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

optimize-skills

SKILL.md形式のスキル作成・改善や、スキルの起動に関する問題点(過剰/過少な起動、曖昧な説明、過多なコンテキスト、不足した手順など)を診断し、より効果的なスキルへと最適化するSkill。

📜 元の英語説明(参考)

Use when creating or refining SKILL.md-based skills, or diagnosing weak triggering (under/over-triggering, vague descriptions, bloated context, or missing workflow guidance).

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

一言でいうと

SKILL.md形式のスキル作成・改善や、スキルの起動に関する問題点(過剰/過少な起動、曖昧な説明、過多なコンテキスト、不足した手順など)を診断し、より効果的なスキルへと最適化するSkill。

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

⚡ おすすめ: コマンド1行でインストール(60秒)

下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。

🍎 Mac / 🐧 Linux
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o optimize-skills.zip https://jpskill.com/download/10631.zip && unzip -o optimize-skills.zip && rm optimize-skills.zip
🪟 Windows (PowerShell)
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/10631.zip -OutFile "$d\optimize-skills.zip"; Expand-Archive "$d\optimize-skills.zip" -DestinationPath $d -Force; ri "$d\optimize-skills.zip"

完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。

💾 手動でダウンロードしたい(コマンドが難しい人向け)
  1. 1. 下の青いボタンを押して optimize-skills.zip をダウンロード
  2. 2. ZIPファイルをダブルクリックで解凍 → optimize-skills フォルダができる
  3. 3. そのフォルダを C:\Users\あなたの名前\.claude\skills\(Win)または ~/.claude/skills/(Mac)へ移動
  4. 4. Claude Code を再起動

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

🎯 この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-18
取得日時
2026-05-18
同梱ファイル
1

📖 Skill本文(日本語訳)

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

スキルの最適化

このスキルを使用して、SKILL.mdに基づいたスキルを作成、レビュー、または改善し、それらが正しくトリガーされ、簡潔さを保ち、確実に実行されるようにします。

どのような時に使うか

  • 繰り返しの作業パターンから新しい再利用可能なスキルを作成する場合。
  • トリガー不足、過剰トリガー、または誤作動する既存のスキルを更新する場合。
  • 長すぎる、冗長な、または実行が難しいスキルを絞り込む場合。
  • ナラティブなガイダンスを簡潔で命令的な指示に変換する場合。
  • コンテンツをSKILL.mdreferences/assets/、およびscripts/のどこに配置するかを再調整する場合。

概要

スキルとは?

スキルとは、実績のあるテクニック、パターン、またはツールのリファレンスガイドであり、通常は手順的な知識またはベストプラクティスとして分類されます。 スキルは、将来の Agent インスタンスが効果的なアプローチを見つけて適用するのに役立ちます。

スキルとは: 再利用可能なテクニック、パターン、ツール、リファレンスガイド

スキルとは: 問題を一度解決した方法に関するナラティブではない

スキルをいつ作成するか

作成する場合:

  • テクニックが直感的に明らかではなかった、または正しく理解するのに複数の反復が必要だった場合。
  • プロジェクト全体でこれを再度参照する場合/他の人がこれを知ることで恩恵を受ける場合。
  • パターンが広範に適用される場合(プロジェクト固有ではない)。
  • 特定のユーザーの意図または一般的な障害モードによってトリガー可能な場合。

作成しない場合:

  • 一度限りの解決策
  • 他の場所で十分に文書化されている標準的なプラクティス
  • 広範に適用できないプロジェクト固有の規則

ワークフロー

