Skip to content

taskOutputSchema

const taskOutputSchema: object

The JSON Schemas those models were generated from, for runtime use.

readonly $id: "https://schemas.inderun.dev/1.0/task-output.schema.json"

readonly $schema: "https://json-schema.org/draft/2020-12/schema"

readonly additionalProperties: true

readonly allOf: readonly [{ if: { properties: { type: { const: "text"; }; }; }; then: { required: readonly ["text"]; }; }, { if: { properties: { type: { const: "playback"; }; }; }; then: { required: readonly ["playback"]; }; }, { if: { properties: { type: { const: "artifact"; }; }; }; then: { required: readonly ["artifact"]; }; }, { if: { properties: { type: { const: "prepared"; }; }; }; then: { required: readonly ["preparation"]; }; }]

readonly description: "The normalized output of a run, shared by TaskResult and the completed and cancelled stream terminal outcomes (ADR 016). 'type' describes the content representation, not the task: 'text' carries inline text, 'playback' reports a managed, audible effect that has no retrievable bytes, and 'artifact' references retrievable media (ADR 017). A playback output is never an artifact, and an artifact output never implies that anything was played."

readonly properties: object

readonly artifact: object

readonly $ref: "media-artifact.schema.json"

readonly description: "The retrievable media the run produced. Required when type is 'artifact'."

readonly playback: object

readonly additionalProperties: true

readonly description: "Completion of managed playback. Required when type is 'playback'. Carries no media."

readonly properties: object

readonly timing: object

properties.playback.properties.timing.additionalProperties

Section titled “properties.playback.properties.timing.additionalProperties”

readonly additionalProperties: true

properties.playback.properties.timing.description

Section titled “properties.playback.properties.timing.description”

readonly description: "What the provider measured about the playback. Absent when it measured nothing. 'firstAudioMs' and 'firstChunkMs' count from the same origin: the moment the provider's run() or stream() started handling the request, so their difference is the provider's output latency. The span includes everything the provider does after it starts handling the request (queue wait, voice lookup, a cold model load) and excludes routing."

properties.playback.properties.timing.properties

Section titled “properties.playback.properties.timing.properties”

readonly properties: object

properties.playback.properties.timing.properties.durationMs

Section titled “properties.playback.properties.timing.properties.durationMs”

readonly durationMs: object

properties.playback.properties.timing.properties.durationMs.description

Section titled “properties.playback.properties.timing.properties.durationMs.description”

readonly description: "How long audible playback lasted, in milliseconds. For a cancelled run, how long it played before it was stopped, when the provider reports it."

properties.playback.properties.timing.properties.durationMs.minimum

Section titled “properties.playback.properties.timing.properties.durationMs.minimum”

readonly minimum: 0

properties.playback.properties.timing.properties.durationMs.type

Section titled “properties.playback.properties.timing.properties.durationMs.type”

readonly type: "number"

properties.playback.properties.timing.properties.firstAudioMs

Section titled “properties.playback.properties.timing.properties.firstAudioMs”

readonly firstAudioMs: object

properties.playback.properties.timing.properties.firstAudioMs.description

Section titled “properties.playback.properties.timing.properties.firstAudioMs.description”

readonly description: "Milliseconds from the provider receiving the request until the platform's first audible-output callback (for a system voice, its first word callback) or the first audio frame leaving the output. Absent when nothing reports it."

properties.playback.properties.timing.properties.firstAudioMs.minimum

Section titled “properties.playback.properties.timing.properties.firstAudioMs.minimum”

readonly minimum: 0

properties.playback.properties.timing.properties.firstAudioMs.type

Section titled “properties.playback.properties.timing.properties.firstAudioMs.type”

readonly type: "number"

properties.playback.properties.timing.properties.firstChunkMs

Section titled “properties.playback.properties.timing.properties.firstChunkMs”

readonly firstChunkMs: object

properties.playback.properties.timing.properties.firstChunkMs.description

Section titled “properties.playback.properties.timing.properties.firstChunkMs.description”

readonly description: "Milliseconds from the provider receiving the request until its first playable PCM chunk existed. Absent when the provider does not synthesize PCM itself."

properties.playback.properties.timing.properties.firstChunkMs.minimum

Section titled “properties.playback.properties.timing.properties.firstChunkMs.minimum”

readonly minimum: 0

properties.playback.properties.timing.properties.firstChunkMs.type

Section titled “properties.playback.properties.timing.properties.firstChunkMs.type”

readonly type: "number"

properties.playback.properties.timing.title

Section titled “properties.playback.properties.timing.title”

readonly title: "PlaybackTiming"

properties.playback.properties.timing.type

Section titled “properties.playback.properties.timing.type”

readonly type: "object"

readonly title: "PlaybackOutput"

readonly type: "object"

readonly preparation: object

readonly description: "What a prepare() run did, one item per provider and task. Required when type is 'prepared'. One failed item does not fail the run."

readonly items: object

properties.preparation.items.additionalProperties

Section titled “properties.preparation.items.additionalProperties”

readonly additionalProperties: true

readonly properties: object

properties.preparation.items.properties.providerId

Section titled “properties.preparation.items.properties.providerId”

readonly providerId: object

properties.preparation.items.properties.providerId.description

Section titled “properties.preparation.items.properties.providerId.description”

readonly description: "The provider this item belongs to."

properties.preparation.items.properties.providerId.minLength

Section titled “properties.preparation.items.properties.providerId.minLength”

readonly minLength: 1

properties.preparation.items.properties.providerId.type

