Purpose: Standards for creating and maintaining agents in OpenAgents Control
Last Updated: 2026-01-31
This directory contains standards for agent creation, focusing on:
These standards emerged from fixing YAML frontmatter issues across 18 agent files.
| File | Description | Priority | Lines |
|---|---|---|---|
| agent-frontmatter.md | Valid OpenCode frontmatter fields and common mistakes | critical | <200 |
| subagent-structure.md | Standard structure for subagent files | critical | <200 |
Required:
name - Display namedescription - When to use this agentmode - Agent type (primary, subagent, all)Optional:
temperature - Response randomness (0.0-1.0)model - Model overridemaxSteps - Max iterationsdisable - Disable agenthidden - Hide from autocompleteprompt - Custom prompt filetools - Tool access configpermission - Permission rulesskills - Skills to loadThese fields are NOT valid in OpenCode frontmatter:
id - Agent identifiercategory - Agent categorytype - Component typeversion - Version numberauthor - Author identifiertags - Discovery tagsdependencies - Component dependenciesSolution: Move these to .opencode/config/agent-metadata.json
Problem: read: true followed by read: {"**/*": "allow"}
Fix: Use only one declaration per key
Problem: Lines without parent keys (e.g., - write: false)
Fix: Proper YAML structure with parent keys
Problem: permission: instead of permissions:
Fix: Use correct field name permissions:
Problem: Multiple --- blocks in content
Fix: Only one frontmatter block at top
Problem: Fields like id, category, type in frontmatter
Fix: Move to agent-metadata.json
agent-frontmatter.md - Understand valid fieldssubagent-structure.md - Follow structure patternagent-frontmatter.md - Identify invalid fieldsagent-frontmatter.md - Check frontmatter validitysubagent-structure.md - Verify structure complianceyq eval '.opencode/agent/category/agent.md' > /dev/null
grep -A 50 "^---$" .opencode/agent/category/agent.md | grep -E "^[a-z_]+:" | sort | uniq -d
grep -A 50 "^---$" .opencode/agent/category/agent.md | grep -E "^[a-z_]+:" | cut -d: -f1
Valid keys: name, description, mode, temperature, model, maxSteps, disable, hidden, prompt, tools, permissions, skills
2026-01-31: Initial standards created after fixing YAML frontmatter issues in 18 agent files. Issues fixed:
read: true + read: {"**/*": "allow"})permission: → permissions:)--- delimiter blocks in contentVersion: 1.0.0
Maintainer: OpenAgents Control Team