ByteCosts
mcp-tool-selection-accuracy.mdx

AI Coding Agents

MCP Tool Selection Accuracy: How Many Tools Is Too Many?

MCP tool selection accuracy measures how often the model chooses an acceptable tool for the task. Start by removing duplicate tools and clarifying when to use each one, then test on-demand loading if the catalog still causes errors or consumes too much context. Measure wrong selections, invalid arguments, and missing required tools separately on the same tasks.

The cost of exposing the catalog is covered in MCP tool definition token cost.

What the evidence shows

The vendor guides give different starting points for configuring a catalog. The benchmarks show how particular combinations of models, tools, and retrieval methods performed.

Anthropic’s tool search documentation states that Claude’s ability to pick the right tool degrades past roughly 30 to 50 available tools. In Anthropic’s own internal MCP evaluations, published in its advanced tool use engineering post, Opus 4 went from 49% to 74% and Opus 4.5 from 79.5% to 88.1% with the Tool Search Tool enabled, which loads only the relevant tools on demand. Anthropic also reports that tool use examples improved accuracy from 72% to 90% on complex parameter handling in internal testing. The search results and parameter results come from separate internal evaluations. The first measures performance with focused tool discovery. The second measures how well the model supplies complex arguments.

As of November 30, 2026, OpenAI’s function calling guide gives a soft target of fewer than 20 functions at the start of a turn and recommends using the system prompt to clarify when each function applies. Anthropic’s range describes an observed drop in Claude’s tool selection accuracy. OpenAI’s target concerns the set you expose initially. Neither guide explains how its number was derived. Use them to choose configurations to test on your own model and catalog.

What the benchmarks measured

Three papers first posted in 2025 measured tool discovery and its effects on task performance.

SourceSetupWhat it measuredHeadline figure
RAG-MCP (arXiv 2505.03275, May 2025)Semantic retrieval picks relevant MCP tools from an external index before the LLM sees themPrompt size and tool selection accuracy with vs. without retrieval43.13% selection accuracy vs. 13.62% baseline, plus over 50% prompt token reduction (authors’ figures)
MCP-Zero (arXiv 2506.01056, June 2025)Agents request tools on demand. A two-stage router matches requests to a dataset of 308 MCP servers and 2,797 toolsTool selection from nearly 3k candidates spanning 248.1k tokens98% token reduction on APIBank while maintaining accuracy (authors’ figures, different benchmark from RAG-MCP)
LiveMCPBench (arXiv 2508.01780, first posted August 2025, revised February 2026)95 daily tasks across 70 MCP servers with 527 tools, evaluated on 12 LLMsEnd-to-end task success and failure classificationClaude-Sonnet-4 reached 78.95% task success, most tested models reached 30 to 50%. Retrieval errors accounted for nearly half of all failures

In LiveMCPBench, retrieval was the largest reported failure category. RAG-MCP reports higher selection accuracy with retrieval. Its 13.62% figure is the authors’ benchmark baseline. MCP-Zero reports accurate discovery from a large catalog and lower token use while maintaining accuracy on APIBank. The results use different tasks and metrics, so there is no shared accuracy curve to apply to your catalog.

Reduce collisions before you reach for retrieval

Start by auditing names and descriptions for overlap.

  1. List tools across all connected MCP servers. A docs server and a ticketing server can each expose a search tool with a different purpose.
  2. Group tools by name similarity and by description overlap. Mark groups where two descriptions could plausibly match the same query.
  3. Remove or disable true duplicates. If two servers expose the same operation, keep the one you actually want called.
  4. Give each remaining tool a distinct name and description. Specify the records it searches and when a sibling tool is appropriate. Claude tool search also matches argument names and descriptions, so use the same domain terms there.
  5. Add input examples where the schema allows them, especially for tools with optional parameters the model often gets wrong. Use an example that includes the parameter and shows the format you expect.

On OpenAI’s side, the function calling guide recommends namespaces, which group related tools by domain such as crm, billing, or shipping. Namespaces are especially useful when the model must choose between similar tools on different systems, like one search tool for a CRM and another for support tickets. For deferred tools, OpenAI recommends detailed function descriptions and concise namespace descriptions. The namespace helps the model choose what to load. The function description helps it call the loaded tool correctly.

If the curated catalog still causes selection errors or consumes too much context, test deferral on the same tasks.

On supported models and platforms, Anthropic’s Messages API lets you mark tool definitions with defer_loading: true and include a tool search tool, either tool_search_tool_regex_20251119 or tool_search_tool_bm25_20251119, in your tools list. Initially only the search tool and any non-deferred tools enter context. When Claude needs another tool, it searches with a regex pattern or a natural-language query, depending on the variant. The API returns inline references and expands the referenced definitions before Claude uses them. Anthropic recommends this path when you have 10 or more tools or when definitions exceed 10k tokens, and suggests keeping your 3 to 5 most-used tools non-deferred so common calls skip the search step. Anthropic favors standard calling when you have fewer than 10 tools, when every tool is used in every request, or when all definitions total under 100 tokens. With its MCP connector, set defer_loading in the mcp_toolset entry’s default_config for the whole server or in configs for individual tools.

