AI glossary Models & Architecture
What is tool calling (function calling) in LLMs?
Tool Calling (Function Calling)
← All glossary termsThe ability of a language model to emit a structured request to run a function, API or query, which the host application validates and executes.
Explained
Tool calling, also known as function calling, lets a large language model ask for an action instead of only writing text. The application describes the available tools to the model, each with a name, a description and an input schema. When the model decides a tool is needed, it returns a structured call with arguments; the application validates it, runs the function (an SQL query, an HTTP request, a CRM update) and sends the result back so the model can continue. The model never executes anything itself. Tool calling is what turns a chat model into a copilot or an agent that works with real systems and data.
How tool calling works
- The application sends the model the user's request together with a list of tool definitions.
- The model either answers directly or returns one or more tool calls, each naming a tool and giving arguments that follow its schema.
- The application checks the call, executes it with its own credentials and returns the result to the model.
- The model uses the result to answer, or calls another tool, until the task is done.
That loop of model proposes, application executes, is the basic building block of AI agents.
What it is used for
- Looking up live data the model does not have: stock, order status, account balances, documents.
- Taking actions in business systems: creating tickets, updating records, sending notifications.
- Running precise operations that models do badly on their own, such as calculations or database queries.
- Returning structured output that downstream code can consume reliably.
Keeping it safe and reliable
Every tool is a door into a real system, so design them as you would any API exposed to an untrusted caller. Validate arguments against the schema, give tools the minimum permissions they need, and require human confirmation for actions that are irreversible or costly.
Tool descriptions matter more than they look: models choose tools based on them, so clear names, precise descriptions and few overlapping tools reduce wrong calls. Log every call and its result so failures can be traced and evaluated.
Frequently asked questions
What is the difference between tool calling and function calling?
They are two names for the same capability. Function calling is the term OpenAI popularised; tool calling or tool use is the broader term used by most vendors, which also covers built-in tools such as search or code execution.
Does the LLM execute the function itself?
No. The model only produces a structured request. Your application decides whether to run it, executes it with its own permissions and returns the result to the model.
How is tool calling related to AI agents?
Tool calling is the mechanism agents use to act. An agent is essentially a loop in which the model reasons, calls tools, reads the results and decides the next step until the goal is met.
What is the difference between tool calling and MCP?
Tool calling is the model's ability to request a function. The Model Context Protocol is a standard way to package and expose tools to AI applications, so the same tools can be reused across models and applications.
Which models support tool calling?
Most current commercial and many open-weight large language models support it, usually through a JSON-schema based interface in their API. Reliability varies by model, so test tool selection and argument quality on your own tasks.
Decision guides that use this term
- Build vs buy AI agents: which agents should you own, and which should you rent?
- Agentic AI vs generative chatbots: does your use case need an agent or a good assistant?
- MCP vs custom API integrations: how should your AI agents connect to your systems?
- Agent framework vs custom orchestration: should you adopt a framework or write your own agent loop?
- Reasoning models vs standard LLMs: when is the extra thinking worth paying for?
- Single agent or multi-agent system: how should you architect your workflow?
How to put it to work
Where it shows up at Thinkia
Further reading
Related terms
Sources
- OpenAI · Function calling guide
- Anthropic · Tool use with Claude
- Schick et al. · Toolformer: Language Models Can Teach Themselves to Use Tools (arXiv)
- Google AI for Developers · Function calling with the Gemini API
Updated: 2026-10-21