Reference configuration for OpenCode, published alongside my blog posts on how I learned to use AI and my actual AI development workflow:
- My Thoughts on AI, Part 1: Fears, Opinions, and Mental Journey
- My Thoughts on AI, Part 2: Agent Setup, Workflow, and Tools
This is a sanitized snapshot of my actual daily-use config. API keys and personal paths have been replaced with placeholders.
Drop-in contents for ~/.config/opencode/. Key pieces:
AGENTS.md— Global behavioral rules: response style, thinking protocols, git policy, coding standards, documentation workflowopencode.json— Model preferences, MCP servers, permissions, plugin configagent/— Subagent definitions (docs writer, orchestrator, code reviewer, test engineer)command/— Slash commands (/context,/progress,/architecture, etc.)skill/— 23 domain-specific knowledge modules loaded on demandplugin/— Custom tool extensions (permission checker, context-aware caching, session search, token usage analysis)scripts/— Helper utilities for dev-plans management, session extraction, cost tracking
Example structure for a separate work-tracking repo. See dev-plans/README.md.
- Copy
config/contents to~/.config/opencode/ - Edit
opencode.json— add your API keys, adjust model preferences - Edit
AGENTS.md— customize the "About the User" section and path references - Edit
scripts/config.json— set your dev-plans path and project mappings - Search for
YOUR_placeholders across all files and replace with your values
MIT