She writes: a week in Portugal in September, near a beach, under €1,500 — and we’re bringing a toddler
Behind the scenes: classified new_trip → Planning deskFree · 7 modules · 46 lessons
Master AI Agents in Production
We build a travel-planning agency of AI models that survives production, and we explain every choice as we make it, desk by desk.
- 7 modules
- 46 lessons
- $0 price
- 100% on GitHub
No payment, ever — not in the course, not in the product it builds.
What she sees, and what the agency does behind it
One trip in four screens: she asks, it routes to the right desk, the floor orchestrates a parallel search, and it books. By module 5 you will have built every desk on screen.
-
-
The agency replies: Which city are you flying from, and are your dates flexible by a few days?
She writes: Berlin — a few days either side is fine
Behind the scenes: notebook ← budget · month · toddler -
- Explorers · fares Berlin → Faro
- Explorers · Algarve stays, crib filter
- Scouts · brief the coast
- Back office · rehydrate + check prices
14 flights from €176 9 stays from €120 cars from €29 12 tours from €25 -
She writes: the TAP flight, Praia da Rocha, the T-Cross and the kayak tour
Trip booked €1,740- Flights
- Berlin ⇄ Faro · TAP direct
- Stay
- Praia da Rocha · 7 nights · crib
- Car
- VW T-Cross · 7 days
- Tour
- Benagil sea-cave kayak
From one API call to a loop that improves itself
Seven stages down one repository, each running on the code the last one left behind.
- Stage 01 7 lessons
From one call to an agent
Start from a single model call and grow it into a working agent. You learn the main shapes an agent can take, and build the first version of a travel-planning agency that answers a real request.
Eight architectures hired into one agency - Stage 02 7 lessons
Harness foundations
Build the foundation every later feature depends on: a database, background processing, a core engine that is easy to test, safe handling of money, and a running record of every model call and what it cost.
The turn, the ledger, and the engine every desk runs on - Stage 03 7 lessons
Surviving crashes
Make the agent reliable when things go wrong. You learn how a job survives a crashed worker, resumes exactly where it left off without repeating work it already paid for, and prove it against a real database.
A turn that resumes after a killed worker, proven on Postgres - Stage 04 6 lessons
Suppliers, provenance, and gates
Connect real flight and hotel data, and build the checks that keep the model honest. You learn how to guarantee every price a traveller sees came from an actual search, never from the model itself.
Live suppliers, and gates that block any price the model invented - Stage 05 7 lessons
The fleet
Bring the agent to life with real model calls. You give it tools, protect it from untrusted input, add a memory that lasts across conversations, and control exactly what the traveller sees.
The first real model call, its tools, its memory, its fences - Stage 06 6 lessons
Evals
Learn how to measure whether the agent is doing a good job. You grade both its answers and the path it took to reach them, using real test trips, a simulated traveller, and model judges you keep honest.
The output and the path graded, judges calibrated to her decisions - Stage 07 6 lessons
The self-improving loop
Close the loop so the agent improves over time. You turn the signals travellers leave behind, their edits, choices, and bookings, into safe changes that ship on a regular schedule.
A loop that makes her fourth trip better than her first
Inside every module
What you build, what you learn, and the problem each module was written to solve. Every lesson is free once you sign in.
// Ten shapes an agent can take. We hire eight.
type Shape =
| 'single-call' | 'chain'
| 'router' | 'supervisor'
| 'parallel-fan' | 'reflection'
| 'tool-loop' | 'evaluator'
const AGENCY: Shape[] = pickEight(all) From one call to an agent
Start from a single model call and grow it into a working agent. You learn the main shapes an agent can take, and build the first version of a travel-planning agency that answers a real request.
- You build
- The agency's org chart, and the eight architectures we hire into it.
- You learn
- When a chain, a router, or a supervisor beats a single model call.
- The challenge
- Pick the architecture before the wrong one is baked into everything.
7 lessons in this module
// The engine is pure: same inputs, same plan.
export function turn(state: TurnState, io: Deps): Step {
const notebook = applyRequirements(state.notebook)
const spend = ledger.reserve(SEATS.front_desk)
return decide(notebook, spend) // no I/O in here
} Harness foundations
Build the foundation every later feature depends on: a database, background processing, a core engine that is easy to test, safe handling of money, and a running record of every model call and what it cost.
- You build
- The turn, the pure engine, the money type, the notebook, the call ledger.
- You learn
- The primitives every desk shares, and why the engine stays pure.
- The challenge
- A deterministic harness wrapped around a non-deterministic model.
$ npm test -- worker-resume
✓ a killed worker resumes from its last ledger row
✓ a poison loop trips the step cap, not the bill
✓ two workers cannot claim the same turn
Tests 3 passed (3) · real Postgres Surviving crashes
Make the agent reliable when things go wrong. You learn how a job survives a crashed worker, resumes exactly where it left off without repeating work it already paid for, and prove it against a real database.
- You build
- A turn that resumes after a killed worker and a poison loop.
- You learn
- Durability, idempotency, and replay from the ledger it left behind.
- The challenge
- Crash-safe turns that never lose work and never double-charge.
// Every quoted amount must trace to a supplier row.
for (const price of quotedAmountsIn(reply)) {
if (!corpus.backs(price))
return refuse('unbacked', price) // model invented it
}
return pass() Suppliers, provenance, and gates
Connect real flight and hotel data, and build the checks that keep the model honest. You learn how to guarantee every price a traveller sees came from an actual search, never from the model itself.
- You build
- Live flight and hotel data, behind gates that check every number.
- You learn
- Provenance, grounding, and refusing a price that has no source.
- The challenge
- Stop a hallucinated price before it ever reaches the traveller.
const desk = loadDesk('planning') // hashed prompt
const out = await callModel(desk, {
tools: DESK_TOOLS, // fenced
memory: readUserMemory(user), // per traveller
})
record(out) // every call ledgered The fleet
Bring the agent to life with real model calls. You give it tools, protect it from untrusted input, add a memory that lasts across conversations, and control exactly what the traveller sees.
- You build
- The first real model call, its tools, its fences, its memory.
- You learn
- Tool use, context fencing, memory, and showing your work.
- The challenge
- Real capability without reading, or doing, the wrong thing.
scorecard (3 cases graded)
must_include 3/3 (100%)
every_number_has_search 2/2 (100%)
call_count_fits_the_job 0/3 ← the desk over-asks
questions_before_guesses 3/3 (100%)
judge agreement 0.83 ≥ 0.80 floor Evals
Learn how to measure whether the agent is doing a good job. You grade both its answers and the path it took to reach them, using real test trips, a simulated traveller, and model judges you keep honest.
- You build
- Golden trips, a simulated traveller, and judges calibrated to her.
- You learn
- Grading the output and the path that produced it, and taming variance.
- The challenge
- Measure an agent honestly when every run comes out different.
// The loop writes data and proposes changes.
// A commit changes behaviour — never the model at runtime.
export const CADENCE = {
weekly: 'npm run worst', // read the worst traces
monthly: 'npm run examples', // refresh the prompt set
quarterly: 'count, then decide', // fine-tune? usually no
} The self-improving loop
Close the loop so the agent improves over time. You turn the signals travellers leave behind, their edits, choices, and bookings, into safe changes that ship on a regular schedule.
- You build
- The loop that turns the signals she leaves into changes that ship.
- You learn
- Conversions, example selection, release canaries, and cadence.
- The challenge
- Close the loop safely: data and proposals, one commit at a time.
Build the agency with us
Forty-six free lessons, and a repository you can run the moment you finish module 3.