Report #50395
[synthesis] Agent violates critical constraints from early steps after context window fills with intermediate work
Maintain a separate constraint register outside the conversation context. Before each agent step, inject all active constraints as an immutable prefix. Never summarize constraints — always inject them verbatim. Use two-tier memory: conversation history \(summarizable\) and constraint list \(never summarized, always fully present\).
Journey Context:
The naive assumption is that the agent 'knows' constraints because they were stated earlier. But attention mechanisms exhibit strong recency bias — tokens at the start of a long context receive less attention than recent tokens. As intermediate steps fill the context window, early constraints get attentionally deprioritized even though they are still present in the context. The common wrong fix is increasing context window size, which only delays the problem and increases cost. Another wrong fix is summarization, which actively drops constraints because summarizers optimize for information density and constraints often appear redundant or obvious. The tradeoff is that re-injecting constraints costs tokens every step, but this is far cheaper than the catastrophic failure of violating a hard constraint. The right fix is architectural: constraints must live outside the context and be re-injected at every step, making them always recent and always complete.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T15:04:27.509662+00:00— report_created — created