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 skills add berkcangumusisik/claude-code-practices --skill cost-auditgit clone --depth 1 https://github.com/berkcangumusisik/claude-code-practicesWrote 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/berkcangumusisik/claude-code-practices/cost-audit)<a href="https://agentmods.dev/skills/berkcangumusisik/claude-code-practices/cost-audit"><img src="https://agentmods.dev/badge/skills/berkcangumusisik/claude-code-practices/cost-audit/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/skills/berkcangumusisik/claude-code-practices/cost-audit"><img src="https://agentmods.dev/badge/skills/berkcangumusisik/claude-code-practices/cost-audit.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.00025 | $0.00645 |
| Opus 5.5 | $0.00010 | $0.00258 |
| Sonnet 5.5 | $0.00005 | $0.00129 |
| Haiku 4.5 | $0.00003 | $0.00064 |
Grade A, and why
cost-audit 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 2mo 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.
How it starts
The opening of the file, as written. The whole thing — 71 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Goal
Make it visible where the tokens in this session actually went. Not guesses — evidence. Output: "do these 3 things next time and you save ~X%."
Step 1 — Capture current cost
/cost
Note the output: total tokens, input/output split, cache hit rate, total $.
Step 2 — Find the leaks
Scan the transcript for these signals:
| Signal | How to detect it | Why it wastes tokens |
|---|---|---|
| Unnecessary file reads | Read calls touching node_modules/, dist/, *.lock, coverage/ |
Missing .claudeignore |
| Re-reading the same file | Same path appears in multiple Read calls |
Context lost — /compact should have happened earlier |
| Reading entire large files | Read without limit on files >500 lines |
Should have used offset/limit or Grep |
| Bash + grep/cat/find | Bash calls to grep, cat, find, ls -R |
Dedicated tools (Grep/Glob/Read) are cheaper and more precise |
| Vague prompt → many tool calls | Single-word asks ("improve", "fix", "look") followed by 5+ tool calls | Prompt wasn't specific |
| Repeated onboarding research | Same concept re-discovered across sessions | Belongs in CLAUDE.md |
Step 3 — Report
Give the user a report in this shape:
## Session summary
- Total: <tokens> (<$>)
- Cache hit: <%>
## Top 3 leaks
1. [Evidence]: X files under src/components/ were read in full; ~Y tokens combined
Fix: add to .claudeignore → <lines>
Estimated savings: ~Z%
2. ...
3. ...
## Action list
- [ ] Create .claudeignore with <lines>
- [ ] Add a "<topic>" section to CLAUDE.md
- [ ] Use `/compact <hint>` earlier in long sessions
Step 4 — Optional auto-fixes
If the user approves:
- Create
.claudeignoreif missing, add the detected paths - Create a
CLAUDE.mdscaffold if missing, seed it with the repeated-research topics - Suggest a specific
/compacthint phrase for this project
Rules
- No guessing — only report what's in the transcript
- Always a number — not "a lot", but "12,400 tokens"
- Action-oriented — every finding ends with a concrete command or edit
- Keep it short — 3 top leaks is plenty; skip the long tail
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.
- 2mo ago First seen · 71 lines · 25 tokens per session scan A c7c793709b18
cost-audit is a skill published in the GitHub repository berkcangumusisik/claude-code-practices (11 stars, last pushed 6mo ago), licensed MIT. It adds 25 tokens to every session and 645 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
cost-audit compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| cost-auditberkcangumusisik/claude-code-practices | Skill | 11 | 6mo ago | MIT | A | 25 | Claude Code |
| open-sourcebrowser-use/browser-use | Skill | 120k | yesterday | MIT | A | 137 | Claude Code |
| prompt-masternidhinjs/prompt-master | Skill | 16k | 15d ago | MIT | B | 78 | Claude Code, Codex |
| skill-builderyusufkaraaslan/Skill_Seekers | Skill | 15k | 1mo ago | MIT | A | 38 | Claude Code, Codex |
| pre-meeting-briefchrisblattman/claudeblattman | Skill | 476 | yesterday | MIT | A | 23 | Claude Code |
| schedule-querychrisblattman/claudeblattman | Skill | 476 | yesterday | MIT | A | 17 | Claude Code |
| todo-addchrisblattman/claudeblattman | Skill | 476 | yesterday | MIT | A | 18 | Claude Code, Codex |