Docs · The planning model

How Corvi builds a plan.

Draft → review → synthesize: three model passes, each on its own model, turning a sentence into a code-grounded contract for the work.

Three passes

A plan is the contract for the work, so Corvi makes one model draft it, a second tear it apart, and a third reconcile the result. Each pass runs on its own model — disagreement between them is the point.

  • Draft. A capable model reads your workspace through the broker and writes the first plan — milestones, concrete changes, tests-first steps — exploring the code so each step lands at a real path and symbol.
  • Review. A different-family model reviews the draft like a senior engineer: challenging confident-but-wrong claims, flagging missing edge cases, and checking the plan is grounded in the files it cites.
  • Synthesize. A third pass folds the findings into one de-conflicted plan — no contradictions, decisions made. This is the artifact the rest of the flow is held to.

Blast radius

A plan lists more than the files it edits — it surfaces the callers and dependents a change ripples into. Seeing the downstream surface before you approve is how you catch the edge the plan didn't name, so the review reads the whole shape of the change, not just its centre.

The approval gate

A plan runs only once you approve it. Edit it after sign-off and it asks for approval again before it executes or opens a PR. The approved plan is the contract the agent is held to, and the plan outranks the reviewer — a deliberate planning decision isn't silently reverted for a bot comment. This is the human approving the plan; it is separate from any later review of the resulting code.

Plan types

Feature, bugfix, refactor, migration — each type shapes how the engine structures the work and what it looks for. Pick the one that matches the task; it's the cheapest signal you can give. From the CLI, the type is inferred from the prompt and the structured pass.

Choosing models

Bring your own keys and assign a model per pass, or use a preset. Which model is best for a pass varies with the prompt, the repo, the programming language, and its size — Corvi maintains a standing benchmark and updates the preset defaults when a better drafter or reviewer ships, without you touching a setting.

When you need a grounded sketch now rather than a reviewed contract, the ⚡ Quick path (--quick) returns a single-pass draft in under a minute, upgradeable to the full pipeline in one click.

Next steps