jpskill.com
🛠️ 開発・MCP コミュニティ

creating-agent-skills

ClaudeのCode Skillを新規作成、既存改善、または構造理解する際に、専門家のアドバイスを提供するSkill。

📜 元の英語説明(参考)

Expert guidance for creating, writing, and refining Claude Code Skills. Use when working with SKILL.md files, authoring new skills, improving existing skills, or understanding skill structure and best practices.

🇯🇵 日本人クリエイター向け解説

一言でいうと

ClaudeのCode Skillを新規作成、既存改善、または構造理解する際に、専門家のアドバイスを提供するSkill。

※ jpskill.com 編集部が日本のビジネス現場向けに補足した解説です。Skill本体の挙動とは独立した参考情報です。

⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。

🎯 このSkillでできること

下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。

📦 インストール方法 (3ステップ)

  1. 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
  2. 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
  3. 3. 展開してできたフォルダを、ホームフォルダの .claude/skills/ に置く
    • · macOS / Linux: ~/.claude/skills/
    • · Windows: %USERPROFILE%\.claude\skills\

Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。

詳しい使い方ガイドを見る →
最終更新
2026-05-17
取得日時
2026-05-17
同梱ファイル
1

📖 Skill本文(日本語訳)

※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。

エージェントスキルの作成

このスキルでは、Anthropic の公式仕様に従って、効果的な Claude Code Skills を作成する方法を説明します。

核となる原則

1. スキルはプロンプトです

すべてのプロンプトのベストプラクティスが適用されます。明確に、直接的に記述してください。Claude は賢いと仮定し、Claude が持っていないコンテキストのみを追加してください。

2. 標準 Markdown 形式

YAML フロントマターと Markdown ボディを使用してください。XML タグは使用せず、標準の Markdown 見出しを使用してください。

---
name: my-skill-name
description: What it does and when to use it
---

# My Skill Name

## Quick Start
Immediate actionable guidance...

## Instructions
Step-by-step procedures...

## Examples
Concrete usage examples...

3. 段階的開示

SKILL.md は 500 行未満に保ってください。詳細なコンテンツは参照ファイルに分割してください。必要なものだけを読み込んでください。

my-skill/
├── SKILL.md              # Entry point (required)
├── reference.md          # Detailed docs (loaded when needed)
├── examples.md           # Usage examples
└── scripts/              # Utility scripts (executed, not loaded)

4. 効果的な説明

description フィールドはスキルの発見を可能にします。スキルが何をするか、そしていつ使用するかを両方含めてください。三人称で記述してください。

良い例:

description: Extracts text and tables from PDF files, fills forms, merges documents. Use when working with PDF files or when the user mentions PDFs, forms, or document extraction.

悪い例:

description: Helps with documents

スキル構造

必須フロントマター

フィールド 必須 最大長 説明
name はい 64 文字 小文字、数字、ハイフンのみ
description はい 1024 文字 何をするか、そしていつ使用するか
allowed-tools いいえ - Claude が尋ねずに使用できるツール
model いいえ - 使用する特定のモデル

命名規則

スキル名には動名詞形(動詞 + -ing)を使用してください。

  • processing-pdfs
  • analyzing-spreadsheets
  • generating-commit-messages
  • reviewing-code

避けるべきもの: helperutilstoolsanthropic-*claude-*

ボディ構造

標準の Markdown 見出しを使用してください。

# Skill Name

## Quick Start
Fastest path to value...

## Instructions
Core guidance Claude follows...

## Examples
Input/output pairs showing expected behavior...

## Advanced Features
Additional capabilities (link to reference files)...

## Guidelines
Rules and constraints...

何をしたいですか?

  1. 新しいスキルを作成する - ゼロから構築する
  2. 既存のスキルを監査する - ベストプラクティスに照らして確認する
  3. コンポーネントを追加する - ワークフロー/参照/例を追加する
  4. ガイダンスを得る - スキル設計を理解する

新しいスキルの作成

ステップ 1: タイプを選択する

シンプルなスキル(単一ファイル):

  • 500 行未満
  • 自己完結型のガイダンス
  • 複雑なワークフローなし

段階的開示スキル(複数ファイル):

  • SKILL.md を概要として使用
  • 詳細なドキュメント用の参照ファイル
  • ユーティリティ用のスクリプト

ステップ 2: SKILL.md を作成する

---
name: your-skill-name
description: [What it does]. Use when [trigger conditions].
---

