@ai-sdk/openai 3.0.0-beta.78 → 3.0.0-beta.80

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.
@@ -640,7 +640,7 @@ declare const webSearchPreview: _ai_sdk_provider_utils.ProviderToolFactoryWithOu
640
640
  /**
641
641
  * The URL opened by the model.
642
642
  */
643
- url: string;
643
+ url?: string | null;
644
644
  } | {
645
645
  /**
646
646
  * Action type "find": Searches for a pattern within a loaded page.
@@ -649,11 +649,11 @@ declare const webSearchPreview: _ai_sdk_provider_utils.ProviderToolFactoryWithOu
649
649
  /**
650
650
  * The URL of the page searched for the pattern.
651
651
  */
652
- url: string;
652
+ url?: string | null;
653
653
  /**
654
654
  * The pattern or text to search for within the page.
655
655
  */
656
- pattern: string;
656
+ pattern?: string | null;
657
657
  };
658
658
  }, {
659
659
  /**
@@ -640,7 +640,7 @@ declare const webSearchPreview: _ai_sdk_provider_utils.ProviderToolFactoryWithOu
640
640
  /**
641
641
  * The URL opened by the model.
642
642
  */
643
- url: string;
643
+ url?: string | null;
644
644
  } | {
645
645
  /**
646
646
  * Action type "find": Searches for a pattern within a loaded page.
@@ -649,11 +649,11 @@ declare const webSearchPreview: _ai_sdk_provider_utils.ProviderToolFactoryWithOu
649
649
  /**
650
650
  * The URL of the page searched for the pattern.
651
651
  */
652
- url: string;
652
+ url?: string | null;
653
653
  /**
654
654
  * The pattern or text to search for within the page.
655
655
  */
656
- pattern: string;
656
+ pattern?: string | null;
657
657
  };
658
658
  }, {
659
659
  /**
@@ -542,8 +542,7 @@ var openaiChatLanguageModelOptions = (0, import_provider_utils4.lazySchema)(
542
542
  var import_provider2 = require("@ai-sdk/provider");
543
543
  function prepareChatTools({
544
544
  tools,
545
- toolChoice,
546
- strictJsonSchema
545
+ toolChoice
547
546
  }) {
548
547
  tools = (tools == null ? void 0 : tools.length) ? tools : void 0;
549
548
  const toolWarnings = [];
@@ -560,7 +559,7 @@ function prepareChatTools({
560
559
  name: tool.name,
561
560
  description: tool.description,
562
561
  parameters: tool.inputSchema,
563
- strict: strictJsonSchema
562
+ ...tool.strict != null ? { strict: tool.strict } : {}
564
563
  }
565
564
  });
566
565
  break;
@@ -780,8 +779,7 @@ var OpenAIChatLanguageModel = class {
780
779
  toolWarnings
781
780
  } = prepareChatTools({
782
781
  tools,
783
- toolChoice,
784
- strictJsonSchema
782
+ toolChoice
785
783
  });
786
784
  return {
787
785
  args: {
@@ -2723,12 +2721,12 @@ var openaiResponsesChunkSchema = (0, import_provider_utils22.lazySchema)(
2723
2721
  }),
2724
2722
  import_v415.z.object({
2725
2723
  type: import_v415.z.literal("open_page"),
2726
- url: import_v415.z.string()
2724
+ url: import_v415.z.string().nullish()
2727
2725
  }),
2728
2726
  import_v415.z.object({
2729
2727
  type: import_v415.z.literal("find"),
2730
- url: import_v415.z.string(),
2731
- pattern: import_v415.z.string()
2728
+ url: import_v415.z.string().nullish(),
2729
+ pattern: import_v415.z.string().nullish()
2732
2730
  })
2733
2731
  ])
2734
2732
  }),
@@ -3018,12 +3016,12 @@ var openaiResponsesResponseSchema = (0, import_provider_utils22.lazySchema)(
3018
3016
  }),
3019
3017
  import_v415.z.object({
3020
3018
  type: import_v415.z.literal("open_page"),
3021
- url: import_v415.z.string()
3019
+ url: import_v415.z.string().nullish()
3022
3020
  }),
3023
3021
  import_v415.z.object({
3024
3022
  type: import_v415.z.literal("find"),
3025
- url: import_v415.z.string(),
3026
- pattern: import_v415.z.string()
3023
+ url: import_v415.z.string().nullish(),
3024
+ pattern: import_v415.z.string().nullish()
3027
3025
  })
3028
3026
  ])
3029
3027
  }),
@@ -3631,12 +3629,12 @@ var webSearchOutputSchema = (0, import_provider_utils28.lazySchema)(
3631
3629
  }),
3632
3630
  import_v421.z.object({
3633
3631
  type: import_v421.z.literal("openPage"),
3634
- url: import_v421.z.string()
3632
+ url: import_v421.z.string().nullish()
3635
3633
  }),
3636
3634
  import_v421.z.object({
3637
3635
  type: import_v421.z.literal("find"),
3638
- url: import_v421.z.string(),
3639
- pattern: import_v421.z.string()
3636
+ url: import_v421.z.string().nullish(),
3637
+ pattern: import_v421.z.string().nullish()
3640
3638
  })
3641
3639
  ]),
3642
3640
  sources: import_v421.z.array(
@@ -3684,12 +3682,12 @@ var webSearchPreviewOutputSchema = (0, import_provider_utils29.lazySchema)(
3684
3682
  }),
3685
3683
  import_v422.z.object({
3686
3684
  type: import_v422.z.literal("openPage"),
3687
- url: import_v422.z.string()
3685
+ url: import_v422.z.string().nullish()
3688
3686
  }),
3689
3687
  import_v422.z.object({
3690
3688
  type: import_v422.z.literal("find"),
3691
- url: import_v422.z.string(),
3692
- pattern: import_v422.z.string()
3689
+ url: import_v422.z.string().nullish(),
3690
+ pattern: import_v422.z.string().nullish()
3693
3691
  })
3694
3692
  ])
3695
3693
  })
@@ -3704,8 +3702,7 @@ var webSearchPreview = (0, import_provider_utils29.createProviderToolFactoryWith
3704
3702
  // src/responses/openai-responses-prepare-tools.ts
3705
3703
  async function prepareResponsesTools({
3706
3704
  tools,
3707
- toolChoice,
3708
- strictJsonSchema
3705
+ toolChoice
3709
3706
  }) {
3710
3707
  tools = (tools == null ? void 0 : tools.length) ? tools : void 0;
3711
3708
  const toolWarnings = [];
@@ -3721,7 +3718,7 @@ async function prepareResponsesTools({
3721
3718
  name: tool.name,
3722
3719
  description: tool.description,
3723
3720
  parameters: tool.inputSchema,
3724
- strict: strictJsonSchema
3721
+ ...tool.strict != null ? { strict: tool.strict } : {}
3725
3722
  });
3726
3723
  break;
3727
3724
  case "provider": {
@@ -4087,8 +4084,7 @@ var OpenAIResponsesLanguageModel = class {
4087
4084
  toolWarnings
4088
4085
  } = await prepareResponsesTools({
4089
4086
  tools,
4090
- toolChoice,
4091
- strictJsonSchema
4087
+ toolChoice
4092
4088
  });
4093
4089
  return {
4094
4090
  webSearchToolName,