@ai-sdk/openai 2.0.48 → 2.0.49

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.
@@ -2933,6 +2933,7 @@ var openaiResponsesProviderOptionsSchema = (0, import_provider_utils22.lazyValid
2933
2933
  include: import_v415.z.array(
2934
2934
  import_v415.z.enum([
2935
2935
  "reasoning.encrypted_content",
2936
+ // handled internally by default, only needed for unknown reasoning models
2936
2937
  "file_search_call.results",
2937
2938
  "message.output_text.logprobs"
2938
2939
  ])
@@ -3430,7 +3431,11 @@ var OpenAIResponsesLanguageModel = class {
3430
3431
  const strictJsonSchema = (_b = openaiOptions == null ? void 0 : openaiOptions.strictJsonSchema) != null ? _b : false;
3431
3432
  let include = openaiOptions == null ? void 0 : openaiOptions.include;
3432
3433
  function addInclude(key) {
3433
- include = include != null ? [...include, key] : [key];
3434
+ if (include == null) {
3435
+ include = [key];
3436
+ } else if (!include.includes(key)) {
3437
+ include = [...include, key];
3438
+ }
3434
3439
  }
3435
3440
  function hasOpenAITool(id) {
3436
3441
  return (tools == null ? void 0 : tools.find(
@@ -3450,6 +3455,10 @@ var OpenAIResponsesLanguageModel = class {
3450
3455
  if (hasOpenAITool("openai.code_interpreter")) {
3451
3456
  addInclude("code_interpreter_call.outputs");
3452
3457
  }
3458
+ const store = openaiOptions == null ? void 0 : openaiOptions.store;
3459
+ if (store === false && modelConfig.isReasoningModel) {
3460
+ addInclude("reasoning.encrypted_content");
3461
+ }
3453
3462
  const baseArgs = {
3454
3463
  model: this.modelId,
3455
3464
  input,
@@ -3477,7 +3486,7 @@ var OpenAIResponsesLanguageModel = class {
3477
3486
  metadata: openaiOptions == null ? void 0 : openaiOptions.metadata,
3478
3487
  parallel_tool_calls: openaiOptions == null ? void 0 : openaiOptions.parallelToolCalls,
3479
3488
  previous_response_id: openaiOptions == null ? void 0 : openaiOptions.previousResponseId,
3480
- store: openaiOptions == null ? void 0 : openaiOptions.store,
3489
+ store,
3481
3490
  user: openaiOptions == null ? void 0 : openaiOptions.user,
3482
3491
  instructions: openaiOptions == null ? void 0 : openaiOptions.instructions,
3483
3492
  service_tier: openaiOptions == null ? void 0 : openaiOptions.serviceTier,