Skip to content
Agentmart
Submit a tool

auditing-agent-token-usage

Audits recent Claude Code and Codex session logs for token and context cost: model routing, inherited subagent models, long sessions, compactions, oversized…

Skill by bostonaholic

IndexedMIT★ 2
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/bostonaholic-auditing-agent-token-usage

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Audits recent Claude Code and Codex session logs for token and context cost: model routing, inherited subagent models, long sessions, compactions, oversized tool results, and unused MCP servers. Use when asked about agent token usage, context costs, session length, model routing, or cost efficiency.

Use cases: agent-building

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 26, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found
Runs as
Shell scripts

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/auditing-agent-token-usage

What's inside

Skill name
auditing-agent-token-usage
Description
Audits recent Claude Code and Codex session logs for token and context cost: model routing, inherited subagent models, long sessions, compactions, oversized tool results, and unused MCP servers. Use when asked about agent token usage, context costs, session length, model routing, or cost efficiency.
License
MIT
Instructions
28 lines in SKILL.md · view on GitHub

Before installing

  • Ships executable scripts

Files (3)

  • SKILL.md
  • openai.yaml · agents/
  • audit-token-usage.sh · scripts/

SKILL.md (first lines)

# Auditing agent token usage

Run the deterministic audit, then explain its results. The script is the
measurement; do not substitute your own log reading for it.

```sh
"<skill-dir>/scripts/audit-token-usage.sh" <days>
```

`<days>` is a positive integer, default seven unless the user names another
window. The script needs `jq` and reads Claude Code transcripts and Codex
rollouts under the home directory. On a nonzero exit, relay stderr and stop.

## Analyze

- State the window and which sources had data. Claude Code sections, [1] to
  [5], measure transcript proxies such as turn counts and character sizes. The
  Codex section, [6], uses recorded token counts.
- Identify the largest evidenced costs: expensive model usage, inherited
  subagent routing, long sessions, compactions, context re-reading, oversized
  tool results, and configured MCP servers absent from section [5].
- Recommend only changes the output supports: at most three, ranked by
  expected impact, each citing the count or percentage behind it.
- Never present Claude Code proxy values as measured tokens.
- When a source is absent or the script fails, report the missing data or
  prerequisite. Do not infer its usage.

From bostonaholic/skills, MIT.

More from bostonaholic/skills

Signals

Stars
2
Forks
0
Open issues
2
Last commit (this folder)
Oct 22, 2026 (7 days ago)
Last release
Oct 24, 2026 (4 days ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from bostonaholic

Cite this page

auditing-agent-token-usage skill. Agent Mart. https://agentmart.dev/skills/bostonaholic-auditing-agent-token-usage (last updated 2026-10-24)