Skip to content

Back to the catalog

Closed-World Resolution Against Tool Hallucination in LLM Agents
arxiv.orgpaper

Closed-World Resolution Against Tool Hallucination in LLM Agents

This arXiv paper identifies tool hallucination — LLM agents calling nonexistent tools or passing undeclared arguments — as a structural blind spot that existing tool-selection and tool-gating defenses cannot catch, since a hallucinated call was never a real gating decision. The authors propose a five-class taxonomy (H1-H5) of tool hallucination and a training-free closed-world resolver (the Resolution Rung, based on registry membership plus signature checking) that must run before any causal gate, then extend the analysis to the Model Context Protocol where merging multiple servers into one namespace creates a second hallucination class (M1-M5) from tool collisions and shadowing. Across ten hosted models they measure 322 hallucinations on single-registry tool calls and 154 on a live MCP surface, and release the versioned Hallucinated-Tools Benchmark (HTB) for comparing resolvers.

TL;DR arXiv paper taxonomizes LLM tool hallucination (H1-H5, plus MCP-specific M1-M5) and proposes a training-free closed-world resolver, releasing the Hallucinated-Tools Benchmark (HTB).
Also seen from another angle🧠 AI →
Document

What it is

The Resolution Rung: a training-free, closed-world check (Algorithm 1) that sits before any causal gate in a tool-calling LLM agent pipeline. It is pure registry-membership plus signature validation — no model access, no fine-tuning, no decoder changes.

How it works

Given a call (n, α) against registry R:

  1. Reject if n ∉ R (H1 — nonexistent tool).
  2. Reject if any key in α is not declared in the tool's signature σ(n), or a required key is missing (H2).
  3. Reject if any argument value fails its declared type/enum/range check (H3/H5-detectable).
  4. Otherwise ALLOW.

The paper proves (Prop. 1–2) that placing this check after the causal gate cannot work: the gate's admissibility function reads risk/authorization fields off the tool's contract, which doesn't exist for a fabricated tool, so an undefined lookup can never produce a REJECT under a fail-open executor. A post-gate contract verifier fails for the same reason — no trusted contract to diff against. So the ordering constraint is load-bearing, not stylistic: Resolution Rung → causal gate → contract verifier.

One residue survives by construction: H5 calls where a model borrows tool m's argument shape but the values happen to satisfy tool n's own schema — schema-indistinguishable from a legitimate call, provably undetectable by any closed-world checker (Prop. 4). That case reduces to the tool-selection problem, not resolution.

flowchart LR
    Call --> Rung[Resolution Rung]
    Rung -->|H1/H2/H3 fail| Reject1[REJECT]
    Rung -->|pass| Gate[Causal Gate]
    Gate -->|H4 off-frontier| Reject2[REJECT]
    Gate -->|pass| Verifier[Contract Verifier]
    Verifier --> Exec[Execute]
    Rung -.->|H5 schema-valid residue| Exec

Preconditions / Affected

Applies to any fail-open function-calling executor (the paper's stated default config for unguarded runtimes) and assumes a trusted, honest registry — a compromised registry is explicitly out of scope and left to contract-verification layers. Hallucinations concentrate on unconstrained raw-JSON tool-call surfaces (34 fabricated-tool calls) versus schema-enforced APIs like Bedrock Converse or OpenAI function calling (3), since schema enforcement structurally blocks naming an unlisted tool at generation time.

What to do

Insert the membership-plus-signature check as its own pipeline stage strictly before any causal/least-privilege gate, not folded into the gate or the contract verifier — the paper shows relocating the existence check into the verifier reintroduces the exact unsoundness it fixes. For MCP deployments, use the closed-world MCP variant that resolves to a (server, tool) pair rather than a bare tool name, since namespace merging across servers is what produces collisions and shadowing.

Caveats

Guarantees for H1–H3 rejection and zero honest over-rejection are stated by the authors as construction-consistent restatements of the algorithm's definition, not independent empirical discoveries — only the ordering result (must precede the gate) is non-definitional. The H5 borrowed-argument residue is proven irreducible by any closed-world method, by the paper's own analysis.

Technologies named here

Techniques named here

  • Tool hallucination taxonomy H1-H5
  • Tool hallucination taxonomy M1-M5
  • Fabricated-tool calls on unconstrained raw-JSON surface