Skip to content
Harness · 4 of 6 · about 15 minutes · With a year

Trace a run

A run of an agent has many steps: calls to the model, searches, tools. When a run is slow or expensive, you must know which step is the cause. A harness records each step with its name, its time and its tokens. This record is a trace. From a trace you can compute the totals and find the slowest step. Without a trace, you can only guess.

About this lesson

Words to know

trace
The record of one run: each step with its name, its time and its tokens.
token
The unit a model reads and writes: a word, a piece of a word, or a punctuation mark. Limits and prices are counted in tokens.

Why it matters

Each tool that monitors agents shows this view for a run. The totals tell you what a run costs, and the slowest step tells you where to start the work.

With a year

How it works, a worked example, the exercise with its tests, three hints and the explained solution are in the app, with a year of Algo150 for $29 or ₾49. The first chapter, Model foundations, is free for everyone: start with Vector dot product.

What a year includes