Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions litellm/llms/bedrock/chat/converse_transformation.py
Original file line number Diff line number Diff line change
Expand Up @@ -840,6 +840,7 @@ def _create_output_config_for_response_format(
}
"""
if json_schema is not None:
json_schema = AnthropicConfig.filter_anthropic_output_schema(json_schema)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Missing test for the fixed regression

The PR fixes a real 400-error path but ships no test for _create_output_config_for_response_format with a schema containing minimum/maximum (or any of the other newly-stripped fields). Existing tests in test_converse_transformation.py only cover clean schemas, so this scenario remains uncovered. A test mirroring the PR's own example (a score property with minimum: 0, maximum: 1) would verify that after the fix the fields are stripped and a Note: description is injected, and prevent future regressions on this path.

Rule Used: What: Ensure that any PR claiming to fix an issue ... (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

json_schema = AmazonConverseConfig._add_additional_properties_to_schema(
json_schema
)
Expand Down
Loading