create-skill-file
Guides Claude in creating well-structured SKILL.md files following best practices. Provides clear guidelines for naming, structure, and content organization to make skills easy to discover and execute.
下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o create-skill-file.zip https://jpskill.com/download/19561.zip && unzip -o create-skill-file.zip && rm create-skill-file.zip
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/19561.zip -OutFile "$d\create-skill-file.zip"; Expand-Archive "$d\create-skill-file.zip" -DestinationPath $d -Force; ri "$d\create-skill-file.zip"
完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。
💾 手動でダウンロードしたい(コマンドが難しい人向け)
- 1. 下の青いボタンを押して
create-skill-file.zipをダウンロード - 2. ZIPファイルをダブルクリックで解凍 →
create-skill-fileフォルダができる - 3. そのフォルダを
C:\Users\あなたの名前\.claude\skills\(Win)または~/.claude/skills/(Mac)へ移動 - 4. Claude Code を再起動
⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。
🎯 このSkillでできること
下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。
📦 インストール方法 (3ステップ)
- 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
- 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
- 3. 展開してできたフォルダを、ホームフォルダの
.claude/skills/に置く- · macOS / Linux:
~/.claude/skills/ - · Windows:
%USERPROFILE%\.claude\skills\
- · macOS / Linux:
Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。
詳しい使い方ガイドを見る →- 最終更新
- 2026-05-18
- 取得日時
- 2026-05-18
- 同梱ファイル
- 1
📖 Skill本文(日本語訳)
※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。
[Skill 名] create-skill-file
Claude Agent Skill 記述ガイドライン
高品質な SKILL.md ファイルを作成する方法
目次
クイックスタート
3ステップで Skill を作成
ステップ1: ディレクトリの作成
mkdir -p .claude/skill/your-skill-name
cd .claude/skill/your-skill-name
ステップ2: SKILL.md の作成
---
name: your-skill-name
description: Brief description with trigger keywords and scenarios
---
# Your Skill Title
## When to Use This Skill
- User asks to [specific scenario]
- User mentions "[keyword]"
## How It Works
1. Step 1: [Action]
2. Step 2: [Action]
## Examples
**Input**: User request
**Output**: Expected result
ステップ3: テスト
- 会話で description 内のキーワードを使用してトリガーします。
- Claude が正しく実行するかどうかを観察します。
- 効果に基づいて調整します。
コア原則
1. 簡潔さを保つ
Claude が知らない新しい知識のみを追加します。
- ✅ プロジェクト固有のワークフロー
- ✅ 特殊な命名規則またはフォーマット要件
- ✅ カスタムツールとスクリプトの使用方法
- ❌ 一般的なプログラミング知識
- ❌ 明らかな手順
比較例:
# ❌ 過度に詳細
1. Python ファイルを作成します。
2. 必要なライブラリをインポートします。
3. 関数を定義します。
4. メインプログラムロジックを記述します。
# ✅ 簡潔で効果的
`scripts/api_client.py` を使用して内部 API を呼び出します。
リクエストヘッダーには `X-Internal-Token` (環境変数 `INTERNAL_API_KEY` から取得) を含める必要があります。
2. 適切な自由度を設定する
| 自由度 | 適用シナリオ | 記述方法 |
|---|---|---|
| 高 | 創造性、複数の解決策が必要な場合 | 指導原則を提供し、具体的な手順を限定しない |
| 中 | 推奨パターンがあるが変更も許容される場合 | パラメータ化された例とデフォルトのプロセスを提供 |
| 低 | エラーが発生しやすく、厳密な実行が必要な場合 | 詳細なステップバイステップの指示またはスクリプトを提供 |
判断基準:
- タスクに明確な「正解」がありますか? → 低自由度
- さまざまなシナリオに適応する必要がありますか? → 高自由度
- エラーのコストはどれくらいですか? → コストが高い場合は低自由度を使用
3. 段階的な開示
複雑なコンテンツを階層的に整理します。
SKILL.md (メインドキュメント, 200-500行)
├── reference.md (詳細ドキュメント)
├── examples.md (完全な例)
└── scripts/ (実行可能スクリプト)
ルール:
- SKILL.md が 500行を超える場合 → サブファイルに分割します。
- サブファイルが 100行を超える場合 → 目次を追加します。
- 参照深度 ≤ 1層
ファイル構造ガイドライン
YAML Frontmatter
---
name: skill-name-here
description: Clear description of what this skill does and when to activate it
---
フィールドガイドライン:
| フィールド | 要件 | 説明 |
|---|---|---|
name |
小文字、数字、ハイフン、≤64文字 | ディレクトリ名と一致する必要があります |
description |
プレーンテキスト、≤1024文字 | 検索とアクティベーションに使用されます |
命名の禁止事項:
- ❌ XML タグ、予約語 (
anthropic,claude) - ❌ 曖昧な語彙 (
helper,utility,manager) - ❌ スペースまたはアンダースコア (ハイフン
-を使用)
Description のヒント:
# ❌ 汎用すぎる
description: Helps with code tasks
# ✅ 具体的にキーワードを含む
description: Processes CSV files and generates Excel reports with charts. Use when user asks to convert data formats or create visual reports.
# ✅ トリガーシナリオを説明
description: Analyzes Python code for security vulnerabilities using bandit. Activates when user mentions "security audit" or "vulnerability scan".
ディレクトリ構成
基本構造(シンプルな Skill):
skill-name/
└── SKILL.md
標準構造(推奨):
skill-name/
├── SKILL.md
├── templates/
│ └── template.md
└── scripts/
└── script.py
命名と説明のガイドライン
Skill の命名
推奨フォーマット: 動名詞形式 (verb-ing + noun)
✅ 良い命名:
- processing-csv-files
- generating-api-docs
- managing-database-migrations
❌ 悪い命名:
- csv (短すぎる)
- data_processor (アンダースコアを使用)
- helper (曖昧すぎる)
Description の記述
三人称を使用する必要があります:
# ❌ 誤り
description: I help you process PDFs
# ✅ 正しい
description: Processes PDF documents and extracts structured data
4C 原則:
- Clear (明確): 専門用語や曖昧な語彙を避ける
- Concise (簡潔): 1-2文でコア機能を説明する
- Contextual (文脈): 適用シナリオを説明する
- Complete (完全): 機能 + トリガー条件
コンテンツ記述ガイド
"When to Use" セクション
トリガーシナリオを明確に説明します。
## When to Use This Skill
- User asks to analyze Python code for type errors
- User mentions "mypy" or "type checking"
- User is working in a Python project with type hints
- User needs to add type annotations
パターン:
- 直接的なリクエスト: "User asks to X"
- キーワード: "User mentions 'keyword'"
- コンテキスト: "User is working with X"
- タスクタイプ: "User needs to X"
ワークフロー設計
シンプルな線形フロー:
## How It Works
1. Scan the project for all `.py` files
2. Run `mypy --strict` on each file
3. Parse error output and categorize by severity
4. Generate summary report with fix suggestions
条件分岐フロー:
## Workflow
1. **Check project type**
- If Django → Use `django-stubs` config
- If Flask → Use `flask-stubs` config
- Otherwise → Use default mypy config
2. **Run type checking**
- If errors found → Proceed to step 3
- If no errors → Report success and exit
チェックリストパターン(検証タスク):
## Pre-deployment Checklist
Execute in order. Stop if any step fails.
- [ ] Run tests: `npm test` (must pass)
- [ ] Build: `npm run build` (no errors)
- [ ] Check deps: `npm audit` (no critical vulnerabilities)
例とテンプレート
入力-出力例:
## Examples
### Example 1: Basic Check
**User Request**: "Check my code for type errors"
**Action**:
1. Scan for `.py` files
2. Run `mypy` on all files
**Output**:
Found 3 type errors in 2 files:
src/main.py:15: error: Missing return type
src/utils.py:42: error: Incompatible types
スクリプトの統合
スクリプトを使用するタイミング:
- シンプルなコマンド → SKILL.md で直接説明
- 複雑なフロー → 独立したスクリプトを提供
スクリプト記述ガイドライン:
#!/usr/bin/env python3
"""
Brief description of what this script does.
Usage:
python script.py <arg> [--option value]
"""
import argparse
DEFAULT_VALUE = 80 # Use constants, not magic numbers
def main():
parser = argparse.ArgumentParser(description=__doc__)
parser.add_argument("directory", help="Directory to process")
parser.add_argument("--threshold", type=int, default=DEFAULT_VALUE)
args = parser.parse_args()
# Validate inputs
if not Path(args.directory).is_dir():
print(f"Error: {args.directory} not found")
return 1
# Execute
result = process(args.directory, args.threshold)
# Report
print(f"Processed {result['count']} files")
return 0
if __name__ == "__main__":
exit(main())
主要なガイドライン:
- ✅ Shebang 行と docstring
- ✅ 型アノテーションと定数
- ✅ 引数検証とエラー処理
- ✅ 明確な戻り値 (0=成功, 1=失敗)
ベストプラクティス
Do:
- ✅ 実行可能なコマンドとスクリプトを提供する
- ✅ 入力-出力例を含める
- ✅ 検証基準と成功条件を説明する
- ✅ Do/Don't チェックリストを含める
Don't:
- ❌ Claude がすでに知っている一般的な知識を含める
- ❌ 具体的な手順ではなく抽象的な説明を使用する
- ❌ エラー処理のガイダンスを省略する
- ❌ 偽コードではなく実際のコードを使用する
品質チェックリスト
コア品質
- [ ]
nameが命名ガイドライン (小文字、ハイフン、≤64文字) に準拠しています。 - [ ]
descriptionにトリガーキーワードとシナリオが含まれています (≤1024文字)。 - [ ] 名前がディレクトリ名と一致しています。
- [ ] Claude が知らない情報のみが含まれています。
- [ ] 冗長な内容や重複する内容がありません。
機能の完全性
- [ ] 「When to Use」セクションがあり、3〜5つのトリガーシナリオがリストされています。
- [ ] 明確な実行フローまたは手順があります。
- [ ] 少なくとも2〜3つの完全な例があります。
- [ ] 入力と期待される出力が含まれています。
- [ ] エラー処理のガイダンスがあります。
構造ガイドライン
- [ ] セクションの構成が明確です。
- [ ] 200行を超える場合は目次ナビゲーションがあります。
- [ ] 参照階層が1層以下です。
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開
Claude Agent Skill 编写规范
如何创建高质量的 SKILL.md 文件
目录
快速开始
3步创建 Skill
第1步: 创建目录
mkdir -p .claude/skill/your-skill-name
cd .claude/skill/your-skill-name
第2步: 创建 SKILL.md
---
name: your-skill-name
description: Brief description with trigger keywords and scenarios
---
# Your Skill Title
## When to Use This Skill
- User asks to [specific scenario]
- User mentions "[keyword]"
## How It Works
1. Step 1: [Action]
2. Step 2: [Action]
## Examples
**Input**: User request
**Output**: Expected result
第3步: 测试
- 在对话中使用 description 中的关键词触发
- 观察 Claude 是否正确执行
- 根据效果调整
核心原则
1. 保持简洁
只添加 Claude 不知道的新知识:
- ✅ 项目特定的工作流程
- ✅ 特殊的命名规范或格式要求
- ✅ 自定义工具和脚本的使用方法
- ❌ 通用编程知识
- ❌ 显而易见的步骤
示例对比:
# ❌ 过度详细
1. 创建 Python 文件
2. 导入必要的库
3. 定义函数
4. 编写主程序逻辑
# ✅ 简洁有效
使用 `scripts/api_client.py` 调用内部 API。
请求头必须包含 `X-Internal-Token`(从环境变量 `INTERNAL_API_KEY` 获取)。
2. 设定合适的自由度
| 自由度 | 适用场景 | 编写方式 |
|---|---|---|
| 高 | 需要创造性、多种解决方案 | 提供指导原则,不限定具体步骤 |
| 中 | 有推荐模式但允许变化 | 提供参数化示例和默认流程 |
| 低 | 容易出错、需严格执行 | 提供详细的分步指令或脚本 |
判断标准:
- 任务是否有明确的"正确答案"? → 低自由度
- 是否需要适应不同场景? → 高自由度
- 错误的代价有多大? → 代价高则用低自由度
3. 渐进式披露
将复杂内容分层组织:
SKILL.md (主文档, 200-500行)
├── reference.md (详细文档)
├── examples.md (完整示例)
└── scripts/ (可执行脚本)
规则:
- SKILL.md 超过 500行 → 拆分子文件
- 子文件超过 100行 → 添加目录
- 引用深度 ≤ 1层
文件结构规范
YAML Frontmatter
---
name: skill-name-here
description: Clear description of what this skill does and when to activate it
---
字段规范:
| 字段 | 要求 | 说明 |
|---|---|---|
name |
小写字母、数字、短横线,≤64字符 | 必须与目录名一致 |
description |
纯文本,≤1024字符 | 用于检索和激活 |
命名禁忌:
- ❌ XML 标签、保留字(
anthropic,claude) - ❌ 模糊词汇(
helper,utility,manager) - ❌ 空格或下划线(用短横线
-)
Description 技巧:
# ❌ 过于泛化
description: Helps with code tasks
# ✅ 具体且包含关键词
description: Processes CSV files and generates Excel reports with charts. Use when user asks to convert data formats or create visual reports.
# ✅ 说明触发场景
description: Analyzes Python code for security vulnerabilities using bandit. Activates when user mentions "security audit" or "vulnerability scan".
目录组织
基础结构(简单 Skill):
skill-name/
└── SKILL.md
标准结构(推荐):
skill-name/
├── SKILL.md
├── templates/
│ └── template.md
└── scripts/
└── script.py
命名和描述规范
Skill 命名
推荐格式: 动名词形式 (verb-ing + noun)
✅ 好的命名:
- processing-csv-files
- generating-api-docs
- managing-database-migrations
❌ 不好的命名:
- csv (过于简短)
- data_processor (使用下划线)
- helper (过于模糊)
Description 编写
必须使用第三人称:
# ❌ 错误
description: I help you process PDFs
# ✅ 正确
description: Processes PDF documents and extracts structured data
4C 原则:
- Clear (清晰): 避免术语和模糊词汇
- Concise (简洁): 1-2句话说明核心功能
- Contextual (上下文): 说明适用场景
- Complete (完整): 功能 + 触发条件
内容编写指南
"When to Use" 章节
明确说明触发场景:
## When to Use This Skill
- User asks to analyze Python code for type errors
- User mentions "mypy" or "type checking"
- User is working in a Python project with type hints
- User needs to add type annotations
模式:
- 直接请求: "User asks to X"
- 关键词: "User mentions 'keyword'"
- 上下文: "User is working with X"
- 任务类型: "User needs to X"
工作流设计
简单线性流程:
## How It Works
1. Scan the project for all `.py` files
2. Run `mypy --strict` on each file
3. Parse error output and categorize by severity
4. Generate summary report with fix suggestions
条件分支流程:
## Workflow
1. **Check project type**
- If Django → Use `django-stubs` config
- If Flask → Use `flask-stubs` config
- Otherwise → Use default mypy config
2. **Run type checking**
- If errors found → Proceed to step 3
- If no errors → Report success and exit
Checklist 模式(验证型任务):
## Pre-deployment Checklist
Execute in order. Stop if any step fails.
- [ ] Run tests: `npm test` (must pass)
- [ ] Build: `npm run build` (no errors)
- [ ] Check deps: `npm audit` (no critical vulnerabilities)
示例和模板
输入-输出示例:
## Examples
### Example 1: Basic Check
**User Request**: "Check my code for type errors"
**Action**:
1. Scan for `.py` files
2. Run `mypy` on all files
**Output**:
Found 3 type errors in 2 files:
src/main.py:15: error: Missing return type
src/utils.py:42: error: Incompatible types
脚本集成
何时使用脚本:
- 简单命令 → 直接在 SKILL.md 中说明
- 复杂流程 → 提供独立脚本
脚本编写规范:
#!/usr/bin/env python3
"""
Brief description of what this script does.
Usage:
python script.py <arg> [--option value]
"""
import argparse
DEFAULT_VALUE = 80 # Use constants, not magic numbers
def main():
parser = argparse.ArgumentParser(description=__doc__)
parser.add_argument("directory", help="Directory to process")
parser.add_argument("--threshold", type=int, default=DEFAULT_VALUE)
args = parser.parse_args()
# Validate inputs
if not Path(args.directory).is_dir():
print(f"Error: {args.directory} not found")
return 1
# Execute
result = process(args.directory, args.threshold)
# Report
print(f"Processed {result['count']} files")
return 0
if __name__ == "__main__":
exit(main())
关键规范:
- ✅ Shebang 行和 docstring
- ✅ 类型注解和常量
- ✅ 参数验证和错误处理
- ✅ 清晰的返回值(0=成功, 1=失败)
最佳实践
Do:
- ✅ 提供可执行的命令和脚本
- ✅ 包含输入-输出示例
- ✅ 说明验证标准和成功条件
- ✅ 包含 Do/Don't 清单
Don't:
- ❌ 包含 Claude 已知的通用知识
- ❌ 使用抽象描述而非具体步骤
- ❌ 遗漏错误处理指导
- ❌ 示例使用伪代码而非真实代码
质量检查清单
核心质量
- [ ]
name符合命名规范(小写、短横线、≤64字符) - [ ]
description包含触发关键词和场景(≤1024字符) - [ ] 名称与目录名一致
- [ ] 只包含 Claude 不知道的信息
- [ ] 没有冗余或重复内容
功能完整性
- [ ] 有"When to Use"章节,列出 3-5 个触发场景
- [ ] 有清晰的执行流程或步骤
- [ ] 至少 2-3 个完整示例
- [ ] 包含输入和预期输出
- [ ] 错误处理有指导
结构规范
- [ ] 章节组织清晰
- [ ] 超过 200行有目录导航
- [ ] 引用层级 ≤ 1层
- [ ] 所有路径使用正斜杠
/ - [ ] 术语使用一致
脚本和模板
- [ ] 脚本包含使用说明和参数文档
- [ ] 脚本有错误处理
- [ ] 避免魔法数字,使用配置
- [ ] 模板格式清晰易用
最终检查
- [ ] 通读全文,确保流畅易读
- [ ] 使用实际场景测试触发
- [ ] 长度适中(200-500行,或已拆分)
常见问题
Q: Skill 多长才合适?
- 最小: 50-100行
- 理想: 200-500行
- 最大: 500行(超过则拆分)
Q: 如何让 Skill 更容易激活?
- 在
description中使用用户会说的关键词 - 说明具体场景("when user asks to X")
- 提及相关工具名称
Q: 多个 Skill 功能重叠怎么办?
- 使用更具体的
description区分 - 在"When to Use"中说明关系
- 考虑合并为一个 Skill
Q: Skill 需要维护吗?
- 每季度审查一次,更新过时信息
- 根据使用反馈迭代
- 工具或 API 变更时及时更新
快速参考
Frontmatter 模板
---
name: skill-name
description: Brief description with trigger keywords
---
基础结构模板
# Skill Title
## When to Use This Skill
- Scenario 1
- Scenario 2
## How It Works
1. Step 1
2. Step 2
## Examples
### Example 1
...
## References
- [Link](url)
相关资源
- Claude Agent Skills 官方文档
- Best Practices Checklist
- 模板文件 - 开箱即用的模板
- 示例库 - 完整的 Skill 示例