Represents a single LLM call within a trajectory.
Each step captures the input, output, token usage, timing, and metadata
from a Puck.call/4 invocation.
Fields
:input- The content sent to the LLM:output- The parsed struct (ifoutput_schemawas used) or raw content:tokens- Token usage map with:input,:output, and:totalkeys:duration_ms- Time taken for this call in milliseconds:metadata- Additional metadata fromPuck.Response.metadata
Example
%Step{
input: "Find John's email",
output: %LookupContact{name: "John"},
tokens: %{input: 150, output: 30, total: 180},
duration_ms: 450,
metadata: %{model: "claude-sonnet-4-5-20250514"}
}
Summary
Types
@type t() :: %Puck.Eval.Step{ duration_ms: non_neg_integer(), input: term(), metadata: map(), output: term(), tokens: %{ input: non_neg_integer(), output: non_neg_integer(), total: non_neg_integer() } }