Google previews Tool Retrieval for large Gemini API tool libraries

Google has launched Tool Retrieval in preview in the Gemini Interactions API, allowing agents to load tool parameter schemas only when they are needed. The feature is designed to reduce input tokens, latency and tool-selection problems as developers connect agents to larger tool libraries.
- Tool Retrieval is in preview in the Gemini Interactions API.
- Agents can defer tool parameter schemas until they are needed.
- The feature supports server-side and client-side retrieval.
- There is no separate Tool Retrieval charge.
- It works with Gemini 3.6 and later models, including all Gemini 4 models.
Loading tools only when required
Agents connected to dozens or hundreds of tools can incur additional input tokens and latency when every tool's full parameter schema is included in each request. Google says that a growing list of candidate tools can also reduce tool-selection accuracy.
Tool Retrieval keeps the full library on standby. The model continues to see the name and description of each deferred tool, while its parameter schema remains outside the context until the model requests that tool. The API then loads the schema and the model makes the function call within the same request.
Developers enable the feature by adding a tool_search tool and setting defer_loading: true on tools they want to hold back. Frequently used tools can remain loaded in advance, while less frequently used tools are deferred.
Server-side and client-side retrieval
Google handles the search on the server, so developers do not need to build or host an index for the standard setup. The search, returned schema and function call appear in interaction.steps, which Google says can help developers inspect the tools considered while debugging tool names or descriptions.
The feature also supports remote MCP servers in the Gemini API. Developers can set defer_loading: true on an mcp_server tool, causing the tools exposed by that server to load on demand.
Developers with their own tool registry, embedding index or per-user permission filter can instead use client-side retrieval. In that setup, the application performs the lookup, which adds one round trip per search. It also allows applications to expose new tools during a conversation when a user connects an integration.
Pricing and supported models
Google says Tool Retrieval has no separate charge. Input and output tokens are billed at the standard rates for the selected model. Enabling tool_search adds a small fixed block of input tokens, while each schema loaded by the model is billed as input for the rest of the conversation, as it would be if the tool had been declared up front.
The approach saves tokens when the schemas not loaded outweigh the schemas that are loaded, which Google describes as the usual case for large libraries. The company advises developers to measure the effect against their own traffic.
Tool Retrieval works with Gemini 3.6 and later models, including all Gemini 4 models, in the Interactions API. Google says the preview is available for developers to try now.
Google: Introducing Tool Retrieval in the Gemini API


