Claude Code sends each active background agent's full transcript to Opus every 30 seconds for a 3-word status line, and a Bun preload brings that agent_summary spend to zero
- In one week of Claude Code OpenTelemetry data, requests tagged query_source = agent_summary took 16.4% of estimated spend (the main conversation took 15.7%) and 19.7% of all API requests, at roughly 9,000 input tokens per output token, with 96% of that spend on Opus.
- Claude Code fires the summary call about every 30 seconds for each actively working background agent, sending that agent's entire transcript to its own model for a 3 to 5 word status line that never reaches the conversation, and no supported setting turns off only the summaries.
- Anthropic engineer Edwin Arbus put the fleet-wide number at about 2% of cost at API list prices (just under 4% of requests, about 6% in the terminal), said version 2.1.311+ fixes the case where summaries miss the prompt cache, and said a cheaper mode that sends short notes to a smaller model is in progress.
- The workaround is no-agent-summary.js, an ~80 line Bun preload loaded with BUN_OPTIONS=--preload that wraps setTimeout and setInterval and returns an inert handle with a 2,147,483,647 ms delay when a callback's source text contains an anchor such as
[AgentSummary] Timer fired, leaving the Claude Code binary unmodified. - Reported shares vary by workload: about 8% for mostly short-context subagents, about 16% for heavy research subagent use, roughly 3% across one team, while GitHub issue #86879 collects four independent measurements of 18 to 26%.
Hacker News 의견들
16.4% of our spend on a three-word status line, and one in five requests. Most of it hits the prompt cache, but re-reading a big cached transcript over and over costs real money. We couldn't find a supported setting that kills only the summaries, so we hooked the timer.
Claude Code is bloatware. I'll take Pi, it's minimal and I actually like using it.
I daily drive a harness leaner than Pi and there's still a case for both. Claiming one harness is best for everyone is shortsighted.
Does this happen in Claude Desktop too, or is it terminal only?
Is this the status line at the bottom of the terminal or the little summaries in the agents panel? I run disableAgentView in my settings, does that stop the calls or just hide the panel?
If they send the full transcript and ask for a summary, isn't nearly all of that a cache hit, and therefore cheap?
Even at cache hit prices you're paying input times 0.10 times the context, repeatedly. Do that ten times and you've spent what a fresh prefill of the whole session costs, and people here are either rich or way too rich.
Didn't they cut the cache TTL to five minutes earlier this year? Depending on the exact timing it could expire between updates.
The cache only hits if everything before the summary matches, including MCP and tool definitions. If they don't pass your tools to the summariser, you get no caching benefit at all.
I tested it and it's real but narrower than the post suggests. It's just subagents, workflows seem unaffected, and it's mostly cached reads, so short-context subagents cost little. In my sessions it's about 8% at most.
8% is still pretty indefensible when you can't switch it off. That's a big chunk of a weekly limit.
Mine is about 16%. I run a lot of research subagents where fixed workflows don't fit the work.
I work on Claude Code. You have the mechanism right, but this only applies to background agents that are actively working, idle ones don't get the call. Across users who send us telemetry last week, agent_summary was about 2% of cost at list prices, just under 4% of requests, and about 6% of cost in the terminal. We shipped a fix for the cache-miss case in 2.1.311 and we're building a cheaper mode that sends short notes to a smaller model.
Thanks for the context. Now add a real setting to turn agent summaries off. As it stands the SDK option and the env var can only switch them on.
A status line should be optional, or the tokens for it should be free. Anything else is insane.
I'm at 15%+ too. That explains a lot about how fast I hit the weekly cap.
On Pro: two days ago a full 5-hour window ate 25% of my weekly quota, today the same thing is about 13%. Something got fixed.
That's an A/B test on their side, not a fix. Mine on 20x Max still eats about 32%.
Background agents only get a 5 minute cache TTL. And "15 to 20% of your tokens" is ambiguous, is that all tokens or only tokens spent on background agents? Poorly edited AI writing again.
Just checked our numbers and we're burning around 3%, but that's across everything and everyone, not per session.