Doojyaan

Ctxaudit — Development skill for Claude Code

Development community

Find out how much of your agent's context window is burned before you type a single word.

How to install Ctxaudit

This entry records only its repository, not the path inside it, so there is no exact command to give. Open Doojyaan/ctxaudit and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Ctxaudit does

Find out how much of your agent's context window is burned before you type a single word.

Alternatives in Development

README

ctxaudit

**Find out how much of your agent's context window is burned before you type a single word.**

$ npx ctxaudit

ctxaudit — pre-flight context audit
  /Users/you/payments-platform

  15.0% of the context window is gone before you type.
  ████░░░░░░░░░░░░░░░░░░░░  29,928 / 200,000 tokens
  window: Claude (200k) · tokenizer: o200k_base

  Breakdown
  MCP tool schemas (3 servers)    29,000   96.9%  ████████████
  AGENTS.md                          675    2.3%  ░░░░░░░░░░░░
  skill metadata (4 skills)          127    0.4%  ░░░░░░░░░░░░
  MCP config files                   126    0.4%  ░░░░░░░░░░░░

  What to cut
  • Disable or lazy-load the "github" MCP server      −20,000 tokens
    Tool schemas load at startup and are paid every session,
    including sessions that never touch that server.
  • Prune rarely-used skills                          −63 tokens
    4 skills cost 127 tokens of metadata on every request.

Every agent session starts with a bill you already paid: instruction files, skill metadata, and MCP tool schemas are all loaded before your first message. `ctxaudit` measures that bill, in tokens, per source — and tells you what to cut.


Why this exists

I measured a real install with 1,901 skills and 22 MCP servers. The pre-flight cost was **248,662 tokens — 124% of a 200k window**. The session could not start.

That is an extreme case, but the tax is universal. Published measurements of the same problem:

Observation Source
A Claude Code session starts at ~35,000 tokens before the first keystroke, while another harness starts at 7,000 [HN discussion, P-46]
The GitHub MCP server alone costs 15,000–20,000 tokens of tool schema on every request [GitHub issue, B-11]
A browser toolset adds ~6,600 tokens per request; one study found 71% of tokens spent on tool discovery rather than work [blog, N-06/N-22]
Skill metadata is injected into the system prompt on every request, even when