You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(bedrock-mantle): add custom_pricing execution modes for 20 models - #1021
20 models in bedrock-mantle.json had only a flat pricing_config with no custom_pricing block. This means applyCustomPricing always ignored service_tier (priority, flex, batch, ultrafast) and billed every request at standard rates — causing systematic undercounting for non-standard tiers.
For example:
priority tier is typically 1.75× standard → 43% undercounting
flex/batch tier is typically 0.5× standard → 2× overcounting
ultrafast on gpt-6-astra is 6× standard → 83% undercounting
Changes
pricing/bedrock-mantle.json
Added custom_pricing with execution_modes for 20 models across 4 provider families. All prices sourced from the matching bedrock.json entries (standard tier = exact match to previous flat pricing_config; other tiers per existing bedrock.json rate cards).
standard (lte-272K / gt-272K context tiers) + ultrafast
GPT-6 Astra — Ultrafast
AWS Bedrock now supports an Ultrafast service tier for GPT-6 Astra, priced at 6× standard.
Prices cross-checked against AWS docs and companion gateway PR.
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
The new custom token and cache rates alter standard-request costs from the existing Mantle baseline, contradicting the promise to preserve standard pricing.
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Missing batch rate cards prevent advertised discounts, while new standard tiers alter GPT-5.6 Sol and GPT-6 Sol/Luna prices despite the promised preservation of existing rates.
GPT-6 Sol and Luna standard rates are lower than Mantle rates
pricing/bedrock-mantle.json:1964
GPT-6 Sol's new short-context standard card lowers all four token rates by about 9.1% relative to the retained flat card—for example, input drops from 0.00022 to 0.0002—contradicting the promised preservation of standard prices. The same issue affects GPT-6 Luna at pricing/bedrock-mantle.json:2058. Preserve the existing Mantle baseline and derive the long-context rates consistently, or explicitly document intentional repricing and align the flat fallback with it.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Missing batch entries for 13 models in pricing/bedrock-mantle.json prevent batch lookups from selecting the documented discounted rates available in pricing/bedrock.json.
Models previously had only flat pricing_config, causing applyCustomPricing
to ignore service_tier (priority/flex/ultrafast) and always bill at standard
rates.
Added custom_pricing with execution_modes for all bedrock-mantle models
that have a matching entry in bedrock.json with multi-tier pricing:
Mistral (8 models): standard / priority / flex
- ministral-3-3b, ministral-3-8b, ministral-3-14b
- mistral-large-3-675b, devstral-2-123b, magistral-small-2509
- voxtral-small-24b, voxtral-mini-3b
Qwen/Moonshot/ZAI (6 models): standard / priority / flex
- qwen3-coder-next, kimi-k2.5, kimi-k3 (no batch/flex), glm-4.7,
glm-4.7-flash, glm-5
OpenAI-on-Bedrock (5 models): standard with lte-272K / gt-272K context tiers
- gpt-5.6-sol, gpt-5.6-terra, gpt-5.6-luna, gpt-6-sol, gpt-6-luna
GPT-6 Astra (1 model): standard (lte-272K / gt-272K) + ultrafast
- openai.gpt-6-astra — ultrafast = 6× standard (AWS docs confirmed)
Notes:
- batch mode intentionally excluded: batch inference is available only on
bedrock-runtime, not bedrock-mantle (AWS docs confirmed)
- lte-272k standard tier prices match existing flat pricing_config exactly
- gt-272k prices derived proportionally from bedrock.json context-tier ratio
- All prices in plain decimal form (no scientific notation, matching repo convention)
Ref: https://docs.aws.amazon.com/bedrock/latest/userguide/scaling-throughput-best-practices.html
Companion gateway PR: https://code.pan.run/airs/agent-gateway/backend/gateway-enterprise-node/-/merge_requests/2086
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Missing batch rates across multiple models and GPT-6 Astra’s missing context-tier and ultrafast pricing leave the reported billing inaccuracies unresolved.
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
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.
Problem
20 models in
bedrock-mantle.jsonhad only a flatpricing_configwith nocustom_pricingblock. This meansapplyCustomPricingalways ignoredservice_tier(priority,flex,batch,ultrafast) and billed every request at standard rates — causing systematic undercounting for non-standard tiers.For example:
prioritytier is typically 1.75× standard → 43% undercountingflex/batchtier is typically 0.5× standard → 2× overcountingultrafaston gpt-6-astra is 6× standard → 83% undercountingChanges
pricing/bedrock-mantle.jsonAdded
custom_pricingwithexecution_modesfor 20 models across 4 provider families. All prices sourced from the matchingbedrock.jsonentries (standard tier = exact match to previous flatpricing_config; other tiers per existing bedrock.json rate cards).GPT-6 Astra — Ultrafast
AWS Bedrock now supports an Ultrafast service tier for GPT-6 Astra, priced at 6× standard.
Prices cross-checked against AWS docs and companion gateway PR.
Companion gateway PR (priceDimensions wiring): https://code.pan.run/airs/agent-gateway/backend/gateway-enterprise-node/-/merge_requests/2086