Skip to content
New: Ask Ideabro — get answers sourced from our entire archive.Try it

Gemini agents can now fetch tools only when needed. Rewrite your tool descriptions

Google's Tool Retrieval preview lets agents defer most tool schemas and search for them on demand, which cuts tokens but makes descriptions matter more.

Ideabro Machine

By Ideabro Machine

Synthetic Correspondent

4 min read 0 reads 0 AI-generated
Gemini agents can now fetch tools only when needed. Rewrite your tool descriptions
Share

Google has put Tool Retrieval into preview in the Gemini API. Instead of sending every tool definition with every request, an agent can now hold most of its tools back and look them up only when a task calls for them. You add one tool_search tool, mark the rest with defer_loading: true, and the model searches the deferred set when it needs something. The same flag works on mcp_server tools, so a large remote MCP server no longer has to be loaded in full. Google announced it on November 19. It works with Gemini 3.6 and later, including the Gemini 4 models, and only through the Interactions API.

The problem it solves

Anyone who has built an agent with more than a few dozen tools knows the trade-off. Each tool comes with a name, a description and a JSON schema. Send all of them on every turn and you pay for those tokens every time, whether the model uses one tool or none. Worse, a long list of similar tools makes the model more likely to pick the wrong one.

Teams have handled this with their own routing layers: a classifier or embedding search that picks a handful of tools before the main call. That works, but it is one more thing to build, tune and debug. Tool Retrieval moves that step inside the API. Coverage of the preview puts the cost of an idle, deferred tool at roughly 26 tokens, compared with the hundreds a full schema can take.

The pattern is not unique to Google. Other model providers have shipped similar on-demand tool search, and the direction is the same everywhere: agents are expected to sit on top of large, shared tool catalogues, most of which go unused on any given turn.

How to set it up

The changes are small, but the constraints matter.

  • Use the Interactions API. The older generateContent method does not support Tool Retrieval, and the feature sits behind the v1beta API version. If your agent still runs on generateContent, this is a migration, not a flag flip.
  • Add exactly one tool_search tool. Only one is allowed per request.
  • Mark tools with defer_loading: true. Keep the few tools your agent uses on almost every turn loaded as normal, and defer the long tail.
  • Check your model. Setting defer_loading on a model older than Gemini 3.6 returns a 400 error, so pin model versions in any fallback logic.
  • Budget as usual. Reports say there is no separate fee; you pay standard input and output rates.

Because the model now finds tools by searching, your tool descriptions do more work than before. A vague description such as "handles customer stuff" was tolerable when the tool was always in view. Under retrieval it may simply never be found. Write descriptions the way you would write a search result: say what the tool does, what it needs and when to use it.

What it means for builders

The obvious win is cost. If your agent ships with a big MCP server, such as a full Workspace, CRM or internal API surface, deferring most of it should cut input tokens on routine turns. It also loosens a design constraint. Teams have been splitting agents into narrow sub-agents partly to keep tool lists short. With retrieval, one agent can reasonably carry a much bigger toolbox.

There are new failure modes to watch, though. A retrieval step can miss. The model may not search when it should, or may surface a near-match instead of the right tool. Those errors are quieter than a schema validation failure, so log which tools were retrieved on each turn and compare against what the task needed. Run your existing evals with and without deferral before you switch production traffic. Pay special attention to rarely used tools that matter a lot when they are used, such as refunds, account deletion or anything that moves money. Those may be worth keeping loaded all the time.

Security teams should note one more thing: a bigger catalogue means more tools an agent could reach. Deferring a tool hides it from the prompt, not from the agent. Permissions still need to live on the tool side.

What to watch next

This is a preview. Google says the API surface may change before general availability and has not given a date, so keep the integration behind a thin wrapper you can adjust. Watch for three things: whether the one-search-tool limit lifts, whether support reaches generateContent or stays tied to the Interactions API, and whether Google publishes accuracy numbers for retrieval on large catalogues. The last one matters most. Saving tokens is only useful if the agent still picks the right tool.

Sources

How this was made AI-generated

AI-generated. Drafted by AI and reviewed by a human editor before publishing.

Researched and written by Ideabro's AI newsroom from the sources listed at the end, and published automatically. Spot an error? Use the contact page and a human editor will correct it.

The brief and the plain-language version on this page are written with AI and reviewed by an editor. The story itself is the source of truth.

Read our AI policy

View as Markdown — for AI agents

Conversation0

Markdown links, **bold** and *italics* work.2000

Comments are reviewed before they appear. Sign in to skip the form.

No comments yet.

Start the conversation — the first reply sets the tone.