CUADebug: Diagnosing and Repairing Computer-Use Agent Failures

Weijia Zhang, Kunlun Zhu, Zeyi Liu, Yinting Chen, Tianyi Ma, Jiateng Liu, Jiaxun Zhang, Bingxuan Li, Xiangru Tang, Heng Ji, Jiaxuan YouarXiv 2026

TL;DR

When computer-use agents (CUAs) fail, the final broken screen is often just a downstream symptom of a mistake made many steps earlier. This paper introduces CUADebug, a framework that uses a ReAct-style debugger agent to trace back through execution histories, pinpoint the exact root cause of a failure, and provide a "repair recipe" that significantly boosts task recovery during re-execution.

What Problem Does This Paper Address?

Computer-Use Agents (CUAs) automate tasks by interacting directly with graphical user interfaces (GUIs) via screenshots, mouse clicks, and keystrokes. However, evaluating them is currently a binary game: did they succeed or fail?

When they fail, looking at the final state is rarely enough to diagnose the issue. An agent might hallucinate a piece of data at step 6, propagate that false belief across multiple applications, and finally fail at step 12. Inspecting step 12 won't tell you how to fix the agent; you need to find the root cause at step 6. This temporal gap between the root cause and the observed failure makes debugging CUAs incredibly difficult.

Figure 1: Why CUA failures require root-cause diagnosis rather than terminal-state inspection.

Methods

The authors present CUADebugger, an automated, ReAct-style debugging agent designed for Root Cause Analysis (RCA). Instead of trying to digest an entire multi-step multimodal trajectory in a single pass, CUADebugger uses specific tools to actively inspect the trajectory:

  • Multimodal step-inspection tool (get_step_details): Allows the debugger to look at paired before/after screenshots, low-level actions, and model reasoning for any specific step.
  • Structured root-cause submission tool (finish): Forces the debugger to output a structured record containing the exact root-cause step, a fine-grained taxonomy label, grounded evidence, and a concrete correction strategy.
  • Episodic Memory: An optional retrieval-augmented debugging loop where the agent can recall distilled lessons from prior failures to help diagnose the current trajectory.

Once the root cause is localized, CUADebugger generates a "repair recipe" used to guide re-rollout (re-execution) from the step right before the failure occurred, giving the agent a chance to correct its behavior.

Figure 2: CUADebugger inspects failed trajectories, produces structured RCA, retrieves relevant memories, and guides re-rollout.

Datasets

The paper introduces CUAErrorBench, a newly curated benchmark consisting of 204 failed trajectories from the OSWorld environment. These trajectories were generated by three different agent backbones: Claude 4.5 Sonnet, Gemini 2.5 Pro, and Qwen 3.5. Human experts meticulously annotated each trajectory with the ground-truth root-cause step, a two-level taxonomy label (5 main categories, 30 subtypes), supporting evidence, and a corrective strategy.

Figure 3: CUAErrorBench annotation distribution by trajectory source.

Key Insights and Ideas

  • Reasoning is the Real Culprit: Contrary to what one might expect with visual agents, the majority of failures (53.9%) stem from Task Reasoning and Control errors (e.g., ignoring constraints, making impossible plans) rather than pure visual perception or low-level grounding issues.
  • The Temporal Gap is Real: Terminal symptoms are highly deceptive. Pinpointing the exact step where an agent's internal belief diverged from reality is crucial for effective recovery.
  • Self-Evolving Taxonomies are Path-Dependent: The authors tried letting an LLM dynamically create its own error taxonomy from scratch. They discovered that the resulting taxonomies varied wildly depending on the order in which the failures were presented, proving the necessity of a stable, human-annotated baseline taxonomy.

Key Results

  • RCA Accuracy: CUADebugger significantly outperforms a naive prompt-only baseline. For instance, using a Gemini 2.5 Pro debugger backbone on Claude trajectories, the "Tag+Step Exact" accuracy (matching both the exact failure subtype and the exact root-cause step) rose from 11.1% to 19.4%.
  • Failure Recovery: Providing the agent with CUADebugger's structured diagnosis during a single re-execution boosted the failure recovery rate from 13.89% (history-only baseline) to 29.86%.
  • Continual Re-execution: In a continual execution setting (continuing from step 51 after a 50-step failure), CUADebugger achieved a 25.69% task success rate, approaching the human-oracle guidance performance of 29.17%.
Figure 4: Category-level RCA F1 for the CUADebugger trial using Gemini 2.5 Pro as the debugger on Claude 4.5 Sonnet trajectories (144-task split), including the Others (O) category.

Limitations and Future Work

  • Backbone Dependency: The success of CUADebugger heavily relies on the strength of its underlying LLM backbone. Stronger models successfully translate tool-derived evidence into accurate diagnoses, whereas weaker models show limited gains.
  • Evaluation Scope: The framework and benchmark are currently limited to the OSWorld environment. Future work should test CUADebug on other computer-use benchmarks.
  • Evaluation Setup: The single re-rollout experiments represent a "package comparison" (varying multiple prompt and state factors simultaneously) rather than a perfectly isolated ablation of diagnosis quality. Matched re-rollout ablations are needed to test how subtype prediction and exact root-step localization independently affect behavioral repair.

Summary updated

BibTeX
@misc{zhang2026cuadebug,
  author = {Weijia Zhang and Kunlun Zhu and Zeyi Liu and Yinting Chen and Tianyi Ma and Jiateng Liu and Jiaxun Zhang and Bingxuan Li and Xiangru Tang and Heng Ji and Jiaxuan You},
  title = {{CUADebug: Diagnosing and Repairing Computer-Use Agent Failures}},
  year = {2026},
  eprint = {2608.02643},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2608.02643},
}
Figure