Repository navigation
Conversation
Greptile SummaryUpdates the Bedrock Mantle GPT-5.6 Sol, Terra, and Luna metadata to advertise a 1,050,000-token input limit
Confidence Score: 4/5The metadata correction appears safe to merge after removing the newly added source-code comment The model-map values, lookup behavior, bundled backup, and regression coverage are consistent; only a non-blocking repository convention violation remains Files Needing Attention: tests/test_litellm/llms/bedrock_mantle/test_bedrock_mantle_responses_transformation.py
|
| Filename | Overview |
|---|---|
| model_prices_and_context_window.json | Updates the canonical max_input_tokens metadata consistently for all three Bedrock Mantle GPT-5.6 variants |
| litellm/model_prices_and_context_window_backup.json | Mirrors the canonical GPT-5.6 context-window changes in the bundled local model map |
| tests/test_litellm/llms/bedrock_mantle/test_bedrock_mantle_responses_transformation.py | Correctly updates the parametrized metadata assertion, but introduces a source comment prohibited by repository conventions |
| tests/test_litellm/llms/bedrock_mantle/test_bedrock_mantle_transformation.py | Adds offline, provider-scoped regression coverage for all changed GPT-5.6 entries and preserves shorter limits for GPT-5.4 and GPT-5.5 |
Reviews (1): Last reviewed commit: "fix(bedrock_mantle): correct GPT-5.6 con..." | Re-trigger Greptile
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
GPT-5.6 Sol, Terra, and Luna support 1M-token context windows on Amazon Bedrock, announced 2026-08-03: https://aws.amazon.com/about-aws/whats-new/2026/08/gpt-sol-terra-luna-long-context-bedrock/ The bedrock_mantle entries still carried the pre-launch 272000, while the azure/gpt-5.6-* entries in the same cost map already read 1050000. Because max_input_tokens is what clients use to budget context, the stale value causes premature context-window errors and early auto-compaction on a model that accepts ~4x more input. Verified against the live endpoint (bedrock-mantle us-east-2, Responses API). An oversized prompt reports the real cap: openai.gpt-5.6-sol -> prompt tokens (1300007) exceed model maximum (1050000) openai.gpt-5.6-terra -> prompt tokens (1300007) exceed model maximum (1050000) openai.gpt-5.6-luna -> prompt tokens (1300007) exceed model maximum (1050000) and a real 832877-token request completed successfully, correctly retrieving a fact planted at 85% depth. Scoped to 5.6 deliberately: openai.gpt-5.5 and openai.gpt-5.4 report a 278528 cap from the same endpoint, so they are left at their current value even though their azure/* counterparts read 1050000. Added a regression test pinning that distinction so the long-context values are not widened to every openai.gpt-5.x entry. Also updates the existing TestBedrockMantleResponsesPricing assertion, which pinned the old 272000.
0379875 to
3b001a7
Compare
|
Good catch, removed both comment lines. The test docstrings are kept since CONTRIBUTING.md asks for them. Tests still pass. |
|
Superseded: #38225 already raised the gpt-5.6 sol, terra, and luna entries to 1,050,000 with long-context tier pricing, so this change is on staging |
Title
fix(bedrock_mantle): correct GPT-5.6 context window to 1M tokens
Relevant issues
None filed — found while using
bedrock_mantleGPT-5.6 models behind the proxy.Pre-Submission checklist
tests/litellm/directoryType
🐛 Bug Fix
Changes
GPT-5.6 Sol, Terra, and Luna support 1M-token context windows on Amazon Bedrock, announced 2026-08-03.
The
bedrock_mantle/openai.gpt-5.6-*entries still carried the pre-launch272000, while theazure/gpt-5.6-*entries in the same cost map already read1050000— which is what suggested this was an oversight rather than intentional.Since
max_input_tokensis what clients use to budget context, the stale value causes premature context-window errors and early auto-compaction on a model that accepts ~4x more input."bedrock_mantle/openai.gpt-5.6-sol": { - "max_input_tokens": 272000, + "max_input_tokens": 1050000,…and the same for
-terraand-luna(plus the mirroredmodel_prices_and_context_window_backup.json).Verification against the live endpoint
bedrock-mantleus-east-2, Responses API. An oversized prompt makes the service report its own cap:A real 832,877-token request then completed successfully (
HTTP 200, 15s), correctly retrieving a fact planted at 85% depth — so the window is usable, not just accepted.Scoped to 5.6 on purpose
openai.gpt-5.5andopenai.gpt-5.4report a 278528 cap from the same endpoint, so I left them at their current value even though theirazure/*counterparts read1050000:Added
test_gpt_5_5_and_5_4_keep_shorter_context_windowto pin that distinction, so the long-context values don't get widened to everyopenai.gpt-5.xentry later.I did not change 5.5/5.4 to
278528here to keep this PR to one problem — happy to file that separately.Tests
New tests in
tests/test_litellm/llms/bedrock_mantle/test_bedrock_mantle_transformation.py, and updated the existingTestBedrockMantleResponsesPricingassertion that pinned the old value.The new tests fail without the data change (confirming they're meaningful):
ruffandblackare clean on the lines this PR touches.Note on
ci_cd/check_files_match.pyBoth JSON files are updated identically. Note that check already fails on a clean
litellm_internal_stagingcheckout — the backup has unrelated drift (zai/glm-5.1,openrouter/z-ai/glm-5.1,darkbloom/*). I deliberately did not sync those to keep this diff to 6 data lines; happy to include the full sync if you'd prefer.