Cleaning an Agent's History Hurts When the World Still Holds the Error

Egor Pakhomov, Shafiq Joty, Erik Nijkamp and colleagues at Salesforce AI Research freeze tool-using agents mid-task, edit either the history or the world state, and show that cleaning an agent's history can make it worse when the world still contains the mistake.
Ask this paper
Design. An agent is paused with its exact world state saved. The researchers edit the history or the world and let a receiver model continue, so the only difference between arms is the edit.
Same content, opposite effect. On AgentCE-Bench, after the agent commits a wrong value, adding the correct value as a truthful note beside the preserved error raises recovery from 51% to 66%. Adding the same value as the agent's own completed action lowers recovery from 50% to 44%, below no edit at all.
Receipts versus world. On AppWorld, a success receipt for a database write lowers whole-task success from 45% to 28% when the write's effect is absent, and raises it from 38% to 49% when the effect is present. The 27-point interaction is positive in six of eight receivers at 97.5% confidence.
Practical rule. Compaction, repair and handoff policies should be tested against the actual world state, because a history that looks clean while the error remains in the environment misleads the next agent.
Abstract
Tool-using language-model agents accumulate histories of their own mistakes, and a system that compacts, repairs or hands off such a history decides what it says about those mistakes while their effects stay in the world. Prior work cleans the history at a fixed world, where showing a corrected step and saying it is done move together. We ask whether the same correct content helps or hurts depending on how the history states it and what the world holds. We freeze an agent mid-task with its exact world state, edit the history or the world, and let a receiver model continue. On AgentCE-Bench, after the agent commits a wrong value, we hold the world fixed and add the correct value by two natural edits: a truthful note beside the preserved error or the agent's own completed action. The note raises recovery, the share of remaining targets the receiver gets right, from 51% under a matched neutral note to 66%. The completed action lowers it below the unedited history, from 50% to 44%, so the value's presence alone does not predict the effect. On AppWorld, after a database write, we vary whether its receipt reports success or failure and whether its effect is present. A success receipt lowers whole-task success from 45% to 28% while the effect is absent and raises it from 38% to 49% once present. The two effects differ by 27 points pooled over two receivers, a difference positive in six of eight receivers at 97.5% and seven at 95%. A history edit's effect thus depends on the world it describes, and a history made to look clean while the world still holds the error can leave an agent worse off than no edit at all.