Code Agents After 21.54 Billion Tokens: What’s Missing?
Tech
AI
Code Agents
MCP
OpenAI

Code Agents After 21.54 Billion Tokens: What’s Missing?

I ran 21.54 billion activity tokens through real code-agent work. The models improved, but the system still matters more.

Uygar DuzgunUUygar Duzgun
Jul 12, 2026
8 min read

My code agents used Claude Fable 5 and OpenAI’s GPT-5.4, GPT-5.5, and GPT-5.6 family on real work throughout 2026: websites, iOS apps, e-commerce, CRM, music tools, SEO systems, and my own agent workflows. When I summed the local session logs still left on my Mac, the number landed at 21.54 billion tokens.

That number is absurd. It also needs context.

Most of that is not 21.5 billion new words written for me. Long agent sessions send large codebases and instructions through context multiple times. A large part gets read from cache. The token count mainly shows how much context my code agents worked through.

My conclusion after this period is still clear: we have leveled up. The models can hold together longer tasks, use tools, and repair mistakes at a level that felt far away a year ago. However, the model itself is still the least interesting part of a reliable system.

What 21.5 billion tokens says about code agents

I counted OpenAI usage from each `last_token_usage` value in preserved Codex logs. I counted Fable from unique assistant messages in Claude logs, using normal input, cache creation, cache read, and output. The result is a local activity measurement — not an OpenAI or Anthropic bill.

ModelLogged activity tokensUnique usage events / model replies
------:---:
GPT-5.512.96 billion95,930
GPT-5.6 Sol, Terra, and Luna1.88 billion12,370
GPT-5.4 including Mini3.43 billion26,624
Claude Fable 53.27 billion16,878
Total21.54 billion151,802

Using the high-water method, GPT-5.4 accounted for about 3.21 billion cached input tokens, GPT-5.5 for 12.30 billion, and the GPT-5.6 family for about 1.82 billion. The Fable logs contained about 3.05 billion cache reads and 181 million cache creation tokens.

That is why comparing the total to the amount of text a human could read is misleading. Agent work reuses large contexts. The relevant question is whether the system did the right thing with them.

Prompt — Copy & Paste
**Method note:** logs may have been deleted, moved, or missing from other computers and cloud runs. These numbers are a verified floor for this Mac, not complete account history or vendor billing data. For each physical Codex rollout, I counted only increases above the previous highest observed `total_token_usage.total_tokens` value. Unchanged values and decreases contributed zero. That makes 21.54 billion a conservative floor. Claude logs were deduplicated using the message UUID.

The codebase behind the usage: 59 GitHub projects

At the time of measurement, my GitHub account had 59 repositories: 50 private and 9 public. They break down roughly like this:

24 in AI, agents, and automation
12 in e-commerce, CRM, and business systems
8 in web, content, and education
5 native apps
5 music, video, and media projects
5 infrastructure and tooling projects

On the 26 GitHub repos that had a local checkout with the exact same name, I found 6.90 million tracked source lines after filtering out vendor, build, cache, and minified files. That number is dominated by three large legacy PHP platforms. If I remove those, about 357,000 lines remain in the more modern, more self-built surface that includes TypeScript, Python, Swift, Shell, and Astro.

This is not an attempt to win a code-line contest. A million bad lines is still debt. The statistics show the breadth of the environment where the models were tested: mobile, backend, frontend, automation, content, operations, and business logic.

Fable 5 and GPT-5.6 are better — in different ways

Anthropic describes Fable 5 as its model for large code projects, migrations, and long autonomous sessions. OpenAI describes GPT-5.4 as a merge of frontier coding, knowledge work, and computer use. The GPT-5.6 family has pushed the focus even further toward long-running agent work.

That matches my experience pretty well. Fable is often better at understanding the shape of a hard problem before it starts changing code. GPT-5.6 Sol is more likely to grab the problem, use the tools, and drive the work forward.

The X debate shows the same split:

Forrest Knight calls Fable best at coding but criticizes its speed and the safety blocks that affect normal tasks.
Will Sentance says the API price makes constant Fable use unreasonable and suggests Fable as a planner with cheaper subagents.
Mikhail Parakhin judges Fable better at the coding itself and GPT-5.6 better at agentic workflows.
Simon Willison points to a new problem: the user has to choose between multiple models and reasoning levels for the same task.
Peter Gostev warns how quickly GPT-5.6 with fast mode, high reasoning, and many subagents can burn through the usage budget.
Babak Morshedizadeh criticizes the gap between the model’s promised API context and the smaller window Codex actually gives a session.

That criticism is fair. A better model can still create a worse workday if routing, pricing, context limits, or security policy are hard to understand.

A modular agent stack with models, tools, memory, and verification
A modular agent stack with models, tools, memory, and verification

