@ai-sdk/amazon-bedrock 5.0.62 → 5.0.66

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.js CHANGED
@@ -11,6 +11,7 @@ import {
11
11
  // src/amazon-bedrock-chat-language-model.ts
12
12
  import {
13
13
  combineHeaders,
14
+ createProviderStreamError,
14
15
  createJsonErrorResponseHandler,
15
16
  createJsonResponseHandler,
16
17
  injectJsonInstructionIntoMessages,
@@ -87,6 +88,13 @@ var amazonBedrockFilePartProviderOptions = z.object({
87
88
  enabled: z.boolean()
88
89
  }).optional()
89
90
  });
91
+ var amazonBedrockTextPartProviderOptions = z.object({
92
+ guardContent: z.boolean().optional(),
93
+ guardContentQualifiers: z.array(z.enum(["grounding_source", "query", "guard_content"])).optional()
94
+ });
95
+ var amazonBedrockImagePartProviderOptions = z.object({
96
+ guardContent: z.boolean().optional()
97
+ });
90
98
  var amazonBedrockLanguageModelChatOptions = z.object({
91
99
  /**
92
100
  * Additional inference parameters that the model supports,
@@ -245,6 +253,29 @@ var createAmazonBedrockEventStreamResponseHandler = (chunkSchema) => async ({ re
245
253
  };
246
254
  };
247
255
 
256
+ // src/amazon-bedrock-stream-error.ts
257
+ function getAmazonBedrockStreamErrorMetadata(type) {
258
+ switch (type) {
259
+ case "internalServerException":
260
+ case "InternalServerException":
261
+ return { statusCode: 500, isRetryable: true };
262
+ case "modelStreamErrorException":
263
+ case "ModelStreamErrorException":
264
+ return { statusCode: 424, isRetryable: true };
265
+ case "serviceUnavailableException":
266
+ case "ServiceUnavailableException":
267
+ return { statusCode: 503, isRetryable: true };
268
+ case "throttlingException":
269
+ case "ThrottlingException":
270
+ return { statusCode: 429, isRetryable: true };
271
+ case "validationException":
272
+ case "ValidationException":
273
+ return { statusCode: 400, isRetryable: false };
274
+ default:
275
+ return {};
276
+ }
277
+ }
278
+
248
279
  // src/amazon-bedrock-prepare-tools.ts
249
280
  import {
250
281
  UnsupportedFunctionalityError
@@ -257,7 +288,8 @@ import {
257
288
  async function prepareTools({
258
289
  tools,
259
290
  toolChoice,
260
- modelId
291
+ modelId,
292
+ disableParallelToolUse
261
293
  }) {
262
294
  var _a;
263
295
  const toolWarnings = [];
@@ -303,6 +335,7 @@ async function prepareTools({
303
335
  } = await prepareAnthropicTools({
304
336
  tools: ProviderTools,
305
337
  toolChoice,
338
+ disableParallelToolUse,
306
339
  supportsStructuredOutput: false,
307
340
  supportsStrictTools: false
308
341
  });
@@ -358,8 +391,17 @@ async function prepareTools({
358
391
  }
359
392
  });
360
393
  }
394
+ if (isAnthropicModel && !usingAnthropicTools && disableParallelToolUse && amazonBedrockTools.length > 0 && (toolChoice == null ? void 0 : toolChoice.type) !== "none") {
395
+ additionalTools = {
396
+ tool_choice: (toolChoice == null ? void 0 : toolChoice.type) === "required" ? { type: "any", disable_parallel_tool_use: true } : (toolChoice == null ? void 0 : toolChoice.type) === "tool" ? {
397
+ type: "tool",
398
+ name: toolChoice.toolName,
399
+ disable_parallel_tool_use: true
400
+ } : { type: "auto", disable_parallel_tool_use: true }
401
+ };
402
+ }
361
403
  let amazonBedrockToolChoice = void 0;
362
- if (!usingAnthropicTools && amazonBedrockTools.length > 0 && toolChoice) {
404
+ if (!usingAnthropicTools && (additionalTools == null ? void 0 : additionalTools.tool_choice) == null && amazonBedrockTools.length > 0 && toolChoice) {
363
405
  const type = toolChoice.type;
364
406
  switch (type) {
365
407
  case "auto":
@@ -501,6 +543,30 @@ async function shouldEnableCitations(providerMetadata) {
501
543
  });
502
544
  return (_c = (_b = amazonBedrockOptions == null ? void 0 : amazonBedrockOptions.citations) == null ? void 0 : _b.enabled) != null ? _c : false;
503
545
  }
546
+ async function getTextPartGuardContentOptions(providerMetadata) {
547
+ var _a;
548
+ return (_a = await parseProviderOptions({
549
+ provider: "amazonBedrock",
550
+ providerOptions: providerMetadata,
551
+ schema: amazonBedrockTextPartProviderOptions
552
+ })) != null ? _a : await parseProviderOptions({
553
+ provider: "bedrock",
554
+ providerOptions: providerMetadata,
555
+ schema: amazonBedrockTextPartProviderOptions
556
+ });
557
+ }
558
+ async function getImagePartGuardContentOptions(providerMetadata) {
559
+ var _a;
560
+ return (_a = await parseProviderOptions({
561
+ provider: "amazonBedrock",
562
+ providerOptions: providerMetadata,
563
+ schema: amazonBedrockImagePartProviderOptions
564
+ })) != null ? _a : await parseProviderOptions({
565
+ provider: "bedrock",
566
+ providerOptions: providerMetadata,
567
+ schema: amazonBedrockImagePartProviderOptions
568
+ });
569
+ }
504
570
  async function convertToAmazonBedrockChatMessages(prompt, isMistral = false) {
505
571
  var _a, _b;
506
572
  const blocks = groupIntoBlocks(prompt);
@@ -538,9 +604,23 @@ async function convertToAmazonBedrockChatMessages(prompt, isMistral = false) {
538
604
  const part = content[j];
539
605
  switch (part.type) {
540
606
  case "text": {
541
- amazonBedrockContent.push({
542
- text: part.text
543
- });
607
+ const textOptions = await getTextPartGuardContentOptions(
608
+ part.providerOptions
609
+ );
610
+ if (textOptions == null ? void 0 : textOptions.guardContent) {
611
+ amazonBedrockContent.push({
612
+ guardContent: {
613
+ text: {
614
+ text: part.text,
615
+ qualifiers: textOptions.guardContentQualifiers
616
+ }
617
+ }
618
+ });
619
+ } else {
620
+ amazonBedrockContent.push({
621
+ text: part.text
622
+ });
623
+ }
544
624
  break;
545
625
  }
546
626
  case "file": {
@@ -615,7 +695,10 @@ async function convertToAmazonBedrockChatMessages(prompt, isMistral = false) {
615
695
  const fullMediaType = resolveFullMediaType({ part });
616
696
  switch (getTopLevelMediaType(fullMediaType)) {
617
697
  case "image": {
618
- amazonBedrockContent.push({
698
+ const imageOptions = await getImagePartGuardContentOptions(
699
+ part.providerOptions
700
+ );
701
+ const imageBlock = {
619
702
  image: {
620
703
  format: getAmazonBedrockImageFormat(fullMediaType),
621
704
  source: getAmazonBedrockMediaSource({
@@ -623,7 +706,14 @@ async function convertToAmazonBedrockChatMessages(prompt, isMistral = false) {
623
706
  functionality: "File URL data"
624
707
  })
625
708
  }
626
- });
709
+ };
710
+ if (imageOptions == null ? void 0 : imageOptions.guardContent) {
711
+ amazonBedrockContent.push({
712
+ guardContent: imageBlock
713
+ });
714
+ } else {
715
+ amazonBedrockContent.push(imageBlock);
716
+ }
627
717
  break;
628
718
  }
629
719
  case "video": {
@@ -989,6 +1079,22 @@ function mapAmazonBedrockFinishReason(finishReason, isJsonResponseFromTool) {
989
1079
  }
990
1080
 
991
1081
  // src/amazon-bedrock-chat-language-model.ts
1082
+ var anthropicProviderOptions = z4.object({
1083
+ disableParallelToolUse: z4.boolean().optional()
1084
+ });
1085
+ function createAmazonBedrockStreamError({
1086
+ type,
1087
+ error,
1088
+ data
1089
+ }) {
1090
+ const message = typeof error.message === "string" ? error.message : `Amazon Bedrock stream failed with ${type}`;
1091
+ return createProviderStreamError({
1092
+ message,
1093
+ type,
1094
+ ...getAmazonBedrockStreamErrorMetadata(type),
1095
+ data
1096
+ });
1097
+ }
992
1098
  var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
993
1099
  constructor(modelId, config) {
994
1100
  this.modelId = modelId;
@@ -1025,7 +1131,7 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1025
1131
  reasoning,
1026
1132
  providerOptions
1027
1133
  }) {
1028
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
1134
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s;
1029
1135
  let amazonBedrockOptions = (_b = (_a = await parseProviderOptions2({
1030
1136
  provider: "amazonBedrock",
1031
1137
  providerOptions,
@@ -1035,6 +1141,11 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1035
1141
  providerOptions,
1036
1142
  schema: amazonBedrockLanguageModelChatOptions
1037
1143
  })) != null ? _b : {};
1144
+ const anthropicOptions = await parseProviderOptions2({
1145
+ provider: "anthropic",
1146
+ providerOptions,
1147
+ schema: anthropicProviderOptions
1148
+ });
1038
1149
  const warnings = [];
1039
1150
  if (frequencyPenalty != null) {
1040
1151
  warnings.push({
@@ -1077,7 +1188,9 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1077
1188
  });
1078
1189
  }
1079
1190
  const isAnthropicModel = this.modelId.includes("anthropic");
1080
- const isOpenAIModel = this.modelId.startsWith("openai.");
1191
+ const openAIModelId = (_c = /^(?:[^.]+\.)?(openai\..+)$/.exec(this.modelId)) == null ? void 0 : _c[1];
1192
+ const isOpenAIModel = openAIModelId != null;
1193
+ const isOpenAIGptOssModel = (_d = openAIModelId == null ? void 0 : openAIModelId.startsWith("openai.gpt-oss-")) != null ? _d : false;
1081
1194
  amazonBedrockOptions = resolveAmazonBedrockReasoningConfig({
1082
1195
  reasoning,
1083
1196
  amazonBedrockOptions,
@@ -1085,7 +1198,7 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1085
1198
  isAnthropicModel,
1086
1199
  modelId: this.modelId
1087
1200
  });
1088
- const isThinkingEnabled = ((_c = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _c.type) === "enabled" || ((_d = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _d.type) === "adaptive";
1201
+ const isThinkingEnabled = ((_e = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _e.type) === "enabled" || ((_f = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _f.type) === "adaptive";
1089
1202
  const { supportsStructuredOutput: modelSupportsStructuredOutput } = getModelCapabilities(this.modelId);
1090
1203
  const useNativeStructuredOutput = isAnthropicModel && supportsNativeStructuredOutput(this.modelId) && (modelSupportsStructuredOutput || isThinkingEnabled) && (responseFormat == null ? void 0 : responseFormat.type) === "json" && responseFormat.schema != null;
1091
1204
  const useJsonInstructionForStructuredOutput = isAnthropicModel && !supportsStrictTools(this.modelId) && (responseFormat == null ? void 0 : responseFormat.type) === "json" && responseFormat.schema != null && tools != null && tools.length > 0;
@@ -1098,7 +1211,8 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1098
1211
  const { toolConfig, additionalTools, toolWarnings, betas } = await prepareTools({
1099
1212
  tools: jsonResponseTool ? [...tools != null ? tools : [], jsonResponseTool] : tools,
1100
1213
  toolChoice: jsonResponseTool != null ? { type: "required" } : toolChoice,
1101
- modelId: this.modelId
1214
+ modelId: this.modelId,
1215
+ disableParallelToolUse: anthropicOptions == null ? void 0 : anthropicOptions.disableParallelToolUse
1102
1216
  });
1103
1217
  warnings.push(...toolWarnings);
1104
1218
  if (additionalTools) {
@@ -1108,16 +1222,16 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1108
1222
  };
1109
1223
  }
1110
1224
  if (betas.size > 0 || amazonBedrockOptions.anthropicBeta) {
1111
- const existingBetas = (_e = amazonBedrockOptions.anthropicBeta) != null ? _e : [];
1225
+ const existingBetas = (_g = amazonBedrockOptions.anthropicBeta) != null ? _g : [];
1112
1226
  const mergedBetas = betas.size > 0 ? [...existingBetas, ...Array.from(betas)] : existingBetas;
1113
1227
  amazonBedrockOptions.additionalModelRequestFields = {
1114
1228
  ...amazonBedrockOptions.additionalModelRequestFields,
1115
1229
  anthropic_beta: mergedBetas
1116
1230
  };
1117
1231
  }
1118
- const thinkingType = (_f = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _f.type;
1119
- const thinkingBudget = thinkingType === "enabled" ? (_g = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _g.budgetTokens : void 0;
1120
- const thinkingDisplay = thinkingType === "adaptive" ? (_h = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _h.display : void 0;
1232
+ const thinkingType = (_h = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _h.type;
1233
+ const thinkingBudget = thinkingType === "enabled" ? (_i = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _i.budgetTokens : void 0;
1234
+ const thinkingDisplay = thinkingType === "adaptive" ? (_j = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _j.display : void 0;
1121
1235
  const isAnthropicThinkingEnabled = isAnthropicModel && isThinkingEnabled;
1122
1236
  const inferenceConfig = {
1123
1237
  ...maxOutputTokens != null && { maxTokens: maxOutputTokens },
@@ -1150,7 +1264,7 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1150
1264
  };
1151
1265
  }
1152
1266
  } else if (!isAnthropicModel) {
1153
- if (((_i = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _i.budgetTokens) != null) {
1267
+ if (((_k = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _k.budgetTokens) != null) {
1154
1268
  warnings.push({
1155
1269
  type: "unsupported",
1156
1270
  feature: "budgetTokens",
@@ -1165,20 +1279,26 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1165
1279
  });
1166
1280
  }
1167
1281
  }
1168
- const maxReasoningEffort = (_j = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _j.maxReasoningEffort;
1282
+ const maxReasoningEffort = (_l = amazonBedrockOptions.reasoningConfig) == null ? void 0 : _l.maxReasoningEffort;
1169
1283
  if (maxReasoningEffort != null) {
1170
1284
  if (isAnthropicModel) {
1171
1285
  amazonBedrockOptions.additionalModelRequestFields = {
1172
1286
  ...amazonBedrockOptions.additionalModelRequestFields,
1173
1287
  output_config: {
1174
- ...(_k = amazonBedrockOptions.additionalModelRequestFields) == null ? void 0 : _k.output_config,
1288
+ ...(_m = amazonBedrockOptions.additionalModelRequestFields) == null ? void 0 : _m.output_config,
1175
1289
  effort: maxReasoningEffort
1176
1290
  }
1177
1291
  };
1178
1292
  } else if (isOpenAIModel) {
1179
- amazonBedrockOptions.additionalModelRequestFields = {
1293
+ amazonBedrockOptions.additionalModelRequestFields = isOpenAIGptOssModel ? {
1180
1294
  ...amazonBedrockOptions.additionalModelRequestFields,
1181
1295
  reasoning_effort: maxReasoningEffort
1296
+ } : {
1297
+ ...amazonBedrockOptions.additionalModelRequestFields,
1298
+ reasoning: {
1299
+ ...(_n = amazonBedrockOptions.additionalModelRequestFields) == null ? void 0 : _n.reasoning,
1300
+ effort: maxReasoningEffort
1301
+ }
1182
1302
  };
1183
1303
  } else {
1184
1304
  amazonBedrockOptions.additionalModelRequestFields = {
@@ -1195,7 +1315,7 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1195
1315
  amazonBedrockOptions.additionalModelRequestFields = {
1196
1316
  ...amazonBedrockOptions.additionalModelRequestFields,
1197
1317
  output_config: {
1198
- ...(_l = amazonBedrockOptions.additionalModelRequestFields) == null ? void 0 : _l.output_config,
1318
+ ...(_o = amazonBedrockOptions.additionalModelRequestFields) == null ? void 0 : _o.output_config,
1199
1319
  format: {
1200
1320
  type: "json_schema",
1201
1321
  schema: sanitizeJsonSchema(responseFormat.schema)
@@ -1227,7 +1347,7 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1227
1347
  details: "topK is not supported when thinking is enabled"
1228
1348
  });
1229
1349
  }
1230
- const hasAnyTools = ((_n = (_m = toolConfig.tools) == null ? void 0 : _m.length) != null ? _n : 0) > 0 || additionalTools;
1350
+ const hasAnyTools = ((_q = (_p = toolConfig.tools) == null ? void 0 : _p.length) != null ? _q : 0) > 0 || additionalTools;
1231
1351
  let filteredPrompt = prompt;
1232
1352
  if (!hasAnyTools) {
1233
1353
  const hasToolContent = prompt.some(
@@ -1270,7 +1390,7 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1270
1390
  additionalModelRequestFields: __,
1271
1391
  serviceTier: ___,
1272
1392
  ...filteredAmazonBedrockOptions
1273
- } = (_p = (_o = providerOptions == null ? void 0 : providerOptions.amazonBedrock) != null ? _o : providerOptions == null ? void 0 : providerOptions.bedrock) != null ? _p : {};
1393
+ } = (_s = (_r = providerOptions == null ? void 0 : providerOptions.amazonBedrock) != null ? _r : providerOptions == null ? void 0 : providerOptions.bedrock) != null ? _s : {};
1274
1394
  const additionalModelResponseFieldPaths = isAnthropicModel ? ["/delta/stop_sequence"] : void 0;
1275
1395
  return {
1276
1396
  command: {
@@ -1499,36 +1619,53 @@ var AmazonBedrockChatLanguageModel = class _AmazonBedrockChatLanguageModel {
1499
1619
  },
1500
1620
  transform(chunk, controller) {
1501
1621
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r;
1502
- function enqueueError(amazonBedrockError) {
1622
+ function enqueueError(type, amazonBedrockError) {
1503
1623
  finishReason = { unified: "error", raw: void 0 };
1504
- controller.enqueue({ type: "error", error: amazonBedrockError });
1624
+ controller.enqueue({
1625
+ type: "error",
1626
+ error: createAmazonBedrockStreamError({
1627
+ type,
1628
+ error: amazonBedrockError,
1629
+ data: chunk.rawValue
1630
+ })
1631
+ });
1505
1632
  }
1506
1633
  if (options.includeRawChunks) {
1507
1634
  controller.enqueue({ type: "raw", rawValue: chunk.rawValue });
1508
1635
  }
1509
1636
  if (!chunk.success) {
1510
- enqueueError(chunk.error);
1637
+ finishReason = { unified: "error", raw: void 0 };
1638
+ controller.enqueue({ type: "error", error: chunk.error });
1511
1639
  return;
1512
1640
  }
1513
1641
  const value = chunk.value;
1514
1642
  if (value.internalServerException) {
1515
- enqueueError(value.internalServerException);
1643
+ enqueueError(
1644
+ "internalServerException",
1645
+ value.internalServerException
1646
+ );
1516
1647
  return;
1517
1648
  }
1518
1649
  if (value.modelStreamErrorException) {
1519
- enqueueError(value.modelStreamErrorException);
1650
+ enqueueError(
1651
+ "modelStreamErrorException",
1652
+ value.modelStreamErrorException
1653
+ );
1520
1654
  return;
1521
1655
  }
1522
1656
  if (value.serviceUnavailableException) {
1523
- enqueueError(value.serviceUnavailableException);
1657
+ enqueueError(
1658
+ "serviceUnavailableException",
1659
+ value.serviceUnavailableException
1660
+ );
1524
1661
  return;
1525
1662
  }
1526
1663
  if (value.throttlingException) {
1527
- enqueueError(value.throttlingException);
1664
+ enqueueError("throttlingException", value.throttlingException);
1528
1665
  return;
1529
1666
  }
1530
1667
  if (value.validationException) {
1531
- enqueueError(value.validationException);
1668
+ enqueueError("validationException", value.validationException);
1532
1669
  return;
1533
1670
  }
1534
1671
  if (value.messageStop) {
@@ -1876,6 +2013,10 @@ var AmazonBedrockReasoningTextSchema = z4.object({
1876
2013
  var AmazonBedrockRedactedReasoningSchema = z4.object({
1877
2014
  data: z4.string()
1878
2015
  });
2016
+ var AmazonBedrockCacheDetailSchema = z4.object({
2017
+ inputTokens: z4.number(),
2018
+ ttl: z4.string()
2019
+ }).catchall(z4.json());
1879
2020
  var AmazonBedrockResponseSchema = z4.object({
1880
2021
  metrics: z4.object({
1881
2022
  latencyMs: z4.number()
@@ -1917,8 +2058,8 @@ var AmazonBedrockResponseSchema = z4.object({
1917
2058
  totalTokens: z4.number(),
1918
2059
  cacheReadInputTokens: z4.number().nullish(),
1919
2060
  cacheWriteInputTokens: z4.number().nullish(),
1920
- cacheDetails: z4.array(z4.object({ inputTokens: z4.number(), ttl: z4.string() })).nullish()
1921
- })
2061
+ cacheDetails: z4.array(AmazonBedrockCacheDetailSchema).nullish()
2062
+ }).catchall(z4.json())
1922
2063
  });
1923
2064
  var AmazonBedrockStreamSchema = z4.object({
1924
2065
  contentBlockDelta: z4.object({
@@ -1966,10 +2107,11 @@ var AmazonBedrockStreamSchema = z4.object({
1966
2107
  usage: z4.object({
1967
2108
  cacheReadInputTokens: z4.number().nullish(),
1968
2109
  cacheWriteInputTokens: z4.number().nullish(),
1969
- cacheDetails: z4.array(z4.object({ inputTokens: z4.number(), ttl: z4.string() })).nullish(),
2110
+ cacheDetails: z4.array(AmazonBedrockCacheDetailSchema).nullish(),
1970
2111
  inputTokens: z4.number(),
1971
- outputTokens: z4.number()
1972
- }).nullish()
2112
+ outputTokens: z4.number(),
2113
+ totalTokens: z4.number().optional()
2114
+ }).catchall(z4.json()).nullish()
1973
2115
  }).nullish(),
1974
2116
  modelStreamErrorException: z4.record(z4.string(), z4.unknown()).nullish(),
1975
2117
  serviceUnavailableException: z4.record(z4.string(), z4.unknown()).nullish(),
@@ -2548,7 +2690,7 @@ import {
2548
2690
  import { AwsV4Signer } from "aws4fetch";
2549
2691
 
2550
2692
  // src/version.ts
2551
- var VERSION = true ? "5.0.62" : "0.0.0-test";
2693
+ var VERSION = true ? "5.0.66" : "0.0.0-test";
2552
2694
 
2553
2695
  // src/amazon-bedrock-sigv4-fetch.ts
2554
2696
  function createSigV4FetchFunction(getCredentials, fetch, service = "bedrock") {