ai 5.0.197 → 5.0.198
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 +6 -0
- package/dist/index.js +11 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11 -6
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +1 -1
- package/dist/internal/index.mjs +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -778,7 +778,7 @@ function detectMediaType({
|
|
|
778
778
|
var import_provider_utils2 = require("@ai-sdk/provider-utils");
|
|
779
779
|
|
|
780
780
|
// src/version.ts
|
|
781
|
-
var VERSION = true ? "5.0.
|
|
781
|
+
var VERSION = true ? "5.0.198" : "0.0.0-test";
|
|
782
782
|
|
|
783
783
|
// src/util/download/download.ts
|
|
784
784
|
var download = async ({
|
|
@@ -3145,6 +3145,11 @@ function isDataUIMessageChunk(chunk) {
|
|
|
3145
3145
|
return chunk.type.startsWith("data-");
|
|
3146
3146
|
}
|
|
3147
3147
|
|
|
3148
|
+
// src/util/create-id-map.ts
|
|
3149
|
+
function createIdMap() {
|
|
3150
|
+
return /* @__PURE__ */ Object.create(null);
|
|
3151
|
+
}
|
|
3152
|
+
|
|
3148
3153
|
// src/util/merge-objects.ts
|
|
3149
3154
|
function mergeObjects(base, overrides) {
|
|
3150
3155
|
if (base === void 0 && overrides === void 0) {
|
|
@@ -3559,9 +3564,9 @@ function createStreamingUIMessageState({
|
|
|
3559
3564
|
role: "assistant",
|
|
3560
3565
|
parts: []
|
|
3561
3566
|
},
|
|
3562
|
-
activeTextParts:
|
|
3563
|
-
activeReasoningParts:
|
|
3564
|
-
partialToolCalls:
|
|
3567
|
+
activeTextParts: createIdMap(),
|
|
3568
|
+
activeReasoningParts: createIdMap(),
|
|
3569
|
+
partialToolCalls: createIdMap()
|
|
3565
3570
|
};
|
|
3566
3571
|
}
|
|
3567
3572
|
function processUIMessageStream({
|
|
@@ -3937,8 +3942,8 @@ function processUIMessageStream({
|
|
|
3937
3942
|
break;
|
|
3938
3943
|
}
|
|
3939
3944
|
case "finish-step": {
|
|
3940
|
-
state.activeTextParts =
|
|
3941
|
-
state.activeReasoningParts =
|
|
3945
|
+
state.activeTextParts = createIdMap();
|
|
3946
|
+
state.activeReasoningParts = createIdMap();
|
|
3942
3947
|
break;
|
|
3943
3948
|
}
|
|
3944
3949
|
case "start": {
|