Skip to content

feat(models): register Grok 4.3 for reasoning effort - #2890

Closed
IsmaelMartinez wants to merge 2 commits into
The-PR-Agent:mainfrom
IsmaelMartinez:feat/grok-registry-4-20-4-3
Closed

IsmaelMartinez wants to merge 2 commits into
The-PR-Agent:mainfrom
IsmaelMartinez:feat/grok-registry-4-20-4-3

Conversation

@IsmaelMartinez

@IsmaelMartinez IsmaelMartinez commented Aug 30, 2026 •

Copy link
Copy Markdown
Collaborator

Follow-up promised on #2530, which is now closed in favour of the registry route. Credit to @Kyzcreig, whose PR found the gap and who called the scope honestly.

xai/grok-4.3 and grok-4.3-latest support reasoning_effort on the pinned litellm 1.98.0 but are in neither SUPPORT_REASONING_EFFORT_MODELS nor GROK_REASONING_EFFORT_LEVELS, so a configured effort is forwarded unclamped. MAX_TOKENS needs no row: LiteLLM's bundled cost map already carries both at 1M, and since #3220 main only pins models absent from it.

Scope is narrower than I said on that thread, deliberately. I had promised the grok-4.20 ids too, and they are not safe to add here:

  • xai/grok-4.20-multi-agent is absent from litellm 1.98.0's bundled cost map and present only in the map litellm fetches at import, so get_supported_openai_params reports reasoning_effort supported with a network and unsupported without one. Registering it would make our behaviour depend on whether the process reached the network at start-up.
  • The 4.20 family splits into -reasoning and -non-reasoning ids. A family-level add would grant reasoning_effort to models that explicitly do not do reasoning.

Levels mirror 4.5 rather than 4.6: xhigh is granted only where it is published, and I have no source putting it on 4.3.

Verified by running: 72 pass in test_litellm_reasoning_effort.py, and reverting only pr_agent/algo/__init__.py to main with the new rows kept turns all five red with real assertion failures. Full unit suite 2701 passed, which is main's 2696 plus these five. uvx ruff check clean.

Adds xai/grok-4.3 and grok-4.3-latest to the reasoning-effort registry
and MAX_TOKENS, so a configured effort is clamped rather than dropped.
Split out of The-PR-Agent#2530.

Co-authored-by: Kyzcreig <Kyzcreig@users.noreply.github.com>
@IsmaelMartinez

Copy link
Copy Markdown
Collaborator Author

/agentic_review

1 similar comment
@IsmaelMartinez

Copy link
Copy Markdown
Collaborator Author

/agentic_review

@qodo-code-review

qodo-code-review Bot commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review
  • Author self-review: I have reviewed the code review findings, and addressed the relevant ones.

Grey Divider

Tip of the day
💡 Did you know, you can ask Qodo to dismiss a finding you disagree with, with your reason on record

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Previous reviews

Review updated until commit 2a8bdcf ⚖️ Balanced

Results up to commit N/A


Sorry, something went wrong


We weren't able to complete the code review on our side. Please try again manually by commenting /agentic_review on this PR.


Grey Divider

Qodo Logo

Drop the two MAX_TOKENS rows: LiteLLM's bundled cost map now carries xai/grok-4.3 at 1M, and main only pins models absent from it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LpThzLDt7pgLathoucBkcL
@qodo-free-for-open-source-projects

Copy link
Copy Markdown
Contributor

Code review by qodo was updated up to the latest commit 2a8bdcf

@IsmaelMartinez

Copy link
Copy Markdown
Collaborator Author

Closing in favour of a community pick-up: main needs an approving review from a second maintainer and I cannot approve my own PR, so this has sat green since 30 August. The change and its tests stay on feat/grok-registry-4-20-4-3 as a reference implementation, and #3413 is open as help wanted for anyone who wants to land it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants