@ai-sdk/openai 3.0.93 → 3.0.95

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.
@@ -3137,10 +3137,10 @@ async function convertToOpenAIResponsesInput({
3137
3137
  }
3138
3138
  break;
3139
3139
  }
3140
- if (hasPreviousResponseId && store && id != null) {
3140
+ const isProviderDefinedToolCall = hasLocalShellTool && resolvedToolName === "local_shell" || hasShellTool && resolvedToolName === "shell" || hasApplyPatchTool && resolvedToolName === "apply_patch" || ((_m = customProviderToolNames == null ? void 0 : customProviderToolNames.has(resolvedToolName)) != null ? _m : false);
3141
+ if (hasPreviousResponseId && store && id != null && isProviderDefinedToolCall) {
3141
3142
  break;
3142
3143
  }
3143
- const isProviderDefinedToolCall = hasLocalShellTool && resolvedToolName === "local_shell" || hasShellTool && resolvedToolName === "shell" || hasApplyPatchTool && resolvedToolName === "apply_patch" || ((_m = customProviderToolNames == null ? void 0 : customProviderToolNames.has(resolvedToolName)) != null ? _m : false);
3144
3144
  if (store && id != null && isProviderDefinedToolCall) {
3145
3145
  input.push({ type: "item_reference", id });
3146
3146
  break;
@@ -3364,7 +3364,7 @@ async function convertToOpenAIResponsesInput({
3364
3364
  continue;
3365
3365
  }
3366
3366
  processedApprovalIds.add(approvalResponse.approvalId);
3367
- if (store) {
3367
+ if (store && !hasConversation && !hasPreviousResponseId) {
3368
3368
  input.push({
3369
3369
  type: "item_reference",
3370
3370
  id: approvalResponse.approvalId