The Only Free Edit Is at the End of the Window
An agent loop can append for free, but changing anything earlier breaks the cache and risks the state. So the prompt layout and the compaction policy have to be designed together, and judged by cost and by the decisions that still follow.