Linux Machine Setup Guide
Authoritative step-by-step guide for bootstrapping the full AI workflow on a fresh Linux machine after cloning this repo. Written for AI agents (Claude, Codex, Gemini) to execute directly. Run steps in order — ordering constraints are load-bearing. Full AI stack covered: Claude Code · opencode · pi · headroom · Gemini CLI · wiki toolchain (qmd + LightRAG)TL;DR — AI Agent Quickstart
Prerequisites
System packages
Node.js (via nvm)
ollama (local embeddings)
install.sh:
nomic-embed-text— embeddings for qmd and LightRAG
LLAMACPP_BASE_URL slot reserved, not wired yet) and later for embeddings, which stay on ollama until then (OpenCode has no embeddings endpoint).
Step 1: Clone repositories
Order matters. Dotfiles commits symlinks with absolute paths pointing to~/repos/llm-wiki. Clone llm-wiki first or stow creates broken symlinks in ~/.claude/rules/.
Step 2: Stow dotfiles
Each dotfiles module maps to a different AI tool’s config directory:Step 3: Set environment variables
Add to~/.zshrc:
source ~/.zshrc
Key uses by tool:
Step 4: Install AI tools
Claude Code
Pi (council Voice B + AFK loop worker)
opencode
Gemini CLI
~/.gemini/ (stowed in Step 2). On first use, authenticate:
Wiki toolchain (uv + wiki-chat/index/mcp + git hook + ollama models)
- Installs
uv(Python package manager via curl) - Copies
wiki-chat,wiki-index,wiki-mcp→~/.local/bin/ - Installs post-commit git hook (auto-runs qmd indexing after wiki commits)
- Pulls the ollama embedding model:
nomic-embed-text
ollama not found — start ollama serve first.
headroom (context compression)
Requiresuv from step above:
Step 5: First Claude Code run — plugin installation
~/.claude/settings.json:
Plugin cache:
~/.claude/plugins/cache/ — downloaded fresh, not in dotfiles.
The qmd CLI comes from the plugin, not npm. After this step, qmd is in PATH.
Step 6: Build wiki LightRAG index (one-time)
OPENCODE_GO_API_KEY_LIGHTRAG; without it wiki-index exits with an error before touching the index. A full build runs several LLM calls per page and can exhaust the plan’s 5-hour usage limit (limits), hence --yes.
Time: not measured with OpenCode Go.
Progress:
Step 7: Verify
Gotchas and ordering constraints
File ownership map
Related pages
- Headroom — context compression modes (proxy, wrap, library, MCP)
- Pi Agent (pi-mono) — pi CLI, council workflow, pueue delegation
- OpenCode — opencode TUI, headless API, warm-server pattern
- Lean Agentic Coding Workflow — how these tools compose in practice
- Council Pattern — when/how to invoke multi-vendor review