Manuscript Offprint

arXiv:2610.18082

Failure Recovery via Belief Updates and World Modeling for Long-Horizon Agents

Xiyang Wu, Zhichao Liu, Shengxin zhang, Zongxia Li, Ming Li, Tianyi Zhou, Dinesh Manocha

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Long-horizon agents often struggle to recover from failures whose causes lie several steps earlier, beyond what local reflection or backtracking can resolve. We introduce BELIEFWEAVER, a framework that combines persistent evidence across attempts with prospective reasoning over repair directions. It maintains a relational belief state over frontiers, attempts, observations, and checkpoints. Execution evidence updates related frontier priorities across attempts and rollback, while diagnostic evidence gates execution. An implicit world model (IWM) evaluates repair hypotheses, predicts progress, and identifies relations among frontiers to guide exploration. We further distill these reasoning components into a 9B student through supervised fine-tuning and on-policy distillation (OPD). Across three terminal-based benchmarks, BELIEFWEAVER improves aggregate final score by 5.1 percentage points over native Terminus-2 continuation, with positive trends in exploration efficiency. The distilled 9B student improves final score by 9.8 percentage points over the reported native baseline while reducing estimated teacher API cost by 54.8% relative to the matched teacher. These results show that persistent evidence and prospective reasoning can improve recovery in long-horizon agent tasks while substantially reducing reliance on teacher-model inference.

1 Introduction

Long-horizon agents tackle tasks such as autonomous research (Yamada et al., 2025), computer use (Xie et al., 2024), and sequential decision-making (Yao et al., 2022). However, early mistakes can propagate through long trajectories, trapping agents in repetitive attempts or leading to premature commitments that are difficult to reverse (Wang et al., 2026; Liu et al., 2026b; Li et al., 2026). The evidence needed to identify these mistakes often emerges only after many subsequent actions. Recovering from such failures requires agents to revisit earlier assumptions in light of new evidence and use what they learn to guide subsequent exploration.

Reflection allows agents to revise their behavior after failures or new evidence (Shinn et al., 2023; Madaan et al., 2023). Recovery may involve backtracking and trying another frontier, a testable hypothesis for repairing the current failure. Existing approaches often organize such alternatives as a tree to support branching and backtracking (Zhu et al., 2026; Chen et al., 2026; Jin et al., 2026). Long-horizon failures, however, can arise from earlier decisions or assumptions shared across branches (Zhuang et al., 2026; Rafi et al., 2026). Although rollback and persistent memory can preserve what happened, recovery still requires deciding how new verifier-grounded evidence should change the priorities of related repair hypotheses. When frontiers share prerequisites or interact across steps, evidence from one attempt can make another direction more or less promising (Zhang et al., 2026d; Liang et al., 2026). This motivates a persistent exploration state that carries evidence across rollback and uses it to reprioritize future exploration.

We represent exploration as a persistent relational state over frontiers, attempts, observations, and checkpoints. Recorded outcomes and candidate relations determine which unary evidence factors update each frontier's priority (Mishra et al., 2024; Cao and Chen, 2026). This lets evidence from one attempt re-rank related alternatives, while diagnostic evidence separately controls execution eligibility. The state is preserved across rollback. Belief updates capture what has been learned, but recovery also requires deciding what to try next. Recent agentic world models (Zuo et al., 2026) use learned dynamics or outcome prediction to guide decisions (Zhou et al., 2024; Zhao et al., 2026). We use an implicit world model (IWM) to evaluate re-

∗^{*}Equal contribution.

pair hypotheses, estimate prospective progress, and infer frontier relations, guiding their generation, refinement, and reconsideration. These repeated assessments can then be distilled into a lightweight student to reduce teacher inference cost (Yang et al., 2026).

In this paper, we introduce BELIEFWEAVER, a framework for long-horizon problem solving that combines a persistent relational exploration state with an implicit world model (IWM). The exploration state tracks frontiers, attempts, observations, and checkpoints, preserving evidence across rollback and using new outcomes to revise related hypotheses. The IWM evaluates repair hypotheses, estimates prospective progress, and infers relations among frontiers to guide what to explore next. Execution outcomes are then added back to the persistent state, so later decisions can build on earlier attempts. Because these assessments are used repeatedly during exploration, we distill them into a lightweight 9B student through supervised fine-tuning (SFT) and on-policy distillation (OPD) (Agarwal et al., 2024), improving task performance while reducing teacher API costs (Jolicoeur-Martineau, 2025). This makes recovery cumulative: failed attempts provide evidence for subsequent exploration rather than simply triggering another retry. Our contributions are:

• We introduce a recovery controller that uses retained execution evidence and relations among repair hypotheses to update frontier priorities. It can reprioritize candidates beyond the latest attempt, while a separate diagnostic gate controls execution eligibility.

• We develop an implicit world model that reasons over repair hypotheses, expected progress, and their relations, and distill this reasoning into a smaller student for efficient execution.

• Across three terminal-based benchmarks, BELIEFWEAVER improves aggregate final score by 5.1 points over native Terminus-2 continuation and also improves exploration efficiency. The distilled 9B student gains 9.8 points over the reported native baseline while reducing estimated teacher API cost by 54.8%.

References (64)