Claude Code token cost explorer built locally
The author built a local tool using Claude Code to analyze token usage and costs across conversation sessions and subagents. The explorer provides flame graphs and cumulative plots revealing that Bash tool calls, reasoning tokens, and shared initial instruction blocks drive the majority of context costs. This data helps practitioners identify specific inefficiencies, such as repetitive file reads and growing context sizes over multiple turns. Open article →