Loading source
Pulling the file list, source metadata, and syntax-aware rendering for this listing.
Source from repo
Deploy, evaluate, and manage AI agents end-to-end on Microsoft Azure AI Foundry
Files
Skill
Size
Entrypoint
Format
Open file
Syntax-highlighted preview of this file as included in the skill package.
foundry-agent/create/references/tool-tool-search.md
1# Tool — Tool Search (preview)23For toolboxes containing many tools, replace the full tool list passed to the model with two meta-tools — `tool_search` (natural-language discovery, returns matching tools per query) and `call_tool` (invoke any discovered tool by name) — so context cost stays flat regardless of toolbox size.45## Toolbox shape67```json8{ "type": "toolbox_search_preview" }9```1011## Behavior1213- `toolbox_search_preview` is a **configuration directive** — it doesn't appear in `tools/list` itself and doesn't count toward the unnamed-tool-per-type limit.14- All other toolbox tools are **hidden** from the initial `tools/list` and are returned only by `tool_search` calls (or by per-user auto-pinning of hot tools).15- Pin specific tools or add search-only keywords via `tool_configs.{tool_name}`:1617```json18{19"type": "mcp",20"server_label": "analytics",21"server_url": "https://db-mcp.internal/sse",22"tool_configs": {23"execute_query": { "pin": true, "additional_search_text": "SQL analytics reporting dashboard" },24"*": { "additional_search_text": "data warehouse queries" }25}26}27```2829Use `"*"` as the key to apply settings to all tools in that entry.30- `additional_search_text` is used only for search ranking — it's never exposed to the model in the tool schema.31- Tool **descriptions drive match quality**: every MCP tool should have a clear `description`, or `tool_search` won't find it.32- Recommendation: add an instruction in the system prompt telling the model to call `tool_search` when a needed capability isn't in its current tool list.3334## References3536For full fields, pinning recipes, the verify-with-`tool_search` flow, and best practices, see [Tool Search tool documentation](https://learn.microsoft.com/azure/foundry/agents/how-to/tools/tool-search).3738- [agent-tools.md](agent-tools.md) — tool index39- [use-toolbox-in-hosted-agent.md § Recommendation: enable Tool Search](use-toolbox-in-hosted-agent.md#-recommendation-enable-tool-search)40