Defined in: packages/ai/src/types.ts:2598
Result of text-to-speech generation.
Properties#
alignment?#
optional alignment?: TTSAlignment;
Defined in: packages/ai/src/types.ts:2613
Character- or word-level timings, present when timestamps: true was
requested. Use this rather than duration to find where speech ends.
artifacts?#
optional artifacts?: PersistedArtifactRef[];
Defined in: packages/ai/src/types.ts:2624
Persisted artifact references for generated assets, when available
audio#
audio: string;
Defined in: packages/ai/src/types.ts:2604
Base64-encoded audio data
contentType?#
optional contentType?: string;
Defined in: packages/ai/src/types.ts:2620
Content type of the audio (e.g., 'audio/mp3')
duration?#
optional duration?: number;
Defined in: packages/ai/src/types.ts:2608
Duration of the audio file in seconds, if available
format#
format: string;
Defined in: packages/ai/src/types.ts:2606
Audio format of the generated audio
id#
id: string;
Defined in: packages/ai/src/types.ts:2600
Unique identifier for the generation
model#
model: string;
Defined in: packages/ai/src/types.ts:2602
Model used for generation
segments?#
optional segments?: TTSSegment[];
Defined in: packages/ai/src/types.ts:2618
Per-turn (or per-utterance) spans of the audio, present when
timestamps: true was requested and the provider reports segmentation.
usage?#
optional usage?: TokenUsage<ProviderUsageDetails>;
Defined in: packages/ai/src/types.ts:2622
Token usage information (if provided by the adapter)