@ai-sdk/anthropic 2.0.59 → 2.0.60
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.d.mts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +13 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +13 -2
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +12 -1
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +12 -1
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.mjs
CHANGED
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
} from "@ai-sdk/provider-utils";
|
|
12
12
|
|
|
13
13
|
// src/version.ts
|
|
14
|
-
var VERSION = true ? "2.0.
|
|
14
|
+
var VERSION = true ? "2.0.60" : "0.0.0-test";
|
|
15
15
|
|
|
16
16
|
// src/anthropic-messages-language-model.ts
|
|
17
17
|
import {
|
|
@@ -622,7 +622,12 @@ var anthropicProviderOptions = z3.object({
|
|
|
622
622
|
/**
|
|
623
623
|
* @default 'high'
|
|
624
624
|
*/
|
|
625
|
-
effort: z3.enum(["low", "medium", "high", "max"]).optional()
|
|
625
|
+
effort: z3.enum(["low", "medium", "high", "max"]).optional(),
|
|
626
|
+
/**
|
|
627
|
+
* Enable fast mode for faster inference (2.5x faster output token speeds).
|
|
628
|
+
* Only supported with claude-opus-4-6.
|
|
629
|
+
*/
|
|
630
|
+
speed: z3.literal("fast").optional()
|
|
626
631
|
});
|
|
627
632
|
|
|
628
633
|
// src/anthropic-prepare-tools.ts
|
|
@@ -1927,6 +1932,9 @@ var AnthropicMessagesLanguageModel = class {
|
|
|
1927
1932
|
...(anthropicOptions == null ? void 0 : anthropicOptions.effort) && {
|
|
1928
1933
|
output_config: { effort: anthropicOptions.effort }
|
|
1929
1934
|
},
|
|
1935
|
+
...(anthropicOptions == null ? void 0 : anthropicOptions.speed) && {
|
|
1936
|
+
speed: anthropicOptions.speed
|
|
1937
|
+
},
|
|
1930
1938
|
// structured output:
|
|
1931
1939
|
...useStructuredOutput && (responseFormat == null ? void 0 : responseFormat.type) === "json" && responseFormat.schema != null && {
|
|
1932
1940
|
output_format: {
|
|
@@ -2007,6 +2015,9 @@ var AnthropicMessagesLanguageModel = class {
|
|
|
2007
2015
|
if (anthropicOptions == null ? void 0 : anthropicOptions.effort) {
|
|
2008
2016
|
betas.add("effort-2025-11-24");
|
|
2009
2017
|
}
|
|
2018
|
+
if (anthropicOptions == null ? void 0 : anthropicOptions.speed) {
|
|
2019
|
+
betas.add("fast-mode-2026-02-01");
|
|
2020
|
+
}
|
|
2010
2021
|
if (useStructuredOutput) {
|
|
2011
2022
|
betas.add("structured-outputs-2025-11-13");
|
|
2012
2023
|
}
|