フェーズ 1:準備

  1. パスを選択します。
    • 新しいスキル:スキャフォールドとベースライン構造を初期化します。
    • 既存のスキル:現在のSKILL.mdと関連リソースをベースラインとしてロードします。
  2. 最初にターゲットワークフローを定義します。
    • 前提条件、ゲート、および出力を含む、実行ステップを順番にリストします。
    • ステップを命令的かつ実行可能に保ちます。
  3. 作業メモでトリガーシナリオを決定します。
    • スキルをトリガーする必要がある2〜3のシナリオをキャプチャします。
    • スキルをトリガーしてはならない最大2つのシナリオをキャプチャします。
  4. フローチャートが必要かどうかを決定します。
    • フローが線形で明白な場合は、markdownのみのワークフローを使用します。
    • 分岐/ループが明白でない場合にのみ、小さな DOT フローチャートを追加します。

フェーズ 2:ドラフト

  1. 準備からメタデータと使用ガイダンスをドラフトします。
    • frontmatter を namedescription に保ちます。
    • トリガーシナリオを description## When to Use (および役立つ場合は ## When Not to Use )にエンコードします。
  2. 命令形でスキル本体をドラフトします。
    • 指示を短く、具体的で、実行順に並べます。
    • 詳細な詳細を references/assets/、または scripts/ に移動し、SKILL.md からリンクします。

フェーズ 3:レビューと最適化

  1. 現実的なプロンプトに対してシナリオと機能チェックを実行します。
  2. リソースの適合性を確認します。
    • 参照/アセット/スクリプトが十分であり、スコープされていることを確認します。
    • 必要に応じて、冗長な SKILL.md セクションをリソースにオフロードします。
  3. ドラフトを最適化します。
    • トリガーを絞り込みます(トリガー不足/過剰トリガー)。
    • 冗長性を取り除き、プログレッシブな開示を改善します。
    • フローチャートの使用がまだ正当化されるかどうかを再確認します。
  4. トリガーの動作と実行品質の両方が合格するまで反復処理します。

コア原則

  • トリガーの最適化:説明では、スキルをいつ使用するかを強調する必要があります(references/skills-search-optimization.md)。
  • トリガーシナリオをオーサリングスキャフォールドとして扱います。最終的なスキルでは、description## When to Use を通じてトリガーを公開する必要があります。
  • frontmatter メタデータを小さく保ちます(合計約100トークン)。
  • メインの SKILL.md を500行未満に保ち、アクションに焦点を当てます。
  • プログレッシブな開示を使用します:メタデータ -> SKILL.md -> references/scripts/assets。
  • 脆弱性に応じて、適切な自由度を選択します:テキスト、擬似コード、またはスクリプト。
  • 繰り返しの散文よりも、再利用可能なリソース(スクリプト、テンプレート)を優先します。

プログレッシブな開示のターゲット

  • メタデータ(name + description):小さなスタートアップフットプリント、理想的には〜100トークン。
  • SKILL.md:アクション可能で簡潔に保ち、\<5000トークンおよび\<500行をターゲットにします。
  • scripts/references/assets/:必要な場合にのみロードされます。エージェントが取得するコンテキストを減らすために、ファイルを狭く保ちます。

フローチャートのガイダンス

digraph when_flowchart {
    "Need to show process guidance?" [shape=diamond];
    "Non-obvious decision or loop?" [shape=diamond];
    "Use markdown (list/table/code)" [shape=box];
    "Use small inline DOT flowchart" [shape=box];

    "Need to show process guidance?" -> "Non-obvious decision or loop?" [label="yes"];
    "Need to show process guidance?" -> "Use markdown (list/table/code)" [label="no"];
    "Non-obvious decision or loop?" -> "Use small inline DOT flowchart" [label="yes"];
    "Non-obvious decision or loop?" -> "Use markdown (list/table/code)" [label="no"];
}
  • デフォルトでは、markdown リスト/テーブル/コードブロックを使用します。
  • 意思決定ロジックまたはループが誤って適用されやすい場合にのみ、DOT を追加します。
  • プレースホルダーノードラベルは避けてください。具体的なアクションと条件を使用します。
  • ノードの形状とラベルについては、references/graphviz-conventions.dot に従ってください。
  • フローチャートを小さく、トリガーベースに保ちます。大きなフローを焦点を絞ったサブグラフに分割します。

