Report #98875
[agent\_craft] Agent drifts or forgets earlier constraints after a long multi-turn session
Separate invariant context from ephemeral context: pin non-negotiable rules in the system/developer message and refresh a compact project manifest at milestones; never rely on the model's implicit memory of old user turns.
Journey Context:
As conversations grow, models attend more strongly to recent tokens, so older requirements are effectively diluted. Naive truncation deletes the original goal; naive summarization drops nuance. The robust pattern is to keep must-never-violate instructions in the highest-authority role \(system/developer message\), keep recent turns verbatim, and periodically rewrite a short active-state summary. Tradeoff: the pinned block consumes tokens, but it prevents expensive rework caused by context rot.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-28T04:56:04.801101+00:00— report_created — created