TurnCommit
The committed outcome of a turn handed to post-commit consumers.
Class Diagram
Section titled “Class Diagram”---
title: TurnCommit
config:
look: handDrawn
theme: colorful
class:
hideEmptyMembersBox: true
---
classDiagram
class TurnCommit {
+string sessionId
+string turnId
+string status
+unknown output
+Message[] messages
+int32 iterations
+int64 lastSequence
+InvocationContextState contextState
+ModelReconciliationState modelReconciliation
}
class Message {
+string role
+ContentPart[] parts
+dictionary metadata
}
TurnCommit *-- Message
class InvocationContextState {
+string portability
+DelegatedStateReference[] delegatedState
}
TurnCommit *-- InvocationContextState
class ModelReconciliationState {
+string invocationId
+ModelInvocationRequest request
+int32 failedAttempt
+string message
+dictionary metadata
}
TurnCommit *-- ModelReconciliationState
Yaml Example
Section titled “Yaml Example”sessionId: sess_abc123turnId: turn_abc123Properties
Section titled “Properties”| Name | Type | Description |
|---|---|---|
| sessionId | string | Stable session identifier |
| turnId | string | Stable turn identifier |
| status | string | Terminal status of the turn |
| output | unknown | Final output when the turn succeeded |
| messages | Message[] | Canonical conversation messages at commit time |
| iterations | int32 | Number of model loop iterations executed |
| lastSequence | int64 | Last committed event sequence for the turn |
| contextState | InvocationContextState | Provider-context state carried out of the turn |
| modelReconciliation | ModelReconciliationState | Typed provider state when the commit requires model reconciliation |
Composed Types
Section titled “Composed Types”The following types are composed within TurnCommit: