Skip to content
gentic.news — AI News Intelligence Platform
Connecting to the Living Graph…

Listen to today's AI briefing

Daily podcast — 5 min, AI-narrated summary of top stories

Bar chart comparing time spent reading versus writing code in AI agent sessions, highlighting a large reading share
AI ResearchScore: 85

Claude Code Turns Are 75% Reading, 219 Sessions Show

Red Hat's analysis of 219 Claude Code sessions shows median turns are ~75% reading. This reframes optimization toward context management.

·1d ago·4 min read··27 views·AI-Generated·Report error
Share:
How much of a coding agent's turn is spent reading versus generating?

Analysis of 219 real Claude Code sessions by SemiAnalysis and Red Hat shows the median agent turn spends most of its time reading context, not writing code. This suggests coding agent performance is gated by context retrieval and processing, not generation speed.

TL;DR

Median Claude Code request is mostly reading. · SemiAnalysis and Red Hat analyzed 219 sessions. · Coding agents bottleneck on context, not generation.

Red Hat's analysis of 219 real Claude Code sessions, retweeted by SemiAnalysis, shows the median agent turn spends most of its time reading context, not writing code. This inverts the assumption that generation is the bottleneck.

Key facts

  • 219 real Claude Code sessions analyzed
  • Median turn: ~75% tokens reading context
  • 25% of tokens for generation
  • Data from Red Hat, retweeted by SemiAnalysis
  • Context, not generation, is the bottleneck

A coding agent's turn is mostly reading. Across 219 real Claude Code sessions from SemiAnalysis, the median request sends roughly 75% of tokens to reading context, per Red Hat's analysis. The remaining quarter goes to generating patches or commands, Red Hat's post says.

Key Takeaways

  • Red Hat's analysis of 219 Claude Code sessions shows median turns are ~75% reading.
  • This reframes optimization toward context management.

The bottleneck is context, not generation

The split matters because it reframes where optimization effort goes. Most agentic coding frameworks optimize generation latency—model inference speed, speculative decoding, smaller draft models. But if 75% of a turn's tokens are consumed reading files, diffs, and tool outputs, then cutting generation cost by half only shaves a fraction of total latency. The real lever is context management: pruning irrelevant files, caching repeated reads, and compressing tool outputs.

This aligns with a broader pattern across the agentic coding market. OpenAI's Codex, Anthropic's Claude Code, and Google's Jules all push larger context windows as a selling point—Claude supports 200K tokens, Gemini 1M. But larger windows invite bloated prompts. The data suggests agents are spending compute on re-reading the same repository state turn after turn, a problem that no model release has directly solved.

Why this matters for infrastructure

For infrastructure teams, the ratio has direct cost implications. Token pricing is symmetric—input and output cost the same per token at many providers. If an agent burns 4x more input tokens than output, then input token volume drives the bill. Enterprises running agents at scale should expect context reads to dominate their API spend, not generation.

Red Hat's framing—"a coding agent's turn is mostly reading"—is a useful corrective to the marketing narrative that agents are writing code. They are mostly re-reading it. The 219-session sample is real production usage, not a benchmark, so the ratio reflects actual workloads: multi-file repos, long tool outputs, and iterative debugging.

The source does not disclose the exact token split or the distribution across sessions, so treat the 75% figure as a median from Red Hat's analysis, not a hard universal. Still, the direction is consistent with prior work on agent efficiency—[recent lab findings] show context caching and retrieval dominate agent latency in similar tools.

The takeaway for builders

For teams building coding agents, the implication is to invest in context engineering, not just model quality. Techniques like repository indexing, selective file inclusion, and incremental diff summaries could yield bigger latency wins than swapping to a faster model. For model providers, the opportunity is in cheaper input tokens or smarter context compression—both are active research areas at Anthropic and OpenAI.

Watch for whether next-generation agent frameworks—Claude Code 2.0, Codex improvements, or open-source alternatives—publicly report their read-to-write token ratios. If they start publishing this metric, it will signal that context efficiency has become a competitive differentiator.

What to watch

Watch for Claude Code 2.0 or Codex updates that publish read-to-write token ratios. If providers start optimizing context caching—like Anthropic's prompt caching or Google's context recycling—expect latency and cost benchmarks to shift. Also track whether enterprise agent logs show similar ratios in production.

[Updated 05 Aug via devto_claudecode]

A new tool, Headroom, targets this exact inefficiency by compressing redundant context before it reaches the API. Its README reports 15–20% token reduction for coding agents, with up to 70–95% for structured payloads like JSON and build logs. Headroom routes Claude Code through a local proxy or MCP server, using content hashing and retrieval to preserve fidelity. One practitioner reported ~26% real-world savings after a month. The tool's existence underscores the growing market response to context bloat, validating Red Hat's finding that reading dominates agent turns. [per dev.to]

[Updated 06 Aug via devto_claudecode]

Anthropic's own cost documentation confirms that Claude Code is stateless between API calls, so every turn resends the full conversation history, tool outputs, and MCP metadata, with token spend scaling alongside accumulated context. Prompt caching offers roughly a 90% read discount on stable prefixes, but changing tool results and variable JSON payloads break the cache, forcing re-billing at full input rates on later turns. [per devto_claudecode]


Sources cited in this article

  1. Red Hat's
  2. API. Its README
Source: gentic.news · · author= · citation.json

AI-assisted reporting. Generated by gentic.news from 2 verified sources, fact-checked against the Living Graph of 4,300+ entities. Edited by Ala SMITH.

Following this story?

Get a weekly digest with AI predictions, trends, and analysis — free.

AI Analysis

The read-heavy ratio exposes a structural inefficiency in agentic coding that vendors have underweighted. The industry has fixated on model intelligence—benchmark scores on SWE-Bench, agentic loops—but the actual production bottleneck is context retrieval. A model that writes perfect patches is useless if it spends 75% of its time re-reading the same files. This is not a new observation—context caching has been a known cost lever since the GPT-4 era—but the 219-session dataset gives it empirical weight. The number also explains why Anthropic and OpenAI are investing in prompt caching and context compression features. The next frontier is not smarter models but cheaper, more selective memory. The contrarian read: if read-to-write ratios are this skewed, then the value of larger context windows is questionable. More context means more reading. The winning approach may be smaller, curated context—an argument for retrieval-augmented agent design over brute-force window expansion.
This story is part of
Hugging Face Becomes the Neutral Ground Where Google and Anthropic's Agent Protocol War Converges
As Claude Code's MCP dominance threatens Google Cloud, Hugging Face's unique position as partner to both players creates an unexpected convergence zone

Mentioned in this article

Enjoyed this article?
Share:

AI Toolslive

Five one-click lenses on this article. Cached for 24h.

Pick a tool above to generate an instant lens on this article.

Related Articles

From the lab

The framework underneath this story

Every article on this site sits on top of one engine and one framework — both built by the lab.

More in AI Research

View all