Agents
Agents
fai works with 16 coding agents. fai doesn't launch them. It runs alongside
whichever one you use. When you run fai in a project, it:
- Writes your project context into the native rules file of every agent it has detected
- Keeps running in watch mode, reading agent logs as you work (where supported)
- Feeds everything captured into synthesis
Then start your agent the way you normally would, in the same directory:
fai # in one terminal, leave it running
claude # or cursor, codex, goose, or open your IDE extension
Stop fai with Ctrl+C when you're done.
How context injection works
When fai starts, it writes your accumulated project context into each agent's
native rules/instructions file. The block is idempotent — re-running fai
refreshes the block in-place without duplicating it.
Cursor → .cursor/rules/fai-context.mdc
Cline → .clinerules
Codex → AGENTS.md
This happens for every agent fai has detected, on every fai invocation, not
just the one you plan to use. Any agent you open after running fai already
has current context.
Context injection is error-tolerant. One agent's rules file failing to write never delays session launch or blocks other agents.
15 of the 16 agents (all but OpenClaw) receive context injection into their
native rules files. 11 of those (Claude, Cursor, Cline, Copilot, Windsurf,
Codex, Gemini, JetBrains, Goose, Antigravity, Continue) also get MCP server
configuration written to user-level global paths on each session start, all
using type: 'http'. Use fai mcp install to extend this auto-config to
third-party MCP servers — see MCP Server.
Switch without losing context. Your vault follows you across tools. Run
fai, work in Claude Code, then open Cursor in the same project. Your
accumulated context is already there.
CLI agents
Start these in your terminal as usual. fai reads their logs while it watches.
| Agent | Start with | Rules file | Log capture |
|---|---|---|---|
| Claude Code | claude | CLAUDE.md (via hooks) | ✅ Real-time (native hooks) |
| Codex CLI | codex | AGENTS.md | ✅ ~/.codex/sessions/YYYY/MM/DD/rollout-*.jsonl |
| OpenCode | opencode | .opencode-fai-context.md | ✅ .opencode/*.jsonl in project |
| Goose | goose | .goosehints | Deferred (SQLite) |
| Aider | aider | .aider-fai-context.md | ✅ .aider.chat.history.md |
| Gemini CLI | gemini | GEMINI.md | ✅ ~/.gemini/tmp/<hash>/chats/*.jsonl |
| Amazon Q | q | .amazonq-fai-context.md | Deferred |
| OpenMono | openmono | OPENMONO.md | Deferred (transcripts) |
GUI agents
Open the IDE yourself. The rules file is already written, and fai keeps watching while you work.
| Agent | Start with | Rules file | Log capture |
|---|---|---|---|
| Windsurf | windsurf {cwd} | .windsurf/rules/fai-context.md | ✅ ~/.codeium/windsurf/cascade/ |
| Cursor | cursor {cwd} | .cursor/rules/fai-context.mdc | Deferred (workspace SQLite) |
| Antigravity | agy {cwd} | AGENTS.md (free — already written by fai) | ⏳ Phase 3 (.pb binary) |
Extension agents
fai writes the rules file. Open the extension in your IDE as usual.
| Agent | Rules file | Log capture |
|---|---|---|
| Cline | .clinerules | ✅ {AppData}/Code/.../saoudrizwan.claude-dev/tasks/ |
| Continue.dev | .continuerules | ✅ ~/.continue/sessions/*.jsonl |
| GitHub Copilot | .github/copilot-instructions.md | Deferred (workspace-scoped) |
| JetBrains AI | .aiassistant/rules/fai-context.md | Deferred |
Daemon agent
| Agent | Integration | Log capture |
|---|---|---|
| OpenClaw | Detected when ~/.openclaw exists. fai doesn't install capture hooks for it | Not currently captured |
Detecting installed agents
fai detect --agents
Scans which agent binaries are on your PATH. Results cached at ~/.fai/detect.json.
Extension agents (Cline, Continue, Copilot, JetBrains) are always listed since they
don't require a binary.
Configure your synthesis provider
Agents use your configured synthesis provider to distill session captures into knowledge. Run:
fai synthesize
To configure which model powers synthesis. See Local Models → for setup with Ollama, LM Studio, or cloud API keys.
Right AI for the Job → — deeper look at agent categories