Skip to content

fix(prices): add estimated Bedrock prices for GPT-6 Sol and GPT-6 Luna - #42728

Closed
marianobilli wants to merge 3 commits into
BerriAI:mainfrom
marianobilli:fix/bedrock-gpt-6-sol-luna-estimated-prices
Closed

marianobilli wants to merge 3 commits into
BerriAI:mainfrom
marianobilli:fix/bedrock-gpt-6-sol-luna-estimated-prices

Conversation

@marianobilli

@marianobilli marianobilli commented Sep 23, 2026 •

Copy link
Copy Markdown

TLDR

Problem this solves:

  • GPT-6 Sol and GPT-6 Luna are live on Bedrock, but AWS hasn't published their prices
  • Without a cost map entry, the proxy logs their spend as $0 and skips budget limits

How it solves it:

  • Adds estimated prices: the OpenAI API rate plus the 10% fee AWS adds for US Bedrock, and the plain OpenAI rate for Global cross-Region
  • Maintainers can replace them with official prices once AWS publishes them

⚠️ These are estimates, not published AWS prices. They are here so spend is tracked and budgets apply instead of counting as $0. It's up to the LiteLLM team whether to accept estimated entries or wait for official prices; if you'd rather wait, feel free to close this.

Why the estimate should be close

  • Every OpenAI model AWS has priced on Bedrock follows the same rule: US Geo and In-Region prices are the OpenAI API rate plus 10%, and Global cross-Region prices are the OpenAI API rate with no fee. The GPT-6 Astra model card says so directly: "Commercial In-Region prices include a 10% fee over OpenAI rates", and the card's Global CRIS row matches the OpenAI rate exactly. The GPT-5.6 Sol / Luna entries already in this file (us., bedrock_mantle/ and global.) follow the same pattern.
  • The Global cross-Region "no fee" part is visible in the pricing tables of the published model cards, where the Global CRIS row equals the OpenAI API rate and only In-Region / Geo CRIS carry the 10%:
    • GPT-6 Astra: Global CRIS $10.00 / $50.00 vs In-Region and Geo CRIS $11.00 / $55.00 (OpenAI rate: $10 / $50)
    • GPT-5.6 Sol: Global CRIS $4.00 / $20.00 vs In-Region and Geo CRIS $4.40 / $22.00 (OpenAI rate: $4 / $20)
  • The OpenAI rates come from the existing gpt-6-sol and gpt-6-luna entries in this file (source: https://developers.openai.com/api/docs/pricing).

Where AWS stands today (checked 2026-09-23)

  • The Bedrock pricing page lists GPT-6 Sol and GPT-6 Luna under OpenAI → Frontier Models, but with no prices. They link to the general OpenAI models page instead of their own model card.
  • model-card-openai-gpt-6-sol.html and model-card-openai-gpt-6-luna.html redirect to the Bedrock overview page.
  • The AWS Pricing API (AmazonBedrock, AmazonBedrockFoundationModels) has no GPT-6 Sol or Luna usage types yet.
  • Both models are already callable: us.openai.gpt-6-sol, us.openai.gpt-6-luna, global.openai.gpt-6-sol and global.openai.gpt-6-luna are listed as ACTIVE inference profiles in us-east-1, and openai.gpt-6-sol / openai.gpt-6-luna are returned by the Bedrock Mantle /v1/models endpoint.

Entries added

USD per 1M tokens, prompts up to 272K tokens. Above 272K tokens the same multiplier (1.1× for US, 1.0× for Global) is applied to OpenAI's long-context rates.

Key Input Cache read Output
us.openai.gpt-6-sol 2.20 0.22 11.00
bedrock_mantle/openai.gpt-6-sol 2.20 0.22 11.00
global.openai.gpt-6-sol 2.00 0.20 10.00
us.openai.gpt-6-luna 0.11 0.011 0.55
bedrock_mantle/openai.gpt-6-luna 0.11 0.011 0.55
global.openai.gpt-6-luna 0.10 0.010 0.50

Context limits and capability flags are copied from the matching GPT-5.6 Sol / Luna Bedrock entries (us.openai.gpt-5.6-*, bedrock_mantle/openai.gpt-5.6-* and global.openai.gpt-5.6-*). source points to the OpenAI pricing page, since no AWS page lists these prices yet.

Relevant issues

Related: #42727 (missing bedrock_mantle prices for DeepSeek, Kimi and Qwen)

Affected release

Linear ticket

Pre-Submission checklist

Please complete all items before asking a LiteLLM maintainer to review your PR

  • I have added meaningful tests
  • The handful of test files covering my change pass locally, e.g. uv run pytest tests/test_litellm/<your_test_file>.py -v. Leave the suites (make test-unit-*, make test-unit) to CI: it finishes in ~15 minutes where a laptop takes an hour or more
  • My PR passes all required CI/CD checks (e.g., lint, schema.d.ts sync check, etc.)
  • My PR's scope is as isolated as possible; it only solves 1 specific problem
  • I have received a Greptile Confidence Score of at least 4/5 before requesting a maintainer review (Greptile reviews automatically once the PR is opened; only comment @greptileai to re-request a review after pushing changes)

Tests run locally:

  • tests/test_litellm/test_bedrock_gpt_6_sol_luna_model_metadata.py (new): checks main and backup match, each price is the OpenAI rate × 1.1 (US) or × 1.0 (Global), and cost_per_token returns a non-zero cost
  • tests/test_litellm/test_model_prices_schema.py and tests/test_litellm/test_cost_map_guard.py: passing (103 passed in total)

Screenshots / Proof of Fix

Shared setup: LITELLM_LOCAL_MODEL_COST_MAP=True, then litellm.cost_per_token(model=..., prompt_tokens=100_000, completion_tokens=100_000) for each model.

Before (860bc78)

  1. us.openai.gpt-6-sol → BadRequestError: LLM Provider NOT provided
  2. bedrock_mantle/openai.gpt-6-sol → ModelNotMappedError: This model isn't mapped yet.
  3. us.openai.gpt-6-luna → BadRequestError: LLM Provider NOT provided
  4. bedrock_mantle/openai.gpt-6-luna → ModelNotMappedError: This model isn't mapped yet.
  5. global.openai.gpt-6-sol → BadRequestError: LLM Provider NOT provided
  6. global.openai.gpt-6-luna → BadRequestError: LLM Provider NOT provided

After (f10291e)

  1. us.openai.gpt-6-sol → (0.22, 1.10)
  2. bedrock_mantle/openai.gpt-6-sol → (0.22, 1.10)
  3. us.openai.gpt-6-luna → (0.011, 0.055)
  4. bedrock_mantle/openai.gpt-6-luna → (0.011, 0.055)
  5. global.openai.gpt-6-sol → (0.20, 1.00)
  6. global.openai.gpt-6-luna → (0.010, 0.050)

Type

🐛 Bug Fix

Caveats (if any)

  • Estimated prices. If AWS publishes different prices, these entries should be updated to match. I'm happy to do that once the model cards are out.
  • The Bedrock prices AWS publishes may differ from OpenAI rate × 1.1 (US) / × 1.0 (Global), but so far every OpenAI model on Bedrock has followed that rule.
  • Batch, flex and priority rates are left out, matching the existing GPT-5.6 Bedrock entries.

AWS has not published Bedrock prices for these models yet. Uses the OpenAI
API rate plus the 10% fee AWS applies to US Geo and In-Region OpenAI models,
so spend is tracked instead of logged as $0 until official prices land.
@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Mariano Billinghurst seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@greptile-apps

greptile-apps Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

The pricing entries appear behaviorally sound, but the explicit repository test requirements must be satisfied before merging

Findings

  1. P2 Uncited vendor pricing assumption ▶
  2. P2 New tests are untyped ▶
  3. P2 Disallowed explanatory comment ▶
  4. P2 Test uses wrong location ▶
  5. P2 Long-context cache rates untested ▶

Summary

This PR adds estimated Bedrock pricing and capability metadata for GPT-6 Sol and GPT-6 Luna to both model cost maps, plus regression coverage for map synchronization, the estimated uplift, and nonzero public cost calculation

  • Adds Bedrock Mantle and US Bedrock Converse entries for both models
  • Keeps the primary and backup cost maps synchronized
  • Uses OpenAI rates plus an estimated 10% US Bedrock uplift
  • Adds tests for entry equality, uplift calculations, and base token costs
  • The implementation metadata is consistent, but the new test needs repository-rule and long-context coverage fixes

Reviews (1) · Last reviewed commit: "fix(prices): add estimated Bedrock price..."

Comment on lines +13 to +15
# In-Region rates for OpenAI models are the OpenAI API rate plus a 10% fee,
# so these entries are the OpenAI rate for the same model times 1.1.
US_UPLIFT = 1.1

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Uncited vendor pricing assumption

This hardcodes AWS's 10% uplift without a source and verification date, violating a repository requirement that must be satisfied before merging

Context Used: AGENTS.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!



def _load(path):
with open(path) as f:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 New tests are untyped

The helper and parametrized tests omit parameter and return types, violating the fully typed Python requirement that must be satisfied before merging

Context Used: AGENTS.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Comment on lines +12 to +14
# AWS has not published Bedrock prices for these yet. Bedrock US Geo and
# In-Region rates for OpenAI models are the OpenAI API rate plus a 10% fee,
# so these entries are the OpenAI rate for the same model times 1.1.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Disallowed explanatory comment

This comment only restates straightforward pricing logic, violating the source-comment policy that must be satisfied before merging

Context Used: AGENTS.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@@ -0,0 +1,67 @@
import json

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Test uses wrong location

This bug fix creates a separate test file instead of extending mapped Bedrock cost coverage, violating a requirement that must be satisfied before merging

Context Used: AGENTS.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Comment on lines +22 to +29
PRICE_KEYS = (
"input_cost_per_token",
"input_cost_per_token_above_272k_tokens",
"cache_creation_input_token_cost",
"cache_read_input_token_cost",
"output_cost_per_token",
"output_cost_per_token_above_272k_tokens",
)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Long-context cache rates untested

These keys omit both above-272K cache rates, allowing incorrect long-context cache pricing to pass the new uplift test

Suggested change
PRICE_KEYS = (
"input_cost_per_token",
"input_cost_per_token_above_272k_tokens",
"cache_creation_input_token_cost",
"cache_read_input_token_cost",
"output_cost_per_token",
"output_cost_per_token_above_272k_tokens",
)
PRICE_KEYS = (
"input_cost_per_token",
"input_cost_per_token_above_272k_tokens",
"cache_creation_input_token_cost",
"cache_creation_input_token_cost_above_272k_tokens",
"cache_read_input_token_cost",
"cache_read_input_token_cost_above_272k_tokens",
"output_cost_per_token",
"output_cost_per_token_above_272k_tokens",
)

@codspeed

codspeed Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Merging this PR will not alter performance

✅ 31 untouched benchmarks


Comparing marianobilli:fix/bedrock-gpt-6-sol-luna-estimated-prices (f10291e) with main (860bc78)

Open in CodSpeed

@codecov

codecov Bot commented Sep 23, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@msvechla

Copy link
Copy Markdown

@marianobilli while you are at it, can you also add the same ones for global.openai.gpt-6-luna and sol? Otherwise I will open a PR

Mariano Billinghurst added 2 commits September 23, 2026 14:24
…rock prices

Global cross-Region inference for OpenAI models on Bedrock is priced at the
OpenAI API rate with no regional fee, so these use the OpenAI rate as is.
@marianobilli

Copy link
Copy Markdown
Author

@msvechla done, added global.openai.gpt-6-sol and global.openai.gpt-6-luna (both are ACTIVE inference profiles in us-east-1).

They use the plain OpenAI API rate with no 10% fee, since that's how AWS prices Global cross-Region for OpenAI models:

Key Input Cache read Output (per 1M)
global.openai.gpt-6-sol 2.00 0.20 10.00
global.openai.gpt-6-luna 0.10 0.010 0.50

Same caveat as the rest of the PR: these are estimates until AWS publishes the Sol / Luna model cards. The test now checks the ×1.0 Global and ×1.1 US multipliers and links the two model cards above.

@devin-ai-integration

Copy link
Copy Markdown
Contributor

Closing: these rows already landed on main with the same prices, and the rolling registry PR #42951 tracks the remaining unverified fields. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants