Manuscript Offprint

arXiv:2610.20780

ARIA: Runtime Inspection and Amendment for Multi-Agent Systems

Bolin Shen, Yushun Dong

ABSTRACT

In LLM-based multi-agent systems (MAS), a local mistake can propagate as other agents build on it, turning a correctable error into a failed task. Diagnosing completed runs or repeatedly re-executing them to search for corrections does not provide a learned policy for intervening while execution is still in progress. We present Agent Runtime Inspection and Amendment (ARIA), a framework for learning when and how to repair ongoing multi-agent executions. Our key intuition is to turn execution-verified repairs into reusable supervision, moving repair search into data construction and training so that a learned model can intervene at runtime without repeatedly testing alternatives. First, we collect over 24,000 successful and failed trajectories across four multi-agent frameworks, six benchmarks, and eight host models. From these trajectories, we construct the ARIA dataset, to our knowledge the first large-scale dataset pairing failed multi-agent trajectories with execution-verified repairs. It contains 3,953 verified repair pairs, each specifying what went wrong, where to intervene, and how execution should continue. Then, we develop the ARIA framework for MAS-agnostic runtime inspection and amendment, designed to integrate with any MAS that exposes execution trajectories and supports continuation replacement. Using verified repairs as training examples, we teach a compact model to recognize when intervention is needed and how to correct an ongoing run. The aim is to learn repair strategies that apply to related failures in new configurations, rather than merely reproduce individual corrections. Finally, the trained ARIA model demonstrates strong repair performance in both post-hoc and runtime settings, with generalization to unseen frameworks and host models. Our code is available at https://github.com/LabRAI/ARIA.

1 INTRODUCTION

The use of large language models (LLMs) has expanded from text generation and dialogue (Brown et al., 2020; Touvron et al., 2023) to agents that plan, invoke tools, and adapt to feedback (Yao et al., 2023; Schick et al., 2023; Shinn et al., 2023). Multi-agent systems (MAS) organize agents into coordinated workflows with distinct roles, decomposed tasks, and exchanges through messages or shared artifacts (Li et al., 2023; Wu et al., 2023; Chen et al., 2024; Guo et al., 2024). This division of labor combines specialized capabilities with cross-agent critique to refine intermediate reasoning (Du et al., 2024; Liang et al., 2024). Applications include software development, where MetaGPT and ChatDev coordinate design, implementation, and testing (Hong et al., 2024; Qian et al., 2024); scientific experimentation, where Coscientist integrates planning, search, code execution, and laboratory tools (Boiko et al., 2023); medical reasoning with MedAgents and MDAgents (Tang et al., 2024; Kim et al., 2024); interactive social simulation (Park et al., 2023); and general-purpose web and file tasks with Magentic-One (Fourney et al., 2024). However, distributed work creates dependencies through which an incorrect intermediate result may become the premise for another agent's reasoning or the input to a later tool call (Hong et al., 2024; Guo et al., 2024). Misunderstood messages, inconsistent assumptions, or inadequate verification can carry errors across handoffs, turning a local mistake into an execution-level failure (Cemri et al., 2025; Hammond et al., 2025). These dependencies motivate runtime inspection and repair before actions compound a faulty state, rather than relying solely on final-output evaluation.

∗^{*}Corresponding author.

Work on execution reliability addresses three questions: what fails, where it originates, and how successful execution can be restored. Failure taxonomies characterize recurring patterns: the Multi-Agent System Failure Taxonomy (MAST) (Cemri et al., 2025) identifies 14 modes spanning system design, inter-agent misalignment, and task verification, while a complementary analysis (Hammond et al., 2025) examines interaction-level risks from miscoordination, conflict, and collusion. Incident-level diagnosis instead locates the decisions responsible for failed runs. The Who&When benchmark (Zhang et al., 2025) evaluates agent- and step-level failure attribution; AgentRx (Barke et al., 2026) uses constraints derived from task requirements and tool specifications to identify critical failure steps; and ErrorProbe (Li et al., 2026) combines backward tracing with execution-based verification and retains verified error patterns. Repair methods then test whether changing suspected failure points improves outcomes. CausalFlow (Bonagiri et al., 2026) searches for minimal counterfactual edits to single-agent traces, whereas DoVer (Ma et al., 2026) tests message or plan changes in multi-agent systems by re-executing the affected continuation. These works support retrospective diagnosis and repair, but runtime intervention must determine from an incomplete trajectory whether a failure has occurred and how to amend the continuation. Learning this capability from past executions presents three connected challenges. First, reliable supervision must pair a failed trajectory with a well-supported diagnosis and an effective correction: task-level labels do not identify the responsible decisions (Zhang et al., 2025; Barke et al., 2026), and plausible repairs require evidence of restored success. Second, collecting such supervision at scale requires selecting productive sources across MAS frameworks, tasks, and backbone models. Configurations that rarely fail supply few examples, yet frequent failures may still yield few verified repairs when correction is difficult; task accuracy alone therefore cannot identify sources rich in useful failure–repair pairs. Third, incident-specific corrections do not directly specify how to act on unseen, unfinished trajectories. A runtime model must decide whether a prefix warrants intervention and generate an amendment that improves subsequent execution. Together, these challenges call for connecting reliable supervision, repair-aware data collection, and joint learning of runtime inspection and amendment.

To address these challenges, we propose Agent Runtime Inspection and Amendment (ARIA), which couples an execution-verified dataset with a framework for learning when and how to intervene in multi-agent executions. We collect over 24,000 successful and failed trajectories across four MAS frameworks, six benchmarks, and eight host models. To obtain useful supervision efficiently, we introduce a source selection rule based on repair optimality that balances failure frequency with repairability, favoring configurations that yield more verified repairs per execution. We connect failure diagnoses to targeted corrections and retain a pair only when the repaired execution passes benchmark evaluation while its unmodified counterpart fails. This process produces the ARIA dataset of 3,953 verified failure–repair pairs, each recording what went wrong, where to intervene, and how execution should continue. Building on this dataset, the ARIA framework trains a compact model in three stages. First, supervised learning teaches the model to recognize when intervention is needed and to generate repairs from verified examples. Second, preference learning (Rafailov et al., 2023) favors successful repairs over failed continuations and diagnoses that help predict repairs for related incidents. Third, policy optimization uses execution feedback on the model's own proposals to improve repair effectiveness and cross-configuration transfer, while refining intervention decisions to recover failures and limit harmful interventions. The resulting model supports both runtime inspection and amendment and post-hoc repair.

Contributions. Our contributions are threefold:

• A large-scale failure repair dataset. To the best of our knowledge, ARIA is the first large-scale dataset pairing failed multi-agent trajectories with execution-verified repairs. It spans four MAS frameworks, six benchmarks, and eight backbone models, enabling systematic study of failure repair across diverse multi-agent systems.

• A novel MAS-agnostic runtime repair framework. We introduce ARIA, to the best of our knowledge the first MAS-agnostic framework for runtime failure repair. ARIA operates on partial execution trajectories to detect and repair failures without access to the host system's internals, enabling integration into diverse MAS frameworks.

• State-of-the-art repair performance. Our post-training approach equips a compact model with both a gate for runtime error detection and a patching capability for failure repair. Extensive experiments show that even a 7B ARIA model achieves state-of-the-art executed repair accuracy in both runtime and post-hoc settings, outperforming zero-shot frontier models.

References (61)