The Six-Hour Drift Problem - How Long Gaps Kill Agent Session Context
The Six-Hour Drift Problem
Six-hour gaps are where your AI agent loses the most context. Not the beginning of the last session - that is usually well-documented in commit messages and task descriptions. Not the end - that is fresh enough to reconstruct. The middle is what disappears.
Why the Middle Dies First
When you step away for six hours and come back, the agent starts a new session with whatever context files exist. It reads CLAUDE.md, checks git log, maybe scans recent files. But the reasoning chain from the middle of the previous session - why you chose approach A over approach B, the dead ends you explored, the half-formed ideas - none of that survives.
This is the same problem humans have. You leave work at 3pm with a clear mental model. You come back the next morning and the edges have blurred. The beginning is anchored by your initial notes. The end is anchored by recency. The middle floats away.
How to Fix the Drift
The solution is explicit mid-session checkpoints. Every 45 minutes to an hour, write a brief summary of where you are, what you have tried, and what you are considering next. Store these in a running log file that persists between sessions.
Structure your checkpoints like this:
- Current state: What is working right now
- Dead ends: What you tried and rejected, and why
- Open questions: What you have not decided yet
- Next steps: Where you would pick up if interrupted
The key insight is that dead ends matter more than successes. Your agent can rediscover what worked by reading the code. It cannot rediscover what you already ruled out without explicit notes.
Make It Automatic
Build checkpoint generation into your workflow. Set a timer. Use a pre-commit hook that appends session state to a log. The format matters less than the habit.
Six-hour drift is not a technology problem. It is a documentation problem. And it is solvable today with nothing more than structured note-taking.
Fazm is an open source macOS AI agent. Open source on GitHub.