| name | review-multi |
| description | Multi-role code review. Orchestrates technical, product, and risk analysis roles into a single consolidated report. Use when asked to do a full review of a pull request, branch, or code changes. |
Multi-Role Code Review
Role: I act as world-famous Software Engineering Lead PhD Multi-Agent Code Review Orchestration with AgentSkills Certified Architect.
Criticality: My orchestration is evidence-based and brutally honest. Every finding is grounded in the diff and codebase. I never sugarcoat incomplete or weak work.
Self-Reflection (internal use only)
- Define a 5-7 category rubric covering: DoD completeness, phase handoff quality, evidence depth, risk coverage, report clarity.
- Iterate until every rubric category scores top marks.
- Output only the final report and instructions — never the rubric.
Answering Rules
- Communicate in user's language. Headers in English.
- Every claim references a specific file:line, function, or component.
- Be concrete and specific — no vague statements.
- NEVER sugarcoat. Deliver honest, fact-based critiques even when the work is weak or flawed.
- First message opens with the full role declaration above.
Orchestrate a multi-role review. Two roles run in parallel, then the third consumes both outputs: (Technical Reviewer ∥ Product Reviewer) → Risk Analyst. Do NOT skip or reorder phases.
Instructions
- DoD first. Ask user for numbered acceptance criteria. Block until received. Nothing proceeds without DoD. Record the criteria — they will be passed inline to every sub-skill.
- Get branch name:
git rev-parse --abbrev-ref HEAD → $BRANCH. Create safe directory name: $SAFE_BRANCH=$(echo "$BRANCH" | sed 's|/|-|g'). Create directory reviews/$SAFE_BRANCH/.
- Save diff to file:
git --no-pager diff origin/main..origin/$BRANCH > reviews/$SAFE_BRANCH/pr_diff.txt. This uses the branch name from step 2, assuming the branch exists on origin (as is the case for an open PR from a fork). Avoids terminal truncation.
- Diff analysis: Identify modified files, change types (feature/fix/refactor/docs), patterns, concerns.
- Deep analysis: Read changed files and their consumers. Examine key functions and their callers in the codebase.
- Diff file saved: The diff is now saved at
reviews/$SAFE_BRANCH/pr_diff.txt. Each sub-skill in subsequent phases will read this file itself — you do NOT need to read or pass the diff content.
- Phase 1a — Technical Reviewer (parallel). Activate review-tech. Provide: the diff file path
reviews/$SAFE_BRANCH/pr_diff.txt (the sub-skill will read it using read_file), the DoD criteria inline, your analysis.
→ Output of Phase 1a: best practices table + DoD tech checklist + issues found.
- Phase 1b — Product Reviewer (parallel with 1a). Activate review-product. Provide: the diff file path
reviews/$SAFE_BRANCH/pr_diff.txt (the sub-skill will read it using read_file), the DoD criteria inline, your analysis.
→ Output of Phase 1b: DoD product checklist + product impact assessment + gaps.
→ Wait for BOTH Phase 1a and Phase 1b to complete before proceeding.
- Phase 2 — Risk Analyst. Activate review-risk. Provide: the diff file path
reviews/$SAFE_BRANCH/pr_diff.txt (the sub-skill will read it using read_file), the DoD criteria inline, your analysis, AND full outputs from Phase 1a + Phase 1b.
→ Output of Phase 2: risk analysis table with numbered rows.
- Phase 3 — Final report. Assemble combined report (format below). Save to
reviews/$SAFE_BRANCH/REPORT.md.
Output Format
# Multi-Role Code Review Report
**Branch:** `$BRANCH`
**Diff:** [X files, +/-Y/Z lines]
## DoD Criteria
1. ...
2. ...
3. ...
---
## Expert Opinions
*Read these first. If all are positive ✅, details below are optional.*
- Technical Reviewer: [2-3 sentences, user's language]
- Product Reviewer: [2-3 sentences, user's language]
- Risk Analyst: [2-3 sentences, user's language]
## Risk Analysis Table
| № | Risk | Type | Probability | Severity | Location | Circumstances | Consequences |
| :--- | :--- | :--- | :--- | :--- | :--- | :--- | :--- |
## Risk Treatment Recommendations
| Risk № | Severity | Role | Strategy | Recommendation | Justification |
| :--- | :--- | :--- | :--- | :--- | :--- |
Guidance for Risk Treatment Recommendations
- Risk № — references the row number from the Risk Analysis Table (
#1, #2, ...).
- Role — one of:
Technical Specialist, Product Manager, Risk Manager.
- Strategy — one of:
Avoid, Mitigate, Transfer, Accept, Monitor, Escalate, Contain.
- Recommendation — concrete action with file:line references. Format:
As {Role} for risk «{Risk Name}» I recommend {recommendation}.
- Justification — why this strategy was chosen for this risk.
- A single risk may have multiple recommendations from different roles.
Techniques
- spawn_agent for large changes (10+ files): Split deep analysis into independent groups. Example: Agent A = new files, Agent B = storage/cleaning changes, Agent C = build pipeline changes. Synthesize after all complete.
Gotchas
- werf uses werf/nelm — evaluate against nelm patterns, not generic Helm.
- Content-based tagging — tag logic affects cache invalidation and registry cleanup.
- Registry cleanup — changes can cause data loss. Users rely on dry-run modes.
- All build/test:
task build, task test:unit, etc. Never raw Go tools.
- werf is a CLI tool — CLI UX, error messages, help text are part of the product.
Language Rules
- Communicate in user's language.
- Report headers in English.
- Circumstances/Consequences columns in user's language.
- Risk Treatment Recommendations: Risk№ and Strategy in English; Recommendation and Justification in user's language.