@ai-sdk/openai 3.0.64 → 3.0.65
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/index.js +7 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -2
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +6 -1
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +6 -1
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/responses/convert-to-openai-responses-input.ts +9 -1
- package/src/responses/openai-responses-language-model.ts +1 -0
package/dist/internal/index.js
CHANGED
|
@@ -2689,6 +2689,7 @@ async function convertToOpenAIResponsesInput({
|
|
|
2689
2689
|
passThroughUnsupportedFiles = false,
|
|
2690
2690
|
store,
|
|
2691
2691
|
hasConversation = false,
|
|
2692
|
+
hasPreviousResponseId = false,
|
|
2692
2693
|
hasLocalShellTool = false,
|
|
2693
2694
|
hasShellTool = false,
|
|
2694
2695
|
hasApplyPatchTool = false,
|
|
@@ -2831,6 +2832,9 @@ async function convertToOpenAIResponsesInput({
|
|
|
2831
2832
|
break;
|
|
2832
2833
|
}
|
|
2833
2834
|
if (store && id != null) {
|
|
2835
|
+
if (hasPreviousResponseId) {
|
|
2836
|
+
break;
|
|
2837
|
+
}
|
|
2834
2838
|
input.push({ type: "item_reference", id });
|
|
2835
2839
|
break;
|
|
2836
2840
|
}
|
|
@@ -2975,7 +2979,7 @@ async function convertToOpenAIResponsesInput({
|
|
|
2975
2979
|
schema: openaiResponsesReasoningProviderOptionsSchema
|
|
2976
2980
|
});
|
|
2977
2981
|
const reasoningId = providerOptions == null ? void 0 : providerOptions.itemId;
|
|
2978
|
-
if (hasConversation && reasoningId != null) {
|
|
2982
|
+
if ((hasConversation || hasPreviousResponseId) && reasoningId != null) {
|
|
2979
2983
|
break;
|
|
2980
2984
|
}
|
|
2981
2985
|
if (reasoningId != null) {
|
|
@@ -5127,6 +5131,7 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
5127
5131
|
passThroughUnsupportedFiles: (_d = openaiOptions == null ? void 0 : openaiOptions.passThroughUnsupportedFiles) != null ? _d : false,
|
|
5128
5132
|
store: (_e = openaiOptions == null ? void 0 : openaiOptions.store) != null ? _e : true,
|
|
5129
5133
|
hasConversation: (openaiOptions == null ? void 0 : openaiOptions.conversation) != null,
|
|
5134
|
+
hasPreviousResponseId: (openaiOptions == null ? void 0 : openaiOptions.previousResponseId) != null,
|
|
5130
5135
|
hasLocalShellTool: hasOpenAITool("openai.local_shell"),
|
|
5131
5136
|
hasShellTool: hasOpenAITool("openai.shell"),
|
|
5132
5137
|
hasApplyPatchTool: hasOpenAITool("openai.apply_patch"),
|