Use this workflow when a task needs planning, implementation, and validation without mixing every responsibility into one chat.

Role split

OpenClaw

Planning, routing, context control, escalation, and done criteria.

Codex

Implementation, repo inspection, edits, tests, and verification notes.

Routing checklist

Before starting execution, lock these details:
  • Target outcome
  • Files or modules in scope
  • Explicitly out-of-scope work
  • Definition of done
  • Validation command or review method

Quality gate

Mark work done only when the requirement is met, checks pass, regression risk is noted, and the result is ready for handoff.

Failure recovery

When a run fails, classify the failure first:
The requirement was unclear, missing constraints, or mixed with unrelated goals. Rewrite the brief with narrower scope.
The implementation is wrong or incomplete. Point to the exact behavior that needs correction.
The output looks plausible but tests, lint, preview, or manual review caught a problem. Feed the failing signal back into the next pass.