feat(cost): add baseten model api pricing entries - #25358
Conversation
Add Baseten Model API pricing entries for Nemotron, GLM, Kimi, GPT OSS, and DeepSeek models with validated model slugs. Include a focused regression test to assert provider and per-token pricing values. Made-with: Cursor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Greptile SummaryThis PR adds pricing entries for 11 new Baseten Model API models — Nemotron, MiniMax, GLM (3 variants), Kimi (3 variants), GPT OSS, and DeepSeek (2 variants) — to both
Confidence Score: 5/5Safe to merge — pure data addition with matching unit test coverage and no logic changes. All changes are additive: 11 new pricing entries in both JSON files and a new mock test that verifies them. The test uses LITELLM_LOCAL_MODEL_COST_MAP=True so no network calls are made. Existing test assertions were reformatted by Black with no semantic changes. No P0 or P1 issues found. No files require special attention.
|
| Filename | Overview |
|---|---|
| model_prices_and_context_window.json | 11 new baseten model pricing entries added; all follow the existing pattern for baseten (cost-only, no context window fields); pricing values are internally consistent |
| litellm/model_prices_and_context_window_backup.json | Identical 11 entries added as in the primary JSON file; kept in sync correctly |
| tests/test_litellm/test_cost_calculator.py | New mock-only test added for all 11 baseten entries; uses LITELLM_LOCAL_MODEL_COST_MAP=True (no network calls); remaining changes are Black reformatting with no logic changes |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[PR: Add Baseten Pricing Entries] --> B[model_prices_and_context_window.json]
A --> C[model_prices_and_context_window_backup.json]
A --> D[tests/test_litellm/test_cost_calculator.py]
B --> E[11 new baseten/ entries]
C --> E
E --> E1[baseten/nvidia/Nemotron-120B-A12B]
E --> E2[baseten/MiniMaxAI/MiniMax-M2.5]
E --> E3[baseten/zai-org/GLM-5/4.7/4.6]
E --> E4[baseten/moonshotai/Kimi-K2.5/Thinking/Instruct]
E --> E5[baseten/openai/gpt-oss-120b]
E --> E6[baseten/deepseek-ai/DeepSeek-V3.1/V3-0324]
D --> F[test_baseten_model_api_pricing_entries]
F --> G{LITELLM_LOCAL_MODEL_COST_MAP=True}
G --> H[litellm.get_model_cost_map url=empty]
H --> I[Assert all 11 entries present with correct provider + pricing]
Reviews (1): Last reviewed commit: "feat(cost): add baseten model api pricin..." | Re-trigger Greptile
- Add 8 content PRs that merged directly to the release branch outside the listed staging PRs: #23769 (Ramp callback), #25252 (JWT OAuth2 override), #25254 (AWS GovCloud mode), #25258 (batch-limit cleanup), #25334 (router custom_llm_provider), #25345 (Triton embeddings), #25347 (tag-based routing), #25358 (Baseten pricing attribution) - Add @kedarthakkar to new contributors (first-ever PR via #23769) - Update RELEASE_NOTES_GENERATION_INSTRUCTIONS: require walking git log range between release tags in addition to staging PRs, and verify new-contributor status per author rather than trusting the GH release body floor
- Add 8 content PRs that merged directly to the release branch outside the listed staging PRs: #23769 (Ramp callback), #25252 (JWT OAuth2 override), #25254 (AWS GovCloud mode), #25258 (batch-limit cleanup), #25334 (router custom_llm_provider), #25345 (Triton embeddings), #25347 (tag-based routing), #25358 (Baseten pricing attribution) - Add @kedarthakkar to new contributors (first-ever PR via #23769) - Update RELEASE_NOTES_GENERATION_INSTRUCTIONS: require walking git log range between release tags in addition to staging PRs, and verify new-contributor status per author rather than trusting the GH release body floor
Add Baseten Model API pricing entries for Nemotron, GLM, Kimi, GPT OSS, and DeepSeek models with validated model slugs. Include a focused regression test to assert provider and per-token pricing values. Made-with: Cursor
- Add 8 content PRs that merged directly to the release branch outside the listed staging PRs: BerriAI#23769 (Ramp callback), BerriAI#25252 (JWT OAuth2 override), BerriAI#25254 (AWS GovCloud mode), BerriAI#25258 (batch-limit cleanup), BerriAI#25334 (router custom_llm_provider), BerriAI#25345 (Triton embeddings), BerriAI#25347 (tag-based routing), BerriAI#25358 (Baseten pricing attribution) - Add @kedarthakkar to new contributors (first-ever PR via BerriAI#23769) - Update RELEASE_NOTES_GENERATION_INSTRUCTIONS: require walking git log range between release tags in addition to staging PRs, and verify new-contributor status per author rather than trusting the GH release body floor
- Add 8 content PRs that merged directly to the release branch outside the listed staging PRs: BerriAI#23769 (Ramp callback), BerriAI#25252 (JWT OAuth2 override), BerriAI#25254 (AWS GovCloud mode), BerriAI#25258 (batch-limit cleanup), BerriAI#25334 (router custom_llm_provider), BerriAI#25345 (Triton embeddings), BerriAI#25347 (tag-based routing), BerriAI#25358 (Baseten pricing attribution) - Add @kedarthakkar to new contributors (first-ever PR via BerriAI#23769) - Update RELEASE_NOTES_GENERATION_INSTRUCTIONS: require walking git log range between release tags in addition to staging PRs, and verify new-contributor status per author rather than trusting the GH release body floor
Add Baseten Model API pricing entries for Nemotron, GLM, Kimi, GPT OSS, and DeepSeek models with validated model slugs. Include a focused regression test to assert provider and per-token pricing values.
Fixes LIT-2147
Relevant issues
Pre-Submission checklist
Please complete all items before asking a LiteLLM maintainer to review your PR
tests/test_litellm/directory, Adding at least 1 test is a hard requirement - see detailsmake test-unit@greptileaiand received a Confidence Score of at least 4/5 before requesting a maintainer reviewDelays in PR merge?
If you're seeing a delay in your PR being merged, ping the LiteLLM Team on Slack (#pr-review).
CI (LiteLLM team)
Branch creation CI run
Link:
CI run for the last commit
Link:
Merge / cherry-pick CI run
Links:
Type
🆕 New Feature
🐛 Bug Fix
🧹 Refactoring
📖 Documentation
🚄 Infrastructure
✅ Test
Changes