Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By tanvoid0v0.6.0MITIn 1 marketplace
Token cost gate. Tallies every token class at its price off the session transcript, warns when context per turn, spend or burn rate runs hot, refuses shell commands whose output has no ceiling, and blocks tool calls once the budget is gone — which a session may extend itself, up to a ceiling only the user can lift. Adds skills to audit plugin cost and search the public plugin catalog.
Claude loads one when your task matches it, or you run it by name.
1 critical · 2 cautions to review before installing
A hook runs before every tool call and can block or approve it
A hook runs when Claude uses the Bash tool
A hook runs when Claude writes or edits files
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
A PreToolUse hook that watches what a session is spending and stops it running
away. Zero always-on token cost: hooks live outside the model's context.
It tallies every token class at its price off the session transcript, in output-token equivalents. Output alone is the wrong meter: measured over 563 real local sessions, input outnumbers output 268:1, so a gate watching output watches 0.4% of the bill and stays silent through the runaway.
The runaway is not a loop. Every turn re-reads the whole conversation, so cost per turn tracks context size, and cumulative cost is quadratic in turn count — a session feels cheap for its first fifth and expensive by its last, with nothing having gone wrong and no single call to blame.
| gate | default | effect |
|---|---|---|
| unbounded output | git log, ls -R, find, full git diff, cat >64KB | deny, naming the bounded form |
| repeat read | a Read identical to an earlier one, file unchanged since | deny: it is already in context |
| images | 8 in one session | warn: send further screenshots to a subagent |
| context | 120k / 200k / 300k per turn | warn: bound output, delegate search, then hand off to a fresh session |
| burn rate | 120k weighted tokens in 5 min | warn: check the approach is converging, replan smaller if not |
| soft | 60% of budget (900k) | warn: prioritise what is left |
| hard | 100% of budget (1.5M) | deny tool calls; the model can still talk to you |
A gate that says stop without saying here is what the next session needs is why nobody starts a fresh one: the state lives in the transcript, and abandoning it feels worse than paying for another 300k-token turn. So the last turn of an expensive session buys the first turn of a cheap one.
At 300k of context, or once the budget is spent, a Stop hook fires once
and asks for .claude/handoff.md — goal, state, files with paths, decisions and
their reasons, next actions, gotchas. The next session starts with
read .claude/handoff.md and skips the archaeology. /governor:handoff does
the same on demand, at any size.
It cannot loop: stop_hook_active is honoured, and the session's state file
records that it has already fired.
Everything in ~/.claude/skills/ is listed in every session in every project,
at its full frontmatter description. Measured locally: 32 personal skills came
to ~11k tokens per turn, on repos where an image-generation or branding
skill never fired once.
A hook cannot fix that — hooks add context, they cannot subtract from a system
prompt that is already assembled. The only real lever is where the skill
directory lives. So: park them in ~/.claude/skills-parked/, and this plugin
hands discovery back for about 2% of the price.
hooks/skill-index.js runs at SessionStart and prints one line per parked
skill — name plus nine words — only where one could plausibly fire. A
package.json alone does not qualify: that check was caught out by a Flutter
monorepo whose package.json exists to hold npm run release. It wants a real
frontend dependency, or loose .tsx/.html/.vue files, and it bails on any
pubspec.yaml within one level.
/governor:skill <name> then reads that skill's SKILL.md and follows it for
the rest of the session. Same behaviour as a listed skill, paid for only when
used.
Repeat reads are denied only when the file has not changed since — the mtime check is the design, not a nicety. The worst case in the measured transcripts was a screenshot read 22 times, every one legitimate because a crop script rewrote it between reads. A naive path-dedupe would have broken that loop.
Subagent spend counts. A child's tokens are logged to its own transcript and never appear as usage in the parent's, so a fan-out of ten agents used to cost the parent's tally nothing. The total that comes back on the tool result is claimed instead, weighted like input — a child's tokens are mostly its own system prompt being read.
The unbounded-output gate is the only one that saves tokens without costing
anything: a dump is re-read on every remaining turn, so git log and
git log | head -20 differ by one turn's output and a hundred turns' input.
The denial names the bounded form, so the work still happens.
Context is warned on before spend, because it is the cause rather than the symptom, and because it fires while the session can still be steered somewhere cheaper. Burn rate is checked before the budget — spending fast is more urgent than spending a lot. Warnings do not repeat inside 10 minutes.
At the hard gate every tool call is denied, which is the point: it forces a stop and a replan rather than a quiet overrun. The model keeps its voice, so it can report what is done and what is left.
npx claudepluginhub tanvoid0/claude-code-plugins --plugin governorBuilt from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
Plugins from other owners that cover similar ground