Chatbot and agent
-
Chatbot
- Takes your message and returns text
- You still check its answer against the official website
- What happens next is up to you
-
Agent
- Is given a goal
- Takes actions using tools: search, open a file, calculate, fill a form, send an email
- A language model chooses the next step; ordinary software carries out each action
The agent loop
- Plan The model breaks the goal into steps.
- Act It asks for a tool to be run.
- Observe The tool's result is added to what the model can see.
- Repeat or stop It picks the next step, until the goal is met, a step limit is reached or it needs a person.
Then back to step 1: Plan
| Feature | Fixed script | AI agent |
|---|---|---|
| Who decides the steps | The programmer, in advance | The model, while running |
| Same input, same result? | Yes, every time | Not guaranteed |
| Unexpected layout or wording | Stops or makes an error | Often copes, but may guess wrongly |
| Testing and audit | Easy | Harder; needs logs and checks |
| Best for | Repetitive, fully defined jobs | Varied jobs that need reading or judgement |
A chatbot answers; an agent acts. The agent loop: goal -> plan -> act with a tool -> observe -> repeat or stop.
Key takeaways: an agent pursues a goal by calling tools and deciding each next step from what it observes. A fixed script is better when the steps are fully known; an agent helps only where reading or judgement is needed. Agents still struggle with long chains, admitting failure, facts and vague goals, so their output is checked and a person stays responsible.