Skip to content
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

Add xAI #1017

Merged
merged 2 commits into from
Dec 10, 2024
Merged

Add xAI #1017

merged 2 commits into from
Dec 10, 2024

Conversation

winsonluk
Copy link
Contributor

@winsonluk winsonluk commented Dec 10, 2024

Working with xAI grok-beta

Setup:

export XAI_API_KEY=<your xai api key>
pip3 install langchain-xai

Config (example xai.json)

{"RETRIEVER": "exa", "EMBEDDING": "openai:text-embedding-3-small", "FAST_LLM": "xai:grok-beta", "SMART_LLM": "xai:grok-beta", "STRATEGIC_LLM": "xai:grok-beta", ...}

GPTResearcher initialization

researcher = GPTResearcher(query=query, report_type=report_type, verbose=True, headers={'retriever': 'exa'}, config_path='./config/xai.json')

@winsonluk
Copy link
Contributor Author

@assafelovic just a simple integration with langchain-xai - lmk if there's anything I missed

@assafelovic
Copy link
Owner

This is great thank you! I'll try it out!

@assafelovic assafelovic merged commit 27f4703 into assafelovic:master Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants