fix _map_tool_helper

This commit is contained in:
Ishaan Jaff 2025-07-24 15:58:55 -07:00
parent 6c950a545c
commit 9b76c0de9f

View file

@ -199,6 +199,11 @@ class AnthropicConfig(AnthropicModelInfo, BaseConfig):
},
)
input_schema: AnthropicInputSchema = AnthropicInputSchema(**_input_schema)
_allowed_properties = set(AnthropicInputSchema.__annotations__.keys())
input_schema_filtered = {k: v for k, v in _input_schema.items() if k in _allowed_properties}
input_schema: AnthropicInputSchema = AnthropicInputSchema(**input_schema_filtered)
_tool = AnthropicMessagesTool(
name=tool["function"]["name"],
input_schema=input_schema,