jpskill.com
📦 その他 コミュニティ

ralph-loop-template

Ralph Loopの計画ファイルや現在の状況から、反復可能なチェックリストプロンプトファイルを生成するSkill。

📜 元の英語説明(参考)

Generates iterable checklist PROMPT files for Ralph Loop from plan files or current context, and provides the /ralph-loop execution command.

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

一言でいうと

Ralph Loopの計画ファイルや現在の状況から、反復可能なチェックリストプロンプトファイルを生成するSkill。

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

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

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

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

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

💾 手動でダウンロードしたい(コマンドが難しい人向け)
  1. 1. 下の青いボタンを押して ralph-loop-template.zip をダウンロード
  2. 2. ZIPファイルをダブルクリックで解凍 → ralph-loop-template フォルダができる
  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-17
取得日時
2026-05-17
同梱ファイル
1

📖 Skill本文(日本語訳)

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

[スキル名] ralph-loop-template

入力

$ARGUMENTS

手順

ステップ1: プランの収集

引数が提供されている場合: ファイルを読み込み、プランの内容を理解します。

引数がない場合: 以下の順序でプランを検索します。

  1. プロジェクトルートでプランファイルを検索します: PLAN.mdplan.mdPLAN-*.mdplan-*.mdTODO.mdprd.mdPRD.md
    • 1つ見つかった場合 → それを使用します(どのファイルが検出されたかをユーザーに通知します)
    • 複数見つかった場合 → リストを提示し、選択を求めます
    • 0個見つかった場合 → 次のステップに進みます
  2. 現在の会話コンテキストで議論されているプランを使用します。
  3. 会話コンテキストにプランが存在しない場合、ユーザーにプランの説明を求めます。

ステップ2: プロジェクト環境の特定

PROMPTファイルに埋め込むプロジェクト固有の情報を収集します。

エージェント/プロジェクト設定ファイルを以下の優先順位で検索します:

  1. CLAUDE.md (Claude Code)
  2. .cursorrules (Cursor)
  3. .windsurfrules (Windsurf)
  4. AGENTS.mdCOPILOT.mdGEMINI.md

