Context compaction in coding agents creates a silent failure mode that catches many engineers off guard. An empirical study analyzing 2.59 gigabytes of conversation transcripts across 43 compaction events uncovered a massive structural bias in what gets preserved.
While summaries retained roughly 77 percent of prose decisions and rationales, they kept only 9.8 percent of file paths and a staggering 0.2 percent of executed shell commands. Measured numbers and specific error messages suffered an identical fate, dropping almost entirely out of context.
This explains why a coding agent appears to remember architectural intent yet suddenly forgets the exact flags, connection pool parameters, or test invocations from twenty minutes prior. Compaction algorithms naturally optimize for conceptual narrative at the expense of technical state.
If you build agent harnesses or context windows, relying solely on recursive summarization will degrade tool precision. Production harnesses require dedicated secondary stores to persist raw terminal interactions, environment diffs, and exact error payloads alongside conversational summaries.
Context management cannot treat raw execution logs and high-level reasoning as the same data type.












