TurnTrace
Portable JSONL/replay container for a recorded turn harness run.
Class Diagram
Section titled “Class Diagram”---
title: TurnTrace
config:
look: handDrawn
theme: colorful
class:
hideEmptyMembersBox: true
---
classDiagram
class TurnTrace {
+string version
+string runtime
+string promptyVersion
+TurnEvent[] events
+TurnSummary summary
}
class TurnEvent {
+string id
+string type
+string timestamp
+string turnId
+int32 iteration
+string parentId
+string spanId
+dictionary payload
}
TurnTrace *-- TurnEvent
class TurnSummary {
+string turnId
+string status
+int32 iterations
+int32 llmCalls
+int32 toolCalls
+int32 retries
+TokenUsage usage
+float64 durationMs
}
TurnTrace *-- TurnSummary
Yaml Example
Section titled “Yaml Example”version: "1"runtime: typescriptpromptyVersion: 2.0.0Properties
Section titled “Properties”| Name | Type | Description |
|---|---|---|
| version | string | Trace schema version |
| runtime | string | Runtime name that produced the trace |
| promptyVersion | string | Prompty library version that produced the trace |
| events | TurnEvent[] | Recorded turn events in emission order |
| summary | TurnSummary | Optional summary computed from the event stream |
Composed Types
Section titled “Composed Types”The following types are composed within TurnTrace: