Mistral
Mistral AI provides state-of-the-art open and proprietary models with strong multilingual capabilities.
Installation
The Mistral extra is included in the [all] install. If you installed the minimal bundle:
cd ~/.monoclaw/monoclaw-runtime
uv pip install -e ".[mistral]"
Setup
- Get an API key from console.mistral.ai
- Configure MonoClaw:
monoclaw config set MISTRAL_API_KEY "your-key"
monoclaw config set model.default "mistral/mistral-large-latest"
Available models
| Model | Context | Best for |
|---|---|---|
mistral-large-latest | 128K | General purpose, reasoning |
mistral-medium-latest | 128K | Balanced performance/cost |
mistral-small-latest | 128K | Fast, cost-effective |
codestral-latest | 256K | Code generation |
mistral-embed | 8K | Embeddings |
Configuration
model:
default: "mistral/mistral-large-latest"
mistral:
api_key: "${MISTRAL_API_KEY}"
temperature: 0.7
max_tokens: 4096
Troubleshooting
| Problem | Fix |
|---|---|
| "Invalid API key" | Generate a new key from the Mistral console |
| "Model not found" | Check the model name matches the API documentation |
| High latency | Use mistral-small for faster responses |