arXiv · 2611.35727
The Cost of Failure: Quantifying the Downstream Impact of Error Histories in LLM Agents
Abstract
When an action fails, an LLM agent retains the action text and its feedback in the context used for subsequent decisions. We study the downstream impact of this retained content as the Cost of Failure. We define Error Token Density (ETD) as the fraction of an interaction history occupied by execution-failure content. On natural ALFWorld rollouts from Qwen3-8B, success is 40.1% at zero ETD and 6.7% when ETD is at least 40%. Controlled continuations separate this association from the effect of retained failure content: with environment state and remaining action budget fixed, inserting failure turns lowers success by 1.9-3.8 percentage points more than token-matched neutral insertions. Deleting existing failure turns yields complementary gains. Failure-conditioned evaluations across planning, code execution, and visual tool use establish the broader relevance of the problem. These findings motivate training agents to reduce the introduction of execution failures. We test this principle with Tool-Feedback Advantage Shaping (TFAS), which combines separately normalized task-success and trajectory-level execution-validity advantages. Across all six model-environment settings, TFAS improves overall accuracy and achieves the lowest ETD among the compared policies, reducing ETD by 26.5-67.7% relative to outcome-only RL. These measurements connect the intervention to lower failure-context density.
Explore related subjects
Keep this discovery
Explore connections, maps & timelines
Jiahao Wang, Ruichuan An, Xinru Jiang, Sihan Yang, Hao Liang, Bohan Zeng, YiFan Zhang, Aijun Yang, Xiaohua Wang. 2026-11-26. The Cost of Failure: Quantifying the Downstream Impact of Error Histories in LLM Agents. https://arxiv.science/abs/2611.35727
Citations retain the original authors and DOI and include this site’s record URL. If this discovery service contributed to your research, you can also cite arXiv Science by Indiciae: BibTeX · RIS.