Local Models
fai works with any OpenAI-compatible endpoint. You don't need Claude. You don't need any API key at all — Ollama is free and runs entirely on your machine.
Local providers
Install any of these, then run fai detect — fai finds them automatically.
| Provider | Default port | Get it |
|---|---|---|
| Ollama | 11434 | ollama.ai |
| LM Studio | 1234 | lmstudio.ai |
| LocalAI | 8080 | localai.io |
Recommended for most users: Ollama + a 7B coding model (e.g. qwen2.5-coder:7b).
Cloud API keys (optional)
Set these env vars if you have API keys:
| Env var | Provider |
|---|---|
OPENROUTER_API_KEY | OpenRouter — access to many models including Claude |
GROQ_API_KEY | Groq — very fast inference, generous free tier |
OPENAI_API_KEY | OpenAI |
Note:
ANTHROPIC_API_KEYis not supported directly — the Anthropic API is not OpenAI-compatible. To use Claude models, setOPENROUTER_API_KEYinstead.
Detecting your setup
fai detect
Scans local ports and env vars. Prints what's installed and reachable. Cached
at ~/.fai/detect.json.
Useful flags:
fai detect --models models and API keys only
fai detect --agents coding agents only
fai detect --verify re-scan and verify each endpoint is reachable
Configuring synthesis
fai synthesize
Opens an interactive wizard to pick your synthesis provider. fai picks the best available option in this order:
- Ollama (local, free)
- LM Studio (local, free)
- LocalAI (local, free)
- OpenRouter (OPENROUTER_API_KEY)
- Groq (GROQ_API_KEY)
- OpenAI (OPENAI_API_KEY)
- claude-code (if
claudeis on your PATH) - capture-only (no synthesis — sessions still capture, synthesis runs later)
To skip the wizard and auto-configure from whatever's detected:
fai synthesize --non-interactive
What synthesis does
Synthesis distills your session captures — conversations, decisions, patterns — into structured knowledge that persists in your vault. Without a synthesis provider configured, fai still captures everything; synthesis just runs later when a provider is available.
The capture-only fallback means fai is never blocked — your work is always
preserved.
Commands → — full fai command reference Agents → — configure which AI tool to use