MCP server instructions are silently truncated when multiple servers are configured

Open 💬 3 comments Opened Apr 4, 2026 by freelf

Problem

When multiple MCP servers are configured (e.g., context7 + deepwiki + serena), the MCP server instructions block in the system prompt is silently truncated. The last server's instructions get cut off mid-sentence with no warning.

Reproduction

Configure 3 MCP servers with non-trivial instructions (context7, deepwiki, serena). Capture the raw API request and inspect the system-reminder block containing # MCP Server Instructions.

Observed: The instructions for the last server (serena) are truncated mid-sentence:

use `find_symbol` with name path pattern `Foo/__init__` and `includ… [truncated]

The total MCP instructions block is ~4KB before truncation occurs. The full serena instructions are ~4KB+ on their own, but only ~2KB makes it through because context7 and deepwiki consume the first half of the budget.

Impact

  • Silent data loss: Critical usage instructions for MCP servers are dropped without any warning to the user or the server.
  • Unfair ordering: Servers listed later are more likely to be truncated. The ordering is not user-controllable.
  • Degraded behavior: The model loses important guidance on how to use the truncated server's tools effectively (e.g., advanced query patterns, editing workflows, memory system usage).
  • No workaround for server authors: MCP servers cannot know their instructions are being truncated, and have no way to prioritize which parts to keep.

Expected Behavior

  • MCP server instructions should not be silently truncated, or at minimum a warning should be shown to the user.
  • The budget should be large enough to accommodate multiple servers with reasonable instructions.
  • Ideally, users should be able to configure the instruction length limit.

Environment

  • Claude Code CLI (latest)
  • macOS
  • 3 MCP servers configured: context7, deepwiki, serena

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