Phase 1 - Planning: Create an implementation plan from the spec
- If ralplan consensus plan exists: Skip — already done in the 3-stage pipeline
- Architect (Opus): Create plan (direct mode, no interview)
- Critic (Opus): Validate plan
- Output:
.omc/plans/autopilot-impl.md
Phase 2 - Execution: Implement the plan using Ralph + Ultrawork
- Executor (Haiku): Simple tasks
- Executor (Sonnet): Standard tasks
- Executor (Opus): Complex tasks
- Run independent tasks in parallel
Phase 3 - QA: Cycle until all tests pass (UltraQA mode)
- Build, lint, test, fix failures
- Repeat up to 5 cycles
- Stop early if the same error repeats 3 times (indicates a fundamental issue)
Phase 4 - Validation: Multi-perspective review in parallel
- Architect: Functional completeness
- Security-reviewer: Vulnerability check
- Code-reviewer: Quality review
- All must approve; fix and re-validate on rejection
Phase 5 - Cleanup: Delete all state files on successful completion
- Remove
.omc/state/autopilot-state.json, ralph-state.json, ultrawork-state.json, ultraqa-state.json
- Run
/oh-my-claudecode:cancel for clean exit
Optional settings in .gemini/antigravity/settings.json:
{
"omc": {
"autopilot": {
"maxIterations": 10,
"maxQaCycles": 5,
"maxValidationRounds": 3,
"pauseAfterExpansion": false,
"pauseAfterPlanning": false,
"skipQa": false,
"skipValidation": false
}
}
}
Resume
If autopilot was cancelled or failed, run /oh-my-claudecode:autopilot again to resume from where it stopped.
Best Practices for Input
- Be specific about the domain -- "bookstore" not "store"
- Mention key features -- "with CRUD", "with authentication"
- Specify constraints -- "using TypeScript", "with PostgreSQL"
- Let it run -- avoid interrupting unless truly needed
Troubleshooting
Stuck in a phase? Check TODO list for blocked tasks, review .omc/autopilot-state.json, or cancel and resume.
QA cycles exhausted? The same error 3 times indicates a fundamental issue. Review the error pattern; manual intervention may be needed.
Validation keeps failing? Review the specific issues. Requirements may have been too vague -- cancel and provide more detail.
Deep Interview Integration
When autopilot is invoked with a vague input, Phase 0 can redirect to /deep-interview for Socratic clarification:
User: "autopilot build me something cool"
Autopilot: "Your request is open-ended. Would you like to run a deep interview first?"
[Yes, interview first (Recommended)] [No, expand directly]
If a deep-interview spec already exists at .omc/specs/deep-interview-*.md, autopilot uses it directly as Phase 0 output (the spec has already been mathematically validated for clarity).
3-Stage Pipeline: deep-interview → ralplan → autopilot
The recommended full pipeline chains three quality gates:
/deep-interview "vague idea"
→ Socratic Q&A → spec (ambiguity ≤ 20%)
→ /ralplan --direct → consensus plan (Planner/Architect/Critic approved)
→ /autopilot → skips Phase 0+1, starts at Phase 2 (Execution)
When autopilot detects a ralplan consensus plan (.omc/plans/ralplan-*.md or .omc/plans/consensus-*.md), it skips both Phase 0 (Expansion) and Phase 1 (Planning) because the plan has already been:
- Requirements-validated (deep-interview ambiguity gate)
- Architecture-reviewed (ralplan Architect agent)
- Quality-checked (ralplan Critic agent)
Autopilot starts directly at Phase 2 (Execution via Ralph + Ultrawork).
1---2name: autopilot3description: Full autonomous execution from idea to working code4---56<Purpose>7Autopilot takes a brief product idea and autonomously handles the full lifecycle: requirements analysis, technical design, planning, parallel implementation, QA cycling, and multi-perspective validation. It produces working, verified code from a 2-3 line description.8</Purpose>910<Use_When>11- User wants end-to-end autonomous execution from an idea to working code12- User says "autopilot", "auto pilot", "autonomous", "build me", "create me", "make me", "full auto", "handle it all", or "I want a/an..."13- Task requires multiple phases: planning, coding, testing, and validation14- User wants hands-off execution and is willing to let the system run to completion15</Use_When>1617<Do_Not_Use_When>18- User wants to explore options or brainstorm -- use `plan` skill instead19- User says "just explain", "draft only", or "what would you suggest" -- respond conversationally20- User wants a single focused code change -- use `ralph` or delegate to an executor agent21- User wants to review or critique an existing plan -- use `plan --review`22- Task is a quick fix or small bug -- use direct executor delegation23</Do_Not_Use_When>2425<Why_This_Exists>26Most non-trivial software tasks require coordinated phases: understanding requirements, designing a solution, implementing in parallel, testing, and validating quality. Autopilot orchestrates all of these phases automatically so the user can describe what they want and receive working code without managing each step.27</Why_This_Exists>2829<Execution_Policy>30- Each phase must complete before the next begins31- Parallel execution is used within phases where possible (Phase 2 and Phase 4)32- QA cycles repeat up to 5 times; if the same error persists 3 times, stop and report the fundamental issue33- Validation requires approval from all reviewers; rejected items get fixed and re-validated34- Cancel with `/oh-my-claudecode:cancel` at any time; progress is preserved for resume35</Execution_Policy>3637<Steps>381. **Phase 0 - Expansion**: Turn the user's idea into a detailed spec39 - **If ralplan consensus plan exists** (`.omc/plans/ralplan-*.md` or `.omc/plans/consensus-*.md` from the 3-stage pipeline): Skip BOTH Phase 0 and Phase 1 — jump directly to Phase 2 (Execution). The plan has already been Planner/Architect/Critic validated.40 - **If deep-interview spec exists** (`.omc/specs/deep-interview-*.md`): Skip analyst+architect expansion, use the pre-validated spec directly as Phase 0 output. Continue to Phase 1 (Planning).41 - **If input is vague** (no file paths, function names, or concrete anchors): Offer redirect to `/deep-interview` for Socratic clarification before expanding42 - **Otherwise**: Analyst (Opus) extracts requirements, Architect (Opus) creates technical specification43 - Output: `.omc/autopilot/spec.md`44452. **Phase 1 - Planning**: Create an implementation plan from the spec46 - **If ralplan consensus plan exists**: Skip — already done in the 3-stage pipeline47 - Architect (Opus): Create plan (direct mode, no interview)48 - Critic (Opus): Validate plan49 - Output: `.omc/plans/autopilot-impl.md`50513. **Phase 2 - Execution**: Implement the plan using Ralph + Ultrawork52 - Executor (Haiku): Simple tasks53 - Executor (Sonnet): Standard tasks54 - Executor (Opus): Complex tasks55 - Run independent tasks in parallel56574. **Phase 3 - QA**: Cycle until all tests pass (UltraQA mode)58 - Build, lint, test, fix failures59 - Repeat up to 5 cycles60 - Stop early if the same error repeats 3 times (indicates a fundamental issue)61625. **Phase 4 - Validation**: Multi-perspective review in parallel63 - Architect: Functional completeness64 - Security-reviewer: Vulnerability check65 - Code-reviewer: Quality review66 - All must approve; fix and re-validate on rejection67686. **Phase 5 - Cleanup**: Delete all state files on successful completion69 - Remove `.omc/state/autopilot-state.json`, `ralph-state.json`, `ultrawork-state.json`, `ultraqa-state.json`70 - Run `/oh-my-claudecode:cancel` for clean exit71</Steps>7273<Tool_Usage>74- Use `Task(subagent_type="oh-my-claudecode:architect", ...)` for Phase 4 architecture validation75- Use `Task(subagent_type="oh-my-claudecode:security-reviewer", ...)` for Phase 4 security review76- Use `Task(subagent_type="oh-my-claudecode:code-reviewer", ...)` for Phase 4 quality review77- Agents form their own analysis first, then spawn Antigravity Task agents for cross-validation78- Never block on external tools; proceed with available agents if delegation fails79</Tool_Usage>8081<Examples>82<Good>83User: "autopilot A REST API for a bookstore inventory with CRUD operations using TypeScript"84Why good: Specific domain (bookstore), clear features (CRUD), technology constraint (TypeScript). Autopilot has enough context to expand into a full spec.85</Good>8687<Good>88User: "build me a CLI tool that tracks daily habits with streak counting"89Why good: Clear product concept with a specific feature. The "build me" trigger activates autopilot.90</Good>9192<Bad>93User: "fix the bug in the login page"94Why bad: This is a single focused fix, not a multi-phase project. Use direct executor delegation or ralph instead.95</Bad>9697<Bad>98User: "what are some good approaches for adding caching?"99Why bad: This is an exploration/brainstorming request. Respond conversationally or use the plan skill.100</Bad>101</Examples>102103<Escalation_And_Stop_Conditions>104- Stop and report when the same QA error persists across 3 cycles (fundamental issue requiring human input)105- Stop and report when validation keeps failing after 3 re-validation rounds106- Stop when the user says "stop", "cancel", or "abort"107- If requirements were too vague and expansion produces an unclear spec, offer redirect to `/deep-interview` for Socratic clarification, or pause and ask the user for clarification before proceeding108</Escalation_And_Stop_Conditions>109110<Final_Checklist>111- [ ] All 5 phases completed (Expansion, Planning, Execution, QA, Validation)112- [ ] All validators approved in Phase 4113- [ ] Tests pass (verified with fresh test run output)114- [ ] Build succeeds (verified with fresh build output)115- [ ] State files cleaned up116- [ ] User informed of completion with summary of what was built117</Final_Checklist>118119<Advanced>120## Configuration121122Optional settings in `.gemini/antigravity/settings.json`:123124```json125{126 "omc": {127 "autopilot": {128 "maxIterations": 10,129 "maxQaCycles": 5,130 "maxValidationRounds": 3,131 "pauseAfterExpansion": false,132 "pauseAfterPlanning": false,133 "skipQa": false,134 "skipValidation": false135 }136 }137}138```139140## Resume141142If autopilot was cancelled or failed, run `/oh-my-claudecode:autopilot` again to resume from where it stopped.143144## Best Practices for Input1451461. Be specific about the domain -- "bookstore" not "store"1472. Mention key features -- "with CRUD", "with authentication"1483. Specify constraints -- "using TypeScript", "with PostgreSQL"1494. Let it run -- avoid interrupting unless truly needed150151## Troubleshooting152153**Stuck in a phase?** Check TODO list for blocked tasks, review `.omc/autopilot-state.json`, or cancel and resume.154155**QA cycles exhausted?** The same error 3 times indicates a fundamental issue. Review the error pattern; manual intervention may be needed.156157**Validation keeps failing?** Review the specific issues. Requirements may have been too vague -- cancel and provide more detail.158159## Deep Interview Integration160161When autopilot is invoked with a vague input, Phase 0 can redirect to `/deep-interview` for Socratic clarification:162163```164User: "autopilot build me something cool"165Autopilot: "Your request is open-ended. Would you like to run a deep interview first?"166 [Yes, interview first (Recommended)] [No, expand directly]167```168169If a deep-interview spec already exists at `.omc/specs/deep-interview-*.md`, autopilot uses it directly as Phase 0 output (the spec has already been mathematically validated for clarity).170171### 3-Stage Pipeline: deep-interview → ralplan → autopilot172173The recommended full pipeline chains three quality gates:174175```176/deep-interview "vague idea"177 → Socratic Q&A → spec (ambiguity ≤ 20%)178 → /ralplan --direct → consensus plan (Planner/Architect/Critic approved)179 → /autopilot → skips Phase 0+1, starts at Phase 2 (Execution)180```181182When autopilot detects a ralplan consensus plan (`.omc/plans/ralplan-*.md` or `.omc/plans/consensus-*.md`), it skips both Phase 0 (Expansion) and Phase 1 (Planning) because the plan has already been:183- Requirements-validated (deep-interview ambiguity gate)184- Architecture-reviewed (ralplan Architect agent)185- Quality-checked (ralplan Critic agent)186187Autopilot starts directly at Phase 2 (Execution via Ralph + Ultrawork).188</Advanced>