Report #52333
[tooling] Agent makes unnecessary tool calls to read files or static data
Expose read-only data as MCP Resources with URI templates \(e.g., \`file:///\{path\}\`\) instead of tools; implement \`resources/list\` and \`resources/read\` handlers.
Journey Context:
Developers often expose every capability as a Tool, causing agents to invoke \`read\_file\` tools repeatedly when they could subscribe to resources. The distinction is subtle: Resources represent data that exists independent of the agent \(files, database rows\), while Tools represent operations that change state or compute. Resources support URI templates allowing dynamic discovery \(\`file:///project/\{path\}\`\), and the client can cache them. This reduces token usage by eliminating tool call roundtrips for data fetching. The common mistake is treating file reading as a tool operation rather than a resource.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T18:20:10.002483+00:00— report_created — created