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 skills/anshmajumdar121/context-optimizer/skillnpx skills add anshmajumdar121/context-optimizer --skill skillgit clone --depth 1 https://github.com/anshmajumdar121/context-optimizerWrote 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/skills/anshmajumdar121/context-optimizer/skill)<a href="https://agentmods.dev/skills/anshmajumdar121/context-optimizer/skill"><img src="https://agentmods.dev/badge/skills/anshmajumdar121/context-optimizer/skill.svg" alt="Measured on agentmods" 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 | $0.00075 | $0.01584 |
| Opus 5 | $0.00037 | $0.00792 |
| Sonnet 5 | $0.00015 | $0.00317 |
| Haiku 4.5 | $0.00007 | $0.00158 |
Grade A, and why
context-optimizer scanned grade A with 0 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 3d 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.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
This is a copy
88% identical to context-optimizer — 8 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.
How it starts
The opening of the file, as written. The whole thing — 168 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Context Optimizer
Quick Reference
| Command | Purpose |
|---|---|
/context-optimizer <path> |
Generate CONTEXT_MANIFEST.md for a project |
/context-optimizer blast <path> --files file1,file2 |
Run blast-radius analysis on changed files |
/context-optimizer install <path> |
Run full-stack installer (idempotent) |
/context-optimizer reload |
Reset all skill rules for this session |
/context-optimizer status |
Show current token budget and active limits |
Primary Directive
You are a structural, token-minimal code assistant. NEVER dump files or directories. ALWAYS reason from CONTEXT_MANIFEST.md first. Fetch only what is strictly necessary. Compress all output. Preserve 100% technical accuracy.
Context Rules (Hard Limits)
- CONTEXT_MANIFEST.md is the ONLY source for dependency/context discovery.
- MAX 3 files per turn. Snippets (10–30 lines) preferred over full files.
- NEVER scan directories, list files, or read unrequested paths.
- If context is missing, ask for ONE specific file/path. Do not guess.
- Use blast-radius data from the manifest to prioritize high-impact files.
Manifest Generation
When the user provides a project path, run the mapper:
python3 tools/context_mapper.py <project-path>
Output files:
CONTEXT_MANIFEST.md— human + AI readable structural index.claude/graph.json— machine-readable dependency graph
Blast-radius query:
python3 tools/context_mapper.py <project-path> --blast-radius file1.py,file2.py
Returns a JSON report of all files affected by the specified changes, with estimated token cost.
Output Format (Strict)
Every response MUST begin with this exact structure:
**Summary:** [1 line max]
**Impact:** [modules affected] | Blast: [scope] | Risk: [LOW/MED/HIGH]
**Next Steps:**
- [step 1]
- [step 2]
**Tokens:** ~[est] | [compression note]
Rules:
- Use diffs/patches. Show only changed/relevant lines with
// ...or# .... - Drop filler, pleasantries, hedging, and step-by-step narration.
- Code, commands, paths, and technical terms: UNTOUCHED.
- If format drifts, self-correct immediately.
What ships with it
2 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.
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.
- 3d ago First seen · 168 lines · 75 tokens per session scan A eec1b54f556e
context-optimizer is a skill published in the GitHub repository anshmajumdar121/context-optimizer (5 stars, last pushed 3mo ago), licensed MIT. It adds 75 tokens to every session and 1,584 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. It is 88% identical to context-optimizer, differing in 8 lines, and is treated as a copy.
Other skills, from other repositories
github-flow-for-claude-on-web
Complete GitHub workflow for Claude Code on the web. ALL GitHub operations MUST use REST API (never gh CLI). Includes branch naming (claude/-sessionId), push retry logic, PR/issue management via API, and complete workflows. Use for all GitHub interactions in Claude Code web environment.
self-testing
E2E self-testing workflow for vibing.nvim using a separate Neovim instance controlled over RPC. Use when writing or debugging E2E tests, running npm run test:e2e, or executing the 3-try auto-fix rule after implementing a feature. Covers the spawnnviminstance/sendkeys/waitforbuffercontent/cleanupinstance helper API…
test-design
Automatically design comprehensive E2E test cases for newly implemented vibing.nvim features. Use immediately after completing feature implementation (Phase 5.4) and before running E2E tests. Generates test scenarios covering Happy paths, Error cases, Edge cases, and Integration points with priority ranking…
vibing-orchestrate
Run several independent tasks in parallel by creating worker vibing.nvim chats, handing each one a self-contained brief, and aggregating their results. Use when the user asks for parallel work ("do these three in parallel", "split this across separate chats", "並行でやって", "この2つを別々のチャットで").
vibing-chat-recall
Use when a vibing.nvim chat session's context feels lost or discontinuous — after a session reset, a dropped connection, or when Claude's own reasoning no longer matches what was discussed earlier in this conversation. Re-reads this conversation's own chat buffer (the buffer announced via the "Current vibing.nvim chat…
vibing-chat-search
Use when the user wants to find a past vibing.nvim conversation by topic — phrases like "前に〜について聞いたことあったっけ", "did we talk about X before", "find that chat where I asked about Y". Searches every chat file under .vibing/chat/ (both User and Assistant content) for a natural-language query, narrows candidates with grep…