Tool Selection
Tool selection is the agent's decision of which tool to use for the current step — it reads each tool's name and description and matches them to the task, so clear tool design directly drives agent reliability.
Explain like I'm new to AI
An agent usually has several tools available — search, calculator, calendar, code runner, database. For each step it must pick the right one. How? It reads each tool's name and description (which you write) and matches them against what the task needs.
Pick a question:
Chosen: It needs exact arithmetic → calculator.
Because the model decides purely from those descriptions, how you describe a tool is as important as the tool itself. Vague descriptions → wrong choices.
Mental model
Think of a toolbox with labels. If the labels are clear ("cuts wood," "tightens screws"), you grab the right tool instantly. If they're vague or overlapping ("tool A," "tool B"), you fumble. The agent only sees the labels.
How it works
- Each tool is registered with a name, a description, and a parameter schema (via function calling).
- The model compares the current need against all tool descriptions and selects one (or none).
- It fills in the arguments from the context.
- The tool runs; the result comes back as an observation.
Good practice: clear, distinct descriptions, few well-chosen tools rather than dozens, and examples of when to use each in the description.
Real-world example
Ask an agent "What's 15% of last month's revenue?" It shouldn't guess arithmetic — it should pick the calculator (and maybe a database tool for the revenue figure). If two tools both sound like "get data," the model may pick wrong; renaming them get_sales_data and get_support_tickets fixes it instantly.
Technical explanation
Tool selection quality degrades as the number of tools grows and as descriptions overlap — the model has to disambiguate from text alone. Techniques to keep it reliable:
- Minimal, orthogonal tool set — fewer tools with non-overlapping purposes.
- Descriptive names + rich descriptions, including when not to use a tool.
- Tool retrieval / RAG over tools when there are many (retrieve the top-k relevant tools into context rather than listing all).
- Strict parameter schemas so arguments are valid, plus error messages that guide correction.
- Namespacing / grouping (e.g., MCP servers) to organize large tool sets.
Poor tool design is one of the most common causes of flaky agents — it shows up as wrong actions, not model "stupidity."
Common mistakes
Blaming the model when the agent calls the wrong tool. Usually the fix is a clearer tool name and description — the model can only choose from what you wrote.
- Overloading an agent with dozens of similar tools, causing confusion and wrong picks.
- Vague or overlapping descriptions ("gets info") that don't disambiguate.
When to use it
- Any agent with more than one tool — thoughtful tool design is non-optional.
When NOT to use it
- Single-tool or no-tool tasks, where selection is trivial or unnecessary.
Alternatives
- For very large tool sets, retrieve the relevant tools per query instead of exposing all at once.
Quick quiz
Related concepts
- What is ReAct? — ReAct is an agent pattern that interleaves reasoning (Thought) with tool use (Action) and results (Observation), looping until it can answer.
- What is Function Calling (Tool Use)? — Function calling lets an LLM request that your code run a real tool by emitting a structured call, then use the result to answer.
- Tool Abuse and Excessive Agency — If the model can call a powerful tool, injection can try to. Shrink the kit, validate args, and require humans for irreversible actions.
Last reviewed: 2026-09-04 · Written by ByHeart AI · Reviewed by ByHeart AI