mirror of
https://github.com/BerriAI/litellm.git
synced 2026-12-05 01:59:27 +00:00
* fix(cost_map): accept reasoning_effort xhigh on unmapped Claude 5+ ids A Claude 5 or later id that is newer than the loaded cost map failed with BadRequestError effort='xhigh' is not supported by this model before the request was sent. The effort gate reads supports_xhigh_reasoning_effort, and no fallback rule carried it, so an unmapped id never had it. The same flag decides whether output_config.effort counts as supported, so with drop_params on, effort was dropped silently on the Anthropic, Bedrock and Vertex routes This adds a claude-xhigh-effort capability rule next to claude-thinking-on-by-default, with the same claude-<family>-<major> boundary at major 5 and up. Every mapped Claude 5+ row that declares the flag sets it true, and a test now keeps the rule and those rows in agreement. On /v1/messages, a legacy thinking budget in the xhigh bucket on an unmapped 5+ id now maps to effort xhigh instead of high, like the mapped 5 rows. The rule has no fill_missing_for_providers, so a mapped row keeps its own answer. Claude 4.x ids still reject xhigh, and supports_max_reasoning_effort and supports_speed stay off the rule because mapped 5+ rows disagree on them * fix(cost_map): keep none off the effort levels of unmapped Claude 5+ ids so Codex defaults to medium Opus and Sonnet 5.5 refuse thinking.type.disabled, and an unmapped id cannot show whether its thinking can be turned off. The Codex model catalog picked none as the default for these groups, so every Codex turn answered 400. The claude-xhigh-effort rule now sets supports_none_reasoning_effort false, so the catalog offers minimal to xhigh and defaults to medium * test(proxy): type the Codex default-level test for unmapped Claude 5+ groups --------- Co-authored-by: mateo-berri <277851410+mateo-berri@users.noreply.github.com> |
||
|---|---|---|
| .. | ||
| guardrail_translation | ||
| __init__.py | ||
| conftest.py | ||
| test_anthropic_chat_handler.py | ||
| test_anthropic_chat_transformation.py | ||
| test_code_interpreter_results_extraction.py | ||
| test_transformation.py | ||