Plan & Execute
Verified planning loop + post-approval autonomous execution
When to use
- You need a verified change plan before making edits
- The plan requires user approval before execution
- After approval, execution should continue autonomously
Two coupled loops
Loop A: Plan (before approval)
- Pick one unresolved plan claim. Files to change, tests to run, migration safety.
- Gather the smallest evidence. Repo excerpt, config, test output.
- Update Facts / Decisions / Assumptions.
- Audit. Run
audit_trace_budgeton plan claims. - Repeat until all plan-critical claims are supported. Then ask for approval once.
Loop B: Execute (after approval)
- Choose the smallest next patch mapped to one plan step.
- Apply, test, store outputs.
- Record attempt with keep/revert decision.
- Audit changed claims. If tests fail, revert and return to Loop A.
- Repeat until all planned changes are implemented and verified.
Copy/paste prompt
Start a run. Gather evidence for the plan.
Produce Facts (cited), Decisions, and Assumptions.
Run audit_trace_budget on plan claims.
Ask for approval once all claims are supported.
After approval, implement patches one at a time, testing each.
Record every attempt. Revert failed patches.