Open History to see the last commit
1---
2id: AudioGenerationOptions
3title: AudioGenerationOptions
4---
5
6# Interface: AudioGenerationOptions\<TProviderOptions\>
7
8Defined in: [packages/typescript/ai/src/types.ts:1489](https://github.com/TanStack/ai/blob/main/packages/typescript/ai/src/types.ts#L1489)
9
10Options for audio generation (music, sound effects, etc.).
11These are the common options supported across providers.
12
13## Type Parameters
14
15### TProviderOptions
16
17`TProviderOptions` *extends* `object` = `object`
18
19## Properties
20
21### duration?
22
23```ts
24optional duration: number;
25```
26
27Defined in: [packages/typescript/ai/src/types.ts:1497](https://github.com/TanStack/ai/blob/main/packages/typescript/ai/src/types.ts#L1497)
28
29Desired duration in seconds
30
31***
32
33### logger
34
35```ts
36logger: InternalLogger;
37```
38
39Defined in: [packages/typescript/ai/src/types.ts:1505](https://github.com/TanStack/ai/blob/main/packages/typescript/ai/src/types.ts#L1505)
40
41Internal logger threaded from the generateAudio() entry point. Adapters
42must call logger.request() before the SDK call and logger.errors() in
43catch blocks.
44
45***
46
47### model
48
49```ts
50model: string;
51```
52
53Defined in: [packages/typescript/ai/src/types.ts:1493](https://github.com/TanStack/ai/blob/main/packages/typescript/ai/src/types.ts#L1493)
54
55The model to use for audio generation
56
57***
58
59### modelOptions?
60
61```ts
62optional modelOptions: TProviderOptions;
63```
64
65Defined in: [packages/typescript/ai/src/types.ts:1499](https://github.com/TanStack/ai/blob/main/packages/typescript/ai/src/types.ts#L1499)
66
67Model-specific options for audio generation
68
69***
70
71### prompt
72
73```ts
74prompt: string;
75```
76
77Defined in: [packages/typescript/ai/src/types.ts:1495](https://github.com/TanStack/ai/blob/main/packages/typescript/ai/src/types.ts#L1495)
78
79Text description of the desired audio