Compaction is cheaper than the context it removes

When a coding agent’s context fills up, it gets compacted: the history is replaced by a summary and the session continues. Everyone who has watched this happen mid-task has the same instinct — compact as late as possible. The summary loses detail, and compacting throws away the prompt cache you have been paying to build. Better to hold on. Half of that is true. The other half is expensive, and I had the threshold set wrong for weeks because of it. ...

September 9, 2026 · 6 min

A memory that lives in the repository

A coding agent starts every session knowing nothing. You explain the project, it does good work, the session ends, and the next one begins from zero. The usual patch is a longer context window, but that only moves the wall. When the context fills, it gets summarised — and a summary keeps decisions while losing the reasons behind them. “We chose A” survives. “We rejected B because we measured it and it was worse” does not. So the next session proposes B again, and you pay for that experiment twice. ...

September 8, 2026 · 3 min