ai 6.0.241 → 6.0.243

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.
@@ -164,7 +164,7 @@ function detectMediaType({
164
164
  var import_provider_utils2 = require("@ai-sdk/provider-utils");
165
165
 
166
166
  // src/version.ts
167
- var VERSION = true ? "6.0.241" : "0.0.0-test";
167
+ var VERSION = true ? "6.0.243" : "0.0.0-test";
168
168
 
169
169
  // src/util/download/download.ts
170
170
  var download = async ({
@@ -144,7 +144,7 @@ import {
144
144
  } from "@ai-sdk/provider-utils";
145
145
 
146
146
  // src/version.ts
147
- var VERSION = true ? "6.0.241" : "0.0.0-test";
147
+ var VERSION = true ? "6.0.243" : "0.0.0-test";
148
148
 
149
149
  // src/util/download/download.ts
150
150
  var download = async ({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai",
3
- "version": "6.0.241",
3
+ "version": "6.0.243",
4
4
  "description": "AI SDK by Vercel - build apps like ChatGPT, Claude, Gemini, and more with a single interface for any model using the Vercel AI Gateway or go direct to OpenAI, Anthropic, Google, or any other model provider.",
5
5
  "license": "Apache-2.0",
6
6
  "sideEffects": false,
@@ -45,7 +45,7 @@
45
45
  },
46
46
  "dependencies": {
47
47
  "@opentelemetry/api": "^1.9.0",
48
- "@ai-sdk/gateway": "3.0.163",
48
+ "@ai-sdk/gateway": "3.0.165",
49
49
  "@ai-sdk/provider": "3.0.14",
50
50
  "@ai-sdk/provider-utils": "4.0.41"
51
51
  },
@@ -477,14 +477,10 @@ export async function safeValidateUIMessages<UI_MESSAGE extends UIMessage>({
477
477
  }
478
478
 
479
479
  // Tool input validation
480
- // Note: input is intentionally not re-validated for `output-error`
481
- // states. A tool call that failed with an invalid-input error keeps
482
- // its (invalid) input, and re-validating it on replay would throw a
483
- // TypeValidationError that crashes follow-up messages.
484
- if (
485
- toolPart.state === 'input-available' ||
486
- toolPart.state === 'output-available'
487
- ) {
480
+ // Note: input is intentionally not re-validated for terminal states.
481
+ // Terminal tool calls can keep invalid or incomplete input, and
482
+ // re-validating it on replay would crash follow-up messages.
483
+ if (toolPart.state === 'input-available') {
488
484
  await validateTypes({
489
485
  value: toolPart.input,
490
486
  schema: tool.inputSchema,