# Your Skill Name

## Quick Start

[Immediate actionable example]

```[language]
[Code example]

Instructions

[Core guidance]

Examples

Example 1: Input: [description] Output:

[result]

Guidelines

  • [Constraint 1]
  • [Constraint 2]

ステップ 3: 参照ファイルを追加する(必要な場合)

SKILL.md から詳細なコンテンツにリンクしてください。

For API reference, see [REFERENCE.md](REFERENCE.md).
For form filling guide, see [FORMS.md](FORMS.md).

参照は SKILL.md から1 階層のみに保ってください。

ステップ 4: スクリプトを追加する(必要な場合)

スクリプトはコンテキストに読み込まれずに実行されます。

## Utility Scripts

Extract fields:
```bash
python scripts/analyze.py input.pdf > fields.json

### ステップ 5: 実際の使用でテストする

1. テストシナリオではなく、実際のタスクでテストしてください
2. Claude がどこで苦戦するかを観察してください
3. 実際の動作に基づいて改善してください
4. Haiku、Sonnet、Opus でテストしてください

## 既存のスキルの監査

この評価基準に照らして確認してください。

- [ ] 有効な YAML フロントマター(name + description)
- [ ] 説明にトリガーキーワードが含まれている
- [ ] 標準の Markdown 見出しを使用している(XML タグではない)
- [ ] SKILL.md が 500 行未満である
- [ ] 参照が 1 階層である
- [ ] 例が抽象的ではなく具体的である
- [ ] 用語が統一されている
- [ ] 時間に依存する情報がない
- [ ] スクリプトがエラーを明示的に処理している

## 一般的なパターン

### テンプレートパターン

一貫した結果を得るために出力テンプレートを提供してください。

```markdown
## Report Template

```markdown
# [Analysis Title]

## Executive Summary
[One paragraph overview]

## Key Findings
- Finding 1
- Finding 2

## Recommendations
1. [Action item]
2. [Action item]

### ワークフローパターン

複雑な多段階タスクの場合:

```markdown
## Migration Workflow

Copy this checklist:
  • [ ] Step 1: Backup database
  • [ ] Step 2: Run migration script
  • [ ] Step 3: Validate output
  • [ ] Step 4: Update configuration

Step 1: Backup database Run: ./scripts/backup.sh ...


### 条件パターン

意思決定ポイントをガイドしてください。

```markdown
## Choose Your Approach

**Creating new content?** Follow "Creation workflow" below.
**Editing existing?** Follow "Editing workflow" below.

避けるべきアンチパターン

  • ボディ内の XML タグ - 代わりに Markdown 見出しを使用してください
  • 曖昧な説明 - トリガーキーワードを具体的に記述してください
  • 深いネスト - 参照は SKILL.md から 1 階層に保ってください
  • 多すぎるオプション - エスケープハッチ付きのデフォルトを提供してください
  • Windows パス - 常にスラッシュを使用してください
  • Claude への丸投げ - スクリプトがエラーを処理すべきです
  • 時間に依存する情報 - 代わりに「古いパターン」セクションを使用してください

参照ファイル

詳細なガイダンスについては、以下を参照してください。

成功基準

適切に構造化されたスキルは、

  • 記述的な名前と有効な YAML フロントマターを持ち、

(原文がここで切り詰められています)

📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開

Creating Agent Skills

This skill teaches how to create effective Claude Code Skills following Anthropic's official specification.

Core Principles

1. Skills Are Prompts

All prompting best practices apply. Be clear, be direct. Assume Claude is smart - only add context Claude doesn't have.

2. Standard Markdown Format

Use YAML frontmatter + markdown body. No XML tags - use standard markdown headings.

---
name: my-skill-name
description: What it does and when to use it
---

# My Skill Name

## Quick Start
Immediate actionable guidance...

## Instructions
Step-by-step procedures...

## Examples
Concrete usage examples...

3. Progressive Disclosure

Keep SKILL.md under 500 lines. Split detailed content into reference files. Load only what's needed.

my-skill/
├── SKILL.md              # Entry point (required)
├── reference.md          # Detailed docs (loaded when needed)
├── examples.md           # Usage examples
└── scripts/              # Utility scripts (executed, not loaded)

4. Effective Descriptions

The description field enables skill discovery. Include both what the skill does AND when to use it. Write in third person.

Good:

description: Extracts text and tables from PDF files, fills forms, merges documents. Use when working with PDF files or when the user mentions PDFs, forms, or document extraction.

