mjdeving
← concepts

Context & Retrieval

Context Rot

The decay of a long session: constraints forgotten, work redone, a task declared done that is not.

Context rot is the quality decay of a long session: the model degrades well before the window is full. It skips a constraint you gave it an hour ago, redoes finished work, or declares an unfinished task done. The mechanism: the window fills with its own history, superseded instructions, spent tool output, abandoned approaches, and attention is finite, so the requirement from turn three is now mid-window, where models read least reliably. It can be in the window and still not reach the answer.

The fix is writing the state out and starting again: what is done, what is next, which constraints still bind, into a clean window. A sub-agent is the same move made mid-task, since the child’s exploration never enters the parent’s window at all.