Section titled “properties.preparation.items.properties.providerId.type”

readonly type: "string"

properties.preparation.items.properties.reason

Section titled “properties.preparation.items.properties.reason”

readonly reason: object

properties.preparation.items.properties.reason.description

Section titled “properties.preparation.items.properties.reason.description”

readonly description: "Why the item was skipped or failed."

properties.preparation.items.properties.reason.minLength

Section titled “properties.preparation.items.properties.reason.minLength”

readonly minLength: 1

properties.preparation.items.properties.reason.type

Section titled “properties.preparation.items.properties.reason.type”

readonly type: "string"

properties.preparation.items.properties.status

Section titled “properties.preparation.items.properties.status”

readonly status: object

properties.preparation.items.properties.status.description

Section titled “properties.preparation.items.properties.status.description”

readonly description: "'prepared': this run made it ready. 'already_ready': nothing was needed. 'skipped': it needs a download that neither autoDownload nor allowDownload permits. 'failed': see reason."

properties.preparation.items.properties.status.enum

Section titled “properties.preparation.items.properties.status.enum”

readonly enum: readonly ["prepared", "already_ready", "skipped", "failed"]

properties.preparation.items.properties.status.title

Section titled “properties.preparation.items.properties.status.title”

readonly title: "PreparationStatus"

properties.preparation.items.properties.task

Section titled “properties.preparation.items.properties.task”

readonly task: object

properties.preparation.items.properties.task.description

Section titled “properties.preparation.items.properties.task.description”

readonly description: "The task kind this item belongs to."

properties.preparation.items.properties.task.minLength

Section titled “properties.preparation.items.properties.task.minLength”

readonly minLength: 1

properties.preparation.items.properties.task.type

Section titled “properties.preparation.items.properties.task.type”

readonly type: "string"

properties.preparation.items.properties.voiceId

Section titled “properties.preparation.items.properties.voiceId”

readonly voiceId: object

properties.preparation.items.properties.voiceId.description

Section titled “properties.preparation.items.properties.voiceId.description”

readonly description: "The voice this item prepared, when one was bound."

properties.preparation.items.properties.voiceId.minLength

Section titled “properties.preparation.items.properties.voiceId.minLength”

readonly minLength: 1

properties.preparation.items.properties.voiceId.type

Section titled “properties.preparation.items.properties.voiceId.type”

readonly type: "string"

readonly required: readonly ["providerId", "task", "status"]

readonly title: "PreparationItem"

readonly type: "object"

readonly type: "array"

readonly speech: object

readonly additionalProperties: true

readonly description: "The locale and voice a text-to-speech run actually used, so an unmet preference is visible without being an error."

readonly properties: object

readonly locale: object

properties.speech.properties.locale.description

Section titled “properties.speech.properties.locale.description”

readonly description: "BCP 47 tag of the locale that was spoken."

properties.speech.properties.locale.minLength

Section titled “properties.speech.properties.locale.minLength”

readonly minLength: 1

readonly type: "string"

readonly voice: object

properties.speech.properties.voice.additionalProperties

Section titled “properties.speech.properties.voice.additionalProperties”

readonly additionalProperties: true

properties.speech.properties.voice.description

Section titled “properties.speech.properties.voice.description”

readonly description: "The voice that spoke, as the catalog lists it."

properties.speech.properties.voice.properties

Section titled “properties.speech.properties.voice.properties”

readonly properties: object

properties.speech.properties.voice.properties.gender

Section titled “properties.speech.properties.voice.properties.gender”

readonly gender: object

properties.speech.properties.voice.properties.gender.$ref

Section titled “properties.speech.properties.voice.properties.gender.$ref”

readonly $ref: "provider-dynamic-capabilities.schema.json#/$defs/voiceGender"

properties.speech.properties.voice.properties.id

Section titled “properties.speech.properties.voice.properties.id”

readonly id: object

properties.speech.properties.voice.properties.id.description

Section titled “properties.speech.properties.voice.properties.id.description”

readonly description: "The voice's id, when its provider lists one."

properties.speech.properties.voice.properties.id.minLength

Section titled “properties.speech.properties.voice.properties.id.minLength”

readonly minLength: 1

properties.speech.properties.voice.properties.id.type

Section titled “properties.speech.properties.voice.properties.id.type”

readonly type: "string"

properties.speech.properties.voice.properties.name

Section titled “properties.speech.properties.voice.properties.name”

readonly name: object

properties.speech.properties.voice.properties.name.description

Section titled “properties.speech.properties.voice.properties.name.description”

readonly description: "The voice's display label, when its provider lists one."

properties.speech.properties.voice.properties.name.minLength

Section titled “properties.speech.properties.voice.properties.name.minLength”

readonly minLength: 1

properties.speech.properties.voice.properties.name.type

Section titled “properties.speech.properties.voice.properties.name.type”

readonly type: "string"

readonly title: "SpeechOutputVoice"

readonly type: "object"

readonly required: readonly ["locale"]

readonly title: "SpeechOutput"

readonly type: "object"

readonly text: object

readonly description: "The text the run produced. Required when type is 'text'."

readonly type: "string"

readonly type: object

readonly description: "The content representation: 'text', 'playback' or 'artifact'. 'prepared' ends a prepare() run, carries no content, and lists each item in 'preparation'."

readonly enum: readonly ["text", "playback", "artifact", "prepared"]

readonly title: "TaskOutputType"

readonly required: readonly ["type"]

readonly title: "TaskOutput"

readonly type: "object"