Harness Intelligence Wiki
Public DocsContext Engineering Handoff

Context Engineering Handoff Fragments

Context Engineering Handoff Fragments

Context has half-life. A long agent run starts with useful instructions and evidence, then accumulates rejected guesses, stale assumptions, failed commands, partial plans, obsolete file reads, and emotional weight from whatever happened most recently.


Context rot is when the run still carries facts that were once true enough to be useful, but are now stale. Examples: a test failure already fixed, a file layout that changed during the run, a plan that was superseded, or a repo instruction read before a deeper scoped instruction was found.


Context poisoning is stronger than clutter. It is when wrong or low-quality context keeps influencing later decisions because it remains in the window. A bad hypothesis, a hallucinated constraint, a noisy log excerpt, or an abandoned implementation path can become sticky if the agent keeps seeing it.


Token consumption is not only billing. As the window fills, every new decision competes with more material. The agent must spend attention separating current signals from old signals. The run can become slower, more expensive, and less precise even before it literally runs out of window.


Large windows help a run survive longer. They also make it easier to carry stale material for longer. The useful question is not "can it fit?" The useful question is "should this still shape the next decision?"


Automatic compaction helps, but it is lossy. It compresses the transcript into a story. That story can drop exact commands, uncertainty, provenance, rejected alternatives, or why a decision changed. It can also preserve a poisoned assumption in cleaner language.


Manual handoff is an intentional reset. The agent writes the current objective, decisions, changed files, verification evidence, unresolved questions, and suggested skills into a small handoff artifact. The next session starts with that curated state instead of inheriting the whole sediment of the previous run.


The new handoff skill is small on purpose. It tells the agent to write a continuation document to the OS temp directory, include suggested skills, avoid duplicating existing artifacts, reference source paths or URLs, and redact sensitive information.


Manual handoff is useful when the next step is a different phase, when debugging has produced too much debris, when compaction is about to happen, when a session has crossed many unrelated files, or when a human wants a clean restart without losing traceability.


The handoff should not become another giant archive. It should be the smallest complete operating contract for the next agent: what matters now, what has been proven, what should not be repeated, and where to look for the durable artifacts.

On this page