scripts/render-dot.py を使用して DOT を SVG にレンダリングします。 出力 SVG は、ターゲットスキルの assets/ ディレクトリに書き込まれます。

scripts/render-dot.py skills/optimize-skills/references/skill-workflow.dot
scripts/render-dot.py skills/optimize-skills/SKILL.md
scripts/render-dot.py skills/optimize-skills/SKILL.md --force # overwrite existing SVGs

出力

SKILL.md の構造

skills/
  skill-name/
    SKILL.md      # メインリファレンス (必須)
    assets/       # (オプション) テンプレートや図などの静的な再利用可能なリソース
    references/   # (オプション) トピックまたはバリアントごとに整理されたオンデマンドドキュメント
    scripts/      # (オプション) 決定論的なタスクのための実行可能なヘルパー。
                  # スクリプトは自己完結型であるか、依存関係を明確に宣言し、
                  # 明確なエラーを含み、エッジケースを処理する必要があります。

ルール

  • SKILL.md は正確に SKILL.md という名前でなければなりません。
  • フォルダ名はケバブケースで、fro の name と一致する必要があります。

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

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

Optimizing Skills

Use this skill to create, review, or improve SKILL.md-based skills so they trigger correctly, stay concise, and execute reliably.

When to Use

  • Creating a new reusable skill from repeated work patterns.
  • Updating an existing skill that under-triggers, over-triggers, or misfires.
  • Tightening a skill that is too long, redundant, or hard to execute.
  • Converting narrative guidance into concise, imperative instructions.
  • Rebalancing where content should live across SKILL.md, references/, assets/, and scripts/.

Overview

What is a Skill?

A skill is a reference guide for proven techniques, patterns, or tools, typically classed as procedural knowledge or best practices. Skills help future Agent instances find and apply effective approaches.

Skills are: Reusable techniques, patterns, tools, reference guides

Skills are NOT: Narratives about how you solved a problem once

When to Create a Skill

Create when:

  • Technique wasn't intuitively obvious to you or required multiple iterations to get right.
  • You'd reference this again across projects / Others would benefit from knowing this.
  • Pattern applies broadly (not project-specific)
  • Triggerable by specific user intents or common failure modes.

Don't create for:

  • One-off solutions
  • Standard practices well-documented elsewhere
  • Project-specific conventions that aren't broadly applicable

Workflow

Phase 1: Preparation

  1. Choose the path:
    • New skill: initialize scaffold and baseline structure.
    • Existing skill: load current SKILL.md and related resources as baseline.
  2. Define the target workflow first:
    • List the execution steps in order, including prerequisites, gates, and outputs.
    • Keep steps imperative and executable.
  3. Determine trigger scenarios in working notes:
    • Capture 2-3 scenarios that must trigger the skill.
    • Capture up to 2 scenarios that must not trigger the skill.
  4. Decide whether a flowchart is required:
    • Use markdown-only workflow when flow is linear and obvious.
    • Add a small DOT flowchart only when branching/loops are non-obvious.

Phase 2: Draft

  1. Draft metadata and usage guidance from preparation:
    • Keep frontmatter to name and description.
    • Encode trigger scenarios in description and ## When to Use (and ## When Not to Use when helpful).
  2. Draft the skill body in imperative form:
    • Keep instructions short, specific, and ordered by execution.
    • Move deep detail to references/, assets/, or scripts/ and link from SKILL.md.

Phase 3: Review and Optimize

  1. Run scenario and functional checks against realistic prompts.
  2. Review resource fit:
    • Confirm references/assets/scripts are sufficient and scoped.
    • Offload verbose SKILL.md sections into resources where appropriate.
  3. Optimize the draft:
    • Tighten triggering (under/over-triggering).
    • Remove redundancy and improve progressive disclosure.
    • Re-check whether flowchart usage is still justified.
  4. Iterate until trigger behavior and execution quality both pass.

