How tedivm/opencode-config works
Purpose and Runtime
This is a personal opencode CLI configuration repository, intended to populate ~/.config/opencode. It defines agent behavior, model/provider integration, reusable instruction skills, and custom prompt commands rather than an application service. The primary runtime is the OpenCode CLI, configured by opencode.jsonc, with persisted conversation state in dcp.jsonc.
Core Configuration Boundary
opencode.jsonc is the central integration point for the local vLLM OpenAI-compatible provider, the qwen3.6-27b model, LSP/formatting capabilities, Context7 MCP documentation lookup, and the @tarquinen/opencode-dcp plugin. AGENTS.md establishes global agent operating rules. Secrets and endpoint settings are deliberately external environment files rather than repository configuration.
Paths: opencode.jsonc, dcp.jsonc, AGENTS.md.
Agent Specialization
Role-specific agent prompts define delegated work patterns and boundaries: architecture design, repository research, and review. These are reusable subagent personas invoked by the OpenCode workflow, rather than executable processes.
Paths: agents/architect.md, agents/researcher.md, agents/reviewer.md.
Command Layer
Custom commands package recurring, user-invoked workflows: repository critique, OpenSpec proposal/spec drift analysis, GitHub Action upgrades, response compression, and architecture/design review. Commands orchestrate configured agents and skills through prompt instructions; they are the main interactive entry points beyond the base CLI.
Paths: commands/repo-critique.md, commands/openspec-review.md, commands/document-architecture.md.
Skill Library
Each skills/*/SKILL.md is a domain workflow contract that supplies procedural instructions, conventions, and sometimes supporting assets or reference material. Major domains include project bootstrapping, code exploration, command/skill authoring, Python scaffolding, OpenSpec setup, PR creation, GitHub operations, JSON processing, quality validation, and design-system work.
Paths: skills/bootstrapping-plan/SKILL.md, skills/exploring-code/SKILL.md, skills/robs-design/SKILL.md.
Skill Assets and Reference Knowledge
Some skills carry executable or static supporting material. Markdown conversion invokes a Python integration with Microsoft MarkItDown; the Rob’s theme skill supplies CSS tokens/layout/component assets; architecture/design skills include reference patterns for FastAPI, Celery, SQLAlchemy, Pydantic, and Typer. These resources constrain generated output but are not a shared application runtime.
Paths: skills/converting-to-markdown/scripts/markitdown-llm.py, skills/robs-theme/assets/variables.css, skills/robs-design/references/fastapi-routes.md.
Installation and Validation
make install installs snip, an output-compression dependency used by the configuration/workflows. Repository validation is implemented in Node.js and invoked by the Makefile and CI. GitHub Actions enforce formatting and validation on changes.
Paths: Makefile, scripts/validate.js, .github/workflows/validate.yml.
External Services
The configuration depends on a locally hosted vLLM server through an OpenAI-compatible API, Context7 via MCP for documentation retrieval, GitHub through gh-oriented skills/commands, and the DCP plugin for conversation persistence. Credentials and host data are expected from untracked files such as .llm_host, .openai_api_key, and .context7-api-key.
Main entry points: opencode.jsonc OpenCode configuration · SKILL.md Rob's design skill · Makefile Make targets · validate.js Configuration validator
Components 27
OpenCode Runtime
- OpenCode CLI · Loads this repository as the user configuration.
- OpenCode configuration · Central provider, capability, MCP, and plugin integration point.
opencode.jsonc - Global agent rules
AGENTS.md - Conversation state
dcp.jsonc - DCP plugin · Persists conversation state through the configured plugin.
Workflow Library
- Specialist agents · Architecture, research, and review delegation roles.
- Architect persona
agents/architect.md - Researcher persona
agents/researcher.md - Reviewer persona
agents/reviewer.md - Custom commands · User-invoked prompts that orchestrate agents and skills.
- Repository critique
commands/repo-critique.md - OpenSpec review
commands/openspec-review.md - Architecture review
commands/document-architecture.md - Skill library · Reusable procedural guidance for generation and operations.
- Bootstrapping skill
skills/bootstrapping-plan/SKILL.md - Code exploration skill
skills/exploring-code/SKILL.md - Rob's design skill
skills/robs-design/SKILL.md
Skill Assets
- MarkItDown integration · Converts content to Markdown using Microsoft MarkItDown.
skills/converting-to-markdown/scripts/markitdown-llm.py - Theme CSS tokens
skills/robs-theme/assets/variables.css - FastAPI route patterns
skills/robs-design/references/fastapi-routes.md
Installation & Validation
- Make targets · Installs dependencies and invokes validation.
Makefile - Configuration validator
scripts/validate.js - Validation workflow · Enforces formatting and validation on changes.
.github/workflows/validate.yml
External Integrations
- Local vLLM server
- Context7
- GitHub · Accessed by gh-oriented workflows.
- Untracked environment files · Provides host and API credentials outside repository configuration.
Connections 26
- OpenCode CLI → OpenCode configuration: loads
- OpenCode CLI → Global agent rules: follows
- OpenCode configuration → Local vLLM server: configures provider
- Untracked environment files → OpenCode configuration: supplies credentials
- OpenCode configuration → Context7: configures MCP
- OpenCode configuration → DCP plugin: enables
- DCP plugin → Conversation state: persists
- OpenCode CLI → Custom commands: invokes
- Custom commands → Repository critique: includes
- Custom commands → OpenSpec review: includes
- Custom commands → Architecture review: includes
- Custom commands → Specialist agents: delegates to
- Specialist agents → Architect persona: includes
- Specialist agents → Researcher persona: includes
- Specialist agents → Reviewer persona: includes
- Custom commands → Skill library: uses
- Skill library → Bootstrapping skill: includes
- Skill library → Code exploration skill: includes
- Skill library → Rob's design skill: includes
- Rob's design skill → Theme CSS tokens: uses
- Rob's design skill → FastAPI route patterns: consults
- Skill library → MarkItDown integration: uses
- Custom commands → GitHub: operates through gh
- Make targets → Configuration validator: runs
- Validation workflow → Configuration validator: runs
- Make targets → OpenCode CLI: installs configuration dependencies