Tool Use
Tool use is the capability that lets an AI model reach outside its own weights to interact with external systems—search engines, calculators, code interpreters, REST APIs, or databases—and incorporate the results into its response. Rather than relying solely on knowledge frozen at training time, the model can issue a structured call, receive fresh data, and reason over it before replying. This transforms an LLM from a static text generator into an active agent that can browse the web, run computations, and trigger real-world workflows.
Think of it like a skilled analyst who keeps a desk full of specialist tools: when asked a question about today's stock price, the analyst doesn't guess—they pick up a terminal, query the exchange, and then explain what they found. The model's reasoning is still central; the tools just extend its reach.
// OpenAI-style tool definition
{
"name": "get_weather",
"description": "Get current weather for a city",
"parameters": {
"type": "object",
"properties": { "city": { "type": "string" } },
"required": ["city"]
}
}
The model emits a JSON call, your code executes it, and the result is injected back into the conversation so the model can formulate its final answer.
Tool use is closely related to RAG (which retrieves documents rather than calling live APIs) and Prompt Engineering (crafting system prompts that explain available tools clearly). It is also a building block for Chain of Thought reasoning chains where each step may invoke a different tool.
You'll encounter tool use whenever you build autonomous agents, customer-support bots that need live order data, or coding assistants that must execute code to verify their answers.
Related Courses
Go beyond basics with advanced prompting techniques including chain-of-thought reasoning, structured outputs, tool use, and systematic prompt optimization for…
AI Agents & Automation: Build Intelligent WorkflowsUnderstand AI agents, tool use, function calling, and RAG. Learn to build intelligent automation workflows that connect AI to real-world tools and your own…
AI Agents: Building Autonomous SystemsDesign and build autonomous AI agents — tool use, planning, multi-agent architectures, human-in-the-loop patterns, and production deployment.