設定ファイルが見つかった場合、以下を抽出します。

  • 検証コマンド: ビルド、テスト、リンティングを単一のチェーンに結合します(例: npm run lint && npm run build && npm test
  • 主要なコードスタイルルール(PROMPTの絶対ルール{AGENT_RULES}に挿入する項目、最大3つ)

設定ファイルが見つからない場合: プロジェクト構造から推測します。

  • package.json → npm/yarnコマンド
  • Makefile / Justfile → make/justコマンド
  • Cargo.toml → cargoコマンド
  • pyproject.toml / setup.py → Pythonツールチェーン
  • 検出できない場合、ユーザーにビルド/テストコマンドを尋ねます

ステップ3: プランの分析

プランから以下を抽出します。

  • 目標: 何を構築するのか
  • 非目標: このタスクでは行わないこと(機能の過剰な追加を防ぐため)
  • フェーズリスト: 順序付けられた実装ステップ
  • フェーズごとの主要コンテンツ: 変更するファイル、実装の詳細
  • 参照ドキュメント/ファイル: パターン参照、設計ドキュメントのパス
  • 完了基準: タスク全体が完了したと判断するための基準

完了基準は機械的に検証可能である必要があります(例: コマンド実行が終了コード0を返す)。「うまく機能する」や「きれいに見える」のような主観的な基準は使用しないでください。

ステップ4: フェーズ分割

プランをRalph Loopのイテレーションに適したフェーズに分割します。

分割の原則:

  • 1回のイテレーション = 厳密に1つのフェーズ。2つ以上のフェーズを処理することは厳禁です。
  • フェーズが完了したら、すぐにイテレーションを終了します。次のフェーズは次のイテレーションで処理されます。
  • 各フェーズは、独立して検証に合格できる最小単位である必要があります。
  • 大きすぎるフェーズは分割し、小さすぎるフェーズは隣接するフェーズと結合します。

サイズガイドライン(参考であり、絶対ではありません):

  • 説明が3文以上必要 → 分割の候補
  • 1つのファイルに対する1行の変更 → 隣接するフェーズとの結合の候補
  • 適切なサイズとは、エージェントが単一のコンテキスト内で実装+検証できるものです

max-iterationsの計算: フェーズ数 + 2

  • +1: 検証失敗時の自動再試行のためのバッファ
  • +1: 最終フェーズ完了後のプロミス出力イテレーションのためのバッファ

ステップ5: PROMPTファイルの生成

references/prompt-template.mdをベーステンプレートとして、references/iteration-procedure.mdをイテレーション手順ブロックとして使用し、PROMPTファイルを生成します。

プロジェクトルートにPROMPT-{kebab-case-name}.mdファイルを作成します。

プレースホルダーのマッピング:

プレースホルダー ソース フォールバック
{goal title} ステップ3 ユーザーに尋ねる
{project name} プロジェクトディレクトリ名またはCLAUDE.md ユーザーに尋ねる
{goal} ステップ3 ユーザーに尋ねる
{AGENT_RULES} ステップ2(エージェント設定ルール) 設定ファイルがない場合、行全体を省略
{non-goals} ステップ3 + 推論のための非目標記述ルール 最小2項目
{reference doc rows} ステップ2-3 ドキュメントが0の場合、参照ドキュメントセクション全体を省略
{iteration procedure} references/iteration-procedure.md全体
{checklist} ステップ4のフェーズ分割結果
{verification command} ステップ2(プロジェクト検出) ユーザーに尋ねる
{COMPLETION_PROMISE} COMPLETION_PROMISE生成ルール

: 中括弧を使用する例示テキスト(スコープ外の発見事項の記録形式など)は、置換せずにそのまま残してください。

ステップ6: 結果の出力

生成されたPROMPTファイルのパスを提供し、/ralph-loopコマンドを以下の形式で出力します。

### 生成されたファイル

`{PROMPT file path}`

> 実行前に生成されたPROMPTファイルを確認してください。特に検証コマンドとフェーズ構造をチェックしてください。

### Ralph Loop 実行コマンド

/ralph-loop "Read {PROMPT file path} and implement the next unchecked phase. Always read the file first to find the first phase with [ ] items." --max-iterations {number of phases + 2} --completion-promise "{COMPLETION_PROMISE}"

上記のコマンドブロックは、コピーして直接使用できるように出力してください。


生成ルール

チェックリスト記述ルール

  • フェーズ = イテレーション単位: 1つの### Phase Nブロックが1回のイテレーションで処理されます
  • サブアイテム = フェーズ内の詳細タスク: 各フェーズの下に2〜5個の- [ ]サブアイテムを配置します
  • サブアイテムは、変更するファイルと実装の詳細を指定する必要があります
  • 検証はチェックリスト項目ではありません — イテレーション手順のステップ4で自動的に実行されます。ステップ2で検出されたプロジェクトのビルド/テストコマンドを使用してください

非目標記述ルール

プランによって明示的に除外された項目に加えて、以下を推測して追加します。

  • プランのスコープ外のリファクタリング
  • 要求されていないテスト/ドキュメント/設定の変更
  • 既存のAPIまたはインターフェースの変更(プランで指定されていない場合)

COMPLETION_PROMISE生成ルール

  • 大文字の英字、スペース区切り
  • 目標を簡潔に要約します(例: "HELP OVERLAY COMPLETE"、"AUTH REFACTOR DONE")
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開

Input

$ARGUMENTS

Instructions

Step 1: Gather Plan

If an argument is provided: Read the file to understand the plan content.

If no argument: Search for a plan in the following order:

  1. Search for plan files in the project root: PLAN.md, plan.md, PLAN-*.md, plan-*.md, TODO.md, prd.md, PRD.md
    • 1 found → Use it (inform the user which file was detected)
    • Multiple found → Present the list and ask for selection
    • 0 found → Proceed to next step
  2. Use the plan discussed in the current conversation context.
  3. If no plan exists in the conversation context, ask the user to describe the plan.

Step 2: Identify Project Environment

Collect project-specific information to embed in the PROMPT file.

Search for agent/project configuration files in the following priority order:

  1. CLAUDE.md (Claude Code)
  2. .cursorrules (Cursor)
  3. .windsurfrules (Windsurf)
  4. AGENTS.md, COPILOT.md, GEMINI.md

If a config file is found, extract:

  • Verification commands: Combine build, test, lint into a single chain (e.g., npm run lint && npm run build && npm test)
  • Key code style rules (items to insert into the PROMPT's absolute rules {AGENT_RULES}, max 3)

If no config file is found: Infer from project structure:

  • package.json → npm/yarn commands
  • Makefile / Justfile → make/just commands
  • Cargo.toml → cargo commands
  • pyproject.toml / setup.py → python toolchain
  • If undetectable, ask the user for build/test commands

Step 3: Analyze Plan

Extract the following from the plan:

  • Goal: What is being built
  • Non-goals: What will NOT be done in this task (to prevent Feature Invention)
  • Phase list: Ordered implementation steps
  • Key content per phase: Files to change, implementation details
  • Reference docs/files: Pattern references, design document paths
  • Completion criteria: Criteria for determining the entire task is complete

Completion criteria must be mechanically verifiable (e.g., command execution returns exit code 0). Do not use subjective criteria like "works well" or "looks clean".

Step 4: Phase Splitting

Split the plan into phases suitable for Ralph Loop iterations.

Splitting principles:

  • One iteration = exactly one phase. Processing 2+ phases is strictly forbidden.
  • When a phase is completed, immediately end the iteration. The next phase is handled in the next iteration.
  • Each phase must be the minimum unit that can independently pass verification.
  • Split phases that are too large, merge phases that are too small.

Size guideline (reference, not absolute):

  • If description needs 3+ sentences → candidate for splitting
  • If it's a single-line change to one file → candidate for merging with adjacent phase
  • The appropriate size is one the agent can implement + verify within a single context

max-iterations calculation: number of phases + 2

  • +1: Buffer for automatic retry on verification failure
  • +1: Buffer for promise output iteration after final phase completion

Step 5: Generate PROMPT File

Use references/prompt-template.md as the base template and references/iteration-procedure.md as the iteration procedure block to generate the PROMPT file.

Create a PROMPT-{kebab-case-name}.md file in the project root.

Placeholder mapping:

Placeholder Source Fallback
{goal title} Step 3 Ask user
{project name} Project directory name or CLAUDE.md Ask user
{goal} Step 3 Ask user
{AGENT_RULES} Step 2 (agent config rules) Omit entire line if no config file
{non-goals} Step 3 + non-goal writing rules for inference Min 2 items
{reference doc rows} Step 2-3 Omit entire reference docs section if 0 docs
{iteration procedure} Entire references/iteration-procedure.md
{checklist} Step 4 phase splitting result
{verification command} Step 2 (project detection) Ask user
{COMPLETION_PROMISE} COMPLETION_PROMISE generation rules

Note: Example text that uses curly braces (such as the recording format for out-of-scope findings) should be left as-is without substitution.

Step 6: Output Result

Provide the generated PROMPT file path and output the /ralph-loop command in the following format:

### Generated File

`{PROMPT file path}`

> Review the generated PROMPT file before execution. Check the verification commands and phase structure in particular.

### Ralph Loop Execution Command

/ralph-loop "Read {PROMPT file path} and implement the next unchecked phase. Always read the file first to find the first phase with [ ] items." --max-iterations {number of phases + 2} --completion-promise "{COMPLETION_PROMISE}"

Output the command block above so it can be copied and used directly.


Generation Rules

Checklist Writing Rules

  • Phase = iteration unit: A single ### Phase N block is processed in one iteration
  • Sub-items = detailed tasks within a phase: Place 2-5 - [ ] sub-items under each Phase
  • Sub-items should specify files to change and implementation details
  • Verification is not a checklist item — it runs automatically in STEP 4 of the iteration procedure. Use the project's build/test commands detected in Step 2

Non-Goal Writing Rules

In addition to items explicitly excluded by the plan, infer and add:

  • Refactoring outside the plan's scope
  • Unrequested test/documentation/configuration changes
  • Existing API or interface changes (if not specified in the plan)

COMPLETION_PROMISE Generation Rules

  • Uppercase English, space-separated
  • Briefly summarize the goal (e.g., "HELP OVERLAY COMPLETE", "AUTH REFACTOR DONE")