@ai-sdk/amazon-bedrock 4.0.119 → 4.0.120
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 +8 -0
- package/dist/anthropic/index.js +1 -1
- package/dist/anthropic/index.mjs +1 -1
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -2
- package/dist/index.mjs.map +1 -1
- package/dist/mantle/index.js +1 -1
- package/dist/mantle/index.mjs +1 -1
- package/package.json +3 -3
- package/src/bedrock-prepare-tools.ts +9 -1
package/dist/index.mjs
CHANGED
|
@@ -286,12 +286,13 @@ async function prepareTools({
|
|
|
286
286
|
}
|
|
287
287
|
}
|
|
288
288
|
const filteredFunctionTools = (toolChoice == null ? void 0 : toolChoice.type) === "tool" ? functionTools.filter((t) => t.name === toolChoice.toolName) : functionTools;
|
|
289
|
+
const supportsStrictOnTools = !modelId.includes("claude-opus-4-7") && !modelId.includes("claude-opus-4-8");
|
|
289
290
|
for (const tool of filteredFunctionTools) {
|
|
290
291
|
bedrockTools.push({
|
|
291
292
|
toolSpec: {
|
|
292
293
|
name: tool.name,
|
|
293
294
|
...((_a = tool.description) == null ? void 0 : _a.trim()) !== "" ? { description: tool.description } : {},
|
|
294
|
-
...tool.strict != null ? { strict: tool.strict } : {},
|
|
295
|
+
...tool.strict != null && supportsStrictOnTools ? { strict: tool.strict } : {},
|
|
295
296
|
inputSchema: {
|
|
296
297
|
json: tool.inputSchema
|
|
297
298
|
}
|
|
@@ -2035,7 +2036,7 @@ import {
|
|
|
2035
2036
|
import { AwsV4Signer } from "aws4fetch";
|
|
2036
2037
|
|
|
2037
2038
|
// src/version.ts
|
|
2038
|
-
var VERSION = true ? "4.0.
|
|
2039
|
+
var VERSION = true ? "4.0.120" : "0.0.0-test";
|
|
2039
2040
|
|
|
2040
2041
|
// src/bedrock-sigv4-fetch.ts
|
|
2041
2042
|
function createSigV4FetchFunction(getCredentials, fetch, service = "bedrock") {
|