From latestaiagents
Structure SKILL.md content so the model reads just enough — concise summary up front, progressively deeper detail, examples on demand. Covers section ordering, length budgets, when to split into multiple skills. Use this skill when writing or refactoring a skill body, one skill has grown too long, or a skill is wordy but not useful. Activate when: SKILL.md structure, skill content, skill too long, split skill, progressive disclosure, skill body.
npx claudepluginhub latestaiagents/agent-skills --plugin skills-authoringThis skill uses the workspace's default tool permissions.
**A skill is consumed by a model with finite attention. Put the highest-signal content first, let depth come later. Length without structure is noise.**
Guides creating and editing SKILL.md files for Claude Code skills, covering objectives, when to create, YAML frontmatter requirements, structure, and writing principles like showing patterns with examples.
Guides creation of effective skills extending AI model capabilities with specialized knowledge, workflows, and tool integrations. Useful when users request new or updated skills.
Guides creation of effective skills for OpenHands including anatomy, YAML metadata, progressive disclosure, bundled resources, scripts, and references.
Share bugs, ideas, or general feedback.
A skill is consumed by a model with finite attention. Put the highest-signal content first, let depth come later. Length without structure is noise.
Target ≈ 150-300 lines. Order sections from most-essential to least:
1. ---frontmatter---
2. One-line bolded summary
3. When to Use (bullet list)
4. Core concept (≤ 5 sentences)
5. Minimal example
6. Deeper patterns / variations
7. Anti-patterns
8. Best Practices (numbered list)
The model reads top-down. Every section should earn its place.
# Skill Title
**One sentence that captures the whole skill's value proposition.**
If the reader stops after this line, they still learned something.
A bullet list of 3-6 situations. Concrete, not abstract:
## When to Use
- Your agent needs to remember user preferences across sessions
- You're replacing "stuff everything into system prompt" with structured state
- You're building coding agents that learn about a codebase over time
Bad:
5 sentences. Maximum. Explain the mental model:
The Memory tool gives Claude a file system. Claude issues read/write ops;
your app executes them on real storage. Per-user roots isolate data.
Unlike RAG, the agent curates what's worth remembering. Unlike context-stuffing,
state persists without growing every message.
If you need 3 paragraphs, you probably have two concepts and should split.
The fewest lines of code that demonstrate the thing:
const response = await client.messages.create({
model: "claude-sonnet-4-6",
tools: [{ type: "memory_20250818", name: "memory" }],
messages: [...],
});
No setup boilerplate the reader already knows. Start where the skill-specific code starts.
After the minimal, show variations and production patterns. Use subheadings:
### Persistent Containers
### Streaming Results
### Error Handling
Each pattern: 1 short paragraph + 1 short code block. Resist the urge to write an essay.
Numbered list of things people get wrong:
## Anti-Patterns
1. Running on a host with real data — one injection away from disaster
2. Using Computer Use when an API exists — 10-100× more expensive
3. No human-in-loop for destructive actions
This section is high-value. Readers who've hit these pain points become believers.
Numbered list of recommendations. Each one actionable:
## Best Practices
1. Use sub-agents for research and context isolation
2. Prompt sub-agents self-contained — they have no prior context
3. Require summarized output with word limits
Not "be careful", not "consider X" — imperatives.
| Skill type | Target length |
|---|---|
| Quick reference (git commands, API shapes) | 80-150 lines |
| Concept + workflow (most skills) | 150-300 lines |
| Deep dive (rare; prefer splitting) | 300-500 lines |
Past 500 lines you almost always have two or three skills masquerading as one.
Signals your skill should become multiple:
Split along:
Reference sibling skills by name, not duplicate their content:
See the `mcp-security-sandboxing` skill for full threat model.
If your skill is re-explaining what another skill covers, trust the reader will load both.
Skim the skill in 10 seconds. Can you answer:
If yes on all three, you're there. If no, the structure's off — reorder or trim.
await fetch(...) noise in every block