Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/luiseiman/dotforge/forge-context-statusgit clone --depth 1 https://github.com/luiseiman/dotforgeWhat 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 | $0.00026 | $0.00508 |
| Opus 5 | $0.00013 | $0.00254 |
| Sonnet 5 | $0.00005 | $0.00102 |
| Haiku 4.5 | $0.00003 | $0.00051 |
Grade B, and why
forge-context-status 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 2d 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.
Detect model from `~/.claude/settings.json` `model` field if available, default to 1M. What it actually says
Read the current session transcript file (path is in the runtime — check $CLAUDE_TRANSCRIPT_PATH env var, or fall back to .claude/session/last-startup.md for the working tree state). Estimate context usage with this approach:
-
Token estimation (proxy): use
wc -con the transcript file (if accessible), divide bytes by 5 for rough token count. This is approximate — actual context = transcript content + system prompt + memory injections. -
Context limit by model:
- Sonnet 4.6 / Opus 4.7: 1M tokens → 80% threshold = 800K
- Haiku 4.5: 200K tokens → 80% threshold = 160K
Detect model from
~/.claude/settings.jsonmodelfield if available, default to 1M.
-
Cache health proxy: read
/tmp/claude-tool-latency-<hash>(the project hash file written bytool-latency.sh). Latency p50 << 100ms on Read/Edit suggests hot cache. p50 > 500ms suggests cache miss / cold reads. -
Recent edits volume: count modifications in
.claude/session/and.git/index.lockrecency.
Output a tight report:
═══ CONTEXT STATUS ═══
Model: Sonnet 4.6 (1M context)
Estimated usage: ~XX% (≈Y tokens)
Cache health proxy: hot | warm | cold (based on tool latency p50)
Files modified: N this session
Last compact: <timestamp from .claude/session/last-compact.md, or "none">
Behaviors disabled: <list from session state>
── RECOMMENDATION ──
< 70%: Continue working
70-80%: Monitor; consider /forge compact-task at next task break
> 80%: /forge compact-task NOW (evidence-based threshold)
> 90%: /forge compact-task URGENT or risk auto-compact mid-task
Be honest about the estimation — token count is a proxy, not exact. If estimate seems off, mention it.
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.
- 2d ago First seen · 38 lines · 26 tokens per session scan B 6a205b217375
forge-context-status is a command published in the GitHub repository luiseiman/dotforge (8 stars, last pushed 2mo ago), licensed MIT. It adds 26 tokens to every session and 508 once invoked, about $0.0001 per session on Opus 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
get-to-work
Autonomous ops work. Args: [mode] [repeat]. Modes: tasks | opps | full | escalating (default). Repeat: cycle (keep going, default) | once (single pass). Run this before stepping away from an ops repo.
recap
Summarize what happened in the project since a given date. Produces a short lead on what's different now, backed by tables and lists covering completed work, state changes, backlog movement, and key decisions. Use when the user wants to catch up on project activity, review recent progress, or generate a status update…
whats-next
Generate an executive overview of the project. Synthesizes state, backlogs, and recent plans into a ranked action plan answering "What should we do next?".
batch-plan
Create a batch of ops plans continuously without user input, storing any user questions in a .md file to be processed with the user afterwards. Do NOT invoke this yourself! Should only be invoked by the user.
batch-execute
Execute a batch of ops plans continuously without user input, storing any issues and user questions in a .md file to be processed with the user afterwards. Do NOT invoke this yourself! Should only be invoked by the user.
find-all
Run both ops finders in parallel (tasks, opps) and brief you on what they found. Discovery only — no plans, no execution.