Skip to content

Tracing

Tracing records runtime steps such as rendering, parsing, provider calls, stream iteration, and custom application operations.

from prompty import PromptyTracer, Tracer, trace
Tracer.add("json", PromptyTracer("./traces").tracer)
@trace
def my_function():
...
TypeDescription
TraceFileSerialized trace file
TraceSpanOne operation span
TraceTimeStart, end, and duration metadata