Scripted offline mode
Needs no key and makes no paid request. It proves the code path, but cannot demonstrate model variation.
--offlinePart 3 has nine guided TypeScript stages (0–8) plus a Stage 9 transfer project. This page gets the local tools working, proves offline Stage 0, and then hands you to the repository without pretending the website can see your progress.
Your code, model keys, outputs and progress stay in your local clone. This static website neither runs the course nor reads course/progress.json.
The course itself is in English. The site is in nine languages, but the stage guides, the café menu and the twenty test cases are not translated — translating the measured inputs would change the exercise, which is the same reason the Lab's cases stay English.
Done the Lab? Stages 1–4 will be review — this time you write the code.
Clone the public repository, enter it, and install the exact locked dependencies.
That clone and install pull the whole website — several hundred megabytes, because the course shares the site's manifest. The course itself imports one package. Give it a few minutes on a slow connection.
git clone https://github.com/HUDongpin/agent-edu.git
cd agent-edu
npm ciOpen course/stage0-hello/run.ts and replace the empty QUESTION string with a question of your own.
export const QUESTION = "What should I notice about an API?";Offline mode uses a bundled deterministic stand-in. It is the safest preflight: no provider request, private recording or token charge.
npm run course:offline
npx tsx course/stage0-hello/run.ts --offline
npx tsx course/check.ts 0 --offlinePASS you asked the model something
PASS an answer came back
stage 0 complete.Needs no key and makes no paid request. It proves the code path, but cannot demonstrate model variation.
--offlineThe default live Provider. Your terminal process reads DEEPSEEK_API_KEY; live stages incur DeepSeek charges and print their measured spend.
export DEEPSEEK_API_KEY=your_key_hereAn optional local Provider for comparison. Set the key and CAFE_PROVIDER. Claude pricing can be much higher, so inspect the printed estimate before a run.
export ANTHROPIC_API_KEY=your_key_here
export CAFE_PROVIDER=anthropicOffline is free. Live totals vary with the selected model, tokens, cache and current Provider prices. Treat any course estimate as dated; the Provider dashboard is the billing record.
The course checker writes course/progress.json locally. The website cannot observe that file, so it shows no percentage and no Resume state for Part 3 — only the note you make for yourself below.
npx tsx course/report.ts
# reads course/progress.json in this cloneNothing here checks your work. If you have finished the stages, you can note that for yourself. It is kept in this browser, it is sent nowhere, and you can remove it at any time.
Stage 9 asks you to move beyond the café and document an agent in a domain you know. A reviewable submission includes:
Return to the browser Lab and practise rules → prompt → eval first. It teaches the same control handoff without asking you to install a development environment.