Skip to content

Interface: ModelTurnResponse ​

Defined in: ports/model-turn-response.ts:25

Response returned by a single ModelDriver.invokeTurn() call.

Pairs the raw UTF-8 vendor wire bytes with the canonical message projection, optional parsed structured output, and token usage metrics.

Properties ​

PropertyModifierTypeDescriptionDefined in
canonicalreadonlyCanonicalMessageVendor-neutral canonical message projection of the assistant response.ports/model-turn-response.ts:29
structuredOutput?readonlyunknownParsed structured output object (populated only when canonical.toolCalls is empty).ports/model-turn-response.ts:31
usagereadonlyModelUsageMetricsToken usage and USD cost metrics for the turn.ports/model-turn-response.ts:33
wireFramereadonlyUint8ArrayRaw UTF-8 provider wire JSON bytes preserving vendor reasoning signatures.ports/model-turn-response.ts:27

Released under the MIT License.