Add support for grok-4.20-0309-reasoning model#25930
Add support for grok-4.20-0309-reasoning model#25930ishaan-berri merged 1 commit intolitellm_internal_stagingfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Greptile SummaryThis PR adds the stable
Confidence Score: 4/5Safe to merge after adding the required test — pricing values and capabilities are accurate per official xAI docs. One P1 finding remains: no test was added despite CLAUDE.md stating it is a hard requirement. The metadata itself is correct (pricing matches xAI docs, context window is accurate, capabilities are consistent with the beta predecessor). No files have defects; the gap is a missing test file in tests/test_litellm/.
|
| Filename | Overview |
|---|---|
| model_prices_and_context_window.json | Adds xai/grok-4.20-0309-reasoning with correct pricing and context window values; no tests added. |
| litellm/model_prices_and_context_window_backup.json | Mirror of the root JSON file; identical entry added, consistent with existing backup sync pattern. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A["User calls litellm with xai/grok-4.20-0309-reasoning"] --> B["litellm.get_model_info()"]
B --> C["Loads model_prices_and_context_window.json"]
C --> D{"Model key found?"}
D -- Yes --> E["Returns model metadata\n input cost, output cost,\n context window, capabilities"]
D -- No --> F["KeyError / unknown model"]
E --> G["Cost tracking and routing\nuse returned metadata"]
Reviews (1): Last reviewed commit: "Add support for grok-4.20-0309-reasoning..." | Re-trigger Greptile
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
bd5f560
into
litellm_internal_staging
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:
Screenshots / Proof of Fix
Type
🆕 New Feature
🐛 Bug Fix
🧹 Refactoring
📖 Documentation
🚄 Infrastructure
✅ Test
Changes