mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-13 23:11:40 +00:00
Anthropic's structured outputs reject any `additionalProperties` value other
than `false` ("output_format.schema: For 'object' type, 'additionalProperties:
true' is not supported. Please set 'additionalProperties' to false")
`filter_anthropic_output_schema` only added the key when it was absent, so an
explicit `true` (or a sub-schema) was copied verbatim into output_format.schema
and 400'd. Coerce it for object schemas instead, at every recursion depth,
matching what the Anthropic Python/TypeScript SDKs do
The permissive tool-use path (map_response_format_to_anthropic_tool, used for
vertex_ai) is deliberately left alone
Fixes #35808
|
||
|---|---|---|
| .. | ||
| a2a_protocol/providers/pydantic_ai_agents | ||
| integrations/helicone | ||
| litellm_core_utils | ||
| llms | ||
| proxy | ||
| test_bedrock_extended_beta_models.py | ||
| test_bedrock_nemotron_super.py | ||
| test_no_hardcoded_secrets.py | ||
| test_proxy_auth.py | ||
| test_router_retry_backoff_headers.py | ||
| test_sambanova_model_metadata.py | ||
| test_stream_chunk_builder_images.py | ||