REFLECT: Intervention-Supported Error Attribution for Silent Failures in LLM Agent Traces

Xiaofeng Lin, Yingxu Wang, Tung Sum Thomas Kwok, Daniel Guo, Sahil Arun Nale, Charles Fleming, Guang Cheng

TL;DR

LLM agents are great at complex tasks but struggle to pinpoint why they fail, especially in "silent failures" where outputs look fine but are wrong. REFLECT introduces a novel method that diagnoses a potential error, tests it with a targeted fix and replay, and uses the outcome of that test to refine the error attribution, achieving state-of-the-art localization accuracy.

What Problem Does This Paper Address?

Large Language Models (LLMs) are increasingly used as agents to perform complex tasks, often involving long sequences of actions (traces). However, when these agents fail, especially in "silent failure" scenarios (where the output looks correct but is semantically wrong), it's incredibly difficult to figure out which specific step in the agent's trace caused the problem. Existing methods either guess at the error step without verifying, or they try to fix the problem without identifying the root cause. This makes it hard to trust LLM agents for critical applications and requires significant human effort to debug. The paper aims to bridge this gap by developing a method that not only identifies the error but also uses the process of fixing it to improve the accuracy of the attribution itself.

Methods

REFLECT proposes a three-stage pipeline for error attribution:

  1. Diagnosis: An LLM auditor analyzes the completed trace and the task input to generate a hypothesis about the earliest "decisive" error step and a suggested correction.
  2. Targeted Replay: The agent's trace is replayed from a point before the hypothesized error. Crucially, this replay is guided by a diagnosis-specific "repair plan" (not just a random retry). This ensures the replay is a targeted test of the hypothesis. This stage adheres to four key requirements: execution grounding (using actual outcomes), prefix-preserving replay (maintaining the correct part of the trace), targeted intervention (using a specific fix), and inference-time computation (doing this on the fly).
  3. Verify & Re-localize: If the targeted replay successfully produces the correct answer, the contrast between the original failed trace and the corrected trace provides strong evidence to refine the attribution. This verified outcome flip is the core novelty, feeding back into the localization process. If the initial hypothesis is wrong, the process can iterate.

Datasets

The paper evaluates REFLECT on four benchmarks:

  • WTQ (WikiTableQuestions): A table-QA dataset.
  • GAIA: A multi-hop reasoning dataset.
  • SWE-bench: A software engineering benchmark for resolving GitHub issues.
  • BBM (BigBenchMistake): A chain-of-thought verification task.

The authors also mention using internal datasets for WTQ and SWE-bench, with human annotations for error localization.

Key Insights and Ideas

  • The "Correction-Attribution Gap": Simply fixing an error (e.g., via retry) doesn't tell you why it failed. REFLECT closes this gap by making the process of correction provide evidence for attribution.
  • Intervention as Evidence: The core idea is that if a targeted intervention fixes the problem, that success is strong evidence that the intervened step was indeed the cause of failure. This is more powerful than just predicting a suspect step.
  • Targeted Replay is Key: Unconstrained retries are less effective. REFLECT's "diagnosis-specific patch" and "repair plan" ensure that the replay is a meaningful test of the error hypothesis, not just random chance.
  • Closing the Loop: The feedback from a successful intervention (the "verified outcome flip") is used to refine the attribution, making the localization more accurate. This iterative refinement is a significant advancement.
  • Actionable Localization: REFLECT provides not just a step number but also the intervention that worked, making the attribution more useful for developers.

Key Results

  • State-of-the-Art Localization: REFLECT achieves the highest exact match (EM) localization accuracy among methods using the same LLM auditor across all four benchmarks.
  • Significant Gains on Structured Tasks: The largest gains are seen on structured tool-use traces (like WTQ and SWE-bench), where the targeted intervention and replay are most effective.
  • Strong Correction-Attribution Coupling: REFLECT shows a substantial difference in explanation quality between corrected and failed traces, indicating its corrections are coupled to genuine understanding, unlike baselines like ICS or Reflexion.
  • Effective Proxy Verification: Even without ground-truth answers (in a "proxy" regime), REFLECT can still provide valuable localization, demonstrating its utility in real-world deployment scenarios.
  • Computational Cost: While REFLECT is more computationally intensive than simple localization baselines, its accuracy gains are achieved without a prohibitive increase in compute compared to some other advanced methods.

Limitations and Future Work

  • Structured Traces: REFLECT is primarily evaluated on structured traces (tool-use, chain-of-thought). Extending it to more unstructured domains remains a challenge.
  • Oracle Dependence: The primary evaluation relies on having the correct answer (oracle access). While a plan-anchored proxy verifier is proposed for deployment, it's noted as weaker.
  • Re-execution Feasibility: The method requires re-executing agent traces, which might not be feasible in all environments (e.g., due to irreversible side effects).
  • Single Error Focus: REFLECT localizes a single "earliest decisive error." Traces with multiple independent errors or distributed failures might require extensions.
  • Ethical Considerations: The authors acknowledge that automated attribution could be misused to assign blame, emphasizing that REFLECT should be a diagnostic aid for human review.

Future work could focus on improving verification for unstructured domains, handling multi-error scenarios, and exploring more robust re-execution mechanisms.

Summary updated

BibTeX
@inproceedings{lin2026reflect,
  author = {Xiaofeng Lin and Yingxu Wang and Tung Sum Thomas Kwok and Daniel Guo and Sahil Arun Nale and Charles Fleming and Guang Cheng},
  title = {{REFLECT: Intervention-Supported Error Attribution for Silent Failures in LLM Agent Traces}},
  booktitle = {FAGEN @ ICML},
  year = {2026},
  url = {https://openreview.net/forum?id=UrTBgAh9k3},
}
Figure