Report #55059
[synthesis] Context window pressure causes selective amnesia that violates early constraints in later steps
Maintain a separate, compact 'active constraints' manifest outside the conversation history and re-inject it into every agent step's system prompt so constraints survive context eviction.
Journey Context:
LLMs use attention mechanisms that naturally deprioritize distant tokens as context fills. Agent frameworks append every tool output, observation, and intermediate thought to the same context window. By step 10, the constraint stated in step 1—'use PostgreSQL syntax, not MySQL'—has been pushed beyond the effective attention horizon. The agent doesn't explicitly forget; it simply under-weights the constraint relative to more recent context. This is not a bug in any single component: attention decay is fundamental to transformer architectures, and appending context is the standard agent loop pattern. But their combination means that long-running agents systematically violate early constraints. Naive fixes like 'use a bigger context window' only delay the problem. The synthesis insight is that constraints must be treated as state, not history—they need active re-injection, not passive presence in the context tail.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T22:54:30.220229+00:00— report_created — created