mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-17 09:34:48 +00:00
fix(bedrock_mantle): price gpt-5.6-sol at its promotional rates
AWS reduced GPT-5.6 Sol pricing on 2026-08-21 (20% off input, 33.3% off output), available at least through 2026-11-21. The reduction was applied to the bedrock_converse keys (us.openai.gpt-5.6-sol, global.openai.gpt-5.6-sol) and to the openai key, but the bedrock_mantle/openai.gpt-5.6-sol key still carried the pre-promotion rates, so mantle callers saw reported cost run ~24-43% above what AWS billed, depending on their input/output mix. bedrock-mantle serves Sol In-Region only, and the model card prices In-Region and Geo CRIS identically, so the mantle key now matches the existing us. converse entry exactly: input 5.5e-06 -> 4.4e-06 ($4.40 / 1M) cache write (30m) 6.875e-06 -> 5.5e-06 ($5.50 / 1M) cache read 5.5e-07 -> 4.4e-07 ($0.44 / 1M) output 3.3e-05 -> 2.2e-05 ($22.00 / 1M) plus the matching >272k long-context tier. Terra and Luna were already correct and are unchanged. Ref: https://docs.aws.amazon.com/bedrock/latest/userguide/model-card-openai-gpt-56-sol.html Ref: https://aws.amazon.com/about-aws/whats-new/2026/08/bedrock-openai-gpt-56-sol-reduced-pricing/ Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
db37977307
commit
e60dbc96ad
3 changed files with 37 additions and 16 deletions
|
|
@ -57368,14 +57368,14 @@
|
|||
"supports_tool_choice": true
|
||||
},
|
||||
"bedrock_mantle/openai.gpt-5.6-sol": {
|
||||
"input_cost_per_token": 5.5e-06,
|
||||
"input_cost_per_token_above_272k_tokens": 1.1e-05,
|
||||
"cache_creation_input_token_cost": 6.875e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,
|
||||
"cache_read_input_token_cost": 5.5e-07,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,
|
||||
"output_cost_per_token": 3.3e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 4.95e-05,
|
||||
"input_cost_per_token": 4.4e-06,
|
||||
"input_cost_per_token_above_272k_tokens": 8.8e-06,
|
||||
"cache_creation_input_token_cost": 5.5e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 1.1e-05,
|
||||
"cache_read_input_token_cost": 4.4e-07,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 8.8e-07,
|
||||
"output_cost_per_token": 2.2e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 3.3e-05,
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_high": 0.012,
|
||||
"search_context_size_low": 0.012,
|
||||
|
|
|
|||
|
|
@ -57368,14 +57368,14 @@
|
|||
"supports_tool_choice": true
|
||||
},
|
||||
"bedrock_mantle/openai.gpt-5.6-sol": {
|
||||
"input_cost_per_token": 5.5e-06,
|
||||
"input_cost_per_token_above_272k_tokens": 1.1e-05,
|
||||
"cache_creation_input_token_cost": 6.875e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,
|
||||
"cache_read_input_token_cost": 5.5e-07,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,
|
||||
"output_cost_per_token": 3.3e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 4.95e-05,
|
||||
"input_cost_per_token": 4.4e-06,
|
||||
"input_cost_per_token_above_272k_tokens": 8.8e-06,
|
||||
"cache_creation_input_token_cost": 5.5e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 1.1e-05,
|
||||
"cache_read_input_token_cost": 4.4e-07,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 8.8e-07,
|
||||
"output_cost_per_token": 2.2e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 3.3e-05,
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_high": 0.012,
|
||||
"search_context_size_low": 0.012,
|
||||
|
|
|
|||
|
|
@ -1912,6 +1912,27 @@ class TestBedrockMantleResponsesSigV4:
|
|||
class TestBedrockMantleResponsesPricing:
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"model",
|
||||
["openai.gpt-5.6-sol", "openai.gpt-5.6-terra", "openai.gpt-5.6-luna"],
|
||||
)
|
||||
def test_mantle_matches_in_region_converse_pricing(self, local_cost_map, model):
|
||||
"""bedrock-mantle serves these models In-Region only, and the AWS model
|
||||
cards price In-Region and Geo CRIS identically -- so every cost field on
|
||||
the mantle key must equal the `us.` converse key. A price change applied
|
||||
to one namespace but not the other shows up here.
|
||||
"""
|
||||
mantle = litellm.model_cost[f"bedrock_mantle/{model}"]
|
||||
converse = litellm.model_cost[f"us.{model}"]
|
||||
|
||||
cost_fields = [k for k in converse if "cost" in k and k != "search_context_cost_per_query"]
|
||||
assert cost_fields, "expected cost fields on the converse entry"
|
||||
for field in cost_fields:
|
||||
assert mantle.get(field) == pytest.approx(converse[field]), (
|
||||
f"{model}: {field} is {mantle.get(field)} on bedrock_mantle "
|
||||
f"but {converse[field]} on us. (bedrock_converse)"
|
||||
)
|
||||
|
||||
def test_models_registered(self, local_cost_map):
|
||||
assert "bedrock_mantle/openai.gpt-5.5" in litellm.bedrock_mantle_models
|
||||
assert "bedrock_mantle/openai.gpt-5.4" in litellm.bedrock_mantle_models
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue