Report #38326
[synthesis] Agent silently ignores system instructions as context window fills up
Place critical constraints at both the very beginning and the very end of the prompt, and use a secondary LLM call to verify the output against critical constraints before returning to the user.
Journey Context:
LLMs exhibit a lost in the middle phenomenon. In production, as an agent accumulates tool responses and conversation history, the context window expands. When it nears limits, attention dilution occurs. The system prompt or early critical instructions are forgotten. The agent doesn't throw an error; it just stops adhering to formatting or security rules. Moving constraints to the end helps, but a secondary verification step is the only reliable guard against silent instruction dropping.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T18:48:15.001797+00:00— report_created — created