Everything,
every time.

Why long-running coding agents get so expensive, and how the same work can cost a quarter as much.

The cast

Your agent writes code, runs tests and reads files, all day long.

It doesn't think on its own. For every step it asks a model, and the model bills by the token for everything it reads.

Scroll

Two bills

Two agents. Same job.

Same coding agent and same model, given the same six real coding tasks, back to back in one long session. Both solved the same share of them.

Two bills

One bill is 4.4× the other.

The work was the same and so were the results. So where did the money go?

Every turn

Agents don't remember. They re-read.

A model keeps no memory between requests. So on every turn the agent sends the whole conversation again: the task, every file it opened, every command it ran, every reply.

Every turn

The pile grows. All of it goes back.

Each turn adds a little, the bright tip of each bar. But the bill counts everything that's sent, so you pay again for every old page, every time.

After 8 turns

A 36K-token conversation. 168K tokens billed.

And a real session doesn't stop at 8 turns.

What's in the pile?

Open the last request.

Here's what an agent is actually carrying, twelve messages into a debugging session.

What's in the pile?

Mostly leftovers.

Logs, retries, re-reads and dead ends the agent has already moved past. You pay to send them on every turn, and the model has to wade through them, which makes it worse at its job too.1

A real session

Now stretch it to 398 turns.

The average baseline session from our benchmark: six tasks in one conversation. Each bar is one request, as tall as the context it sends.

The bill

You pay for the area under the curve.

Only the bright rim is new. Everything under it is words the model had already read, sent again: 107,363,349input tokens to finish six tasks.

The square law

Twice as long costs 4.6× as much.

The first 199 turns cost $23.50. All 398 cost $107.29. Every turn re-sends everything before it, so the bill grows with the square of the session.

But caching…

Caching softens it. It doesn't fix it.

Cached input is 90% off, and this run hit the cache 99.2% of the time. But 90% off a mountain is still a mountain.

And then

Past 272K tokens, the price doubles.

Every request over the line is billed 2× for input and 1.5× for output. The average session crosses it at turn 193 and never comes back.

What if your agent only carried
what matters?

A context layer between your agent and the model.

Sleev runs on your machine. Every request passes through it, and it keeps the conversation lean as the session grows.

Nothing else changes

Same agent. Same model. Same keys.

Your provider key goes straight through to the provider; Sleev never stores it. Point your agent at Sleev and keep working.

How a fold works

  1. 1When the context gets heavy, Sleev nudges the agent.
  2. 2The agent flags what it's done with. It did the work, so it knows what's stale.
  3. 3Sleev folds the flagged messages into a short summary, in the background.
  4. 4The next request carries the summary, not the pile.

Compression, not compaction

Small folds, all session long.

Compaction stops the agent and rewrites everything at once, losing detail. Sleev folds small pieces as it goes. Each fold costs one cache rewrite, which pays for itself within two or three turns.

The race

Same six tasks. Run them again.

Once without Sleev, once with. Same agent, same model, same tasks: the average of four runs each.

Turn 1

Both start from the same prompt, and for a while they look alike.

Turn 12

Sleev's first fold: the context drops from 59K to 32K tokens.

Turns 50–180

The baseline keeps everything, so every request gets heavier. Sleev's barely change.

Turn 193

The baseline crosses 272K. From here on, every request costs double.

Turns 260+

Sleev's context never passes 77K tokens. The baseline's heads past 450K.

Turn 338

Sleev finishes all six tasks. The baseline needs another 60 turns.

The result

4.4× cheaper. Same quality.

61.9% of tasks solved with Sleev, 61.1% without.

The gap

The longer the session, the bigger the gap.

On one short task, the pile never gets big, so there's little to fold: Sleev saves 6%. Chain six tasks into one session and it saves 78% per task.2

Where this is going

And agents are only working longer.

Agents take on bigger jobs every month and run for hours. Without Sleev, each turn costs more than the last: by the end of the session, 10× more. With Sleev, a late turn costs about what an early one did.

Same work. Same results. 4.4× less.

Everything, every time.

Only what matters,
every time.

Sleev

A local context layer for your coding agents.

BashPowerShellnpm
$ curl -fsSL https://sleev.ai/install.sh | bash

1 Long-context degradation: Chroma, “Context Rot” (2025); Liu et al., “Lost in the Middle” (2023); Hsieh et al., “RULER” (2024).

2 Batched runs: DeepSWE 1.1, 113 real-repo tasks chained six per session, GPT-5.6 Sol at medium reasoning in Codex CLI, four runs per arm, June 21 – July 2, 2026, average session shown. Costs repriced at OpenAI list rates ($5 / $0.50 / $30 per million input / cached input / output tokens; 2× input and 1.5× output above 272K). Single-task runs used GPT-5.5 at high reasoning, a separate experiment. The baseline wins on cache hit rate (99.2% vs 93.9%) and output tokens.