@redocly/replay 0.27.0-next.9 → 0.27.0

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.
Files changed (69) hide show
  1. package/dist/{replay-AiChatProvider-B94RnQsz.js → replay-AiChatProvider-LQhrLIDL.js} +44 -44
  2. package/dist/{replay-AiChatProvider-P2u2MtTk.js → replay-AiChatProvider-Oms5CFgT.js} +1 -1
  3. package/dist/{replay-AiChatSqliteDBStorage-z_QUPu2M.js → replay-AiChatSqliteDBStorage-3-p1mthX.js} +1 -1
  4. package/dist/{replay-AiChatSqliteDBStorage-BtTa9KkQ.js → replay-AiChatSqliteDBStorage-GZibdHOQ.js} +1 -1
  5. package/dist/replay-AiPanel-BvwwBTh1.js +742 -0
  6. package/dist/{replay-AiPanel-BCkDovN_.js → replay-AiPanel-lcDNvgo0.js} +973 -1176
  7. package/dist/replay-FileWatcher-ClVd_wG0.js +1 -0
  8. package/dist/replay-FileWatcher-DR-wJLe2.js +343 -0
  9. package/dist/replay-Observable-D6wKbFwB.js +31 -0
  10. package/dist/replay-Observable-bjJ6wkRB.js +1 -0
  11. package/dist/replay-SemanticSearchService-CCqwCRo6.js +1 -0
  12. package/dist/replay-SemanticSearchService-U1eXQGfF.js +723 -0
  13. package/dist/{replay-SqliteDBStorage-DMxFWJQ7.js → replay-SqliteDBStorage-Dn6DoVWW.js} +1 -1
  14. package/dist/{replay-SqliteDBStorage-D9b6LAKr.js → replay-SqliteDBStorage-d_ZK6ScA.js} +1 -1
  15. package/dist/replay-TauriFileSystemAdapter-CpiUuG3T.js +99 -0
  16. package/dist/replay-TauriFileSystemAdapter-dwJ0xBYr.js +1 -0
  17. package/dist/replay-TauriRootStorage-CuVbYMXX.js +605 -0
  18. package/dist/replay-TauriRootStorage-DhzbAahU.js +1 -0
  19. package/dist/{replay-agent-loop-C2QNfRSA.js → replay-agent-loop-BLSu4v_O.js} +1 -1
  20. package/dist/{replay-agent-loop-C8ERLqB5.js → replay-agent-loop-DgEHdXUt.js} +11 -11
  21. package/dist/{replay-ai-chat-mappers-fViZvzIy.js → replay-ai-chat-mappers-BvfcEubB.js} +5 -5
  22. package/dist/{replay-ai-chat-mappers-BMhtm64Y.js → replay-ai-chat-mappers-Dy2kJ7ZG.js} +1 -1
  23. package/dist/replay-core-BJmXmoC5.js +1 -0
  24. package/dist/replay-core-B_hiOZZr.js +10 -0
  25. package/dist/{replay-create-model-BhuazQ2q.js → replay-create-model-DNPFcOIp.js} +579 -578
  26. package/dist/{replay-create-model-BgR6vFGV.js → replay-create-model-bOIDB-e8.js} +10 -10
  27. package/dist/{replay-db-DAiJFj0l.js → replay-db-BQGv3PGw.js} +1 -1
  28. package/dist/{replay-db-DKzJowQC.js → replay-db-CMXZZs9v.js} +1 -1
  29. package/dist/{replay-external-resolver-UONYkON2.js → replay-external-resolver-mrykFC2h.js} +2 -2
  30. package/dist/{replay-external-resolver-BY6AAeGp.js → replay-external-resolver-n5OvQMRF.js} +1 -1
  31. package/dist/replay-index-3lwhSmvi.js +1 -0
  32. package/dist/{replay-index-BowK-_3Z.js → replay-index-Bc5RHu5L.js} +23698 -25407
  33. package/dist/replay-index-CFLu-XMV.js +25 -0
  34. package/dist/{replay-index-DWKlhkdU.js → replay-index-CHGVyIdG.js} +1 -1
  35. package/dist/replay-index-CSR_qlua.js +1 -0
  36. package/dist/replay-index-CepJ5Z0m.js +6875 -0
  37. package/dist/{replay-index-amF_dPN8.js → replay-index-CgCGhu4l.js} +6 -6
  38. package/dist/replay-index-DDjmUXWm.js +1 -0
  39. package/dist/{replay-index-DM12kT-D.js → replay-index-DiSy_1OY.js} +1 -1
  40. package/dist/replay-index-Oct6Dygd.js +1 -0
  41. package/dist/{replay-index-BubK_s3I.js → replay-index-QXosJxRc.js} +18 -18
  42. package/dist/replay-index-jkDlU0Lx.js +32 -0
  43. package/dist/{replay-lint-CAN3a2zf.js → replay-lint-DoHQIATV.js} +3 -3
  44. package/dist/{replay-lint-a0aMVdOC.js → replay-lint-PWaLESz5.js} +3 -3
  45. package/dist/{replay-lint-graphql-C3aqm51r.js → replay-lint-graphql-xh8VoAwd.js} +1 -1
  46. package/dist/{replay-lint-graphql-DnztHI0i.js → replay-lint-graphql-zO8zunug.js} +1 -1
  47. package/dist/replay-periodic-revalidation-BoyLQHtg.js +1 -0
  48. package/dist/replay-periodic-revalidation-Dsp-n7ui.js +21 -0
  49. package/dist/replay-promise-map-limit-DRDkHc-b.js +1 -0
  50. package/dist/replay-promise-map-limit-Db_42GvV.js +14 -0
  51. package/dist/replay-resolve-B0AjmaE9.js +47 -0
  52. package/dist/{replay-resolve-LjvT95Yw.js → replay-resolve-MVe_8Ube.js} +1104 -1094
  53. package/dist/{replay-respect-run-DLSZ4d4p.js → replay-respect-run-BJsR4a4m.js} +1 -1
  54. package/dist/{replay-respect-run-wqqp8WHA.js → replay-respect-run-X4PSO6Fj.js} +3 -3
  55. package/dist/{replay-tauri-path-Bg-T0cwI.js → replay-tauri-path-CkGiQWsb.js} +2 -2
  56. package/dist/{replay-tauri-path-DHZlqqfb.js → replay-tauri-path-D8FJsoZb.js} +1 -1
  57. package/dist/replay-useAiChatQueries-BXL-_N2Q.js +215 -0
  58. package/dist/{replay-useAiChatQueries-Dy-kPGKF.js → replay-useAiChatQueries-D7sHNAfV.js} +1078 -1022
  59. package/dist/{replay-validate-key-B2N6AiQk.js → replay-validate-key-CmzSfORv.js} +1 -1
  60. package/dist/{replay-validate-key-B7RBY-6z.js → replay-validate-key-CtZEJRP7.js} +2 -2
  61. package/dist/replay.cjs +1 -1
  62. package/dist/replay.js +12 -12
  63. package/package.json +5 -4
  64. package/dist/replay-AiPanel-COL9ADyD.js +0 -868
  65. package/dist/replay-index-ClVtMDHn.js +0 -6899
  66. package/dist/replay-index-F528jCaH.js +0 -1
  67. package/dist/replay-index-fpeoVNQb.js +0 -1
  68. package/dist/replay-resolve-BoryNVbu.js +0 -47
  69. package/dist/replay-useAiChatQueries-DuNxx5rQ.js +0 -215
@@ -1,4 +1,4 @@
1
- import { R as nd, aD as zh, E as Kr } from "./replay-index-BowK-_3Z.js";
1
+ import { F as nd, aO as zh, V as Kr } from "./replay-index-Bc5RHu5L.js";
2
2
  var ad = "vercel.ai.error", Fh = Symbol.for(ad), Js, Ks, ve = class rd extends (Ks = Error, Js = Fh, Ks) {
3
3
  /**
4
4
  * Creates an AI SDK Error.
@@ -5898,9 +5898,9 @@ var de;
5898
5898
  (function(e) {
5899
5899
  e.ZodString = "ZodString", e.ZodNumber = "ZodNumber", e.ZodNaN = "ZodNaN", e.ZodBigInt = "ZodBigInt", e.ZodBoolean = "ZodBoolean", e.ZodDate = "ZodDate", e.ZodSymbol = "ZodSymbol", e.ZodUndefined = "ZodUndefined", e.ZodNull = "ZodNull", e.ZodAny = "ZodAny", e.ZodUnknown = "ZodUnknown", e.ZodNever = "ZodNever", e.ZodVoid = "ZodVoid", e.ZodArray = "ZodArray", e.ZodObject = "ZodObject", e.ZodUnion = "ZodUnion", e.ZodDiscriminatedUnion = "ZodDiscriminatedUnion", e.ZodIntersection = "ZodIntersection", e.ZodTuple = "ZodTuple", e.ZodRecord = "ZodRecord", e.ZodMap = "ZodMap", e.ZodSet = "ZodSet", e.ZodFunction = "ZodFunction", e.ZodLazy = "ZodLazy", e.ZodLiteral = "ZodLiteral", e.ZodEnum = "ZodEnum", e.ZodEffects = "ZodEffects", e.ZodNativeEnum = "ZodNativeEnum", e.ZodOptional = "ZodOptional", e.ZodNullable = "ZodNullable", e.ZodDefault = "ZodDefault", e.ZodCatch = "ZodCatch", e.ZodPromise = "ZodPromise", e.ZodBranded = "ZodBranded", e.ZodPipeline = "ZodPipeline", e.ZodReadonly = "ZodReadonly";
5900
5900
  })(de || (de = {}));
5901
- const Ee = Fo.create, ft = aa.create, ei = Ei.create, Ab = Oi.create, LR = Ai.create, zR = mn.create, Ct = Ro.create, yt = gt.create, FR = gt.strictCreate, kn = yr.create, ZR = gs.create;
5901
+ const Ee = Fo.create, ft = aa.create, ei = Ei.create, Ab = Oi.create, FR = Ai.create, ZR = mn.create, Ct = Ro.create, yt = gt.create, VR = gt.strictCreate, kn = yr.create, GR = gs.create;
5902
5902
  _r.create;
5903
- const VR = Rn.create, Nb = br.create, GR = wr.create, Co = On.create, BR = xr.create;
5903
+ const BR = Rn.create, Nb = br.create, HR = wr.create, Co = On.create, WR = xr.create;
5904
5904
  Tr.create;
5905
5905
  Vo.create;
5906
5906
  Nn.create;
@@ -13622,8 +13622,8 @@ async function KT() {
13622
13622
  if (hf())
13623
13623
  return fi == null && (fi = import(
13624
13624
  /* webpackIgnore: true */
13625
- "./replay-index-BowK-_3Z.js"
13626
- ).then((e) => e.bc).catch(() => {
13625
+ "./replay-index-Bc5RHu5L.js"
13626
+ ).then((e) => e.bh).catch(() => {
13627
13627
  })), fi;
13628
13628
  }
