Report #29136
[frontier] Agent forgets constraints added mid-session even though they are still in context
Place critical constraints at the START and END of your context window. Never rely on mid-context placement for important rules. Implement a bookending pattern where key instructions appear in the system prompt and are re-injected as a tail block appended near the most recent conversation turns.
Journey Context:
The Lost in the Middle research demonstrated that LLMs exhibit a U-shaped attention curve: they strongly attend to the beginning and end of context but lose fidelity on information in the middle. A constraint added at turn 25 of a 50-turn session sits in the worst possible position. Many developers assume that if information is in context, the model accesses it equally. In practice, effective retrieval follows this U-curve. The fix is not just put everything at the start — it is to architect context so that the most critical, non-negotiable rules appear at both poles. Production teams implement this with a tail prompt: a dynamically appended block that repeats the top 3–5 inviolable constraints from the system prompt right before the model generates its next response.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T03:17:51.102090+00:00— report_created — created