Skip to content

Latest commit

 

History

History
103 lines (62 loc) · 2.14 KB

File metadata and controls

103 lines (62 loc) · 2.14 KB
id TTSOptions
title TTSOptions

Interface: TTSOptions<TProviderOptions>

Defined in: packages/typescript/ai/src/types.ts:1333

Options for text-to-speech generation. These are the common options supported across providers.

Type Parameters

TProviderOptions

TProviderOptions extends object = object

Properties

format?

optional format: "mp3" | "opus" | "aac" | "flac" | "wav" | "pcm";

Defined in: packages/typescript/ai/src/types.ts:1341

The output audio format


logger

logger: InternalLogger;

Defined in: packages/typescript/ai/src/types.ts:1351

Internal logger threaded from the generateSpeech() entry point. Adapters must call logger.request() before the SDK call and logger.errors() in catch blocks.


model

model: string;

Defined in: packages/typescript/ai/src/types.ts:1335

The model to use for TTS generation


modelOptions?

optional modelOptions: TProviderOptions;

Defined in: packages/typescript/ai/src/types.ts:1345

Model-specific options for TTS generation


speed?

optional speed: number;

Defined in: packages/typescript/ai/src/types.ts:1343

The speed of the generated audio (0.25 to 4.0)


text

text: string;

Defined in: packages/typescript/ai/src/types.ts:1337

The text to convert to speech


voice?

optional voice: string;

Defined in: packages/typescript/ai/src/types.ts:1339

The voice to use for generation