@ai-sdk/google 3.0.139 → 3.0.140

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/dist/index.mjs CHANGED
@@ -238,7 +238,7 @@ import {
238
238
  } from "@ai-sdk/provider-utils";
239
239
 
240
240
  // src/version.ts
241
- var VERSION = true ? "3.0.139" : "0.0.0-test";
241
+ var VERSION = true ? "3.0.140" : "0.0.0-test";
242
242
 
243
243
  // src/google-generative-ai-embedding-model.ts
244
244
  import {
@@ -485,7 +485,7 @@ import {
485
485
  resolve as resolve3,
486
486
  zodSchema as zodSchema7
487
487
  } from "@ai-sdk/provider-utils";
488
- import { z as z7 } from "zod/v4";
488
+ import { z as z8 } from "zod/v4";
489
489
 
490
490
  // src/continue-google-stream.ts
491
491
  function continueGoogleStream({
@@ -916,6 +916,19 @@ import {
916
916
  isUrlSupported,
917
917
  secureJsonParse
918
918
  } from "@ai-sdk/provider-utils";
919
+
920
+ // src/google-generative-ai-prompt.ts
921
+ import { z as z6 } from "zod/v4";
922
+ var googleVideoMetadataSchema = z6.object({
923
+ /** Start offset as a duration in seconds, e.g. `'3.5s'`. */
924
+ startOffset: z6.string().optional(),
925
+ /** End offset as a duration in seconds, e.g. `'10s'`. */
926
+ endOffset: z6.string().optional(),
927
+ /** Frames per second in the range (0, 24]. Defaults to 1. */
928
+ fps: z6.number().gt(0).max(24).optional()
929
+ });
930
+
931
+ // src/convert-to-google-generative-ai-messages.ts
919
932
  var SKIP_THOUGHT_SIGNATURE_VALIDATOR = "skip_thought_signature_validator";
920
933
  function getGoogleProviderOptions(providerOptions, providerOptionsName) {
921
934
  const namespaces = [
@@ -1054,7 +1067,7 @@ function appendLegacyToolResultParts(parts, toolName, outputValue, toolCallId, i
1054
1067
  }
1055
1068
  }
1056
1069
  function convertToGoogleGenerativeAIMessages(prompt, options) {
1057
- var _a2, _b, _c, _d, _e, _f, _g;
1070
+ var _a2, _b, _c, _d, _e, _f, _g, _h;
1058
1071
  const systemInstructionParts = [];
1059
1072
  const contents = [];
1060
1073
  let systemMessagesAllowed = true;
@@ -1094,17 +1107,24 @@ function convertToGoogleGenerativeAIMessages(prompt, options) {
1094
1107
  }
1095
1108
  case "file": {
1096
1109
  const mediaType = part.mediaType === "image/*" ? "image/jpeg" : part.mediaType;
1110
+ const rawVideoMetadata = (_g = getGoogleProviderOptions(
1111
+ part.providerOptions,
1112
+ providerOptionsName
1113
+ )) == null ? void 0 : _g.videoMetadata;
1114
+ const videoMetadata = rawVideoMetadata == null ? void 0 : googleVideoMetadataSchema.parse(rawVideoMetadata);
1097
1115
  parts.push(
1098
1116
  part.data instanceof URL ? {
1099
1117
  fileData: {
1100
1118
  mimeType: mediaType,
1101
1119
  fileUri: part.data.protocol === "gs:" && part.originalUrl != null ? part.originalUrl : part.data.toString()
1102
- }
1120
+ },
1121
+ ...videoMetadata != null ? { videoMetadata } : {}
1103
1122
  } : {
1104
1123
  inlineData: {
1105
1124
  mimeType: mediaType,
1106
1125
  data: convertToBase642(part.data)
1107
- }
1126
+ },
1127
+ ...videoMetadata != null ? { videoMetadata } : {}
1108
1128
  }
1109
1129
  );
1110
1130
  break;
@@ -1265,7 +1285,7 @@ function convertToGoogleGenerativeAIMessages(prompt, options) {
1265
1285
  name: part.toolName,
1266
1286
  response: {
1267
1287
  name: part.toolName,
1268
- content: output.type === "execution-denied" ? (_g = output.reason) != null ? _g : "Tool call execution denied." : output.value
1288
+ content: output.type === "execution-denied" ? (_h = output.reason) != null ? _h : "Tool call execution denied." : output.value
1269
1289
  }
1270
1290
  }
1271
1291
  });
@@ -1376,23 +1396,23 @@ import {
1376
1396
  lazySchema as lazySchema6,
1377
1397
  zodSchema as zodSchema6
1378
1398
  } from "@ai-sdk/provider-utils";
1379
- import { z as z6 } from "zod/v4";
1399
+ import { z as z7 } from "zod/v4";
1380
1400
  var googleLanguageModelOptions = lazySchema6(
1381
1401
  () => zodSchema6(
1382
- z6.object({
1383
- responseModalities: z6.array(z6.enum(["TEXT", "IMAGE"])).optional(),
1384
- thinkingConfig: z6.object({
1385
- thinkingBudget: z6.number().optional(),
1386
- includeThoughts: z6.boolean().optional(),
1402
+ z7.object({
1403
+ responseModalities: z7.array(z7.enum(["TEXT", "IMAGE"])).optional(),
1404
+ thinkingConfig: z7.object({
1405
+ thinkingBudget: z7.number().optional(),
1406
+ includeThoughts: z7.boolean().optional(),
1387
1407
  // https://ai.google.dev/gemini-api/docs/gemini-3?thinking=high#thinking_level
1388
- thinkingLevel: z6.enum(["minimal", "low", "medium", "high"]).optional()
1408
+ thinkingLevel: z7.enum(["minimal", "low", "medium", "high"]).optional()
1389
1409
  }).optional(),
1390
1410
  /**
1391
1411
  * Optional.
1392
1412
  * The name of the cached content used as context to serve the prediction.
1393
1413
  * Format: cachedContents/{cachedContent}
1394
1414
  */
1395
- cachedContent: z6.string().optional(),
1415
+ cachedContent: z7.string().optional(),
1396
1416
  /**
1397
1417
  * Optional. Enable structured output. Default is true.
1398
1418
  *
@@ -1401,13 +1421,13 @@ var googleLanguageModelOptions = lazySchema6(
1401
1421
  * Google Generative AI uses. You can use this to disable
1402
1422
  * structured outputs if you need to.
1403
1423
  */
1404
- structuredOutputs: z6.boolean().optional(),
1424
+ structuredOutputs: z7.boolean().optional(),
1405
1425
  /**
1406
1426
  * Optional. A list of unique safety settings for blocking unsafe content.
1407
1427
  */
1408
- safetySettings: z6.array(
1409
- z6.object({
1410
- category: z6.enum([
1428
+ safetySettings: z7.array(
1429
+ z7.object({
1430
+ category: z7.enum([
1411
1431
  "HARM_CATEGORY_UNSPECIFIED",
1412
1432
  "HARM_CATEGORY_HATE_SPEECH",
1413
1433
  "HARM_CATEGORY_DANGEROUS_CONTENT",
@@ -1415,7 +1435,7 @@ var googleLanguageModelOptions = lazySchema6(
1415
1435
  "HARM_CATEGORY_SEXUALLY_EXPLICIT",
1416
1436
  "HARM_CATEGORY_CIVIC_INTEGRITY"
1417
1437
  ]),
1418
- threshold: z6.enum([
1438
+ threshold: z7.enum([
1419
1439
  "HARM_BLOCK_THRESHOLD_UNSPECIFIED",
1420
1440
  "BLOCK_LOW_AND_ABOVE",
1421
1441
  "BLOCK_MEDIUM_AND_ABOVE",
@@ -1425,7 +1445,7 @@ var googleLanguageModelOptions = lazySchema6(
1425
1445
  ])
1426
1446
  })
1427
1447
  ).optional(),
1428
- threshold: z6.enum([
1448
+ threshold: z7.enum([
1429
1449
  "HARM_BLOCK_THRESHOLD_UNSPECIFIED",
1430
1450
  "BLOCK_LOW_AND_ABOVE",
1431
1451
  "BLOCK_MEDIUM_AND_ABOVE",
@@ -1438,19 +1458,19 @@ var googleLanguageModelOptions = lazySchema6(
1438
1458
  *
1439
1459
  * https://cloud.google.com/vertex-ai/generative-ai/docs/multimodal/audio-understanding
1440
1460
  */
1441
- audioTimestamp: z6.boolean().optional(),
1461
+ audioTimestamp: z7.boolean().optional(),
1442
1462
  /**
1443
1463
  * Optional. Defines labels used in billing reports. Available on Vertex AI only.
1444
1464
  *
1445
1465
  * https://cloud.google.com/vertex-ai/generative-ai/docs/multimodal/add-labels-to-api-calls
1446
1466
  */
1447
- labels: z6.record(z6.string(), z6.string()).optional(),
1467
+ labels: z7.record(z7.string(), z7.string()).optional(),
1448
1468
  /**
1449
1469
  * Optional. If specified, the media resolution specified will be used.
1450
1470
  *
1451
1471
  * https://ai.google.dev/api/generate-content#MediaResolution
1452
1472
  */
1453
- mediaResolution: z6.enum([
1473
+ mediaResolution: z7.enum([
1454
1474
  "MEDIA_RESOLUTION_UNSPECIFIED",
1455
1475
  "MEDIA_RESOLUTION_LOW",
1456
1476
  "MEDIA_RESOLUTION_MEDIUM",
@@ -1461,8 +1481,8 @@ var googleLanguageModelOptions = lazySchema6(
1461
1481
  *
1462
1482
  * https://ai.google.dev/gemini-api/docs/image-generation#aspect_ratios
1463
1483
  */
1464
- imageConfig: z6.object({
1465
- aspectRatio: z6.enum([
1484
+ imageConfig: z7.object({
1485
+ aspectRatio: z7.enum([
1466
1486
  "1:1",
1467
1487
  "2:3",
1468
1488
  "3:2",
@@ -1478,12 +1498,12 @@ var googleLanguageModelOptions = lazySchema6(
1478
1498
  "1:4",
1479
1499
  "4:1"
1480
1500
  ]).optional(),
1481
- imageSize: z6.enum(["1K", "2K", "4K", "512"]).optional(),
1501
+ imageSize: z7.enum(["1K", "2K", "4K", "512"]).optional(),
1482
1502
  /**
1483
1503
  * Optional. Controls the generation of people in images.
1484
1504
  * Vertex AI only.
1485
1505
  */
1486
- personGeneration: z6.enum([
1506
+ personGeneration: z7.enum([
1487
1507
  "PERSON_GENERATION_UNSPECIFIED",
1488
1508
  "ALLOW_ALL",
1489
1509
  "ALLOW_ADULT",
@@ -1497,7 +1517,7 @@ var googleLanguageModelOptions = lazySchema6(
1497
1517
  *
1498
1518
  * https://docs.cloud.google.com/vertex-ai/generative-ai/docs/reference/rest/v1/GenerationConfig
1499
1519
  */
1500
- prominentPeople: z6.enum([
1520
+ prominentPeople: z7.enum([
1501
1521
  "PROMINENT_PEOPLE_UNSPECIFIED",
1502
1522
  "ALLOW_PROMINENT_PEOPLE",
1503
1523
  "BLOCK_PROMINENT_PEOPLE"
@@ -1506,9 +1526,9 @@ var googleLanguageModelOptions = lazySchema6(
1506
1526
  * Optional. The image output format for generated images.
1507
1527
  * Vertex AI only.
1508
1528
  */
1509
- imageOutputOptions: z6.object({
1510
- mimeType: z6.enum(["image/jpeg", "image/png"]).optional(),
1511
- compressionQuality: z6.number().optional()
1529
+ imageOutputOptions: z7.object({
1530
+ mimeType: z7.enum(["image/jpeg", "image/png"]).optional(),
1531
+ compressionQuality: z7.number().optional()
1512
1532
  }).optional()
1513
1533
  }).optional(),
1514
1534
  /**
@@ -1517,10 +1537,10 @@ var googleLanguageModelOptions = lazySchema6(
1517
1537
  *
1518
1538
  * https://cloud.google.com/vertex-ai/generative-ai/docs/grounding/grounding-with-google-maps
1519
1539
  */
1520
- retrievalConfig: z6.object({
1521
- latLng: z6.object({
1522
- latitude: z6.number(),
1523
- longitude: z6.number()
1540
+ retrievalConfig: z7.object({
1541
+ latLng: z7.object({
1542
+ latitude: z7.number(),
1543
+ longitude: z7.number()
1524
1544
  }).optional()
1525
1545
  }).optional(),
1526
1546
  /**
@@ -1533,12 +1553,12 @@ var googleLanguageModelOptions = lazySchema6(
1533
1553
  *
1534
1554
  * https://docs.cloud.google.com/vertex-ai/generative-ai/docs/multimodal/function-calling#streaming-fc
1535
1555
  */
1536
- streamFunctionCallArguments: z6.boolean().optional(),
1556
+ streamFunctionCallArguments: z7.boolean().optional(),
1537
1557
  /**
1538
1558
  * Optional. The service tier to use for the request. Sent as the
1539
1559
  * `serviceTier` body field. Gemini API only.
1540
1560
  */
1541
- serviceTier: z6.enum(["standard", "flex", "priority"]).optional(),
1561
+ serviceTier: z7.enum(["standard", "flex", "priority"]).optional(),
1542
1562
  /**
1543
1563
  * Optional. Resumes a response that stopped with `MAX_TOKENS` because it
1544
1564
  * used up its `maxOutputTokens` budget (Gemini 4 long decode). Pass the
@@ -1548,7 +1568,7 @@ var googleLanguageModelOptions = lazySchema6(
1548
1568
  * per-request cap while budget remains (`CONTINUATION`) are continued
1549
1569
  * automatically. Sent as the `continuationToken` body field.
1550
1570
  */
1551
- continuationToken: z6.string().optional(),
1571
+ continuationToken: z7.string().optional(),
1552
1572
  /**
1553
1573
  * Optional. Vertex AI only. Sent as the
1554
1574
  * `X-Vertex-AI-LLM-Shared-Request-Type` request header to select a
@@ -1559,7 +1579,7 @@ var googleLanguageModelOptions = lazySchema6(
1559
1579
  * https://docs.cloud.google.com/vertex-ai/generative-ai/docs/priority-paygo
1560
1580
  * https://docs.cloud.google.com/vertex-ai/generative-ai/docs/flex-paygo
1561
1581
  */
1562
- sharedRequestType: z6.enum(["priority", "flex", "standard"]).optional(),
1582
+ sharedRequestType: z7.enum(["priority", "flex", "standard"]).optional(),
1563
1583
  /**
1564
1584
  * Optional. Vertex AI only. Sent as the `X-Vertex-AI-LLM-Request-Type`
1565
1585
  * request header. Set to `'shared'` together with `sharedRequestType`
@@ -1567,7 +1587,7 @@ var googleLanguageModelOptions = lazySchema6(
1567
1587
  *
1568
1588
  * https://docs.cloud.google.com/vertex-ai/generative-ai/docs/priority-paygo
1569
1589
  */
1570
- requestType: z6.enum(["shared"]).optional()
1590
+ requestType: z7.enum(["shared"]).optional()
1571
1591
  })
1572
1592
  )
1573
1593
  );
@@ -3186,205 +3206,205 @@ function extractSources({
3186
3206
  }
3187
3207
  return sources.length > 0 ? sources : void 0;
3188
3208
  }
3189
- var getGroundingMetadataSchema = () => z7.object({
3190
- webSearchQueries: z7.array(z7.string()).nullish(),
3191
- imageSearchQueries: z7.array(z7.string()).nullish(),
3192
- retrievalQueries: z7.array(z7.string()).nullish(),
3193
- searchEntryPoint: z7.object({ renderedContent: z7.string() }).nullish(),
3194
- groundingChunks: z7.array(
3195
- z7.object({
3196
- web: z7.object({ uri: z7.string(), title: z7.string().nullish() }).nullish(),
3197
- image: z7.object({
3198
- sourceUri: z7.string(),
3199
- imageUri: z7.string(),
3200
- title: z7.string().nullish(),
3201
- domain: z7.string().nullish()
3209
+ var getGroundingMetadataSchema = () => z8.object({
3210
+ webSearchQueries: z8.array(z8.string()).nullish(),
3211
+ imageSearchQueries: z8.array(z8.string()).nullish(),
3212
+ retrievalQueries: z8.array(z8.string()).nullish(),
3213
+ searchEntryPoint: z8.object({ renderedContent: z8.string() }).nullish(),
3214
+ groundingChunks: z8.array(
3215
+ z8.object({
3216
+ web: z8.object({ uri: z8.string(), title: z8.string().nullish() }).nullish(),
3217
+ image: z8.object({
3218
+ sourceUri: z8.string(),
3219
+ imageUri: z8.string(),
3220
+ title: z8.string().nullish(),
3221
+ domain: z8.string().nullish()
3202
3222
  }).nullish(),
3203
- retrievedContext: z7.object({
3204
- uri: z7.string().nullish(),
3205
- title: z7.string().nullish(),
3206
- text: z7.string().nullish(),
3207
- fileSearchStore: z7.string().nullish(),
3208
- customMetadata: z7.array(
3209
- z7.object({
3210
- key: z7.string(),
3211
- stringValue: z7.string().nullish(),
3212
- numericValue: z7.number().nullish(),
3213
- stringListValue: z7.object({ values: z7.array(z7.string()).nullish() }).nullish()
3223
+ retrievedContext: z8.object({
3224
+ uri: z8.string().nullish(),
3225
+ title: z8.string().nullish(),
3226
+ text: z8.string().nullish(),
3227
+ fileSearchStore: z8.string().nullish(),
3228
+ customMetadata: z8.array(
3229
+ z8.object({
3230
+ key: z8.string(),
3231
+ stringValue: z8.string().nullish(),
3232
+ numericValue: z8.number().nullish(),
3233
+ stringListValue: z8.object({ values: z8.array(z8.string()).nullish() }).nullish()
3214
3234
  })
3215
3235
  ).nullish()
3216
3236
  }).nullish(),
3217
- maps: z7.object({
3218
- uri: z7.string().nullish(),
3219
- title: z7.string().nullish(),
3220
- text: z7.string().nullish(),
3221
- placeId: z7.string().nullish()
3237
+ maps: z8.object({
3238
+ uri: z8.string().nullish(),
3239
+ title: z8.string().nullish(),
3240
+ text: z8.string().nullish(),
3241
+ placeId: z8.string().nullish()
3222
3242
  }).nullish()
3223
3243
  })
3224
3244
  ).nullish(),
3225
- groundingSupports: z7.array(
3226
- z7.object({
3227
- segment: z7.object({
3228
- startIndex: z7.number().nullish(),
3229
- endIndex: z7.number().nullish(),
3230
- text: z7.string().nullish()
3245
+ groundingSupports: z8.array(
3246
+ z8.object({
3247
+ segment: z8.object({
3248
+ startIndex: z8.number().nullish(),
3249
+ endIndex: z8.number().nullish(),
3250
+ text: z8.string().nullish()
3231
3251
  }).nullish(),
3232
- segment_text: z7.string().nullish(),
3233
- groundingChunkIndices: z7.array(z7.number()).nullish(),
3234
- supportChunkIndices: z7.array(z7.number()).nullish(),
3235
- confidenceScores: z7.array(z7.number()).nullish(),
3236
- confidenceScore: z7.array(z7.number()).nullish()
3252
+ segment_text: z8.string().nullish(),
3253
+ groundingChunkIndices: z8.array(z8.number()).nullish(),
3254
+ supportChunkIndices: z8.array(z8.number()).nullish(),
3255
+ confidenceScores: z8.array(z8.number()).nullish(),
3256
+ confidenceScore: z8.array(z8.number()).nullish()
3237
3257
  })
3238
3258
  ).nullish(),
3239
- retrievalMetadata: z7.union([
3240
- z7.object({
3241
- webDynamicRetrievalScore: z7.number()
3259
+ retrievalMetadata: z8.union([
3260
+ z8.object({
3261
+ webDynamicRetrievalScore: z8.number()
3242
3262
  }),
3243
- z7.object({})
3263
+ z8.object({})
3244
3264
  ]).nullish()
3245
3265
  });
3246
- var partialArgSchema = () => z7.object({
3247
- jsonPath: z7.string(),
3248
- stringValue: z7.string().nullish(),
3249
- numberValue: z7.number().nullish(),
3250
- boolValue: z7.boolean().nullish(),
3251
- nullValue: z7.unknown().nullish(),
3252
- willContinue: z7.boolean().nullish()
3266
+ var partialArgSchema = () => z8.object({
3267
+ jsonPath: z8.string(),
3268
+ stringValue: z8.string().nullish(),
3269
+ numberValue: z8.number().nullish(),
3270
+ boolValue: z8.boolean().nullish(),
3271
+ nullValue: z8.unknown().nullish(),
3272
+ willContinue: z8.boolean().nullish()
3253
3273
  });
3254
- var getContentSchema = () => z7.object({
3255
- parts: z7.array(
3256
- z7.union([
3274
+ var getContentSchema = () => z8.object({
3275
+ parts: z8.array(
3276
+ z8.union([
3257
3277
  // note: order matters since text can be fully empty
3258
- z7.object({
3259
- functionCall: z7.object({
3260
- id: z7.string().nullish(),
3261
- name: z7.string().nullish(),
3262
- args: z7.unknown().nullish(),
3263
- partialArgs: z7.array(partialArgSchema()).nullish(),
3264
- willContinue: z7.boolean().nullish()
3278
+ z8.object({
3279
+ functionCall: z8.object({
3280
+ id: z8.string().nullish(),
3281
+ name: z8.string().nullish(),
3282
+ args: z8.unknown().nullish(),
3283
+ partialArgs: z8.array(partialArgSchema()).nullish(),
3284
+ willContinue: z8.boolean().nullish()
3265
3285
  }),
3266
- thoughtSignature: z7.string().nullish()
3286
+ thoughtSignature: z8.string().nullish()
3267
3287
  }),
3268
- z7.object({
3269
- inlineData: z7.object({
3270
- mimeType: z7.string(),
3271
- data: z7.string()
3288
+ z8.object({
3289
+ inlineData: z8.object({
3290
+ mimeType: z8.string(),
3291
+ data: z8.string()
3272
3292
  }),
3273
- thought: z7.boolean().nullish(),
3274
- thoughtSignature: z7.string().nullish()
3293
+ thought: z8.boolean().nullish(),
3294
+ thoughtSignature: z8.string().nullish()
3275
3295
  }),
3276
- z7.object({
3277
- toolCall: z7.object({
3278
- toolType: z7.string(),
3279
- args: z7.unknown().nullish(),
3280
- id: z7.string()
3296
+ z8.object({
3297
+ toolCall: z8.object({
3298
+ toolType: z8.string(),
3299
+ args: z8.unknown().nullish(),
3300
+ id: z8.string()
3281
3301
  }),
3282
- thoughtSignature: z7.string().nullish()
3302
+ thoughtSignature: z8.string().nullish()
3283
3303
  }),
3284
- z7.object({
3285
- toolResponse: z7.object({
3286
- toolType: z7.string(),
3287
- response: z7.unknown().nullish(),
3288
- id: z7.string()
3304
+ z8.object({
3305
+ toolResponse: z8.object({
3306
+ toolType: z8.string(),
3307
+ response: z8.unknown().nullish(),
3308
+ id: z8.string()
3289
3309
  }),
3290
- thoughtSignature: z7.string().nullish()
3310
+ thoughtSignature: z8.string().nullish()
3291
3311
  }),
3292
- z7.object({
3293
- executableCode: z7.object({
3294
- language: z7.string(),
3295
- code: z7.string()
3312
+ z8.object({
3313
+ executableCode: z8.object({
3314
+ language: z8.string(),
3315
+ code: z8.string()
3296
3316
  }).nullish(),
3297
- codeExecutionResult: z7.object({
3298
- outcome: z7.string(),
3299
- output: z7.string().nullish()
3317
+ codeExecutionResult: z8.object({
3318
+ outcome: z8.string(),
3319
+ output: z8.string().nullish()
3300
3320
  }).nullish(),
3301
- text: z7.string().nullish(),
3302
- thought: z7.boolean().nullish(),
3303
- thoughtSignature: z7.string().nullish()
3321
+ text: z8.string().nullish(),
3322
+ thought: z8.boolean().nullish(),
3323
+ thoughtSignature: z8.string().nullish()
3304
3324
  })
3305
3325
  ])
3306
3326
  ).nullish()
3307
3327
  });
3308
- var getSafetyRatingSchema = () => z7.object({
3309
- category: z7.string().nullish(),
3310
- probability: z7.string().nullish(),
3311
- probabilityScore: z7.number().nullish(),
3312
- severity: z7.string().nullish(),
3313
- severityScore: z7.number().nullish(),
3314
- blocked: z7.boolean().nullish()
3328
+ var getSafetyRatingSchema = () => z8.object({
3329
+ category: z8.string().nullish(),
3330
+ probability: z8.string().nullish(),
3331
+ probabilityScore: z8.number().nullish(),
3332
+ severity: z8.string().nullish(),
3333
+ severityScore: z8.number().nullish(),
3334
+ blocked: z8.boolean().nullish()
3315
3335
  });
3316
- var tokenDetailsSchema = () => z7.array(
3317
- z7.object({
3318
- modality: z7.string(),
3319
- tokenCount: z7.number()
3320
- }).catchall(z7.json())
3336
+ var tokenDetailsSchema = () => z8.array(
3337
+ z8.object({
3338
+ modality: z8.string(),
3339
+ tokenCount: z8.number()
3340
+ }).catchall(z8.json())
3321
3341
  ).nullish();
3322
- var usageSchema = () => z7.object({
3323
- cachedContentTokenCount: z7.number().nullish(),
3324
- thoughtsTokenCount: z7.number().nullish(),
3325
- promptTokenCount: z7.number().nullish(),
3326
- candidatesTokenCount: z7.number().nullish(),
3327
- toolUsePromptTokenCount: z7.number().nullish(),
3328
- totalTokenCount: z7.number().nullish(),
3342
+ var usageSchema = () => z8.object({
3343
+ cachedContentTokenCount: z8.number().nullish(),
3344
+ thoughtsTokenCount: z8.number().nullish(),
3345
+ promptTokenCount: z8.number().nullish(),
3346
+ candidatesTokenCount: z8.number().nullish(),
3347
+ toolUsePromptTokenCount: z8.number().nullish(),
3348
+ totalTokenCount: z8.number().nullish(),
3329
3349
  // https://cloud.google.com/vertex-ai/generative-ai/docs/reference/rest/v1/GenerateContentResponse#TrafficType
3330
- trafficType: z7.string().nullish(),
3331
- serviceTier: z7.string().nullish(),
3350
+ trafficType: z8.string().nullish(),
3351
+ serviceTier: z8.string().nullish(),
3332
3352
  // https://ai.google.dev/api/generate-content#Modality
3333
3353
  promptTokensDetails: tokenDetailsSchema(),
3334
3354
  cacheTokensDetails: tokenDetailsSchema(),
3335
3355
  candidatesTokensDetails: tokenDetailsSchema(),
3336
3356
  toolUsePromptTokensDetails: tokenDetailsSchema()
3337
- }).catchall(z7.json());
3338
- var getUrlContextMetadataSchema = () => z7.object({
3339
- urlMetadata: z7.array(
3340
- z7.object({
3341
- retrievedUrl: z7.string(),
3342
- urlRetrievalStatus: z7.string()
3357
+ }).catchall(z8.json());
3358
+ var getUrlContextMetadataSchema = () => z8.object({
3359
+ urlMetadata: z8.array(
3360
+ z8.object({
3361
+ retrievedUrl: z8.string(),
3362
+ urlRetrievalStatus: z8.string()
3343
3363
  })
3344
3364
  ).nullish()
3345
3365
  });
3346
3366
  var responseSchema = lazySchema7(
3347
3367
  () => zodSchema7(
3348
- z7.object({
3349
- responseId: z7.string().nullish(),
3350
- candidates: z7.array(
3351
- z7.object({
3352
- content: getContentSchema().nullish().or(z7.object({}).strict()),
3353
- finishReason: z7.string().nullish(),
3354
- finishMessage: z7.string().nullish(),
3355
- continuationToken: z7.string().nullish(),
3356
- safetyRatings: z7.array(getSafetyRatingSchema()).nullish(),
3368
+ z8.object({
3369
+ responseId: z8.string().nullish(),
3370
+ candidates: z8.array(
3371
+ z8.object({
3372
+ content: getContentSchema().nullish().or(z8.object({}).strict()),
3373
+ finishReason: z8.string().nullish(),
3374
+ finishMessage: z8.string().nullish(),
3375
+ continuationToken: z8.string().nullish(),
3376
+ safetyRatings: z8.array(getSafetyRatingSchema()).nullish(),
3357
3377
  groundingMetadata: getGroundingMetadataSchema().nullish(),
3358
3378
  urlContextMetadata: getUrlContextMetadataSchema().nullish()
3359
3379
  })
3360
3380
  ).nullish(),
3361
3381
  usageMetadata: usageSchema().nullish(),
3362
- promptFeedback: z7.object({
3363
- blockReason: z7.string().nullish(),
3364
- safetyRatings: z7.array(getSafetyRatingSchema()).nullish()
3382
+ promptFeedback: z8.object({
3383
+ blockReason: z8.string().nullish(),
3384
+ safetyRatings: z8.array(getSafetyRatingSchema()).nullish()
3365
3385
  }).nullish()
3366
3386
  })
3367
3387
  )
3368
3388
  );
3369
3389
  var chunkSchema = lazySchema7(
3370
3390
  () => zodSchema7(
3371
- z7.object({
3372
- responseId: z7.string().nullish(),
3373
- candidates: z7.array(
3374
- z7.object({
3391
+ z8.object({
3392
+ responseId: z8.string().nullish(),
3393
+ candidates: z8.array(
3394
+ z8.object({
3375
3395
  content: getContentSchema().nullish(),
3376
- finishReason: z7.string().nullish(),
3377
- finishMessage: z7.string().nullish(),
3378
- continuationToken: z7.string().nullish(),
3379
- safetyRatings: z7.array(getSafetyRatingSchema()).nullish(),
3396
+ finishReason: z8.string().nullish(),
3397
+ finishMessage: z8.string().nullish(),
3398
+ continuationToken: z8.string().nullish(),
3399
+ safetyRatings: z8.array(getSafetyRatingSchema()).nullish(),
3380
3400
  groundingMetadata: getGroundingMetadataSchema().nullish(),
3381
3401
  urlContextMetadata: getUrlContextMetadataSchema().nullish()
3382
3402
  })
3383
3403
  ).nullish(),
3384
3404
  usageMetadata: usageSchema().nullish(),
3385
- promptFeedback: z7.object({
3386
- blockReason: z7.string().nullish(),
3387
- safetyRatings: z7.array(getSafetyRatingSchema()).nullish()
3405
+ promptFeedback: z8.object({
3406
+ blockReason: z8.string().nullish(),
3407
+ safetyRatings: z8.array(getSafetyRatingSchema()).nullish()
3388
3408
  }).nullish()
3389
3409
  })
3390
3410
  )
@@ -3395,16 +3415,16 @@ function isConfirmedPromptBlockReason(blockReason) {
3395
3415
 
3396
3416
  // src/tool/code-execution.ts
3397
3417
  import { createProviderToolFactoryWithOutputSchema } from "@ai-sdk/provider-utils";
3398
- import { z as z8 } from "zod/v4";
3418
+ import { z as z9 } from "zod/v4";
3399
3419
  var codeExecution = createProviderToolFactoryWithOutputSchema({
3400
3420
  id: "google.code_execution",
3401
- inputSchema: z8.object({
3402
- language: z8.string().describe("The programming language of the code."),
3403
- code: z8.string().describe("The code to be executed.")
3421
+ inputSchema: z9.object({
3422
+ language: z9.string().describe("The programming language of the code."),
3423
+ code: z9.string().describe("The code to be executed.")
3404
3424
  }),
3405
- outputSchema: z8.object({
3406
- outcome: z8.string().describe('The outcome of the execution (e.g., "OUTCOME_OK").'),
3407
- output: z8.string().describe("The output from the code execution.")
3425
+ outputSchema: z9.object({
3426
+ outcome: z9.string().describe('The outcome of the execution (e.g., "OUTCOME_OK").'),
3427
+ output: z9.string().describe("The output from the code execution.")
3408
3428
  })
3409
3429
  });
3410
3430
 
@@ -3414,10 +3434,10 @@ import {
3414
3434
  lazySchema as lazySchema8,
3415
3435
  zodSchema as zodSchema8
3416
3436
  } from "@ai-sdk/provider-utils";
3417
- import { z as z9 } from "zod/v4";
3437
+ import { z as z10 } from "zod/v4";
3418
3438
  var enterpriseWebSearch = createProviderToolFactory({
3419
3439
  id: "google.enterprise_web_search",
3420
- inputSchema: lazySchema8(() => zodSchema8(z9.object({})))
3440
+ inputSchema: lazySchema8(() => zodSchema8(z10.object({})))
3421
3441
  });
3422
3442
 
3423
3443
  // src/tool/file-search.ts
@@ -3426,20 +3446,20 @@ import {
3426
3446
  lazySchema as lazySchema9,
3427
3447
  zodSchema as zodSchema9
3428
3448
  } from "@ai-sdk/provider-utils";
3429
- import { z as z10 } from "zod/v4";
3430
- var fileSearchArgsBaseSchema = () => z10.object({
3449
+ import { z as z11 } from "zod/v4";
3450
+ var fileSearchArgsBaseSchema = () => z11.object({
3431
3451
  /** The names of the file_search_stores to retrieve from.
3432
3452
  * Example: `fileSearchStores/my-file-search-store-123`
3433
3453
  */
3434
- fileSearchStoreNames: z10.array(z10.string()).describe(
3454
+ fileSearchStoreNames: z11.array(z11.string()).describe(
3435
3455
  "The names of the file_search_stores to retrieve from. Example: `fileSearchStores/my-file-search-store-123`"
3436
3456
  ),
3437
3457
  /** The number of file search retrieval chunks to retrieve. */
3438
- topK: z10.number().int().positive().describe("The number of file search retrieval chunks to retrieve.").optional(),
3458
+ topK: z11.number().int().positive().describe("The number of file search retrieval chunks to retrieve.").optional(),
3439
3459
  /** Metadata filter to apply to the file search retrieval documents.
3440
3460
  * See https://google.aip.dev/160 for the syntax of the filter expression.
3441
3461
  */
3442
- metadataFilter: z10.string().describe(
3462
+ metadataFilter: z11.string().describe(
3443
3463
  "Metadata filter to apply to the file search retrieval documents. See https://google.aip.dev/160 for the syntax of the filter expression."
3444
3464
  ).optional()
3445
3465
  }).passthrough();
@@ -3457,10 +3477,10 @@ import {
3457
3477
  lazySchema as lazySchema10,
3458
3478
  zodSchema as zodSchema10
3459
3479
  } from "@ai-sdk/provider-utils";
3460
- import { z as z11 } from "zod/v4";
3480
+ import { z as z12 } from "zod/v4";
3461
3481
  var googleMaps = createProviderToolFactory3({
3462
3482
  id: "google.google_maps",
3463
- inputSchema: lazySchema10(() => zodSchema10(z11.object({})))
3483
+ inputSchema: lazySchema10(() => zodSchema10(z12.object({})))
3464
3484
  });
3465
3485
 
3466
3486
  // src/tool/google-search.ts
@@ -3469,15 +3489,15 @@ import {
3469
3489
  lazySchema as lazySchema11,
3470
3490
  zodSchema as zodSchema11
3471
3491
  } from "@ai-sdk/provider-utils";
3472
- import { z as z12 } from "zod/v4";
3473
- var googleSearchToolArgsBaseSchema = () => z12.object({
3474
- searchTypes: z12.object({
3475
- webSearch: z12.object({}).optional(),
3476
- imageSearch: z12.object({}).optional()
3492
+ import { z as z13 } from "zod/v4";
3493
+ var googleSearchToolArgsBaseSchema = () => z13.object({
3494
+ searchTypes: z13.object({
3495
+ webSearch: z13.object({}).optional(),
3496
+ imageSearch: z13.object({}).optional()
3477
3497
  }).optional(),
3478
- timeRangeFilter: z12.object({
3479
- startTime: z12.string(),
3480
- endTime: z12.string()
3498
+ timeRangeFilter: z13.object({
3499
+ startTime: z13.string(),
3500
+ endTime: z13.string()
3481
3501
  }).optional()
3482
3502
  }).passthrough();
3483
3503
  var googleSearchToolArgsSchema = lazySchema11(
@@ -3496,20 +3516,20 @@ import {
3496
3516
  lazySchema as lazySchema12,
3497
3517
  zodSchema as zodSchema12
3498
3518
  } from "@ai-sdk/provider-utils";
3499
- import { z as z13 } from "zod/v4";
3519
+ import { z as z14 } from "zod/v4";
3500
3520
  var urlContext = createProviderToolFactory5({
3501
3521
  id: "google.url_context",
3502
- inputSchema: lazySchema12(() => zodSchema12(z13.object({})))
3522
+ inputSchema: lazySchema12(() => zodSchema12(z14.object({})))
3503
3523
  });
3504
3524
 
3505
3525
  // src/tool/vertex-rag-store.ts
3506
3526
  import { createProviderToolFactory as createProviderToolFactory6 } from "@ai-sdk/provider-utils";
3507
- import { z as z14 } from "zod/v4";
3527
+ import { z as z15 } from "zod/v4";
3508
3528
  var vertexRagStore = createProviderToolFactory6({
3509
3529
  id: "google.vertex_rag_store",
3510
- inputSchema: z14.object({
3511
- ragCorpus: z14.string(),
3512
- topK: z14.number().optional()
3530
+ inputSchema: z15.object({
3531
+ ragCorpus: z15.string(),
3532
+ topK: z15.number().optional()
3513
3533
  })
3514
3534
  });
3515
3535
 
@@ -3585,7 +3605,7 @@ import {
3585
3605
  resolve as resolve4,
3586
3606
  zodSchema as zodSchema13
3587
3607
  } from "@ai-sdk/provider-utils";
3588
- import { z as z15 } from "zod/v4";
3608
+ import { z as z16 } from "zod/v4";
3589
3609
  var GoogleGenerativeAIImageModel = class {
3590
3610
  constructor(modelId, settings, config) {
3591
3611
  this.modelId = modelId;
@@ -3841,11 +3861,11 @@ function isGeminiModel(modelId) {
3841
3861
  }
3842
3862
  var googleImageResponseSchema = lazySchema13(
3843
3863
  () => zodSchema13(
3844
- z15.object({
3845
- predictions: z15.array(
3846
- z15.union([
3847
- z15.object({ bytesBase64Encoded: z15.string() }),
3848
- z15.object({ raiFilteredReason: z15.string() })
3864
+ z16.object({
3865
+ predictions: z16.array(
3866
+ z16.union([
3867
+ z16.object({ bytesBase64Encoded: z16.string() }),
3868
+ z16.object({ raiFilteredReason: z16.string() })
3849
3869
  ])
3850
3870
  ).default([])
3851
3871
  })
@@ -3853,9 +3873,9 @@ var googleImageResponseSchema = lazySchema13(
3853
3873
  );
3854
3874
  var googleImageModelOptionsSchema = lazySchema13(
3855
3875
  () => zodSchema13(
3856
- z15.object({
3857
- personGeneration: z15.enum(["dont_allow", "allow_adult", "allow_all"]).nullish(),
3858
- aspectRatio: z15.enum(["1:1", "3:4", "4:3", "9:16", "16:9"]).nullish(),
3876
+ z16.object({
3877
+ personGeneration: z16.enum(["dont_allow", "allow_adult", "allow_all"]).nullish(),
3878
+ aspectRatio: z16.enum(["1:1", "3:4", "4:3", "9:16", "16:9"]).nullish(),
3859
3879
  /**
3860
3880
  * Enable Google Search grounding for Gemini image models. The value is
3861
3881
  * forwarded as the args of the `google.tools.googleSearch` provider
@@ -3887,7 +3907,7 @@ import {
3887
3907
  resolve as resolve5,
3888
3908
  zodSchema as zodSchema14
3889
3909
  } from "@ai-sdk/provider-utils";
3890
- import { z as z16 } from "zod/v4";
3910
+ import { z as z17 } from "zod/v4";
3891
3911
  function getFirstFrameImage(options) {
3892
3912
  var _a2, _b;
3893
3913
  return (_b = (_a2 = options.frameImages) == null ? void 0 : _a2.find((frame) => frame.frameType === "first_frame")) == null ? void 0 : _b.image;
@@ -4154,20 +4174,20 @@ var GoogleGenerativeAIVideoModel = class {
4154
4174
  };
4155
4175
  var googleOperationSchema = lazySchema14(
4156
4176
  () => zodSchema14(
4157
- z16.object({
4158
- name: z16.string().nullish(),
4159
- done: z16.boolean().nullish(),
4160
- error: z16.object({
4161
- code: z16.number().nullish(),
4162
- message: z16.string(),
4163
- status: z16.string().nullish()
4177
+ z17.object({
4178
+ name: z17.string().nullish(),
4179
+ done: z17.boolean().nullish(),
4180
+ error: z17.object({
4181
+ code: z17.number().nullish(),
4182
+ message: z17.string(),
4183
+ status: z17.string().nullish()
4164
4184
  }).nullish(),
4165
- response: z16.object({
4166
- generateVideoResponse: z16.object({
4167
- generatedSamples: z16.array(
4168
- z16.object({
4169
- video: z16.object({
4170
- uri: z16.string().nullish()
4185
+ response: z17.object({
4186
+ generateVideoResponse: z17.object({
4187
+ generatedSamples: z17.array(
4188
+ z17.object({
4189
+ video: z17.object({
4190
+ uri: z17.string().nullish()
4171
4191
  }).nullish()
4172
4192
  })
4173
4193
  ).nullish()
@@ -4178,15 +4198,15 @@ var googleOperationSchema = lazySchema14(
4178
4198
  );
4179
4199
  var googleVideoModelOptionsSchema = lazySchema14(
4180
4200
  () => zodSchema14(
4181
- z16.object({
4182
- pollIntervalMs: z16.number().positive().nullish(),
4183
- pollTimeoutMs: z16.number().positive().nullish(),
4184
- personGeneration: z16.enum(["dont_allow", "allow_adult", "allow_all"]).nullish(),
4185
- negativePrompt: z16.string().nullish(),
4186
- referenceImages: z16.array(
4187
- z16.object({
4188
- bytesBase64Encoded: z16.string().nullish(),
4189
- gcsUri: z16.string().nullish()
4201
+ z17.object({
4202
+ pollIntervalMs: z17.number().positive().nullish(),
4203
+ pollTimeoutMs: z17.number().positive().nullish(),
4204
+ personGeneration: z17.enum(["dont_allow", "allow_adult", "allow_all"]).nullish(),
4205
+ negativePrompt: z17.string().nullish(),
4206
+ referenceImages: z17.array(
4207
+ z17.object({
4208
+ bytesBase64Encoded: z17.string().nullish(),
4209
+ gcsUri: z17.string().nullish()
4190
4210
  })
4191
4211
  ).nullish()
4192
4212
  }).passthrough()
@@ -5362,30 +5382,30 @@ import {
5362
5382
  lazySchema as lazySchema15,
5363
5383
  zodSchema as zodSchema15
5364
5384
  } from "@ai-sdk/provider-utils";
5365
- import { z as z17 } from "zod/v4";
5366
- var tokenByModalitySchema = () => z17.object({
5367
- modality: z17.string().nullish(),
5368
- tokens: z17.number().nullish()
5385
+ import { z as z18 } from "zod/v4";
5386
+ var tokenByModalitySchema = () => z18.object({
5387
+ modality: z18.string().nullish(),
5388
+ tokens: z18.number().nullish()
5369
5389
  }).loose();
5370
- var usageSchema2 = () => z17.object({
5371
- total_input_tokens: z17.number().nullish(),
5372
- total_output_tokens: z17.number().nullish(),
5373
- total_thought_tokens: z17.number().nullish(),
5374
- total_cached_tokens: z17.number().nullish(),
5375
- total_tool_use_tokens: z17.number().nullish(),
5376
- total_tokens: z17.number().nullish(),
5377
- input_tokens_by_modality: z17.array(tokenByModalitySchema()).nullish(),
5378
- output_tokens_by_modality: z17.array(tokenByModalitySchema()).nullish(),
5379
- cached_tokens_by_modality: z17.array(tokenByModalitySchema()).nullish(),
5380
- tool_use_tokens_by_modality: z17.array(tokenByModalitySchema()).nullish(),
5381
- grounding_tool_count: z17.array(
5382
- z17.object({
5383
- type: z17.string().nullish(),
5384
- count: z17.number().nullish()
5390
+ var usageSchema2 = () => z18.object({
5391
+ total_input_tokens: z18.number().nullish(),
5392
+ total_output_tokens: z18.number().nullish(),
5393
+ total_thought_tokens: z18.number().nullish(),
5394
+ total_cached_tokens: z18.number().nullish(),
5395
+ total_tool_use_tokens: z18.number().nullish(),
5396
+ total_tokens: z18.number().nullish(),
5397
+ input_tokens_by_modality: z18.array(tokenByModalitySchema()).nullish(),
5398
+ output_tokens_by_modality: z18.array(tokenByModalitySchema()).nullish(),
5399
+ cached_tokens_by_modality: z18.array(tokenByModalitySchema()).nullish(),
5400
+ tool_use_tokens_by_modality: z18.array(tokenByModalitySchema()).nullish(),
5401
+ grounding_tool_count: z18.array(
5402
+ z18.object({
5403
+ type: z18.string().nullish(),
5404
+ count: z18.number().nullish()
5385
5405
  }).loose()
5386
5406
  ).nullish()
5387
5407
  }).loose();
5388
- var interactionStatusSchema = () => z17.enum([
5408
+ var interactionStatusSchema = () => z18.enum([
5389
5409
  "in_progress",
5390
5410
  "requires_action",
5391
5411
  "completed",
@@ -5394,69 +5414,69 @@ var interactionStatusSchema = () => z17.enum([
5394
5414
  "incomplete"
5395
5415
  ]);
5396
5416
  var annotationSchema = () => {
5397
- const urlCitation = z17.object({
5398
- type: z17.literal("url_citation"),
5399
- url: z17.string().nullish(),
5400
- title: z17.string().nullish(),
5401
- start_index: z17.number().nullish(),
5402
- end_index: z17.number().nullish()
5417
+ const urlCitation = z18.object({
5418
+ type: z18.literal("url_citation"),
5419
+ url: z18.string().nullish(),
5420
+ title: z18.string().nullish(),
5421
+ start_index: z18.number().nullish(),
5422
+ end_index: z18.number().nullish()
5403
5423
  }).loose();
5404
- const fileCitation = z17.object({
5405
- type: z17.literal("file_citation"),
5406
- file_name: z17.string().nullish(),
5407
- document_uri: z17.string().nullish(),
5408
- url: z17.string().nullish(),
5409
- page_number: z17.number().nullish(),
5410
- media_id: z17.string().nullish(),
5411
- start_index: z17.number().nullish(),
5412
- end_index: z17.number().nullish(),
5413
- custom_metadata: z17.record(z17.string(), z17.unknown()).nullish()
5424
+ const fileCitation = z18.object({
5425
+ type: z18.literal("file_citation"),
5426
+ file_name: z18.string().nullish(),
5427
+ document_uri: z18.string().nullish(),
5428
+ url: z18.string().nullish(),
5429
+ page_number: z18.number().nullish(),
5430
+ media_id: z18.string().nullish(),
5431
+ start_index: z18.number().nullish(),
5432
+ end_index: z18.number().nullish(),
5433
+ custom_metadata: z18.record(z18.string(), z18.unknown()).nullish()
5414
5434
  }).loose();
5415
- const placeCitation = z17.object({
5416
- type: z17.literal("place_citation"),
5417
- name: z17.string().nullish(),
5418
- url: z17.string().nullish(),
5419
- place_id: z17.string().nullish(),
5420
- start_index: z17.number().nullish(),
5421
- end_index: z17.number().nullish()
5435
+ const placeCitation = z18.object({
5436
+ type: z18.literal("place_citation"),
5437
+ name: z18.string().nullish(),
5438
+ url: z18.string().nullish(),
5439
+ place_id: z18.string().nullish(),
5440
+ start_index: z18.number().nullish(),
5441
+ end_index: z18.number().nullish()
5422
5442
  }).loose();
5423
- return z17.union([
5443
+ return z18.union([
5424
5444
  urlCitation,
5425
5445
  fileCitation,
5426
5446
  placeCitation,
5427
- z17.object({ type: z17.string() }).loose()
5447
+ z18.object({ type: z18.string() }).loose()
5428
5448
  ]);
5429
5449
  };
5430
- var thoughtSummaryItemSchema = () => z17.object({
5431
- type: z17.string(),
5432
- text: z17.string().nullish(),
5433
- data: z17.string().nullish(),
5434
- mime_type: z17.string().nullish()
5450
+ var thoughtSummaryItemSchema = () => z18.object({
5451
+ type: z18.string(),
5452
+ text: z18.string().nullish(),
5453
+ data: z18.string().nullish(),
5454
+ mime_type: z18.string().nullish()
5435
5455
  }).loose();
5436
5456
  var contentBlockSchema = () => {
5437
- const textContent = z17.object({
5438
- type: z17.literal("text"),
5439
- text: z17.string(),
5440
- annotations: z17.array(annotationSchema()).nullish()
5457
+ const textContent = z18.object({
5458
+ type: z18.literal("text"),
5459
+ text: z18.string(),
5460
+ annotations: z18.array(annotationSchema()).nullish()
5441
5461
  }).loose();
5442
- const imageContent = z17.object({
5443
- type: z17.literal("image"),
5444
- data: z17.string().nullish(),
5445
- mime_type: z17.string().nullish(),
5446
- resolution: z17.enum(["low", "medium", "high", "ultra_high"]).nullish(),
5447
- uri: z17.string().nullish()
5462
+ const imageContent = z18.object({
5463
+ type: z18.literal("image"),
5464
+ data: z18.string().nullish(),
5465
+ mime_type: z18.string().nullish(),
5466
+ resolution: z18.enum(["low", "medium", "high", "ultra_high"]).nullish(),
5467
+ uri: z18.string().nullish()
5448
5468
  }).loose();
5449
- const videoContent = z17.object({
5450
- type: z17.literal("video"),
5451
- data: z17.string().nullish(),
5452
- mime_type: z17.string().nullish(),
5453
- uri: z17.string().nullish()
5469
+ const videoContent = z18.object({
5470
+ type: z18.literal("video"),
5471
+ data: z18.string().nullish(),
5472
+ mime_type: z18.string().nullish(),
5473
+ uri: z18.string().nullish()
5454
5474
  }).loose();
5455
- return z17.union([
5475
+ return z18.union([
5456
5476
  textContent,
5457
5477
  imageContent,
5458
5478
  videoContent,
5459
- z17.object({ type: z17.string() }).loose()
5479
+ z18.object({ type: z18.string() }).loose()
5460
5480
  ]);
5461
5481
  };
5462
5482
  var BUILTIN_TOOL_CALL_STEP_TYPES = [
@@ -5476,73 +5496,73 @@ var BUILTIN_TOOL_RESULT_STEP_TYPES = [
5476
5496
  "mcp_server_tool_result"
5477
5497
  ];
5478
5498
  var stepSchema = () => {
5479
- const userInputStep = z17.object({
5480
- type: z17.literal("user_input"),
5481
- content: z17.array(contentBlockSchema()).nullish()
5499
+ const userInputStep = z18.object({
5500
+ type: z18.literal("user_input"),
5501
+ content: z18.array(contentBlockSchema()).nullish()
5482
5502
  }).loose();
5483
- const modelOutputStep = z17.object({
5484
- type: z17.literal("model_output"),
5485
- content: z17.array(contentBlockSchema()).nullish()
5503
+ const modelOutputStep = z18.object({
5504
+ type: z18.literal("model_output"),
5505
+ content: z18.array(contentBlockSchema()).nullish()
5486
5506
  }).loose();
5487
- const functionCallStep = z17.object({
5488
- type: z17.literal("function_call"),
5489
- id: z17.string(),
5490
- name: z17.string(),
5491
- arguments: z17.record(z17.string(), z17.unknown()).nullish(),
5492
- signature: z17.string().nullish()
5507
+ const functionCallStep = z18.object({
5508
+ type: z18.literal("function_call"),
5509
+ id: z18.string(),
5510
+ name: z18.string(),
5511
+ arguments: z18.record(z18.string(), z18.unknown()).nullish(),
5512
+ signature: z18.string().nullish()
5493
5513
  }).loose();
5494
- const thoughtStep = z17.object({
5495
- type: z17.literal("thought"),
5496
- signature: z17.string().nullish(),
5497
- summary: z17.array(thoughtSummaryItemSchema()).nullish()
5514
+ const thoughtStep = z18.object({
5515
+ type: z18.literal("thought"),
5516
+ signature: z18.string().nullish(),
5517
+ summary: z18.array(thoughtSummaryItemSchema()).nullish()
5498
5518
  }).loose();
5499
- const builtinToolCallStep = z17.object({
5500
- type: z17.enum(BUILTIN_TOOL_CALL_STEP_TYPES),
5501
- id: z17.string(),
5502
- arguments: z17.record(z17.string(), z17.unknown()).nullish(),
5503
- name: z17.string().nullish(),
5504
- server_name: z17.string().nullish(),
5505
- search_type: z17.string().nullish(),
5506
- signature: z17.string().nullish()
5519
+ const builtinToolCallStep = z18.object({
5520
+ type: z18.enum(BUILTIN_TOOL_CALL_STEP_TYPES),
5521
+ id: z18.string(),
5522
+ arguments: z18.record(z18.string(), z18.unknown()).nullish(),
5523
+ name: z18.string().nullish(),
5524
+ server_name: z18.string().nullish(),
5525
+ search_type: z18.string().nullish(),
5526
+ signature: z18.string().nullish()
5507
5527
  }).loose();
5508
- const builtinToolResultStep = z17.object({
5509
- type: z17.enum(BUILTIN_TOOL_RESULT_STEP_TYPES),
5510
- call_id: z17.string(),
5511
- result: z17.unknown().nullish(),
5512
- is_error: z17.boolean().nullish(),
5513
- name: z17.string().nullish(),
5514
- server_name: z17.string().nullish(),
5515
- signature: z17.string().nullish()
5528
+ const builtinToolResultStep = z18.object({
5529
+ type: z18.enum(BUILTIN_TOOL_RESULT_STEP_TYPES),
5530
+ call_id: z18.string(),
5531
+ result: z18.unknown().nullish(),
5532
+ is_error: z18.boolean().nullish(),
5533
+ name: z18.string().nullish(),
5534
+ server_name: z18.string().nullish(),
5535
+ signature: z18.string().nullish()
5516
5536
  }).loose();
5517
- return z17.union([
5537
+ return z18.union([
5518
5538
  userInputStep,
5519
5539
  modelOutputStep,
5520
5540
  functionCallStep,
5521
5541
  thoughtStep,
5522
5542
  builtinToolCallStep,
5523
5543
  builtinToolResultStep,
5524
- z17.object({ type: z17.string() }).loose()
5544
+ z18.object({ type: z18.string() }).loose()
5525
5545
  ]);
5526
5546
  };
5527
5547
  var googleInteractionsResponseSchema = lazySchema15(
5528
5548
  () => zodSchema15(
5529
- z17.object({
5549
+ z18.object({
5530
5550
  /*
5531
5551
  * `id` is omitted from the response body when `store: false` (fully
5532
5552
  * stateless mode) — there is no server-side interaction record for the
5533
5553
  * client to reference. `nullish` lets the schema accept that shape.
5534
5554
  */
5535
- id: z17.string().nullish(),
5536
- created: z17.string().nullish(),
5537
- updated: z17.string().nullish(),
5555
+ id: z18.string().nullish(),
5556
+ created: z18.string().nullish(),
5557
+ updated: z18.string().nullish(),
5538
5558
  status: interactionStatusSchema(),
5539
- model: z17.string().nullish(),
5540
- agent: z17.string().nullish(),
5541
- steps: z17.array(stepSchema()).nullish(),
5559
+ model: z18.string().nullish(),
5560
+ agent: z18.string().nullish(),
5561
+ steps: z18.array(stepSchema()).nullish(),
5542
5562
  usage: usageSchema2().nullish(),
5543
- service_tier: z17.string().nullish(),
5544
- previous_interaction_id: z17.string().nullish(),
5545
- response_modalities: z17.array(z17.string()).nullish()
5563
+ service_tier: z18.string().nullish(),
5564
+ previous_interaction_id: z18.string().nullish(),
5565
+ response_modalities: z18.array(z18.string()).nullish()
5546
5566
  }).loose()
5547
5567
  )
5548
5568
  );
@@ -5552,82 +5572,82 @@ var googleInteractionsEventSchema = lazySchema15(
5552
5572
  const status = interactionStatusSchema();
5553
5573
  const annotation = annotationSchema();
5554
5574
  const thoughtSummaryItem = thoughtSummaryItemSchema();
5555
- const interactionCreatedEvent = z17.object({
5556
- event_type: z17.literal("interaction.created"),
5557
- event_id: z17.string().nullish(),
5558
- interaction: z17.object({
5575
+ const interactionCreatedEvent = z18.object({
5576
+ event_type: z18.literal("interaction.created"),
5577
+ event_id: z18.string().nullish(),
5578
+ interaction: z18.object({
5559
5579
  /*
5560
5580
  * `id` is omitted when `store: false` (fully stateless mode);
5561
5581
  * see the matching note on `googleInteractionsResponseSchema.id`.
5562
5582
  */
5563
- id: z17.string().nullish(),
5564
- created: z17.string().nullish(),
5565
- model: z17.string().nullish(),
5566
- agent: z17.string().nullish(),
5583
+ id: z18.string().nullish(),
5584
+ created: z18.string().nullish(),
5585
+ model: z18.string().nullish(),
5586
+ agent: z18.string().nullish(),
5567
5587
  status: status.nullish()
5568
5588
  }).loose()
5569
5589
  }).loose();
5570
- const stepStartEvent = z17.object({
5571
- event_type: z17.literal("step.start"),
5572
- event_id: z17.string().nullish(),
5573
- index: z17.number(),
5590
+ const stepStartEvent = z18.object({
5591
+ event_type: z18.literal("step.start"),
5592
+ event_id: z18.string().nullish(),
5593
+ index: z18.number(),
5574
5594
  step: stepSchema()
5575
5595
  }).loose();
5576
- const stepDeltaText = z17.object({
5577
- type: z17.literal("text"),
5578
- text: z17.string()
5596
+ const stepDeltaText = z18.object({
5597
+ type: z18.literal("text"),
5598
+ text: z18.string()
5579
5599
  }).loose();
5580
- const stepDeltaThoughtSummary = z17.object({
5581
- type: z17.literal("thought_summary"),
5600
+ const stepDeltaThoughtSummary = z18.object({
5601
+ type: z18.literal("thought_summary"),
5582
5602
  content: thoughtSummaryItem.nullish()
5583
5603
  }).loose();
5584
- const stepDeltaThoughtSignature = z17.object({
5585
- type: z17.literal("thought_signature"),
5586
- signature: z17.string().nullish()
5604
+ const stepDeltaThoughtSignature = z18.object({
5605
+ type: z18.literal("thought_signature"),
5606
+ signature: z18.string().nullish()
5587
5607
  }).loose();
5588
- const stepDeltaArgumentsDelta = z17.object({
5589
- type: z17.literal("arguments_delta"),
5590
- arguments: z17.string().nullish(),
5591
- id: z17.string().nullish(),
5592
- signature: z17.string().nullish()
5608
+ const stepDeltaArgumentsDelta = z18.object({
5609
+ type: z18.literal("arguments_delta"),
5610
+ arguments: z18.string().nullish(),
5611
+ id: z18.string().nullish(),
5612
+ signature: z18.string().nullish()
5593
5613
  }).loose();
5594
- const stepDeltaTextAnnotation = z17.object({
5595
- type: z17.enum(["text_annotation_delta", "text_annotation"]),
5596
- annotations: z17.array(annotation).nullish()
5614
+ const stepDeltaTextAnnotation = z18.object({
5615
+ type: z18.enum(["text_annotation_delta", "text_annotation"]),
5616
+ annotations: z18.array(annotation).nullish()
5597
5617
  }).loose();
5598
- const stepDeltaImage = z17.object({
5599
- type: z17.literal("image"),
5600
- data: z17.string().nullish(),
5601
- mime_type: z17.string().nullish(),
5602
- resolution: z17.enum(["low", "medium", "high", "ultra_high"]).nullish(),
5603
- uri: z17.string().nullish()
5618
+ const stepDeltaImage = z18.object({
5619
+ type: z18.literal("image"),
5620
+ data: z18.string().nullish(),
5621
+ mime_type: z18.string().nullish(),
5622
+ resolution: z18.enum(["low", "medium", "high", "ultra_high"]).nullish(),
5623
+ uri: z18.string().nullish()
5604
5624
  }).loose();
5605
- const stepDeltaVideo = z17.object({
5606
- type: z17.literal("video"),
5607
- data: z17.string().nullish(),
5608
- mime_type: z17.string().nullish(),
5609
- uri: z17.string().nullish()
5625
+ const stepDeltaVideo = z18.object({
5626
+ type: z18.literal("video"),
5627
+ data: z18.string().nullish(),
5628
+ mime_type: z18.string().nullish(),
5629
+ uri: z18.string().nullish()
5610
5630
  }).loose();
5611
- const stepDeltaBuiltinToolCall = z17.object({
5612
- type: z17.enum(BUILTIN_TOOL_CALL_STEP_TYPES),
5613
- id: z17.string().nullish(),
5614
- arguments: z17.record(z17.string(), z17.unknown()).nullish(),
5615
- name: z17.string().nullish(),
5616
- server_name: z17.string().nullish(),
5617
- search_type: z17.string().nullish(),
5618
- signature: z17.string().nullish()
5631
+ const stepDeltaBuiltinToolCall = z18.object({
5632
+ type: z18.enum(BUILTIN_TOOL_CALL_STEP_TYPES),
5633
+ id: z18.string().nullish(),
5634
+ arguments: z18.record(z18.string(), z18.unknown()).nullish(),
5635
+ name: z18.string().nullish(),
5636
+ server_name: z18.string().nullish(),
5637
+ search_type: z18.string().nullish(),
5638
+ signature: z18.string().nullish()
5619
5639
  }).loose();
5620
- const stepDeltaBuiltinToolResult = z17.object({
5621
- type: z17.enum(BUILTIN_TOOL_RESULT_STEP_TYPES),
5622
- call_id: z17.string().nullish(),
5623
- result: z17.unknown().nullish(),
5624
- is_error: z17.boolean().nullish(),
5625
- name: z17.string().nullish(),
5626
- server_name: z17.string().nullish(),
5627
- signature: z17.string().nullish()
5640
+ const stepDeltaBuiltinToolResult = z18.object({
5641
+ type: z18.enum(BUILTIN_TOOL_RESULT_STEP_TYPES),
5642
+ call_id: z18.string().nullish(),
5643
+ result: z18.unknown().nullish(),
5644
+ is_error: z18.boolean().nullish(),
5645
+ name: z18.string().nullish(),
5646
+ server_name: z18.string().nullish(),
5647
+ signature: z18.string().nullish()
5628
5648
  }).loose();
5629
- const stepDeltaUnknown = z17.object({ type: z17.string() }).loose();
5630
- const stepDeltaUnion = z17.union([
5649
+ const stepDeltaUnknown = z18.object({ type: z18.string() }).loose();
5650
+ const stepDeltaUnion = z18.union([
5631
5651
  stepDeltaText,
5632
5652
  stepDeltaImage,
5633
5653
  stepDeltaVideo,
@@ -5639,55 +5659,55 @@ var googleInteractionsEventSchema = lazySchema15(
5639
5659
  stepDeltaBuiltinToolResult,
5640
5660
  stepDeltaUnknown
5641
5661
  ]);
5642
- const stepDeltaEvent = z17.object({
5643
- event_type: z17.literal("step.delta"),
5644
- event_id: z17.string().nullish(),
5645
- index: z17.number(),
5662
+ const stepDeltaEvent = z18.object({
5663
+ event_type: z18.literal("step.delta"),
5664
+ event_id: z18.string().nullish(),
5665
+ index: z18.number(),
5646
5666
  delta: stepDeltaUnion
5647
5667
  }).loose();
5648
- const stepStopEvent = z17.object({
5649
- event_type: z17.literal("step.stop"),
5650
- event_id: z17.string().nullish(),
5651
- index: z17.number()
5668
+ const stepStopEvent = z18.object({
5669
+ event_type: z18.literal("step.stop"),
5670
+ event_id: z18.string().nullish(),
5671
+ index: z18.number()
5652
5672
  }).loose();
5653
- const interactionStatusUpdateEvent = z17.object({
5654
- event_type: z17.literal("interaction.status_update"),
5655
- event_id: z17.string().nullish(),
5656
- interaction_id: z17.string().nullish(),
5673
+ const interactionStatusUpdateEvent = z18.object({
5674
+ event_type: z18.literal("interaction.status_update"),
5675
+ event_id: z18.string().nullish(),
5676
+ interaction_id: z18.string().nullish(),
5657
5677
  status: status.nullish()
5658
5678
  }).loose();
5659
- const interactionInProgressEvent = z17.object({
5660
- event_type: z17.literal("interaction.in_progress"),
5661
- event_id: z17.string().nullish(),
5662
- interaction_id: z17.string().nullish(),
5679
+ const interactionInProgressEvent = z18.object({
5680
+ event_type: z18.literal("interaction.in_progress"),
5681
+ event_id: z18.string().nullish(),
5682
+ interaction_id: z18.string().nullish(),
5663
5683
  status: status.nullish()
5664
5684
  }).loose();
5665
- const interactionRequiresActionEvent = z17.object({
5666
- event_type: z17.literal("interaction.requires_action"),
5667
- event_id: z17.string().nullish(),
5668
- interaction_id: z17.string().nullish(),
5685
+ const interactionRequiresActionEvent = z18.object({
5686
+ event_type: z18.literal("interaction.requires_action"),
5687
+ event_id: z18.string().nullish(),
5688
+ interaction_id: z18.string().nullish(),
5669
5689
  status: status.nullish()
5670
5690
  }).loose();
5671
- const interactionCompletedEvent = z17.object({
5672
- event_type: z17.literal("interaction.completed"),
5673
- event_id: z17.string().nullish(),
5674
- interaction: z17.object({
5675
- id: z17.string().nullish(),
5691
+ const interactionCompletedEvent = z18.object({
5692
+ event_type: z18.literal("interaction.completed"),
5693
+ event_id: z18.string().nullish(),
5694
+ interaction: z18.object({
5695
+ id: z18.string().nullish(),
5676
5696
  status: status.nullish(),
5677
5697
  usage: usageSchema2().nullish(),
5678
- service_tier: z17.string().nullish()
5698
+ service_tier: z18.string().nullish()
5679
5699
  }).loose()
5680
5700
  }).loose();
5681
- const errorEvent = z17.object({
5682
- event_type: z17.literal("error"),
5683
- event_id: z17.string().nullish(),
5684
- error: z17.object({
5685
- code: z17.string().nullish(),
5686
- message: z17.string().nullish()
5701
+ const errorEvent = z18.object({
5702
+ event_type: z18.literal("error"),
5703
+ event_id: z18.string().nullish(),
5704
+ error: z18.object({
5705
+ code: z18.string().nullish(),
5706
+ message: z18.string().nullish()
5687
5707
  }).loose().nullish()
5688
5708
  }).loose();
5689
- const unknownEvent = z17.object({ event_type: z17.string() }).loose();
5690
- return z17.union([
5709
+ const unknownEvent = z18.object({ event_type: z18.string() }).loose();
5710
+ return z18.union([
5691
5711
  interactionCreatedEvent,
5692
5712
  stepStartEvent,
5693
5713
  stepDeltaEvent,
@@ -5708,26 +5728,26 @@ import {
5708
5728
  lazySchema as lazySchema16,
5709
5729
  zodSchema as zodSchema16
5710
5730
  } from "@ai-sdk/provider-utils";
5711
- import { z as z18 } from "zod/v4";
5731
+ import { z as z19 } from "zod/v4";
5712
5732
  var googleInteractionsLanguageModelOptions = lazySchema16(
5713
5733
  () => zodSchema16(
5714
- z18.object({
5715
- previousInteractionId: z18.string().nullish(),
5716
- store: z18.boolean().nullish(),
5717
- agent: z18.string().nullish(),
5718
- agentConfig: z18.union([
5719
- z18.object({
5720
- type: z18.literal("dynamic")
5734
+ z19.object({
5735
+ previousInteractionId: z19.string().nullish(),
5736
+ store: z19.boolean().nullish(),
5737
+ agent: z19.string().nullish(),
5738
+ agentConfig: z19.union([
5739
+ z19.object({
5740
+ type: z19.literal("dynamic")
5721
5741
  }).loose(),
5722
- z18.object({
5723
- type: z18.literal("deep-research"),
5724
- thinkingSummaries: z18.enum(["auto", "none"]).nullish(),
5725
- visualization: z18.enum(["off", "auto"]).nullish(),
5726
- collaborativePlanning: z18.boolean().nullish()
5742
+ z19.object({
5743
+ type: z19.literal("deep-research"),
5744
+ thinkingSummaries: z19.enum(["auto", "none"]).nullish(),
5745
+ visualization: z19.enum(["off", "auto"]).nullish(),
5746
+ collaborativePlanning: z19.boolean().nullish()
5727
5747
  })
5728
5748
  ]).nullish(),
5729
- thinkingLevel: z18.enum(["minimal", "low", "medium", "high"]).nullish(),
5730
- thinkingSummaries: z18.enum(["auto", "none"]).nullish(),
5749
+ thinkingLevel: z19.enum(["minimal", "low", "medium", "high"]).nullish(),
5750
+ thinkingSummaries: z19.enum(["auto", "none"]).nullish(),
5731
5751
  /**
5732
5752
  * Output-format entries that map directly to the API's `response_format`
5733
5753
  * array. Use this to request image, audio, video, or non-JSON text
@@ -5737,17 +5757,17 @@ var googleInteractionsLanguageModelOptions = lazySchema16(
5737
5757
  * type: 'json', schema }` still drives JSON-mode and adds a matching
5738
5758
  * text entry automatically; entries listed here are appended.
5739
5759
  */
5740
- responseFormat: z18.array(
5741
- z18.union([
5742
- z18.object({
5743
- type: z18.literal("text"),
5744
- mimeType: z18.string().nullish(),
5745
- schema: z18.unknown().nullish()
5760
+ responseFormat: z19.array(
5761
+ z19.union([
5762
+ z19.object({
5763
+ type: z19.literal("text"),
5764
+ mimeType: z19.string().nullish(),
5765
+ schema: z19.unknown().nullish()
5746
5766
  }).loose(),
5747
- z18.object({
5748
- type: z18.literal("image"),
5749
- mimeType: z18.string().nullish(),
5750
- aspectRatio: z18.enum([
5767
+ z19.object({
5768
+ type: z19.literal("image"),
5769
+ mimeType: z19.string().nullish(),
5770
+ aspectRatio: z19.enum([
5751
5771
  "1:1",
5752
5772
  "2:3",
5753
5773
  "3:2",
@@ -5763,19 +5783,19 @@ var googleInteractionsLanguageModelOptions = lazySchema16(
5763
5783
  "1:4",
5764
5784
  "4:1"
5765
5785
  ]).nullish(),
5766
- imageSize: z18.enum(["1K", "2K", "4K", "512"]).nullish()
5786
+ imageSize: z19.enum(["1K", "2K", "4K", "512"]).nullish()
5767
5787
  }).loose(),
5768
- z18.object({
5769
- type: z18.literal("audio"),
5770
- mimeType: z18.string().nullish()
5788
+ z19.object({
5789
+ type: z19.literal("audio"),
5790
+ mimeType: z19.string().nullish()
5771
5791
  }).loose(),
5772
- z18.object({
5773
- type: z18.literal("video"),
5774
- aspectRatio: z18.enum(["16:9", "9:16"]).nullish(),
5775
- resolution: z18.enum(["360p", "720p", "1080p", "4k"]).nullish(),
5776
- duration: z18.string().nullish(),
5777
- delivery: z18.enum(["inline", "uri"]).nullish(),
5778
- gcsUri: z18.string().nullish()
5792
+ z19.object({
5793
+ type: z19.literal("video"),
5794
+ aspectRatio: z19.enum(["16:9", "9:16"]).nullish(),
5795
+ resolution: z19.enum(["360p", "720p", "1080p", "4k"]).nullish(),
5796
+ duration: z19.string().nullish(),
5797
+ delivery: z19.enum(["inline", "uri"]).nullish(),
5798
+ gcsUri: z19.string().nullish()
5779
5799
  }).loose()
5780
5800
  ])
5781
5801
  ).nullish(),
@@ -5785,8 +5805,8 @@ var googleInteractionsLanguageModelOptions = lazySchema16(
5785
5805
  * translates it into a matching `response_format` image entry and
5786
5806
  * emits a warning when set.
5787
5807
  */
5788
- imageConfig: z18.object({
5789
- aspectRatio: z18.enum([
5808
+ imageConfig: z19.object({
5809
+ aspectRatio: z19.enum([
5790
5810
  "1:1",
5791
5811
  "2:3",
5792
5812
  "3:2",
@@ -5802,35 +5822,35 @@ var googleInteractionsLanguageModelOptions = lazySchema16(
5802
5822
  "1:4",
5803
5823
  "4:1"
5804
5824
  ]).nullish(),
5805
- imageSize: z18.enum(["1K", "2K", "4K", "512"]).nullish()
5825
+ imageSize: z19.enum(["1K", "2K", "4K", "512"]).nullish()
5806
5826
  }).nullish(),
5807
- mediaResolution: z18.enum(["low", "medium", "high", "ultra_high"]).nullish(),
5808
- responseModalities: z18.array(z18.enum(["text", "image", "audio", "video", "document"])).nullish(),
5809
- serviceTier: z18.enum(["flex", "standard", "priority"]).nullish(),
5827
+ mediaResolution: z19.enum(["low", "medium", "high", "ultra_high"]).nullish(),
5828
+ responseModalities: z19.array(z19.enum(["text", "image", "audio", "video", "document"])).nullish(),
5829
+ serviceTier: z19.enum(["flex", "standard", "priority"]).nullish(),
5810
5830
  /**
5811
5831
  * Alternative to AI SDK `system` message. If both are set, the AI SDK
5812
5832
  * `system` message wins and a warning is emitted.
5813
5833
  */
5814
- systemInstruction: z18.string().nullish(),
5834
+ systemInstruction: z19.string().nullish(),
5815
5835
  /**
5816
5836
  * Per-block signature for round-tripping `thought.signature` and
5817
5837
  * `function_call.signature` blocks. Set by the SDK on output reasoning /
5818
5838
  * tool-call parts; passed back unchanged on input parts so the API
5819
5839
  * accepts the prior turn.
5820
5840
  */
5821
- signature: z18.string().nullish(),
5841
+ signature: z19.string().nullish(),
5822
5842
  /**
5823
5843
  * Set by the SDK on output assistant messages. The converter uses it to
5824
5844
  * decide which messages to drop when compacting under
5825
5845
  * `previousInteractionId`.
5826
5846
  */
5827
- interactionId: z18.string().nullish(),
5847
+ interactionId: z19.string().nullish(),
5828
5848
  /**
5829
5849
  * Maximum time, in milliseconds, to poll a background interaction (agent
5830
5850
  * call) before giving up. Defaults to 30 minutes. Long-running agents
5831
5851
  * such as deep research can take tens of minutes — increase if needed.
5832
5852
  */
5833
- pollingTimeoutMs: z18.number().int().positive().nullish(),
5853
+ pollingTimeoutMs: z19.number().int().positive().nullish(),
5834
5854
  /**
5835
5855
  * Run the interaction in the background. Required for agents whose
5836
5856
  * server-side workflow cannot complete within a single request/response.
@@ -5839,7 +5859,7 @@ var googleInteractionsLanguageModelOptions = lazySchema16(
5839
5859
  * reject `true`; see the agent's documentation for which mode it
5840
5860
  * requires.
5841
5861
  */
5842
- background: z18.boolean().nullish(),
5862
+ background: z19.boolean().nullish(),
5843
5863
  /**
5844
5864
  * Environment configuration for the agent sandbox. Only applies to agent
5845
5865
  * calls (`google.interactions({ agent })`); ignored on model-id calls.
@@ -5849,36 +5869,36 @@ var googleInteractionsLanguageModelOptions = lazySchema16(
5849
5869
  * - object: provision a fresh sandbox and optionally preload `sources`
5850
5870
  * and/or constrain outbound traffic via `network`.
5851
5871
  */
5852
- environment: z18.union([
5853
- z18.string(),
5854
- z18.object({
5855
- type: z18.literal("remote"),
5856
- sources: z18.array(
5857
- z18.union([
5858
- z18.object({
5859
- type: z18.literal("gcs"),
5860
- source: z18.string(),
5861
- target: z18.string().nullish()
5872
+ environment: z19.union([
5873
+ z19.string(),
5874
+ z19.object({
5875
+ type: z19.literal("remote"),
5876
+ sources: z19.array(
5877
+ z19.union([
5878
+ z19.object({
5879
+ type: z19.literal("gcs"),
5880
+ source: z19.string(),
5881
+ target: z19.string().nullish()
5862
5882
  }),
5863
- z18.object({
5864
- type: z18.literal("repository"),
5865
- source: z18.string(),
5866
- target: z18.string().nullish()
5883
+ z19.object({
5884
+ type: z19.literal("repository"),
5885
+ source: z19.string(),
5886
+ target: z19.string().nullish()
5867
5887
  }),
5868
- z18.object({
5869
- type: z18.literal("inline"),
5870
- content: z18.string(),
5871
- target: z18.string()
5888
+ z19.object({
5889
+ type: z19.literal("inline"),
5890
+ content: z19.string(),
5891
+ target: z19.string()
5872
5892
  })
5873
5893
  ])
5874
5894
  ).nullish(),
5875
- network: z18.union([
5876
- z18.literal("disabled"),
5877
- z18.object({
5878
- allowlist: z18.array(
5879
- z18.object({
5880
- domain: z18.string(),
5881
- transform: z18.array(z18.record(z18.string(), z18.string())).nullish()
5895
+ network: z19.union([
5896
+ z19.literal("disabled"),
5897
+ z19.object({
5898
+ allowlist: z19.array(
5899
+ z19.object({
5900
+ domain: z19.string(),
5901
+ transform: z19.array(z19.record(z19.string(), z19.string())).nullish()
5882
5902
  })
5883
5903
  )
5884
5904
  })