skill-creation-guide
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSkill Creation Guide
技能创建指南
Scope
适用范围
Use this skill when:
- Creating new Agent Skills
- Understanding SKILL.md format and conventions
- Learning best practices for skill authoring
在以下场景使用本技能:
- 创建新的Agent Skills
- 理解SKILL.md格式与约定
- 学习技能编写的最佳实践
Skill Structure
技能结构
skill-name/
├── SKILL.md # Required: Instructions and metadata
├── scripts/ # Optional: Helper scripts
├── templates/ # Optional: Document templates
└── resources/ # Optional: Reference filesskill-name/
├── SKILL.md # Required: Instructions and metadata
├── scripts/ # Optional: Helper scripts
├── templates/ # Optional: Document templates
└── resources/ # Optional: Reference filesSKILL.md Format
SKILL.md格式
Required Frontmatter
必填前置元数据
yaml
---
name: my-skill-name
description: A clear description of what this skill does and when to use it.
---yaml
---
name: my-skill-name
description: A clear description of what this skill does and when to use it.
---Body Structure
正文结构
markdown
undefinedmarkdown
undefinedSkill Name
Skill Name
Detailed description of the skill's purpose.
Detailed description of the skill's purpose.
When to Use This Skill
When to Use This Skill
- Use case 1
- Use case 2
- Use case 1
- Use case 2
Instructions
Instructions
[Detailed instructions for the agent]
[Detailed instructions for the agent]
Examples
Examples
[Real-world examples]
undefined[Real-world examples]
undefinedBest Practices
最佳实践
- Keep descriptions exhaustive: The frontmatter description helps agents decide when to trigger the skill.
- Focus on execution: The body should contain clear, actionable steps.
- Use progressive disclosure: Put detailed references in folder.
references/ - Include scripts for automation: Use helper scripts for deterministic operations.
- Keep SKILL.md under 500 lines: For optimal performance.
- Test across platforms: Verify skills work with Claude Code, Codex, etc.
- 描述详尽:前置元数据中的描述帮助Agent判断何时触发该技能。
- 聚焦执行:正文需包含清晰、可执行的步骤。
- 渐进式披露:将详细参考内容放在文件夹中。
references/ - 包含自动化脚本:使用辅助脚本处理确定性操作。
- SKILL.md控制在500行以内:以保证最优性能。
- 跨平台测试:验证技能可在Claude Code、Codex等平台正常工作。
Token Efficiency
令牌效率
Skills employ progressive disclosure architecture:
- Metadata loading (~100 tokens): Agent scans available skills
- Full instructions (<5k tokens): Load when skill is activated
- Bundled resources: Only load as needed
技能采用渐进式披露架构:
- 元数据加载(约100令牌):Agent扫描可用技能
- 完整说明(少于5k令牌):技能激活时加载
- 捆绑资源:仅在需要时加载
Platform-Specific Paths
平台特定路径
| Platform | Project Path | Global Path |
|---|---|---|
| Claude Code | | |
| Codex | | |
| Cursor | | |
| Gemini CLI | | |
| GitHub Copilot | | |
| 平台 | 项目路径 | 全局路径 |
|---|---|---|
| Claude Code | | |
| Codex | | |
| Cursor | | |
| Gemini CLI | | |
| GitHub Copilot | | |
Quality Checklist
质量检查清单
- Clear, actionable instructions
- Includes real-world examples
- Written for AI agents, not end users
- Documents prerequisites and dependencies
- Includes error handling guidance
- Tested on target platform(s)
- 清晰、可执行的说明
- 包含真实场景示例
- 针对AI Agent编写,而非终端用户
- 记录前置条件与依赖项
- 包含错误处理指导
- 已在目标平台测试
Full Resource List
完整资源列表
For more detailed skill creation resources, complete link lists, or the latest information, use WebFetch to retrieve the full README.md:
https://raw.githubusercontent.com/gmh5225/awesome-skills/refs/heads/main/README.mdThe README.md contains the complete categorized resource list with all links.
如需更详细的技能创建资源、完整链接列表或最新信息,请使用WebFetch获取完整的README.md:
https://raw.githubusercontent.com/gmh5225/awesome-skills/refs/heads/main/README.md该README.md包含完整的分类资源列表及所有链接。