Skip to content

feat(llm): add Grok (xAI) integration (#179)#236

Merged
ankaisen merged 5 commits intoNevaMind-AI:mainfrom
david-mamani:feat/grok-provider
Jan 16, 2026
Merged

feat(llm): add Grok (xAI) integration (#179)#236
ankaisen merged 5 commits intoNevaMind-AI:mainfrom
david-mamani:feat/grok-provider

Conversation

@david-mamani
Copy link
Contributor

@david-mamani david-mamani commented Jan 13, 2026

Description

Closes #179 (2026 Model Provider Extensions - Grok)

This PR implements full support for Grok (xAI) as an LLM provider, compliant with the strict CI/CD requirements (Python 3.13, uv locked dependencies, and Typed Python).

Changes

  • Feat: Added GrokBackend in src/memu/llm/backends/grok.py (inherits from OpenAI base).
  • Config: Updated settings.py to support provider="grok" (Defaults to https://api.x.ai/v1).
  • Deps: Added openai to pyproject.toml and updated uv.lock.
  • Docs: Added setup guide in docs/providers/grok.md.
  • Tests: Added tests/llm/test_grok_provider.py with unittest.mock to simulate API responses without network calls.

Verification

  • uv run pytest passed (3 tests).
  • uv run ruff check passed.
  • uv sync ensures lockfile integrity.

Checklist

  • My code follows the code style of this project (ruff formatted).
  • I have updated the documentation accordingly.
  • I have added tests that prove my fix is effective.

resolves #179

Copy link
Collaborator

@ankaisen ankaisen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@david-mamani Thank you! LGTM 👍

@ankaisen ankaisen merged commit 1e16309 into NevaMind-AI:main Jan 16, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants