Token导航 LogoToken导航

Agent Skill · 研究检索

ralph-preflight(拉尔夫飞行前)

ralph-preflight 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

ralph-preflight 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为只读;许可证为 MIT,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 47,709。

总安装 723周安装 12GitHub Stars 公开资料未说明下载 97核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:ralph-preflight(拉尔夫飞行前)
来源仓库:https://github.com/ansarullahanasz360/cc-guide
仓库路径:skills/ralph-preflight
安装命令:
npx skills add https://github.com/ansarullahanasz360/cc-guide --skill ralph-preflight
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/ansarullahanasz360/cc-guide --skill ralph-preflight

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

用于查找、检索和筛选相关信息。适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。适合在需要根据关键词或任务场景快速定位候选结果时使用。可结合来源仓库和原始 README 核验具体用法。安装前建议确认权限范围和维护状态,避免触发联网或文件读写。

ralph-preflight 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

来源仓库内路径:skills/ralph-preflight

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/ansarullahanasz360/cc-guide --skill ralph-pref…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它标注为只读,先用只读任务试一次,确认行为符合预期再扩大使用范围。

常见问题

6 条

ralph-preflight 怎么安装?

在终端执行 npx skills add https://github.com/ansarullahanasz360/cc-guide --skill ralph-preflight。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

ralph-preflight 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

ralph-preflight 需要什么权限?

权限级别是只读。该 Skill 主要提供规则、说明或参考内容,本身偏只读;真正读写文件、联网或执行命令仍取决于宿主 Agent 的任务。

ralph-preflight 是免费的吗?

来源标注的许可证是 MIT。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

ralph-preflight 用的人多吗?

公开数据是累计安装 723 次,近一周安装 12 次,下载 97 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

ralph-preflight 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 3 个目录同时收录,说明这个 Skill 流传比较广。
  • 许可证明确为 MIT,商用和分发边界好判断。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。
  • 需要许可证清楚、并且有第三方扫描结果的团队项目。

不太适合

  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
ralph-preflight

拉尔夫飞行前 · 本页

723—只读MIT通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Ralph TUI Pre-Flight Check

Fast verification that everything is configured correctly before starting a Ralph loop. Run this after creating a PRD with /prd to validate and launch.

When to Use

  • After running /prd to create a prd.json
  • Before starting any Ralph loop
  • When troubleshooting Ralph loop issues
  • To verify template and config are in sync

Pre-Flight Phases

Execute these checks in order. Stop and report if critical issues are found.


Phase 1: Environment Check

1.1 Global CLAUDE.md Conflict Detection (CRITICAL)

Ralph loops can have global ~/.claude/CLAUDE.md override local project CLAUDE.md. Check and warn:

# Check if global CLAUDE.md exists
if [ -f ~/.claude/CLAUDE.md ]; then
  echo "WARNING: Global CLAUDE.md exists at ~/.claude/CLAUDE.md"
  echo "This may override your local CLAUDE.md during Ralph loops"
  wc -l ~/.claude/CLAUDE.md
else
  echo "OK: No global CLAUDE.md found"
fi

If global CLAUDE.md exists:

  • Show its contents (first 20 lines)
  • Ask user if they want to:

- A. Remove it temporarily (rename to CLAUDE.md.bak) - B. Keep it (may cause issues) - C. View full contents first

1.2 Ralph TUI Installation

which ralph-tui && ralph-tui --version

1.3 Required Tools

# Check tmux (required for persistent sessions)
which tmux && tmux -V

# Check git (required for worktrees)
git --version

1.4 Existing Ralph State Detection (CRITICAL)

Check if .ralph-tui/ has data from a previous run that could interfere:

# Check for existing state
if [ -d .ralph-tui ]; then
  echo "Found existing .ralph-tui/ directory"

  # Check for progress file with content
  if [ -f .ralph-tui/progress.md ] && [ -s .ralph-tui/progress.md ]; then
    echo "⚠ progress.md exists with content ($(wc -l < .ralph-tui/progress.md) lines)"
  fi

  # Check for iteration logs
  if [ -d .ralph-tui/iterations ] && [ "$(ls -A .ralph-tui/iterations 2>/dev/null)" ]; then
    echo "⚠ iterations/ has $(ls .ralph-tui/iterations | wc -l) log files"
  fi

  # Check for session state
  if [ -f .ralph-tui/state.json ]; then
    echo "⚠ state.json exists (previous session state)"
  fi

  # Check for lock file (Ralph might be running)
  if [ -f .ralph-tui.lock ]; then
    echo "⚠ .ralph-tui.lock exists - Ralph may be running!"
  fi
else
  echo "OK: No existing .ralph-tui/ state"
fi

If existing state is found, determine the situation:

AskUserQuestion: "Found existing Ralph state from a previous run. What's the situation?"
├── "Previous run is complete, clean up for new PRD"
│   → Clean .ralph-tui/iterations/, progress.md, state.json
│   → Keep config.toml and templates
├── "Previous run is still active (different PRD)"
│   → Create new worktree for this PRD
│   → Keep current directory untouched
├── "Save progress to branch first, then clean"
│   → Commit current progress
│   → Clean for new PRD
└── "Let me check the progress first"
│   → Show progress.md contents
│   → Show iteration count
│   → Re-ask after review

Cleanup commands (if user chooses to clean):

# Remove iteration logs
rm -rf .ralph-tui/iterations/*

# Clear progress file (keep file, clear content)
echo "" > .ralph-tui/progress.md

# Remove session state
rm -f .ralph-tui/state.json
rm -f .ralph-tui.lock
rm -f .ralph-tui-session.json

# Verify cleanup
ls -la .ralph-tui/
echo "Cleaned. Ready for new Ralph loop."

If previous run is still active:

# Check current branch
CURRENT_BRANCH=$(git branch --show-current)
echo "Current branch: $CURRENT_BRANCH"

# Suggest worktree for new PRD
REPO_NAME=$(basename $(git rev-parse --show-toplevel))
echo "Suggested worktree: ../${REPO_NAME}-[new-prd-name]"

Then proceed to Phase 7 for worktree setup.


Phase 2: Configuration Validation

2.1 Locate.ralph-tui/config.toml

# Check project config exists
if [ -f .ralph-tui/config.toml ]; then
  echo "OK: Config found at .ralph-tui/config.toml"
else
  echo "ERROR: No .ralph-tui/config.toml found"
  echo "Run: ralph-tui setup"
fi

2.2 Validate Config Settings

Read config.toml and verify critical settings:

SettingRequired ValueCheck
tracker"json"Must be json for prd.json execution
agent"claude"Claude agent
prompt_templatePath existsTemplate file must exist
model"opus" or "sonnet"Valid model
maxIterations> 0Reasonable iteration limit

2.3 Show Template Source

ralph-tui template show | head -5

Verify it's loading from expected location (not default).


Phase 3: Template Validation

3.1 Locate prompt.hbs

Get template path from config.toml prompt_template setting and verify file exists:

# Extract template path from config
grep "prompt_template" .ralph-tui/config.toml
# Verify file exists
ls -la [extracted-path]

3.2 Template Variable Check

Read the prompt.hbs and verify it uses these required variables:

PRD Variables:

  • {{prdName}} - Project name
  • {{prdDescription}} - Project overview
  • {{prdCompletedCount}} / {{prdTotalCount}} - Progress
  • {{currentIteration}} - Current iteration number (REQUIRED in header)

Task Variables:

  • {{taskId}} - Story ID (e.g., US-001)
  • {{taskTitle}} - Story title
  • {{taskDescription}} - What and why (includes embedded tasks)
  • {{acceptanceCriteria}} - Auto-formatted checkbox list
  • {{notes}} - Additional context
  • {{dependsOn}} - Prerequisites

Context Variables:

  • {{codebasePatterns}} - Discovered patterns (optional)

DEPRECATED (should NOT be in template):

  • {{recentProgress}} - Agent reads .ralph-tui/progress.md directly as first action

3.3 Template Quality Check (Optimized v2)

Verify template includes all critical elements:

Structure Checks:

  • Template does NOT include {{recentProgress}} (agent reads file directly - this is redundant)
  • Template includes {{currentIteration}} in header for tracking
  • Template has explicit "Context Files (Read These First)" section with:

- Path to .ralph-tui/progress.md - Instruction to find PRD.md in same directory as prd.json

Workflow Checks:

  • Template includes 3-phase workflow: Context Gathering → Implementation → Documentation
  • Phase 3 includes gibberish cleanup instructions (remove JSON fragments, malformed entries)
  • Template defines verbose progress entry format with sections:

- "What was implemented" (detailed descriptions) - "Files changed" (paths with descriptions) - "Learnings" (patterns, gotchas, architecture insights) - "Quality gate" (command output, test results)

Rules Checks:

  • Template says "Be verbose and thorough - future iterations start with no memory"
  • Template instructs to delete malformed entries (JSON fragments, "type":"message", gibberish)
  • Completion signals (COMPLETE, BLOCKED, SKIP, EJECT)
  • Loop awareness (starts fresh each iteration, must read progress.md)

Context References:

  • Reference to CLAUDE.md for project commands/conventions
  • Reference to progress.md for iteration context
  • Reference to PRD.md for full project goals

3.4 Template Anti-Pattern Detection

Flag these issues if found:

IssueProblemFix
{{recentProgress}} in templateRedundant - agent reads file directlyRemove the section
No {{currentIteration}}Can't track which iteration in logsAdd to header
No gibberish cleanup instructionJSON fragments accumulate in progress.mdAdd Phase 3 step 7
Simple progress formatFuture iterations lack contextUse verbose 4-section format
No "start with no memory" warningAgent may not document thoroughlyAdd to rules section

Phase 4: PRD Validation

4.1 Discover prd.json

Search for prd.json files:

find . -name "prd.json" -not -path "*/node_modules/*" 2>/dev/null

If multiple found, ask user to select. If none found, report and exit.

4.2 Validate prd.json Structure

Read the prd.json and verify required fields:

{
  "name": "required - kebab-case",
  "description": "required - project context",
  "branchName": "required - git branch name",
  "userStories": [
    {
      "id": "required - e.g., US-001",
      "title": "required - short title",
      "description": "required - what and why",
      "acceptanceCriteria": "required - array of strings",
      "dependsOn": "optional - array of story IDs",
      "notes": "optional - additional context",
      "passes": "required - boolean, should be false initially"
    }
  ]
}

4.3 Template Variable Mapping

Verify prd.json fields will map correctly to template:

prd.json FieldTemplate VariableStatus
name{{prdName}}Check
description{{prdDescription}}Check
userStories[].id{{taskId}}Check
userStories[].title{{taskTitle}}Check
userStories[].description{{taskDescription}}Check
userStories[].acceptanceCriteria{{acceptanceCriteria}}Check
userStories[].notes{{notes}}Check
userStories[].dependsOn{{dependsOn}}Check

4.4 Tasks in Description Check

Verify each story's description includes embedded tasks:

**Tasks:**
1. First task
2. Second task

WARNING: Tasks are NOT a separate field - they must be in the description.

4.5 Acceptance Criteria Format

Verify acceptanceCriteria is an array of strings (Ralph auto-converts to checkboxes).


Phase 5: Project Context Validation

5.1 Local CLAUDE.md Check

if [ -f CLAUDE.md ]; then
  echo "OK: Local CLAUDE.md found"
  # Check it has key sections
  grep -l "Commands\|Development\|Project" CLAUDE.md
else
  echo "WARNING: No local CLAUDE.md - Ralph will rely on global context"
fi

5.2 PRD.md Discovery

Check for human-readable PRD document:

find . -name "PRD.md" -o -name "prd.md" | head -5

If found, note the path for the prompt template enhancement.

5.3 Progress.md Path

Verify progress file path from config:

grep "progressFile" .ralph-tui/config.toml
# Default: .ralph-tui/progress.md

Phase 6: Pre-Launch Summary

6.1 Generate Report

Present a clear summary:

═══════════════════════════════════════════════════════════════════════════
Ralph TUI Pre-Flight Check Results
═══════════════════════════════════════════════════════════════════════════

Environment
├── Global CLAUDE.md: ✗ Not found (good) / ⚠ Found (may conflict)
├── Ralph TUI: ✓ v0.x.x installed
├── tmux: ✓ v3.x installed
├── git: ✓ v2.x installed
└── Existing State: ✓ Clean / ⚠ Previous run detected (action taken)

Existing State Details (if found)
├── progress.md: [X lines] / Empty
├── iterations/: [X files] / Empty
├── state.json: Found / Not found
└── Lock file: ⚠ Running / Not found

Configuration (.ralph-tui/config.toml)
├── Tracker: json ✓
├── Agent: claude ✓
├── Model: opus ✓
├── Max Iterations: 70 ✓
├── Template Path: .ralph-tui/templates/prompt.hbs ✓
└── PRD Path: [discovered path] ✓

Template (.ralph-tui/templates/prompt.hbs)
├── File exists: ✓
├── PRD variables: ✓
├── Task variables: ✓
├── Context variables: ✓
├── Workflow section: ✓
└── Completion signals: ✓

PRD (docs/prds/[name]/prd.json)
├── Name: [prd-name] ✓
├── Branch: [branch-name] ✓
├── Stories: [count] stories ✓
├── All have IDs: ✓
├── All have descriptions: ✓
├── All have acceptance criteria: ✓
└── Tasks embedded in descriptions: ✓

Project Context
├── Local CLAUDE.md: ✓ Found
├── PRD.md: ✓ Found at [path]
└── Progress tracking: .ralph-tui/progress.md (clean)

═══════════════════════════════════════════════════════════════════════════

6.2 Issues Found

If any issues were found, list them with severity:

Issues Found:
├── [CRITICAL] Global CLAUDE.md may override local context
├── [CRITICAL] Existing Ralph state - may confuse model with old progress
├── [CRITICAL] Lock file present - Ralph may already be running
├── [WARNING] Story US-003 missing tasks in description
└── [INFO] Model set to sonnet, opus recommended for complex work

Phase 7: Launch Options

7.1 Worktree vs Branch Question

AskUserQuestion: "How do you want to run this Ralph loop?"
├── "Branch only" - Create/switch to feature branch in current directory
├── "Worktree" - Create isolated worktree for parallel development
└── "Already set up" - Skip branch/worktree setup

7.2 Branch Setup (if selected)

# Determine base branch
git branch --show-current

# Create and checkout feature branch
git checkout -b [branchName-from-prd]

7.3 Worktree Setup (if selected)

# Get repo name and PRD name
REPO_NAME=$(basename $(git rev-parse --show-toplevel))
PRD_NAME=[name-from-prd]

# Create worktree
git worktree add ../${REPO_NAME}-${PRD_NAME} -b [branchName-from-prd]

# Show next steps
echo "Worktree created at: ../${REPO_NAME}-${PRD_NAME}"
echo "cd ../${REPO_NAME}-${PRD_NAME}"

7.4 Generate Launch Commands

Provide ready-to-copy commands:

═══════════════════════════════════════════════════════════════════════════
Launch Commands
═══════════════════════════════════════════════════════════════════════════

Option 1: Run in new tmux session (recommended)
───────────────────────────────────────────────────────────────────────────
tmux new-session -d -s ralph-[prd-name] "ralph-tui run --prd [prd-path]"
tmux attach-session -t ralph-[prd-name]
# Press 's' to start, then Ctrl+B D to detach

Option 2: Run directly (stays in foreground)
───────────────────────────────────────────────────────────────────────────
ralph-tui run --prd [prd-path]

Option 3: Run with verification (recommended first time)
───────────────────────────────────────────────────────────────────────────
ralph-tui run --prd [prd-path] --verify

Monitoring:
───────────────────────────────────────────────────────────────────────────
# Check progress
cat .ralph-tui/progress.md

# View iteration logs
ralph-tui logs

# Check session status
ralph-tui status

# Reattach to tmux
tmux attach-session -t ralph-[prd-name]
═══════════════════════════════════════════════════════════════════════════

Quick Reference

Template Variables from Ralph TUI

VariableSourceDescription
{{prdName}}prd.json nameProject name
{{prdDescription}}prd.json descriptionProject context
{{prdCompletedCount}}CalculatedCompleted stories
{{prdTotalCount}}CalculatedTotal stories
{{currentIteration}}CalculatedCurrent iteration number
{{taskId}}userStories[].idCurrent story ID
{{taskTitle}}userStories[].titleCurrent story title
{{taskDescription}}userStories[].descriptionStory description (includes tasks)
{{acceptanceCriteria}}userStories[].acceptanceCriteriaAuto-formatted checkboxes
{{notes}}userStories[].notesAdditional context
{{dependsOn}}userStories[].dependsOnPrerequisites
{{codebasePatterns}}.ralph-tui/progress.mdDiscovered patterns

DEPRECATED - Do NOT use:

VariableReason
{{recentProgress}}Redundant - agent reads .ralph-tui/progress.md directly as first action every iteration

Common Issues

IssueSolution
Global CLAUDE.md overrides localRename ~/.claude/CLAUDE.md to .bak
Existing state from previous runClean iterations/, progress.md, state.json OR use worktree
Lock file presentAnother Ralph may be running; check tmux sessions
Template not loadingCheck prompt_template path in config.toml
Tasks not showingEmbed tasks in description field, not separate
acceptanceCriteria emptyEnsure it's an array of strings
Progress corruptedCheck .ralph-tui.lock, use ralph-tui resume
Model confused by old progressClean progress.md before starting new PRD
Gibberish/JSON in progress.mdTemplate should include cleanup instructions in Phase 3
Duplicate progress entriesRalph auto-appends + agent appends; use cleanup instructions
Template uses {{recentProgress}}Remove it - agent reads file directly (redundant)
Missing {{currentIteration}}Add to header for iteration tracking
Sparse progress notesUse verbose 4-section format; add "no memory" warning

Ralph TUI Commands

ralph-tui template show     # Show current template
ralph-tui doctor            # Diagnose issues
ralph-tui config show       # Show merged config
ralph-tui status            # Check session status
ralph-tui resume            # Resume interrupted session
ralph-tui logs              # View iteration logs

平台分布

Claude Code

32.61%
按下载量换算32

Codex

25.04%
按下载量换算24

windsurf

16.89%
按下载量换算16

OpenCode

12.23%
按下载量换算12

Antigravity

8.57%
按下载量换算8

Gemini CLI

3.55%
按下载量换算3

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

只读

该 Skill 主要提供规则、说明或参考内容,本身偏只读;真正读写文件、联网或执行命令仍取决于宿主 Agent 的任务。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

继续浏览同类 Skills