Skip to content

Conversation

danielmklein
Copy link

Title

Update Sonnet 4 configurations to support million-token context windows (with correct pricing)

Relevant issues

#13724
#13759

Pre-Submission checklist

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

  • I have Added testing in the tests/litellm/ directory, Adding at least 1 test is a hard requirement - see details
  • I have added a screenshot of my new test passing locally
  • My PR passes all unit tests on make test-unit
  • My PR's scope is as isolated as possible, it only solves 1 specific problem

Type

🐛 Bug Fix

Changes

This updates the relevant elements in model_prices_and_context_window.json and litellm/model_prices_and_context_window_backup.json to reflect the token limits and pricing tiers for long-context Sonnet 4.

Copy link

vercel bot commented Sep 17, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
litellm Error Error Sep 17, 2025 3:37pm

"cache_read_input_token_cost": 3e-07,
"input_cost_per_token": 3e-06,
"input_cost_per_token_above_200k_tokens": 6e-06,
"output_cost_per_token_above_200k_tokens": 2.25e-05,
Copy link
Contributor

Choose a reason for hiding this comment

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

where are you seeing this? @danielmklein

Copy link
Author

Choose a reason for hiding this comment

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

@krrishdholakia This pricing specifically? It's the "long context pricing" described here. Let me know if that's not what you're asking about!

Copy link
Contributor

Choose a reason for hiding this comment

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

hey @danielmklein this pricing page is for the anthropic api. But the change you're suggesting is for bedrock.

Can you confirm the bedrock pricing is the same as that of the anthropic api in this case?

Copy link
Author

Choose a reason for hiding this comment

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

@krrishdholakia Yes, the bedrock pricing page for long context Sonnet 4 matches these figures: https://aws.amazon.com/bedrock/pricing/ (unfortunately they don't support linking directly to the relevant table)

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.

2 participants