Open History to see the last commit
1---
2id: AudioGenerationOptions
3title: AudioGenerationOptions
4---
5
6Defined in: [packages/ai/src/types.ts:2163](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L2163)
7
8Options for audio generation (music, sound effects, etc.).
9These are the common options supported across providers.
10
11## Type Parameters
12
13### TProviderOptions
14
15`TProviderOptions` *extends* `object` = `object`
16
17## Properties
18
19### abortSignal?
20
21```ts
22optional abortSignal?: AbortSignal;
23```
24
25Defined in: [packages/ai/src/types.ts:2185](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L2185)
26
27Effective abort signal composed by the activity from caller `abortSignal`
28and/or `timeout`. Adapters should forward this to the provider SDK when
29supported. Request-specific — never store on a global client config.
30
31***
32
33### duration?
34
35```ts
36optional duration?: number;
37```
38
39Defined in: [packages/ai/src/types.ts:2171](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L2171)
40
41Desired duration in seconds
42
43***
44
45### logger
46
47```ts
48logger: InternalLogger;
49```
50
51Defined in: [packages/ai/src/types.ts:2179](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L2179)
52
53Internal logger threaded from the generateAudio() entry point. Adapters
54must call logger.request() before the SDK call and logger.errors() in
55catch blocks.
56
57***
58
59### model
60
61```ts
62model: string;
63```
64
65Defined in: [packages/ai/src/types.ts:2167](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L2167)
66
67The model to use for audio generation
68
69***
70
71### modelOptions?
72
73```ts
74optional modelOptions?: TProviderOptions;
75```
76
77Defined in: [packages/ai/src/types.ts:2173](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L2173)
78
79Model-specific options for audio generation
80
81***
82
83### prompt
84
85```ts
86prompt: string;
87```
88
89Defined in: [packages/ai/src/types.ts:2169](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L2169)
90
91Text description of the desired audio