Blog › AI agents

What is an AI agent? A plain-English guide

The Questzo team17 November 20263 min read

You have probably heard that AI agents will book your flights, sort your inbox and write your code. Underneath the hype, the idea is simple enough to build yourself, and that is exactly what the Questzo AI Agent track does. This guide explains what an agent is, piece by piece.

The short version

An AI agent is a program that uses an AI model to decide what to do next, then does it, then looks at what happened and decides again. A chatbot answers your message. An agent takes a goal and works on it.

Chatbot vs agent

Ask a chatbot "what is 6 times 7?" and it writes back an answer, which may or may not be right. Give an agent the same question and a calculator, and it can notice that this is a maths question, pick the calculator, run it, and give you 42 every time. The difference is not a smarter model. It is the code around the model.

The four parts of an agent

Put several agents together, each with its own job, and you get a team: a boss that splits the work and a crew that does it. That is Chapter 6.

A tiny agent in Python

Here is a complete tool-using agent. You can paste it into Build and press Run.

import pip, json

def calculator(a, b, op):
    if op == "+":
        return a + b
    if op == "*":
        return a * b
    return a - b

tools = {"calculator": calculator}
reply = json.loads(pip.ask_with_tools("What is 6 times 7?", tools))
if reply["tool"]:
    answer = tools[reply["tool"]](**reply["args"])
    print("The tool says:", answer)
else:
    print(reply["reply"])

Pip reads the question, sees a calculator in the list, and answers with a small piece of JSON: which tool to use and what to give it. Your code does the rest. Real agents work the same way, with a bigger model and more tools.

What agents are bad at

Agents can be confidently wrong, can loop without making progress, and can use a tool in a way you did not expect. That is why good agents have step limits, check their own work, and only get the tools they need. You build each of those safety habits into your bot as you go.

Where to start

If you have never written code, start at Quest 1: it begins with print(). If you already know some Python, skim Chapter 1 and jump to Talk to the Model.

Learn it by building it

Questzo teaches Python by building an AI agent, one pixel quest at a time. The first two chapters are free, with no sign-up.

Start the first quest

Keep reading

Python

Python for total beginners: your first ten lines

Never written a line of code? These ten lines of Python cover the ideas behind almost every program, explained one at a time.

The Questzo team · 17 November 2026 · 2 min read

Inside Questzo

How the Questzo checks work

Every instruction in a Questzo quest has its own check that runs your real Python. Here is exactly what happens when you press Submit.

The Questzo team · 17 November 2026 · 2 min read

Build

Build a tool-using bot in 30 lines

A step-by-step build: give your bot a calculator and a dice roller, let the model pick the right one, and keep chatting until you say bye.

The Questzo team · 17 November 2026 · 2 min read