Files
dotfiles/pi/.pi/agent/prompts/implement-critical.md

40 lines
1.5 KiB
Markdown

---
description: "Maximum quality pipeline — deep scout, Max planning, Opus plan review, approval gate, Sonnet coding, Opus code review"
---
Use the subagent tool to implement with maximum quality. This is for high-risk or architecturally significant changes.
## Step 1: Deep scout + Plan + Plan review
```
{ chain: [
{ agent: "deep-scout", task: "Thoroughly investigate all code relevant to: $@" },
{ agent: "planner", task: "Create a detailed implementation plan for: $@\n\nDeep context:\n\n{previous}" },
{ agent: "plan-reviewer", task: "Review this plan critically. Verify all file paths, line numbers, and assumptions against the codebase. Check for missing steps, edge cases, and risks.\n\n{previous}" }
]}
```
## Step 2: APPROVAL GATE
**STOP. Present the plan and the Opus review to the user.**
Show clearly:
- The implementation plan (steps, files, risks)
- Opus's verdict and any issues found
- Ask: "Approve this plan, or want changes?"
Do NOT proceed until the user explicitly approves.
If the user requests changes, revise the plan and present again.
## Step 3: Implement (only after approval)
- Use "coder-claude" (Sonnet 4.6) for the implementation steps
- For multiple independent steps, run them in parallel using separate coder-claude tasks
## Step 4: Opus review
Run the "reviewer" agent on all changes.
## Step 5: Fix
If the reviewer says NEEDS_FIXES, run the "fixer" agent with the review output.
## Step 6: Report
Summarize everything: what was planned, what was implemented, what was reviewed, what was fixed, and any remaining concerns.