Youdunit: Single-Call Counterfactual Necessity in Multi-Agent LLM Systems
Marissa Li, Stephanie Gao, Kenny Guo, Xingjian Li, William Chang, Goran Radanovic
NeurIPS page · Open on the map
Category: AI Safety, Security & Alignment › Multi-Agent Security Evaluation · Type: new method · Keywords: counterfactual necessity, multi-agent LLM systems, causal attribution, Gumbel-Max tape, agentic AI safety
Areas: AI Agents › Agent Robustness › Agent Security Benchmarks; Safety & Security › Language Model Security › LLM Agent Security; Evaluation & Benchmarks › Language Model and Agent Safety › Multi-Agent Attack Detection
Summary
Youdunit is a single-call counterfactual necessity test for multi-agent LLM systems that identifies which specific agent communication caused harmful outcomes using a Gumbel-Max tape.
Explained to a 5-year-old
In a group of talking bots, sometimes they say something that hurts people. We want to know which single chat message caused the bad result. To find out, we write down the random choices the bots make while they talk normally. Then we let them talk again, copying the random choices but changing one chat at a time. If the bad thing disappears when we change that chat, that chat was the problem.
Explained to a 5-year-old, longer
Imagine a team of robot friends that talk to each other using words. Sometimes they accidentally say something that makes people sad or angry. We want to know which single sentence they said caused the problem. To do this, we watch them talk normally and write down the random things they decide (like which word they pick next). Then we let them talk again, using the same notes, but we change one sentence at a time. If we change a sentence and the bad thing no longer happens, that sentence was the cause. If we change a sentence and the bad thing still happens, that sentence probably wasn't the problem. This way we can find the exact chat that made the trouble. It helps us fix the robot friends so they won't say harmful things again. The method works for many different kinds of robot teams, like planning trips, writing articles, or debating topics. By checking each chat one by one, we can see where the trouble starts and stop it before it spreads.
For a technical reader
The system records random number generator states during a normal conversation and replays them in counterfactual runs, intervening at a single message to test its necessity. This single-call test isolates the causal impact of each communication without running many simulations. It is applied to a benchmark of 148 adversarial scenarios across four multi-agent environments, revealing that decentralized and hierarchical setups have strong causal effects while sequential debate shows little effect. A sanity check confirms zero counterfactual effects when no intervention is made, validating the mechanism.
Problem
Understanding which specific interactions in multi-agent LLM systems cause harmful outcomes is challenging, especially when multiple agents communicate. Existing causal analysis methods often require extensive counterfactual simulations and struggle to pinpoint individual communication events.
Method
The approach records per-token random number generator states during a factual run and replays them in counterfactual runs, intervening at a single communication event to assess its necessity for the harmful outcome. This enables a single-call necessity test that isolates the causal contribution of individual agent messages without requiring multiple simulations.
Results
The approach finds that decentralized and hierarchical multi-agent environments exhibit a meaningful aggregate causal effect, whereas the sequential debate setting shows near-zero causal effect despite similar attack success rates, and a sanity check confirms zero counterfactual effects under identity interventions.
Contributions
It introduces a single-call counterfactual necessity test for multi-agent LLM systems and a Gumbel-Max tape mechanism that enables efficient causal attribution of harmful outcomes to specific communications. It also demonstrates the test on a benchmark of 148 adversarial scenarios, revealing varying causal structures across different agent architectures.
Practical relevance
It helps developers pinpoint which agent communications cause harmful behavior, enabling more focused defenses in deployed multi-agent LLM systems.
Research questions this paper is counted under
This page was written by language models from the title and abstract of each paper, and the answers were checked by two other models. It can be wrong: check the paper itself. Suggest a correction