ai 4.3.16 → 5.0.0-alpha.10

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.
Files changed (53) hide show
  1. package/CHANGELOG.md +517 -66
  2. package/README.md +1 -1
  3. package/dist/index.d.mts +2760 -2640
  4. package/dist/index.d.ts +2760 -2640
  5. package/dist/index.js +4666 -4330
  6. package/dist/index.js.map +1 -1
  7. package/dist/index.mjs +4631 -4287
  8. package/dist/index.mjs.map +1 -1
  9. package/dist/internal/index.d.mts +468 -0
  10. package/dist/internal/index.d.ts +468 -0
  11. package/dist/internal/index.js +957 -0
  12. package/dist/internal/index.js.map +1 -0
  13. package/dist/internal/index.mjs +930 -0
  14. package/dist/internal/index.mjs.map +1 -0
  15. package/{mcp-stdio/dist → dist/mcp-stdio}/index.d.mts +14 -14
  16. package/{mcp-stdio/dist → dist/mcp-stdio}/index.d.ts +14 -14
  17. package/{mcp-stdio/dist → dist/mcp-stdio}/index.js +1 -4
  18. package/dist/mcp-stdio/index.js.map +1 -0
  19. package/{mcp-stdio/dist → dist/mcp-stdio}/index.mjs +1 -16
  20. package/dist/mcp-stdio/index.mjs.map +1 -0
  21. package/dist/test/index.d.mts +64 -0
  22. package/dist/test/index.d.ts +64 -0
  23. package/{test/dist → dist/test}/index.js +43 -20
  24. package/dist/test/index.js.map +1 -0
  25. package/{test/dist → dist/test}/index.mjs +41 -18
  26. package/dist/test/index.mjs.map +1 -0
  27. package/internal.d.ts +1 -0
  28. package/mcp-stdio.d.ts +1 -0
  29. package/package.json +34 -59
  30. package/test.d.ts +1 -0
  31. package/mcp-stdio/dist/index.js.map +0 -1
  32. package/mcp-stdio/dist/index.mjs.map +0 -1
  33. package/react/dist/index.d.mts +0 -22
  34. package/react/dist/index.d.ts +0 -22
  35. package/react/dist/index.js +0 -42
  36. package/react/dist/index.js.map +0 -1
  37. package/react/dist/index.mjs +0 -20
  38. package/react/dist/index.mjs.map +0 -1
  39. package/rsc/dist/index.d.ts +0 -813
  40. package/rsc/dist/index.mjs +0 -18
  41. package/rsc/dist/rsc-client.d.mts +0 -1
  42. package/rsc/dist/rsc-client.mjs +0 -18
  43. package/rsc/dist/rsc-client.mjs.map +0 -1
  44. package/rsc/dist/rsc-server.d.mts +0 -748
  45. package/rsc/dist/rsc-server.mjs +0 -2174
  46. package/rsc/dist/rsc-server.mjs.map +0 -1
  47. package/rsc/dist/rsc-shared.d.mts +0 -101
  48. package/rsc/dist/rsc-shared.mjs +0 -308
  49. package/rsc/dist/rsc-shared.mjs.map +0 -1
  50. package/test/dist/index.d.mts +0 -65
  51. package/test/dist/index.d.ts +0 -65
  52. package/test/dist/index.js.map +0 -1
  53. package/test/dist/index.mjs.map +0 -1
package/CHANGELOG.md CHANGED
@@ -1,145 +1,596 @@
1
1
  # ai
2
2
 
