Table of Contents
Fetching ...

Counterfactual-based Agent Influence Ranker for Agentic AI Workflows

Amit Giloni, Chiara Picardi, Roy Betser, Shamik Bose, Aishvariya Priya Rathina Sabapathy, Roman Vainshtein

TL;DR

CAIR introduces a counterfactual-based Agent Influence Ranker to quantify each agent’s influence in Agentic AI Workflows (AAWs) through offline counterfactual perturbations and an online mapping to offline rankings. It employs OC, WC, and an amplification-aware perturbation model to compute a per-agent influence score, enabling fast, inference-time ranking. The authors validate CAIR on the AAW-Zoo dataset, showing superior alignment with ground truth and human judgments compared to baselines, and demonstrate practical benefits by reducing latency in downstream tasks like toxicity guardrails with minimal loss in effectiveness. The work provides a production-ready dataset and tools (AAW-Zoo and AAW-Zoo-Generator), delivering interpretability, security insights, and latency-aware optimization for multi-agent LLM workflows.

Abstract

An Agentic AI Workflow (AAW), also known as an LLM-based multi-agent system, is an autonomous system that assembles several LLM-based agents to work collaboratively towards a shared goal. The high autonomy, widespread adoption, and growing interest in such AAWs highlight the need for a deeper understanding of their operations, from both quality and security aspects. To this day, there are no existing methods to assess the influence of each agent on the AAW's final output. Adopting techniques from related fields is not feasible since existing methods perform only static structural analysis, which is unsuitable for inference time execution. We present Counterfactual-based Agent Influence Ranker (CAIR) - the first method for assessing the influence level of each agent on the AAW's output and determining which agents are the most influential. By performing counterfactual analysis, CAIR provides a task-agnostic analysis that can be used both offline and at inference time. We evaluate CAIR using an AAWs dataset of our creation, containing 30 different use cases with 230 different functionalities. Our evaluation showed that CAIR produces consistent rankings, outperforms baseline methods, and can easily enhance the effectiveness and relevancy of downstream tasks.

Counterfactual-based Agent Influence Ranker for Agentic AI Workflows

TL;DR

CAIR introduces a counterfactual-based Agent Influence Ranker to quantify each agent’s influence in Agentic AI Workflows (AAWs) through offline counterfactual perturbations and an online mapping to offline rankings. It employs OC, WC, and an amplification-aware perturbation model to compute a per-agent influence score, enabling fast, inference-time ranking. The authors validate CAIR on the AAW-Zoo dataset, showing superior alignment with ground truth and human judgments compared to baselines, and demonstrate practical benefits by reducing latency in downstream tasks like toxicity guardrails with minimal loss in effectiveness. The work provides a production-ready dataset and tools (AAW-Zoo and AAW-Zoo-Generator), delivering interpretability, security insights, and latency-aware optimization for multi-agent LLM workflows.

Abstract

An Agentic AI Workflow (AAW), also known as an LLM-based multi-agent system, is an autonomous system that assembles several LLM-based agents to work collaboratively towards a shared goal. The high autonomy, widespread adoption, and growing interest in such AAWs highlight the need for a deeper understanding of their operations, from both quality and security aspects. To this day, there are no existing methods to assess the influence of each agent on the AAW's final output. Adopting techniques from related fields is not feasible since existing methods perform only static structural analysis, which is unsuitable for inference time execution. We present Counterfactual-based Agent Influence Ranker (CAIR) - the first method for assessing the influence level of each agent on the AAW's output and determining which agents are the most influential. By performing counterfactual analysis, CAIR provides a task-agnostic analysis that can be used both offline and at inference time. We evaluate CAIR using an AAWs dataset of our creation, containing 30 different use cases with 230 different functionalities. Our evaluation showed that CAIR produces consistent rankings, outperforms baseline methods, and can easily enhance the effectiveness and relevancy of downstream tasks.

Paper Structure

This paper contains 32 sections, 18 equations, 6 figures, 3 tables.

Figures (6)

  • Figure 1: Overview of CAIR phases.
  • Figure 2: CAIR 's offline phase. For each representative query, CAIR creates counterfactual agents' outputs for each agent. The influence score is calculated based on the resulting changes via the amplification factor (AF), agent output change (AOC), final output change (FOC), complete output change (OC), and workflow change (WC).
  • Figure 3: Proximity of input queries and representative queries when using CAIR in online settings in the gift suggester sequential use case .
  • Figure 4: Results of added latency in seconds when using guardrails in three settings: applying guardrails on all LLM calls, applying only on CAIR critical agents, and applying on CFI critical agents.
  • Figure 5: Average results of CAIR 's (a) ablation studies, (b) $\alpha$ and $\beta$ sensitivity analysis, and (c) CAIR sensitivity to representative query set size performed on 20 queries of functionality one in the gift recommender use case.
  • ...and 1 more figures