Skip to content

/

Guides

The anatomy of a trace

Spans, attributes and the three numbers worth reading first on any run.

T

Ines Carvalho

5 min

Chart illustration for the anatomy of a trace

A trace is a tree of spans. The root is your agent run. Every model call, tool call and guardrail check is a child with a start, an end and a bag of attributes.

Read the shape first

Before reading any text, look at the waterfall. A long bar with nothing under it is a model thinking. A staircase is sequential tool calls that could run in parallel.

Then the three numbers

  • Latency of the root span

  • Tokens in and out

  • Cost of the run

Then the words

Only now open the prompt and the response. By this point you usually know which span to open.

Create a free website with Framer, the website builder loved by startups, designers and agencies.