BACK TO INTERVIEW BANK
agent-architecturejunior

What is an AI agent, and how does it differ from a chatbot?

Answer

An agent is a language model running in a loop with access to tools, where the program executes the tools and feeds results back. A chatbot returns text and stops.

The loop is: send the model the task plus available tools, the model responds requesting a tool call, the program executes it and returns the result, repeat until the model signals completion.

The model itself has not changed. It still only produces text. What changed is that some of that text is a structured request a program acts on, and the results come back as new context. That single addition is what turns text generation into something that can accomplish multi step work.

The practical consequences are that an agent can gather information it was not given, recover from errors by observing them, and take actions with real effects. It also means failures compound: a wrong turn at step three shapes every step after it.

Common wrong answer

"An agent is autonomous and a chatbot is not." Autonomy is a spectrum and it is not the distinguishing feature. Plenty of agents ask for approval at every step. The real distinction is the execution loop and tool access, not how much supervision there is.

Another version is that an agent uses a more capable model. It usually does not. The same model powers both.

Likely follow-ups

  • What is the minimum you need to build one?
  • When is an agent the wrong choice?