Coralogix
Read post

Where did all my Claude Code tokens go?

Most teams evaluate AI coding agents by their monthly bill and gut feeling, but neither reveals what the agent actually did. An experiment using Claude Code across three coding approaches (open/default, TDD, and skip-permissions) with OpenTelemetry telemetry piped to an observability backend reveals that total cost is a misleading metric. Per-turn cost and cache hit rate are far more informative signals. Cache invalidation events — where the agent rewrites its own plan mid-session — are the primary cost driver, not code generation itself. About 63% of spend is context re-read, ~25% is cache writes, and only ~11% is generated output. The key cost levers are: keeping context lean, scoping sessions tightly, matching model size to task complexity, and generating in proportion to need. These findings were validated across 20,000+ real Claude Code sessions over 90 days.

    #ai-agents#observability#claude-code#opentelemetry
Jun 25•11m read time•From coralogix.com
Post cover image
Table of contents
Right now, most teams are guessingThe signal is already thereI tried three approaches to building the same appThe total bill was misleadingPer-turn cost is where the truth shows upWatching the agent change its mindIt’s not just meThe levers that actually move costWhat to go and look at
19 Impressions
Coralogix's image
Coralogix

22 Followers

•

214 Upvotes

Would you recommend this post?

Copy link
WhatsApp
Facebook
X
New Squad
  • © 2026 Daily Dev Ltd.
  • Guidelines
  • Explore
  • Tags
  • Sources
  • Squads
  • Leaderboard