7-stage workflow pipeline for OpenCode: plan → reuse → dispatch → test → review → docs → deliver with directory standards
Boss Mode turns OpenCode into a disciplined engineering workflow. Instead of jumping straight into coding, it forces a structured pipeline that catches mistakes early and keeps your project clean.
- 7-Stage Pipeline — necessity check → directory blueprint → write plan → check reuse → dispatch subagents → test loop → forced review → auto-docs → delivery
- 11 Specialized Agents — boss (orchestrator) + api-clone, api-server, reverse (API work), db, browser, frontend (implementation), review (code review), test (test execution), docs (documentation), ops (deployment)
- Directory Standards — keeps your project root clean with 10 iron rules for file placement
- Quality Gates — no skipping: plan must be written, reuse must be checked, review must pass, docs must be updated
# Windows (PowerShell 5.1+)
irm https://raw.githubusercontent.com/baseredge/opencode-boss-mode/main/install.ps1 | iex# Mac / Linux
curl -fsSL https://raw.githubusercontent.com/baseredge/opencode-boss-mode/main/install.sh | bashAfter restarting OpenCode, boss will appear in the mode selector alongside build and plan.
# Windows — install to current project only
irm https://raw.githubusercontent.com/baseredge/opencode-boss-mode/main/install.ps1 | iex# Mac / Linux — install to current project only
curl -fsSL https://raw.githubusercontent.com/baseredge/opencode-boss-mode/main/install.sh | bash- Copy
agents/*.mdto~/.config/opencode/agents/(global) or.opencode/agents/(project) - Copy
templates/AGENTS.mdto your project root - Add to
opencode.json:{ "instructions": ["AGENTS.md"], "default_agent": "boss" }
# Keep build as the default, but boss is still available in the mode selector
irm https://.../install.ps1 | iex # then manually keep default_agent: "build"After installing, restart OpenCode. You'll see boss in the mode selector (bottom of the window or via Ctrl+K, Ctrl+M).
Select boss when starting a non-trivial feature:
@boss I need to add a user registration API with database storage
The boss will:
- Check if this is trivial (typo fix → skip plan)
- Plan directory layout for new files
- Write a plan to
docs/plans/ - Ask you to confirm → then dispatch subagents
- Force testing + review before delivery
Type @ in the chat to see all available subagents:
@api-clone— External API client (requires packet capture)@api-server— Internal API endpoints@reverse— JS reverse engineering / signature cracking@db— Database schema & queries@browser— Browser automation (DrissionPage, Playwright, CDP)@frontend— Frontend UI/UX@test— Run tests (auto-dispatched by boss)@review— Code review (auto-dispatched by boss)@docs— Documentation (auto-dispatched by boss)@ops— Build & deploy scripts
opencode-boss-mode/
├── agents/ # 11 agent definitions
│ ├── boss.md (primary) # Workflow orchestrator
│ ├── api-clone.md (subagent) # External API client cloning
│ ├── api-server.md (subagent) # Internal API endpoints
│ ├── reverse.md (subagent) # JS reverse engineering
│ ├── db.md (subagent) # Database schema & queries
│ ├── browser.md (subagent) # Browser automation
│ ├── frontend.md (subagent) # Frontend UI/UX
│ ├── test.md (subagent) # Test execution
│ ├── review.md (subagent) # Code review
│ ├── docs.md (subagent) # Documentation
│ └── ops.md (subagent) # Build & deploy
├── templates/ # Project bootstrap templates
│ ├── AGENTS.md # Project-level AI instructions
│ └── opencode.json # Base OpenCode config
├── install.ps1 # Windows install script
├── install.sh # Mac/Linux install script
└── README.md # This file
- OpenCode — Desktop or CLI, any version with agent support
Other AI coding assistants jump straight to code. Boss Mode enforces:
| Aspect | Default AI | Boss Mode |
|---|---|---|
| Before coding | Starts writing | Writes a plan first |
| Code reuse | May rewrite existing code | Searches project first |
| Testing | Optional | Mandatory loop |
| Code review | None | Forced per delivery |
| Directory | Files scattered | Standards enforced |
| Documentation | None | Auto-maintained |
- AGENTS.md in your project root is the single source of truth for directory standards. Edit it to match your project's conventions.
- Each agent prompt can be customized by editing the
.mdfiles in~/.config/opencode/agents/or.opencode/agents/. - When standards change,
@docscan propagate updates across all agent prompts.
MIT