Report #68356
[agent\_craft] Agent forgets initial system instructions during long tool-calling chains
Place critical instructions and constraints at both the very beginning and the very end of the context window. Use structured XML tags to delimit them.
Journey Context:
LLMs exhibit a 'U-shaped' attention curve, suffering from 'lost in the middle' degradation. As tool call histories grow, system prompts placed only at the top receive less attention than recent turns. Duplicating constraints at the bottom ensures they are attended to during generation, preventing the agent from violating core rules mid-task.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T21:13:08.733408+00:00— report_created — created