Report #14258
[agent\_craft] Agent loops on failed approaches due to episodic memory rot
Implement a reflection and eviction step. When a trajectory fails, summarize \*why\* it failed as a short declarative rule \(e.g., 'Do not use library X for Y'\), evict the raw trajectory, and inject the rule into the system prompt.
Journey Context:
Raw trajectory history is highly token-inefficient and introduces bias—models tend to repeat patterns present in the context, even if they failed. Converting failure into a declarative rule breaks the loop and saves tokens, turning a lengthy failure trace into a compact, actionable constraint.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T21:09:48.322629+00:00— report_created — created