Request size, cache breakpoints, and search limits each affect the setup.

  • With definitions supplied directly, defer_loading controls what enters the context window. You still send every tool’s full definition in the tools array on every request. The API keeps deferred definitions out of the initial prompt prefix and expands them when discovered. Savings come from the tokens the model processes.
  • Putting cache_control on a deferred tool returns a 400 error. Put cache breakpoints on non-deferred tools.
  • Each search returns up to 5 matching tools by default (Claude can set limit from 1 to 10,000), and at least one tool, normally the search tool itself, must stay non-deferred, or the request errors.

OpenAI’s equivalent is the tool_search tool, which lets the model search for relevant tools, add them to context, and use them. As of November 30, 2026, it requires gpt-5.4 or later. Functions can also carry "defer_loading": true inside a namespace. Keep the tools that serve common tasks available up front and load the rest when the model requests them. For a reference implementation of a deferred registry, see lazy MCP tool registry, and for pushing tool composition into code rather than the model loop, see programmatic tool calling vs. tool loops.

Choose the initial set using actual tasks. Keep a tool available up front if ordinary requests frequently need it early. Defer a narrowly used tool first, then test a case that explicitly needs it and a case that implies its purpose without naming it. For example, a user asking who owns a reported bug might never say “ticket” or mention the tracker by name. If the relevant tool comes back for exact names but stays hidden for requests like that one, revise the catalog terms and retest. If search finds the tool but the model still picks the wrong one, inspect the tools returned alongside it. Their names or descriptions may remain ambiguous after discovery.

Measure the wrong-tool rate in your own logs

Use a repeatable task set with a mix of tasks that use one server and tasks that require tools from several servers. Keep the prompts and data the same across runs.

  1. Enable telemetry or collect transcripts. In Claude Code, the claude_code.tool_result event has a success attribute and can include an error_type such as Error:ENOENT. If you enable beta tracing, join the result to a claude_code.tool span by tool_use_id to review the call. When reviewing transcripts, capture the task prompt and tool calls together so you can see whether a call that succeeded addressed the original task. For detailed MCP names and parameters, enable OTEL_LOG_TOOL_DETAILS=1 and check what tool arguments your collector will retain. Since Claude Code v2.1.214, built-in Claude Desktop servers report host-authored MCP names on tool decision and result events in Desktop-owned sessions even with the setting off. With OpenTelemetry enabled, Codex CLI emits codex.tool_result with duration, success, and an output snippet.
  2. Label each task’s acceptable tools and valid fallbacks before reviewing the trace. Record wrong tools, invalid arguments on valid tools, and required tools that never load as separate outcomes.
  3. Divide wrong selections by reviewed MCP calls. Also report the share of reviewed tasks where a required tool never loaded. Record the model, the server, and how many tools were initially available.
  4. Replay the same tasks with one change at a time. Keep changes that improve tool selection while preserving or improving task success. Compare input tokens and time to the first useful tool result. A smaller initial catalog can save input while introducing a search step on frequently used paths.

For example, label a request to find the owner of a support ticket as a ticketing lookup. A docs search can return a successful response and still count as a wrong selection. Calling the ticketing tool with a malformed ID counts as an argument error. If deferral leaves the ticketing tool unavailable for the whole task, count a discovery miss even if the trace contains no call to score. A run that tries a docs search and then corrects itself can count as both a wrong selection and a successful task. Tracking both rates shows whether the agent gets the right answer only after extra work. Review permission denials and server failures separately. If the expected tool was available and correctly selected but failed to run, changing the catalog will address a different part of the flow.

Save the expected tool and outcome alongside each task so another reviewer can apply the same labels. If a second route succeeds, decide whether it qualifies as a valid fallback and apply that decision to both runs. Compare the counts as well as the rates. A change that removes unnecessary calls can shrink the denominator, so the percentage alone can obscure how many wrong calls the agent made. For the token side of this comparison, see measure coding agent token savings.

What to do next

Inventory the connected tools, fix ambiguous descriptions, and remove duplicates you can replace with an existing tool. If errors persist after the audit, defer infrequently used tools and replay the baseline before deciding what stays loaded. See lazy MCP tool registry for a deferred registry design and programmatic tool calling vs. tool loops for reducing how many intermediate results the model has to process.

Sources

Interactive report

  • The Tool Tax: Connecting a tool server can make the very next request bigger, even if the agent never calls it. Follow the cost of the catalog, the search, and the results that come back.

How this note was produced

Drafted with AI assistance from committed ByteCosts pricing snapshots and deterministic cost formulas. Figures are grounded in the linked sources (last updated 2026-11-30). Read our editorial & automation policy, inspect the methodology, or report a discrepancy.

MCP Tool Selection Accuracy: How Many Tools Is Too Many?. ByteCosts. Updated 2026-11-30. https://bytecosts.com/blog/mcp-tool-selection-accuracy/

Sources