@ai-sdk/ui-utils
Advanced tools
Comparing version 1.1.10 to 1.1.11
# @ai-sdk/ui-utils | ||
## 1.1.11 | ||
### Patch Changes | ||
- 318b351: fix (ui): update ui before automatic client-side tool call is executed | ||
## 1.1.10 | ||
@@ -4,0 +10,0 @@ |
@@ -179,2 +179,14 @@ "use strict"; | ||
// src/duplicated/usage.ts | ||
function calculateLanguageModelUsage({ | ||
promptTokens, | ||
completionTokens | ||
}) { | ||
return { | ||
promptTokens, | ||
completionTokens, | ||
totalTokens: promptTokens + completionTokens | ||
}; | ||
} | ||
// src/parse-partial-json.ts | ||
@@ -856,14 +868,2 @@ var import_provider_utils = require("@ai-sdk/provider-utils"); | ||
// src/duplicated/usage.ts | ||
function calculateLanguageModelUsage({ | ||
promptTokens, | ||
completionTokens | ||
}) { | ||
return { | ||
promptTokens, | ||
completionTokens, | ||
totalTokens: promptTokens + completionTokens | ||
}; | ||
} | ||
// src/process-chat-response.ts | ||
@@ -1019,2 +1019,3 @@ async function processChatResponse({ | ||
updateToolInvocationPart(value.toolCallId, invocation); | ||
execUpdate(); | ||
if (onToolCall) { | ||
@@ -1031,5 +1032,5 @@ const result = await onToolCall({ toolCall: value }); | ||
updateToolInvocationPart(value.toolCallId, invocation2); | ||
execUpdate(); | ||
} | ||
} | ||
execUpdate(); | ||
}, | ||
@@ -1036,0 +1037,0 @@ onToolResultPart(value) { |
{ | ||
"name": "@ai-sdk/ui-utils", | ||
"version": "1.1.10", | ||
"version": "1.1.11", | ||
"license": "Apache-2.0", | ||
@@ -5,0 +5,0 @@ "sideEffects": false, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
387338
4218