Skip to content

Commit 3595d1f

Browse files
committed
Fix Anthropic tool format to use custom type
1 parent c95a69c commit 3595d1f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

packages/agent/src/core/llm/providers/anthropic.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,11 @@ export class AnthropicProvider implements LLMProvider {
8080
// Add tools if provided
8181
if (functions && functions.length > 0) {
8282
const tools = functions.map(fn => ({
83-
type: 'function',
84-
function: {
83+
type: 'custom',
84+
custom: {
8585
name: fn.name,
8686
description: fn.description,
87-
parameters: fn.parameters,
87+
input_schema: fn.parameters,
8888
}
8989
}));
9090
console.log('Tools for Anthropic:', JSON.stringify(tools, null, 2));

0 commit comments

Comments
 (0)