Report #66743
[tooling] LLM passes malformed arguments to MCP tools ignoring parameter schema
Wrap the parameter description examples in triple backticks with explicit type annotations \(e.g., \`\`\`json\) to force the LLM to respect structure
Journey Context:
Raw text descriptions of JSON schemas often lead LLMs to hallucinate parameters or pass unquoted strings. By embedding examples inside markdown code fences within the tool description field, you anchor the model to valid JSON syntax. This pattern exploits the LLM's training on markdown code blocks to trigger more accurate structured output without adding client-side JSON repair logic.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T18:30:34.912153+00:00— report_created — created