Bad:

description: Helps with documents

Skill Structure

Required Frontmatter

Field Required Max Length Description
name Yes 64 chars Lowercase letters, numbers, hyphens only
description Yes 1024 chars What it does AND when to use it
allowed-tools No - Tools Claude can use without asking
model No - Specific model to use

Naming Conventions

Use gerund form (verb + -ing) for skill names:

  • processing-pdfs
  • analyzing-spreadsheets
  • generating-commit-messages
  • reviewing-code

Avoid: helper, utils, tools, anthropic-*, claude-*

Body Structure

Use standard markdown headings:

# Skill Name

## Quick Start
Fastest path to value...

## Instructions
Core guidance Claude follows...

## Examples
Input/output pairs showing expected behavior...

## Advanced Features
Additional capabilities (link to reference files)...

## Guidelines
Rules and constraints...

What Would You Like To Do?

  1. Create new skill - Build from scratch
  2. Audit existing skill - Check against best practices
  3. Add component - Add workflow/reference/example
  4. Get guidance - Understand skill design

Creating a New Skill

Step 1: Choose Type

Simple skill (single file):

  • Under 500 lines
  • Self-contained guidance
  • No complex workflows

Progressive disclosure skill (multiple files):

  • SKILL.md as overview
  • Reference files for detailed docs
  • Scripts for utilities

Step 2: Create SKILL.md

---
name: your-skill-name
description: [What it does]. Use when [trigger conditions].
---

# Your Skill Name

## Quick Start

[Immediate actionable example]

```[language]
[Code example]

Instructions

[Core guidance]

Examples

Example 1: Input: [description] Output:

[result]

Guidelines

  • [Constraint 1]
  • [Constraint 2]

Step 3: Add Reference Files (If Needed)

Link from SKILL.md to detailed content:

For API reference, see [REFERENCE.md](REFERENCE.md).
For form filling guide, see [FORMS.md](FORMS.md).

Keep references one level deep from SKILL.md.

Step 4: Add Scripts (If Needed)

Scripts execute without loading into context:

## Utility Scripts

Extract fields:
```bash
python scripts/analyze.py input.pdf > fields.json

### Step 5: Test With Real Usage

1. Test with actual tasks, not test scenarios
2. Observe where Claude struggles
3. Refine based on real behavior
4. Test with Haiku, Sonnet, and Opus

## Auditing Existing Skills

Check against this rubric:

- [ ] Valid YAML frontmatter (name + description)
- [ ] Description includes trigger keywords
- [ ] Uses standard markdown headings (not XML tags)
- [ ] SKILL.md under 500 lines
- [ ] References one level deep
- [ ] Examples are concrete, not abstract
- [ ] Consistent terminology
- [ ] No time-sensitive information
- [ ] Scripts handle errors explicitly

## Common Patterns

### Template Pattern

Provide output templates for consistent results:

```markdown
## Report Template

```markdown
# [Analysis Title]

## Executive Summary
[One paragraph overview]

## Key Findings
- Finding 1
- Finding 2

## Recommendations
1. [Action item]
2. [Action item]

### Workflow Pattern

For complex multi-step tasks:

```markdown
## Migration Workflow

Copy this checklist:
  • [ ] Step 1: Backup database
  • [ ] Step 2: Run migration script
  • [ ] Step 3: Validate output
  • [ ] Step 4: Update configuration

Step 1: Backup database Run: ./scripts/backup.sh ...


### Conditional Pattern

Guide through decision points:

```markdown
## Choose Your Approach

**Creating new content?** Follow "Creation workflow" below.
**Editing existing?** Follow "Editing workflow" below.

Anti-Patterns to Avoid

  • XML tags in body - Use markdown headings instead
  • Vague descriptions - Be specific with trigger keywords
  • Deep nesting - Keep references one level from SKILL.md
  • Too many options - Provide a default with escape hatch
  • Windows paths - Always use forward slashes
  • Punting to Claude - Scripts should handle errors
  • Time-sensitive info - Use "old patterns" section instead

Reference Files

For detailed guidance, see:

Success Criteria

A well-structured skill:

  • Has valid YAML frontmatter with descriptive name and description
  • Uses standard markdown headings (not XML tags)
  • Keeps SKILL.md under 500 lines
  • Links to reference files for detailed content
  • Includes concrete examples with input/output pairs
  • Has been tested with real usage

Sources: