skill-creator
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSkill Creator - SaaS Factory Edition
Skill Creator - SaaS Factory Edition
This skill provides guidance for creating custom skills following SaaS Factory standards.
本技能提供遵循SaaS Factory标准创建自定义技能的指导。
Purpose
用途
To create specialized skills that extend Claude's capabilities with domain-specific knowledge and reusable workflows.
创建专业技能,通过领域专属知识和可复用工作流扩展Claude的能力。
When to Use
适用场景
- Creating new domain-specific skills
- Building reusable tools for your team
- Extending Claude Code functionality
- Documenting specialized procedures
- 创建新的领域专属技能
- 为团队构建可复用工具
- 扩展Claude Code功能
- 记录专业流程
How to Create a Skill
如何创建技能
Step 1: Initialize
步骤1:初始化
bash
python scripts/init_skill.py my-skill --path ./my-skillThis creates:
my-skill/
├── SKILL.md # Edit this with your skill
├── scripts/ # Add executable code
├── references/ # Add documentation
└── assets/ # Add resourcesbash
python scripts/init_skill.py my-skill --path ./my-skill此命令会创建如下结构:
my-skill/
├── SKILL.md # 编辑该文件以定义您的技能
├── scripts/ # 添加可执行代码
├── references/ # 添加文档资料
└── assets/ # 添加资源文件Step 2: Edit SKILL.md
步骤2:编辑SKILL.md
Follow this template:
yaml
---
name: my-skill
description: What this skill does and when to use it (3-5 sentences)
license: MIT
---遵循以下模板:
yaml
---
name: my-skill
description: 该技能的功能及适用场景(3-5句话)
license: MIT
---My Skill Title
我的技能标题
Purpose
用途
Describe what the skill does in 1-2 paragraphs.
用1-2段文字描述该技能的功能。
When to Use
适用场景
Explain when Claude should activate this skill.
说明Claude应何时激活此技能。
How to Use
使用方法
Step 1: First action
步骤1:第一步操作
Instructions for step one.
第一步的具体说明。
Step 2: Second action
步骤2:第二步操作
Instructions for step two.
第二步的具体说明。
Examples
示例
- Example usage 1
- Example usage 2
- 示例用法1
- 示例用法2
Reference Files
参考文件
- See for detailed documentation
references/ - Use for executable code
scripts/
undefined- 详见目录下的详细文档
references/ - 目录下为可执行代码
scripts/
undefinedStep 3: Add Content
步骤3:添加内容
For scripts/ (executable code):
bash
scripts/
├── helper.py # Reusable code
├── processor.sh # Shell utilities
└── validator.py # Input validationFor references/ (documentation):
bash
references/
├── api_docs.md # API specifications
├── schemas.md # Data schemas
└── best_practices.md # GuidelinesFor assets/ (output resources):
bash
assets/
├── template.html # HTML templates
├── icon.png # Images
└── style.css # Styles脚本文件(可执行代码):
bash
scripts/
├── helper.py # 可复用代码
├── processor.sh # Shell工具
└── validator.py # 输入验证参考资料(文档):
bash
references/
├── api_docs.md # API规格说明
├── schemas.md # 数据架构
└── best_practices.md # 指导规范资源文件(输出资源):
bash
assets/
├── template.html # HTML模板
├── icon.png # 图片文件
└── style.css # 样式文件Step 4: Validate
步骤4:验证
bash
python scripts/quick_validate.py ./my-skillCheck:
- ✅ SKILL.md has valid YAML frontmatter
- ✅ Required fields: name, description
- ✅ Correct file structure
- ✅ Naming conventions followed
bash
python scripts/quick_validate.py ./my-skill检查项:
- ✅ SKILL.md包含合法的YAML前置元数据
- ✅ 包含必填字段:name、description
- ✅ 文件结构正确
- ✅ 遵循命名规范
Step 5: Package
步骤5:打包
bash
python scripts/package_skill.py ./my-skillOutput: ready for distribution
my-skill.zipbash
python scripts/package_skill.py ./my-skill输出结果:,可直接用于分发
my-skill.zipStep 6: Install in Claude Code
步骤6:在Claude Code中安装
bash
/plugin install ./my-skill.zipbash
/plugin install ./my-skill.zipBest Practices
最佳实践
✅ DO
✅ 建议
- Write imperative instructions: "To create X, do Y"
- Keep SKILL.md <5k words: Move large docs to references/
- Name scripts descriptively: , not
rotate_pdf.pyutil.py - Include --help in scripts: For user guidance
- Document everything: Clear examples and use cases
- 使用命令式表述:“如需创建X,请执行Y”
- SKILL.md字数控制在5000字以内:将大篇幅文档移至references/目录
- 脚本命名要清晰:如,而非
rotate_pdf.pyutil.py - 脚本中包含--help参数:为用户提供使用指导
- 全面文档化:包含清晰的示例和使用场景
❌ DON'T
❌ 避免
- Use vague names: "tool", "helper", "util"
- Write in second person: "You should do X"
- Include thousands of lines of code in SKILL.md
- Forget error handling in scripts
- Hardcode configurations
- 使用模糊名称:如“tool”、“helper”、“util”
- 使用第二人称表述:“您应该执行X”
- 在SKILL.md中包含数千行代码
- 脚本中未处理错误
- 硬编码配置信息
Naming Conventions
命名规范
Skills: kebab-case (my-skill)
Scripts: action_noun.py (rotate_pdf.py)
References: descriptive.md (api_docs.md)
Files: kebab-case.extension (config-template.json)技能名称: 短横线分隔小写格式(my-skill)
脚本文件: 动作_名词.py格式(rotate_pdf.py)
参考文档: 描述性名称.md(api_docs.md)
普通文件: 短横线分隔小写格式.extension(config-template.json)Example Structure
示例结构
pdf-processor/
├── SKILL.md
│ ---
│ name: pdf-processor
│ description: Process and manipulate PDF files.
│ Use when users need to rotate, merge, or
│ extract data from PDFs.
│ ---
│
│ # PDF Processor
│
│ ## Purpose
│ Advanced PDF manipulation for common tasks.
│
│ ## How to Use
│ 1. Prepare input PDF
│ 2. Execute relevant script
│ 3. Output is saved
│
├── scripts/
│ ├── rotate_pdf.py
│ ├── merge_pdfs.py
│ └── extract_text.py
│
└── references/
├── pdf_formats.md
└── library_guide.mdpdf-processor/
├── SKILL.md
│ ---
│ name: pdf-processor
│ description: 处理和操作PDF文件。
│ 当用户需要旋转、合并或
│ 从PDF中提取数据时使用。
│ ---
│
│ # PDF Processor
│
│ ## 用途
│ 针对常见任务的高级PDF操作能力。
│
│ ## 使用方法
│ 1. 准备输入PDF文件
│ 2. 执行相关脚本
│ 3. 保存输出结果
│
├── scripts/
│ ├── rotate_pdf.py
│ ├── merge_pdfs.py
│ └── extract_text.py
│
└── references/
├── pdf_formats.md
└── library_guide.mdValidation Checklist
验证检查清单
□ SKILL.md structure
□ Valid YAML frontmatter
□ name in kebab-case
□ description is descriptive
□ File organization
□ Scripts in scripts/
□ Docs in references/
□ Resources in assets/
□ Quality
□ SKILL.md <5k words
□ Scripts have docstrings
□ Clear examples included
□ All paths relative
□ Ready to distribute
□ Validated: ✓ All OK!
□ Packaged: skill-name.zip
□ Can install: /plugin install□ SKILL.md结构
□ 合法的YAML前置元数据
□ 名称为短横线分隔小写格式
□ 描述清晰准确
□ 文件组织
□ 脚本存放于scripts/目录
□ 文档存放于references/目录
□ 资源存放于assets/目录
□ 质量检查
□ SKILL.md字数<5000
□ 脚本包含文档字符串
□ 包含清晰示例
□ 所有路径均为相对路径
□ 可分发状态
□ 已验证:✓ 全部通过!
□ 已打包:skill-name.zip
□ 可安装:/plugin installReferences
参考资料
See for:
references/- Anthropic Skills Specification
- Best Practices Guide
- Example Skills
Create skills following SaaS Factory standards for consistency and quality.
详见目录下的:
references/- Anthropic Skills Specification
- 最佳实践指南
- 示例技能
遵循SaaS Factory标准创建技能,确保一致性和高质量。