Match litellm.completion supported model parameters with proxy model info - #27720
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Greptile SummaryThis PR fixes a mismatch between the model identifier passed to
Confidence Score: 5/5The change is a single-line conditional in The fix is narrow and well-tested: No files require special attention.
|
| Filename | Overview |
|---|---|
| litellm/main.py | Uses base_model from model_info (when present) as the model arg to get_optional_params, so proxy model aliases correctly inherit supported parameter sets from their base model. |
| tests/test_litellm/test_main.py | Adds a parametrized mock-only test verifying that get_optional_params receives the base_model value when model_info contains one, and falls back to the stripped model name otherwise. |
Reviews (2): Last reviewed commit: "Formatting" | Re-trigger Greptile
|
🤖 litellm-agent: This PR is currently BLOCKED from merge. Score: 3/5 ❌ Why blocked:
Details: Score docked for: 1 PR-related CI failure (triage-llm-invalid: schema validation failed — manual review required). Fix the issues above and push an update — the bot will re-review automatically.
|
fc8a9a3
into
BerriAI:litellm_internal_staging
…info (BerriAI#27720) * Use base_model for supported optional params * Add test * Formatting
Relevant issues
Fixes #27717
Linear ticket
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
🐛 Bug Fix
Changes