[Feat] Add azure/gpt-5.5 + azure/gpt-5.5-pro entries (+ dated variants) - #26458
[Feat] Add azure/gpt-5.5 + azure/gpt-5.5-pro entries (+ dated variants)#26458mateo-berri wants to merge 2 commits into
Conversation
…ariants) Azure variants of OpenAI's GPT-5.5 family. Microsoft has not yet shipped GPT-5.5 on Azure OpenAI (latest GA on the Foundry models page is GPT-5.4 as of 2026-04-24), but adding the entries day-0 mirrors the established precedent for azure/gpt-5.4* (which were in the cost map before the Azure rollout) so cost tracking and capability flags work the moment customers deploy. Schema follows the existing azure/gpt-5.4* shape: - Same base/long-context pricing as openai/gpt-5.5*: $5/$30 chat, $60/$360 pro per 1M, with priority tier 2x base - Azure variants drop the flex/batches keys (Azure has no flex tier) but keep priority pricing, matching gpt-5.4* precedent - mode=chat for the thinking model, mode=responses for pro reasoning_effort capability flags mirror the OpenAI variants exactly since Azure proxies the same API contract: minimal rejection on both chat and pro, low/none rejection on pro. Once #26456 (which sets supports_low_reasoning_effort + minimal=false on openai/gpt-5.5*) lands, OpenAI and Azure flag profiles align. Tests pin entry presence + pricing for all four Azure variants and verify the live-API-derived reasoning_effort flags.
|
|
Low: No security issues foundThis PR adds static model pricing and capability metadata entries for Azure GPT-5.5 variants to two JSON configuration files, along with corresponding tests. No code logic, authentication, authorization, or input handling is changed. Status: 0 open Posted by Veria AI · 2026-04-24T22:36:41.893Z |
Greptile SummaryThis PR adds day-0 Azure entries for the GPT-5.5 family ( Confidence Score: 4/5Safe to merge once previous open feedback (missing reasoning-effort flags on dated variants) is resolved; pricing and schema structure are correct. The P1 issues flagged in earlier review threads — missing reasoning-effort capability flags on azure/gpt-5.5-2026-04-23 and azure/gpt-5.5-pro-2026-04-23, and no test coverage for those dated variants — remain unresolved in the current HEAD. No new P0/P1 issues were found beyond those. The pricing values, JSON schema, and existing test logic are all correct. model_prices_and_context_window.json and litellm/model_prices_and_context_window_backup.json — both dated-variant entries need reasoning-effort flags added to match their base aliases.
|
| Filename | Overview |
|---|---|
| model_prices_and_context_window.json | Adds 4 new azure/gpt-5.5* entries; base aliases have full reasoning-effort flags but both dated variants are missing them (flagged in previous review threads) |
| litellm/model_prices_and_context_window_backup.json | Mirror of main JSON; same 4 entries added with the same missing reasoning-effort flags on dated variants |
| tests/test_litellm/litellm_core_utils/llm_cost_calc/test_llm_cost_calc_utils.py | Adds pricing tests for all 4 entries and reasoning-effort flag tests for base aliases only; dated variants not covered by the flag test (flagged in previous review threads) |
| tests/test_litellm/test_utils.py | Adds supports_low_reasoning_effort to the JSON schema validator — minimal, correct change |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[litellm.completion call\nwith azure/gpt-5.5*] --> B{model_cost lookup\nget_model_info}
B --> C{Dated variant?\ne.g. azure/gpt-5.5-2026-04-23}
C -->|No - base alias| D[Full entry:\ncost + capability flags\ne.g. supports_none_reasoning_effort]
C -->|Yes - dated variant| E[Partial entry:\ncost fields only\nmissing reasoning-effort flags]
D --> F[Cost calc + capability\nchecks work correctly]
E --> G[Cost calc works ✓\nCapability flags return None/falsy ✗]
G --> H[supports_xhigh_reasoning_effort\nsilently returns None]
G --> I[supports_low_reasoning_effort\nnot enforced after #26456 merges]
Reviews (2): Last reviewed commit: "test: register supports_low_reasoning_ef..." | Re-trigger Greptile
| "azure/gpt-5.5-2026-04-23": { | ||
| "cache_read_input_token_cost": 5e-07, | ||
| "cache_read_input_token_cost_above_272k_tokens": 1e-06, | ||
| "cache_read_input_token_cost_priority": 1e-06, | ||
| "cache_read_input_token_cost_above_272k_tokens_priority": 2e-06, | ||
| "input_cost_per_token": 5e-06, | ||
| "input_cost_per_token_above_272k_tokens": 1e-05, | ||
| "input_cost_per_token_priority": 1e-05, | ||
| "input_cost_per_token_above_272k_tokens_priority": 2e-05, | ||
| "litellm_provider": "azure", | ||
| "max_input_tokens": 1050000, | ||
| "max_output_tokens": 128000, | ||
| "max_tokens": 128000, | ||
| "mode": "chat", | ||
| "output_cost_per_token": 3e-05, | ||
| "output_cost_per_token_above_272k_tokens": 4.5e-05, | ||
| "output_cost_per_token_priority": 6e-05, | ||
| "output_cost_per_token_above_272k_tokens_priority": 9e-05, | ||
| "supported_endpoints": [ | ||
| "/v1/chat/completions", | ||
| "/v1/batch", | ||
| "/v1/responses" | ||
| ], | ||
| "supported_modalities": [ | ||
| "text", | ||
| "image" | ||
| ], | ||
| "supported_output_modalities": [ | ||
| "text" | ||
| ], | ||
| "supports_function_calling": true, | ||
| "supports_native_streaming": true, | ||
| "supports_parallel_function_calling": true, | ||
| "supports_pdf_input": true, | ||
| "supports_prompt_caching": true, | ||
| "supports_reasoning": true, | ||
| "supports_response_schema": true, | ||
| "supports_system_messages": true, | ||
| "supports_tool_choice": true, | ||
| "supports_service_tier": true, | ||
| "supports_vision": true, | ||
| "supports_web_search": true | ||
| }, |
There was a problem hiding this comment.
Dated variants are missing reasoning-effort capability flags
azure/gpt-5.5-2026-04-23 is missing supports_none_reasoning_effort, supports_xhigh_reasoning_effort, and supports_minimal_reasoning_effort flags that are explicitly set on azure/gpt-5.5. azure/gpt-5.5-pro-2026-04-23 (lines 4790-4824) has the same problem and additionally drops supports_low_reasoning_effort: false — the flag the PR explicitly depends on for the rejection logic landing in #26456.
When users pin to a dated deployment variant (the common production pattern), get_model_info returns None for every one of these flags, making them all falsy. A user on azure/gpt-5.5-2026-04-23 will silently lose advertised xhigh support, and a user on azure/gpt-5.5-pro-2026-04-23 will have low pass through even after #26456 merges. The existing test_gpt55_dated_variants_match_base_reasoning_effort_capabilities test enforces this invariant for the OpenAI provider — the same pattern should apply here. The same omission exists in litellm/model_prices_and_context_window_backup.json for both dated variants.
Add the missing flags to both dated variant entries so they mirror their base models exactly.
| model, expected_none, expected_minimal, expected_xhigh | ||
| ): | ||
| """Azure entries pin reasoning_effort flags to OpenAI's actual API contract.""" | ||
| os.environ["LITELLM_LOCAL_MODEL_COST_MAP"] = "True" | ||
| litellm.model_cost = litellm.get_model_cost_map(url="") | ||
|
|
||
| m = litellm.model_cost[model] | ||
| assert m.get("supports_none_reasoning_effort") is expected_none | ||
| assert m.get("supports_minimal_reasoning_effort") is expected_minimal | ||
| assert m.get("supports_xhigh_reasoning_effort") is expected_xhigh | ||
|
|
||
|
|
||
| def test_generic_cost_per_token_anthropic_prompt_caching(): | ||
| model = "claude-sonnet-4@20250514" | ||
| usage = Usage( |
There was a problem hiding this comment.
Dated Azure variants not covered by reasoning-effort flag test
test_azure_gpt55_reasoning_effort_flags_match_live_openai_api only parametrizes azure/gpt-5.5 and azure/gpt-5.5-pro, so the missing flags on azure/gpt-5.5-2026-04-23 and azure/gpt-5.5-pro-2026-04-23 go undetected. The analogous OpenAI test (test_gpt55_dated_variants_match_base_reasoning_effort_capabilities) explicitly guards that dated variants inherit the same capability profile as their base alias. Without an equivalent guard for Azure, the two dated variants could silently diverge. Adding them to the parametrize list (or adding an Azure-specific dated-variant parity test) would catch the current gap and prevent regressions.
azure/gpt-5.5-pro and azure/gpt-5.5-pro-2026-04-23 added in this branch carry supports_low_reasoning_effort=false. The strict 'additionalProperties: false' schema in test_aaamodel_prices_and_context_window_json_is_valid rejected the new key. Register it alongside the other supports_*_reasoning_effort entries. Note: the runtime side of this flag (code that reads it) lands in #26456. Until that PR merges the flag is inert for both Azure and OpenAI pro entries, but having the schema accept it lets cost-map tests pass on either merge order.
|
Superseded by #26361 (force-pushed to include this PR's full scope: 4 entries, long-context pricing, tests, supports_low_reasoning_effort schema fix). Closing this duplicate. |
Relevant issues
Day-0 Azure entries for OpenAI's GPT-5.5 family. Microsoft hasn't shipped GPT-5.5 on Azure OpenAI yet (latest GA on the Foundry models page is the GPT-5.4 series as of 2026-04-24), but the existing precedent —
azure/gpt-5.4*was in the cost map before its Azure rollout — means we should land these entries now so cost tracking + capability flags Just Work the moment customers deploy.Pre-Submission checklist
tests/test_litellm/directory, Adding at least 1 test is a hard requirement - see detailsmake test-unit@greptileaiand received a Confidence Score of at least 4/5 before requesting a maintainer reviewDelays in PR merge?
If you're seeing a delay in your PR being merged, ping the LiteLLM Team on Slack (#pr-review).
CI (LiteLLM team)
Branch creation CI run
Link:
CI run for the last commit
Link:
Merge / cherry-pick CI run
Links:
Screenshots / Proof of Fix
Type
🆕 New Feature
Changes
Adds four entries to both
model_prices_and_context_window.jsonandlitellm/model_prices_and_context_window_backup.json:azure/gpt-5.5azure/gpt-5.5-2026-04-23azure/gpt-5.5-proazure/gpt-5.5-pro-2026-04-23Pricing per-1M-tokens. Schema follows the existing
azure/gpt-5.4*shape:openai/gpt-5.5*counterpartsmode: chatfor thinking,mode: responsesfor proreasoning_effortcapability flags mirror the OpenAI variants exactly since Azure proxies the same API contract —minimalrejected on both chat and pro,lowandnonerejected on pro.Dependency note
supports_low_reasoning_effortis set onazure/gpt-5.5-pro*here, but the flag itself is introduced in #26456 (along with thegpt-5.5-prolow-rejection logic inOpenAIGPT5Config.map_openai_params). Until #26456 lands, the flag on the Azure entries is inert (no effect —lowcontinues to pass through). After #26456 merges, both OpenAI and Azure pro variants will rejectlowconsistently.Tests
tests/test_litellm/litellm_core_utils/llm_cost_calc/test_llm_cost_calc_utils.py:test_azure_gpt55_entries_present_with_correct_pricing— parametrized over all four entries; verifies provider, mode, base + long-context pricing, context windowtest_azure_gpt55_reasoning_effort_flags_match_live_openai_api— pins the live-API-derivedsupports_{none, minimal, xhigh}_reasoning_effortprofile