Table of Contents

Constructor ChatTurnStatus

Namespace
Qavren.Edge.Chat
Assembly
Qavren.Edge.Chat.Onnx.dll

ChatTurnStatus(EdgeChatStopReason, string, string?, int, int, int, int, int, TimeSpan, TimeSpan, double, EdgeThermalState, bool)

One turn's honest record, carried on the final ChatResponseUpdate and on the ChatResponse under TurnStatus. One strongly-typed record under one key, rather than seven loose string keys.

public ChatTurnStatus(EdgeChatStopReason StopReason, string ModelId, string? ConversationId, int PromptTokens, int PromptTokensAppended, int GeneratedTokens, int ContextTokens, int MessagesDropped, TimeSpan TimeToFirstToken, TimeSpan Duration, double TokensPerSecond, EdgeThermalState Thermal, bool ThermalThrottled)

Parameters

StopReason EdgeChatStopReason

Why the turn ended.

ModelId string

The model that produced it.

ConversationId string

The effective id for this response - the caller's if they supplied one, otherwise the one this client minted. Also on every ChatResponseUpdate.ConversationId.

PromptTokens int

Total sequence length the model conditioned on, after any conversation-cache append. Equal to UsageDetails.InputTokenCount on the same response.

PromptTokensAppended int

Tokens actually encoded and appended this turn: equal to PromptTokens on a fresh generator, and the delta alone on a conversation-cache hit.

GeneratedTokens int

Tokens this turn produced.

ContextTokens int

The context the budget allowed.

MessagesDropped int

How many messages history reduction evicted.

TimeToFirstToken TimeSpan

Prefill plus the first decode step.

Duration TimeSpan

The whole turn.

TokensPerSecond double

Decode throughput, excluding prefill.

Thermal EdgeThermalState

The thermal state at the end of the turn, published verbatim - Unknown is never normalised to Nominal.

ThermalThrottled bool

Whether the decode was paced at any point.