@ai-sdk/anthropic 3.0.0-beta.20 → 3.0.0-beta.22
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 +13 -0
- package/dist/index.js +13 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +13 -1
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +12 -0
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +12 -0
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "@ai-sdk/provider-utils";
|
|
11
11
|
|
|
12
12
|
// src/version.ts
|
|
13
|
-
var VERSION = true ? "3.0.0-beta.
|
|
13
|
+
var VERSION = true ? "3.0.0-beta.22" : "0.0.0-test";
|
|
14
14
|
|
|
15
15
|
// src/anthropic-messages-language-model.ts
|
|
16
16
|
import {
|
|
@@ -1023,6 +1023,18 @@ async function convertToAnthropicMessagesPrompt({
|
|
|
1023
1023
|
cache_control: void 0
|
|
1024
1024
|
};
|
|
1025
1025
|
}
|
|
1026
|
+
if (contentPart.mediaType === "application/pdf") {
|
|
1027
|
+
betas.add("pdfs-2024-09-25");
|
|
1028
|
+
return {
|
|
1029
|
+
type: "document",
|
|
1030
|
+
source: {
|
|
1031
|
+
type: "base64",
|
|
1032
|
+
media_type: contentPart.mediaType,
|
|
1033
|
+
data: contentPart.data
|
|
1034
|
+
},
|
|
1035
|
+
cache_control: void 0
|
|
1036
|
+
};
|
|
1037
|
+
}
|
|
1026
1038
|
throw new UnsupportedFunctionalityError2({
|
|
1027
1039
|
functionality: `media type: ${contentPart.mediaType}`
|
|
1028
1040
|
});
|