Open-Source Tool Reveals Hidden Token Waste in AI Coding Agents
A developer has released AI Agent Profiler, a local reverse proxy tool that sits between coding agents like Claude Code and LLM providers to track exactly how API tokens are spent. The tool found that only around 60% of API costs stem from actual user prompts, with the remaining 40% attributed to agent overhead such as subagent searches, context summaries, and session-title generation. A key cost driver identified is Claude Code's 5-minute cache expiry window, which forces expensive full cache rewrites on tokens exceeding 200K whenever a user steps away briefly. The profiler classifies requests into 11 categories and flags cold-cache regenerations with severity badges to help users understand idle-gap costs. The tool supports multiple providers including Anthropic, OpenAI, DeepSeek, AWS Bedrock, and Ollama, and can be installed via npm with zero telemetry.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in