Note (2026-05-14, supersession banner). Example model IDs in code blocks below (
claude-sonnet-4-20250514,claude-haiku-4-20250514,claude-opus-4-20250514) are historical and produceConfigInvalidErroragainst OpenCode v1.14.30+. As of 0.10.1, no model IDs are hardcoded in agent configs - all agents inherit from top-levelmodel(currentlyopencode-go/glm-5.1). The ADR text itself is preserved unchanged. See.serena/memories/CORE-02-PROJECT-SHAPE.mdfor current config facts.
---
name: skill-name
description: Russian-leading description for auto-routing. EN triggers: english keywords.
---
# Skill Title
Body content in Markdown...name- required, 1-64 chars, lowercase alphanumeric + single hyphens, must match directory namedescription- required, 1-1024 chars, specific enough for agent to choose correctlylicense- optionalcompatibility- optionalmetadata- optional string-to-string map- NO
allowed-tools, NOdisable-model-invocation, NOmodel, NOeffort, NOmaxTurns, NOpaths, NOcontext, NOagent - Tool routing is done through AGENTS.md instructions and agent
permissionconfig
OpenCode searches these locations:
- Project:
.opencode/skills/*/SKILL.md - Global:
~/.config/opencode/skills/*/SKILL.md - Claude-compatible:
.claude/skills/*/SKILL.mdand~/.claude/skills/*/SKILL.md - Agent-compatible:
.agents/skills/*/SKILL.mdand~/.agents/skills/*/SKILL.md
---
description: Agent description (required)
mode: subagent
model: anthropic/claude-sonnet-4-20250514
temperature: 0.1
steps: 36
permission:
edit: deny
bash:
"*": ask
"git diff": allow
"git log*": allow
webfetch: deny
read: allow
glob: allow
grep: allow
lsp: allow
color: blue
prompt: |
You are a code reviewer. Focus on security, performance, and maintainability.
---
Additional prompt content...description- requiredmode-primaryorsubagentmodel- provider/model-id format (e.g.,anthropic/claude-sonnet-4-20250514)temperature- 0.0-1.0top_p- 0.0-1.0steps- max agentic iterations (replaces deprecatedmaxSteps)permission- granular allow/ask/deny with glob patternshidden- boolean, hides from @ autocomplete for subagentscolor- hex color or theme color nameprompt- custom system prompt (can use{file:./prompts/build.txt}reference)- Additional keys are passed through to the provider as model options
| Key | Tools it gates |
|---|---|
read |
read |
edit |
write, edit, apply_patch |
glob |
glob |
grep |
grep |
list |
list |
bash |
bash |
task |
task |
external_directory |
Any tool that reads/writes outside project worktree |
todowrite |
todowrite |
webfetch |
webfetch |
websearch |
websearch |
lsp |
lsp |
skill |
skill |
question |
question |
build- default primary, all tools enabledplan- primary planning context; this repository keeps edit/bash allowed by owner-standard full-auto policy
- Primary agents switch via Tab key
- Subagents invoked via
@agent_namein messages - Task tool: agents can invoke subagents via the Task tool
---
description: Run tests with coverage
agent: build
model: anthropic/claude-haiku-4-20250514
---
Run the full test suite with coverage report and show any failures.
Focus on the failing tests and suggest fixes.{
"command": {
"test": {
"template": "Run the full test suite with coverage report and show any failures.",
"description": "Run tests with coverage",
"agent": "build",
"model": "anthropic/claude-haiku-4-20250514"
}
}
}{
"mcp": {
"serena": {
"type": "local",
"command": ["uvx", "--from", "serena-agent==1.5.3", "serena", "start-mcp-server", "--context=agent"],
"enabled": true,
"environment": {
"SERENA_AGENT_VERSION": "1.5.1"
}
}
}
}{
"mcp": {
"context7": {
"type": "remote",
"url": "https://mcp.context7.com/mcp",
"enabled": true
}
}
}{
"mcp": {
"github": {
"type": "remote",
"url": "https://api.githubcopilot.com/mcp/",
"enabled": true,
"headers": {
"Authorization": "Bearer {env:GITHUB_PERSONAL_ACCESS_TOKEN}"
}
}
}
}{
"lsp": true
}Or with overrides:
{
"lsp": {
"typescript": { "disabled": true },
"custom-lsp": {
"command": ["custom-lsp-server", "--stdio"],
"extensions": [".custom"]
}
}
}OpenCode has 30+ built-in LSP servers that auto-start when file extensions are detected.
Global:
{
"permission": {
"edit": "allow",
"bash": "allow",
"webfetch": "allow",
"websearch": "allow",
"lsp": "allow"
}
}Per-agent override:
{
"agent": {
"flow-architecture-review": {
"permission": {
"edit": "deny",
"bash": { "*": "ask", "git diff": "allow", "git log*": "allow" },
"webfetch": "deny"
}
}
}
}OpenCode uses provider/model-id format:
anthropic/claude-sonnet-4-20250514anthropic/claude-haiku-4-20250514openai/gpt-5opencode/gpt-5.1-codex(Zen)google/gemini-2.5-prodeepseek/deepseek-v4
bash, edit, write, read, grep, glob, apply_patch, lsp (experimental), skill, todowrite, webfetch, websearch, question
MCP tool names follow pattern: mcp__<servername>__<toolname> (shown in permission config as mymcp_* glob)
-
No hooks lifecycle - All lifecycle automation (Serena sync, commit advice, context bootstrap) moves to:
- AGENTS.md instructions (advisory)
/ry-initand/ry-synccommands (user-invoked)- Agent system prompts (enforcement through agent permission config)
-
No marketplace.json - All config in
opencode.jsonand.opencode/directory -
Skill frontmatter is minimal - Only
nameanddescription. Noallowed-tools,model,effort,maxTurns. Tool access is per-agent, model selection is per-agent or per-command. -
Agent format uses YAML frontmatter in .md - Similar to Claude Code but with different keys (
mode,steps,permissiondict instead ofmaxTurns,disallowedTools) -
Permission system is powerful - Glob patterns on bash commands, per-tool allow/ask/deny, per-agent overrides
-
Built-in websearch - Available with
OPENCODE_ENABLE_EXA=1env var or via Zen provider -
Built-in LSP - 30+ servers, much more than Codex (none) or Claude Code (manual
.lsp.json)