The 62% problem: agentic AI bills are mostly re-sent context
There is a number worth sitting with before you sign off on your next AI budget. In a 2026 analysis of agentic AI costs at scale, Cockroach Labs cited Stanford research finding that re-sent context accounts for 62% of total agent inference bills.
Not the model. Not the reasoning. Not the tools. The single largest line item in an agent's cost is the same context, sent again — the system prompt, the conversation so far, the retrieved documents, the tool definitions — re-transmitted on every step of every loop.
Chatbots hid this. A chat call sends context once and returns an answer. An agent sends context, gets a tool call, appends the result, and sends everything again — five, ten, thirty times per task. Goldman Sachs projects a 24x increase in token consumption by 2030, and it is not because prices are rising. It is because agents multiply the same tokens.
Why this is a code problem, not a pricing problem
The instinctive reaction is to wait for token prices to fall. They are falling — roughly 90% since 2023 — and aggregate spend has still doubled since late 2025. Cheaper tokens make teams build more agents, and more agents re-send more context. The problem grows with the market, not against it.
The important consequence: this waste is decided in your code, not on your invoice. Whether context is cached, whether it is trimmed, whether the same call fires twice — those are implementation choices sitting in your repository right now. An observability dashboard can tell you the bill went up. It cannot tell you that a live timestamp three lines into your system prompt is the reason.
Where the 62% actually hides
Across the open-source AI products we have audited, the same mechanical patterns show up again and again — every one of them a form of re-sent context that never had to be re-sent:
A live timestamp defeating prompt caching for an entire framework. MetaGPT embeds the current time into its agent system prompt. Provider prompt caching requires an exact prefix match, so that one dynamic line invalidates the cache on every request — forfeiting the 50–90% cached-input discount across the whole runtime. One line, applied to millions of tokens.
Oversized static context. Passing an entire document, tool catalog, or knowledge base on every call when a handful of relevant chunks would do. The context is identical run to run, so it is a perfect caching candidate — but only if something recognizes it as static.
Redundant calls. Identical requests fired in loops or parallel branches with no deduplication. The cheapest token is the one you never send.
Caching is the highest-ROI fix — if you do the economics honestly
Prompt caching is the obvious lever, and the blogs love to quote "90% savings." The honest version is more nuanced, and erabot models it directly:
- Cached reads are cheaper, not free. Providers bill cached input at a fraction of the base rate (typically 0.1–0.5x), not zero.
- The first write pays a premium. Anthropic charges 1.25x (5-minute TTL) or 2x (1-hour TTL) to establish a cache entry, so caching only pays off above a break-even hit rate.
- There is a minimum cacheable size. Below roughly 1,024–4,096 tokens depending on the model, caching a prefix is not worth it, and recommending it anyway is just noise.
erabot computes the break-even for your actual traffic instead of quoting a headline percentage. Sometimes the answer is "cache this and save 70%." Sometimes it is "this prefix is too small and too rarely repeated — don't bother." Both are useful; only one of them is honest.
Finding it in your own code
The reason re-sent context is 62% of the bill and not 6% is that nobody is looking at the code layer. erabot audit runs inside your own environment, traces every LLM call site — including the framework-wrapped ones a grep would miss — and reports the caching, context-trim, and dedup opportunities with the arithmetic behind each number. Then it verifies each fix before recommending it, so you are not trading a lower bill for worse output.
The 62% is not a law of nature. It is a backlog.