@ai-sdk/anthropic 3.0.7 → 3.0.8
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 +10 -0
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -3
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +2 -2
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +2 -2
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# @ai-sdk/anthropic
|
|
2
2
|
|
|
3
|
+
## 3.0.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- bee4f82: fix(anthropic): enable structured output support for claude-haiku-4-5
|
|
8
|
+
|
|
9
|
+
This fixes an issue where the `strict: true` property was not included in the request body when using tools with Claude Haiku 4.5, because `supportsStructuredOutput` was incorrectly set to `false` for this model.
|
|
10
|
+
|
|
11
|
+
Claude Haiku 4.5 supports structured outputs, so the `strict` property should be forwarded to the Anthropic API when specified on tools.
|
|
12
|
+
|
|
3
13
|
## 3.0.7
|
|
4
14
|
|
|
5
15
|
### Patch Changes
|
package/dist/index.js
CHANGED
|
@@ -32,7 +32,7 @@ var import_provider4 = require("@ai-sdk/provider");
|
|
|
32
32
|
var import_provider_utils22 = require("@ai-sdk/provider-utils");
|
|
33
33
|
|
|
34
34
|
// src/version.ts
|
|
35
|
-
var VERSION = true ? "3.0.
|
|
35
|
+
var VERSION = true ? "3.0.8" : "0.0.0-test";
|
|
36
36
|
|
|
37
37
|
// src/anthropic-messages-language-model.ts
|
|
38
38
|
var import_provider3 = require("@ai-sdk/provider");
|
|
@@ -3756,7 +3756,7 @@ var AnthropicMessagesLanguageModel = class {
|
|
|
3756
3756
|
}
|
|
3757
3757
|
};
|
|
3758
3758
|
function getModelCapabilities(modelId) {
|
|
3759
|
-
if (modelId.includes("claude-sonnet-4-5") || modelId.includes("claude-opus-4-5")) {
|
|
3759
|
+
if (modelId.includes("claude-sonnet-4-5") || modelId.includes("claude-opus-4-5") || modelId.includes("claude-haiku-4-5")) {
|
|
3760
3760
|
return {
|
|
3761
3761
|
maxOutputTokens: 64e3,
|
|
3762
3762
|
supportsStructuredOutput: true,
|
|
@@ -3768,7 +3768,7 @@ function getModelCapabilities(modelId) {
|
|
|
3768
3768
|
supportsStructuredOutput: true,
|
|
3769
3769
|
isKnownModel: true
|
|
3770
3770
|
};
|
|
3771
|
-
} else if (modelId.includes("claude-sonnet-4-") || modelId.includes("claude-3-7-sonnet")
|
|
3771
|
+
} else if (modelId.includes("claude-sonnet-4-") || modelId.includes("claude-3-7-sonnet")) {
|
|
3772
3772
|
return {
|
|
3773
3773
|
maxOutputTokens: 64e3,
|
|
3774
3774
|
supportsStructuredOutput: false,
|