What is tool calling?
How an AI model uses tools: it asks for a function, your code runs it, and the result goes back.
A language model only produces text. It can't check the weather, query your database, or send an email. On its own, it can only talk.
What it is
Tool calling, also called function calling, fixes that. With your request, you send the model a list of tools: a name, a description, and a schema for the inputs.
How it works
When the model needs one, it doesn't answer in words. It replies with a tool call: the tool's name, and the arguments as JSON. Then your code runs the function. Not the model. You send the result back, and the model picks up from there.
Why it matters
Call, run, return, repeat, until the job is done. That loop is what turns a chatbot into an agent. And MCP is just a standard way to plug those tools in.










