The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
feat(anthropic): add Claude Opus 5.5 (#42489)
devin-ai-integration[bot]c835a1a98236
diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.jsonindex 5847d8d5e68..468d86d049d 100644--- a/litellm/model_prices_and_context_window_backup.json+++ b/litellm/model_prices_and_context_window_backup.json@@ -15008,6 +15008,49 @@"supports_native_structured_output": true,"source": "https://platform.claude.com/docs/en/about-claude/pricing"},+ "claude-opus-5-5": {+ "supports_anthropic_compaction": true,+ "cache_creation_input_token_cost": 5e-06,+ "cache_creation_input_token_cost_above_1hr": 8e-06,+ "cache_read_input_token_cost": 2e-07,+ "input_cost_per_token": 4e-06,+ "litellm_provider": "anthropic",+ "max_input_tokens": 1000000,+ "max_output_tokens": 128000,+ "max_tokens": 128000,+ "mode": "chat",+ "output_cost_per_token": 2e-05,+ "search_context_cost_per_query": {+ "search_context_size_high": 0.01,+ "search_context_size_low": 0.01,+ "search_context_size_medium": 0.01+ },+ "supports_adaptive_thinking": true,+ "thinking_always_on": true,+ "supports_mid_conversation_system": true,+ "supports_assistant_prefill": false,+ "supports_computer_use": true,+ "supports_forced_tool_use": false,+ "supports_function_calling": true,+ "supports_pdf_input": true,+ "supports_prompt_caching": true,+ "supports_reasoning": true,+ "supports_response_schema": true,+ "supports_native_structured_output": true,+ "supports_sampling_params": false,+ "supports_tool_choice": true,+ "supports_vision": true,+ "supports_xhigh_reasoning_effort": true,+ "supports_max_reasoning_effort": true,+ "provider_specific_entry": {+ "fast": 2.0+ },+ "supports_output_config": true,+ "supports_speed": true,+ "supports_fast_mode": true,+ "prompt_cache_min_tokens": 512,+ "source": "https://platform.claude.com/docs/en/about-claude/pricing"+ },"claude-opus-5": {"supports_anthropic_compaction": true,"cache_creation_input_token_cost": 6.25e-06,diff --git a/litellm/setup_wizard.py b/litellm/setup_wizard.pyindex dd147aaccee..8b946923cd2 100644--- a/litellm/setup_wizard.py+++ b/litellm/setup_wizard.py@@ -53,13 +53,14 @@ PROVIDERS: Final[list[dict]] = [{"id": "anthropic","name": "Anthropic",- "description": "Claude Fable 5.1, Fable 5, Opus 5, Opus 4.8, Opus 4.7, Opus 4.6, Sonnet 5, Sonnet 4.6, Haiku 4.5",+ "description": "Claude Fable 5.1, Fable 5, Opus 5.5, Opus 5, Opus 4.8, Opus 4.7, Opus 4.6, Sonnet 5, Sonnet 4.6, Haiku 4.5","env_key": "ANTHROPIC_API_KEY","key_hint": "sk-ant-...","test_model": "claude-haiku-4-5-20251001","models": ["claude-fable-5-1","claude-fable-5",+ "claude-opus-5-5","claude-opus-5","claude-sonnet-5","claude-opus-4-8",diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.jsonindex 5847d8d5e68..468d86d049d 100644--- a/model_prices_and_context_window.json+++ b/model_prices_and_context_window.json@@ -15008,6 +15008,49 @@"supports_native_structured_output": true,"source": "https://platform.claude.com/docs/en/about-claude/pricing"},+ "claude-opus-5-5": {+ "supports_anthropic_compaction": true,+ "cache_creation_input_token_cost": 5e-06,+ "cache_creation_input_token_cost_above_1hr": 8e-06,+ "cache_read_input_token_cost": 2e-07,+ "input_cost_per_token": 4e-06,+ "litellm_provider": "anthropic",+ "max_input_tokens": 1000000,+ "max_output_tokens": 128000,+ "max_tokens": 128000,+ "mode": "chat",+ "output_cost_per_token": 2e-05,+ "search_context_cost_per_query": {+ "search_context_size_high": 0.01,+ "search_context_size_low": 0.01,+ "search_context_size_medium": 0.01+ },+ "supports_adaptive_thinking": true,+ "thinking_always_on": true,+ "supports_mid_conversation_system": true,+ "supports_assistant_prefill": false,+ "supports_computer_use": true,+ "supports_forced_tool_use": false,+ "supports_function_calling": true,+ "supports_pdf_input": true,+ "supports_prompt_caching": true,+ "supports_reasoning": true,+ "supports_response_schema": true,+ "supports_native_structured_output": true,+ "supports_sampling_params": false,+ "supports_tool_choice": true,+ "supports_vision": true,+ "supports_xhigh_reasoning_effort": true,+ "supports_max_reasoning_effort": true,+ "provider_specific_entry": {+ "fast": 2.0+ },+ "supports_output_config": true,+ "supports_speed": true,+ "supports_fast_mode": true,+ "prompt_cache_min_tokens": 512,+ "source": "https://platform.claude.com/docs/en/about-claude/pricing"+ },"claude-opus-5": {"supports_anthropic_compaction": true,"cache_creation_input_token_cost": 6.25e-06,diff --git a/tests/test_litellm/test_claude_opus_5_config.py b/tests/test_litellm/test_claude_opus_5_config.pyindex aaf179e0216..2e0a359b79b 100644--- a/tests/test_litellm/test_claude_opus_5_config.py+++ b/tests/test_litellm/test_claude_opus_5_config.py@@ -1,6 +1,8 @@"""Validate Claude Opus 5 model configuration entries.+Opus 5.5 (``claude-opus-5-5``) is covered here too.+Opus 5 carries Opus 4.8's pricing ($5 / $25 per MTok) and the gen-5 adaptivethinking profile, but differs from 4.8 in two ways that are behavior-bearing inLiteLLM: the cacheable-prefix minimum drops to 512 tokens, and Bedrock's Opus 5@@ -12,14 +14,23 @@ validator accepts the full effort ladder, so the entries must not carry the``anthropic/*`` wildcard deployment)."""+import jsonimport osimport pytestfrom litellm.constants import BEDROCK_CONVERSE_MODELS+from litellm.litellm_core_utils.get_model_cost_map import GetModelCostMapREPO_ROOT = os.path.join(os.path.dirname(__file__), "../..")++def _load_root_cost_map() -> dict:+ json_path = os.path.join(REPO_ROOT, "model_prices_and_context_window.json")+ with open(json_path) as f:+ return json.load(f)++ALL_OPUS_5_VARIANTS = ("claude-opus-5","anthropic.claude-opus-5",@@ -58,3 +69,20 @@ def test_opus_5_registered_for_bedrock_converse():assert "anthropic.claude-opus-5" in BEDROCK_CONVERSE_MODELS+def test_opus_5_5_present_in_bundled_backup():+ backup = GetModelCostMap.load_local_model_cost_map()+ root = _load_root_cost_map()+ assert "claude-opus-5-5" in backup+ assert "claude-opus-5-5" in root+ assert backup["claude-opus-5-5"] == root["claude-opus-5-5"]++[email protected]("model", ["claude-opus-5-5", "anthropic/claude-opus-5-5"])+def test_opus_5_5_thinking_profile(local_model_cost_map, model):+ """Opus 5.5 has thinking always on with the adaptive thinking surface, and+ no forced tool use, same as Fable 5.1."""+ from litellm.llms.anthropic.common_utils import AnthropicModelInfo++ assert AnthropicModelInfo._is_adaptive_thinking_model(model, "anthropic") is True+ assert AnthropicModelInfo._is_always_on_thinking_model(model, "anthropic") is True+ assert AnthropicModelInfo.forced_tool_use_unsupported(model.removeprefix("anthropic/")) is True