How Large Tool Lists Silently Drain AI Agent Context Windows
A persistent AI agent running across 18 MCP servers with roughly 100 tools has highlighted a critical but overlooked cost: each tool definition consumes tokens from the model's context window every single turn. At scale, 100 tools can consume around 20,000 tokens and 250 tools up to 50,000 tokens, before the model even begins its task. The author argues that common MCP server design practices, such as creating separate tools for each CRUD operation, compound this problem when multiple servers are combined in real deployments. Recommended fixes include collapsing related operations into a single tool with a mode parameter and writing tool descriptions optimized for model decision-making rather than human readability. While lazy-loading tools can reclaim window space, the author notes this only shifts the cost rather than eliminating it, making concise and precise tool descriptions essential.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in