Skip to content

Add grok-4 and groq kimi-k2 models #2235

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
Jul 18, 2025

Conversation

zachmayer
Copy link
Contributor

@zachmayer zachmayer commented Jul 17, 2025

Extracted from #2211 for easier review.
Closes #2187

This PR adds support for new Grok and Groq models:

  • Add grok:grok-4 as a known model name
  • Add grok-4 plain model name support (with provider inference)
  • Add groq:moonshotai/kimi-k2-instruct to Groq preview models
  • Add test cases for grok model variants
  • Update CLI test to include grok provider

Both grok and groq models use existing OpenAI-compatible infrastructure, so this is primarily adding model names and test coverage.

- Add grok:grok-4 as a known model name
- Add grok-4 plain model name support (provider inference)
- Add groq:moonshotai/kimi-k2-instruct to Groq preview models
- Add test cases for grok model variants
- Update CLI test to include grok provider
@zachmayer
Copy link
Contributor Author

@DouweM the groq/grok changes are ready to review

@zachmayer
Copy link
Contributor Author

Would it make sense to make this PR just for the grok models? and then move the groq:moonshot/ stuff to a new PR or to #2211 ?

@zachmayer
Copy link
Contributor Author

Ok I think I responded to all the feedback here. Let me know how things look or if I need other changes.

@DouweM DouweM changed the title feat: add grok-4 and groq kimi-k2 model support Add grok-4 and groq kimi-k2 models Jul 18, 2025
@DouweM DouweM merged commit 3c43c2d into pydantic:main Jul 18, 2025
18 checks passed
@DouweM
Copy link
Contributor

DouweM commented Jul 18, 2025

@zachmayer Thanks Zach!

@zachmayer
Copy link
Contributor Author

Awesome thank you!

@zachmayer zachmayer deleted the feat/grok-groq-models branch July 18, 2025 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Official Support For XAI models (namely Grok 4)
2 participants