What are Tools?
Tools are Python functions that your agent can invoke during a conversation. The LLM analyzes the user’s request, decides which tool to call (if any), and your code executes it. The result is fed back to the LLM so it can respond naturally. This is also known as function calling or tool use.How It Works
- User says “What’s the weather in NYC?”
- LLM decides to call
get_weather("New York, NY") - Your function runs and returns
{"temp": 72} - LLM responds “It’s 72°F in New York City!”
Key Concepts
| Concept | Description |
|---|---|
| @function_tool() | Decorator that marks a method as callable by the LLM |
| ToolRegistry | Discovers and manages all tools on your agent |
| Tool Schemas | Auto-generated from your function’s docstring and type hints |
| Parallel Execution | Run multiple tool calls at once |

