Rig Implement
Execute a frozen plan or bounded change, run configured gates, and produce an evidence-backed commit handoff.
Files1
View on GitHubSKILL.mdplugins/opencode-rig/src/resources/skills/rig-implement/SKILL.md
GitHubRig Implement
Read Evidence rules and Commit handoff.
Input
- A frozen
plan.mdwith its digest, or a bounded change with explicit scope. - Optional:
kind=feature,fix,refactor, orperf.
Workflow
- Revalidate the plan. Read current source and compare it with the plan's assumptions. If source contradicts the plan, stop and report; do not rewrite the plan.
- Start the run.
rig_evidencewithaction: "start",skill: "rig-implement", target paths, and the plan path. Record the plan digest. - Establish a baseline. Run the narrowest relevant test or reproduction before editing. For a refactor, capture characterization tests first.
- Implement in batches. Group non-overlapping edits and their tests into one batch. Run the focused check after each batch. When a batch fails, bisect to the smallest edit so attribution is not lost.
- Reconcile the scope. After the last edit and any formatter, call
rig_evidencewithaction: "refresh"and amessagenaming what changed. This is the only way the run adopts edited source. - Run configured gates. Call
rig_gatewithaction: "run"and the run ID. Fix failures and rerun the same gate. Never retry a failing gate unchanged, and never substitute a manual claim for a failed check. If a gate rewrites files, refresh the scope and rerun that gate. - Record outputs.
rig_evidencewithaction: "record"for changed paths, limits, and any decision that future readers need. - Finalize.
rig_evidencewithaction: "finalize". A failed gate or source drift blocks completion; drift means refresh and rerun, never editing the record. - Commit handoff. Propose the exact commit message and paths. A plain commit runs when the user asked for it or a local Git grant covers it; otherwise ask once. Never push.
Rules
- Do not touch paths outside the owned set without saying so and getting scope approval.
- Do not delete or weaken tests to reach green.
- Preserve unrelated working-tree changes.
- Keep the change minimal: no opportunistic refactors outside the plan.
- Report incomplete work as incomplete; a partial fix with a clear stop is valid.
Output
Report run ID, changed paths with digests, gate receipts, failed or skipped checks, remaining risks, and the commit handoff. Do not claim completion without a finalized run.