docs(skill-creator): Add comprehensive YAML frontmatter reference (#6)

Add documentation for all available YAML frontmatter fields, with special
emphasis on `context: fork` which is critical for skills that subagents
should be able to use via the Task tool.

Changes:
- Add YAML Frontmatter Reference section to SKILL.md with complete field table
- Document when to use `context: fork` for subagent-accessible skills
- Add invocation control comparison table
- Update init_skill.py template with commented optional frontmatter fields

This addresses a gap where skills created without `context: fork` could not
be used by subagents, limiting the skill's usefulness in multi-agent workflows.

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Costantino Marcello
2026-01-29 12:15:36 +00:00
committed by GitHub
parent 1d49e3e377
commit 2ce0266454
2 changed files with 79 additions and 0 deletions

View File

@@ -18,6 +18,13 @@ from pathlib import Path
SKILL_TEMPLATE = """---
name: {skill_name}
description: [TODO: Complete and informative explanation of what the skill does and when to use it. Include WHEN to use this skill - specific scenarios, file types, or tasks that trigger it.]
# ─── OPTIONAL FIELDS (uncomment as needed) ───
# context: fork # Run in subagent context. IMPORTANT: Required for skills that subagents should use via Task tool
# agent: Explore # Subagent type when context: fork (Explore, Plan, general-purpose, or custom)
# disable-model-invocation: true # Only allow manual /skill-name invocation, prevent auto-triggering
# user-invocable: false # Hide from / menu (for background knowledge only)
# allowed-tools: Read, Grep # Tools allowed without permission prompts
# argument-hint: [filename] # Autocomplete hint for arguments
---
# {skill_title}