Awesome-omni-skill validate-agent-files
Validates AI coding assistant customization files (agents, skills, prompts, instructions) for correct format and structure. Works with GitHub Copilot, Claude Code, Codex, OpenCode, and other providers. Use when checking if agent files are properly configured, troubleshooting agent issues, or before committing new customization files.
git clone https://github.com/diegosouzapw/awesome-omni-skill
T=$(mktemp -d) && git clone --depth=1 https://github.com/diegosouzapw/awesome-omni-skill "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/ai-agents/validate-agent-files" ~/.claude/skills/diegosouzapw-awesome-omni-skill-validate-agent-files && rm -rf "$T"
skills/ai-agents/validate-agent-files/SKILL.mdValidate Agent Files
Validates that agent, skill, prompt, and instruction files follow the correct format and structure.
Provider Folder Reference
This skill works across multiple AI coding assistant providers:
| Provider | Base Folder |
|---|---|
| GitHub Copilot | |
| Claude Code | |
| Codex | |
| OpenCode | |
Throughout this document,
represents your chosen provider's base folder.<provider>/
When to Use
- Before committing new agents, skills, prompts, or instructions
- When an agent isn't behaving as expected
- To audit existing customization files for issues
- After modifying any
customization files.gemini
Validation Process
Step 1: Identify File Type
Determine the type based on location and extension:
→ Agent file (user-invokable)<provider>/agents/*.md
→ Sub-agent file (workflow component)<provider>/agents/*.subagent.agent.md
→ Skill file<provider>/skills/*/SKILL.md
→ Prompt file<provider>/prompts/*.prompt.md
→ Instruction file<provider>/instructions/*.instructions.md
Step 2: Apply Type-Specific Validation
Agent File Validation (<provider>/agents/*.md
)
<provider>/agents/*.mdRequired Structure:
--- name: agent-name description: When to use this agent (should include examples) user-invokable: true # Optional, defaults to true --- [System prompt body]
Supported Frontmatter Attributes:
(required) - Agent identifiername
(required) - When/how to use, with examplesdescription
(optional) - Set touser-invokable
for sub-agents (default:false
)true
- List of allowed toolstools
- Specific model to usemodel
- Other agents this can delegate tohandoffs
Checks:
- ✓ YAML frontmatter present with
delimiters--- - ✓
field exists and is non-emptyname - ✓
field exists (recommend 50+ characters with examples)description - ✓ Body content exists after frontmatter
- ✓ If
specified, they are valid tool namestools - ✓ If filename contains
, verify.subagent.agent.md
is setuser-invokable: false
Naming Convention Checks:
- User-facing agents:
or<name>.agent.md<name>.md - Sub-agents:
with<name>.subagent.agent.mduser-invokable: false
Common Issues:
- Missing
delimiters--- - Empty or minimal description
- No usage examples in description
- Body content missing or too brief
- Sub-agent missing
user-invokable: false - Sub-agent not using
naming convention.subagent.agent.md
Skill File Validation (<provider>/skills/*/SKILL.md
)
<provider>/skills/*/SKILL.mdRequired Structure:
--- name: skill-name description: What this skill does and when to use it. --- [Skill instructions body]
Supported Frontmatter Attributes:
(required) - Must match parent directory name, lowercase with hyphensname
(required) - Max 1024 chars, describes function and triggersdescription
(optional) - License informationlicense
(optional) - Environment requirementscompatibility
(optional) - Key-value pairs for additional infometadata
(optional) - Space-delimited pre-approved toolsallowed-tools
Checks:
- ✓ File is named
inside a directorySKILL.md - ✓
matches parent directory name exactlyname - ✓
is lowercase, alphanumeric with hyphens onlyname - ✓
doesn't start/end with hyphen or have consecutive hyphensname - ✓
is 1-1024 charactersdescription - ✓ Body content provides clear instructions
Common Issues:
doesn't match directory namename- Uppercase characters in name
- Description too vague (should include trigger keywords)
- Missing instructions in body
Prompt File Validation (<provider>/prompts/*.prompt.md
)
<provider>/prompts/*.prompt.mdRequired Structure:
--- mode: agent description: What this prompt does --- [Prompt template with {{variables}}]
Supported Frontmatter Attributes:
(optional) - One of:mode
(default),agent
,ask
,editgenerate
(optional) - Available tools for this prompttools
(optional but recommended) - What the prompt accomplishesdescription
Checks:
- ✓ File has
extension.prompt.md - ✓ If
present, it's a valid valuemode - ✓ Variables use
syntax{{variableName}} - ✓ Body content exists (the prompt itself)
Common Issues:
- Wrong extension (
instead of.md
).prompt.md - Invalid
valuemode - Undefined variables in template
Instruction File Validation (<provider>/instructions/*.instructions.md
)
<provider>/instructions/*.instructions.mdRequired Structure:
--- applyTo: "**/*.ts" --- [Contextual instructions]
Supported Frontmatter Attributes:
(required) - Glob pattern(s) for when instructions applyapplyTo
Checks:
- ✓ File has
extension.instructions.md - ✓
field existsapplyTo - ✓
contains valid glob pattern(s)applyTo - ✓ Body content provides meaningful guidance
Common Issues:
- Wrong extension
- Missing
fieldapplyTo - Invalid glob syntax
- Empty or minimal instructions
Output Format
## Validation: [filename] **Type:** [Agent|Skill|Prompt|Instruction] **Status:** ✅ Valid | ⚠️ Warnings | ❌ Invalid ### Issues - [Issue 1 with line number if applicable] - [Issue 2] ### Recommendations - [Suggestion for improvement]
Batch Validation
When validating all files, provide summary:
## Validation Summary | Type | Total | Valid | Warnings | Invalid | |------|-------|-------|----------|---------| | Agents | X | X | X | X || Sub-Agents | X | X | X | X || Skills | X | X | X | X | | Prompts | X | X | X | X | | Instructions | X | X | X | X | ### Files Requiring Attention - [List files with issues]