Core Principles

  • Optimize for triggering: description must emphasize when to use the skill (references/skills-search-optimization.md).
  • Treat trigger scenarios as authoring scaffolding; the final skill should expose triggers through description and ## When to Use.
  • Keep frontmatter metadata small (about 100 tokens combined).
  • Keep main SKILL.md under 500 lines and focused on action.
  • Use progressive disclosure: metadata -> SKILL.md -> references/scripts/assets.
  • Choose the right degree of freedom: text, pseudocode, or scripts depending on fragility.
  • Prefer reusable resources (scripts, templates) over repeated prose.

Progressive Disclosure Targets

  • Metadata (name + description): small startup footprint, ideally ~100 tokens.
  • SKILL.md: keep actionable and concise, target \<5000 tokens and \<500 lines.
  • scripts/, references/, assets/: loaded only when needed; keep files narrow so agents pull less context.

Flowchart Guidance

digraph when_flowchart {
    "Need to show process guidance?" [shape=diamond];
    "Non-obvious decision or loop?" [shape=diamond];
    "Use markdown (list/table/code)" [shape=box];
    "Use small inline DOT flowchart" [shape=box];

    "Need to show process guidance?" -> "Non-obvious decision or loop?" [label="yes"];
    "Need to show process guidance?" -> "Use markdown (list/table/code)" [label="no"];
    "Non-obvious decision or loop?" -> "Use small inline DOT flowchart" [label="yes"];
    "Non-obvious decision or loop?" -> "Use markdown (list/table/code)" [label="no"];
}
  • Use markdown lists/tables/code blocks by default.
  • Add DOT only when decision logic or loops are easy to misapply.
  • Avoid placeholder node labels; use concrete actions and conditions.
  • Follow references/graphviz-conventions.dot for node shapes and labels.
  • Keep flowcharts small and trigger-based; split large flows into focused subgraphs.

Render DOT to SVG with scripts/render-dot.py. Output SVGs are written to the target skill's assets/ directory.

scripts/render-dot.py skills/optimize-skills/references/skill-workflow.dot
scripts/render-dot.py skills/optimize-skills/SKILL.md
scripts/render-dot.py skills/optimize-skills/SKILL.md --force # overwrite existing SVGs

Output

SKILL.md Structure

skills/
  skill-name/
    SKILL.md      # Main reference (required)
    assets/       # (optional) Static reusable resources such as templates or figures
    references/   # (optional) On-demand documentation, organized by topic or variant
    scripts/      # (optional) Executable helpers for deterministic tasks;
                  # scripts should be self-contained or clearly declare dependencies,
                  # include clear errors, and handle edge cases.

Rules

  • SKILL.md must be named exactly SKILL.md.
  • Folder name must be kebab-case, matching the name in frontmatter.
  • Do not add README.md inside the skill.
  • YAML frontmatter must include name and description fields.
  • name must be kebab-case and match the folder name.
  • description should emphasize when to use the skill and include triggers/symptoms.
  • Avoid workflow summaries in the description.
  • Keep descriptions short and specific.
  • Prefer ## When to Use / ## When Not to Use for trigger cues; do not add a dedicated trigger-scenarios section unless explicitly requested by the repo.
  • Refer to assets/skill-template.md for a suggested (but easily modified) template structure.

Common Mistakes

  • Summarizing workflow in description instead of stating actionable triggers and symptoms.
  • Copying working trigger scenarios directly into the final skill instead of converting them into description and ## When to Use.
  • Keeping workflows as one giant graph instead of splitting into trigger-based subgraphs.
  • Repeating deep reference material in SKILL.md instead of linking to references/.
  • Leaving scripts implicit: deterministic steps should be executable where possible.

References

  • assets/skill-template.md for a suggested SKILL.md structure.
  • references/best-practices.md: checklists, structure guidance, testing, and troubleshooting patterns.
  • references/skills-search-optimization.md: description and trigger optimization rules.
  • references/skill-workflow.dot: canonical workflow for this skill.
  • references/graphviz-conventions.dot: DOT style and semantics for workflow diagrams.