13629
13629
  function nc(e) {
@@ -14084,7 +14084,7 @@ function gf({
14084
14084
  function Ps(e) {
14085
14085
  return ({ steps: t }) => t.length === e;
14086
14086
  }
14087
- function HR(...e) {
14087
+ function JR(...e) {
14088
14088
  return ({ steps: t }) => {
14089
14089
  var o, n, a;
14090
14090
  return (a = (n = (o = t[t.length - 1]) == null ? void 0 : o.toolCalls) == null ? void 0 : n.some(
@@ -18560,7 +18560,7 @@ var AI = class {
18560
18560
  ...e
18561
18561
  });
18562
18562
  }
18563
- }, WR = class {
18563
+ }, KR = class {
18564
18564
  constructor(e) {
18565
18565
  this.version = "agent-v1";
18566
18566
  const { onFinish: t, onEnd: o = t } = e;
@@ -19422,7 +19422,7 @@ ho({
19422
19422
  prefix: "call",
19423
19423
  size: 24
19424
19424
  });
19425
- function JR(e) {
19425
+ function YR(e) {
19426
19426
  return typeof e == "string" ? e : e instanceof ArrayBuffer ? Wo(new Uint8Array(e)) : Wo(e);
19427
19427
  }
19428
19428
  ho({ prefix: "aiobj", size: 24 });
@@ -19450,7 +19450,7 @@ var jI = class {
19450
19450
  }
19451
19451
  };
19452
19452
  ho({ prefix: "aiobj", size: 24 });
19453
- function KR({
19453
+ function XR({
19454
19454
  messages: e,
19455
19455
  reasoning: t = "none",
19456
19456
  toolCalls: o = [],
@@ -19623,7 +19623,7 @@ var LI = class {
19623
19623
  })
19624
19624
  );
19625
19625
  }
19626
- }, YR = class {
19626
+ }, QR = class {
19627
19627
  constructor({
19628
19628
  generateId: e = nt,
19629
19629
  id: t = e(),
@@ -19891,7 +19891,7 @@ var LI = class {
19891
19891
  body: n
19892
19892
  });
19893
19893
  }
19894
- }, XR = class {
19894
+ }, eO = class {
19895
19895
  constructor({
19896
19896
  agent: e,
19897
19897
  options: t,
@@ -19931,7 +19931,7 @@ var LI = class {
19931
19931
  return null;
19932
19932
  }
19933
19933
  };
19934
- function QR({
19934
+ function tO({
19935
19935
  messages: e
19936
19936
  }) {
19937
19937
  const t = e[e.length - 1];
@@ -20219,8 +20219,8 @@ function dk(e) {
20219
20219
  }
20220
20220
  return "Unknown error";
20221
20221
  }
20222
- const pk = "replay/ai-conversations";
20223
- function mk(e) {
20222
+ const pk = "replay/ai-conversations", mk = "replay", fk = "0.27.0";
20223
+ function hk(e) {
20224
20224
  const t = e.baseUrl.replace(/\/$/, ""), o = e.accessToken;
20225
20225
  return {
20226
20226
  provider: nd,
@@ -20238,6 +20238,7 @@ function mk(e) {
20238
20238
  headers: {
20239
20239
  "Content-Type": "application/json",
20240
20240
  Accept: "text/event-stream",
20241
+ "x-redocly-client": `${mk}/${fk}`,
20241
20242
  Cookie: `accessToken=${o};`,
20242
20243
  ...n.headers ?? {}
20243
20244
  },
@@ -20251,14 +20252,14 @@ function mk(e) {
20251
20252
  );
20252
20253
  }
20253
20254
  return {
20254
- stream: fk(s, n.abortSignal),
20255
+ stream: gk(s, n.abortSignal),
20255
20256
  request: { body: r },
20256
20257
  response: { headers: Object.fromEntries(s.headers.entries()) }
20257
20258
  };
20258
20259
  }
20259
20260
  };
20260
20261
  }
20261
- function fk(e, t) {
20262
+ function gk(e, t) {
20262
20263
  const o = e.body;
20263
20264
  if (!o) throw new Error("Reunite provider: response has no body");
20264
20265
  return new ReadableStream({
@@ -20277,7 +20278,7 @@ function fk(e, t) {
20277
20278
  }
20278
20279
  });
20279
20280
  }
20280
- var hk = "4.0.3", gk = K(
20281
+ var vk = "4.0.3", yk = K(
20281
20282
  () => W(
20282
20283
  u({
20283
20284
  error: u({
@@ -20288,9 +20289,9 @@ var hk = "4.0.3", gk = K(
20288
20289
  })
20289
20290
  )
20290
20291
  ), Qt = Lt({
20291
- errorSchema: gk,
20292
+ errorSchema: yk,
20292
20293
  errorToMessage: (e) => e.error.message
20293
- }), vk = ce([
20294
+ }), _k = ce([
20294
20295
  u({ text: i() }),
20295
20296
  u({
20296
20297
  inlineData: u({
@@ -20304,7 +20305,7 @@ var hk = "4.0.3", gk = K(
20304
20305
  mimeType: i()
20305
20306
  })
20306
20307
  })
20307
- ]), yk = K(
20308
+ ]), bk = K(
20308
20309
  () => W(
20309
20310
  u({
20310
20311
  /**
@@ -20343,10 +20344,10 @@ var hk = "4.0.3", gk = K(
20343
20344
  * The array length must match the number of values being embedded. In
20344
20345
  * the case of a single embedding, the array length must be 1.
20345
20346
  */
20346
- content: A(A(vk).min(1).nullable()).optional()
20347
+ content: A(A(_k).min(1).nullable()).optional()
20347
20348
  })
20348
20349
  )
20349
- ), _k = class $f {
20350
+ ), wk = class $f {
20350
20351
  constructor(t, o) {
20351
20352
  this.specificationVersion = "v4", this.maxEmbeddingsPerCall = 2048, this.supportsParallelCalls = !0, this.modelId = t, this.config = o;
20352
20353
  }
@@ -20371,7 +20372,7 @@ var hk = "4.0.3", gk = K(
20371
20372
  const r = await tt({
20372
20373
  provider: "google",
20373
20374
  providerOptions: a,
20374
- schema: yk
20375
+ schema: bk
20375
20376
  });
20376
20377
  if (t.length > this.maxEmbeddingsPerCall)
20377
20378
  throw new Sd({
@@ -20406,7 +20407,7 @@ var hk = "4.0.3", gk = K(
20406
20407
  },
20407
20408
  failedResponseHandler: Qt,
20408
20409
  successfulResponseHandler: Fe(
20409
- wk
20410
+ Tk
20410
20411
  ),
20411
20412
  abortSignal: n,
20412
20413
  fetch: this.config.fetch
@@ -20441,7 +20442,7 @@ var hk = "4.0.3", gk = K(
20441
20442
  },
20442
20443
  failedResponseHandler: Qt,
20443
20444
  successfulResponseHandler: Fe(
20444
- bk
20445
+ xk
20445
20446
  ),
20446
20447
  abortSignal: n,
20447
20448
  fetch: this.config.fetch
@@ -20453,13 +20454,13 @@ var hk = "4.0.3", gk = K(
20453
20454
  response: { headers: c, body: d }
20454
20455
  };
20455
20456
  }
20456
- }, bk = K(
20457
+ }, xk = K(
20457
20458
  () => W(
20458
20459
  u({
20459
20460
  embeddings: A(u({ values: A(T()) }))
20460
20461
  })
20461
20462
  )
20462
- ), wk = K(
20463
+ ), Tk = K(
20463
20464
  () => W(
20464
20465
  u({
20465
20466
  embedding: u({ values: A(T()) })
@@ -20502,7 +20503,7 @@ function mc(e) {
20502
20503
  function uo(e, t = !0) {
20503
20504
  if (e == null)
20504
20505
  return;
20505
- if (xk(e))
20506
+ if (Ik(e))
20506
20507
  return t ? void 0 : typeof e == "object" && e.description ? { type: "object", description: e.description } : { type: "object" };
20507
20508
  if (typeof e == "boolean")
20508
20509
  return { type: "boolean", properties: {} };
@@ -20556,20 +20557,20 @@ function uo(e, t = !0) {
20556
20557
  (b) => uo(b, !1)
20557
20558
  )), v !== void 0 && (g.minLength = v), g;
20558
20559
  }
20559
- function xk(e) {
20560
+ function Ik(e) {
20560
20561
  return e != null && typeof e == "object" && e.type === "object" && (e.properties == null || Object.keys(e.properties).length === 0) && !e.additionalProperties;
20561
20562
  }
20562
- var Tk = "skip_thought_signature_validator", Ik = /^data:([^;,]+);base64,(.+)$/s;
20563
- function kk(e) {
20564
- const t = Ik.exec(e);
20563
+ var kk = "skip_thought_signature_validator", Sk = /^data:([^;,]+);base64,(.+)$/s;
20564
+ function Ck(e) {
20565
+ const t = Sk.exec(e);
20565
20566
  if (t != null)
20566
20567
  return {
20567
20568
  mediaType: t[1],
20568
20569
  data: t[2]
20569
20570
  };
20570
20571
  }
20571
- function Sk(e) {
20572
- const t = kk(e);
20572
+ function Ek(e) {
20573
+ const t = Ck(e);
20573
20574
  if (t != null)
20574
20575
  return {
20575
20576
  inlineData: {
@@ -20578,7 +20579,7 @@ function Sk(e) {
20578
20579
  }
20579
20580
  };
20580
20581
  }
20581
- function Ck(e, t, o, n) {
20582
+ function Mk(e, t, o, n) {
20582
20583
  const a = [], r = [];
20583
20584
  for (const s of o)
20584
20585
  switch (s.type) {
@@ -20595,7 +20596,7 @@ function Ck(e, t, o, n) {
20595
20596
  }
20596
20597
  });
20597
20598
  else if (s.data.type === "url") {
20598
- const l = Sk(
20599
+ const l = Ek(
20599
20600
  s.data.url.toString()
20600
20601
  );
20601
20602
  l != null ? a.push(l) : r.push(JSON.stringify(s));
@@ -20621,7 +20622,7 @@ function Ck(e, t, o, n) {
20621
20622
  }
20622
20623
  });
20623
20624
  }
20624
- function Ek(e, t, o, n) {
20625
+ function Rk(e, t, o, n) {
20625
20626
  for (const a of o)
20626
20627
  switch (a.type) {
20627
20628
  case "text":
@@ -20655,13 +20656,13 @@ function Ek(e, t, o, n) {
20655
20656
  break;
20656
20657
  }
20657
20658
  }
20658
- function Mk(e, t) {
20659
+ function Ok(e, t) {
20659
20660
  var o, n, a, r, s;
20660
20661
  const l = [], c = [];
20661
20662
  let p = !0;
20662
20663
  const d = (o = t?.isGemmaModel) != null ? o : !1, m = (n = t?.isGemini3Model) != null ? n : !1, v = t?.onWarning, y = (a = t?.providerOptionsNames) != null ? a : ["google"], g = !y.includes("google"), b = (r = t?.supportsFunctionResponseParts) != null ? r : !0;
20663
20664
  let x = !1;
20664
- const w = [], _ = (h) => (w.push(h), x = !0, Tk), k = (h) => {
20665
+ const w = [], _ = (h) => (w.push(h), x = !0, kk), k = (h) => {
20665
20666
  var S, E, O, R, C;
20666
20667
  for (const P of y) {
20667
20668
  const H = (S = h.providerOptions) == null ? void 0 : S[P];
@@ -20882,12 +20883,12 @@ function Mk(e, t) {
20882
20883
  }
20883
20884
  }
20884
20885
  const H = O.output;
20885
- H.type === "content" ? b ? Ck(
20886
+ H.type === "content" ? b ? Mk(
20886
20887
  E,
20887
20888
  O.toolName,
20888
20889
  H.value,
20889
20890
  O.toolCallId
20890
- ) : Ek(
20891
+ ) : Rk(
20891
20892
  E,
20892
20893
  O.toolName,
20893
20894
  H.value,
@@ -21086,7 +21087,7 @@ var fc = K(
21086
21087
  })
21087
21088
  )
21088
21089
  );
21089
- function Rk({
21090
+ function Ak({
21090
21091
  tools: e,
21091
21092
  toolChoice: t,
21092
21093
  modelId: o,
@@ -21281,7 +21282,7 @@ function Rk({
21281
21282
  }
21282
21283
  }
21283
21284
  }
21284
- var Ok = class {
21285
+ var Nk = class {
21285
21286
  constructor() {
21286
21287
  this.accumulatedArgs = {}, this.jsonText = "", this.pathStack = [], this.stringOpen = !1;
21287
21288
  }
@@ -21294,7 +21295,7 @@ var Ok = class {
21294
21295
  for (const o of e) {
21295
21296
  const n = o.jsonPath.replace(/^\$\./, "");
21296
21297
  if (!n) continue;
21297
- const a = Ak(n), r = $k(this.accumulatedArgs, a);
21298
+ const a = $k(n), r = Dk(this.accumulatedArgs, a);
21298
21299
  if (o.stringValue != null && r !== void 0) {
21299
21300
  const c = JSON.stringify(o.stringValue).slice(1, -1);
21300
21301
  gc(
@@ -21304,7 +21305,7 @@ var Ok = class {
21304
21305
  ), t += c;
21305
21306
  continue;
21306
21307
  }
21307
- const l = Pk(o);
21308
+ const l = qk(o);
21308
21309
  l != null && (gc(this.accumulatedArgs, a, l.value), t += this.emitNavigationTo(a, o, l.json));
21309
21310
  }
21310
21311
  return this.jsonText += t, {
@@ -21402,7 +21403,7 @@ var Ok = class {
21402
21403
  return a.childCount > 0 && (n += ","), a.childCount++, typeof e == "string" && (n += `${JSON.stringify(e)}:`), t.stringValue != null && t.willContinue ? (n += o.slice(0, -1), this.stringOpen = !0) : n += o, n;
21403
21404
  }
21404
21405
  };
21405
- function Ak(e) {
21406
+ function $k(e) {
21406
21407
  const t = [];
21407
21408
  for (const o of e.split(".")) {
21408
21409
  const n = o.indexOf("[");
@@ -21416,9 +21417,9 @@ function Ak(e) {
21416
21417
  }
21417
21418
  return t;
21418
21419
  }
21419
- var Nk = Object.prototype.hasOwnProperty;
21420
+ var Pk = Object.prototype.hasOwnProperty;
21420
21421
  function Pf(e, t) {
21421
- return Nk.call(e, t);
21422
+ return Pk.call(e, t);
21422
21423
  }
21423
21424
  function hc(e, t, o) {
21424
21425
  Object.defineProperty(e, t, {
@@ -21428,7 +21429,7 @@ function hc(e, t, o) {
21428
21429
  writable: !0
21429
21430
  });
21430
21431
  }
21431
- function $k(e, t) {
21432
+ function Dk(e, t) {
21432
21433
  let o = e;
21433
21434
  for (const n of t) {
21434
21435
  if (o == null || typeof o != "object") return;
@@ -21450,7 +21451,7 @@ function gc(e, t, o) {
21450
21451
  }
21451
21452
  hc(n, t[t.length - 1], o);
21452
21453
  }
21453
- function Pk(e) {
21454
+ function qk(e) {
21454
21455
  var t, o;
21455
21456
  const n = (o = (t = e.stringValue) != null ? t : e.numberValue) != null ? o : e.boolValue;
21456
21457
  if (n != null) return { value: n, json: JSON.stringify(n) };
@@ -21553,7 +21554,7 @@ var Df = class qf {
21553
21554
  ...h.requestType && {
21554
21555
  "X-Vertex-AI-LLM-Request-Type": h.requestType
21555
21556
  }
21556
- } : void 0, O = S ? void 0 : h?.serviceTier, R = this.modelId.toLowerCase().startsWith("gemma-"), C = /^gemini-3[.-]/.test(this.modelId), P = C, { contents: H, systemInstruction: Y } = Mk(t, {
21557
+ } : void 0, O = S ? void 0 : h?.serviceTier, R = this.modelId.toLowerCase().startsWith("gemma-"), C = /^gemini-3[.-]/.test(this.modelId), P = C, { contents: H, systemInstruction: Y } = Ok(t, {
21557
21558
  isGemmaModel: R,
21558
21559
  isGemini3Model: C,
21559
21560
  onWarning: (V) => _.push(V),
@@ -21563,12 +21564,12 @@ var Df = class qf {
21563
21564
  tools: z,
21564
21565
  toolConfig: D,
21565
21566
  toolWarnings: re
21566
- } = Rk({
21567
+ } = Ak({
21567
21568
  tools: m,
21568
21569
  toolChoice: v,
21569
21570
  modelId: this.modelId,
21570
21571
  isVertexProvider: S
21571
- }), F = Uk({
21572
+ }), F = zk({
21572
21573
  reasoning: y,
21573
21574
  modelId: this.modelId,
21574
21575
  warnings: _
@@ -21648,7 +21649,7 @@ var Df = class qf {
21648
21649
  headers: C,
21649
21650
  body: h,
21650
21651
  failedResponseHandler: Qt,
21651
- successfulResponseHandler: Fe(Zk),
21652
+ successfulResponseHandler: Fe(Gk),
21652
21653
  abortSignal: t.abortSignal,
21653
21654
  fetch: this.config.fetch
21654
21655
  }), z = H.candidates[0], D = [], re = (n = (o = z.content) == null ? void 0 : o.parts) != null ? n : [], F = H.usageMetadata;
@@ -21795,7 +21796,7 @@ var Df = class qf {
21795
21796
  headers: l,
21796
21797
  body: o,
21797
21798
  failedResponseHandler: Qt,
21798
- successfulResponseHandler: fn(Vk),
21799
+ successfulResponseHandler: fn(Bk),
21799
21800
  abortSignal: t.abortSignal,
21800
21801
  fetch: this.config.fetch
21801
21802
  });
@@ -21967,7 +21968,7 @@ var Df = class qf {
21967
21968
  }) : void 0, U = I.functionCall.partialArgs != null || I.functionCall.name != null && I.functionCall.willContinue === !0, ie = I.functionCall.name == null && I.functionCall.args == null && I.functionCall.partialArgs == null && I.functionCall.willContinue == null, Pe = I.functionCall.name != null && I.functionCall.args != null && I.functionCall.partialArgs == null, ct = I.functionCall.name != null && I.functionCall.args == null && I.functionCall.partialArgs == null && I.functionCall.willContinue !== !0;
21968
21969
  if (U) {
21969
21970
  if (I.functionCall.name != null) {
21970
- const Ze = ($ = I.functionCall.id) != null ? $ : b(), Ue = new Ok();
21971
+ const Ze = ($ = I.functionCall.id) != null ? $ : b(), Ue = new Nk();
21971
21972
  if (O.push({
21972
21973
  toolCallId: Ze,
21973
21974
  toolName: I.functionCall.name,
@@ -22079,25 +22080,25 @@ var Df = class qf {
22079
22080
  };
22080
22081
  }
22081
22082
  };
22082
- function Dk(e) {
22083
+ function jk(e) {
22083
22084
  return /gemini-3[\.\-]/i.test(e) || /gemini-3$/i.test(e);
22084
22085
  }
22085
- function qk() {
22086
+ function Uk() {
22086
22087
  return 65536;
22087
22088
  }
22088
- function jk(e) {
22089
+ function Lk(e) {
22089
22090
  const t = e.toLowerCase();
22090
22091
  return t.includes("2.5-pro") || t.includes("gemini-3-pro-image") ? 32768 : 24576;
22091
22092
  }
22092
- function Uk({
22093
+ function zk({
22093
22094
  reasoning: e,
22094
22095
  modelId: t,
22095
22096
  warnings: o
22096
22097
  }) {
22097
22098
  if (Ua(e))
22098
- return Dk(t) && !t.includes("gemini-3-pro-image") ? Lk({ reasoning: e, warnings: o }) : zk({ reasoning: e, modelId: t, warnings: o });
22099
+ return jk(t) && !t.includes("gemini-3-pro-image") ? Fk({ reasoning: e, warnings: o }) : Zk({ reasoning: e, modelId: t, warnings: o });
22099
22100
  }
22100
- function Lk({
22101
+ function Fk({
22101
22102
  reasoning: e,
22102
22103
  warnings: t
22103
22104
  }) {
@@ -22117,7 +22118,7 @@ function Lk({
22117
22118
  if (o != null)
22118
22119
  return { thinkingLevel: o };
22119
22120
  }
22120
- function zk({
22121
+ function Zk({
22121
22122
  reasoning: e,
22122
22123
  modelId: t,
22123
22124
  warnings: o
@@ -22126,8 +22127,8 @@ function zk({
22126
22127
  return { thinkingBudget: 0 };
22127
22128
  const n = xp({
22128
22129
  reasoning: e,
22129
- maxOutputTokens: qk(),
22130
- maxReasoningBudget: jk(t),
22130
+ maxOutputTokens: Uk(),
22131
+ maxReasoningBudget: Lk(t),
22131
22132
  minReasoningBudget: 0,
22132
22133
  warnings: o
22133
22134
  });
@@ -22250,7 +22251,7 @@ var jf = () => u({
22250
22251
  }),
22251
22252
  u({})
22252
22253
  ]).nullish()
22253
- }), Fk = u({
22254
+ }), Vk = u({
22254
22255
  jsonPath: i(),
22255
22256
  stringValue: i().nullish(),
22256
22257
  numberValue: T().nullish(),
@@ -22266,7 +22267,7 @@ var jf = () => u({
22266
22267
  id: i().nullish(),
22267
22268
  name: i().nullish(),
22268
22269
  args: he().nullish(),
22269
- partialArgs: A(Fk).nullish(),
22270
+ partialArgs: A(Vk).nullish(),
22270
22271
  willContinue: ae().nullish()
22271
22272
  }),
22272
22273
  thoughtSignature: i().nullish()
@@ -22341,7 +22342,7 @@ var jf = () => u({
22341
22342
  urlRetrievalStatus: i()
22342
22343
  })
22343
22344
  ).nullish()
22344
- }), Zk = K(
22345
+ }), Gk = K(
22345
22346
  () => W(
22346
22347
  u({
22347
22348
  candidates: A(
@@ -22361,7 +22362,7 @@ var jf = () => u({
22361
22362
  }).nullish()
22362
22363
  })
22363
22364
  )
22364
- ), Vk = K(
22365
+ ), Bk = K(
22365
22366
  () => W(
22366
22367
  u({
22367
22368
  candidates: A(
@@ -22381,7 +22382,7 @@ var jf = () => u({
22381
22382
  }).nullish()
22382
22383
  })
22383
22384
  )
22384
- ), Gk = it({
22385
+ ), Hk = it({
22385
22386
  id: "google.code_execution",
22386
22387
  inputSchema: u({
22387
22388
  language: i().describe("The programming language of the code."),
@@ -22391,7 +22392,7 @@ var jf = () => u({
22391
22392
  outcome: i().describe('The outcome of the execution (e.g., "OUTCOME_OK").'),
22392
22393
  output: i().describe("The output from the code execution.")
22393
22394
  })
22394
- }), Bk = it({
22395
+ }), Wk = it({
22395
22396
  id: "google.enterprise_web_search",
22396
22397
  inputSchema: K(() => W(u({}))),
22397
22398
  outputSchema: K(() => W(u({})))
@@ -22412,15 +22413,15 @@ En({
22412
22413
  "Metadata filter to apply to the file search retrieval documents. See https://google.aip.dev/160 for the syntax of the filter expression."
22413
22414
  ).optional()
22414
22415
  });
22415
- var Hk = it({
22416
+ var Jk = it({
22416
22417
  id: "google.file_search",
22417
22418
  inputSchema: K(() => W(u({}))),
22418
22419
  outputSchema: K(() => W(u({})))
22419
- }), Wk = it({
22420
+ }), Kk = it({
22420
22421
  id: "google.google_maps",
22421
22422
  inputSchema: K(() => W(u({}))),
22422
22423
  outputSchema: K(() => W(u({})))
22423
- }), Jk = En({
22424
+ }), Yk = En({
22424
22425
  searchTypes: u({
22425
22426
  webSearch: u({}).optional(),
22426
22427
  imageSearch: u({}).optional()
@@ -22429,24 +22430,24 @@ var Hk = it({
22429
22430
  startTime: i(),
22430
22431
  endTime: i()
22431
22432
  }).optional()
22432
- }), Kk = it({
22433
+ }), Xk = it({
22433
22434
  id: "google.google_search",
22434
22435
  inputSchema: K(() => W(u({}))),
22435
22436
  outputSchema: K(() => W(u({})))
22436
- }), Yk = it({
22437
+ }), Qk = it({
22437
22438
  id: "google.url_context",
22438
22439
  inputSchema: K(() => W(u({}))),
22439
22440
  outputSchema: K(() => W(u({})))
22440
- }), Xk = it({
22441
+ }), eS = it({
22441
22442
  id: "google.vertex_rag_store",
22442
22443
  inputSchema: K(() => W(u({}))),
22443
22444
  outputSchema: K(() => W(u({})))
22444
- }), Qk = {
22445
+ }), tS = {
22445
22446
  /**
22446
22447
  * Creates a Google search tool that gives Google direct access to real-time web content.
22447
22448
  * Must have name "google_search".
22448
22449
  */
22449
- googleSearch: Kk,
22450
+ googleSearch: Xk,
22450
22451
  /**
22451
22452
  * Creates an Enterprise Web Search tool for grounding responses using a compliance-focused web index.
22452
22453
  * Designed for highly-regulated industries (finance, healthcare, public sector).
@@ -22457,7 +22458,7 @@ var Hk = it({
22457
22458
  *
22458
22459
  * @see https://cloud.google.com/vertex-ai/generative-ai/docs/grounding/web-grounding-enterprise
22459
22460
  */
22460
- enterpriseWebSearch: Bk,
22461
+ enterpriseWebSearch: Wk,
22461
22462
  /**
22462
22463
  * Creates a Google Maps grounding tool that gives the model access to Google Maps data.
22463
22464
  * Must have name "google_maps".
@@ -22465,12 +22466,12 @@ var Hk = it({
22465
22466
  * @see https://ai.google.dev/gemini-api/docs/maps-grounding
22466
22467
  * @see https://cloud.google.com/vertex-ai/generative-ai/docs/grounding/grounding-with-google-maps
22467
22468
  */
22468
- googleMaps: Wk,
22469
+ googleMaps: Kk,
22469
22470
  /**
22470
22471
  * Creates a URL context tool that gives Google direct access to real-time web content.
22471
22472
  * Must have name "url_context".
22472
22473
  */
22473
- urlContext: Yk,
22474
+ urlContext: Qk,
22474
22475
  /**
22475
22476
  * Enables Retrieval Augmented Generation (RAG) via the Gemini File Search tool.
22476
22477
  * Must have name "file_search".
@@ -22481,7 +22482,7 @@ var Hk = it({
22481
22482
  *
22482
22483
  * @see https://ai.google.dev/gemini-api/docs/file-search
22483
22484
  */
22484
- fileSearch: Hk,
22485
+ fileSearch: Jk,
22485
22486
  /**
22486
22487
  * A tool that enables the model to generate and run Python code.
22487
22488
  * Must have name "code_execution".
@@ -22492,12 +22493,12 @@ var Hk = it({
22492
22493
  * @see https://ai.google.dev/gemini-api/docs/code-execution (Google AI)
22493
22494
  * @see https://cloud.google.com/vertex-ai/generative-ai/docs/model-reference/code-execution-api (Vertex AI)
22494
22495
  */
22495
- codeExecution: Gk,
22496
+ codeExecution: Hk,
22496
22497
  /**
22497
22498
  * Creates a Vertex RAG Store tool that enables the model to perform RAG searches against a Vertex RAG Store.
22498
22499
  * Must have name "vertex_rag_store".
22499
22500
  */
22500
- vertexRagStore: Xk
22501
+ vertexRagStore: eS
22501
22502
  }, bc = K(
22502
22503
  () => W(
22503
22504
  u({
@@ -22512,10 +22513,10 @@ var Hk = it({
22512
22513
  * dedicated escape hatch for grounding image generation the same way
22513
22514
  * `generateText` does.
22514
22515
  */
22515
- googleSearch: Jk.optional()
22516
+ googleSearch: Yk.optional()
22516
22517
  })
22517
22518
  )
22518
- ), eS = class Ff {
22519
+ ), oS = class Ff {
22519
22520
  constructor(t, o, n) {
22520
22521
  this.modelId = t, this.settings = o, this.config = n, this.specificationVersion = "v4";
22521
22522
  }
@@ -22595,7 +22596,7 @@ var Hk = it({
22595
22596
  body: k,
22596
22597
  failedResponseHandler: Qt,
22597
22598
  successfulResponseHandler: Fe(
22598
- tS
22599
+ nS
22599
22600
  ),
22600
22601
  abortSignal: v,
22601
22602
  fetch: this.config.fetch
@@ -22724,13 +22725,13 @@ var Hk = it({
22724
22725
  function wc(e) {
22725
22726
  return e.startsWith("gemini-");
22726
22727
  }
22727
- var tS = K(
22728
+ var nS = K(
22728
22729
  () => W(
22729
22730
  u({
22730
22731
  predictions: A(u({ bytesBase64Encoded: i() })).default([])
22731
22732
  })
22732
22733
  )
22733
- ), oS = class {
22734
+ ), aS = class {
22734
22735
  constructor(e) {
22735
22736
  this.config = e, this.specificationVersion = "v4";
22736
22737
  }
@@ -22742,7 +22743,7 @@ var tS = K(
22742
22743
  const r = await tt({
22743
22744
  provider: "google",
22744
22745
  providerOptions: e.providerOptions,
22745
- schema: aS
22746
+ schema: iS
22746
22747
  }), s = this.config.headers(), l = (t = this.config.fetch) != null ? t : globalThis.fetch, c = [];
22747
22748
  e.filename != null && c.push({ type: "unsupported", feature: "filename" });
22748
22749
  const p = ja(e.data), d = e.mediaType, m = r?.displayName, v = this.config.baseURL.replace(/\/v1beta$/, ""), y = await l(`${v}/upload/v1beta/files`, {
@@ -22803,7 +22804,7 @@ var tS = K(
22803
22804
  url: `${this.config.baseURL}/${w.name}`,
22804
22805
  headers: ze(s),
22805
22806
  successfulResponseHandler: Fe(
22806
- nS
22807
+ rS
22807
22808
  ),
22808
22809
  failedResponseHandler: Qt,
22809
22810
  fetch: this.config.fetch
@@ -22835,7 +22836,7 @@ var tS = K(
22835
22836
  }
22836
22837
  };
22837
22838
  }
22838
- }, nS = K(
22839
+ }, rS = K(
22839
22840
  () => W(
22840
22841
  u({
22841
22842
  name: i(),
@@ -22850,7 +22851,7 @@ var tS = K(
22850
22851
  state: i()
22851
22852
  })
22852
22853
  )
22853
- ), aS = K(
22854
+ ), iS = K(
22854
22855
  () => W(
22855
22856
  En({
22856
22857
  displayName: i().nullish(),
@@ -22858,7 +22859,7 @@ var tS = K(
22858
22859
  pollTimeoutMs: T().positive().nullish()
22859
22860
  })
22860
22861
  )
22861
- ), rS = K(
22862
+ ), sS = K(
22862
22863
  () => W(
22863
22864
  En({
22864
22865
  pollIntervalMs: T().positive().nullish(),
@@ -22874,19 +22875,19 @@ var tS = K(
22874
22875
  })
22875
22876
  )
22876
22877
  );
22877
- function iS(e) {
22878
+ function lS(e) {
22878
22879
  var t, o;
22879
22880
  return (o = (t = e.frameImages) == null ? void 0 : t.find((n) => n.frameType === "first_frame")) == null ? void 0 : o.image;
22880
22881
  }
22881
- function sS(e) {
22882
+ function uS(e) {
22882
22883
  var t;
22883
- return (t = iS(e)) != null ? t : e.image;
22884
+ return (t = lS(e)) != null ? t : e.image;
22884
22885
  }
22885
- function lS(e) {
22886
+ function cS(e) {
22886
22887
  var t, o;
22887
22888
  return (o = (t = e.frameImages) == null ? void 0 : t.find((n) => n.frameType === "last_frame")) == null ? void 0 : o.image;
22888
22889
  }
22889
- function uS(e) {
22890
+ function dS(e) {
22890
22891
  if (!(e.frameImages != null && e.frameImages.length > 0))
22891
22892
  return e.inputReferences != null && e.inputReferences.length > 0 ? e.inputReferences : void 0;
22892
22893
  }
@@ -22912,7 +22913,7 @@ function Ki(e, t) {
22912
22913
  }
22913
22914
  };
22914
22915
  }
22915
- function cS(e) {
22916
+ function pS(e) {
22916
22917
  return e.bytesBase64Encoded ? {
22917
22918
  inlineData: {
22918
22919
  mimeType: "image/png",
@@ -22922,11 +22923,11 @@ function cS(e) {
22922
22923
  gcsUri: e.gcsUri
22923
22924
  } : e;
22924
22925
  }
22925
- function dS(e, t) {
22926
+ function mS(e, t) {
22926
22927
  const o = Ki(e, t);
22927
22928
  return o != null ? { image: o, referenceType: "asset" } : void 0;
22928
22929
  }
22929
- var pS = class {
22930
+ var fS = class {
22930
22931
  constructor(e, t) {
22931
22932
  this.modelId = e, this.config = t, this.specificationVersion = "v4";
22932
22933
  }
@@ -22941,25 +22942,25 @@ var pS = class {
22941
22942
  const p = (n = (o = (t = this.config._internal) == null ? void 0 : t.currentDate) == null ? void 0 : o.call(t)) != null ? n : /* @__PURE__ */ new Date(), d = [], m = await tt({
22942
22943
  provider: "google",
22943
22944
  providerOptions: e.providerOptions,
22944
- schema: rS
22945
+ schema: sS
22945
22946
  }), v = [{}], y = v[0];
22946
22947
  e.prompt != null && (y.prompt = e.prompt);
22947
- const g = sS(e);
22948
+ const g = uS(e);
22948
22949
  if (g != null) {
22949
22950
  const D = Ki(g, d);
22950
22951
  D != null && (y.image = D);
22951
22952
  }
22952
- const b = lS(e);
22953
+ const b = cS(e);
22953
22954
  if (b != null) {
22954
22955
  const D = Ki(b, d);
22955
22956
  D != null && (y.lastFrame = D);
22956
22957
  }
22957
- const x = uS(e);
22958
+ const x = dS(e);
22958
22959
  x != null ? y.referenceImages = x.flatMap((D) => {
22959
- const re = dS(D, d);
22960
+ const re = mS(D, d);
22960
22961
  return re != null ? [re] : [];
22961
22962
  }) : m?.referenceImages != null && (y.referenceImages = m.referenceImages.map(
22962
- (D) => cS(D)
22963
+ (D) => pS(D)
22963
22964
  ));
22964
22965
  const w = {
22965
22966
  sampleCount: e.n
@@ -23096,7 +23097,7 @@ var pS = class {
23096
23097
  ).nullish()
23097
23098
  }).nullish()
23098
23099
  }).nullish()
23099
- }), mS = K(
23100
+ }), hS = K(
23100
23101
  () => W(
23101
23102
  u({
23102
23103
  candidates: A(
@@ -23115,10 +23116,10 @@ var pS = class {
23115
23116
  ).nullish()
23116
23117
  })
23117
23118
  )
23118
- ), fS = u({
23119
+ ), gS = u({
23119
23120
  voiceName: i()
23120
- }), hS = u({
23121
- prebuiltVoiceConfig: fS
23121
+ }), vS = u({
23122
+ prebuiltVoiceConfig: gS
23122
23123
  }), Tc = K(
23123
23124
  () => W(
23124
23125
  u({
@@ -23133,13 +23134,13 @@ var pS = class {
23133
23134
  speakerVoiceConfigs: A(
23134
23135
  u({
23135
23136
  speaker: i(),
23136
- voiceConfig: hS
23137
+ voiceConfig: vS
23137
23138
  })
23138
23139
  )
23139
23140
  }).optional()
23140
23141
  })
23141
23142
  )
23142
- ), gS = "Kore", vS = 24e3, yS = class Zf {
23143
+ ), yS = "Kore", _S = 24e3, bS = class Zf {
23143
23144
  constructor(t, o) {
23144
23145
  this.modelId = t, this.config = o, this.specificationVersion = "v4";
23145
23146
  }
@@ -23157,7 +23158,7 @@ var pS = class {
23157
23158
  }
23158
23159
  async getArgs({
23159
23160
  text: t,
23160
- voice: o = gS,
23161
+ voice: o = yS,
23161
23162
  outputFormat: n,
23162
23163
  instructions: a,
23163
23164
  speed: r,
@@ -23221,7 +23222,7 @@ var pS = class {
23221
23222
  body: v,
23222
23223
  failedResponseHandler: Qt,
23223
23224
  successfulResponseHandler: Fe(
23224
- mS
23225
+ hS
23225
23226
  ),
23226
23227
  abortSignal: t.abortSignal,
23227
23228
  fetch: this.config.fetch
@@ -23236,7 +23237,7 @@ var pS = class {
23236
23237
  if (_ != null)
23237
23238
  break;
23238
23239
  }
23239
- const h = (d = _S(k)) != null ? d : vS, S = _ != null ? No(_) : new Uint8Array(0), E = g === "pcm" || S.length === 0 ? S : bS(S, h);
23240
+ const h = (d = wS(k)) != null ? d : _S, S = _ != null ? No(_) : new Uint8Array(0), E = g === "pcm" || S.length === 0 ? S : xS(S, h);
23240
23241
  return g === "pcm" && S.length > 0 && y.push({
23241
23242
  type: "unsupported",
23242
23243
  feature: "outputFormat",
@@ -23262,13 +23263,13 @@ var pS = class {
23262
23263
  };
23263
23264
  }
23264
23265
  };
23265
- function _S(e) {
23266
+ function wS(e) {
23266
23267
  if (e == null)
23267
23268
  return;
23268
23269
  const t = /rate=(\d+)/.exec(e);
23269
23270
  return t ? Number.parseInt(t[1], 10) : void 0;
23270
23271
  }
23271
- function bS(e, t) {
23272
+ function xS(e, t) {
23272
23273
  const r = t * 2, s = e.length, l = new ArrayBuffer(44 + s), c = new DataView(l);
23273
23274
  lr(c, 0, "RIFF"), c.setUint32(4, 36 + s, !0), lr(c, 8, "WAVE"), lr(c, 12, "fmt "), c.setUint32(16, 16, !0), c.setUint16(20, 1, !0), c.setUint16(22, 1, !0), c.setUint32(24, t, !0), c.setUint32(28, r, !0), c.setUint16(32, 2, !0), c.setUint16(34, 16, !0), lr(c, 36, "data"), c.setUint32(40, s, !0);
23274
23275
  const p = new Uint8Array(l);
@@ -23311,7 +23312,7 @@ function qs(e) {
23311
23312
  raw: e
23312
23313
  };
23313
23314
  }
23314
- var wS = {
23315
+ var TS = {
23315
23316
  pdf: "application/pdf",
23316
23317
  txt: "text/plain",
23317
23318
  md: "text/markdown",
@@ -23321,7 +23322,7 @@ var wS = {
23321
23322
  };
23322
23323
  function Vf(e) {
23323
23324
  const t = e.toLowerCase();
23324
- for (const [o, n] of Object.entries(wS))
23325
+ for (const [o, n] of Object.entries(TS))
23325
23326
  if (t.endsWith(`.${o}`)) return n;
23326
23327
  return "application/octet-stream";
23327
23328
  }
@@ -23329,7 +23330,7 @@ function Gf(e) {
23329
23330
  const t = e.split("/"), o = t[t.length - 1];
23330
23331
  return o && o.length > 0 ? o : void 0;
23331
23332
  }
23332
- function xS({
23333
+ function IS({
23333
23334
  annotation: e,
23334
23335
  generateId: t
23335
23336
  }) {
@@ -23464,7 +23465,7 @@ function Yi({
23464
23465
  if (e == null) return [];
23465
23466
  const n = /* @__PURE__ */ new Set(), a = [];
23466
23467
  for (const r of e) {
23467
- const s = xS({ annotation: r, generateId: t });
23468
+ const s = IS({ annotation: r, generateId: t });
23468
23469
  if (s == null) continue;
23469
23470
  const l = s.sourceType === "url" ? `url:${s.url}` : `doc:${(o = s.filename) != null ? o : s.title}`;
23470
23471
  n.has(l) || (n.add(l), a.push(s));
@@ -23490,14 +23491,14 @@ function js({
23490
23491
  return "other";
23491
23492
  }
23492
23493
  }
23493
- var TS = /* @__PURE__ */ new Set([
23494
+ var kS = /* @__PURE__ */ new Set([
23494
23495
  "google_search_call",
23495
23496
  "code_execution_call",
23496
23497
  "url_context_call",
23497
23498
  "file_search_call",
23498
23499
  "google_maps_call",
23499
23500
  "mcp_server_tool_call"
23500
- ]), IS = /* @__PURE__ */ new Set([
23501
+ ]), SS = /* @__PURE__ */ new Set([
23501
23502
  "google_search_result",
23502
23503
  "code_execution_result",
23503
23504
  "url_context_result",
@@ -23505,10 +23506,10 @@ var TS = /* @__PURE__ */ new Set([
23505
23506
  "google_maps_result",
23506
23507
  "mcp_server_tool_result"
23507
23508
  ]);
23508
- function kS(e) {
23509
+ function CS(e) {
23509
23510
  return e.replace(/_call$/, "");
23510
23511
  }
23511
- function SS(e) {
23512
+ function ES(e) {
23512
23513
  return e.replace(/_result$/, "");
23513
23514
  }
23514
23515
  function Ic({
@@ -23609,8 +23610,8 @@ function Ic({
23609
23610
  id: ne,
23610
23611
  toolName: pe
23611
23612
  });
23612
- } else if (oe != null && TS.has(oe)) {
23613
- const ne = oe === "mcp_server_tool_call" ? (w = $?.name) != null ? w : "mcp_server_tool" : kS(oe), pe = (_ = $?.id) != null ? _ : L, ye = {
23613
+ } else if (oe != null && kS.has(oe)) {
23614
+ const ne = oe === "mcp_server_tool_call" ? (w = $?.name) != null ? w : "mcp_server_tool" : CS(oe), pe = (_ = $?.id) != null ? _ : L, ye = {
23614
23615
  kind: "builtin_tool_call",
23615
23616
  id: L,
23616
23617
  blockType: oe,
@@ -23620,8 +23621,8 @@ function Ic({
23620
23621
  callEmitted: !1
23621
23622
  };
23622
23623
  p.set(V, ye);
23623
- } else if (oe != null && IS.has(oe)) {
23624
- const ne = oe === "mcp_server_tool_result" ? (h = $?.name) != null ? h : "mcp_server_tool" : SS(oe), pe = (S = $?.call_id) != null ? S : L, ye = {
23624
+ } else if (oe != null && SS.has(oe)) {
23625
+ const ne = oe === "mcp_server_tool_result" ? (h = $?.name) != null ? h : "mcp_server_tool" : ES(oe), pe = (S = $?.call_id) != null ? S : L, ye = {
23625
23626
  kind: "builtin_tool_result",
23626
23627
  id: L,
23627
23628
  blockType: oe,
@@ -23833,7 +23834,7 @@ function Ic({
23833
23834
  }
23834
23835
  });
23835
23836
  }
23836
- function CS({
23837
+ function MS({
23837
23838
  prompt: e,
23838
23839
  previousInteractionId: t,
23839
23840
  store: o,
@@ -23845,7 +23846,7 @@ function CS({
23845
23846
  type: "other",
23846
23847
  message: "google.interactions: providerOptions.google.previousInteractionId was set together with store: false. These are incoherent (the prior interaction cannot be referenced when nothing was stored on the server); the full history will be sent and previous_interaction_id will still be emitted."
23847
23848
  });
23848
- const g = y ? ES({
23849
+ const g = y ? RS({
23849
23850
  prompt: e,
23850
23851
  previousInteractionId: t
23851
23852
  }) : e, b = [], x = [];
@@ -23868,7 +23869,7 @@ function CS({
23868
23869
  });
23869
23870
  E != null && k.push(E);
23870
23871
  }
23871
- const h = AS(k);
23872
+ const h = $S(k);
23872
23873
  h.length > 0 && x.push({ type: "user_input", content: h });
23873
23874
  break;
23874
23875
  }
@@ -23897,7 +23898,7 @@ function CS({
23897
23898
  E != null && k.push(E);
23898
23899
  } else if (S.type === "tool-call") {
23899
23900
  h();
23900
- const E = (l = (s = S.providerOptions) == null ? void 0 : s.google) == null ? void 0 : l.signature, O = typeof S.input == "string" ? MS(S.input) : (c = S.input) != null ? c : {};
23901
+ const E = (l = (s = S.providerOptions) == null ? void 0 : s.google) == null ? void 0 : l.signature, O = typeof S.input == "string" ? OS(S.input) : (c = S.input) != null ? c : {};
23901
23902
  x.push({
23902
23903
  type: "function_call",
23903
23904
  id: S.toolCallId,
@@ -23923,7 +23924,7 @@ function CS({
23923
23924
  });
23924
23925
  continue;
23925
23926
  }
23926
- const S = RS({
23927
+ const S = AS({
23927
23928
  toolCallId: h.toolCallId,
23928
23929
  toolName: h.toolName,
23929
23930
  output: h.output,
@@ -24008,7 +24009,7 @@ function kc({
24008
24009
  }
24009
24010
  }
24010
24011
  }
24011
- function ES({
24012
+ function RS({
24012
24013
  prompt: e,
24013
24014
  previousInteractionId: t
24014
24015
  }) {
@@ -24040,7 +24041,7 @@ function ES({
24040
24041
  }
24041
24042
  return o;
24042
24043
  }
24043
- function MS(e) {
24044
+ function OS(e) {
24044
24045
  try {
24045
24046
  const t = JSON.parse(e);
24046
24047
  return t != null && typeof t == "object" && !Array.isArray(t) ? t : { value: t };
@@ -24048,7 +24049,7 @@ function MS(e) {
24048
24049
  return { value: e };
24049
24050
  }
24050
24051
  }
24051
- function RS({
24052
+ function AS({
24052
24053
  toolCallId: e,
24053
24054
  toolName: t,
24054
24055
  output: o,
@@ -24090,7 +24091,7 @@ function RS({
24090
24091
  });
24091
24092
  continue;
24092
24093
  }
24093
- const d = OS({ part: c, warnings: a });
24094
+ const d = NS({ part: c, warnings: a });
24094
24095
  d != null && l.push(d);
24095
24096
  } else
24096
24097
  a.push({
@@ -24101,7 +24102,7 @@ function RS({
24101
24102
  }
24102
24103
  }
24103
24104
  }
24104
- function OS({
24105
+ function NS({
24105
24106
  part: e,
24106
24107
  warnings: t
24107
24108
  }) {
@@ -24143,7 +24144,7 @@ function OS({
24143
24144
  }
24144
24145
  }
24145
24146
  }
24146
- function AS(e) {
24147
+ function $S(e) {
24147
24148
  if (e.length < 2)
24148
24149
  return e;
24149
24150
  const t = [];
@@ -24447,7 +24448,7 @@ var ur = () => u({
24447
24448
  ]);
24448
24449
  })()
24449
24450
  )
24450
- ), NS = K(
24451
+ ), PS = K(
24451
24452
  () => W(
24452
24453
  u({
24453
24454
  previousInteractionId: i().nullish(),
@@ -24625,14 +24626,14 @@ function _a({
24625
24626
  const o = {};
24626
24627
  return e != null && (o.signature = e), t != null && (o.interactionId = t), Object.keys(o).length > 0 ? { providerMetadata: { google: o } } : {};
24627
24628
  }
24628
- var $S = /* @__PURE__ */ new Set([
24629
+ var DS = /* @__PURE__ */ new Set([
24629
24630
  "google_search_call",
24630
24631
  "code_execution_call",
24631
24632
  "url_context_call",
24632
24633
  "file_search_call",
24633
24634
  "google_maps_call",
24634
24635
  "mcp_server_tool_call"
24635
- ]), PS = /* @__PURE__ */ new Set([
24636
+ ]), qS = /* @__PURE__ */ new Set([
24636
24637
  "google_search_result",
24637
24638
  "code_execution_result",
24638
24639
  "url_context_result",
@@ -24640,10 +24641,10 @@ var $S = /* @__PURE__ */ new Set([
24640
24641
  "google_maps_result",
24641
24642
  "mcp_server_tool_result"
24642
24643
  ]);
24643
- function DS(e) {
24644
+ function jS(e) {
24644
24645
  return e.replace(/_call$/, "");
24645
24646
  }
24646
- function qS(e) {
24647
+ function US(e) {
24647
24648
  return e.replace(/_result$/, "");
24648
24649
  }
24649
24650
  function th({
@@ -24726,8 +24727,8 @@ function th({
24726
24727
  break;
24727
24728
  }
24728
24729
  default: {
24729
- if ($S.has(w)) {
24730
- const _ = x, k = w === "mcp_server_tool_call" ? (c = _.name) != null ? c : "mcp_server_tool" : DS(w), h = JSON.stringify((p = _.arguments) != null ? p : {});
24730
+ if (DS.has(w)) {
24731
+ const _ = x, k = w === "mcp_server_tool_call" ? (c = _.name) != null ? c : "mcp_server_tool" : jS(w), h = JSON.stringify((p = _.arguments) != null ? p : {});
24731
24732
  g.push({
24732
24733
  type: "tool-call",
24733
24734
  toolCallId: (d = _.id) != null ? d : t(),
@@ -24735,8 +24736,8 @@ function th({
24735
24736
  input: h,
24736
24737
  providerExecuted: !0
24737
24738
  });
24738
- } else if (PS.has(w)) {
24739
- const _ = x, k = w === "mcp_server_tool_result" ? (m = _.name) != null ? m : "mcp_server_tool" : qS(w);
24739
+ } else if (qS.has(w)) {
24740
+ const _ = x, k = w === "mcp_server_tool_result" ? (m = _.name) != null ? m : "mcp_server_tool" : US(w);
24740
24741
  g.push({
24741
24742
  type: "tool-result",
24742
24743
  toolCallId: (v = _.call_id) != null ? v : t(),
@@ -24756,12 +24757,12 @@ function th({
24756
24757
  }
24757
24758
  return { content: g, hasFunctionCall: b };
24758
24759
  }
24759
- var jS = () => globalThis.fetch;
24760
+ var LS = () => globalThis.fetch;
24760
24761
  async function oh({
24761
24762
  baseURL: e,
24762
24763
  interactionId: t,
24763
24764
  headers: o,
24764
- fetch: n = jS()
24765
+ fetch: n = LS()
24765
24766
  }) {
24766
24767
  if (t == null || t.length === 0)
24767
24768
  return;
@@ -24782,20 +24783,20 @@ async function oh({
24782
24783
  } catch {
24783
24784
  }
24784
24785
  }
24785
- var US = /* @__PURE__ */ new Set(["completed", "failed", "cancelled", "incomplete"]);
24786
+ var zS = /* @__PURE__ */ new Set(["completed", "failed", "cancelled", "incomplete"]);
24786
24787
  function Qi(e) {
24787
- return e != null && US.has(e);
24788
+ return e != null && zS.has(e);
24788
24789
  }
24789
- var LS = 1e3, zS = 1e4, FS = 1800 * 1e3;
24790
- async function ZS({
24790
+ var FS = 1e3, ZS = 1e4, VS = 1800 * 1e3;
24791
+ async function GS({
24791
24792
  baseURL: e,
24792
24793
  interactionId: t,
24793
24794
  headers: o,
24794
24795
  fetch: n,
24795
24796
  abortSignal: a,
24796
- initialDelayMs: r = LS,
24797
- maxDelayMs: s = zS,
24798
- timeoutMs: l = FS
24797
+ initialDelayMs: r = FS,
24798
+ maxDelayMs: s = ZS,
24799
+ timeoutMs: l = VS
24799
24800
  }) {
24800
24801
  if (t == null || t.length === 0)
24801
24802
  throw new Error(
@@ -24835,7 +24836,7 @@ async function ZS({
24835
24836
  throw Ao(v) && await m(), v;
24836
24837
  }
24837
24838
  }
24838
- function VS({
24839
+ function BS({
24839
24840
  tools: e,
24840
24841
  toolChoice: t
24841
24842
  }) {
@@ -24974,15 +24975,15 @@ function VS({
24974
24975
  toolWarnings: s
24975
24976
  };
24976
24977
  }
24977
- var GS = 3, BS = 500;
24978
- function HS({
24978
+ var HS = 3, WS = 500;
24979
+ function JS({
24979
24980
  baseURL: e,
24980
24981
  interactionId: t,
24981
24982
  headers: o,
24982
24983
  fetch: n,
24983
24984
  abortSignal: a,
24984
- maxRetries: r = GS,
24985
- retryDelayMs: s = BS
24985
+ maxRetries: r = HS,
24986
+ retryDelayMs: s = WS
24986
24987
  }) {
24987
24988
  if (t.length === 0)
24988
24989
  throw new Error(
@@ -25095,7 +25096,7 @@ function HS({
25095
25096
  }
25096
25097
  });
25097
25098
  }
25098
- function WS({
25099
+ function KS({
25099
25100
  response: e,
25100
25101
  warnings: t,
25101
25102
  generateId: o,
@@ -25210,7 +25211,7 @@ function WS({
25210
25211
  }
25211
25212
  });
25212
25213
  }
25213
- var JS = class nh {
25214
+ var YS = class nh {
25214
25215
  constructor(t, o) {
25215
25216
  this.specificationVersion = "v4", typeof t == "string" ? (this.modelId = t, this.agent = void 0) : "managedAgent" in t ? (this.modelId = t.managedAgent, this.agent = t.managedAgent) : (this.modelId = t.agent, this.agent = t.agent), this.config = o;
25216
25217
  }
@@ -25249,7 +25250,7 @@ var JS = class nh {
25249
25250
  const Y = [], z = await tt({
25250
25251
  provider: "google",
25251
25252
  providerOptions: t.providerOptions,
25252
- schema: NS
25253
+ schema: PS
25253
25254
  }), D = this.agent != null, re = t.tools != null && t.tools.length > 0;
25254
25255
  let F, J;
25255
25256
  if (re && D)
@@ -25258,7 +25259,7 @@ var JS = class nh {
25258
25259
  message: "google.interactions: tools are not supported when an agent is set; tools will be omitted from the request body."
25259
25260
  });
25260
25261
  else if (re) {
25261
- const Z = VS({
25262
+ const Z = BS({
25262
25263
  tools: t.tools,
25263
25264
  toolChoice: t.toolChoice
25264
25265
  });
@@ -25304,7 +25305,7 @@ var JS = class nh {
25304
25305
  input: $,
25305
25306
  systemInstruction: V,
25306
25307
  warnings: L
25307
- } = CS({
25308
+ } = MS({
25308
25309
  prompt: t.prompt,
25309
25310
  previousInteractionId: (p = z?.previousInteractionId) != null ? p : void 0,
25310
25311
  store: (d = z?.store) != null ? d : void 0,
@@ -25440,7 +25441,7 @@ var JS = class nh {
25440
25441
  rawValue: w
25441
25442
  } = g;
25442
25443
  if (d && !Qi(x.status)) {
25443
- const C = await ZS({
25444
+ const C = await GS({
25444
25445
  baseURL: this.config.baseURL,
25445
25446
  interactionId: x.id,
25446
25447
  headers: y,
@@ -25569,7 +25570,7 @@ var JS = class nh {
25569
25570
  const y = d?.["x-gemini-service-tier"];
25570
25571
  if (Qi(m.status))
25571
25572
  return {
25572
- stream: WS({
25573
+ stream: KS({
25573
25574
  response: m,
25574
25575
  warnings: o,
25575
25576
  generateId: (l = this.config.generateId) != null ? l : nt,
@@ -25579,7 +25580,7 @@ var JS = class nh {
25579
25580
  request: { body: t },
25580
25581
  response: { headers: d }
25581
25582
  };
25582
- const g = HS({
25583
+ const g = JS({
25583
25584
  baseURL: this.config.baseURL,
25584
25585
  interactionId: v,
25585
25586
  headers: a,
@@ -25607,7 +25608,7 @@ function Uo(e) {
25607
25608
  function Cc(e) {
25608
25609
  return e != null && typeof e == "object" && !Array.isArray(e);
25609
25610
  }
25610
- var KS = class {
25611
+ var XS = class {
25611
25612
  constructor() {
25612
25613
  this.turnCounter = 0, this.hasAudio = !1, this.hasText = !1, this.hasTranscript = !1, this.turnClosed = !1, this.inputAudioRate = 16e3;
25613
25614
  }
@@ -25757,7 +25758,7 @@ var KS = class {
25757
25758
  }
25758
25759
  };
25759
25760
  case "function-call-output":
25760
- return YS(n);
25761
+ return QS(n);
25761
25762
  case "audio-message":
25762
25763
  return null;
25763
25764
  }
@@ -25767,7 +25768,7 @@ var KS = class {
25767
25768
  return null;
25768
25769
  }
25769
25770
  };
25770
- async function YS(e) {
25771
+ async function QS(e) {
25771
25772
  const t = await mo({ text: e.output }), o = t.success ? t.value : {};
25772
25773
  return {
25773
25774
  toolResponse: {
@@ -25817,22 +25818,22 @@ function es(e, t) {
25817
25818
  }
25818
25819
  return o;
25819
25820
  }
25820
- var XS = "google.ai.generativelanguage.v1alpha.GenerativeService.BidiGenerateContentConstrained";
25821
+ var eC = "google.ai.generativelanguage.v1alpha.GenerativeService.BidiGenerateContentConstrained";
25821
25822
  function ah(e) {
25822
25823
  const t = new URL(e), o = t.pathname.split("/"), n = o.at(-1);
25823
25824
  return (n === "v1beta" || n === "v1alpha") && (o.pop(), t.pathname = o.join("/") || "/"), t;
25824
25825
  }
25825
- function QS(e) {
25826
+ function tC(e) {
25826
25827
  const t = ah(e);
25827
25828
  return t.pathname = `${t.pathname.replace(/\/$/, "")}/v1alpha/auth_tokens`, t.toString();
25828
25829
  }
25829
- function eC(e) {
25830
+ function oC(e) {
25830
25831
  const t = ah(e);
25831
- return t.protocol = t.protocol === "https:" ? "wss:" : "ws:", t.pathname = `${t.pathname.replace(/\/$/, "")}/ws/${XS}`, t.toString();
25832
+ return t.protocol = t.protocol === "https:" ? "wss:" : "ws:", t.pathname = `${t.pathname.replace(/\/$/, "")}/ws/${eC}`, t.toString();
25832
25833
  }
25833
- var tC = class {
25834
+ var nC = class {
25834
25835
  constructor(e, t) {
25835
- this.specificationVersion = "v4", this.mapper = new KS(), this.modelId = e, this.provider = t.provider, this.config = t;
25836
+ this.specificationVersion = "v4", this.mapper = new XS(), this.modelId = e, this.provider = t.provider, this.config = t;
25836
25837
  }
25837
25838
  async doCreateClientSecret(e) {
25838
25839
  var t, o;
@@ -25847,7 +25848,7 @@ var tC = class {
25847
25848
  e.sessionConfig,
25848
25849
  this.modelId
25849
25850
  ), m = await n(
25850
- `${QS(this.config.baseURL)}?key=${encodeURIComponent(r)}`,
25851
+ `${tC(this.config.baseURL)}?key=${encodeURIComponent(r)}`,
25851
25852
  {
25852
25853
  method: "POST",
25853
25854
  headers: { "Content-Type": "application/json" },
@@ -25871,7 +25872,7 @@ var tC = class {
25871
25872
  const v = await m.json();
25872
25873
  return {
25873
25874
  token: v.name,
25874
- url: eC(this.config.baseURL),
25875
+ url: oC(this.config.baseURL),
25875
25876
  expiresAt: v.expireTime ? Math.floor(new Date(v.expireTime).getTime() / 1e3) : void 0
25876
25877
  };
25877
25878
  }
@@ -25901,7 +25902,7 @@ function rh(e = {}) {
25901
25902
  }),
25902
25903
  ...e.headers
25903
25904
  },
25904
- `ai-sdk/google/${hk}`
25905
+ `ai-sdk/google/${vk}`
25905
25906
  ), s = (x) => {
25906
25907
  var w;
25907
25908
  return new Df(x, {
@@ -25923,36 +25924,36 @@ function rh(e = {}) {
25923
25924
  }),
25924
25925
  fetch: e.fetch
25925
25926
  });
25926
- }, l = (x) => new _k(x, {
25927
+ }, l = (x) => new wk(x, {
25927
25928
  provider: a,
25928
25929
  baseURL: n,
25929
25930
  headers: r,
25930
25931
  fetch: e.fetch
25931
- }), c = (x, w = {}) => new eS(x, w, {
25932
+ }), c = (x, w = {}) => new oS(x, w, {
25932
25933
  provider: a,
25933
25934
  baseURL: n,
25934
25935
  headers: r,
25935
25936
  fetch: e.fetch
25936
- }), p = () => new oS({
25937
+ }), p = () => new aS({
25937
25938
  provider: a,
25938
25939
  baseURL: n,
25939
25940
  headers: r,
25940
25941
  fetch: e.fetch
25941
25942
  }), d = (x) => {
25942
25943
  var w;
25943
- return new pS(x, {
25944
+ return new fS(x, {
25944
25945
  provider: a,
25945
25946
  baseURL: n,
25946
25947
  headers: r,
25947
25948
  fetch: e.fetch,
25948
25949
  generateId: (w = e.generateId) != null ? w : nt
25949
25950
  });
25950
- }, m = (x) => new tC(x, {
25951
+ }, m = (x) => new nC(x, {
25951
25952
  provider: `${a}.realtime`,
25952
25953
  baseURL: n,
25953
25954
  headers: r,
25954
25955
  fetch: e.fetch
25955
- }), v = (x) => new yS(x, {
25956
+ }), v = (x) => new bS(x, {
25956
25957
  provider: `${a}.speech`,
25957
25958
  baseURL: n,
25958
25959
  headers: r,
@@ -25974,7 +25975,7 @@ function rh(e = {}) {
25974
25975
  }
25975
25976
  ), g = (x) => {
25976
25977
  var w;
25977
- return new JS(
25978
+ return new YS(
25978
25979
  x,
25979
25980
  {
25980
25981
  provider: `${a}.interactions`,
@@ -25991,10 +25992,10 @@ function rh(e = {}) {
25991
25992
  );
25992
25993
  return s(x);
25993
25994
  };
25994
- return b.specificationVersion = "v4", b.languageModel = s, b.chat = s, b.generativeAI = s, b.embedding = l, b.embeddingModel = l, b.textEmbedding = l, b.textEmbeddingModel = l, b.image = c, b.imageModel = c, b.video = d, b.videoModel = d, b.experimental_realtime = y, b.files = p, b.speech = v, b.speechModel = v, b.interactions = g, b.tools = Qk, b;
25995
+ return b.specificationVersion = "v4", b.languageModel = s, b.chat = s, b.generativeAI = s, b.embedding = l, b.embeddingModel = l, b.textEmbedding = l, b.textEmbeddingModel = l, b.image = c, b.imageModel = c, b.video = d, b.videoModel = d, b.experimental_realtime = y, b.files = p, b.speech = v, b.speechModel = v, b.interactions = g, b.tools = tS, b;
25995
25996
  }
25996
- var eO = rh();
25997
- function oC(e, t) {
25997
+ var oO = rh();
25998
+ function aC(e, t) {
25998
25999
  return rh(t)(e);
25999
26000
  }
26000
26001
  var Us = u({
@@ -26041,7 +26042,7 @@ async function Ls({
26041
26042
  const m = t(d.value);
26042
26043
  if (m != null)
26043
26044
  throw l.cancel().catch(() => {
26044
- }), nC({
26045
+ }), rC({
26045
26046
  frame: m,
26046
26047
  url: n,
26047
26048
  requestBodyValues: a,
@@ -26055,25 +26056,25 @@ async function Ls({
26055
26056
  }), c.releaseLock();
26056
26057
  }
26057
26058
  }
26058
- function nC({
26059
+ function rC({
26059
26060
  frame: e,
26060
26061
  url: t,
26061
26062
  requestBodyValues: o,
26062
26063
  responseHeaders: n
26063
26064
  }) {
26064
26065
  var a;
26065
- const r = aC(e);
26066
+ const r = iC(e);
26066
26067
  return new et({
26067
26068
  message: (a = r?.message) != null ? a : "OpenAI stream failed before any output was generated",
26068
26069
  url: t,
26069
26070
  requestBodyValues: o,
26070
- statusCode: r == null ? 500 : rC(r),
26071
+ statusCode: r == null ? 500 : sC(r),
26071
26072
  responseHeaders: n,
26072
26073
  responseBody: JSON.stringify(e),
26073
26074
  data: e
26074
26075
  });
26075
26076
  }
26076
- function aC(e) {
26077
+ function iC(e) {
26077
26078
  var t;
26078
26079
  const o = ba(e);
26079
26080
  if (o == null)
@@ -26095,7 +26096,7 @@ function aC(e) {
26095
26096
  frame: e
26096
26097
  } : void 0;
26097
26098
  }
26098
- function rC(e) {
26099
+ function sC(e) {
26099
26100
  if (typeof e.code == "number" && Mc(e.code))
26100
26101
  return e.code;
26101
26102
  if (typeof e.code == "string" && /^\d{3}$/.test(e.code)) {
@@ -26152,10 +26153,10 @@ function Rc(e) {
26152
26153
  raw: e
26153
26154
  };
26154
26155
  }
26155
- function iC(e) {
26156
+ function lC(e) {
26156
26157
  return JSON.stringify(e === void 0 ? {} : e);
26157
26158
  }
26158
- function sC({
26159
+ function uC({
26159
26160
  prompt: e,
26160
26161
  systemMessageMode: t = "system"
26161
26162
  }) {
@@ -26298,7 +26299,7 @@ function sC({
26298
26299
  type: "function",
26299
26300
  function: {
26300
26301
  name: p.toolName,
26301
- arguments: iC(p.input)
26302
+ arguments: lC(p.input)
26302
26303
  }
26303
26304
  });
26304
26305
  break;
@@ -26372,7 +26373,7 @@ function Oc(e) {
26372
26373
  return "other";
26373
26374
  }
26374
26375
  }
26375
- var lC = K(
26376
+ var cC = K(
26376
26377
  () => W(
26377
26378
  u({
26378
26379
  id: i().nullish(),
@@ -26438,7 +26439,7 @@ var lC = K(
26438
26439
  }).nullish()
26439
26440
  })
26440
26441
  )
26441
- ), uC = K(
26442
+ ), dC = K(
26442
26443
  () => W(
26443
26444
  ce([
26444
26445
  u({
@@ -26508,7 +26509,7 @@ var lC = K(
26508
26509
  Us
26509
26510
  ])
26510
26511
  )
26511
- ), cC = K(
26512
+ ), pC = K(
26512
26513
  () => W(
26513
26514
  u({
26514
26515
  /**
@@ -26623,7 +26624,7 @@ var lC = K(
26623
26624
  })
26624
26625
  )
26625
26626
  );
26626
- function dC({
26627
+ function mC({
26627
26628
  tools: e,
26628
26629
  toolChoice: t
26629
26630
  }) {
@@ -26672,7 +26673,7 @@ function dC({
26672
26673
  }
26673
26674
  }
26674
26675
  }
26675
- var pC = class sh {
26676
+ var fC = class sh {
26676
26677
  constructor(t, o) {
26677
26678
  this.specificationVersion = "v4", this.supportedUrls = {
26678
26679
  "image/*": [/^https?:\/\/.*$/]
@@ -26710,10 +26711,10 @@ var pC = class sh {
26710
26711
  const S = [], E = (b = await tt({
26711
26712
  provider: "openai",
26712
26713
  providerOptions: g,
26713
- schema: cC
26714
+ schema: pC
26714
26715
  })) != null ? b : {}, O = ih(this.modelId), R = (x = E.reasoningEffort) != null ? x : Ua(y) ? y : void 0, C = (w = E.forceReasoning) != null ? w : O.isReasoningModel;
26715
26716
  r != null && S.push({ type: "unsupported", feature: "topK" });
26716
- const { messages: P, warnings: H } = sC(
26717
+ const { messages: P, warnings: H } = uC(
26717
26718
  {
26718
26719
  prompt: t,
26719
26720
  systemMessageMode: (_ = E.systemMessageMode) != null ? _ : C ? "developer" : O.systemMessageMode
@@ -26803,7 +26804,7 @@ var pC = class sh {
26803
26804
  tools: D,
26804
26805
  toolChoice: re,
26805
26806
  toolWarnings: F
26806
- } = dC({
26807
+ } = mC({
26807
26808
  tools: m,
26808
26809
  toolChoice: v
26809
26810
  });
@@ -26831,7 +26832,7 @@ var pC = class sh {
26831
26832
  body: d,
26832
26833
  failedResponseHandler: ao,
26833
26834
  successfulResponseHandler: Fe(
26834
- lC
26835
+ cC
26835
26836
  ),
26836
26837
  abortSignal: t.abortSignal,
26837
26838
  fetch: this.config.fetch
@@ -26887,14 +26888,14 @@ var pC = class sh {
26887
26888
  body: s,
26888
26889
  failedResponseHandler: ao,
26889
26890
  successfulResponseHandler: fn(
26890
- uC
26891
+ dC
26891
26892
  ),
26892
26893
  abortSignal: t.abortSignal,
26893
26894
  fetch: this.config.fetch
26894
26895
  }), d = await Ls({
26895
26896
  stream: p,
26896
26897
  getError: (_) => "error" in _ ? _.error : void 0,
26897
- isOutputChunk: mC,
26898
+ isOutputChunk: hC,
26898
26899
  url: l,
26899
26900
  requestBodyValues: s,
26900
26901
  responseHeaders: c
@@ -26971,7 +26972,7 @@ var pC = class sh {
26971
26972
  };
26972
26973
  }
26973
26974
  };
26974
- function mC(e) {
26975
+ function hC(e) {
26975
26976
  return "error" in e ? !1 : e.choices.some((t) => {
26976
26977
  const o = t.delta;
26977
26978
  return o?.content != null && o.content.length > 0 || o?.tool_calls != null && o.tool_calls.length > 0 || o?.annotations != null && o.annotations.length > 0;
@@ -27010,7 +27011,7 @@ function Ac(e) {
27010
27011
  raw: e
27011
27012
  };
27012
27013
  }
27013
- function fC({
27014
+ function gC({
27014
27015
  prompt: e,
27015
27016
  user: t = "user",
27016
27017
  assistant: o = "assistant"
@@ -27096,7 +27097,7 @@ function $c(e) {
27096
27097
  return "other";
27097
27098
  }
27098
27099
  }
27099
- var hC = K(
27100
+ var vC = K(
27100
27101
  () => W(
27101
27102
  u({
27102
27103
  id: i().nullish(),
@@ -27120,7 +27121,7 @@ var hC = K(
27120
27121
  }).nullish()
27121
27122
  })
27122
27123
  )
27123
- ), gC = K(
27124
+ ), yC = K(
27124
27125
  () => W(
27125
27126
  ce([
27126
27127
  u({
@@ -27191,7 +27192,7 @@ var hC = K(
27191
27192
  logprobs: ce([ae(), T()]).optional()
27192
27193
  })
27193
27194
  )
27194
- ), vC = class lh {
27195
+ ), _C = class lh {
27195
27196
  constructor(t, o) {
27196
27197
  this.specificationVersion = "v4", this.supportedUrls = {
27197
27198
  // No URLs are supported for completion models.
@@ -27244,7 +27245,7 @@ var hC = K(
27244
27245
  feature: "responseFormat",
27245
27246
  details: "JSON response format is not supported."
27246
27247
  });
27247
- const { prompt: x, stopSequences: w } = fC({ prompt: t }), _ = [...w ?? [], ...c ?? []];
27248
+ const { prompt: x, stopSequences: w } = gC({ prompt: t }), _ = [...w ?? [], ...c ?? []];
27248
27249
  return {
27249
27250
  args: {
27250
27251
  // model id:
@@ -27285,7 +27286,7 @@ var hC = K(
27285
27286
  body: r,
27286
27287
  failedResponseHandler: ao,
27287
27288
  successfulResponseHandler: Fe(
27288
- hC
27289
+ vC
27289
27290
  ),
27290
27291
  abortSignal: t.abortSignal,
27291
27292
  fetch: this.config.fetch
@@ -27324,14 +27325,14 @@ var hC = K(
27324
27325
  body: s,
27325
27326
  failedResponseHandler: ao,
27326
27327
  successfulResponseHandler: fn(
27327
- gC
27328
+ yC
27328
27329
  ),
27329
27330
  abortSignal: t.abortSignal,
27330
27331
  fetch: this.config.fetch
27331
27332
  }), d = await Ls({
27332
27333
  stream: p,
27333
27334
  getError: (x) => "error" in x ? x.error : void 0,
27334
- isOutputChunk: yC,
27335
+ isOutputChunk: bC,
27335
27336
  url: l,
27336
27337
  requestBodyValues: s,
27337
27338
  responseHeaders: c
@@ -27387,10 +27388,10 @@ var hC = K(
27387
27388
  };
27388
27389
  }
27389
27390
  };
27390
- function yC(e) {
27391
+ function bC(e) {
27391
27392
  return !("error" in e) && e.choices.some((t) => t.text.length > 0);
27392
27393
  }
27393
- var _C = K(
27394
+ var wC = K(
27394
27395
  () => W(
27395
27396
  u({
27396
27397
  /**
@@ -27405,14 +27406,14 @@ var _C = K(
27405
27406
  user: i().optional()
27406
27407
  })
27407
27408
  )
27408
- ), bC = K(
27409
+ ), xC = K(
27409
27410
  () => W(
27410
27411
  u({
27411
27412
  data: A(u({ embedding: A(T()) })),
27412
27413
  usage: u({ prompt_tokens: T() }).nullish()
27413
27414
  })
27414
27415
  )
27415
- ), wC = class uh {
27416
+ ), TC = class uh {
27416
27417
  constructor(t, o) {
27417
27418
  this.specificationVersion = "v4", this.maxEmbeddingsPerCall = 2048, this.supportsParallelCalls = !0, this.modelId = t, this.config = o;
27418
27419
  }
@@ -27445,7 +27446,7 @@ var _C = K(
27445
27446
  const c = (r = await tt({
27446
27447
  provider: "openai",
27447
27448
  providerOptions: a,
27448
- schema: _C
27449
+ schema: wC
27449
27450
  })) != null ? r : {}, {
27450
27451
  responseHeaders: p,
27451
27452
  value: d,
@@ -27465,7 +27466,7 @@ var _C = K(
27465
27466
  },
27466
27467
  failedResponseHandler: ao,
27467
27468
  successfulResponseHandler: Fe(
27468
- bC
27469
+ xC
27469
27470
  ),
27470
27471
  abortSignal: n,
27471
27472
  fetch: this.config.fetch
@@ -27477,7 +27478,7 @@ var _C = K(
27477
27478
  response: { headers: p, body: m }
27478
27479
  };
27479
27480
  }
27480
- }, xC = K(
27481
+ }, IC = K(
27481
27482
  () => W(
27482
27483
  u({
27483
27484
  id: i(),
@@ -27490,7 +27491,7 @@ var _C = K(
27490
27491
  expires_at: T().nullish()
27491
27492
  })
27492
27493
  )
27493
- ), TC = K(
27494
+ ), kC = K(
27494
27495
  () => W(
27495
27496
  u({
27496
27497
  /*
@@ -27502,7 +27503,7 @@ var _C = K(
27502
27503
  expiresAfter: T().optional()
27503
27504
  })
27504
27505
  )
27505
- ), IC = class {
27506
+ ), SC = class {
27506
27507
  constructor(e) {
27507
27508
  this.config = e, this.specificationVersion = "v4";
27508
27509
  }
@@ -27519,7 +27520,7 @@ var _C = K(
27519
27520
  const l = await tt({
27520
27521
  provider: "openai",
27521
27522
  providerOptions: n,
27522
- schema: TC
27523
+ schema: kC
27523
27524
  }), c = ja(e), p = new Blob([c], {
27524
27525
  type: t
27525
27526
  }), d = new FormData();
@@ -27530,7 +27531,7 @@ var _C = K(
27530
27531
  formData: d,
27531
27532
  failedResponseHandler: ao,
27532
27533
  successfulResponseHandler: Fe(
27533
- xC
27534
+ IC
27534
27535
  ),
27535
27536
  fetch: this.config.fetch
27536
27537
  });
@@ -27576,7 +27577,7 @@ var _C = K(
27576
27577
  }).nullish()
27577
27578
  })
27578
27579
  )
27579
- ), kC = {
27580
+ ), CC = {
27580
27581
  "dall-e-3": 1,
27581
27582
  "dall-e-2": 10,
27582
27583
  "gpt-image-1": 10,
@@ -27584,15 +27585,15 @@ var _C = K(
27584
27585
  "gpt-image-1.5": 10,
27585
27586
  "gpt-image-2": 10,
27586
27587
  "chatgpt-image-latest": 10
27587
- }, SC = [
27588
+ }, EC = [
27588
27589
  "chatgpt-image-",
27589
27590
  "gpt-image-1-mini",
27590
27591
  "gpt-image-1.5",
27591
27592
  "gpt-image-1",
27592
27593
  "gpt-image-2"
27593
27594
  ];
27594
- function CC(e) {
27595
- return SC.some(
27595
+ function MC(e) {
27596
+ return EC.some(
27596
27597
  (t) => e.startsWith(t)
27597
27598
  );
27598
27599
  }
@@ -27624,7 +27625,7 @@ var ch = u({
27624
27625
  * to monitor and detect abuse.
27625
27626
  */
27626
27627
  user: i().optional()
27627
- }), EC = K(
27628
+ }), RC = K(
27628
27629
  () => W(
27629
27630
  ch.extend({
27630
27631
  /**
@@ -27640,7 +27641,7 @@ var ch = u({
27640
27641
  moderation: ee(["auto", "low"]).optional()
27641
27642
  })
27642
27643
  )
27643
- ), MC = K(
27644
+ ), OC = K(
27644
27645
  () => W(
27645
27646
  ch.extend({
27646
27647
  /**
@@ -27649,7 +27650,7 @@ var ch = u({
27649
27650
  inputFidelity: ee(["high", "low"]).optional()
27650
27651
  })
27651
27652
  )
27652
- ), RC = class dh {
27653
+ ), AC = class dh {
27653
27654
  constructor(t, o) {
27654
27655
  this.modelId = t, this.config = o, this.specificationVersion = "v4";
27655
27656
  }
@@ -27664,7 +27665,7 @@ var ch = u({
27664
27665
  }
27665
27666
  get maxImagesPerCall() {
27666
27667
  var t;
27667
- return (t = kC[this.modelId]) != null ? t : 1;
27668
+ return (t = CC[this.modelId]) != null ? t : 1;
27668
27669
  }
27669
27670
  get provider() {
27670
27671
  return this.config.provider;
@@ -27693,7 +27694,7 @@ var ch = u({
27693
27694
  const re = (g = await tt({
27694
27695
  provider: "openai",
27695
27696
  providerOptions: c,
27696
- schema: MC
27697
+ schema: OC
27697
27698
  })) != null ? g : {}, { value: F, responseHeaders: J } = await ia({
27698
27699
  url: this.config.url({
27699
27700
  path: "/images/edits",
@@ -27717,7 +27718,7 @@ var ch = u({
27717
27718
  ) : yp(G.url)
27718
27719
  )
27719
27720
  ),
27720
- mask: n != null ? await OC(n) : void 0,
27721
+ mask: n != null ? await NC(n) : void 0,
27721
27722
  n: a,
27722
27723
  size: r,
27723
27724
  quality: re.quality,
@@ -27772,7 +27773,7 @@ var ch = u({
27772
27773
  const Y = (h = await tt({
27773
27774
  provider: "openai",
27774
27775
  providerOptions: c,
27775
- schema: EC
27776
+ schema: RC
27776
27777
  })) != null ? h : {}, { value: z, responseHeaders: D } = await Je({
27777
27778
  url: this.config.url({
27778
27779
  path: "/images/generations",
@@ -27791,7 +27792,7 @@ var ch = u({
27791
27792
  output_format: Y.outputFormat,
27792
27793
  output_compression: Y.outputCompression,
27793
27794
  user: Y.user,
27794
- ...CC(this.modelId) ? {} : { response_format: "b64_json" }
27795
+ ...MC(this.modelId) ? {} : { response_format: "b64_json" }
27795
27796
  },
27796
27797
  failedResponseHandler: ao,
27797
27798
  successfulResponseHandler: Fe(
@@ -27850,7 +27851,7 @@ function qc(e, t, o) {
27850
27851
  }
27851
27852
  return n;
27852
27853
  }
27853
- async function OC(e) {
27854
+ async function NC(e) {
27854
27855
  if (!e) return;
27855
27856
  if (e.type === "url")
27856
27857
  return yp(e.url);
@@ -27886,18 +27887,18 @@ var ph = K(
27886
27887
  output: i().optional()
27887
27888
  })
27888
27889
  )
27889
- ), AC = Ur({
27890
+ ), $C = Ur({
27890
27891
  id: "openai.apply_patch",
27891
27892
  inputSchema: ph,
27892
27893
  outputSchema: mh
27893
- }), NC = AC, $C = K(
27894
+ }), PC = $C, DC = K(
27894
27895
  () => W(
27895
27896
  u({
27896
27897
  code: i().nullish(),
27897
27898
  containerId: i()
27898
27899
  })
27899
27900
  )
27900
- ), PC = K(
27901
+ ), qC = K(
27901
27902
  () => W(
27902
27903
  u({
27903
27904
  outputs: A(
@@ -27908,7 +27909,7 @@ var ph = K(
27908
27909
  ).nullish()
27909
27910
  })
27910
27911
  )
27911
- ), DC = K(
27912
+ ), jC = K(
27912
27913
  () => W(
27913
27914
  u({
27914
27915
  container: ce([
@@ -27919,11 +27920,11 @@ var ph = K(
27919
27920
  ]).optional()
27920
27921
  })
27921
27922
  )
27922
- ), qC = it({
27923
+ ), UC = it({
27923
27924
  id: "openai.code_interpreter",
27924
- inputSchema: $C,
27925
- outputSchema: PC
27926
- }), jC = (e = {}) => qC(e), UC = K(
27925
+ inputSchema: DC,
27926
+ outputSchema: qC
27927
+ }), LC = (e = {}) => UC(e), zC = K(
27927
27928
  () => W(
27928
27929
  u({
27929
27930
  description: i().optional(),
@@ -27939,10 +27940,10 @@ var ph = K(
27939
27940
  ]).optional()
27940
27941
  })
27941
27942
  )
27942
- ), LC = K(() => W(i())), zC = Io({
27943
+ ), FC = K(() => W(i())), ZC = Io({
27943
27944
  id: "openai.custom",
27944
- inputSchema: LC
27945
- }), FC = (e) => zC(e), fh = u({
27945
+ inputSchema: FC
27946
+ }), VC = (e) => ZC(e), fh = u({
27946
27947
  key: i(),
27947
27948
  type: ee(["eq", "ne", "gt", "gte", "lt", "lte", "in", "nin"]),
27948
27949
  value: ce([i(), T(), ae(), A(i())])
@@ -27951,7 +27952,7 @@ var ph = K(
27951
27952
  filters: A(
27952
27953
  ce([fh, Pr(() => hh)])
27953
27954
  )
27954
- }), ZC = K(
27955
+ }), GC = K(
27955
27956
  () => W(
27956
27957
  u({
27957
27958
  vectorStoreIds: A(i()),
@@ -27963,7 +27964,7 @@ var ph = K(
27963
27964
  filters: ce([fh, hh]).optional()
27964
27965
  })
27965
27966
  )
27966
- ), VC = K(
27967
+ ), BC = K(
27967
27968
  () => W(
27968
27969
  u({
27969
27970
  queries: A(i()),
@@ -27978,11 +27979,11 @@ var ph = K(
27978
27979
  ).nullable()
27979
27980
  })
27980
27981
  )
27981
- ), GC = it({
27982
+ ), HC = it({
27982
27983
  id: "openai.file_search",
27983
27984
  inputSchema: u({}),
27984
- outputSchema: VC
27985
- }), BC = K(
27985
+ outputSchema: BC
27986
+ }), WC = K(
27986
27987
  () => W(
27987
27988
  u({
27988
27989
  background: ee(["auto", "opaque", "transparent"]).optional(),
@@ -28000,13 +28001,13 @@ var ph = K(
28000
28001
  size: ee(["1024x1024", "1024x1536", "1536x1024", "auto"]).optional()
28001
28002
  }).strict()
28002
28003
  )
28003
- ), HC = K(() => W(u({}))), WC = K(
28004
+ ), JC = K(() => W(u({}))), KC = K(
28004
28005
  () => W(u({ result: i() }))
28005
- ), JC = it({
28006
+ ), YC = it({
28006
28007
  id: "openai.image_generation",
28007
- inputSchema: HC,
28008
- outputSchema: WC
28009
- }), KC = (e = {}) => JC(e), gh = K(
28008
+ inputSchema: JC,
28009
+ outputSchema: KC
28010
+ }), XC = (e = {}) => YC(e), gh = K(
28010
28011
  () => W(
28011
28012
  u({
28012
28013
  action: u({
@@ -28021,7 +28022,7 @@ var ph = K(
28021
28022
  )
28022
28023
  ), vh = K(
28023
28024
  () => W(u({ output: i() }))
28024
- ), YC = Ur({
28025
+ ), QC = Ur({
28025
28026
  id: "openai.local_shell",
28026
28027
  inputSchema: gh,
28027
28028
  outputSchema: vh
@@ -28050,7 +28051,7 @@ var ph = K(
28050
28051
  )
28051
28052
  })
28052
28053
  )
28053
- ), XC = A(
28054
+ ), eE = A(
28054
28055
  Te("type", [
28055
28056
  u({
28056
28057
  type: f("skillReference"),
@@ -28068,7 +28069,7 @@ var ph = K(
28068
28069
  })
28069
28070
  })
28070
28071
  ])
28071
- ).optional(), QC = K(
28072
+ ).optional(), tE = K(
28072
28073
  () => W(
28073
28074
  u({
28074
28075
  environment: ce([
@@ -28090,7 +28091,7 @@ var ph = K(
28090
28091
  ).optional()
28091
28092
  })
28092
28093
  ]).optional(),
28093
- skills: XC
28094
+ skills: eE
28094
28095
  }),
28095
28096
  u({
28096
28097
  type: f("containerReference"),
@@ -28109,11 +28110,11 @@ var ph = K(
28109
28110
  ]).optional()
28110
28111
  })
28111
28112
  )
28112
- ), eE = Ur({
28113
+ ), oE = Ur({
28113
28114
  id: "openai.shell",
28114
28115
  inputSchema: yh,
28115
28116
  outputSchema: ts
28116
- }), tE = K(
28117
+ }), nE = K(
28117
28118
  () => W(
28118
28119
  u({
28119
28120
  execution: ee(["server", "client"]).optional(),
@@ -28134,11 +28135,11 @@ var ph = K(
28134
28135
  tools: A(Ce(i(), he()))
28135
28136
  })
28136
28137
  )
28137
- ), oE = Ur({
28138
+ ), aE = Ur({
28138
28139
  id: "openai.tool_search",
28139
28140
  inputSchema: os,
28140
28141
  outputSchema: ns
28141
- }), nE = (e = {}) => oE(e), aE = K(
28142
+ }), rE = (e = {}) => aE(e), iE = K(
28142
28143
  () => W(
28143
28144
  u({
28144
28145
  externalWebAccess: ae().optional(),
@@ -28153,7 +28154,7 @@ var ph = K(
28153
28154
  }).optional()
28154
28155
  })
28155
28156
  )
28156
- ), rE = K(() => W(u({}))), iE = K(
28157
+ ), sE = K(() => W(u({}))), lE = K(
28157
28158
  () => W(
28158
28159
  u({
28159
28160
  action: Te("type", [
@@ -28180,11 +28181,11 @@ var ph = K(
28180
28181
  ).optional()
28181
28182
  })
28182
28183
  )
28183
- ), sE = it({
28184
+ ), uE = it({
28184
28185
  id: "openai.web_search",
28185
- inputSchema: rE,
28186
- outputSchema: iE
28187
- }), lE = (e = {}) => sE(e), uE = K(
28186
+ inputSchema: sE,
28187
+ outputSchema: lE
28188
+ }), cE = (e = {}) => uE(e), dE = K(
28188
28189
  () => W(
28189
28190
  u({
28190
28191
  searchContextSize: ee(["low", "medium", "high"]).optional(),
@@ -28197,9 +28198,9 @@ var ph = K(
28197
28198
  }).optional()
28198
28199
  })
28199
28200
  )
28200
- ), cE = K(
28201
+ ), pE = K(
28201
28202
  () => W(u({}))
28202
- ), dE = K(
28203
+ ), mE = K(
28203
28204
  () => W(
28204
28205
  u({
28205
28206
  action: Te("type", [
@@ -28219,10 +28220,10 @@ var ph = K(
28219
28220
  ]).optional()
28220
28221
  })
28221
28222
  )
28222
- ), pE = it({
28223
+ ), fE = it({
28223
28224
  id: "openai.web_search_preview",
28224
- inputSchema: cE,
28225
- outputSchema: dE
28225
+ inputSchema: pE,
28226
+ outputSchema: mE
28226
28227
  }), as = Pr(
28227
28228
  () => ce([
28228
28229
  i(),
@@ -28232,7 +28233,7 @@ var ph = K(
28232
28233
  A(as),
28233
28234
  Ce(i(), as)
28234
28235
  ])
28235
- ), mE = K(
28236
+ ), hE = K(
28236
28237
  () => W(
28237
28238
  u({
28238
28239
  serverLabel: i(),
@@ -28261,7 +28262,7 @@ var ph = K(
28261
28262
  "One of serverUrl or connectorId must be provided."
28262
28263
  )
28263
28264
  )
28264
- ), fE = K(() => W(u({}))), hE = K(
28265
+ ), gE = K(() => W(u({}))), vE = K(
28265
28266
  () => W(
28266
28267
  u({
28267
28268
  type: f("call"),
@@ -28272,11 +28273,11 @@ var ph = K(
28272
28273
  error: ce([i(), as]).optional()
28273
28274
  })
28274
28275
  )
28275
- ), gE = it({
28276
+ ), yE = it({
28276
28277
  id: "openai.mcp",
28277
- inputSchema: fE,
28278
- outputSchema: hE
28279
- }), vE = (e) => gE(e), yE = {
28278
+ inputSchema: gE,
28279
+ outputSchema: vE
28280
+ }), _E = (e) => yE(e), bE = {
28280
28281
  /**
28281
28282
  * The apply_patch tool lets GPT-5.1 create, update, and delete files in your
28282
28283
  * codebase using structured diffs. Instead of just suggesting edits, the model
@@ -28284,7 +28285,7 @@ var ph = K(
28284
28285
  * enabling iterative, multi-step code editing workflows.
28285
28286
  *
28286
28287
  */
28287
- applyPatch: NC,
28288
+ applyPatch: PC,
28288
28289
  /**
28289
28290
  * Custom tools let callers constrain model output to a grammar (regex or
28290
28291
  * Lark syntax). The model returns a `custom_tool_call` output item whose
@@ -28293,7 +28294,7 @@ var ph = K(
28293
28294
  * @param description - An optional description of the tool.
28294
28295
  * @param format - The output format constraint (grammar type, syntax, and definition).
28295
28296
  */
28296
- customTool: FC,
28297
+ customTool: VC,
28297
28298
  /**
28298
28299
  * The Code Interpreter tool allows models to write and run Python code in a
28299
28300
  * sandboxed environment to solve complex problems in domains like data analysis,
@@ -28301,7 +28302,7 @@ var ph = K(
28301
28302
  *
28302
28303
  * @param container - The container to use for the code interpreter.
28303
28304
  */
28304
- codeInterpreter: jC,
28305
+ codeInterpreter: LC,
28305
28306
  /**
28306
28307
  * File search is a tool available in the Responses API. It enables models to
28307
28308
  * retrieve information in a knowledge base of previously uploaded files through
@@ -28312,7 +28313,7 @@ var ph = K(
28312
28313
  * @param ranking - The ranking options to use for the file search.
28313
28314
  * @param filters - The filters to use for the file search.
28314
28315
  */
28315
- fileSearch: GC,
28316
+ fileSearch: HC,
28316
28317
  /**
28317
28318
  * The image generation tool allows you to generate images using a text prompt,
28318
28319
  * and optionally image inputs. It leverages the GPT Image model,
@@ -28329,14 +28330,14 @@ var ph = K(
28329
28330
  * @param quality - The quality of the generated image. One of 'auto', 'low', 'medium', or 'high'.
28330
28331
  * @param size - The size of the generated image. One of 'auto', '1024x1024', '1024x1536', or '1536x1024'.
28331
28332
  */
28332
- imageGeneration: KC,
28333
+ imageGeneration: XC,
28333
28334
  /**
28334
28335
  * Local shell is a tool that allows agents to run shell commands locally
28335
28336
  * on a machine you or the user provides.
28336
28337
  *
28337
28338
  * Supported models: `gpt-5-codex`
28338
28339
  */
28339
- localShell: YC,
28340
+ localShell: QC,
28340
28341
  /**
28341
28342
  * The shell tool allows the model to interact with your local computer through
28342
28343
  * a controlled command-line interface. The model proposes shell commands; your
@@ -28348,7 +28349,7 @@ var ph = K(
28348
28349
  * execution or add strict allow-/deny-lists before forwarding a command to
28349
28350
  * the system shell.
28350
28351
  */
28351
- shell: eE,
28352
+ shell: oE,
28352
28353
  /**
28353
28354
  * Web search allows models to access up-to-date information from the internet
28354
28355
  * and provide answers with sourced citations.
@@ -28356,7 +28357,7 @@ var ph = K(
28356
28357
  * @param searchContextSize - The search context size to use for the web search.
28357
28358
  * @param userLocation - The user location to use for the web search.
28358
28359
  */
28359
- webSearchPreview: pE,
28360
+ webSearchPreview: fE,
28360
28361
  /**
28361
28362
  * Web search allows models to access up-to-date information from the internet
28362
28363
  * and provide answers with sourced citations.
@@ -28365,7 +28366,7 @@ var ph = K(
28365
28366
  * @param searchContextSize - The search context size to use for the web search.
28366
28367
  * @param userLocation - The user location to use for the web search.
28367
28368
  */
28368
- webSearch: lE,
28369
+ webSearch: cE,
28369
28370
  /**
28370
28371
  * MCP (Model Context Protocol) allows models to call tools exposed by
28371
28372
  * remote MCP servers or service connectors.
@@ -28379,7 +28380,7 @@ var ph = K(
28379
28380
  * @param serverDescription - Optional description of the server.
28380
28381
  * @param serverUrl - URL for the MCP server.
28381
28382
  */
28382
- mcp: vE,
28383
+ mcp: _E,
28383
28384
  /**
28384
28385
  * Tool search allows the model to dynamically search for and load deferred
28385
28386
  * tools into the model's context as needed. This helps reduce overall token
@@ -28389,9 +28390,9 @@ var ph = K(
28389
28390
  * in the tools array. The model will use tool search to load these tools
28390
28391
  * when it determines they are needed.
28391
28392
  */
28392
- toolSearch: nE
28393
+ toolSearch: rE
28393
28394
  };
28394
- function _E(e) {
28395
+ function wE(e) {
28395
28396
  var t, o, n, a, r, s, l, c, p, d, m, v, y, g, b, x, w, _, k;
28396
28397
  const h = e, S = h.type;
28397
28398
  switch (S) {
@@ -28565,7 +28566,7 @@ function _E(e) {
28565
28566
  return { type: "custom", rawType: S, raw: e };
28566
28567
  }
28567
28568
  }
28568
- function bE(e, t) {
28569
+ function xE(e, t) {
28569
28570
  switch (e.type) {
28570
28571
  case "session-update":
28571
28572
  return {
@@ -28678,7 +28679,7 @@ function rs(e, t) {
28678
28679
  parameters: r.parameters
28679
28680
  })), n.tool_choice = "auto"), e.providerOptions != null && Object.assign(n, e.providerOptions), n;
28680
28681
  }
28681
- var wE = class {
28682
+ var TE = class {
28682
28683
  constructor(e, t) {
28683
28684
  this.specificationVersion = "v4", this.modelId = e, this.provider = t.provider, this.config = t;
28684
28685
  }
@@ -28723,10 +28724,10 @@ var wE = class {
28723
28724
  };
28724
28725
  }
28725
28726
  parseServerEvent(e) {
28726
- return _E(e);
28727
+ return wE(e);
28727
28728
  }
28728
28729
  serializeClientEvent(e) {
28729
- return bE(e, this.modelId);
28730
+ return xE(e, this.modelId);
28730
28731
  }
28731
28732
  buildSessionConfig(e) {
28732
28733
  return rs(e, this.modelId);
@@ -28765,13 +28766,13 @@ function jc(e) {
28765
28766
  raw: e
28766
28767
  };
28767
28768
  }
28768
- function xE(e) {
28769
+ function IE(e) {
28769
28770
  return JSON.stringify(e === void 0 ? {} : e);
28770
28771
  }
28771
28772
  function Uc(e, t) {
28772
28773
  return t ? t.some((o) => e.startsWith(o)) : !1;
28773
28774
  }
28774
- async function TE({
28775
+ async function kE({
28775
28776
  prompt: e,
28776
28777
  toolNameMapping: t,
28777
28778
  systemMessageMode: o,
@@ -29007,7 +29008,7 @@ async function TE({
29007
29008
  type: "function_call",
29008
29009
  call_id: B.toolCallId,
29009
29010
  name: j,
29010
- arguments: xE(B.input),
29011
+ arguments: IE(B.input),
29011
29012
  ...te != null && { namespace: te }
29012
29013
  });
29013
29014
  break;
@@ -29074,7 +29075,7 @@ async function TE({
29074
29075
  const Z = await tt({
29075
29076
  provider: n,
29076
29077
  providerOptions: B.providerOptions,
29077
- schema: IE
29078
+ schema: SE
29078
29079
  }), te = Z?.itemId;
29079
29080
  if ((l || c) && te != null)
29080
29081
  break;
@@ -29375,7 +29376,7 @@ async function TE({
29375
29376
  (pe) => !("type" in pe) || pe.type !== "reasoning" || pe.encrypted_content != null
29376
29377
  )), { input: L, warnings: oe };
29377
29378
  }
29378
- var IE = u({
29379
+ var SE = u({
29379
29380
  itemId: i().nullish(),
29380
29381
  reasoningEncryptedContent: i().nullish()
29381
29382
  });
@@ -29404,7 +29405,7 @@ var Na = Pr(
29404
29405
  A(Na),
29405
29406
  Ce(i(), Na.optional())
29406
29407
  ])
29407
- ), kE = u({
29408
+ ), CE = u({
29408
29409
  type: f("error"),
29409
29410
  sequence_number: T(),
29410
29411
  error: u({
@@ -29413,13 +29414,13 @@ var Na = Pr(
29413
29414
  message: i(),
29414
29415
  param: i().nullish()
29415
29416
  })
29416
- }), SE = u({
29417
+ }), EE = u({
29417
29418
  type: f("error"),
29418
29419
  sequence_number: T(),
29419
29420
  code: i().nullish(),
29420
29421
  message: i(),
29421
29422
  param: i().nullish()
29422
- }), CE = K(
29423
+ }), ME = K(
29423
29424
  () => W(
29424
29425
  ce([
29425
29426
  u({
@@ -29960,8 +29961,8 @@ var Na = Pr(
29960
29961
  output_index: T(),
29961
29962
  diff: i()
29962
29963
  }),
29963
- kE,
29964
- SE,
29964
+ CE,
29965
+ EE,
29965
29966
  u({ type: i() }).loose().transform((e) => ({
29966
29967
  type: "unknown_chunk",
29967
29968
  message: e.type
@@ -29969,7 +29970,7 @@ var Na = Pr(
29969
29970
  // fallback for unknown chunks
29970
29971
  ])
29971
29972
  )
29972
- ), EE = K(
29973
+ ), RE = K(
29973
29974
  () => W(
29974
29975
  u({
29975
29976
  id: i().optional(),
@@ -30468,7 +30469,7 @@ var Na = Pr(
30468
30469
  })
30469
30470
  )
30470
30471
  );
30471
- async function ME({
30472
+ async function OE({
30472
30473
  tools: e,
30473
30474
  toolChoice: t,
30474
30475
  allowedTools: o,
@@ -30484,7 +30485,7 @@ async function ME({
30484
30485
  for (const y of e)
30485
30486
  switch (y.type) {
30486
30487
  case "function": {
30487
- const g = (r = y.providerOptions) == null ? void 0 : r.openai, b = RE({
30488
+ const g = (r = y.providerOptions) == null ? void 0 : r.openai, b = AE({
30488
30489
  tool: y,
30489
30490
  options: g
30490
30491
  }), x = g?.namespace;
@@ -30512,7 +30513,7 @@ async function ME({
30512
30513
  case "openai.file_search": {
30513
30514
  const g = await $e({
30514
30515
  value: y.args,
30515
- schema: ZC
30516
+ schema: GC
30516
30517
  });
30517
30518
  p.push({
30518
30519
  type: "file_search",
@@ -30535,12 +30536,12 @@ async function ME({
30535
30536
  case "openai.shell": {
30536
30537
  const g = await $e({
30537
30538
  value: y.args,
30538
- schema: QC
30539
+ schema: tE
30539
30540
  });
30540
30541
  p.push({
30541
30542
  type: "shell",
30542
30543
  ...g.environment && {
30543
- environment: OE(g.environment)
30544
+ environment: NE(g.environment)
30544
30545
  }
30545
30546
  });
30546
30547
  break;
@@ -30554,7 +30555,7 @@ async function ME({
30554
30555
  case "openai.web_search_preview": {
30555
30556
  const g = await $e({
30556
30557
  value: y.args,
30557
- schema: uE
30558
+ schema: dE
30558
30559
  });
30559
30560
  p.push({
30560
30561
  type: "web_search_preview",
@@ -30566,7 +30567,7 @@ async function ME({
30566
30567
  case "openai.web_search": {
30567
30568
  const g = await $e({
30568
30569
  value: y.args,
30569
- schema: aE
30570
+ schema: iE
30570
30571
  });
30571
30572
  p.push({
30572
30573
  type: "web_search",
@@ -30580,7 +30581,7 @@ async function ME({
30580
30581
  case "openai.code_interpreter": {
30581
30582
  const g = await $e({
30582
30583
  value: y.args,
30583
- schema: DC
30584
+ schema: jC
30584
30585
  });
30585
30586
  p.push({
30586
30587
  type: "code_interpreter",
@@ -30591,7 +30592,7 @@ async function ME({
30591
30592
  case "openai.image_generation": {
30592
30593
  const g = await $e({
30593
30594
  value: y.args,
30594
- schema: BC
30595
+ schema: WC
30595
30596
  });
30596
30597
  p.push({
30597
30598
  type: "image_generation",
@@ -30614,7 +30615,7 @@ async function ME({
30614
30615
  case "openai.mcp": {
30615
30616
  const g = await $e({
30616
30617
  value: y.args,
30617
- schema: mE
30618
+ schema: hE
30618
30619
  }), b = (_) => ({
30619
30620
  tool_names: _.toolNames
30620
30621
  }), x = g.requireApproval, w = x == null ? void 0 : typeof x == "string" ? x : x.never != null ? { never: b(x.never) } : void 0;
@@ -30637,7 +30638,7 @@ async function ME({
30637
30638
  case "openai.custom": {
30638
30639
  const g = await $e({
30639
30640
  value: y.args,
30640
- schema: UC
30641
+ schema: zC
30641
30642
  });
30642
30643
  p.push({
30643
30644
  type: "custom",
@@ -30650,7 +30651,7 @@ async function ME({
30650
30651
  case "openai.tool_search": {
30651
30652
  const g = await $e({
30652
30653
  value: y.args,
30653
- schema: tE
30654
+ schema: nE
30654
30655
  });
30655
30656
  p.push({
30656
30657
  type: "tool_search",
@@ -30710,7 +30711,7 @@ async function ME({
30710
30711
  }
30711
30712
  }
30712
30713
  }
30713
- function RE({
30714
+ function AE({
30714
30715
  tool: e,
30715
30716
  options: t
30716
30717
  }) {
@@ -30724,7 +30725,7 @@ function RE({
30724
30725
  ...o != null ? { defer_loading: o } : {}
30725
30726
  };
30726
30727
  }
30727
- function OE(e) {
30728
+ function NE(e) {
30728
30729
  if (e.type === "containerReference")
30729
30730
  return {
30730
30731
  type: "container_reference",
@@ -30741,7 +30742,7 @@ function OE(e) {
30741
30742
  allowed_domains: o.networkPolicy.allowedDomains,
30742
30743
  domain_secrets: o.networkPolicy.domainSecrets
30743
30744
  },
30744
- skills: AE(o.skills)
30745
+ skills: $E(o.skills)
30745
30746
  };
30746
30747
  }
30747
30748
  return {
@@ -30749,7 +30750,7 @@ function OE(e) {
30749
30750
  skills: e.skills
30750
30751
  };
30751
30752
  }
30752
- function AE(e) {
30753
+ function $E(e) {
30753
30754
  return e?.map(
30754
30755
  (t) => {
30755
30756
  var o, n;
@@ -30785,7 +30786,7 @@ function zc(e) {
30785
30786
  }
30786
30787
  return n;
30787
30788
  }
30788
- var NE = class bh {
30789
+ var PE = class bh {
30789
30790
  constructor(t, o) {
30790
30791
  this.specificationVersion = "v4", this.supportedUrls = {
30791
30792
  "image/*": [/^https?:\/\/.*$/],
@@ -30858,13 +30859,13 @@ var NE = class bh {
30858
30859
  tools: V,
30859
30860
  toolChoice: L,
30860
30861
  toolWarnings: oe
30861
- } = await ME({
30862
+ } = await OE({
30862
30863
  tools: v,
30863
30864
  toolChoice: y,
30864
30865
  allowedTools: (w = D?.allowedTools) != null ? w : void 0,
30865
30866
  toolNameMapping: G,
30866
30867
  customProviderToolNames: $
30867
- }), { input: ne, warnings: pe } = await TE({
30868
+ }), { input: ne, warnings: pe } = await kE({
30868
30869
  prompt: p,
30869
30870
  toolNameMapping: G,
30870
30871
  systemMessageMode: (_ = D?.systemMessageMode) != null ? _ : J ? "developer" : Y.systemMessageMode,
@@ -31017,7 +31018,7 @@ var NE = class bh {
31017
31018
  body: F,
31018
31019
  failedResponseHandler: ao,
31019
31020
  successfulResponseHandler: Fe(
31020
- EE
31021
+ RE
31021
31022
  ),
31022
31023
  abortSignal: t.abortSignal,
31023
31024
  fetch: this.config.fetch
@@ -31470,14 +31471,14 @@ var NE = class bh {
31470
31471
  },
31471
31472
  failedResponseHandler: ao,
31472
31473
  successfulResponseHandler: fn(
31473
- CE
31474
+ ME
31474
31475
  ),
31475
31476
  abortSignal: t.abortSignal,
31476
31477
  fetch: this.config.fetch
31477
31478
  }), g = await Ls({
31478
31479
  stream: y,
31479
31480
  getError: (re) => Vc(re) || Fc(re) && re.response.error != null ? re : void 0,
31480
- isOutputChunk: JE,
31481
+ isOutputChunk: YE,
31481
31482
  url: m,
31482
31483
  requestBodyValues: a,
31483
31484
  responseHeaders: v
@@ -31503,7 +31504,7 @@ var NE = class bh {
31503
31504
  transform(re, F) {
31504
31505
  var J, G, $, V, L, oe, ne, pe, ye, se, B, Z, te, j, ue, q, I, N, U, ie, Pe, ct, Ze, Ue, Oe, _t, Jt, to, Kt, Mt, be, Vt, ko, Pt, Xo, ro, Rt, So;
31505
31506
  if (t.includeRawChunks && F.enqueue({ type: "raw", rawValue: re.rawValue }), !re.success) {
31506
- const X = PE(re.rawValue) ? DE({
31507
+ const X = qE(re.rawValue) ? jE({
31507
31508
  value: re.rawValue,
31508
31509
  cause: re.error,
31509
31510
  url: m,
@@ -31678,7 +31679,7 @@ var NE = class bh {
31678
31679
  }
31679
31680
  })));
31680
31681
  }
31681
- } else if (jE(M))
31682
+ } else if (LE(M))
31682
31683
  if (M.item.type === "message") {
31683
31684
  const X = (V = M.item.phase) != null ? V : R;
31684
31685
  R = void 0, F.enqueue({
@@ -32005,28 +32006,28 @@ var NE = class bh {
32005
32006
  }
32006
32007
  }
32007
32008
  });
32008
- else if (zE(M)) {
32009
+ else if (ZE(M)) {
32009
32010
  const X = E[M.output_index];
32010
32011
  X != null && F.enqueue({
32011
32012
  type: "tool-input-delta",
32012
32013
  id: X.toolCallId,
32013
32014
  delta: M.delta
32014
32015
  });
32015
- } else if (FE(M)) {
32016
+ } else if (VE(M)) {
32016
32017
  const X = E[M.output_index];
32017
32018
  X != null && F.enqueue({
32018
32019
  type: "tool-input-delta",
32019
32020
  id: X.toolCallId,
32020
32021
  delta: M.delta
32021
32022
  });
32022
- } else if (BE(M)) {
32023
+ } else if (WE(M)) {
32023
32024
  const X = E[M.output_index];
32024
32025
  X?.applyPatch && (F.enqueue({
32025
32026
  type: "tool-input-delta",
32026
32027
  id: X.toolCallId,
32027
32028
  delta: wn(M.delta)
32028
32029
  }), X.applyPatch.hasDiff = !0);
32029
- } else if (HE(M)) {
32030
+ } else if (JE(M)) {
32030
32031
  const X = E[M.output_index];
32031
32032
  X?.applyPatch && !X.applyPatch.endEmitted && (X.applyPatch.hasDiff || (F.enqueue({
32032
32033
  type: "tool-input-delta",
@@ -32040,7 +32041,7 @@ var NE = class bh {
32040
32041
  type: "tool-input-end",
32041
32042
  id: X.toolCallId
32042
32043
  }), X.applyPatch.endEmitted = !0);
32043
- } else if (ZE(M))
32044
+ } else if (GE(M))
32044
32045
  F.enqueue({
32045
32046
  type: "tool-result",
32046
32047
  toolCallId: M.item_id,
@@ -32050,14 +32051,14 @@ var NE = class bh {
32050
32051
  },
32051
32052
  preliminary: !0
32052
32053
  });
32053
- else if (VE(M)) {
32054
+ else if (BE(M)) {
32054
32055
  const X = E[M.output_index];
32055
32056
  X != null && F.enqueue({
32056
32057
  type: "tool-input-delta",
32057
32058
  id: X.toolCallId,
32058
32059
  delta: wn(M.delta)
32059
32060
  });
32060
- } else if (GE(M)) {
32061
+ } else if (HE(M)) {
32061
32062
  const X = E[M.output_index];
32062
32063
  X != null && (F.enqueue({
32063
32064
  type: "tool-input-delta",
@@ -32076,14 +32077,14 @@ var NE = class bh {
32076
32077
  }),
32077
32078
  providerExecuted: !0
32078
32079
  }));
32079
- } else if (LE(M))
32080
+ } else if (FE(M))
32080
32081
  S = M.response.id, F.enqueue({
32081
32082
  type: "response-metadata",
32082
32083
  id: M.response.id,
32083
32084
  timestamp: new Date(M.response.created_at * 1e3),
32084
32085
  modelId: M.response.model
32085
32086
  });
32086
- else if ($E(M))
32087
+ else if (DE(M))
32087
32088
  F.enqueue({
32088
32089
  type: "text-delta",
32089
32090
  id: M.item_id,
@@ -32137,7 +32138,7 @@ var NE = class bh {
32137
32138
  }
32138
32139
  }
32139
32140
  }), P[M.item_id].summaryParts[M.summary_index] = "concluded") : P[M.item_id].summaryParts[M.summary_index] = "can-conclude";
32140
- else if (UE(M))
32141
+ else if (zE(M))
32141
32142
  _ = {
32142
32143
  unified: bi({
32143
32144
  finishReason: (ct = M.response.incomplete_details) == null ? void 0 : ct.reason,
@@ -32165,7 +32166,7 @@ var NE = class bh {
32165
32166
  }
32166
32167
  }
32167
32168
  }));
32168
- } else WE(M) ? (O.push(M.annotation), M.annotation.type === "url_citation" ? F.enqueue({
32169
+ } else KE(M) ? (O.push(M.annotation), M.annotation.type === "url_citation" ? F.enqueue({
32169
32170
  type: "source",
32170
32171
  sourceType: "url",
32171
32172
  id: (Kt = (to = (Jt = b.config).generateId) == null ? void 0 : to.call(Jt)) != null ? Kt : nt(),
@@ -32237,14 +32238,14 @@ var NE = class bh {
32237
32238
  };
32238
32239
  }
32239
32240
  };
32240
- function $E(e) {
32241
+ function DE(e) {
32241
32242
  return e.type === "response.output_text.delta";
32242
32243
  }
32243
- function PE(e) {
32244
- const t = qE(e);
32244
+ function qE(e) {
32245
+ const t = UE(e);
32245
32246
  return t != null && Array.isArray(t.choices) && typeof t.type != "string";
32246
32247
  }
32247
- function DE({
32248
+ function jE({
32248
32249
  value: e,
32249
32250
  cause: t,
32250
32251
  url: o,
@@ -32262,52 +32263,52 @@ function DE({
32262
32263
  isRetryable: !1
32263
32264
  });
32264
32265
  }
32265
- function qE(e) {
32266
+ function UE(e) {
32266
32267
  return typeof e == "object" && e != null ? e : void 0;
32267
32268
  }
32268
- function jE(e) {
32269
+ function LE(e) {
32269
32270
  return e.type === "response.output_item.done";
32270
32271
  }
32271
- function UE(e) {
32272
+ function zE(e) {
32272
32273
  return e.type === "response.completed" || e.type === "response.incomplete";
32273
32274
  }
32274
32275
  function Fc(e) {
32275
32276
  return e.type === "response.failed";
32276
32277
  }
32277
- function LE(e) {
32278
+ function FE(e) {
32278
32279
  return e.type === "response.created";
32279
32280
  }
32280
- function zE(e) {
32281
+ function ZE(e) {
32281
32282
  return e.type === "response.function_call_arguments.delta";
32282
32283
  }
32283
- function FE(e) {
32284
+ function VE(e) {
32284
32285
  return e.type === "response.custom_tool_call_input.delta";
32285
32286
  }
32286
- function ZE(e) {
32287
+ function GE(e) {
32287
32288
  return e.type === "response.image_generation_call.partial_image";
32288
32289
  }
32289
- function VE(e) {
32290
+ function BE(e) {
32290
32291
  return e.type === "response.code_interpreter_call_code.delta";
32291
32292
  }
32292
- function GE(e) {
32293
+ function HE(e) {
32293
32294
  return e.type === "response.code_interpreter_call_code.done";
32294
32295
  }
32295
- function BE(e) {
32296
+ function WE(e) {
32296
32297
  return e.type === "response.apply_patch_call_operation_diff.delta";
32297
32298
  }
32298
- function HE(e) {
32299
+ function JE(e) {
32299
32300
  return e.type === "response.apply_patch_call_operation_diff.done";
32300
32301
  }
32301
32302
  function Zc(e) {
32302
32303
  return e.type === "response.output_item.added";
32303
32304
  }
32304
- function WE(e) {
32305
+ function KE(e) {
32305
32306
  return e.type === "response.output_text.annotation.added";
32306
32307
  }
32307
32308
  function Vc(e) {
32308
32309
  return e.type === "error";
32309
32310
  }
32310
- function JE(e) {
32311
+ function YE(e) {
32311
32312
  return !(e.type === "response.created" || e.type === "response.failed" || e.type === "error" || e.type === "unknown_chunk");
32312
32313
  }
32313
32314
  function Gc(e) {
@@ -32340,14 +32341,14 @@ function Gc(e) {
32340
32341
  function wn(e) {
32341
32342
  return JSON.stringify(e).slice(1, -1);
32342
32343
  }
32343
- var KE = K(
32344
+ var XE = K(
32344
32345
  () => W(
32345
32346
  u({
32346
32347
  instructions: i().nullish(),
32347
32348
  speed: T().min(0.25).max(4).default(1).nullish()
32348
32349
  })
32349
32350
  )
32350
- ), YE = class wh {
32351
+ ), QE = class wh {
32351
32352
  constructor(t, o) {
32352
32353
  this.modelId = t, this.config = o, this.specificationVersion = "v4";
32353
32354
  }
@@ -32375,7 +32376,7 @@ var KE = K(
32375
32376
  const c = [], p = await tt({
32376
32377
  provider: "openai",
32377
32378
  providerOptions: l,
32378
- schema: KE
32379
+ schema: XE
32379
32380
  }), d = {
32380
32381
  model: this.modelId,
32381
32382
  input: t,
@@ -32436,7 +32437,7 @@ var KE = K(
32436
32437
  }
32437
32438
  };
32438
32439
  }
32439
- }, XE = K(
32440
+ }, eM = K(
32440
32441
  () => W(
32441
32442
  u({
32442
32443
  text: i(),
@@ -32465,7 +32466,7 @@ var KE = K(
32465
32466
  ).nullish()
32466
32467
  })
32467
32468
  )
32468
- ), QE = K(
32469
+ ), tM = K(
32469
32470
  () => W(
32470
32471
  u({
32471
32472
  /**
@@ -32550,7 +32551,7 @@ var KE = K(
32550
32551
  urdu: "ur",
32551
32552
  vietnamese: "vi",
32552
32553
  welsh: "cy"
32553
- }, eM = class xh {
32554
+ }, oM = class xh {
32554
32555
  constructor(t, o) {
32555
32556
  this.modelId = t, this.config = o, this.specificationVersion = "v4";
32556
32557
  }
@@ -32574,7 +32575,7 @@ var KE = K(
32574
32575
  const a = [], r = await tt({
32575
32576
  provider: "openai",
32576
32577
  providerOptions: n,
32577
- schema: QE
32578
+ schema: tM
32578
32579
  }), s = new FormData(), l = t instanceof Uint8Array ? new Blob([t]) : new Blob([No(t)]);
32579
32580
  s.append("model", this.modelId);
32580
32581
  const c = n0(o);
@@ -32626,7 +32627,7 @@ var KE = K(
32626
32627
  formData: y,
32627
32628
  failedResponseHandler: ao,
32628
32629
  successfulResponseHandler: Fe(
32629
- XE
32630
+ eM
32630
32631
  ),
32631
32632
  abortSignal: t.abortSignal,
32632
32633
  fetch: this.config.fetch
@@ -32653,7 +32654,7 @@ var KE = K(
32653
32654
  }
32654
32655
  };
32655
32656
  }
32656
- }, tM = K(
32657
+ }, nM = K(
32657
32658
  () => W(
32658
32659
  u({
32659
32660
  id: i(),
@@ -32665,7 +32666,7 @@ var KE = K(
32665
32666
  updated_at: T().nullish()
32666
32667
  })
32667
32668
  )
32668
- ), oM = class {
32669
+ ), aM = class {
32669
32670
  constructor(e) {
32670
32671
  this.config = e, this.specificationVersion = "v4";
32671
32672
  }
@@ -32689,7 +32690,7 @@ var KE = K(
32689
32690
  formData: o,
32690
32691
  failedResponseHandler: ao,
32691
32692
  successfulResponseHandler: Fe(
32692
- tM
32693
+ nM
32693
32694
  ),
32694
32695
  fetch: this.config.fetch
32695
32696
  });
@@ -32708,7 +32709,7 @@ var KE = K(
32708
32709
  warnings: t
32709
32710
  };
32710
32711
  }
32711
- }, nM = "4.0.4";
32712
+ }, rM = "4.0.4";
32712
32713
  function Th(e = {}) {
32713
32714
  var t, o;
32714
32715
  const n = (t = Lr(
@@ -32727,43 +32728,43 @@ function Th(e = {}) {
32727
32728
  "OpenAI-Project": e.project,
32728
32729
  ...e.headers
32729
32730
  },
32730
- `ai-sdk/openai/${nM}`
32731
- ), s = (k) => new pC(k, {
32731
+ `ai-sdk/openai/${rM}`
32732
+ ), s = (k) => new fC(k, {
32732
32733
  provider: `${a}.chat`,
32733
32734
  url: ({ path: h }) => `${n}${h}`,
32734
32735
  headers: r,
32735
32736
  fetch: e.fetch
32736
- }), l = (k) => new vC(k, {
32737
+ }), l = (k) => new _C(k, {
32737
32738
  provider: `${a}.completion`,
32738
32739
  url: ({ path: h }) => `${n}${h}`,
32739
32740
  headers: r,
32740
32741
  fetch: e.fetch
32741
- }), c = (k) => new wC(k, {
32742
+ }), c = (k) => new TC(k, {
32742
32743
  provider: `${a}.embedding`,
32743
32744
  url: ({ path: h }) => `${n}${h}`,
32744
32745
  headers: r,
32745
32746
  fetch: e.fetch
32746
- }), p = (k) => new RC(k, {
32747
+ }), p = (k) => new AC(k, {
32747
32748
  provider: `${a}.image`,
32748
32749
  url: ({ path: h }) => `${n}${h}`,
32749
32750
  headers: r,
32750
32751
  fetch: e.fetch
32751
- }), d = (k) => new eM(k, {
32752
+ }), d = (k) => new oM(k, {
32752
32753
  provider: `${a}.transcription`,
32753
32754
  url: ({ path: h }) => `${n}${h}`,
32754
32755
  headers: r,
32755
32756
  fetch: e.fetch
32756
- }), m = (k) => new YE(k, {
32757
+ }), m = (k) => new QE(k, {
32757
32758
  provider: `${a}.speech`,
32758
32759
  url: ({ path: h }) => `${n}${h}`,
32759
32760
  headers: r,
32760
32761
  fetch: e.fetch
32761
- }), v = () => new IC({
32762
+ }), v = () => new SC({
32762
32763
  provider: `${a}.files`,
32763
32764
  baseURL: n,
32764
32765
  headers: r,
32765
32766
  fetch: e.fetch
32766
- }), y = () => new oM({
32767
+ }), y = () => new aM({
32767
32768
  provider: `${a}.skills`,
32768
32769
  url: ({ path: k }) => `${n}${k}`,
32769
32770
  headers: r,
@@ -32774,14 +32775,14 @@ function Th(e = {}) {
32774
32775
  "The OpenAI model function cannot be called with the new keyword."
32775
32776
  );
32776
32777
  return b(k);
32777
- }, b = (k) => new NE(k, {
32778
+ }, b = (k) => new PE(k, {
32778
32779
  provider: `${a}.responses`,
32779
32780
  url: ({ path: h }) => `${n}${h}`,
32780
32781
  headers: r,
32781
32782
  fetch: e.fetch,
32782
32783
  // Soft-deprecated. TODO: remove in v8
32783
32784
  fileIdPrefixes: ["file-"]
32784
- }), x = (k) => new wE(k, {
32785
+ }), x = (k) => new TE(k, {
32785
32786
  provider: `${a}.realtime`,
32786
32787
  baseURL: n,
32787
32788
  headers: r,
@@ -32804,13 +32805,13 @@ function Th(e = {}) {
32804
32805
  ), _ = function(k) {
32805
32806
  return g(k);
32806
32807
  };
32807
- return _.specificationVersion = "v4", _.languageModel = g, _.chat = s, _.completion = l, _.responses = b, _.embedding = c, _.embeddingModel = c, _.textEmbedding = c, _.textEmbeddingModel = c, _.image = p, _.imageModel = p, _.transcription = d, _.transcriptionModel = d, _.speech = m, _.speechModel = m, _.files = v, _.skills = y, _.experimental_realtime = w, _.tools = yE, _;
32808
+ return _.specificationVersion = "v4", _.languageModel = g, _.chat = s, _.completion = l, _.responses = b, _.embedding = c, _.embeddingModel = c, _.textEmbedding = c, _.textEmbeddingModel = c, _.image = p, _.imageModel = p, _.transcription = d, _.transcriptionModel = d, _.speech = m, _.speechModel = m, _.files = v, _.skills = y, _.experimental_realtime = w, _.tools = bE, _;
32808
32809
  }
32809
- var tO = Th();
32810
- function aM(e, t) {
32810
+ var nO = Th();
32811
+ function iM(e, t) {
32811
32812
  return Th(t)(e);
32812
32813
  }
32813
- var rM = K(
32814
+ var sM = K(
32814
32815
  () => W(
32815
32816
  u({
32816
32817
  type: f("error"),
@@ -32821,9 +32822,9 @@ var rM = K(
32821
32822
  })
32822
32823
  )
32823
32824
  ), $a = Lt({
32824
- errorSchema: rM,
32825
+ errorSchema: sM,
32825
32826
  errorToMessage: (e) => e.error.message
32826
- }), iM = K(
32827
+ }), lM = K(
32827
32828
  () => W(
32828
32829
  u({
32829
32830
  id: i(),
@@ -32835,7 +32836,7 @@ var rM = K(
32835
32836
  downloadable: ae().nullish()
32836
32837
  })
32837
32838
  )
32838
- ), sM = class {
32839
+ ), uM = class {
32839
32840
  constructor(e) {
32840
32841
  this.config = e, this.specificationVersion = "v4";
32841
32842
  }
@@ -32858,7 +32859,7 @@ var rM = K(
32858
32859
  formData: l,
32859
32860
  failedResponseHandler: $a,
32860
32861
  successfulResponseHandler: Fe(
32861
- iM
32862
+ lM
32862
32863
  ),
32863
32864
  fetch: this.config.fetch
32864
32865
  });
@@ -32883,7 +32884,7 @@ var rM = K(
32883
32884
  category: i().nullish(),
32884
32885
  explanation: i().nullish(),
32885
32886
  recommended_model: i().nullish()
32886
- }), lM = K(
32887
+ }), cM = K(
32887
32888
  () => W(
32888
32889
  u({
32889
32890
  type: f("message"),
@@ -33233,7 +33234,7 @@ var rM = K(
33233
33234
  }).nullish()
33234
33235
  })
33235
33236
  )
33236
- ), uM = K(
33237
+ ), dM = K(
33237
33238
  () => W(
33238
33239
  Te("type", [
33239
33240
  u({
@@ -33675,7 +33676,7 @@ var rM = K(
33675
33676
  })
33676
33677
  ])
33677
33678
  )
33678
- ), cM = K(
33679
+ ), pM = K(
33679
33680
  () => W(
33680
33681
  u({
33681
33682
  signature: i().optional(),
@@ -33933,7 +33934,7 @@ var rM = K(
33933
33934
  )
33934
33935
  }).optional()
33935
33936
  }), Wc = 4;
33936
- function dM(e) {
33937
+ function mM(e) {
33937
33938
  var t;
33938
33939
  const o = e?.anthropic;
33939
33940
  return (t = o?.cacheControl) != null ? t : o?.cache_control;
@@ -33943,7 +33944,7 @@ var zs = class {
33943
33944
  this.breakpointCount = 0, this.warnings = [];
33944
33945
  }
33945
33946
  getCacheControl(e, t) {
33946
- const o = dM(e);
33947
+ const o = mM(e);
33947
33948
  if (o) {
33948
33949
  if (!t.canCache) {
33949
33950
  this.warnings.push({
@@ -33967,7 +33968,7 @@ var zs = class {
33967
33968
  getWarnings() {
33968
33969
  return this.warnings;
33969
33970
  }
33970
- }, pM = K(
33971
+ }, fM = K(
33971
33972
  () => W(
33972
33973
  u({
33973
33974
  model: i(),
@@ -33995,20 +33996,20 @@ var zs = class {
33995
33996
  })
33996
33997
  ])
33997
33998
  )
33998
- ), mM = K(
33999
+ ), hM = K(
33999
34000
  () => W(u({}).strict())
34000
- ), fM = it({
34001
+ ), gM = it({
34001
34002
  id: "anthropic.advisor_20260301",
34002
- inputSchema: mM,
34003
+ inputSchema: hM,
34003
34004
  outputSchema: kh,
34004
34005
  supportsDeferredResults: !0
34005
- }), hM = (e) => fM(e), gM = K(
34006
+ }), vM = (e) => gM(e), yM = K(
34006
34007
  () => W(
34007
34008
  u({
34008
34009
  maxCharacters: T().optional()
34009
34010
  })
34010
34011
  )
34011
- ), vM = K(
34012
+ ), _M = K(
34012
34013
  () => W(
34013
34014
  u({
34014
34015
  command: ee(["view", "create", "str_replace", "insert"]),
@@ -34021,10 +34022,10 @@ var zs = class {
34021
34022
  view_range: A(T().int()).optional()
34022
34023
  })
34023
34024
  )
34024
- ), yM = Io({
34025
+ ), bM = Io({
34025
34026
  id: "anthropic.text_editor_20250728",
34026
- inputSchema: vM
34027
- }), _M = (e = {}) => yM(e), bM = K(
34027
+ inputSchema: _M
34028
+ }), wM = (e = {}) => bM(e), xM = K(
34028
34029
  () => W(
34029
34030
  u({
34030
34031
  maxUses: T().optional(),
@@ -34039,7 +34040,7 @@ var zs = class {
34039
34040
  }).optional()
34040
34041
  })
34041
34042
  )
34042
- ), wM = K(
34043
+ ), TM = K(
34043
34044
  () => W(
34044
34045
  A(
34045
34046
  u({
@@ -34051,18 +34052,18 @@ var zs = class {
34051
34052
  })
34052
34053
  )
34053
34054
  )
34054
- ), xM = K(
34055
+ ), IM = K(
34055
34056
  () => W(
34056
34057
  u({
34057
34058
  query: i()
34058
34059
  })
34059
34060
  )
34060
- ), TM = it({
34061
+ ), kM = it({
34061
34062
  id: "anthropic.web_search_20260209",
34062
- inputSchema: xM,
34063
- outputSchema: wM,
34063
+ inputSchema: IM,
34064
+ outputSchema: TM,
34064
34065
  supportsDeferredResults: !0
34065
- }), IM = (e = {}) => TM(e), kM = K(
34066
+ }), SM = (e = {}) => kM(e), CM = K(
34066
34067
  () => W(
34067
34068
  u({
34068
34069
  maxUses: T().optional(),
@@ -34089,18 +34090,18 @@ var zs = class {
34089
34090
  })
34090
34091
  )
34091
34092
  )
34092
- ), SM = K(
34093
+ ), EM = K(
34093
34094
  () => W(
34094
34095
  u({
34095
34096
  query: i()
34096
34097
  })
34097
34098
  )
34098
- ), CM = it({
34099
+ ), MM = it({
34099
34100
  id: "anthropic.web_search_20250305",
34100
- inputSchema: SM,
34101
+ inputSchema: EM,
34101
34102
  outputSchema: Sh,
34102
34103
  supportsDeferredResults: !0
34103
- }), EM = (e = {}) => CM(e), MM = K(
34104
+ }), RM = (e = {}) => MM(e), OM = K(
34104
34105
  () => W(
34105
34106
  u({
34106
34107
  maxUses: T().optional(),
@@ -34110,7 +34111,7 @@ var zs = class {
34110
34111
  maxContentTokens: T().optional()
34111
34112
  })
34112
34113
  )
34113
- ), RM = K(
34114
+ ), AM = K(
34114
34115
  () => W(
34115
34116
  u({
34116
34117
  type: f("web_fetch_result"),
@@ -34135,18 +34136,18 @@ var zs = class {
34135
34136
  retrievedAt: i().nullable()
34136
34137
  })
34137
34138
  )
34138
- ), OM = K(
34139
+ ), NM = K(
34139
34140
  () => W(
34140
34141
  u({
34141
34142
  url: i()
34142
34143
  })
34143
34144
  )
34144
- ), AM = it({
34145
+ ), $M = it({
34145
34146
  id: "anthropic.web_fetch_20260209",
34146
- inputSchema: OM,
34147
- outputSchema: RM,
34147
+ inputSchema: NM,
34148
+ outputSchema: AM,
34148
34149
  supportsDeferredResults: !0
34149
- }), NM = (e = {}) => AM(e), $M = K(
34150
+ }), PM = (e = {}) => $M(e), DM = K(
34150
34151
  () => W(
34151
34152
  u({
34152
34153
  maxUses: T().optional(),
@@ -34181,19 +34182,19 @@ var zs = class {
34181
34182
  retrievedAt: i().nullable()
34182
34183
  })
34183
34184
  )
34184
- ), PM = K(
34185
+ ), qM = K(
34185
34186
  () => W(
34186
34187
  u({
34187
34188
  url: i()
34188
34189
  })
34189
34190
  )
34190
- ), DM = it({
34191
+ ), jM = it({
34191
34192
  id: "anthropic.web_fetch_20250910",
34192
- inputSchema: PM,
34193
+ inputSchema: qM,
34193
34194
  outputSchema: Ch,
34194
34195
  supportsDeferredResults: !0
34195
- }), qM = (e = {}) => DM(e);
34196
- async function jM({
34196
+ }), UM = (e = {}) => jM(e);
34197
+ async function LM({
34197
34198
  tools: e,
34198
34199
  toolChoice: t,
34199
34200
  disableParallelToolUse: o,
@@ -34321,7 +34322,7 @@ async function jM({
34321
34322
  case "anthropic.text_editor_20250728": {
34322
34323
  const b = await $e({
34323
34324
  value: g.args,
34324
- schema: gM
34325
+ schema: yM
34325
34326
  });
34326
34327
  v.push({
34327
34328
  name: "str_replace_based_edit_tool",
@@ -34358,7 +34359,7 @@ async function jM({
34358
34359
  d.add("web-fetch-2025-09-10");
34359
34360
  const b = await $e({
34360
34361
  value: g.args,
34361
- schema: $M
34362
+ schema: DM
34362
34363
  });
34363
34364
  v.push({
34364
34365
  type: "web_fetch_20250910",
@@ -34376,7 +34377,7 @@ async function jM({
34376
34377
  d.add("code-execution-web-tools-2026-02-09");
34377
34378
  const b = await $e({
34378
34379
  value: g.args,
34379
- schema: MM
34380
+ schema: OM
34380
34381
  });
34381
34382
  v.push({
34382
34383
  type: "web_fetch_20260209",
@@ -34393,7 +34394,7 @@ async function jM({
34393
34394
  case "anthropic.web_search_20250305": {
34394
34395
  const b = await $e({
34395
34396
  value: g.args,
34396
- schema: kM
34397
+ schema: CM
34397
34398
  });
34398
34399
  v.push({
34399
34400
  type: "web_search_20250305",
@@ -34410,7 +34411,7 @@ async function jM({
34410
34411
  d.add("code-execution-web-tools-2026-02-09");
34411
34412
  const b = await $e({
34412
34413
  value: g.args,
34413
- schema: bM
34414
+ schema: xM
34414
34415
  });
34415
34416
  v.push({
34416
34417
  type: "web_search_20260209",
@@ -34441,7 +34442,7 @@ async function jM({
34441
34442
  d.add("advisor-tool-2026-03-01");
34442
34443
  const b = await $e({
34443
34444
  value: g.args,
34444
- schema: pM
34445
+ schema: fM
34445
34446
  });
34446
34447
  v.push({
34447
34448
  type: "advisor_20260301",
@@ -34577,17 +34578,17 @@ var Eh = K(
34577
34578
  ).optional().default([])
34578
34579
  })
34579
34580
  )
34580
- ), UM = K(
34581
+ ), zM = K(
34581
34582
  () => W(
34582
34583
  u({
34583
34584
  code: i()
34584
34585
  })
34585
34586
  )
34586
- ), LM = it({
34587
+ ), FM = it({
34587
34588
  id: "anthropic.code_execution_20250522",
34588
- inputSchema: UM,
34589
+ inputSchema: zM,
34589
34590
  outputSchema: Eh
34590
- }), zM = (e = {}) => LM(e), Mh = K(
34591
+ }), ZM = (e = {}) => FM(e), Mh = K(
34591
34592
  () => W(
34592
34593
  Te("type", [
34593
34594
  u({
@@ -34644,7 +34645,7 @@ var Eh = K(
34644
34645
  })
34645
34646
  ])
34646
34647
  )
34647
- ), FM = K(
34648
+ ), VM = K(
34648
34649
  () => W(
34649
34650
  Te("type", [
34650
34651
  // Programmatic tool calling format (mapped from { code } by AI SDK)
@@ -34678,15 +34679,15 @@ var Eh = K(
34678
34679
  ])
34679
34680
  ])
34680
34681
  )
34681
- ), ZM = it({
34682
+ ), GM = it({
34682
34683
  id: "anthropic.code_execution_20250825",
34683
- inputSchema: FM,
34684
+ inputSchema: VM,
34684
34685
  outputSchema: Mh,
34685
34686
  // Programmatic tool calling: tool results may be deferred to a later turn
34686
34687
  // when code execution triggers a client-executed tool that needs to be
34687
34688
  // resolved before the code execution result can be returned.
34688
34689
  supportsDeferredResults: !0
34689
- }), VM = (e = {}) => ZM(e), Rh = K(
34690
+ }), BM = (e = {}) => GM(e), Rh = K(
34690
34691
  () => W(
34691
34692
  Te("type", [
34692
34693
  u({
@@ -34755,7 +34756,7 @@ var Eh = K(
34755
34756
  })
34756
34757
  ])
34757
34758
  )
34758
- ), GM = K(
34759
+ ), HM = K(
34759
34760
  () => W(
34760
34761
  Te("type", [
34761
34762
  u({
@@ -34788,12 +34789,12 @@ var Eh = K(
34788
34789
  ])
34789
34790
  ])
34790
34791
  )
34791
- ), BM = it({
34792
+ ), WM = it({
34792
34793
  id: "anthropic.code_execution_20260120",
34793
- inputSchema: GM,
34794
+ inputSchema: HM,
34794
34795
  outputSchema: Rh,
34795
34796
  supportsDeferredResults: !0
34796
- }), HM = (e = {}) => BM(e), Oh = K(
34797
+ }), JM = (e = {}) => WM(e), Oh = K(
34797
34798
  () => W(
34798
34799
  A(
34799
34800
  u({
@@ -34802,7 +34803,7 @@ var Eh = K(
34802
34803
  })
34803
34804
  )
34804
34805
  )
34805
- ), WM = K(
34806
+ ), KM = K(
34806
34807
  () => W(
34807
34808
  u({
34808
34809
  /**
@@ -34822,13 +34823,13 @@ var Eh = K(
34822
34823
  limit: T().optional()
34823
34824
  })
34824
34825
  )
34825
- ), JM = it({
34826
+ ), YM = it({
34826
34827
  id: "anthropic.tool_search_regex_20251119",
34827
- inputSchema: WM,
34828
+ inputSchema: KM,
34828
34829
  outputSchema: Oh,
34829
34830
  supportsDeferredResults: !0
34830
- }), KM = (e = {}) => JM(e);
34831
- function YM(e) {
34831
+ }), XM = (e = {}) => YM(e);
34832
+ function QM(e) {
34832
34833
  return typeof e == "string" ? new TextDecoder().decode(No(e)) : new TextDecoder().decode(e);
34833
34834
  }
34834
34835
  function Kc(e) {
@@ -34845,7 +34846,7 @@ function Kc(e) {
34845
34846
  }
34846
34847
  return {};
34847
34848
  }
34848
- async function XM({
34849
+ async function eR({
34849
34850
  prompt: e,
34850
34851
  sendReasoning: t,
34851
34852
  warnings: o,
@@ -34853,7 +34854,7 @@ async function XM({
34853
34854
  toolNameMapping: a
34854
34855
  }) {
34855
34856
  var r, s, l, c, p, d, m, v, y, g, b, x, w, _, k, h, S, E, O, R, C, P;
34856
- const H = /* @__PURE__ */ new Set(), Y = QM(e), z = n || new zs();
34857
+ const H = /* @__PURE__ */ new Set(), Y = tR(e), z = n || new zs();
34857
34858
  let D;
34858
34859
  const re = [];
34859
34860
  async function F($) {
@@ -35024,7 +35025,7 @@ async function XM({
35024
35025
  } : {
35025
35026
  type: "text",
35026
35027
  media_type: "text/plain",
35027
- data: YM(
35028
+ data: QM(
35028
35029
  Z.data.data
35029
35030
  )
35030
35031
  },
@@ -35222,7 +35223,7 @@ async function XM({
35222
35223
  const I = await tt({
35223
35224
  provider: "anthropic",
35224
35225
  providerOptions: j.providerOptions,
35225
- schema: cM
35226
+ schema: pM
35226
35227
  });
35227
35228
  I != null ? I.signature != null ? (z.getCacheControl(j.providerOptions, {
35228
35229
  type: "thinking block",
@@ -35628,7 +35629,7 @@ async function XM({
35628
35629
  }
35629
35630
  re.push({
35630
35631
  role: "assistant",
35631
- content: eR(ne)
35632
+ content: oR(ne)
35632
35633
  });
35633
35634
  break;
35634
35635
  }
@@ -35643,7 +35644,7 @@ async function XM({
35643
35644
  betas: H
35644
35645
  };
35645
35646
  }
35646
- function QM(e) {
35647
+ function tR(e) {
35647
35648
  const t = [];
35648
35649
  let o;
35649
35650
  for (const n of e) {
@@ -35673,7 +35674,7 @@ function QM(e) {
35673
35674
  }
35674
35675
  return t;
35675
35676
  }
35676
- function eR(e) {
35677
+ function oR(e) {
35677
35678
  const t = [];
35678
35679
  let o = [];
35679
35680
  function n() {
@@ -35719,7 +35720,7 @@ var Ah = /* @__PURE__ */ new Set([
35719
35720
  "ipv4",
35720
35721
  "ipv6",
35721
35722
  "uuid"
35722
- ]), tR = [
35723
+ ]), nR = [
35723
35724
  "minimum",
35724
35725
  "maximum",
35725
35726
  "exclusiveMinimum",
@@ -35735,11 +35736,11 @@ var Ah = /* @__PURE__ */ new Set([
35735
35736
  "maxProperties",
35736
35737
  "not"
35737
35738
  ];
35738
- function oR(e) {
35739
+ function aR(e) {
35739
35740
  return Nh(e);
35740
35741
  }
35741
35742
  function an(e) {
35742
- return typeof e == "boolean" || !iR(e) ? e : Nh(e);
35743
+ return typeof e == "boolean" || !lR(e) ? e : Nh(e);
35743
35744
  }
35744
35745
  function Nh(e) {
35745
35746
  const t = {}, o = e;
@@ -35765,24 +35766,24 @@ function Nh(e) {
35765
35766
  an(r)
35766
35767
  ])
35767
35768
  )), t.additionalProperties = !1, e.required != null && (t.required = e.required)), e.items != null && (t.items = Array.isArray(e.items) ? e.items.map(an) : an(e.items)), typeof e.format == "string" && Ah.has(e.format) && (t.format = e.format);
35768
- const n = nR(e);
35769
+ const n = rR(e);
35769
35770
  return n != null && (t.description = t.description == null ? n : `${t.description}
35770
35771
  ${n}`), t;
35771
35772
  }
35772
- function nR(e) {
35773
- const t = tR.flatMap((o) => {
35773
+ function rR(e) {
35774
+ const t = nR.flatMap((o) => {
35774
35775
  const n = e[o];
35775
- return n == null || n === !1 ? [] : `${aR(o)}: ${rR(n)}`;
35776
+ return n == null || n === !1 ? [] : `${iR(o)}: ${sR(n)}`;
35776
35777
  });
35777
35778
  return typeof e.format == "string" && !Ah.has(e.format) && t.push(`format: ${e.format}`), t.length === 0 ? void 0 : `${t.join("; ")}.`;
35778
35779
  }
35779
- function aR(e) {
35780
+ function iR(e) {
35780
35781
  return e.replace(/[A-Z]/g, (t) => ` ${t.toLowerCase()}`);
35781
35782
  }
35782
- function rR(e) {
35783
+ function sR(e) {
35783
35784
  return typeof e == "string" ? e : JSON.stringify(e);
35784
35785
  }
35785
- function iR(e) {
35786
+ function lR(e) {
35786
35787
  return typeof e == "object" && e !== null && !Array.isArray(e);
35787
35788
  }
35788
35789
  function Yc(e, t, o) {
@@ -35825,7 +35826,7 @@ function Yc(e, t, o) {
35825
35826
  }
35826
35827
  };
35827
35828
  }
35828
- var sR = class $h {
35829
+ var uR = class $h {
35829
35830
  constructor(t, o) {
35830
35831
  this.specificationVersion = "v4";
35831
35832
  var n;
@@ -35910,7 +35911,7 @@ var sR = class $h {
35910
35911
  rejectsSamplingParameters: L,
35911
35912
  supportsXhighEffort: oe,
35912
35913
  isKnownModel: ne
35913
- } = lR(this.modelId);
35914
+ } = cR(this.modelId);
35914
35915
  L && (a != null && (Y.push({
35915
35916
  type: "unsupported",
35916
35917
  feature: "temperature",
@@ -35952,7 +35953,7 @@ var sR = class $h {
35952
35953
  "anthropic.tool_search_bm25_20251119": "tool_search_tool_bm25",
35953
35954
  "anthropic.advisor_20260301": "advisor"
35954
35955
  }
35955
- }), { prompt: I, betas: N } = await XM({
35956
+ }), { prompt: I, betas: N } = await eR({
35956
35957
  prompt: o,
35957
35958
  sendReasoning: (h = J?.sendReasoning) != null ? h : !0,
35958
35959
  warnings: Y,
@@ -35960,7 +35961,7 @@ var sR = class $h {
35960
35961
  toolNameMapping: q
35961
35962
  });
35962
35963
  if (Ua(g) && J?.effort == null) {
35963
- const be = uR({
35964
+ const be = dR({
35964
35965
  reasoning: g,
35965
35966
  supportsAdaptiveThinking: V,
35966
35967
  supportsXhighEffort: oe,
@@ -36005,7 +36006,7 @@ var sR = class $h {
36005
36006
  ...Z && d?.type === "json" && d.schema != null && {
36006
36007
  format: {
36007
36008
  type: "json_schema",
36008
- schema: oR(d.schema)
36009
+ schema: aR(d.schema)
36009
36010
  }
36010
36011
  }
36011
36012
  }
@@ -36150,7 +36151,7 @@ var sR = class $h {
36150
36151
  toolChoice: Jt,
36151
36152
  toolWarnings: to,
36152
36153
  betas: Kt
36153
- } = await jM(
36154
+ } = await LM(
36154
36155
  te != null ? {
36155
36156
  tools: [...v ?? [], te],
36156
36157
  toolChoice: { type: "required" },
@@ -36264,7 +36265,7 @@ var sR = class $h {
36264
36265
  body: this.transformRequestBody(p, m),
36265
36266
  failedResponseHandler: $a,
36266
36267
  successfulResponseHandler: Fe(
36267
- lM
36268
+ cM
36268
36269
  ),
36269
36270
  abortSignal: t.abortSignal,
36270
36271
  fetch: this.config.fetch
@@ -36688,7 +36689,7 @@ var sR = class $h {
36688
36689
  headers: await this.getHeaders({ betas: s, headers: t.headers }),
36689
36690
  body: this.transformRequestBody(a, s),
36690
36691
  failedResponseHandler: $a,
36691
- successfulResponseHandler: fn(uM),
36692
+ successfulResponseHandler: fn(dM),
36692
36693
  abortSignal: t.abortSignal,
36693
36694
  fetch: this.config.fetch
36694
36695
  });
@@ -37382,7 +37383,7 @@ var sR = class $h {
37382
37383
  };
37383
37384
  }
37384
37385
  };
37385
- function lR(e) {
37386
+ function cR(e) {
37386
37387
  return e.includes("claude-opus-4-8") || e.includes("claude-opus-4-7") || e.includes("claude-fable-5") || e.includes("claude-sonnet-5") ? {
37387
37388
  maxOutputTokens: 128e3,
37388
37389
  supportsStructuredOutput: !0,
@@ -37457,7 +37458,7 @@ function Xc(e) {
37457
37458
  }
37458
37459
  return t && !o;
37459
37460
  }
37460
- function uR({
37461
+ function dR({
37461
37462
  reasoning: e,
37462
37463
  supportsAdaptiveThinking: t,
37463
37464
  supportsXhighEffort: o,
@@ -37524,7 +37525,7 @@ function ed(e) {
37524
37525
  ...e.recommended_model != null ? { recommendedModel: e.recommended_model } : {}
37525
37526
  };
37526
37527
  }
37527
- var cR = K(
37528
+ var pR = K(
37528
37529
  () => W(
37529
37530
  u({
37530
37531
  command: i(),
@@ -37533,9 +37534,9 @@ var cR = K(
37533
37534
  )
37534
37535
  ), td = Io({
37535
37536
  id: "anthropic.bash_20241022",
37536
- inputSchema: cR
37537
+ inputSchema: pR
37537
37538
  });
37538
- function dR(e = {}) {
37539
+ function mR(e = {}) {
37539
37540
  const { execute: t, ...o } = e;
37540
37541
  return td(t === void 0 ? {
37541
37542
  ...o,
@@ -37552,7 +37553,7 @@ function dR(e = {}) {
37552
37553
  ...t === null ? {} : { execute: t }
37553
37554
  });
37554
37555
  }
37555
- var pR = K(
37556
+ var fR = K(
37556
37557
  () => W(
37557
37558
  u({
37558
37559
  command: i(),
@@ -37561,9 +37562,9 @@ var pR = K(
37561
37562
  )
37562
37563
  ), od = Io({
37563
37564
  id: "anthropic.bash_20250124",
37564
- inputSchema: pR
37565
+ inputSchema: fR
37565
37566
  });
37566
- function mR(e = {}) {
37567
+ function hR(e = {}) {
37567
37568
  const { execute: t, ...o } = e;
37568
37569
  return od(t === void 0 ? {
37569
37570
  ...o,
@@ -37580,7 +37581,7 @@ function mR(e = {}) {
37580
37581
  ...t === null ? {} : { execute: t }
37581
37582
  });
37582
37583
  }
37583
- var fR = K(
37584
+ var gR = K(
37584
37585
  () => W(
37585
37586
  u({
37586
37587
  action: ee([
@@ -37599,10 +37600,10 @@ var fR = K(
37599
37600
  text: i().optional()
37600
37601
  })
37601
37602
  )
37602
- ), hR = Io({
37603
+ ), vR = Io({
37603
37604
  id: "anthropic.computer_20241022",
37604
- inputSchema: fR
37605
- }), gR = K(
37605
+ inputSchema: gR
37606
+ }), yR = K(
37606
37607
  () => W(
37607
37608
  u({
37608
37609
  action: ee([
@@ -37631,10 +37632,10 @@ var fR = K(
37631
37632
  text: i().optional()
37632
37633
  })
37633
37634
  )
37634
- ), vR = Io({
37635
+ ), _R = Io({
37635
37636
  id: "anthropic.computer_20250124",
37636
- inputSchema: gR
37637
- }), yR = K(
37637
+ inputSchema: yR
37638
+ }), bR = K(
37638
37639
  () => W(
37639
37640
  u({
37640
37641
  action: ee([
@@ -37670,10 +37671,10 @@ var fR = K(
37670
37671
  text: i().optional()
37671
37672
  })
37672
37673
  )
37673
- ), _R = Io({
37674
+ ), wR = Io({
37674
37675
  id: "anthropic.computer_20251124",
37675
- inputSchema: yR
37676
- }), bR = K(
37676
+ inputSchema: bR
37677
+ }), xR = K(
37677
37678
  () => W(
37678
37679
  Te("command", [
37679
37680
  u({
@@ -37709,10 +37710,10 @@ var fR = K(
37709
37710
  })
37710
37711
  ])
37711
37712
  )
37712
- ), wR = Io({
37713
+ ), TR = Io({
37713
37714
  id: "anthropic.memory_20250818",
37714
- inputSchema: bR
37715
- }), xR = K(
37715
+ inputSchema: xR
37716
+ }), IR = K(
37716
37717
  () => W(
37717
37718
  u({
37718
37719
  command: ee(["view", "create", "str_replace", "insert", "undo_edit"]),
@@ -37725,10 +37726,10 @@ var fR = K(
37725
37726
  view_range: A(T().int()).optional()
37726
37727
  })
37727
37728
  )
37728
- ), TR = Io({
37729
+ ), kR = Io({
37729
37730
  id: "anthropic.text_editor_20241022",
37730
- inputSchema: xR
37731
- }), IR = K(
37731
+ inputSchema: IR
37732
+ }), SR = K(
37732
37733
  () => W(
37733
37734
  u({
37734
37735
  command: ee(["view", "create", "str_replace", "insert", "undo_edit"]),
@@ -37741,10 +37742,10 @@ var fR = K(
37741
37742
  view_range: A(T().int()).optional()
37742
37743
  })
37743
37744
  )
37744
- ), kR = Io({
37745
+ ), CR = Io({
37745
37746
  id: "anthropic.text_editor_20250124",
37746
- inputSchema: IR
37747
- }), SR = K(
37747
+ inputSchema: SR
37748
+ }), ER = K(
37748
37749
  () => W(
37749
37750
  u({
37750
37751
  command: ee(["view", "create", "str_replace", "insert"]),
@@ -37757,10 +37758,10 @@ var fR = K(
37757
37758
  view_range: A(T().int()).optional()
37758
37759
  })
37759
37760
  )
37760
- ), CR = Io({
37761
+ ), MR = Io({
37761
37762
  id: "anthropic.text_editor_20250429",
37762
- inputSchema: SR
37763
- }), ER = K(
37763
+ inputSchema: ER
37764
+ }), RR = K(
37764
37765
  () => W(
37765
37766
  A(
37766
37767
  u({
@@ -37769,7 +37770,7 @@ var fR = K(
37769
37770
  })
37770
37771
  )
37771
37772
  )
37772
- ), MR = K(
37773
+ ), OR = K(
37773
37774
  () => W(
37774
37775
  u({
37775
37776
  /**
@@ -37783,12 +37784,12 @@ var fR = K(
37783
37784
  limit: T().optional()
37784
37785
  })
37785
37786
  )
37786
- ), RR = it({
37787
+ ), AR = it({
37787
37788
  id: "anthropic.tool_search_bm25_20251119",
37788
- inputSchema: MR,
37789
- outputSchema: ER,
37789
+ inputSchema: OR,
37790
+ outputSchema: RR,
37790
37791
  supportsDeferredResults: !0
37791
- }), OR = (e = {}) => RR(e), AR = {
37792
+ }), NR = (e = {}) => AR(e), $R = {
37792
37793
  /**
37793
37794
  * Pairs a faster executor model with a higher-intelligence advisor model
37794
37795
  * that provides strategic guidance mid-generation.
@@ -37817,21 +37818,21 @@ var fR = K(
37817
37818
  * across calls within a conversation. Worthwhile from ~3 advisor calls
37818
37819
  * per conversation.
37819
37820
  */
37820
- advisor_20260301: hM,
37821
+ advisor_20260301: vM,
37821
37822
  /**
37822
37823
  * The bash tool enables Claude to execute shell commands in a persistent bash session,
37823
37824
  * allowing system operations, script execution, and command-line automation.
37824
37825
  *
37825
37826
  * Image results are supported.
37826
37827
  */
37827
- bash_20241022: dR,
37828
+ bash_20241022: mR,
37828
37829
  /**
37829
37830
  * The bash tool enables Claude to execute shell commands in a persistent bash session,
37830
37831
  * allowing system operations, script execution, and command-line automation.
37831
37832
  *
37832
37833
  * Image results are supported.
37833
37834
  */
37834
- bash_20250124: mR,
37835
+ bash_20250124: hR,
37835
37836
  /**
37836
37837
  * Claude can analyze data, create visualizations, perform complex calculations,
37837
37838
  * run system commands, create and edit files, and process uploaded files directly within
@@ -37840,7 +37841,7 @@ var fR = K(
37840
37841
  * The code execution tool allows Claude to run Bash commands and manipulate files,
37841
37842
  * including writing code, in a secure, sandboxed environment.
37842
37843
  */
37843
- codeExecution_20250522: zM,
37844
+ codeExecution_20250522: ZM,
37844
37845
  /**
37845
37846
  * Claude can analyze data, create visualizations, perform complex calculations,
37846
37847
  * run system commands, create and edit files, and process uploaded files directly within
@@ -37851,7 +37852,7 @@ var fR = K(
37851
37852
  *
37852
37853
  * This is the latest version with enhanced Bash support and file operations.
37853
37854
  */
37854
- codeExecution_20250825: VM,
37855
+ codeExecution_20250825: BM,
37855
37856
  /**
37856
37857
  * Claude can analyze data, create visualizations, perform complex calculations,
37857
37858
  * run system commands, create and edit files, and process uploaded files directly within
@@ -37864,7 +37865,7 @@ var fR = K(
37864
37865
  *
37865
37866
  * Supported models: Claude Opus 4.6, Sonnet 4.6, Sonnet 4.5, Opus 4.5
37866
37867
  */
37867
- codeExecution_20260120: HM,
37868
+ codeExecution_20260120: JM,
37868
37869
  /**
37869
37870
  * Claude can interact with computer environments through the computer use tool, which
37870
37871
  * provides screenshot capabilities and mouse/keyboard control for autonomous desktop interaction.
@@ -37875,7 +37876,7 @@ var fR = K(
37875
37876
  * @param displayHeightPx - The height of the display being controlled by the model in pixels.
37876
37877
  * @param displayNumber - The display number to control (only relevant for X11 environments). If specified, the tool will be provided a display number in the tool definition.
37877
37878
  */
37878
- computer_20241022: hR,
37879
+ computer_20241022: vR,
37879
37880
  /**
37880
37881
  * Claude can interact with computer environments through the computer use tool, which
37881
37882
  * provides screenshot capabilities and mouse/keyboard control for autonomous desktop interaction.
@@ -37886,7 +37887,7 @@ var fR = K(
37886
37887
  * @param displayHeightPx - The height of the display being controlled by the model in pixels.
37887
37888
  * @param displayNumber - The display number to control (only relevant for X11 environments). If specified, the tool will be provided a display number in the tool definition.
37888
37889
  */
37889
- computer_20250124: vR,
37890
+ computer_20250124: _R,
37890
37891
  /**
37891
37892
  * Claude can interact with computer environments through the computer use tool, which
37892
37893
  * provides screenshot capabilities and mouse/keyboard control for autonomous desktop interaction.
@@ -37902,7 +37903,7 @@ var fR = K(
37902
37903
  * @param displayNumber - The display number to control (only relevant for X11 environments). If specified, the tool will be provided a display number in the tool definition.
37903
37904
  * @param enableZoom - Enable zoom action. Set to true to allow Claude to zoom into specific screen regions. Default: false.
37904
37905
  */
37905
- computer_20251124: _R,
37906
+ computer_20251124: wR,
37906
37907
  /**
37907
37908
  * The memory tool enables Claude to store and retrieve information across conversations through a memory file directory.
37908
37909
  * Claude can create, read, update, and delete files that persist between sessions,
@@ -37911,7 +37912,7 @@ var fR = K(
37911
37912
  *
37912
37913
  * Supported models: Claude Sonnet 4.5, Claude Sonnet 4, Claude Opus 4.1, Claude Opus 4.
37913
37914
  */
37914
- memory_20250818: wR,
37915
+ memory_20250818: TR,
37915
37916
  /**
37916
37917
  * Claude can use an Anthropic-defined text editor tool to view and modify text files,
37917
37918
  * helping you debug, fix, and improve your code or other text documents. This allows Claude
@@ -37919,7 +37920,7 @@ var fR = K(
37919
37920
  *
37920
37921
  * Supported models: Claude Sonnet 3.5
37921
37922
  */
37922
- textEditor_20241022: TR,
37923
+ textEditor_20241022: kR,
37923
37924
  /**
37924
37925
  * Claude can use an Anthropic-defined text editor tool to view and modify text files,
37925
37926
  * helping you debug, fix, and improve your code or other text documents. This allows Claude
@@ -37927,7 +37928,7 @@ var fR = K(
37927
37928
  *
37928
37929
  * Supported models: Claude Sonnet 3.7
37929
37930
  */
37930
- textEditor_20250124: kR,
37931
+ textEditor_20250124: CR,
37931
37932
  /**
37932
37933
  * Claude can use an Anthropic-defined text editor tool to view and modify text files,
37933
37934
  * helping you debug, fix, and improve your code or other text documents. This allows Claude
@@ -37937,7 +37938,7 @@ var fR = K(
37937
37938
  *
37938
37939
  * @deprecated Use textEditor_20250728 instead
37939
37940
  */
37940
- textEditor_20250429: CR,
37941
+ textEditor_20250429: MR,
37941
37942
  /**
37942
37943
  * Claude can use an Anthropic-defined text editor tool to view and modify text files,
37943
37944
  * helping you debug, fix, and improve your code or other text documents. This allows Claude
@@ -37949,7 +37950,7 @@ var fR = K(
37949
37950
  *
37950
37951
  * @param maxCharacters - Optional maximum number of characters to view in the file
37951
37952
  */
37952
- textEditor_20250728: _M,
37953
+ textEditor_20250728: wM,
37953
37954
  /**
37954
37955
  * Creates a web fetch tool that gives Claude direct access to real-time web content.
37955
37956
  *
@@ -37959,7 +37960,7 @@ var fR = K(
37959
37960
  * @param citations - Unlike web search where citations are always enabled, citations are optional for web fetch. Set "citations": {"enabled": true} to enable Claude to cite specific passages from fetched documents.
37960
37961
  * @param maxContentTokens - The max_content_tokens parameter limits the amount of content that will be included in the context.
37961
37962
  */
37962
- webFetch_20250910: qM,
37963
+ webFetch_20250910: UM,
37963
37964
  /**
37964
37965
  * Creates a web fetch tool that gives Claude direct access to real-time web content.
37965
37966
  *
@@ -37969,7 +37970,7 @@ var fR = K(
37969
37970
  * @param citations - Unlike web search where citations are always enabled, citations are optional for web fetch. Set "citations": {"enabled": true} to enable Claude to cite specific passages from fetched documents.
37970
37971
  * @param maxContentTokens - The max_content_tokens parameter limits the amount of content that will be included in the context.
37971
37972
  */
37972
- webFetch_20260209: NM,
37973
+ webFetch_20260209: PM,
37973
37974
  /**
37974
37975
  * Creates a web search tool that gives Claude direct access to real-time web content.
37975
37976
  *
@@ -37978,7 +37979,7 @@ var fR = K(
37978
37979
  * @param blockedDomains - Optional list of domains that Claude should avoid when searching.
37979
37980
  * @param userLocation - Optional user location information to provide geographically relevant search results.
37980
37981
  */
37981
- webSearch_20250305: EM,
37982
+ webSearch_20250305: RM,
37982
37983
  /**
37983
37984
  * Creates a web search tool that gives Claude direct access to real-time web content.
37984
37985
  *
@@ -37987,7 +37988,7 @@ var fR = K(
37987
37988
  * @param blockedDomains - Optional list of domains that Claude should avoid when searching.
37988
37989
  * @param userLocation - Optional user location information to provide geographically relevant search results.
37989
37990
  */
37990
- webSearch_20260209: IM,
37991
+ webSearch_20260209: SM,
37991
37992
  /**
37992
37993
  * Creates a tool search tool that uses regex patterns to find tools.
37993
37994
  *
@@ -38001,7 +38002,7 @@ var fR = K(
38001
38002
  *
38002
38003
  * Supported models: Claude Opus 4.5, Claude Sonnet 4.5
38003
38004
  */
38004
- toolSearchRegex_20251119: KM,
38005
+ toolSearchRegex_20251119: XM,
38005
38006
  /**
38006
38007
  * Creates a tool search tool that uses BM25 (natural language) to find tools.
38007
38008
  *
@@ -38015,8 +38016,8 @@ var fR = K(
38015
38016
  *
38016
38017
  * Supported models: Claude Opus 4.5, Claude Sonnet 4.5
38017
38018
  */
38018
- toolSearchBm25_20251119: OR
38019
- }, NR = K(
38019
+ toolSearchBm25_20251119: NR
38020
+ }, PR = K(
38020
38021
  () => W(
38021
38022
  u({
38022
38023
  id: i(),
@@ -38029,7 +38030,7 @@ var fR = K(
38029
38030
  updated_at: i()
38030
38031
  })
38031
38032
  )
38032
- ), $R = K(
38033
+ ), DR = K(
38033
38034
  () => W(
38034
38035
  u({
38035
38036
  type: i(),
@@ -38038,7 +38039,7 @@ var fR = K(
38038
38039
  description: i().nullish()
38039
38040
  })
38040
38041
  )
38041
- ), PR = class {
38042
+ ), qR = class {
38042
38043
  constructor(e) {
38043
38044
  this.config = e, this.specificationVersion = "v4";
38044
38045
  }
@@ -38060,7 +38061,7 @@ var fR = K(
38060
38061
  headers: o,
38061
38062
  failedResponseHandler: $a,
38062
38063
  successfulResponseHandler: Fe(
38063
- $R
38064
+ DR
38064
38065
  ),
38065
38066
  fetch: this.config.fetch
38066
38067
  });
@@ -38083,7 +38084,7 @@ var fR = K(
38083
38084
  formData: a,
38084
38085
  failedResponseHandler: $a,
38085
38086
  successfulResponseHandler: Fe(
38086
- NR
38087
+ PR
38087
38088
  ),
38088
38089
  fetch: this.config.fetch
38089
38090
  }), l = s.latest_version != null ? await this.fetchVersionMetadata({
@@ -38107,7 +38108,7 @@ var fR = K(
38107
38108
  warnings: n
38108
38109
  };
38109
38110
  }
38110
- }, DR = "4.0.4";
38111
+ }, jR = "4.0.4";
38111
38112
  function Ph(e = {}) {
38112
38113
  var t, o;
38113
38114
  const n = (t = Lr(
@@ -38135,11 +38136,11 @@ function Ph(e = {}) {
38135
38136
  ...p,
38136
38137
  ...e.headers
38137
38138
  },
38138
- `ai-sdk/anthropic/${DR}`
38139
+ `ai-sdk/anthropic/${jR}`
38139
38140
  );
38140
38141
  }, s = (p) => {
38141
38142
  var d;
38142
- return new sR(p, {
38143
+ return new uR(p, {
38143
38144
  provider: a,
38144
38145
  baseURL: n,
38145
38146
  headers: r,
@@ -38150,7 +38151,7 @@ function Ph(e = {}) {
38150
38151
  "application/pdf": [/^https?:\/\/.*$/]
38151
38152
  })
38152
38153
  });
38153
- }, l = () => new PR({
38154
+ }, l = () => new qR({
38154
38155
  provider: `${a.replace(".messages", "")}.skills`,
38155
38156
  baseURL: n,
38156
38157
  headers: r,
@@ -38166,59 +38167,59 @@ function Ph(e = {}) {
38166
38167
  throw new ml({ modelId: p, modelType: "embeddingModel" });
38167
38168
  }, c.textEmbeddingModel = c.embeddingModel, c.imageModel = (p) => {
38168
38169
  throw new ml({ modelId: p, modelType: "imageModel" });
38169
- }, c.files = () => new sM({
38170
+ }, c.files = () => new uM({
38170
38171
  provider: a,
38171
38172
  baseURL: n,
38172
38173
  headers: r,
38173
38174
  fetch: e.fetch
38174
- }), c.skills = l, c.tools = AR, c;
38175
+ }), c.skills = l, c.tools = $R, c;
38175
38176
  }
38176
- var oO = Ph();
38177
- function qR(e, t) {
38177
+ var aO = Ph();
38178
+ function UR(e, t) {
38178
38179
  return Ph(t)(e);
38179
38180
  }
38180
- function nO(e) {
38181
+ function rO(e) {
38181
38182
  switch (e.provider) {
38182
38183
  case Kr.OPENAI:
38183
- return aM(e.modelId, { apiKey: e.apiKey });
38184
+ return iM(e.modelId, { apiKey: e.apiKey });
38184
38185
  case Kr.ANTHROPIC:
38185
- return qR(e.modelId, { apiKey: e.apiKey });
38186
+ return UR(e.modelId, { apiKey: e.apiKey });
38186
38187
  case Kr.GEMINI:
38187
- return oC(e.modelId, { apiKey: e.apiKey });
38188
+ return aC(e.modelId, { apiKey: e.apiKey });
38188
38189
  case nd:
38189
- return mk(e);
38190
+ return hk(e);
38190
38191
  default:
38191
38192
  throw new Error("Unknown AI provider");
38192
38193
  }
38193
38194
  }
38194
38195
  export {
38195
- YR as A,
38196
- XR as D,
38197
- WR as T,
38196
+ QR as A,
38197
+ eO as D,
38198
+ KR as T,
38198
38199
  le as Z,
38199
- JR as a,
38200
- oO as b,
38201
- nO as c,
38202
- eO as d,
38200
+ YR as a,
38201
+ aO as b,
38202
+ rO as c,
38203
+ oO as d,
38203
38204
  yt as e,
38204
38205
  Ee as f,
38205
38206
  iI as g,
38206
38207
  ei as h,
38207
38208
  Ps as i,
38208
38209
  Co as j,
38209
- zR as k,
38210
- QR as l,
38211
- GR as m,
38210
+ ZR as k,
38211
+ tO as l,
38212
+ HR as m,
38212
38213
  ft as n,
38213
- tO as o,
38214
- KR as p,
38214
+ nO as o,
38215
+ XR as p,
38215
38216
  Ct as q,
38216
38217
  kn as r,
38217
38218
  RI as s,
38218
- FR as t,
38219
- LR as u,
38220
- ZR as v,
38221
- BR as w,
38222
- VR as x,
38223
- HR as y
38219
+ VR as t,
38220
+ FR as u,
38221
+ GR as v,
38222
+ WR as w,
38223
+ BR as x,
38224
+ JR as y
38224
38225
  };