Flamerix AI discovered that Claude Code versions 2.1.232 through 2.1.312 spend 15–20% of their token budget on background agent status summaries, a feature enabled by default since August 2026. Every ~30 seconds, each background agent sends its entire transcript to Opus with a prompt to describe its recent action in 3–5 words; the response updates only the UI status panel and never reaches the user or main model. OpenTelemetry data showed agent_summary requests consuming 16.4% of total spend (surpassing the main conversation at 15.7%) and 19.7% of API requests, with a 9,000:1 input-to-output token ratio and 96% of that cost on Opus. The no-agent-summary.js Bun preload (~80 lines) suppresses this by hooking setTimeout/setInterval, detecting the summarizer callback via Function.prototype.toString matching a "[AgentSummary] Timer fired" anchor, and returning an inert timer handle (delay 2³¹−1 ms). Verified on Linux across versions 2.1.257–2.1.312, the hook reduces agent_summary spend to 0% without affecting subagent execution; only the panel status stops updating. Overhead is ~7 ms per claude --version call. A cheaper "short mode" (2k token notes) exists in 2.1.310+ but remains disabled by default. Users must set BUN_OPTIONS=--preload with an absolute path and restart the daemon (claude daemon stop --any) to apply; verification requires checking OpenTelemetry for query_source=agent_summary at zero.

Read original