Skip to the content

BUILD YOUR FIRST AGENT

A hands-on course for technical beginners. If you can read a little code, you can do this. You will write the agent loop yourself, line by line, in your browser.

Start lesson one

9 MODULES / 25 LESSONS PLUS ONE PROJECT OF YOUR CHOICE / 32 UE (24 HOURS)

By the end you can

  • Explain what a model really does, without hand-waving
  • Make model calls with messages, system prompts and structured output
  • Give a model tools and run what it asks for
  • Write an agent loop with guardrails that stop it burning money
  • Measure whether your agent works with a small eval
0:00/0:43

Narrated by an AI clone of the founder's voice

Who it’s for

  • Career-switchers, analysts, PMs and designers who can read a little code
  • Junior developers who have used AI tools and want to know what is underneath
  • Anyone tired of watching demos and nodding

What you need

  • A browser. The Python runs in the tab.
  • Enough Python to follow a for loop and a dict. A quick check in the first lesson tells you, and Python for Agents covers it if not.
  • No GPU and no maths degree. An API key only for the last step, running your agent at home.

The loop you will write yourself.

Press run. It executes right there in the tab, and the checks light up one by one.

An agent is a loopagent.py

def run_agent(question, max_turns=5):    messages = [user(question)]    for turn in range(max_turns):        reply = ask_model(messages)        messages.append(reply)        if not reply.tool_calls:            return reply.text        for call in reply.tool_calls:            result = run_tool(call)            messages.append(result)    return "Gave up. Ran out of turns."

Console

> run_agent("Do I need a coat in Berlin?")

TURN 1 MODEL ASKS FOR get_weather("Berlin")

TURN 1 TOOL SAYS 4C AND SLEET

TURN 2 MODEL SAYS "YES. THE BIG COAT."

DONE IN 2 TURNS

4 / 4 CHECKS PASS

  • Calls the modelpassed
  • Runs the tool it asked forpassed
  • Returns the final answerpassed
  • Stops by itselfpassed

All lit. Suspicious. Try breaking it.

An agent is a model in a loop.

The model only ever asks. Your code runs the tool, hands back the result and goes round again. That is the entire trick, and you write it yourself.

THINKTOOL CALLRESULTANSWER

Scripted demo

You Do I need a coat in Berlin?

  1. THINK

    No idea. I am a text predictor in a box. There is a tool for this.

  2. TOOL CALL

    get_weather(city="Berlin")

  3. RESULT

    {"temp_c": 4, "sky": "sleet"}

  4. THINK

    Now I know. No more tools needed. Leaving the loop.

  5. ANSWER

    Yes. 4 degrees and sleet. Take the big coat.

The syllabus. Nothing hidden.

Set at 32 UE, teaching units of 45 minutes, so 24 hours. For a real beginner, expect 20 to 28 hours, mostly because the capstone and the project take longer than their estimates. Lesson minutes are estimates. You pick one project, and only that one counts. Optional lessons don't count either. Lessons marked free open without an account. The rest need a free one.

BEFORE YOU START

A two-minute welcome and a quick check that your Python is ready.

  1. Welcome, and a quick Python checkHow the course works, and ten short code-reading questions to see if you are ready.FREE15 MIN

WHAT A MODEL ACTUALLY DOES

Fancy autocomplete, tokens and probabilities.

  1. Meet the modelWhat you are actually talking to.FREE12 MIN
  2. TokensThe units a model reads and you pay for.FREE25 MIN
  3. Guessing the next tokenProbabilities and temperature.FREE30 MIN
  4. Module test: what a model doesEight questions on tokens, cost and temperature.FREE10 MIN

TALKING TO A MODEL

API calls, prompts and getting usable output.

  1. Anatomy of an API callRoles, messages and why models have no memory.30 MIN
  2. Prompts that workTry prompts on a live model and see what changes.30 MIN
  3. Getting JSON outTurn model text into data your code can trust.45 MIN
  4. Module test: talking to a modelEight questions on messages, memory, prompts and JSON.10 MIN

GIVING IT HANDS

How a text predictor ends up doing things.

  1. How a model uses a toolThe model asks. Your code does.30 MIN
  2. Running what it asked forRoute tool calls and handle failure.40 MIN
  3. Module test: giving it handsEight questions on tool definitions and dispatch.10 MIN

THE LOOP

The ten lines that turn a model into an agent.

  1. An agent is a loopWrite the loop yourself.45 MIN
  2. GuardrailsStop it looping forever and burning your money.50 MIN
  3. Does it work, though?Write a small eval instead of guessing.45 MIN
  4. Module test: the loopNine questions on the loop, guardrails and evals.12 MIN

RULES OF THE ROAD

What the EU AI Act asks of an agent, and the code that does it.

  1. What the AI Act asksRisk tiers, why recruiting is high-risk, and the duties that shape your code.25 MIN
  2. Keep a recordLog every run and every tool call, however the run ends.40 MIN
  3. Ask a human firstStop and ask before anything you cannot undo.40 MIN
  4. Module test: rules of the roadEight questions on the law and the code.12 MIN

SHIP IT

Put it together and find out what to learn next.

  1. Capstone: the research deskBuild a complete agent with tools, guardrails, an audit log, a human approval step and an eval.150 MIN
  2. The toolboxModels, frameworks, MCP and coding agents, and when each one matters.15 MIN
  3. Take it homeOptional: run your research desk on your own computer against a real model. Needs an API key with a little credit.OPTIONAL60 MIN

YOUR JOB, YOUR AGENT

Build a second agent for a real job. Pick one.

  1. The recruiting deskScreen CVs against a job ad, with a human making every decision.180 MIN
  2. The operations deskCheck stock and suppliers, draft purchase orders, and spend nothing without a yes.150 MIN
  3. The support deskTriage tickets, look up orders and draft replies, with refunds behind approval.150 MIN
  4. Bring your own jobSame engine, your problem: your data, your tools, your eval.240 MIN

MAKE IT COUNT

Cost it, ship it to GitHub and take the final test.

  1. The business caseCost per task, monthly cost, time saved and break-even from your own token counts, at half and double the volume.70 MIN
  2. Your portfolioTurn your second project into a GitHub repository with a spec and a two-minute demo.90 MIN
  3. Final testFifteen questions across the whole course. Your score goes on the certificate.20 MIN

Lesson one takes 15 minutes.

Start lesson one