If you want to cut your AI agent bill, start by finding the unit of work you are paying for twice.
I started with a hypothesis that there was repeated work inside sessions. As a parent, I was looking for the software version of a kid asking are we there yet every thirty seconds. More specifically, I was looking to see if the agents were running the same command, re-reading the same file, things like that.
I audited the last 500 sessions our team ran, and exact repeated tool calls were only about 4% of our Claude Code tool calls. Yes, agents repeat themselves, but the real cost was quieter: agents re-reading context they already had, helper agents loading the same files from scratch, permission checks running as their own hidden call stream, and teams solving the same setup problems across sessions because the previous answer never became durable. All parts you can’t see from the bill.
The bigger takeaway here is that every team using agents needs to get their session data now, before the expensive habits become invisible infrastructure.
The thing I got wrong about repeats
We used tapes to record every agent session as a high-fidelity trace, every tool call, every result, and every token, in the order it happened. Then I was able to export the last 500 sessions and analyze the tool calls. For every tool call, we created a fingerprint from the tool name and arguments. If the same tool was called again later in the same session with the same arguments, I counted it as a repeat, which totaled about 4% of our sessions. That didn’t explain where the money was going. I needed to go beyond that and look at the work the agents were doing, and whether it was necessary.
Read the tail before you cut it
I took a look at one session that made 518 tool calls building a Stripe self-serve flow. 138 of them came after the agent last changed a file. Prorated by call count, that tail cost about $26. Initially, it looked like drift since the work was done and the agent kept going.
In actuality, the agent had deployed the flow to a test environment, clicked through the whole thing, and checked that the data landed. It was double-checking its own work.
This matters because if you decide that tail is waste and cut every call after the last edit, you’ll train your agents to hand you work they never tested. You’ll save $26 today and pay it back the first time a broken checkout ships to customers.
So before you cut a long tail, read it. Counting calls only tells you what an agent did. Reading the session tells you whether the work needed to happen. Only one of those questions saves you money.
Why AI Agent Context Re-Reading Drives Up Your Bill
Every single step an agent takes, it re-reads its whole memory first. Picture a student who, before answering each question on a test, silently re-reads the entire textbook from page one. Re-reading one page is cheap, but re-reading the whole book a few hundred times is not, and that’s most of what a long agent session is doing.
In our most expensive sessions, about two-thirds of the cost was exactly this: the agent re-reading context it already had, over and over, instead of doing new work.
This is what token efficiency actually means: not how often the agent talks, but how many tokens it drags along every time it does.
And it isn’t spread evenly. 70% of our spend lived in 20 sessions out of 500. The typical session cost under two dollars. Averaging cost across all your sessions is like averaging your phone bill across every text you send, when one roaming charge is the whole thing. Don’t audit everything. Audit your biggest sessions and ignore the rest.
The Four Biggest AI Agent Cost Leaks Worth Fixing
Two things reframed this for me. The cost is concentrated in a handful of sessions, and almost none of it is someone prompting badly, it’s the defaults built into the tools.
Long AI Agent Sessions Are Expensive, But Cutting Them Can Cost More
The obvious move is “cut long sessions.” Be careful here. This is the one fix that can cost you more. Cut a session that’s in the middle of one real task and the agent loses the thread, then rebuilds it from scratch, and rebuilding is the expensive part. Keep the notes for the problem you’re solving right now. That’s the work you want to do. The waste is dragging unrelated old context along on every step. So start a fresh session for a genuinely new task, and don’t truncate one that’s mid-task. The enemy isn’t length, it’s carrying context the task doesn’t need.
The Hidden Cost of AI Agent Permission Checks
Before our agents run most tools, a second small model quietly checks “is this allowed?” That’s like a cashier who calls a manager over before every single scan, even for a banana. In my first audit, I could count these but couldn’t price them. The last 500 sessions changed that, because the traces are high-fidelity: every call tagged by kind instead of rolled into one session total. A bill tells you what you spent. A trace like that tells you what you spent it on.
The answer in our sessions: permission checks were one in four of every model call we made, and about $670, roughly 4.5% of the bill. They’re cheap per call, because each one is mostly re-reading text the agent already loaded. The permission-check model was chosen by the harness version, not by how hard the question was, and it was never the cheap one. If you can send that “is this allowed?” question to a smaller, cheaper model that does the same job for less, you can cut the tax without changing the work the agent does. The fix is to make sure the permission-check model is as small and cheap as possible, and that it doesn’t re-read the same context every time.
Why Helper Agents Waste Money Re-Reading the Same Context
Big tasks get split across helper agents. Each helper wakes up with a blank memory, so each one re-reads the same briefing file from scratch. In one session, the same design doc was loaded cold in 23 separate helpers. The fix: hand the helpers what the main agent already read, instead of making each one fetch it again.
Cross-Session Memory: The AI Agent Cost Leak Teams Miss
The clearest avoidable work happened between sessions. One environment set up twice in two days (that was me 🙄). Four separate sessions installing and logging into the same tool in one afternoon. The same workflow rebuilt three times from a pasted prompt, for $120 total. It’s like solving the same crossword every morning because someone threw out last night’s finished grid. At least $44 of that in nine days, and it scales badly. At 500 sessions, one file got re-investigated across 31 different sessions. One of our repos even has a sensible rule: don’t leave planning documents lying around in the codebase. The side effect is that the agent re-derives that plan every time, because we told it to keep the thinking in the conversation, and the conversation ends. It isn’t that the agent forgot, it’s that we never gave it a place to remember.
Run your own audit
Capturing your session data is the start here. Export a week or more of your team’s sessions (tool names, arguments, results, timestamps, model usage) and sort what you find into three piles.
- Inside sessions: exact repeats, identical results, retries, and calls after the last real change.
- Across sessions: repeated setups, repeated investigations, duplicate tickets, workflows rebuilt from the same prompt.
- Around sessions: permission checks, routing calls, evaluators, supervisors, helper agents. Keep the number of calls and the dollars in separate columns until you can trust both.
Then read a sample from every pile, because the count lies on its own. A repeat can be a valid safety check. A long tail can be verification. A tidy-looking session can quietly redo yesterday’s work.
I started this sure the waste was agents repeating themselves inside a session, but the better question turned out to be where does finished work stop being available to the next agent that needs it? The money leaks when an agent re-reads what it already knew, when a helper reloads what another helper already had, and when the team solves the same problem twice because the first answer was never saved.
Token efficiency means making sure finished work does not have to be rediscovered. Find the unit of work you are paying for twice. Record it once, then go read your twenty biggest sessions, because that is where your bill actually lives.
Your agent bill is lying by omission. Get the trace data.
Related reading
From the blog
Start with paper
Turn every session into knowledge at team scale.
