Repository navigation
fix(azure): add flex prices to azure/gpt-6-luna - #50058
Closed
danielguthruf wants to merge 3 commits into
Closed
danielguthruf wants to merge 3 commits into
danielguthruf wants to merge 3 commits into
Conversation
The Azure retail price meters for 6-luna Flex Gl are half of the Std Gl meters. Without these fields a call served on the flex tier is priced at the standard price.
danielguthruf
requested review from
joshua-berri,
kerry-berri,
mateo-berri and
ryan-crabbe-berri
as code owners
November 4, 2026 15:20
Replaces the test that pinned the json values with a flex cost test next to the GPT-6 Astra tier test. Without the flex fields the call falls back to the standard rate and the test fails.
…ome from as source
Contributor
|
Rolled into #50082 after re-checking each value against the official provider source. Closing this one as superseded, thanks for the work |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds the eight
*_flexprice fields toazure/gpt-6-lunaandazure/gpt-6-luna-2026-09-22, inmodel_prices_and_context_window.jsonandlitellm/model_prices_and_context_window_backup.json.Why
Azure serves GPT-6 Luna on the Flex tier (it is on the list of Flex-capable models in the Azure flex processing guide), and the response carries
service_tier: "flex". Both entries have no*_flexfields, so the tier key lookup falls back to the standard key and the call is priced at the standard price, twice the real one, without any warning.Seen on a proxy running 1.106.4: a request to an Azure Global Standard deployment of
gpt-6-lunawithx-ms-service-tier: flexcame back withservice_tier: "flex", andx-litellm-response-costhad the same cost per token as the same call on the standard tier.azure/gpt-5.6-lunaand the OpenAIgpt-6-lunaentry already carry these fields.Source
Azure Retail Prices API (
https://prices.azure.com/api/retail/prices, filtercontains(meterName,'6-luna')), meters effective 2026-10-01, USD per 1M tokens. Every Flex meter is exactly half of its Standard Global meter.6-luna ... Gl 1M Tokens)input_cost_per_token_flexoutput_cost_per_token_flexcache_read_input_token_cost_flexcache_creation_input_token_cost_flexinput_cost_per_token_above_272k_tokens_flexoutput_cost_per_token_above_272k_tokens_flexcache_read_input_token_cost_above_272k_tokens_flexcache_creation_input_token_cost_above_272k_tokens_flexThe new values are the same as the flex fields of the
gpt-6-lunaentry.Tests
test_generic_cost_per_token_azure_gpt_6_luna_flex_tiersintests/unit/litellm_core_utils/llm_cost_calc/test_llm_cost_calc_utils.py, next to the GPT-6 Astra tier test. It prices a flex call throughgeneric_cost_per_tokenfor both entries, below and above 272K tokens, with cached tokens. Without the new fields the call falls back to the standard rate and the test fails. I checked the lookup path by reading the cost code and did not run the suite locally, so CI is its first run.Not in this PR
azure/gpt-6-sol,azure/gpt-6-astraandazure/gpt-6.1-solhave the same gap. I only checked the Luna meters, so those are left for a follow-up.