@ai-sdk/openai 2.0.17 → 2.0.19
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 +19 -0
- package/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6 -4
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +6 -4
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +6 -4
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/internal/index.mjs
CHANGED
|
@@ -2221,9 +2221,10 @@ async function convertToOpenAIResponsesMessages({
|
|
|
2221
2221
|
};
|
|
2222
2222
|
} else if (part.mediaType === "application/pdf") {
|
|
2223
2223
|
if (part.data instanceof URL) {
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2224
|
+
return {
|
|
2225
|
+
type: "input_file",
|
|
2226
|
+
file_url: part.data.toString()
|
|
2227
|
+
};
|
|
2227
2228
|
}
|
|
2228
2229
|
return {
|
|
2229
2230
|
type: "input_file",
|
|
@@ -2519,7 +2520,8 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
2519
2520
|
constructor(modelId, config) {
|
|
2520
2521
|
this.specificationVersion = "v2";
|
|
2521
2522
|
this.supportedUrls = {
|
|
2522
|
-
"image/*": [/^https?:\/\/.*$/]
|
|
2523
|
+
"image/*": [/^https?:\/\/.*$/],
|
|
2524
|
+
"application/pdf": [/^https?:\/\/.*$/]
|
|
2523
2525
|
};
|
|
2524
2526
|
this.modelId = modelId;
|
|
2525
2527
|
this.config = config;
|