Table of Contents
Fetching ...

Information Fidelity in Tool-Using LLM Agents: A Martingale Analysis of the Model Context Protocol

Flint Xiaofeng Fan, Cheston Tan, Roger Wattenhofer, Yew-Soon Ong

TL;DR

This work introduces the first theoretical framework for analyzing error accumulation in Model Context Protocol (MCP) agents, proving that cumulative distortion exhibits linear growth and high-probability deviations bounded by $O(\sqrt{T})$.

Abstract

As AI agents powered by large language models (LLMs) increasingly use external tools for high-stakes decisions, a critical reliability question arises: how do errors propagate across sequential tool calls? We introduce the first theoretical framework for analyzing error accumulation in Model Context Protocol (MCP) agents, proving that cumulative distortion exhibits linear growth and high-probability deviations bounded by $O(\sqrt{T})$. This concentration property ensures predictable system behavior and rules out exponential failure modes. We develop a hybrid distortion metric combining discrete fact matching with continuous semantic similarity, then establish martingale concentration bounds on error propagation through sequential tool interactions. Experiments across Qwen2-7B, Llama-3-8B, and Mistral-7B validate our theoretical predictions, showing empirical distortion tracks the linear trend with deviations consistently within $O(\sqrt{T})$ envelopes. Key findings include: semantic weighting reduces distortion by 80\%, and periodic re-grounding approximately every 9 steps suffices for error control. We translate these concentration guarantees into actionable deployment principles for trustworthy agent systems.

Information Fidelity in Tool-Using LLM Agents: A Martingale Analysis of the Model Context Protocol

TL;DR

This work introduces the first theoretical framework for analyzing error accumulation in Model Context Protocol (MCP) agents, proving that cumulative distortion exhibits linear growth and high-probability deviations bounded by .

Abstract

As AI agents powered by large language models (LLMs) increasingly use external tools for high-stakes decisions, a critical reliability question arises: how do errors propagate across sequential tool calls? We introduce the first theoretical framework for analyzing error accumulation in Model Context Protocol (MCP) agents, proving that cumulative distortion exhibits linear growth and high-probability deviations bounded by . This concentration property ensures predictable system behavior and rules out exponential failure modes. We develop a hybrid distortion metric combining discrete fact matching with continuous semantic similarity, then establish martingale concentration bounds on error propagation through sequential tool interactions. Experiments across Qwen2-7B, Llama-3-8B, and Mistral-7B validate our theoretical predictions, showing empirical distortion tracks the linear trend with deviations consistently within envelopes. Key findings include: semantic weighting reduces distortion by 80\%, and periodic re-grounding approximately every 9 steps suffices for error control. We translate these concentration guarantees into actionable deployment principles for trustworthy agent systems.
Paper Structure (64 sections, 6 theorems, 35 equations, 11 figures, 2 tables)

This paper contains 64 sections, 6 theorems, 35 equations, 11 figures, 2 tables.

Key Result

Lemma 1

Let $Z_t = \mathbb{E}[D(T) \mid \mathcal{F}_t]$ be the distortion Doob martingale (Definition def:distortion_martingale). Under Assumptions assump:bounded_branching and assump:decay_structure, we have, almost surely, with If periodic re-grounding enforces a finite horizon $m$, then

Figures (11)

  • Figure 1: MCP standardizes LLM-tool integration through a unified JSON-RPC interface (bottom), replacing custom per-tool connections (top) with centralized schema validation, context management, and uncertainty propagation.
  • Figure 2: Dependency graph for MCP interactions. Solid arrows indicate direct influence $\phi(i,i+1)=\beta$, and the dashed arrow shows long‐range decay $\phi(i,j)=\beta^{j-i}$. This exponential decay structure enables us to prove that distortion deviations remain sublinear, even with adaptive queries.
  • Figure 3: Baseline distortion accumulation over 10 tool calls. Cumulative distortion with $\beta = 0.7$, $\lambda = 0.5$ (50 chains/model). Solid: empirical mean $\pm 1\sigma$; dotted: high-probability envelopes (Theorem \ref{['thm:mcp_concentration']}, 95% confidence). Distortion grows linearly at $\approx 0.5$ per step with deviations tightly concentrated around the linear trend, validating $O(\sqrt{T})$ concentration bounds.
  • Figure 4: Lambda sweep: semantic weighting effect. Distortion for $\lambda \in \{0, 0.25, 0.5, 0.75, 1.0\}$ at $T=30$, $\beta=0.7$ (8 chains/config). Solid: empirical mean $\pm 1\sigma$; dotted: calibrated bounds.
  • Figure 5: Extended chain scaling. Distortion for $\beta \in \{0.5, 0.7, 0.9\}$ at $T=60$, $\lambda=0.5$ (6 chains/config). Solid: mean $\pm 1\sigma$; dotted: calibrated bounds.
  • ...and 6 more figures

Theorems & Definitions (24)

  • Definition 1: Information Filtration
  • Definition 2: Influence Function
  • Definition 3: Ideal Fact Set
  • Definition 4: Cumulative Distortion
  • Definition 5: Effective Branching Factor
  • Remark 1: Modeling framework justification
  • Claim 1: Semantic Sensitivity
  • proof
  • Definition 6: Distortion Martingale
  • Lemma 1: Bounded Doob increments
  • ...and 14 more