Tool use (function calling)
Also called function calling, tool calling, tools
When an AI model asks to run a tool, like a search or a calculator, and uses the result in its answer.
Tool use, also called function calling, lets a language model work with external systems. A developer describes the available tools to the model, each with a name, a purpose and the inputs it takes. When the model decides a tool would help, it outputs a structured request, such as get_weather with city set to Paris. The application runs the tool and sends the result back, and the model continues with that information.
The model itself never runs code or reaches the internet directly. It only produces a request; the surrounding software decides whether and how to carry it out. That separation is important for safety: the application can validate inputs, require approval, or refuse certain actions.
Tool use is what turns a chatbot into an assistant that can check live data, do exact calculations, search documents, create calendar events or update a database. It is also the foundation of AI agents, which chain many tool calls together. Protocols such as MCP standardise how tools are described and connected, so the same tool can work across different AI apps.
Example
A user asks, "What will the weather be in Lisbon on Saturday, and should I pack an umbrella?" The model calls a weather tool with the city and date, receives "18°C, 70% chance of rain", and answers that yes, an umbrella is a good idea.
Common mistake
Writing vague tool descriptions. The model chooses tools based only on their names and descriptions, so "search" with no details gets used at the wrong times. Describe exactly what each tool does, when to use it, and what its inputs mean.