Giving the model tools
A language model by itself produces text. It can describe what a good search query would be, but it can't run one. It can write code that would retrieve a file, but it can't execute it. It can propose a plan with steps, but it can't take the steps.
An agent is a language model that can.
The setup is straightforward: the model is given access to tools. A tool is just a function with a name and a description — "search the web," "run this code," "read this file," "send this email." The model decides when to use a tool and what to pass in. The result comes back into the context window. The model reads it and decides what to do next.
This loop — think, act, observe, decide — is what turns a text generator into something that can accomplish tasks in the world. Not just answer questions about a codebase, but actually debug it. Not just describe what steps to take, but take them.
The tools themselves are ordinary software. What's new is a language model in the loop, deciding when and how to use them.
<!-- TODO: a simple diagram of the agent loop (model → tool call → result → model → ...) would orient the reader quickly -->