Chapter 11 of 36 · ~1 min

Agents

An agent is a model, plus tools, plus instructions, plus state, run inside a control loop. The instructions say what the job is and what the rules are. The tools say what it can do. The state is what it has seen so far. The loop is simple: the model reads the state, decides on an action or a final answer; the action runs; its result is added to the state; the model reads again.

That loop can accomplish multi-step tasks nobody scripted in advance: search, read, search again with better terms, compare, draft, check. It can also wander, repeat itself, or stop too early. What makes an agent useful is less the model than the boundaries placed around the loop.

Exercise

Do it yourself

Give an agent a small research task and a search tool, and watch the sequence of decisions it makes to complete it.

Big question

What separates an agent from a chatbot with a search box?