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/dist/index.mjs
CHANGED
|
@@ -687,7 +687,7 @@ import {
|
|
|
687
687
|
} from "@ai-sdk/provider-utils";
|
|
688
688
|
|
|
689
689
|
// src/version.ts
|
|
690
|
-
var VERSION = true ? "5.0.
|
|
690
|
+
var VERSION = true ? "5.0.198" : "0.0.0-test";
|
|
691
691
|
|
|
692
692
|
// src/util/download/download.ts
|
|
693
693
|
var download = async ({
|
|
@@ -3076,6 +3076,11 @@ function isDataUIMessageChunk(chunk) {
|
|
|
3076
3076
|
return chunk.type.startsWith("data-");
|
|
3077
3077
|
}
|
|
3078
3078
|
|
|
3079
|
+
// src/util/create-id-map.ts
|
|
3080
|
+
function createIdMap() {
|
|
3081
|
+
return /* @__PURE__ */ Object.create(null);
|
|
3082
|
+
}
|
|
3083
|
+
|
|
3079
3084
|
// src/util/merge-objects.ts
|
|
3080
3085
|
function mergeObjects(base, overrides) {
|
|
3081
3086
|
if (base === void 0 && overrides === void 0) {
|
|
@@ -3490,9 +3495,9 @@ function createStreamingUIMessageState({
|
|
|
3490
3495
|
role: "assistant",
|
|
3491
3496
|
parts: []
|
|
3492
3497
|
},
|
|
3493
|
-
activeTextParts:
|
|
3494
|
-
activeReasoningParts:
|
|
3495
|
-
partialToolCalls:
|
|
3498
|
+
activeTextParts: createIdMap(),
|
|
3499
|
+
activeReasoningParts: createIdMap(),
|
|
3500
|
+
partialToolCalls: createIdMap()
|
|
3496
3501
|
};
|
|
3497
3502
|
}
|
|
3498
3503
|
function processUIMessageStream({
|
|
@@ -3868,8 +3873,8 @@ function processUIMessageStream({
|
|
|
3868
3873
|
break;
|
|
3869
3874
|
}
|
|
3870
3875
|
case "finish-step": {
|
|
3871
|
-
state.activeTextParts =
|
|
3872
|
-
state.activeReasoningParts =
|
|
3876
|
+
state.activeTextParts = createIdMap();
|
|
3877
|
+
state.activeReasoningParts = createIdMap();
|
|
3873
3878
|
break;
|
|
3874
3879
|
}
|
|
3875
3880
|
case "start": {
|