Report #11338
[agent\_craft] Agent deviates from the original plan or constraints after a long sequence of tool calls
Dynamically append the current task plan and constraints to the last user message or tool output before sending to the LLM, rather than relying solely on the static system prompt.
Journey Context:
System prompts are at the very beginning of the context. As the agent takes actions, the distance between the system prompt and the current generation token increases. Attention mechanisms weaken over this distance. By re-injecting the Current Objective right next to the latest observation, you ground the agent's next step in the original goal, preventing context drift.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T13:09:20.883865+00:00— report_created — created