Why it matters
Tools are what let agents do things. Well-designed tools enable powerful agents; poor ones frustrate.
Advertisement
The architecture
Function tool: decorate function; type hints + docstring become schema.
Class-based tool: for stateful tools or complex config.
Advertisement
How it works end to end
ToolContext: injected into tools; access session state, artifacts.
Async tools: agents can call async functions natively.
Long-running tools: LongRunningFunctionTool for tools taking minutes.
Built-in tools: web search, code execution, RAG search included.