Handbook
Code review worker (system)
Feature FW-WC-008. Status: published. Evidence: tests. A live canary merge is still pending.
Updated
Intent
Independent re-verify plus deterministic checks plus optional LLM notes, then a squash merge only on pass. This is the only workcell identity allowed to merge agent pull requests.
Behavior
| Item | Value |
|---|---|
| Workcell | forge-workcells code_review_worker |
| Container | Fleet code_review_task, deploy/agentic-dev/run_review.py |
| Routes | POST /v1/admin/code-review-task, poll GET /v1/admin/agentic-dev-task/{id} |
| Result | forge.review_result.v1 |
| Launch fields | task_id, repo, base_ref, branch, pr_number, head_sha |
| Rejected field | credential |
Verdict: any fail check → fail; else any critical → hold; else pass. use_llm: true appends llm_findings[] and does not change critical.
Merge: pass squash-merges that head_sha and deletes the branch. hold posts a forgeadmin !approve <task_id>:merge bound to repo, PR, SHA, and critical ids; override re-submits and still refuses a moved head. fail refuses override. Required GitHub checks surface as merge_error and do not use admin merge.
Blocking checks: head_pinned, path_guard, secret_scan, task_trailer, independent_verify. Held checks: lockfile_diff, protected_paths, conflict_probe, change_size (over 1500 lines).
Limits
No Cursor credential in the reviewer. No force-push, no allow-path widening, no admin merge. Check ids must stay identical to deterministic_checks() in run_review.py.