Skip to content

Reduce token costs

The Optimize tab estimates where your tokens go and offers three levers. Apply them in order of impact.

  1. Install recommended subagents. The analyzer suggests curated subagents (most pinned to a cheaper model) for routine work — file reads, log parsing, test triage. Accept the recommendations to install them into ~/.claude/agents/, and that work returns a digest on a cheaper model instead of raw output on your main model.

  2. Turn on reversible compression. Pick a level — Conservative, Moderate, or Aggressive. Oversized tool_result payloads get trimmed; the original is stored so Claude can pull it back with mcp__sentinel__retrieve if it’s ever needed.

  3. Enable MCP code execution. Bridge your MCP servers through the loopback endpoint so their tool definitions stop being injected into every request’s context. Add the servers you want bridged to the per-server allowlist.

The defaults are conservative on purpose. For the biggest savings, configure each of the three Optimize sub-tabs as follows.

Open the Subagents tab and, under Curated subagents, click Install on these seven right away — they cover the routine, high-volume work that otherwise burns main-model tokens:

  • file-explorer
  • log-analyzer
  • diff-pre-pass
  • web-fetcher
  • dep-tracer
  • bulk-reader
  • bash-loop-summarizer

Leave the rest for later. Check the Potential tile and the Opportunities analyzed list from time to time, and install additional subagents once you’ve reviewed the savings they’d actually earn for your workload.

Open the Compression tab, turn on Enable compression, and set Aggressiveness to Aggressive — the tightest caps trim the most.

Open the Context tab. In the MCP context costs table, use Switch to code execution on every server you can, so their tool definitions stop riding along in every request.

Then scan the Context-bloat inventory below it and disable anything you no longer use — stale CLAUDE.md files, memory directories, plugins, or globally enabled subagents. Everything left enabled is paid for on every request.

Each lever shows realized vs potential savings on the Optimize tab. To see the effect in real money and tokens, watch the Metrics tab over a few days before and after — cache hit rate and per-model cost are the numbers to compare.

For the full description of each technique, see Token optimization.