The model is the engine, not the car

A language model can reason about code. A code agent also has to operate inside a real system.

My practical stack looks like this:

Skills describe reusable workflows and domain rules. The agent does not have to invent the process in every session.
Tools provide controlled access to terminal, files, browser, APIs, databases, and apps.
MCP standardizes how the agent discovers and calls external capabilities.
Memory saves verified decisions, paths, and past failures without forcing the entire history into every prompt.
Git shows what actually changed and makes the work reviewable.
Verification runs lint, test, build, simulator, live website, or live API checks.
Human approval stays in place before publishing, payments, database changes, and production.

Each part solves a different problem. A skill without tools is documentation. A tool without policy is a risk. Memory without source control becomes old folklore. A build without live checks can still leave production broken.

Recommended reading

MCP Developer Workflows: The Real Control Layer matters especially because it moves integration away from custom prompts and into a contract that multiple clients can understand. My personal-page MCP can, for example, research, create a draft, generate images, analyze SEO, and publish. The same agent still has to know when to stop at an unpublished draft.

The big leap is longer work chains

Recommended reading

In my earlier test of GPT-5.5 in Codex, I saw the same shift. A year ago, a good coding session was often: ask, get a code block, copy, test it yourself. Now an agent can read project rules, find the right repo, inspect a route, change the code, build, solve a conflict, push, and verify production.

That is a qualitative shift.

At the same time, I have seen models:

declare victory after only pushing, even though deployment failed
read the right code but work in the wrong worktree
confuse an uploaded iOS build with a signed TestFlight build
write correct code against an API that does not exist in the installed version
use billions of cached tokens without noticing something obvious that a human sees in the interface

The last step is still the most expensive: proving that the result exists in the right place and works for a real user.

A code agent stopped by verification before production
A code agent stopped by verification before production

What we still lack

Better automatic model routing

I do not want to choose model names and reasoning levels for every subtask. The system should send architecture review to the model that is best at the whole picture, mechanical changes to a faster model, and final verification to a separate checker.

Portable working memory

Context is still stuck inside a specific client, model, or session file. Skills and MCP reduce the pain, but an agent should be able to switch models without losing the project’s proven way of working.

Verification as a first-class feature

Most demo agents reward code production. I want to measure the share of tasks that end in verified correct external state: live route, database row, installed app, sent message, or approved build.

Clearer cost

Cached tokens are cheaper and sometimes reported differently, but the user often only sees a bar that disappears fast. The agent should be able to say: this task used X new input tokens, Y cache reads, Z output tokens, and created the following verified result.

My recommendation: build the system before the super-prompt

Start with a narrow task that can be verified. Give the agent a small set of tools, write a skill for the workflow, and define what counts as done. Then add memory and more tools when you see a recurring need.

A useful code agent does not need free access to everything. It needs the right access, the right order, and a stop rule.

Recommended reading

I now use Fable and OpenAI models less like oracles and more like components. Fable can review a hard design. GPT-5.6 Sol, Terra, and Luna can be split by work profile, and GPT-5.6 can drive a long tool flow. A smaller model can translate or classify. MCP connects them to real systems. Skills give Codex a reusable way of working. Git and tests decide whether the result can move forward.

21.54 billion tokens later, the biggest improvement is not that the models write prettier code. They can stay in the work longer. Our job is to build guardrails, memory, and verification that make that time worth something.

FAQ

Why does 21.54 billion tokens not equal 21.54 billion new words?+
Because agent sessions reuse large contexts, read cached material, and revisit the same code and instructions multiple times. The token count shows activity, not readable prose.
What does the high-water method mean in this article?+
For each physical Codex rollout, I counted only increases above the previous highest observed `total_token_usage.total_tokens` value. Unchanged values and decreases counted as zero.
What is the main missing piece in code agents right now?+
I see the biggest gap in verification, routing, and portable working memory. Models are stronger, but the surrounding system still decides whether the result is reliable.

Recommended for you

MCP Developer Workflows: The Real Control Layer

MCP Developer Workflows: The Real Control Layer

MCP developer workflows are the control layer for production agents: scoped tools, approval gates, source-backed context, and replayable actions.

8 min read
OpenAI GPT-5.5 Coding Model: Codex Test

OpenAI GPT-5.5 Coding Model: Codex Test

I tested the OpenAI GPT-5.5 coding model in Codex. It makes more targeted fixes, changes less unrelated code, and often solves issues in one prompt.

10 min read
OpenAI GPT-5.6: What Sol, Terra, and Luna Mean for Real AI Work

OpenAI GPT-5.6: What Sol, Terra, and Luna Mean for Real AI Work

OpenAI's rumored Thursday launch looks like GPT-5.6 Sol, Terra, and Luna. Here is what changes and how I would route them in real agent systems.

7 min read