fix(bedrock): strip output_config from Converse requests; fix spend tracking redaction test - #23240
Conversation
…racking redaction test Made-with: Cursor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Greptile SummaryThis PR contains two focused bug fixes:
Key observations:
Confidence Score: 5/5
Last reviewed commit: 200b001 |
Restore independent fixes from main that were collaterally removed when PR #23276 (staging_03_10 → main) carried a revert commit: - bedrock: restore output_config pop (PR #23240) - redact_messages: restore dict handling for ModelResponse (PR #23235) - model_checks: restore list() copies to avoid cache mutation (PR #23236) - openapi_to_mcp_generator: restore relative URL handling (PR #23238) - vertex_ai/gemini: restore _LITELLM_INTERNAL_EXTRA_BODY_KEYS check (PR #23131) - openai types: restore extra finish reasons (PR #22138) - completion_extras: restore usage transformation logic Accept main for: model_prices JSONs, credential_endpoints, team_endpoints, object_permission_utils, responses transformation.
…tput-config-spend-tracking fix(bedrock): strip output_config from Converse requests; fix spend tracking redaction test
Restore independent fixes from main that were collaterally removed when PR BerriAI#23276 (staging_03_10 → main) carried a revert commit: - bedrock: restore output_config pop (PR BerriAI#23240) - redact_messages: restore dict handling for ModelResponse (PR BerriAI#23235) - model_checks: restore list() copies to avoid cache mutation (PR BerriAI#23236) - openapi_to_mcp_generator: restore relative URL handling (PR BerriAI#23238) - vertex_ai/gemini: restore _LITELLM_INTERNAL_EXTRA_BODY_KEYS check (PR BerriAI#23131) - openai types: restore extra finish reasons (PR BerriAI#22138) - completion_extras: restore usage transformation logic Accept main for: model_prices JSONs, credential_endpoints, team_endpoints, object_permission_utils, responses transformation.
Summary
output_config(snake_case) from Bedrock Converse requests — Nova and other Converse models reject this Anthropic-only paramtest_spend_logs_redacts_request_and_response_when_turn_off_message_logging_enabledto match actualperform_redactionbehavior (in-place content redaction)Changes
converse_transformation.py: popoutput_configbefore building requesttest_converse_transformation.py: addtest_output_config_snake_case_stripped_from_bedrock_converse_requesttest_spend_tracking_utils.py: update assertion for dict response redactionMade with Cursor