ralph-loop
자기교정 반복 루프. 완료까지 자동으로 반복 실행합니다. "루프", "완료까지", "계속 해줘", "ralph-loop", "ulw-loop" 트리거로 사용합니다. oh-my-opencode의 Ralph Loop를 Copilot CLI에 포팅한 스킬입니다.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
자기교정 반복 루프. 완료까지 자동으로 반복 실행합니다. "루프", "완료까지", "계속 해줘", "ralph-loop", "ulw-loop" 트리거로 사용합니다. oh-my-opencode의 Ralph Loop를 Copilot CLI에 포팅한 스킬입니다.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
oh-my-opencode를 Copilot CLI용으로 포팅한 멀티에이전트 오케스트레이션 플러그인. Sisyphus(오케스트레이터) + Hephaestus(딥워커) + Prometheus(플래너) + Ralph Loop. "/ultrawork 태스크설명" 으로 시작하면 모든 에이전트가 자동 활성화됩니다.
Master Orchestrator agent. Delegates ALL work to sub-agents via task(). Reads plan, parallelizes independent tasks, verifies every delegation with lsp_diagnostics + manual code review. Use for complex multi-task execution. (Atlas - oh-my-opencode port)
Copilot CLI session history and self-improvement. Use /chronicle to generate standup reports, personalized tips, and improve custom instructions. Trigger: "chronicle", "standup", "session history", "improve instructions"
Browser automation with persistent page state. Use when asked to navigate websites, fill forms, take screenshots, extract web data, test web apps, or automate browser workflows. Trigger: 'go to [url]', 'click on', 'fill out the form', 'take a screenshot', 'scrape', 'automate', 'test the website'. (dev-browser - oh-my-opencode port)
Diagnose and fix oh-my-copilot installation issues. Checks plugin path, broken symlinks, dependencies (sqlite3/jq/git), hooks.json validity, script permissions, and plugin version. Trigger with "doctor", "진단", "install check", "헬스체크", "health check".
Contextual grep for codebases. Answers 'Where is X?', 'Which file has Y?', 'Find the code that does Z'. Fire multiple in parallel for broad searches. Specify thoroughness: quick/medium/very thorough. (Explore - oh-my-opencode port)
| name | ralph-loop |
| version | 1.0.0 |
| description | 자기교정 반복 루프. 완료까지 자동으로 반복 실행합니다. "루프", "완료까지", "계속 해줘", "ralph-loop", "ulw-loop" 트리거로 사용합니다. oh-my-opencode의 Ralph Loop를 Copilot CLI에 포팅한 스킬입니다. |
| allowed-tools | ["Bash","Read","Write","Edit","Glob","Grep"] |
"완료될 때까지 멈추지 않는다."
/ralph-loop "모든 TypeScript 에러 수정"
/ralph-loop "태스크 설명" --max-iterations=50
/ulw-loop "태스크 설명" # ultrawork + loop 모드
/cancel-ralph # 실행 중인 루프 취소
⚠️ NEVER declare done without DONE ⚠️ NEVER give up after first failure — try different approaches ⚠️ ALWAYS maintain TodoWrite tracking ⚠️ ALWAYS verify before marking complete
| Ralph Loop | ULW Loop | |
|---|---|---|
| 종료 조건 | 완료 promise 태그 출력 | Oracle 검증 + promise 태그 |
| 반복 한도 | 기본 100회 (설정 가능) | 없음 |
| 검증 수준 | 자체 검증 | Oracle 독립 검증 |
| 사용 시기 | 일반 작업 | 크리티컬 작업 |
태스크 수신 → 즉시 TodoWrite (원자적 스텝으로):
TodoWrite([
{ id: "analyze", content: "현재 상태 분석", status: "in_progress" },
{ id: "step-1", content: "[구체적 스텝 1]", status: "pending" },
{ id: "step-2", content: "[구체적 스텝 2]", status: "pending" },
{ id: "verify", content: "결과 검증", status: "pending" }
])
ITERATION N:
1. 남은 TodoWrite 항목 확인
2. 다음 pending 항목을 in_progress로
3. 해당 작업 실행
4. 결과 즉시 검증
5. completed 또는 failed 표시
6. 다음 반복 또는 완료 판정
각 반복 후 체크:
□ 모든 TodoWrite 항목 completed?
□ 빌드/타입 에러 없음?
□ 테스트 통과?
□ 완료 기준 충족?
모두 통과 시:
<promise>DONE</promise>
→ 이 태그가 없으면 루프 계속 실행
실패 항목 있을 시:
같은 에러가 3회 이상 반복되면 자동으로 사용자에게 구조화된 선택지를 제시:
ask_user(
question="[에러 내용] — 같은 실패가 3회 반복됐습니다. 어떻게 진행할까요?",
choices=["계속 — 다른 접근법으로 재시도 (Recommended)", "전략 변경 — 새로운 전략을 제안해주세요", "중단 — 현재까지 완료된 것만 유지", "건너뛰기 — 이 항목 스킵하고 다음으로"]
)
선택별 동작:
<promise>DONE</promise> 출력, 미완료 항목 목록 표시skipped로 표시, 다음 항목 진행/ulw-loop 모드에서는 추가 Oracle 검증 단계:
1. 자체 작업 완료 → <promise>DONE</promise> 출력
2. Oracle 검증 프롬프트 실행:
"방금 구현한 것이 요청 사항을 완전히 충족하는가?
A) 충족 — 명확한 증거 제시
B) 미충족 — 누락된 것 명시
C) 부분 충족 — 완료된 것과 남은 것 구분"
3. A만 진짜 완료
4. B 또는 C → 루프 재시작
Every 10 iterations (10, 20, 30...), write a Loop Summary:
[LOOP-SUMMARY iteration={N} of={max}]
Task: {original task description}
Progress: {items done}/{total items}
Completed: {brief list of done items}
Failed & retried: {items that needed retry}
Current focus: {what iteration N+1 will work on}
Remaining: {pending items count}
[/LOOP-SUMMARY]
Context management thresholds:
/compact/compact before continuing/compact: Re-read the latest Loop Summary, re-state remaining todos, continueNote: Context percentage is estimated by the agent based on the volume of file reads, command outputs, and conversation length.
For high-iteration tasks (50+ expected iterations):
--strategy=continue (default)/compact, the Loop Summary is the recovery checkpoint[MULTI-TURN-RALPH-LOOP]
When MULTI_TURN_AGENTS is available (detected by write_agent tool presence), the ralph loop can keep verification agents alive across iterations instead of spawning new ones each cycle.
iteration 1: task(verifier) → read_agent → done → discard
iteration 2: task(verifier) → read_agent → done → discard ← full context rebuild
iteration 3: task(verifier) → read_agent → done → discard ← full context rebuild
loop_start → task(verifier, mode="background")
→ [write_agent(fix_1) → read_agent]*
→ [write_agent(fix_2) → read_agent]*
→ ...
→ [write_agent(fix_N) → read_agent]*
→ loop_end
write_agent returns an error or the agent is no longer idle, fall back to spawning a new verifier[LOOP-SUMMARY] checkpoint should note multi-turn agent status:[LOOP-SUMMARY iteration={N} of={max}]
...existing fields...
Multi-turn verifier: {agent_id} (turn {T}, status: {idle|completed})
[/LOOP-SUMMARY]
[/MULTI-TURN-RALPH-LOOP]
When BACKGROUND_SESSIONS experimental feature is enabled, ralph-loop can opt into persistent mode that survives session restarts.
~/.copilot/oh-my-copilot/ralph-state.json{
"version": 1,
"active": true,
"iteration": 3,
"max_iterations": 10,
"task": "Review and correct all Phase 1-3 changes",
"phase": "verification",
"last_result": "3 issues found, 2 fixed",
"todos": ["fix-permissions-cache", "verify-q-learning"],
"started_at": "2025-01-15T10:00:00Z",
"updated_at": "2025-01-15T10:05:00Z"
}
💡 This uses
t-state_write(mode: "ralph")/t-state_read(mode: "ralph")tools when available, falling back to direct JSON file I/O.
/ralph-loop "모든 TypeScript 컴파일 에러 수정"
→ 루프 내부:
1. npx tsc --noEmit 2>&1 실행
2. 에러 목록 파싱
3. 각 에러를 TodoWrite로
4. 에러별 수정
5. 다시 tsc 실행
6. 에러 없으면 <promise>DONE</promise>
/ralph-loop "모든 테스트 통과"
→ 루프 내부:
1. npm test 실행
2. 실패 테스트 파악
3. 실패별 수정
4. 다시 npm test
5. 모두 통과 → <promise>DONE</promise>
/ralph-loop "모든 ESLint 경고 수정"
→ 루프 내부:
1. npx eslint . 실행
2. 경고 목록 파싱
3. 자동 수정 가능한 것: npx eslint . --fix
4. 수동 수정 필요한 것: TodoWrite로 개별 처리
5. 모두 해결 → <promise>DONE</promise>
실행 중 루프 취소:
/cancel-ralph
또는 Copilot CLI에서 Ctrl+C 후:
현재 루프가 취소됐습니다.
완료된 TodoWrite: [목록]
미완료 TodoWrite: [목록]
--max-iterations=N # 최대 반복 횟수 (기본: 100)
--strategy=reset # 각 반복마다 상태 초기화
--strategy=continue # 이전 상태에서 계속 (기본)
<promise>DONE</promise> 없이 루프 종료