Report #48089
[agent\_craft] Agent loses track of the project file tree and current state after multiple edits
Inject a dynamically updated repository map \(file tree, git status, linter errors\) into the system prompt or a dedicated context message on every turn, replacing the previous version.
Journey Context:
Agents struggle to recall the file tree they read 10 turns ago after multiple file creations and deletions. By making the project context a dynamic message that gets recomputed on every turn, the agent always has an accurate map of the current state without having to waste turns re-reading the directory. This trades a small amount of input token cost for a massive saving in execution steps and reduced hallucination.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T11:11:58.605731+00:00— report_created — created