BACK TO INTERVIEW BANK
tools-mcpsenior

What happens when an agent has too many tools?

Answer

Three problems appear, and they get worse together.

Context cost. Every tool definition sits in the context on every request. Sixty tools with detailed schemas can consume a significant slice of the window before any work begins, and you pay for it on each turn of the loop.

Selection accuracy falls. The model must pick from the list. As it grows, and especially as tools become similar, it picks wrong more often. Two tools that both search something are a reliable source of mistakes.

Overlap breeds ambiguity. Connecting several MCP servers frequently yields multiple tools that could plausibly serve a request. The model has no principled way to choose and will not be consistent.

Ways to scale past it:

  • Remove what you do not use. The highest value action, and usually available. Most setups accumulate servers nobody uses.
  • Consolidate into task shaped tools. One search_codebase beats separate grep, glob, and find tools.
  • Route by phase. Expose only the tools relevant to the current stage of work rather than everything at once.
  • Use subagents. A subagent with its own focused tool set keeps the parent's list small.

There is no universal number. Quality degrades gradually, and it depends on how distinct the tools are. Twenty distinct tools behave better than ten overlapping ones.

Common wrong answer

Assuming a larger context window solves it. It addresses the cost problem partly and does nothing for selection accuracy, which is the more damaging issue. A model choosing between sixty options is making a harder decision regardless of how much room the definitions occupy.

Likely follow-ups

  • How would you scale past that limit?
  • How do you decide what to remove?