| name | requesting-review |
| description | Dispatch code review subagent on completed work. |
Requesting Review
Dispatch an arsyn:code-reviewer subagent to catch defects before they compound. The reviewer receives crafted context — never your session history — keeping it focused on the work product.
When to Dispatch
Required: after each orchestrated task, after completing a feature, before merging to main.
Worthwhile: before refactoring (baseline audit), after resolving a tricky defect, when you want a second perspective.
Procedure
1. Determine diff range:
BASE_SHA=$(git merge-base origin/main HEAD)
HEAD_SHA=$(git rev-parse HEAD)
2. Dispatch subagent using Task tool with arsyn:code-reviewer type. Fill the template at references/code-reviewer.md.
Placeholders: {WHAT_WAS_IMPLEMENTED}, {PLAN_OR_REQUIREMENTS}, {BASE_SHA}, {HEAD_SHA}, {DESCRIPTION}.
3. Triage response:
| Severity | Action |
|---|
| Critical | Fix immediately — blocks all progress |
| Important | Fix before moving to next task |
| Minor | Log for later or fix opportunistically |
If the reviewer is wrong, push back with technical reasoning — reference tests or code that proves correctness.
Scenario: Post-Task Review in a Multi-Task Plan
[Finished Task 3: pagination for search results]
BASE_SHA=$(git log --oneline --grep="Task 2" | head -1 | awk '{print $1}')
HEAD_SHA=$(git rev-parse HEAD)
[Dispatch arsyn:code-reviewer]
WHAT_WAS_IMPLEMENTED: Cursor-based pagination for /search endpoint
PLAN_OR_REQUIREMENTS: Task 3 from docs/plans/search-overhaul.md
BASE_SHA: b4e22f1
HEAD_SHA: 9a3c8d0
DESCRIPTION: Added cursor encoding, page-size limits, next/prev links
[Reviewer returns]
Critical: Off-by-one in cursor decode skips first result
Minor: Magic number 50 for default page size
→ Fix cursor bug, extract PAGE_SIZE_DEFAULT constant, proceed to Task 4.
Workflow Integration
- Subagent-driven development: review after each task.
- Plan execution: review after each batch (~3 tasks).
- Standalone work: review before merge or when stuck.
Gotchas
- Skipping review on "trivial" changes — trivial changes hide subtle regressions.
- Using session HEAD without verifying — stale SHAs produce empty diffs. Always re-derive.
- Ignoring Important-severity items to stay on schedule — they compound into Critical by the next task.
- Passing session history instead of the template — reviewer loses focus, burns context on irrelevant detail.