calibrate-hooks

calibrate-hooks is a skill for Claude Code from odere-pro/claude-calibration. It costs 243 tokens per session (1,694 once invoked), scanned C, original, MIT.

A checker for coding-agent hooks in settings files and hook scripts. Hooks are automated actions that run when events such as tool use or user prompts occur.

In plain words
What is it for?
Use it to audit hooks across user, project, and plugin layers and to review the reported configuration or script problems.
Why use it?
It identifies unsafe or unreliable hook setups, including overly broad matchers, incorrect blocking behavior, untrusted remote scripts, duplicate rules, and missing local sourcing.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: model in frontmatter; reads .claude/ paths; mentions subagents.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the claude-calibration plugin — 20 skills, 6 agents, 2 hooks shipped together

Good fit Use it to audit hooks across user, project, and plugin layers and to review the reported configuration or script problems.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add odere-pro/claude-calibration
Claude Code
/plugin install claude-calibration

Made for: Claude Code.

Or install claude-calibration, the plugin that ships this one along with the rest of its 20 skills, 6 agents, 2 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for calibrate-hooks

README.md
[![agentmods](https://agentmods.dev/badge/skills/odere-pro/claude-calibration/calibrate-hooks/github.svg)](https://agentmods.dev/skills/odere-pro/claude-calibration/calibrate-hooks)
Your own site
<a href="https://agentmods.dev/skills/odere-pro/claude-calibration/calibrate-hooks"><img src="https://agentmods.dev/badge/skills/odere-pro/claude-calibration/calibrate-hooks/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for calibrate-hooks

Your own site · 80×15
<a href="https://agentmods.dev/skills/odere-pro/claude-calibration/calibrate-hooks"><img src="https://agentmods.dev/badge/skills/odere-pro/claude-calibration/calibrate-hooks.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 243 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,694 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 2 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00243 $0.01694
Opus 5 $0.00121 $0.00847
Sonnet 5 $0.00049 $0.00339
Haiku 4.5 $0.00024 $0.00169

Measured 10d ago against content hash f66b12b0345e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade C, and why

calibrate-hooks scanned grade C with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/enumerate.sh, scripts/lint.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Downloads and executes remote codehighSupply chain

curl | sh runs whatever the server returns today, which is not necessarily what it returned when this was reviewed.

or `${CLAUDE_PLUGIN_ROOT}/hooks/`. Hooks that `curl | sh` re-fetch on every fire and are a

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

commands that `curl`/`wget`/`npx` remote payloads, heavy work (`build`/`test`/`tsc`/`webpack`)
skills/calibrate-hooks/SKILL.md · 117 lines

How it starts

The opening of the file, as written. The whole thing — 117 lines — stays where its author put it; the contents beside it link to each section on GitHub.

calibrate-hooks — per-feature bundle

You audit and tune hook configurations and hook scripts. Two entry points:

  • Direct invocation (/claude-calibration:calibrate-hooks) — audit everything, report findings, propose fixes inline.
  • Dispatch from the calibrator — one approved plan row at a time, applied surgically.

The workflow is the same; only the framing differs.

1. Enumerate

bash <BUNDLE>/scripts/enumerate.sh "$PROJECT_DIR"

Yields TSV scope\tpath. Scope is settings (a settings.json with a hooks block — user or project), script (a project-local hook script under .claude/hooks/), script-user (user hook script under ~/.claude/hooks/), or plugin-self (when the project is itself a plugin and ships hooks at <plugin-root>/hooks/).

2. Lint

bash <BUNDLE>/scripts/lint.sh <path …>

Yields TSV path\tsignature\tseverity\tdetail. The signatures this bundle owns (see reference.md):

  • hook:matcher-bare-star (MEDIUM)
  • hook:exit-1-non-blocking (HIGH)
  • hook:remote-untrusted (HIGH)
  • hook:duplicate-across-layers (LOW) — only fires when multiple settings files are passed
  • hook:not-locally-sourced (LOW)
  • hook:heavy-on-pretooluse-heuristic (MEDIUM)
  • hook:invalid-json (HIGH)

3. Fix — kind: edit rows

For each finding, the remediation pattern lives in examples/<case>/:

  • hook:matcher-bare-starexamples/matcher-bare-star/{before,after}.md. Narrow the matcher to the specific tool(s) (Edit|Write|MultiEdit) plus a path pattern. Bare * on a hot event fires on every tool call.
  • hook:exit-1-non-blockingexamples/exit-1-non-blocking/{before,after}.md. Replace exit 1 with exit 2 when the intent is to block; keep exit 1 only for non-blocking warnings. The semantics: exit 0 = pass, exit 1 = non-blocking warning surfaced to the user, exit 2 = block the tool call and surface stderr to Claude.
  • hook:remote-untrusted → vendor the script locally under ${CLAUDE_PROJECT_DIR}/.claude/hooks/ or ${CLAUDE_PLUGIN_ROOT}/hooks/. Hooks that curl | sh re-fetch on every fire and are a supply-chain risk.
  • hook:heavy-on-pretooluse-heuristic → move the heavy work to a Stop hook (runs at session end) or a manual command. PreToolUse/PostToolUse must stay sub-second.
  • hook:not-locally-sourced → point the command at ${CLAUDE_PROJECT_DIR}/... or ${CLAUDE_PLUGIN_ROOT}/... rather than relying on system PATH.
  • hook:duplicate-across-layers → delete the duplicate from one layer (usually the user layer defers to project, or vice versa — keep the one closer to the change).
  • hook:invalid-json → fix the JSON. Run python3 -m json.tool <settings.json> to find the parse error.

Read the full file on GitHub · 117 lines

Files

What ships with it

8 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 117 lines · 243 tokens per session scan C f66b12b0345e

Subscribe to this mod's changes

calibrate-hooks is a skill published in the GitHub repository odere-pro/claude-calibration (1 stars, last pushed 1mo ago), licensed MIT. It adds 243 tokens to every session and 1,694 once invoked, about $0.0012 per session on Opus 5. A static security scan graded it C with 2 findings (downloads and executes remote code, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.