fix: add mcp support for anthropic native tool input schema
This commit is contained in:
parent
b847352101
commit
ce8c8dad63
@ -1434,7 +1434,9 @@ async function queryAnthropicNative(
|
||||
description: typeof tool.description === 'function'
|
||||
? await tool.description()
|
||||
: tool.description,
|
||||
input_schema: zodToJsonSchema(tool.inputSchema),
|
||||
input_schema:'inputJSONSchema' in tool && tool.inputJSONSchema
|
||||
? tool.inputJSONSchema
|
||||
: zodToJsonSchema(tool.inputSchema),
|
||||
}) as unknown as Anthropic.Beta.Messages.BetaTool,
|
||||
)
|
||||
)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user