Your AI feature works on your laptop. This course shows what it would do for real users: each step it takes, what it costs, and how long people wait. You’ll build a trace, the record of every step one question to the assistant took.
Whatever feature you’ve built, this course uses a ready-made one to observe, the Ridgeline Huts assistant, which comes ready to run in the code download, so you can start right here. The assistant faces a simulated summer season, where a wrong answer can send a hiker up a closed path, and you’ll need to find that one request among hundreds. Every lesson ends with a number you produced.
What You’ll Learn
By the end of this course, you’ll be able to:
- Log every request with an ID and a timer.
- Trace every request through retrieval, model calls and tool calls.
- Find the step that caused a bad answer from its trace.
- Keep personal data out of what you record.
- Report cost and latency per request with percentiles.
The Project: The Tripled Bill and the Full Hut
In the project, a simulated week brings two problems: the treasurer asks why the bill tripled, and a hiker was sent to a full hut. You’ll report the week’s cost and latency, trace the full-hut answer to the step that went wrong, and add an eval case. Then you’ll explain it to your AI mentor, a chat that plays the treasurer and the head warden.
Before You Start
You should have built an AI feature in JavaScript that streams answers from an Express route, answers from documents, calls tools, and has evals.
For the project, you’ll need Node.js 26 and an API key for one model provider. The project’s runs on that key cost a few dollars or more.
At December 2, 2026 prices, the whole project comes to about $2.50 to $4.50 with OpenAI (gpt-5.4-mini-2026-03-17) and about $7 to $15 with Anthropic (claude-sonnet-5-5, with claude-opus-4-6 judging). The low end is a week with the usual mix of questions, and the high end is a week showing the treasurer’s pattern. Here’s the estimate per step:
| Step | What runs | With OpenAI | With Anthropic |
|---|---|---|---|
| 1 | a few questions | under a tenth of a cent each | under a quarter of a cent each |
| 2 | 1,400 questions | about 94 cents | about $2.20 |
| 3 | no model calls, only your scripts | nothing | nothing |
| 4 | replays, ten case runs, five set reruns | about $1.50 | about $5 to $8, mostly the judge |
If your simulated week shows the treasurer’s pattern, step 2 comes to around $2.80 with OpenAI and around $6.60 with Anthropic. These are estimates rather than caps. Longer answers, retries, and extra tool rounds can push them higher, so set a spending limit on the key with headroom above them.
How the Course Works
The lessons come as text and video, and the coding exercises run in your browser with no key. A project, a quiz, and a summary close the course.
Below this video are the slides and the code download. The code download holds the starting project. Its traffic simulator sends the assistant hiker questions, tidier than real ones. You’ll set it up in the first lesson, Add a Request ID and a Timer.