3
- ## 4.3.16
3
+ ## 5.0.0-alpha.10
4
+
5
+ ### Major Changes
6
+
7
+ - 98f25e5: chore (ui): remove managed chat inputs
8
+ - 7bb58d4: chore (ai): restructure prepareRequest
9
+
10
+ ### Patch Changes
11
+
12
+ - Updated dependencies [c4df419]
13
+ - @ai-sdk/provider@2.0.0-alpha.10
14
+ - @ai-sdk/gateway@1.0.0-alpha.10
15
+ - @ai-sdk/provider-utils@3.0.0-alpha.10
16
+
17
+ ## 5.0.0-alpha.9
18
+
19
+ ### Major Changes
20
+
21
+ - 9ae327d: chore (ui): replace chat store concept with chat instances
22
+
23
+ ### Patch Changes
24
+
25
+ - 8255639: ### Fix use with Google APIs + zod v4's `.literal()` schema
26
+
27
+ Before [zod@3.25.49](https://github.com/colinhacks/zod/releases/tag/v3.25.49), requests to Google's APIs failed due to a missing `type` in the provided schema. The problem has been resolved for the `ai` SDK by bumping our `zod` peer dependencies to `^3.25.49`.
28
+
29
+ pull request: https://github.com/vercel/ai/pull/6609
30
+
31
+ - Updated dependencies [26b6dd0]
32
+ - Updated dependencies [811dff3]
33
+ - @ai-sdk/gateway@1.0.0-alpha.9
34
+ - @ai-sdk/provider@2.0.0-alpha.9
35
+ - @ai-sdk/provider-utils@3.0.0-alpha.9
36
+
37
+ ## 5.0.0-alpha.8
38
+
39
+ ### Major Changes
40
+
41
+ - c25cbce: feat (ai): use console.error as default error handler for streamText and streamObject
42
+
43
+ ### Patch Changes
44
+
45
+ - 4fef487: feat: support for zod v4 for schema validation
46
+
47
+ All these methods now accept both a zod v4 and zod v3 schemas for validation:
48
+
49
+ - `generateObject()`
50
+ - `streamObject()`
51
+ - `generateText()`
52
+ - `experimental_useObject()` from `@ai-sdk/react`
53
+ - `streamUI()` from `@ai-sdk/rsc`
54
+
55
+ - 6b1c55c: feat (ai): introduce GLOBAL_DEFAULT_PROVIDER
56
+ - 2e4f9e4: feat (ai): improved error messages when using gateway
57
+ - Updated dependencies [4fef487]
58
+ - Updated dependencies [9222aeb]
59
+ - Updated dependencies [3cbcbb7]
60
+ - Updated dependencies [989ac75]
61
+ - Updated dependencies [7742ba3]
62
+ - @ai-sdk/provider-utils@3.0.0-alpha.8
63
+ - @ai-sdk/provider@2.0.0-alpha.8
64
+ - @ai-sdk/gateway@1.0.0-alpha.8
65
+
66
+ ## 5.0.0-alpha.7
67
+
68
+ ### Major Changes
69
+
70
+ - db345da: chore (ai): remove exports of internal ui functions
71
+ - 247ee0c: chore (ai): remove steps from tool invocation ui parts
72
+
73
+ ### Patch Changes
74
+
75
+ - 9b0da33: fix (ai): do not send id with start unless specified
76
+ - Updated dependencies [5c56081]
77
+ - @ai-sdk/provider@2.0.0-alpha.7
78
+ - @ai-sdk/gateway@1.0.0-alpha.7
79
+ - @ai-sdk/provider-utils@3.0.0-alpha.7
80
+
81
+ ## 5.0.0-alpha.6
82
+
83
+ ### Patch Changes
84
+
85
+ - 0d2c085: feat (ai): support string model ids through gateway
86
+ - 48a7606: feat (ai): support changing the system prompt in prepareSteps
87
+ - Updated dependencies [0d2c085]
88
+ - Updated dependencies [6c2c708]
89
+ - @ai-sdk/provider@2.0.0-alpha.6
90
+ - @ai-sdk/gateway@1.0.0-alpha.6
91
+ - @ai-sdk/provider-utils@3.0.0-alpha.6
92
+
93
+ ## 5.0.0-alpha.5
94
+
95
+ ### Major Changes
96
+
97
+ - ef256ed: chore (ai): refactor and use chatstore in svelte
98
+ - 1ed0287: chore (ai): stable sendStart/sendFinish options
99
+
100
+ ### Patch Changes
101
+
102
+ - 655cf3c: feat (ui): add onFinish to createUIMessageStream
103
+ - 1675396: fix: avoid job executor deadlock when adding tool result
104
+ - cf9af6e: feat (ai): allow sync prepareStep
105
+ - 825e8d7: release alpha.5
106
+ - 7324c21: fix (ai/telemetry): Avoid JSON.stringify on Uint8Arrays for telemetry
107
+
108
+ ## 5.0.0-alpha.4
109
+
110
+ ### Major Changes
111
+
112
+ - 72d7d72: chore (ai): stable activeTools
113
+ - 9315076: chore (ai): rename continueUntil to stopWhen. Rename maxSteps stop condition to stepCountIs.
114
+
115
+ ### Patch Changes
116
+
117
+ - b32c141: feat (ai): add array support to stopWhen
118
+ - 7d97ab6: release alpha.4
119
+ - 37a916d: feat (ai): add prepareSteps to streamText
120
+ - 5f2b3d4: chore (ai): stable prepareStep
121
+ - Updated dependencies [dc714f3]
122
+ - @ai-sdk/provider@2.0.0-alpha.4
123
+ - @ai-sdk/provider-utils@3.0.0-alpha.4
124
+
125
+ ## 5.0.0-alpha.3
126
+
127
+ ### Major Changes
128
+
129
+ - ab7ccef: chore (ai): change source ui message parts to source-url
130
+ - 257224b: chore (ai): separate TextStreamChatTransport
131
+ - 0463011: fix (ai): update source url stream part
132
+ - d306260: feat (ai): replace maxSteps with continueUntil (streamText)
133
+
134
+ ### Patch Changes
135
+
136
+ - Updated dependencies [6b98118]
137
+ - @ai-sdk/provider@2.0.0-alpha.3
138
+ - @ai-sdk/provider-utils@3.0.0-alpha.3
139
+
140
+ ## 5.0.0-alpha.2
141
+
142
+ ### Patch Changes
143
+
144
+ - 82aa95d: fix (ai): merge data ui stream parts correctly
145
+ - Updated dependencies [26535e0]
146
+ - @ai-sdk/provider@2.0.0-alpha.2
147
+ - @ai-sdk/provider-utils@3.0.0-alpha.2
148
+
149
+ ## 5.0.0-alpha.1
150
+
151
+ ### Major Changes
152
+
153
+ - 109c0ac: chore (ai): rename id to chatId (in post request, resume request, and useChat)
154
+
155
+ ### Patch Changes
156
+
157
+ - b346545: feat (ai): add data ui part schemas
158
+ - Updated dependencies [3f2f00c]
159
+ - @ai-sdk/provider@2.0.0-alpha.1
160
+ - @ai-sdk/provider-utils@3.0.0-alpha.1
161
+
162
+ ## 5.0.0-canary.24
163
+
164
+ ### Major Changes
165
+
166
+ - f7e8bf4: chore (ai): flatten ui message stream parts
167
+ - ed675de: feat (ai): add ui data parts
168
+ - 64f6d64: feat (ai): replace maxSteps with continueUntil (generateText)
169
+
170
+ ### Patch Changes
171
+
172
+ - bedb239: chore (ai): make ui stream parts value optional when it's not required
173
+ - 507ac1d: fix (ui/react): update messages immediately with the submitted user message
174
+ - 2b9bbcd: feat (ai): improve prompt validation error message
175
+ - cda32ba: fix (ai): send `start` part in correct position in stream (streamText)
176
+ - 50f0362: fix (ai): fix experimental sendStart/sendFinish options in streamText
177
+ - Updated dependencies [faf8446]
178
+ - @ai-sdk/provider-utils@3.0.0-canary.19
179
+
180
+ ## 5.0.0-canary.23
181
+
182
+ ### Major Changes
183
+
184
+ - 40acf9b: feat (ui): introduce ChatStore and ChatTransport
185
+
186
+ ### Patch Changes
187
+
188
+ - Updated dependencies [40acf9b]
189
+ - @ai-sdk/provider-utils@3.0.0-canary.18
190
+
191
+ ## 5.0.0-canary.22
192
+
193
+ ### Major Changes
194
+
195
+ - e7dc6c7: chore (ai): remove onResponse callback
196
+ - a34eb39: chore (ai): remove `data` and `allowEmptySubmit` from `ChatRequestOptions`
197
+ - b33ed7a: chore (ai): rename DataStream* to UIMessage*
198
+ - 765f1cd: chore (ai): remove deprecated useChat isLoading helper
199
+
200
+ ## 5.0.0-canary.21
201
+
202
+ ### Major Changes
203
+
204
+ - d964901: - remove setting temperature to `0` by default
205
+ - remove `null` option from `DefaultSettingsMiddleware`
206
+ - remove setting defaults for `temperature` and `stopSequences` in `ai` to enable middleware changes
207
+ - 0560977: chore (ai): improve consistency of generate text result, stream text result, and step result
208
+ - 516be5b: ### Move Image Model Settings into generate options
209
+
210
+ Image Models no longer have settings. Instead, `maxImagesPerCall` can be passed directly to `generateImage()`. All other image settings can be passed to `providerOptions[provider]`.
211
+
212
+ Before
213
+
214
+ ```js
215
+ await generateImage({
216
+ model: luma.image('photon-flash-1', {
217
+ maxImagesPerCall: 5,
218
+ pollIntervalMillis: 500,
219
+ }),
220
+ prompt,
221
+ n: 10,
222
+ });
223
+ ```
224
+
225
+ After
226
+
227
+ ```js
228
+ await generateImage({
229
+ model: luma.image('photon-flash-1'),
230
+ prompt,
231
+ n: 10,
232
+ maxImagesPerCall: 5,
233
+ providerOptions: {
234
+ luma: { pollIntervalMillis: 5 },
235
+ },
236
+ });
237
+ ```
238
+
239
+ Pull Request: https://github.com/vercel/ai/pull/6180
240
+
241
+ - bfbfc4c: feat (ai): streamText/generateText: totalUsage contains usage for all steps. usage is for a single step.
242
+ - ea7a7c9: feat (ui): UI message metadata
243
+ - 1409e13: chore (ai): remove experimental continueSteps
244
+
245
+ ### Patch Changes
246
+
247
+ - 66af894: fix (ai): respect content order in toResponseMessages
248
+ - Updated dependencies [ea7a7c9]
249
+ - @ai-sdk/provider-utils@3.0.0-canary.17
250
+
251
+ ## 5.0.0-canary.20
252
+
253
+ ### Major Changes
254
+
255
+ - 13fef90: chore (ai): remove automatic conversion of UI messages to model messages
256
+ - 496bbc1: chore (ui): inline/remove ChatRequest type
257
+ - da70d79: chore (ai): remove getUIText helper
258
+ - c7710a9: chore (ai): rename DataStreamToSSETransformStream to JsonToSseTransformStream
259
+ - 35fc02c: chore (ui): rename RequestOptions to CompletionRequestOptions
260
+ - b983b51: feat (ai): support model message array in prompt
261
+
262
+ ### Minor Changes
263
+
264
+ - bcea599: feat (ai): add content to generateText result
265
+ - 48d675a: feat (ai): add content to streamText result
266
+
267
+ ### Patch Changes
268
+
269
+ - e90d45d: chore (rsc): move HANGING_STREAM_WARNING_TIME constant into @ai-sdk/rsc package
270
+ - bc3109f: chore (ai): push stream-callbacks into langchain/llamaindex adapters
271
+ - Updated dependencies [87b828f]
272
+ - @ai-sdk/provider-utils@3.0.0-canary.16
273
+
274
+ ## 5.0.0-canary.19
275
+
276
+ ### Major Changes
277
+
278
+ - 2d03e19: chore (ai): remove StreamCallbacks.onCompletion
279
+ - 319b989: chore (ai): remove content from ui messages
280
+ - 441d042: chore (ui): data stream protocol v2 with SSEs
281
+ - dcc549b: remove StreamTextResult.mergeIntoDataStream method
282
+ rename DataStreamOptions.getErrorMessage to onError
283
+ add pipeTextStreamToResponse function
284
+ add createTextStreamResponse function
285
+ change createDataStreamResponse function to accept a DataStream and not a DataStreamWriter
286
+ change pipeDataStreamToResponse function to accept a DataStream and not a DataStreamWriter
287
+ change pipeDataStreamToResponse function to have a single parameter
288
+ - cb2b53a: chore (ai): refactor header preparation
289
+ - e244a78: chore (ai): remove StreamData and mergeStreams
290
+
291
+ ## 5.0.0-canary.18
292
+
293
+ ### Major Changes
294
+
295
+ - c60f895: chore (ai): remove useChat keepLastMessageOnError
296
+ - a662dea: chore (ai): remove sendExtraMessageFields
297
+
298
+ ### Patch Changes
299
+
300
+ - a571d6e: chore(provider-utils): move ToolResultContent to provider-utils
301
+ - 332167b: chore (ai): move maxSteps into UseChatOptions
302
+ - a8c8bd5: feat(embed-many): respect supportsParallelCalls & concurrency
303
+ - Updated dependencies [a571d6e]
304
+ - Updated dependencies [a8c8bd5]
305
+ - Updated dependencies [7979f7f]
306
+ - Updated dependencies [41fa418]
307
+ - @ai-sdk/provider-utils@3.0.0-canary.15
308
+ - @ai-sdk/provider@2.0.0-canary.14
309
+
310
+ ## 5.0.0-canary.17
311
+
312
+ ### Major Changes
313
+
314
+ - f04fb4a: chore (ai): replace useChat attachments with file ui parts
315
+ - fd1924b: chore (ai): remove redundant `mimeType` property
316
+ - fafc3f2: chore (ai): change file to parts to use urls instead of data
317
+ - 92cb0a2: chore (ai): rename CoreMessage to ModelMessage
318
+
319
+ ### Minor Changes
320
+
321
+ - c9ad635: feat (ai): add filename to file ui parts
4
322
 
5
323
  ### Patch Changes
6
324
 
7
- - ed0ebeb: Avoid JSON.strinfigy on UInt8Arrays for telemetry
325
+ - 9bd5ab5: feat (provider): add providerMetadata to ImageModelV2 interface (#5977)
326
+
327
+ The `experimental_generateImage` method from the `ai` package now returnes revised prompts for OpenAI's image models.
8
328
 
9
- ## 4.3.15
329
+ ```js
330
+ const prompt = 'Santa Claus driving a Cadillac';
331
+
332
+ const { providerMetadata } = await experimental_generateImage({
333
+ model: openai.image('dall-e-3'),
334
+ prompt,
335
+ });
336
+
337
+ const revisedPrompt = providerMetadata.openai.images[0]?.revisedPrompt;
338
+
339
+ console.log({
340
+ prompt,
341
+ revisedPrompt,
342
+ });
343
+ ```
344
+
345
+ - Updated dependencies [957b739]
346
+ - Updated dependencies [9bd5ab5]
347
+ - @ai-sdk/provider-utils@3.0.0-canary.14
348
+ - @ai-sdk/provider@2.0.0-canary.13
349
+
350
+ ## 5.0.0-canary.16
351
+
352
+ ### Major Changes
353
+
354
+ - ec78cdc: chore (ai): remove "data" UIMessage role
355
+ - 8b86e99: chore (ai): replace `Message` with `UIMessage`
356
+ - 2524fc7: chore (ai): remove ui message toolInvocations property
357
+ - 175b868: chore (ai): rename reasoning UI parts 'reasoning' property to 'text'
10
358
 
11
359
  ### Patch Changes
12
360
 
13
- - Updated dependencies [d87b9d1]
14
- - @ai-sdk/provider-utils@2.2.8
15
- - @ai-sdk/react@1.2.12
16
- - @ai-sdk/ui-utils@1.2.11
361
+ - 9b4d074: feat(streamObject): add enum support
362
+ - 28ad69e: fix(react-native): support experimental_attachments without FileList global
363
+ - ec5933d: chore (ai/mcp): add `assertCapability` method to experimental MCP client
17
364
 
18
- ## 4.3.14
365
+ ## 5.0.0-canary.15
366
+
367
+ ### Major Changes
368
+
369
+ - 4bfe9ec: chore (ai): remove ui message reasoning property
370
+ - 2877a74: chore (ai): remove ui message data property
19
371
 
20
372
  ### Patch Changes
21
373
 
22
- - a295521: feat(message-validator): include more details in error messages
374
+ - d9209ca: fix (image-model): `specificationVersion: v1` -> `v2`
375
+ - ea27cc6: chore (ai): use JSONValue definition from provider
376
+ - 0ff02bb: chore(provider-utils): move over jsonSchema
377
+ - Updated dependencies [7b3ae3f]
378
+ - Updated dependencies [0ff02bb]
379
+ - @ai-sdk/provider@2.0.0-canary.12
380
+ - @ai-sdk/provider-utils@3.0.0-canary.13
23
381
 
24
- ## 4.3.13
382
+ ## 5.0.0-canary.14
25
383
 
26
384
  ### Patch Changes
27
385
 
28
- - Updated dependencies [6c59ae7]
29
- - @ai-sdk/ui-utils@1.2.10
30
- - @ai-sdk/react@1.2.11
386
+ - 9bf7291: chore(providers/openai): enable structuredOutputs by default & switch to provider option
387
+ - 4617fab: chore(embedding-models): remove remaining settings
388
+ - a76a62b: feat (ai): add experimental prepareStep callback to generateText
389
+ - Updated dependencies [9bf7291]
390
+ - Updated dependencies [4617fab]
391
+ - Updated dependencies [e030615]
392
+ - @ai-sdk/provider@2.0.0-canary.11
393
+ - @ai-sdk/provider-utils@3.0.0-canary.12
31
394
 
32
- ## 4.3.12
395
+ ## 5.0.0-canary.13
33
396
 
34
397
  ### Patch Changes
35
398
 
36
- - 1ed3755: fix (ai): don't publish mcp-stdio TypeScript files
37
- - 46cb332: chore (ai/mcp): add `assertCapability` method to experimental MCP client
399
+ - 14cb3be: chore(providers/llamaindex): extract to separate package
400
+ - 66962ed: fix(packages): export node10 compatible types
401
+ - 9301f86: refactor (image-model): rename `ImageModelV1` to `ImageModelV2`
402
+ - Updated dependencies [66962ed]
403
+ - Updated dependencies [9301f86]
404
+ - Updated dependencies [a3f768e]
405
+ - @ai-sdk/provider-utils@3.0.0-canary.11
406
+ - @ai-sdk/provider@2.0.0-canary.10
38
407
 
39
- ## 4.3.11
408
+ ## 5.0.0-canary.12
40
409
 
41
410
  ### Patch Changes
42
411
 
43
- - Updated dependencies [77b2097]
44
- - Updated dependencies [62181ef]
45
- - @ai-sdk/react@1.2.10
46
- - @ai-sdk/ui-utils@1.2.9
412
+ - Updated dependencies [e86be6f]
413
+ - @ai-sdk/provider@2.0.0-canary.9
414
+ - @ai-sdk/provider-utils@3.0.0-canary.10
47
415
 
48
- ## 4.3.10
416
+ ## 5.0.0-canary.11
49
417
 
50
418
  ### Patch Changes
51
419
 
52
- - 0432959: feat (ai): add experimental prepareStep callback to generateText
420
+ - 8e64e9c: feat (ai): allow using provider default temperature by specifying null
421
+ - Updated dependencies [95857aa]
422
+ - Updated dependencies [7ea4132]
423
+ - @ai-sdk/provider@2.0.0-canary.8
424
+ - @ai-sdk/provider-utils@3.0.0-canary.9
53
425
 
54
- ## 4.3.9
426
+ ## 5.0.0-canary.10
55
427
 
56
428
  ### Patch Changes
57
429
 
58
- - b69a253: fix(utils/detect-mimetype): add support for detecting id3 tags
430
+ - d8aeaef: feat(providers/fal): add transcribe
431
+ - 3e10408: fix(utils/detect-mimetype): add support for detecting id3 tags
432
+
433
+ ## 5.0.0-canary.9
434
+
435
+ ### Major Changes
59
436
 
60
- ## 4.3.8
437
+ - a847c3e: chore: rename reasoning to reasoningText etc
438
+ - b32e192: chore (ai): rename reasoning to reasoningText, rename reasoningDetails to reasoning (streamText, generateText)
61
439
 
62
440
  ### Patch Changes
63
441
 
64
- - 6e8a73b: feat(providers/fal): add transcribe
442
+ - cb9c9e4: remove deprecated `experimental_wrapLanguageModel`
443
+ - 8aa9e20: feat: add speech with experimental_generateSpeech
444
+ - Updated dependencies [5d142ab]
445
+ - Updated dependencies [b6b43c7]
446
+ - Updated dependencies [8aa9e20]
447
+ - Updated dependencies [3795467]
448
+ - @ai-sdk/provider-utils@3.0.0-canary.8
449
+ - @ai-sdk/provider@2.0.0-canary.7
65
450
 
66
- ## 4.3.7
451
+ ## 5.0.0-canary.8
452
+
453
+ ### Major Changes
454
+
455
+ - 14c9410: chore: refactor file towards source pattern (spec)
67
456
 
68
457
  ### Patch Changes
69
458
 
70
- - f4f3945: fix (ai/core): refactor `toResponseMessages` to filter out empty string/content
459
+ - 5d1e3ba: chore (ai): remove provider re-exports
460
+ - 26735b5: chore(embedding-model): add v2 interface
461
+ - 7827a49: fix (ai/core): refactor `toResponseMessages` to filter out empty string/content
462
+ - bd8a36c: feat(embedding-model-v2/embedMany): add response body field
463
+ - b6f9f3c: remove deprecated `CoreTool*` types
464
+ - 92c8e66: fix(ai/core): properly handle custom separator in provider registry
465
+ - fd65bc6: chore(embedding-model-v2): rename rawResponse to response
466
+ - 5bdff05: Removed deprecated `options.throwErrorForEmptyVectors` from `cosineSimilarity()`. Since `throwErrorForEmptyVectors` was the only option the entire `options` argument was removed.
467
+
468
+ ```diff
469
+ - cosineSimilarity(vector1, vector2, options)
470
+ +cosineSimilarity(vector1, vector2)
471
+ ```
71
472
 
72
- ## 4.3.6
473
+ - Updated dependencies [26735b5]
474
+ - Updated dependencies [443d8ec]
475
+ - Updated dependencies [14c9410]
476
+ - Updated dependencies [d9c98f4]
477
+ - Updated dependencies [c4a2fec]
478
+ - Updated dependencies [0054544]
479
+ - Updated dependencies [9e9c809]
480
+ - Updated dependencies [32831c6]
481
+ - Updated dependencies [d0f9495]
482
+ - Updated dependencies [fd65bc6]
483
+ - Updated dependencies [393138b]
484
+ - Updated dependencies [7182d14]
485
+ - @ai-sdk/provider@2.0.0-canary.6
486
+ - @ai-sdk/provider-utils@3.0.0-canary.7
487
+
488
+ ## 5.0.0-canary.7
489
+
490
+ ### Major Changes
491
+
492
+ - 6fba4c7: chore (ai): remove deprecated experimental_providerMetadata
493
+ - 1766ede: chore: rename maxTokens to maxOutputTokens
73
494
 
74
495
  ### Patch Changes
75
496
 
76
- - beef951: feat: add speech with experimental_generateSpeech
77
- - bd41167: fix(ai/core): properly handle custom separator in provider registry
78
- - Updated dependencies [beef951]
79
- - @ai-sdk/provider@1.1.3
80
- - @ai-sdk/provider-utils@2.2.7
81
- - @ai-sdk/ui-utils@1.2.8
82
- - @ai-sdk/react@1.2.9
497
+ - 0b78e17: chore(ai/generateObject): simplify function signature
498
+ - 3e3b9df: fix (ai/mcp): better support for zero-argument MCP tools
499
+ - f10304b: feat(tool-calling): don't require the user to have to pass parameters
500
+ - Updated dependencies [411e483]
501
+ - Updated dependencies [79457bd]
502
+ - Updated dependencies [ad80501]
503
+ - Updated dependencies [1766ede]
504
+ - Updated dependencies [f10304b]
505
+ - @ai-sdk/provider@2.0.0-canary.5
506
+ - @ai-sdk/provider-utils@3.0.0-canary.6
83
507
 
84
- ## 4.3.5
508
+ ## 5.0.0-canary.6
85
509
 
86
510
  ### Patch Changes
87
511
 
88
- - 452bf12: fix (ai/mcp): better support for zero-argument MCP tools
512
+ - Updated dependencies [6f6bb89]
513
+ - @ai-sdk/provider@2.0.0-canary.4
514
+ - @ai-sdk/provider-utils@3.0.0-canary.5
89
515
 
90
- ## 4.3.4
516
+ ## 5.0.0-canary.5
91
517
 
92
518
  ### Patch Changes
93
519
 
94
- - 013faa8: core (ai): change transcription model mimeType to mediaType
95
- - Updated dependencies [013faa8]
96
- - @ai-sdk/provider@1.1.2
97
- - @ai-sdk/provider-utils@2.2.6
98
- - @ai-sdk/ui-utils@1.2.7
99
- - @ai-sdk/react@1.2.8
520
+ - b71fe8d: fix(ai): remove jsondiffpatch dependency
521
+ - d91b50d: chore(ui-utils): merge into ai package
522
+ - Updated dependencies [d1a1aa1]
523
+ - @ai-sdk/provider@2.0.0-canary.3
524
+ - @ai-sdk/provider-utils@3.0.0-canary.4
100
525
 
101
- ## 4.3.3
526
+ ## 5.0.0-canary.4
527
+
528
+ ### Major Changes
529
+
530
+ - e1cbf8a: chore(@ai-sdk/rsc): extract to separate package
102
531
 
103
532
  ### Patch Changes
104
533
 
105
- - 3e88f4d: fix (ai/mcp): prevent mutation of customEnv
106
- - c21fa6d: feat: add transcription with experimental_transcribe
107
- - Updated dependencies [c21fa6d]
108
- - @ai-sdk/provider-utils@2.2.5
109
- - @ai-sdk/provider@1.1.1
110
- - @ai-sdk/react@1.2.7
111
- - @ai-sdk/ui-utils@1.2.6
534
+ - 225f087: fix (ai/mcp): prevent mutation of customEnv
535
+ - a166433: feat: add transcription with experimental_transcribe
536
+ - 0a87932: core (ai): change transcription model mimeType to mediaType
537
+ - Updated dependencies [a166433]
538
+ - Updated dependencies [abf9a79]
539
+ - Updated dependencies [9f95b35]
540
+ - Updated dependencies [0a87932]
541
+ - Updated dependencies [6dc848c]
542
+ - @ai-sdk/provider-utils@3.0.0-canary.3
543
+ - @ai-sdk/provider@2.0.0-canary.2
544
+ - @ai-sdk/ui-utils@2.0.0-canary.3
112
545
 
113
- ## 4.3.2
546
+ ## 5.0.0-canary.3
114
547
 
115
548
  ### Patch Changes
116
549
 
117
- - 665a567: fix (core): improve error handling in streamText's consumeStream method
550
+ - Updated dependencies [c57e248]
551
+ - Updated dependencies [33f4a6a]
552
+ - @ai-sdk/provider@2.0.0-canary.1
553
+ - @ai-sdk/provider-utils@3.0.0-canary.2
554
+ - @ai-sdk/ui-utils@2.0.0-canary.2
118
555
 
119
- ## 4.3.1
556
+ ## 5.0.0-canary.2
120
557
 
121
558
  ### Patch Changes
122
559
 
123
- - 3d1bd38: feat(smooth-stream): chunking callbacks
560
+ - bd398e4: fix (core): improve error handling in streamText's consumeStream method
124
561
 
125
- ## 4.3.0
562
+ ## 5.0.0-canary.1
126
563
 
127
564
  ### Minor Changes
128
565
 
129
- - 772a2d7: feat (core): Add finishReason field to NoObjectGeneratedError
566
+ - b7eae2d: feat (core): Add finishReason field to NoObjectGeneratedError
130
567
 
131
568
  ### Patch Changes
132
569
 
133
- - Updated dependencies [2c19b9a]
134
- - @ai-sdk/provider-utils@2.2.4
135
- - @ai-sdk/react@1.2.6
136
- - @ai-sdk/ui-utils@1.2.5
570
+ - c22ad54: feat(smooth-stream): chunking callbacks
571
+ - a4f3007: chore: remove ai/react
572
+ - Updated dependencies [060370c]
573
+ - Updated dependencies [0c0c0b3]
574
+ - Updated dependencies [63d791d]
575
+ - @ai-sdk/provider-utils@3.0.0-canary.1
576
+ - @ai-sdk/ui-utils@2.0.0-canary.1
577
+
578
+ ## 5.0.0-canary.0
579
+
580
+ ### Major Changes
137
581
 
138
- ## 4.2.11
582
+ - d5f588f: AI SDK 5
583
+ - 9477ebb: chore (ui): remove useAssistant hook (**breaking change**)
139
584
 
140
585
  ### Patch Changes
141
586
 
142
- - c45d100: fix (core): send buffered text in smooth stream when stream parts change
587
+ - 8026705: fix (core): send buffered text in smooth stream when stream parts change
588
+ - Updated dependencies [d5f588f]
589
+ - Updated dependencies [9477ebb]
590
+ - @ai-sdk/provider-utils@3.0.0-canary.0
591
+ - @ai-sdk/ui-utils@2.0.0-canary.0
592
+ - @ai-sdk/react@2.0.0-canary.0
593
+ - @ai-sdk/provider@2.0.0-canary.0
143
594
 
144
595
  ## 4.2.10
145
596
 
package/README.md CHANGED
@@ -106,7 +106,7 @@ export async function POST(req: Request) {
106
106
  messages,
107
107
  });
108
108
 
109
- return result.toDataStreamResponse();
109
+ return result.toUIMessageStreamResponse();
110
110
  }
111
111
  ```
112
112