Review as Closeout Check

Type: Pipeline pattern
Referenced from: openclaw-autoreview-skill

Definition

Running structured code review as the final closeout step before commit, push, or ship. The review is the last quality check — not an approval gate, not a mid-process checkpoint, but the final advisory pass that catches issues before they leave the developer's control.

Pipeline Position

Implement → Test → Format → [Review as Closeout] → Commit/Ship

The closeout check runs after formatting (which can change line locations) and after tests. If formatting or tests change code, the review reruns. The review is the last thing that runs.

Key Properties

  1. Advisory, not blocking — The review informs the ship decision but doesn't veto it.
  2. Runs on frozen state — The code under review is the final state, not a work-in-progress.
  3. Single bundle — One review call against one snapshot of the code. No incremental re-reviews.
  4. Clean = done — When the review returns no accepted findings, the closeout is complete.
  5. No redundant reruns — Don't run another review just for a cleaner report or second opinion.

Why Closeout (Not Gated)

  • Gates block progress — A review gate means every change waits for reviewer approval. Too slow for agent-driven pipelines.
  • Closeout catches residual issues — The review is a safety net, not a permission slip.
  • Advisory preserves velocity — The developer (or agent) decides what to fix based on the advisory output.

Integration with Factory Pipelines

In the Kelly factory pattern, this maps to a quality gate at the end of a pipeline stage:

DISCOVER → [research-gate] → DEFINE → [spec-gate] → BUILD → [closeout-review] → SHIP

The closeout review is the BUILD stage's exit criteria — it's advisory, but its output feeds the gate decision.

Parallel with Tests

The closeout check can run in parallel with focused tests:

Format → [Review ∥ Tests] → Fix if needed → Rerun → Clean → Ship

If tests force code changes, the review reruns. If review forces code changes, tests rerun. Convergence: no accepted findings + all tests pass.