Overview of the OpenCode 7 Building Blocks
masterThe OpenCode harness is structured into seven distinct layers located within the .opencode/ directory and the repository root. These layers teach the AI assistant about MockServer's specific boundaries, conventions, and infrastructure:
- Config (
opencode.jsonc): Root configuration for models, permissions, and agents. - Model Strategy (
opencode.jsonc): Assigns the right model to the right task. - Agents (
.opencode/agents/*.md): Specialist sub-agents with least-privilege access. - Rules (
.opencode/rules/*.md): Guardrails that are always enforced. - Skills (
.opencode/skills/*/SKILL.md): Reusable multi-step workflows. - Commands (
.opencode/commands/*.md): Slash shortcuts for routing tasks. - Plugins & Tools (
.opencode/plugins/*.ts): Session hooks and external integrations.