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.
/plugin marketplace add msshives-gif/claude-plugins/plugin install compact-managerWrote 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.
[](https://agentmods.dev/commands/msshives-gif/claude-plugins/setup)<a href="https://agentmods.dev/commands/msshives-gif/claude-plugins/setup"><img src="https://agentmods.dev/badge/commands/msshives-gif/claude-plugins/setup/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.
<a href="https://agentmods.dev/commands/msshives-gif/claude-plugins/setup"><img src="https://agentmods.dev/badge/commands/msshives-gif/claude-plugins/setup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00013 | $0.00874 |
| Opus 5.5 | $0.00005 | $0.00350 |
| Sonnet 5.5 | $0.00003 | $0.00175 |
| Haiku 4.5 | $0.00001 | $0.00087 |
Grade B, and why
setup scanned grade B with 1 finding 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 1mo ago.
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.
Reads agent configuration directoriesmediumAgent snooping
.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.
itself: `find ~/.claude/plugins -maxdepth 8 -type f -name What it actually says
Walk the user through turning compact-manager on. Be brief — this is two decisions, not a tutorial.
- Locate the compact-manager CLI. The path in the later steps
normally reads as an absolute path (script installs write it in).
If it instead still says
${CLAUDE_PLUGIN_ROOT}literally — plugin installs may not substitute command markdown — find the CLI file itself:find ~/.claude/plugins -maxdepth 8 -type f -name compact-manager -path "*/bin/*" 2>/dev/null(this handles versioned cache layouts, where a directory merely NAMED compact-manager has no bin/). If several paths match, use the most recently modified (ls -t). - Read the current state:
~/.claude/compact-manager.json(may not exist; mode defaults tooff),"${CLAUDE_PLUGIN_ROOT}/bin/compact-manager" overview, andenv | grep '^COMPACT_MANAGER_'— environment variables OVERRIDE the file, so if any are set, warn the user that editing the file alone may not change effective behavior in sessions carrying those variables. If a mode is already set, say so and ask whether the user wants to change it before continuing. - Explain the choice in about three sentences, then ask which mode
they want:
- advisory — pure hooks, any platform, zero risk: the model
is warned crossing 70% of the context window (and again, firmer,
at 80% — whichever thresholds are crossed) so it can save its
working state, and after any compaction the saved state is
injected back so the session resumes oriented. The user still
runs
/compactthemselves. - managed — advisory plus a per-session watcher that types
/compactinto the session's tmux pane at a verified-idle moment. Linux/WSL + tmux only; each session must be attached explicitly. - (off stays available — everything inert.)
- advisory — pure hooks, any platform, zero risk: the model
is warned crossing 70% of the context window (and again, firmer,
at 80% — whichever thresholds are crossed) so it can save its
working state, and after any compaction the saved state is
injected back so the session resumes oriented. The user still
runs
- Ask one follow-up: do they run models with a context window other
than 1M? The default
context_windowis 1,000,000 (the Claude 5 standard); smaller/legacy models need amodelsoverride, e.g.{"haiku": {"context_window": 200000}}(substring match, longest wins). Getting this wrong is asymmetric: too small warns — and in managed mode compacts — far too early; too large just means advisories never fire. - If the user is switching AWAY from managed (to advisory or off):
running watchers snapshot their config at spawn and will keep
typing
/compactregardless of the file change. Checkoverviewfor live watchers and stop each one ("${CLAUDE_PLUGIN_ROOT}/bin/compact-manager" stop <session-id>, with the user confirming the list) — or tell the user explicitly that existing watchers stay active until stopped or their session ends. - Write
~/.claude/compact-manager.jsonwith the chosen mode (and any overrides). If the file exists, MERGE — show the user the exact final JSON before writing, and never drop keys they already set. The hooks re-read the file each time, so it takes effect immediately. - Close with the command map, one line each: managed sessions attach
with the attach command (
/compact-manager:attachor/compact-manager-attach);…statusshows mode, watchers, and per-session usage (or runbin/compact-manager overviewdirectly — no model turn);…detachstops this session's watcher. If they chose managed and this session is in tmux ($TMUX_PANEnon-empty), offer to attach right now.
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.
- 1mo ago First seen · 65 lines · 13 tokens per session scan B 190fb4c23549
setup is a command published in the GitHub repository msshives-gif/claude-plugins (2 stars, last pushed 7d ago), licensed MIT. It adds 13 tokens to every session and 874 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other commands, from other repositories
learn
Force claude-smart to extract learnings from this session now.
recall-save
Generate / overwrite .recall/context.md with Recall's local offline summarizer.
broadcast
Run broadcast on a distilled Raw — update related existing pages conversationally.
ai-act-ask
Answer an EU AI Act question grounded in the bundled knowledge base — verbatim statute text, obligation paraphrases, and the compound-risk taxonomy. Offline and deterministic by default; cites the articles it relies on.
sync
Mid-session context refresh command. Keeps context fresh and consistent during work.
memory-diff
Memory and knowledge-base limit check + global project comparison.