@ai-sdk/openai 2.0.0-canary.8 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,668 @@
1
1
  # @ai-sdk/openai
2
2
 
3
+ ## 2.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - d5f588f: AI SDK 5
8
+ - cc62234: chore (provider/openai): switch default to openai responses api
9
+ - 516be5b: ### Move Image Model Settings into generate options
10
+
11
+ Image Models no longer have settings. Instead, `maxImagesPerCall` can be passed directly to `generateImage()`. All other image settings can be passed to `providerOptions[provider]`.
12
+
13
+ Before
14
+
15
+ ```js
16
+ await generateImage({
17
+ model: luma.image('photon-flash-1', {
18
+ maxImagesPerCall: 5,
19
+ pollIntervalMillis: 500,
20
+ }),
21
+ prompt,
22
+ n: 10,
23
+ });
24
+ ```
25
+
26
+ After
27
+
28
+ ```js
29
+ await generateImage({
30
+ model: luma.image('photon-flash-1'),
31
+ prompt,
32
+ n: 10,
33
+ maxImagesPerCall: 5,
34
+ providerOptions: {
35
+ luma: { pollIntervalMillis: 5 },
36
+ },
37
+ });
38
+ ```
39
+
40
+ Pull Request: https://github.com/vercel/ai/pull/6180
41
+
42
+ - efc3a62: fix (provider/openai): default strict mode to false
43
+
44
+ ### Patch Changes
45
+
46
+ - 948b755: chore(providers/openai): convert to providerOptions
47
+ - d63bcbc: feat (provider/openai): o4 updates for responses api
48
+ - 3bd3c0b: chore(providers/openai): update embedding model to use providerOptions
49
+ - 5d959e7: refactor: updated openai + anthropic tool use server side
50
+ - 0eee6a8: Fix streaming and reconstruction of reasoning summary parts
51
+ - 177526b: chore(providers/openai-transcription): switch to providerOptions
52
+ - 2f542fa: Add reasoning-part-finish parts for reasoning models in the responses API
53
+ - c15dfbf: feat (providers/openai): add gpt-image-1 model id to image settings
54
+ - 3b1ea10: adding support for gpt-4o-search-preview and handling unsupported parameters
55
+ - e2aceaf: feat: add raw chunk support
56
+ - d2af019: feat (providers/openai): add gpt-4.1 models
57
+ - eb173f1: chore (providers): remove model shorthand deprecation warnings
58
+ - 209256d: Add missing file_search tool support to OpenAI Responses API
59
+ - faea29f: fix (provider/openai): multi-step reasoning with text
60
+ - 7032dc5: feat(openai): add priority processing service tier support
61
+ - 870c5c0: feat (providers/openai): add o3 and o4-mini models
62
+ - db72adc: chore(providers/openai): update completion model to use providerOptions
63
+ - a166433: feat: add transcription with experimental_transcribe
64
+ - 26735b5: chore(embedding-model): add v2 interface
65
+ - 443d8ec: feat(embedding-model-v2): add response body field
66
+ - 8d12da5: feat(provider/openai): add serviceTier option for flex processing
67
+ - 9bf7291: chore(providers/openai): enable structuredOutputs by default & switch to provider option
68
+ - d521cda: feat(openai): add file_search filters and update field names
69
+ - 66962ed: fix(packages): export node10 compatible types
70
+ - 442be08: fix: propagate openai transcription fixes
71
+ - 0059ee2: fix(openai): update file_search fields to match API changes
72
+ - 8493141: feat (providers/openai): add support for reasoning summaries
73
+ - 9301f86: refactor (image-model): rename `ImageModelV1` to `ImageModelV2`
74
+ - 0a87932: core (ai): change transcription model mimeType to mediaType
75
+ - 8aa9e20: feat: add speech with experimental_generateSpeech
76
+ - 4617fab: chore(embedding-models): remove remaining settings
77
+ - b5a0e32: fix (provider/openai): correct default for chat model strict mode
78
+ - 136819b: chore(providers/openai): re-introduce logprobs as providerMetadata
79
+ - 52ce942: chore(providers/openai): remove & enable strict compatibility by default
80
+ - db64cbe: fix (provider/openai): multi-step reasoning with tool calls
81
+ - b3c3450: feat (provider/openai): add support for encrypted_reasoning to responses api
82
+ - 48249c4: Do not warn if empty text is the first part of a reasoning sequence
83
+ - c7d3b2e: fix (provider/openai): push first reasoning chunk in output item added event
84
+ - ad2a3d5: feat(provider/openai): add missing reasoning models to responses API
85
+ - 9943464: feat(openai): add file_search_call.results support to include parameter
86
+ - 0fa7414: chore (provider/openai): standardize on itemId in provider metadata
87
+ - 9bd5ab5: feat (provider): add providerMetadata to ImageModelV2 interface (#5977)
88
+
89
+ The `experimental_generateImage` method from the `ai` package now returnes revised prompts for OpenAI's image models.
90
+
91
+ ```js
92
+ const prompt = 'Santa Claus driving a Cadillac';
93
+
94
+ const { providerMetadata } = await experimental_generateImage({
95
+ model: openai.image('dall-e-3'),
96
+ prompt,
97
+ });
98
+
99
+ const revisedPrompt = providerMetadata.openai.images[0]?.revisedPrompt;
100
+
101
+ console.log({
102
+ prompt,
103
+ revisedPrompt,
104
+ });
105
+ ```
106
+
107
+ - fa758ea: feat(provider/openai): add o3 & o4-mini with developer systemMessageMode
108
+ - d1a034f: feature: using Zod 4 for internal stuff
109
+ - fd65bc6: chore(embedding-model-v2): rename rawResponse to response
110
+ - e497698: fix (provider/openai): handle responses api errors
111
+ - 928fadf: fix(providers/openai): logprobs for stream alongside completion model
112
+ - 0a87932: fix (provider/openai): increase transcription model resilience
113
+ - 5147e6e: chore(openai): remove simulateStreaming
114
+ - 06bac05: fix (openai): structure output for responses model
115
+ - 205077b: fix: improve Zod compatibility
116
+ - c2b92cc: chore(openai): remove legacy function calling
117
+ - 284353f: fix(providers/openai): zod parse error with function
118
+ - 6f231db: fix(providers): always use optional instead of mix of nullish for providerOptions
119
+ - f10304b: feat(tool-calling): don't require the user to have to pass parameters
120
+ - 4af5233: Fix PDF file parts when passed as a string url or Uint8Array
121
+ - 7df7a25: feat (providers/openai): support gpt-image-1 image generation
122
+ - Updated dependencies [a571d6e]
123
+ - Updated dependencies [742b7be]
124
+ - Updated dependencies [e7fcc86]
125
+ - Updated dependencies [7cddb72]
126
+ - Updated dependencies [ccce59b]
127
+ - Updated dependencies [e2b9e4b]
128
+ - Updated dependencies [95857aa]
129
+ - Updated dependencies [45c1ea2]
130
+ - Updated dependencies [6f6bb89]
131
+ - Updated dependencies [060370c]
132
+ - Updated dependencies [dc714f3]
133
+ - Updated dependencies [b5da06a]
134
+ - Updated dependencies [d1a1aa1]
135
+ - Updated dependencies [63f9e9b]
136
+ - Updated dependencies [5d142ab]
137
+ - Updated dependencies [d5f588f]
138
+ - Updated dependencies [e025824]
139
+ - Updated dependencies [0571b98]
140
+ - Updated dependencies [b6b43c7]
141
+ - Updated dependencies [4fef487]
142
+ - Updated dependencies [48d257a]
143
+ - Updated dependencies [0c0c0b3]
144
+ - Updated dependencies [0d2c085]
145
+ - Updated dependencies [40acf9b]
146
+ - Updated dependencies [9222aeb]
147
+ - Updated dependencies [e2aceaf]
148
+ - Updated dependencies [411e483]
149
+ - Updated dependencies [8ba77a7]
150
+ - Updated dependencies [7b3ae3f]
151
+ - Updated dependencies [a166433]
152
+ - Updated dependencies [26735b5]
153
+ - Updated dependencies [443d8ec]
154
+ - Updated dependencies [a8c8bd5]
155
+ - Updated dependencies [abf9a79]
156
+ - Updated dependencies [14c9410]
157
+ - Updated dependencies [e86be6f]
158
+ - Updated dependencies [9bf7291]
159
+ - Updated dependencies [2e13791]
160
+ - Updated dependencies [9f95b35]
161
+ - Updated dependencies [66962ed]
162
+ - Updated dependencies [0d06df6]
163
+ - Updated dependencies [472524a]
164
+ - Updated dependencies [dd3ff01]
165
+ - Updated dependencies [d9c98f4]
166
+ - Updated dependencies [05d2819]
167
+ - Updated dependencies [9301f86]
168
+ - Updated dependencies [0a87932]
169
+ - Updated dependencies [c4a2fec]
170
+ - Updated dependencies [957b739]
171
+ - Updated dependencies [79457bd]
172
+ - Updated dependencies [a3f768e]
173
+ - Updated dependencies [7435eb5]
174
+ - Updated dependencies [8aa9e20]
175
+ - Updated dependencies [4617fab]
176
+ - Updated dependencies [ac34802]
177
+ - Updated dependencies [0054544]
178
+ - Updated dependencies [cb68df0]
179
+ - Updated dependencies [ad80501]
180
+ - Updated dependencies [68ecf2f]
181
+ - Updated dependencies [9e9c809]
182
+ - Updated dependencies [32831c6]
183
+ - Updated dependencies [6dc848c]
184
+ - Updated dependencies [6b98118]
185
+ - Updated dependencies [d0f9495]
186
+ - Updated dependencies [63d791d]
187
+ - Updated dependencies [87b828f]
188
+ - Updated dependencies [3f2f00c]
189
+ - Updated dependencies [bfdca8d]
190
+ - Updated dependencies [0ff02bb]
191
+ - Updated dependencies [7979f7f]
192
+ - Updated dependencies [39a4fab]
193
+ - Updated dependencies [44f4aba]
194
+ - Updated dependencies [9bd5ab5]
195
+ - Updated dependencies [57edfcb]
196
+ - Updated dependencies [faf8446]
197
+ - Updated dependencies [7ea4132]
198
+ - Updated dependencies [d1a034f]
199
+ - Updated dependencies [5c56081]
200
+ - Updated dependencies [fd65bc6]
201
+ - Updated dependencies [023ba40]
202
+ - Updated dependencies [ea7a7c9]
203
+ - Updated dependencies [26535e0]
204
+ - Updated dependencies [e030615]
205
+ - Updated dependencies [5e57fae]
206
+ - Updated dependencies [393138b]
207
+ - Updated dependencies [c57e248]
208
+ - Updated dependencies [88a8ee5]
209
+ - Updated dependencies [41fa418]
210
+ - Updated dependencies [205077b]
211
+ - Updated dependencies [71f938d]
212
+ - Updated dependencies [3795467]
213
+ - Updated dependencies [28a5ed5]
214
+ - Updated dependencies [7182d14]
215
+ - Updated dependencies [c1e6647]
216
+ - Updated dependencies [1766ede]
217
+ - Updated dependencies [811dff3]
218
+ - Updated dependencies [f10304b]
219
+ - Updated dependencies [dd5fd43]
220
+ - Updated dependencies [33f4a6a]
221
+ - Updated dependencies [383cbfa]
222
+ - Updated dependencies [27deb4d]
223
+ - Updated dependencies [c4df419]
224
+ - @ai-sdk/provider-utils@3.0.0
225
+ - @ai-sdk/provider@2.0.0
226
+
227
+ ## 2.0.0-beta.16
228
+
229
+ ### Patch Changes
230
+
231
+ - Updated dependencies [88a8ee5]
232
+ - @ai-sdk/provider-utils@3.0.0-beta.10
233
+
234
+ ## 2.0.0-beta.15
235
+
236
+ ### Patch Changes
237
+
238
+ - 9943464: feat(openai): add file_search_call.results support to include parameter
239
+ - Updated dependencies [27deb4d]
240
+ - @ai-sdk/provider@2.0.0-beta.2
241
+ - @ai-sdk/provider-utils@3.0.0-beta.9
242
+
243
+ ## 2.0.0-beta.14
244
+
245
+ ### Patch Changes
246
+
247
+ - eb173f1: chore (providers): remove model shorthand deprecation warnings
248
+ - 7032dc5: feat(openai): add priority processing service tier support
249
+ - Updated dependencies [dd5fd43]
250
+ - @ai-sdk/provider-utils@3.0.0-beta.8
251
+
252
+ ## 2.0.0-beta.13
253
+
254
+ ### Patch Changes
255
+
256
+ - Updated dependencies [e7fcc86]
257
+ - @ai-sdk/provider-utils@3.0.0-beta.7
258
+
259
+ ## 2.0.0-beta.12
260
+
261
+ ### Patch Changes
262
+
263
+ - d521cda: feat(openai): add file_search filters and update field names
264
+ - 0059ee2: fix(openai): update file_search fields to match API changes
265
+ - Updated dependencies [ac34802]
266
+ - @ai-sdk/provider-utils@3.0.0-beta.6
267
+
268
+ ## 2.0.0-beta.11
269
+
270
+ ### Patch Changes
271
+
272
+ - Updated dependencies [57edfcb]
273
+ - Updated dependencies [383cbfa]
274
+ - @ai-sdk/provider-utils@3.0.0-beta.5
275
+
276
+ ## 2.0.0-beta.10
277
+
278
+ ### Patch Changes
279
+
280
+ - 0fa7414: chore (provider/openai): standardize on itemId in provider metadata
281
+ - 205077b: fix: improve Zod compatibility
282
+ - Updated dependencies [205077b]
283
+ - @ai-sdk/provider-utils@3.0.0-beta.4
284
+
285
+ ## 2.0.0-beta.9
286
+
287
+ ### Patch Changes
288
+
289
+ - faea29f: fix (provider/openai): multi-step reasoning with text
290
+
291
+ ## 2.0.0-beta.8
292
+
293
+ ### Patch Changes
294
+
295
+ - db64cbe: fix (provider/openai): multi-step reasoning with tool calls
296
+ - Updated dependencies [05d2819]
297
+ - @ai-sdk/provider-utils@3.0.0-beta.3
298
+
299
+ ## 2.0.0-beta.7
300
+
301
+ ### Patch Changes
302
+
303
+ - 209256d: Add missing file_search tool support to OpenAI Responses API
304
+
305
+ ## 2.0.0-beta.6
306
+
307
+ ### Patch Changes
308
+
309
+ - 0eee6a8: Fix streaming and reconstruction of reasoning summary parts
310
+ - b5a0e32: fix (provider/openai): correct default for chat model strict mode
311
+ - c7d3b2e: fix (provider/openai): push first reasoning chunk in output item added event
312
+
313
+ ## 2.0.0-beta.5
314
+
315
+ ### Patch Changes
316
+
317
+ - 48249c4: Do not warn if empty text is the first part of a reasoning sequence
318
+ - e497698: fix (provider/openai): handle responses api errors
319
+
320
+ ## 2.0.0-beta.4
321
+
322
+ ### Patch Changes
323
+
324
+ - b3c3450: feat (provider/openai): add support for encrypted_reasoning to responses api
325
+ - ad2a3d5: feat(provider/openai): add missing reasoning models to responses API
326
+
327
+ ## 2.0.0-beta.3
328
+
329
+ ### Major Changes
330
+
331
+ - efc3a62: fix (provider/openai): default strict mode to false
332
+
333
+ ## 2.0.0-beta.2
334
+
335
+ ### Patch Changes
336
+
337
+ - d1a034f: feature: using Zod 4 for internal stuff
338
+ - Updated dependencies [0571b98]
339
+ - Updated dependencies [39a4fab]
340
+ - Updated dependencies [d1a034f]
341
+ - @ai-sdk/provider-utils@3.0.0-beta.2
342
+
343
+ ## 2.0.0-beta.1
344
+
345
+ ### Major Changes
346
+
347
+ - cc62234: chore (provider/openai): switch default to openai responses api
348
+
349
+ ### Patch Changes
350
+
351
+ - 5d959e7: refactor: updated openai + anthropic tool use server side
352
+ - Updated dependencies [742b7be]
353
+ - Updated dependencies [7cddb72]
354
+ - Updated dependencies [ccce59b]
355
+ - Updated dependencies [e2b9e4b]
356
+ - Updated dependencies [45c1ea2]
357
+ - Updated dependencies [e025824]
358
+ - Updated dependencies [0d06df6]
359
+ - Updated dependencies [472524a]
360
+ - Updated dependencies [dd3ff01]
361
+ - Updated dependencies [7435eb5]
362
+ - Updated dependencies [cb68df0]
363
+ - Updated dependencies [bfdca8d]
364
+ - Updated dependencies [44f4aba]
365
+ - Updated dependencies [023ba40]
366
+ - Updated dependencies [5e57fae]
367
+ - Updated dependencies [71f938d]
368
+ - Updated dependencies [28a5ed5]
369
+ - @ai-sdk/provider@2.0.0-beta.1
370
+ - @ai-sdk/provider-utils@3.0.0-beta.1
371
+
372
+ ## 2.0.0-alpha.15
373
+
374
+ ### Patch Changes
375
+
376
+ - Updated dependencies [48d257a]
377
+ - Updated dependencies [8ba77a7]
378
+ - @ai-sdk/provider@2.0.0-alpha.15
379
+ - @ai-sdk/provider-utils@3.0.0-alpha.15
380
+
381
+ ## 2.0.0-alpha.14
382
+
383
+ ### Patch Changes
384
+
385
+ - Updated dependencies [b5da06a]
386
+ - Updated dependencies [63f9e9b]
387
+ - Updated dependencies [2e13791]
388
+ - @ai-sdk/provider@2.0.0-alpha.14
389
+ - @ai-sdk/provider-utils@3.0.0-alpha.14
390
+
391
+ ## 2.0.0-alpha.13
392
+
393
+ ### Patch Changes
394
+
395
+ - Updated dependencies [68ecf2f]
396
+ - @ai-sdk/provider@2.0.0-alpha.13
397
+ - @ai-sdk/provider-utils@3.0.0-alpha.13
398
+
399
+ ## 2.0.0-alpha.12
400
+
401
+ ### Patch Changes
402
+
403
+ - 2f542fa: Add reasoning-part-finish parts for reasoning models in the responses API
404
+ - e2aceaf: feat: add raw chunk support
405
+ - Updated dependencies [e2aceaf]
406
+ - @ai-sdk/provider@2.0.0-alpha.12
407
+ - @ai-sdk/provider-utils@3.0.0-alpha.12
408
+
409
+ ## 2.0.0-alpha.11
410
+
411
+ ### Patch Changes
412
+
413
+ - 8d12da5: feat(provider/openai): add serviceTier option for flex processing
414
+ - Updated dependencies [c1e6647]
415
+ - @ai-sdk/provider@2.0.0-alpha.11
416
+ - @ai-sdk/provider-utils@3.0.0-alpha.11
417
+
418
+ ## 2.0.0-alpha.10
419
+
420
+ ### Patch Changes
421
+
422
+ - Updated dependencies [c4df419]
423
+ - @ai-sdk/provider@2.0.0-alpha.10
424
+ - @ai-sdk/provider-utils@3.0.0-alpha.10
425
+
426
+ ## 2.0.0-alpha.9
427
+
428
+ ### Patch Changes
429
+
430
+ - Updated dependencies [811dff3]
431
+ - @ai-sdk/provider@2.0.0-alpha.9
432
+ - @ai-sdk/provider-utils@3.0.0-alpha.9
433
+
434
+ ## 2.0.0-alpha.8
435
+
436
+ ### Patch Changes
437
+
438
+ - 4af5233: Fix PDF file parts when passed as a string url or Uint8Array
439
+ - Updated dependencies [4fef487]
440
+ - Updated dependencies [9222aeb]
441
+ - @ai-sdk/provider-utils@3.0.0-alpha.8
442
+ - @ai-sdk/provider@2.0.0-alpha.8
443
+
444
+ ## 2.0.0-alpha.7
445
+
446
+ ### Patch Changes
447
+
448
+ - Updated dependencies [5c56081]
449
+ - @ai-sdk/provider@2.0.0-alpha.7
450
+ - @ai-sdk/provider-utils@3.0.0-alpha.7
451
+
452
+ ## 2.0.0-alpha.6
453
+
454
+ ### Patch Changes
455
+
456
+ - Updated dependencies [0d2c085]
457
+ - @ai-sdk/provider@2.0.0-alpha.6
458
+ - @ai-sdk/provider-utils@3.0.0-alpha.6
459
+
460
+ ## 2.0.0-alpha.4
461
+
462
+ ### Patch Changes
463
+
464
+ - Updated dependencies [dc714f3]
465
+ - @ai-sdk/provider@2.0.0-alpha.4
466
+ - @ai-sdk/provider-utils@3.0.0-alpha.4
467
+
468
+ ## 2.0.0-alpha.3
469
+
470
+ ### Patch Changes
471
+
472
+ - Updated dependencies [6b98118]
473
+ - @ai-sdk/provider@2.0.0-alpha.3
474
+ - @ai-sdk/provider-utils@3.0.0-alpha.3
475
+
476
+ ## 2.0.0-alpha.2
477
+
478
+ ### Patch Changes
479
+
480
+ - Updated dependencies [26535e0]
481
+ - @ai-sdk/provider@2.0.0-alpha.2
482
+ - @ai-sdk/provider-utils@3.0.0-alpha.2
483
+
484
+ ## 2.0.0-alpha.1
485
+
486
+ ### Patch Changes
487
+
488
+ - Updated dependencies [3f2f00c]
489
+ - @ai-sdk/provider@2.0.0-alpha.1
490
+ - @ai-sdk/provider-utils@3.0.0-alpha.1
491
+
492
+ ## 2.0.0-canary.20
493
+
494
+ ### Patch Changes
495
+
496
+ - Updated dependencies [faf8446]
497
+ - @ai-sdk/provider-utils@3.0.0-canary.19
498
+
499
+ ## 2.0.0-canary.19
500
+
501
+ ### Patch Changes
502
+
503
+ - Updated dependencies [40acf9b]
504
+ - @ai-sdk/provider-utils@3.0.0-canary.18
505
+
506
+ ## 2.0.0-canary.18
507
+
508
+ ### Major Changes
509
+
510
+ - 516be5b: ### Move Image Model Settings into generate options
511
+
512
+ Image Models no longer have settings. Instead, `maxImagesPerCall` can be passed directly to `generateImage()`. All other image settings can be passed to `providerOptions[provider]`.
513
+
514
+ Before
515
+
516
+ ```js
517
+ await generateImage({
518
+ model: luma.image('photon-flash-1', {
519
+ maxImagesPerCall: 5,
520
+ pollIntervalMillis: 500,
521
+ }),
522
+ prompt,
523
+ n: 10,
524
+ });
525
+ ```
526
+
527
+ After
528
+
529
+ ```js
530
+ await generateImage({
531
+ model: luma.image('photon-flash-1'),
532
+ prompt,
533
+ n: 10,
534
+ maxImagesPerCall: 5,
535
+ providerOptions: {
536
+ luma: { pollIntervalMillis: 5 },
537
+ },
538
+ });
539
+ ```
540
+
541
+ Pull Request: https://github.com/vercel/ai/pull/6180
542
+
543
+ ### Patch Changes
544
+
545
+ - Updated dependencies [ea7a7c9]
546
+ - @ai-sdk/provider-utils@3.0.0-canary.17
547
+
548
+ ## 2.0.0-canary.17
549
+
550
+ ### Patch Changes
551
+
552
+ - 52ce942: chore(providers/openai): remove & enable strict compatibility by default
553
+ - Updated dependencies [87b828f]
554
+ - @ai-sdk/provider-utils@3.0.0-canary.16
555
+
556
+ ## 2.0.0-canary.16
557
+
558
+ ### Patch Changes
559
+
560
+ - 928fadf: fix(providers/openai): logprobs for stream alongside completion model
561
+ - 6f231db: fix(providers): always use optional instead of mix of nullish for providerOptions
562
+ - Updated dependencies [a571d6e]
563
+ - Updated dependencies [a8c8bd5]
564
+ - Updated dependencies [7979f7f]
565
+ - Updated dependencies [41fa418]
566
+ - @ai-sdk/provider-utils@3.0.0-canary.15
567
+ - @ai-sdk/provider@2.0.0-canary.14
568
+
569
+ ## 2.0.0-canary.15
570
+
571
+ ### Patch Changes
572
+
573
+ - 136819b: chore(providers/openai): re-introduce logprobs as providerMetadata
574
+ - 9bd5ab5: feat (provider): add providerMetadata to ImageModelV2 interface (#5977)
575
+
576
+ The `experimental_generateImage` method from the `ai` package now returnes revised prompts for OpenAI's image models.
577
+
578
+ ```js
579
+ const prompt = 'Santa Claus driving a Cadillac';
580
+
581
+ const { providerMetadata } = await experimental_generateImage({
582
+ model: openai.image('dall-e-3'),
583
+ prompt,
584
+ });
585
+
586
+ const revisedPrompt = providerMetadata.openai.images[0]?.revisedPrompt;
587
+
588
+ console.log({
589
+ prompt,
590
+ revisedPrompt,
591
+ });
592
+ ```
593
+
594
+ - 284353f: fix(providers/openai): zod parse error with function
595
+ - Updated dependencies [957b739]
596
+ - Updated dependencies [9bd5ab5]
597
+ - @ai-sdk/provider-utils@3.0.0-canary.14
598
+ - @ai-sdk/provider@2.0.0-canary.13
599
+
600
+ ## 2.0.0-canary.14
601
+
602
+ ### Patch Changes
603
+
604
+ - fa758ea: feat(provider/openai): add o3 & o4-mini with developer systemMessageMode
605
+ - Updated dependencies [7b3ae3f]
606
+ - Updated dependencies [0ff02bb]
607
+ - @ai-sdk/provider@2.0.0-canary.12
608
+ - @ai-sdk/provider-utils@3.0.0-canary.13
609
+
610
+ ## 2.0.0-canary.13
611
+
612
+ ### Patch Changes
613
+
614
+ - 177526b: chore(providers/openai-transcription): switch to providerOptions
615
+ - c15dfbf: feat (providers/openai): add gpt-image-1 model id to image settings
616
+ - 9bf7291: chore(providers/openai): enable structuredOutputs by default & switch to provider option
617
+ - 4617fab: chore(embedding-models): remove remaining settings
618
+ - Updated dependencies [9bf7291]
619
+ - Updated dependencies [4617fab]
620
+ - Updated dependencies [e030615]
621
+ - @ai-sdk/provider@2.0.0-canary.11
622
+ - @ai-sdk/provider-utils@3.0.0-canary.12
623
+
624
+ ## 2.0.0-canary.12
625
+
626
+ ### Patch Changes
627
+
628
+ - db72adc: chore(providers/openai): update completion model to use providerOptions
629
+ - 66962ed: fix(packages): export node10 compatible types
630
+ - 9301f86: refactor (image-model): rename `ImageModelV1` to `ImageModelV2`
631
+ - 7df7a25: feat (providers/openai): support gpt-image-1 image generation
632
+ - Updated dependencies [66962ed]
633
+ - Updated dependencies [9301f86]
634
+ - Updated dependencies [a3f768e]
635
+ - @ai-sdk/provider-utils@3.0.0-canary.11
636
+ - @ai-sdk/provider@2.0.0-canary.10
637
+
638
+ ## 2.0.0-canary.11
639
+
640
+ ### Patch Changes
641
+
642
+ - 8493141: feat (providers/openai): add support for reasoning summaries
643
+ - Updated dependencies [e86be6f]
644
+ - @ai-sdk/provider@2.0.0-canary.9
645
+ - @ai-sdk/provider-utils@3.0.0-canary.10
646
+
647
+ ## 2.0.0-canary.10
648
+
649
+ ### Patch Changes
650
+
651
+ - 3bd3c0b: chore(providers/openai): update embedding model to use providerOptions
652
+ - Updated dependencies [95857aa]
653
+ - Updated dependencies [7ea4132]
654
+ - @ai-sdk/provider@2.0.0-canary.8
655
+ - @ai-sdk/provider-utils@3.0.0-canary.9
656
+
657
+ ## 2.0.0-canary.9
658
+
659
+ ### Patch Changes
660
+
661
+ - d63bcbc: feat (provider/openai): o4 updates for responses api
662
+ - d2af019: feat (providers/openai): add gpt-4.1 models
663
+ - 870c5c0: feat (providers/openai): add o3 and o4-mini models
664
+ - 06bac05: fix (openai): structure output for responses model
665
+
3
666
  ## 2.0.0-canary.8
4
667
 
5
668
  ### Patch Changes
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # AI SDK - OpenAI Provider
2
2
 
3
- The **[OpenAI provider](https://sdk.vercel.ai/providers/ai-sdk-providers/openai)** for the [AI SDK](https://sdk.vercel.ai/docs)
3
+ The **[OpenAI provider](https://ai-sdk.dev/providers/ai-sdk-providers/openai)** for the [AI SDK](https://ai-sdk.dev/docs)
4
4
  contains language model support for the OpenAI chat and completion APIs and embedding model support for the OpenAI embeddings API.
5
5
 
6
6
  ## Setup
@@ -33,4 +33,4 @@ const { text } = await generateText({
33
33
 
34
34
  ## Documentation
35
35
 
36
- Please check out the **[OpenAI provider documentation](https://sdk.vercel.ai/providers/ai-sdk-providers/openai)** for more information.
36
+ Please check out the **[OpenAI provider documentation](https://ai-sdk.dev/providers/ai-sdk-providers/openai)** for more information.