code-review
The review entry point for this repository. GitHub Copilot code review reads agent skills from
.github/skills/ on the head branch, and is more likely to use a skill whose directory name and
description target review — this file is that entry point. Any other agent asked to review a diff
in this repository follows the same route.
This file routes; it does not review. The review work lives in sibling skills under
.ai-badger/skills/ — open the ones the route names, in the order the change warrants.
The route
Work top-down. Stop expanding when the verdict for the change is clear; do not stop before it is.
- Rank the diff by blast radius — open
.ai-badger/skills/review-changes/SKILL.md when the
project has it. A 3-line change to shared auth outranks a 200-line change to one leaf
component; rank before reading, so the deepest checks land on the riskiest units.
- Run the pass/fail gates — open
.ai-badger/skills/code-review-checklist/SKILL.md for
every review. Sequential phases: build/tests/lint/secrets first, then layering, security,
contracts. Report every FAIL in the finding shape the checklist defines — item, severity,
location, evidence, impact, fix.
- Judge changed tests — open
.ai-badger/skills/review-tests/SKILL.md when the diff adds or
changes test files. A vacuous gate or an unproven red is a finding, not a style note.
- Name the missing coverage — open
.ai-badger/skills/design-tests/SKILL.md when a
high-risk unit has no covering test. Name the specific missing case (input, expected
behaviour) — never "consider adding tests".
- Whole-project review — open
.ai-badger/skills/complete-project-scope-code-review/SKILL.md only when the request is the
entire codebase rather than a diff; do not stretch a PR review into one.
Baseline when a named sibling is not installed (opt-in skills ship only when the project asked
for them): do that step inline at its cheapest — diff stat plus git log for ranking, the
checklist's Phase 1 gates verbatim, and every high-risk untested unit named individually with its
missing test case. Say which siblings were absent; the review is thinner for it, not silent.
Reading Copilot's review (when Copilot ran, not you)
- Copilot always leaves a "Comment" review, never "Approve" or "Request changes" — its verdict
does not block merge and does not count toward required approvals. Weigh its comments through
the checklist; a green Copilot review does not substitute for Phase 1.
- Attributions at the bottom of a review comment name the agent skill or MCP server that produced
it — follow them when a comment cites this project's skills.
- Re-review after a push is manual unless automatic reviews are configured; resolved
conversations may repeat on re-review.
- Suggested changes can be accepted in bulk or handed to the Copilot cloud agent via
"Fix with Copilot" — a suggested change is still a finding; check it against the diff before
committing it.
Review output
Findings in one shape, severity-ordered — item, severity, location, evidence, impact, fix — then
the merge recommendation: safe to merge / merge with tracked test debt / block. A review that
ends without a recommendation is incomplete; so is one whose recommendation does not follow from
its own findings.
Stack adjustments
The sections below are scaffold-time merges: each ships only when the project's config detects
that stack, so what you read here is the adjustment for THIS project's stacks.
python review adjustments
Apply alongside the generic route when the diff touches Python.
- Read
.ai-badger/skills/review-tests/references/stack-python.md when judging changed
pytest tests and the file exists — it is a stub in some catalogs and says so; when it is a
stub, fall back to the generic passes rather than inventing stack rules.
- Weight fixture isolation and shared-state teardown as correctness findings: a test suite that
passes only in file order is a non-determinism finding, not a hygiene note.
- Treat unseeded randomness, wall-clock reads, and ambient environment variables in production
paths as testability findings when no seam exists to control them.
- Run the project's own lint and typecheck from config
commands before approving Phase 1 —
Python typing drift is invisible to a review that only reads the diff.
ts review adjustments
Apply alongside the generic route when the diff touches TypeScript.
- The checklist's ts sections (browser security, TypeScript quality) merge into
.ai-badger/skills/code-review-checklist/SKILL.md at scaffold time — zero tolerance for any
in application code and unsafe as casts is the floor, not a preference.
- Read
.ai-badger/skills/review-tests/references/stack-ts-react-browser.md when judging
tests for browser or Node TypeScript — it carries the ecosystem-specific rule bodies the
generic passes point at.
- Treat unawaited promises and floating
void-discarded async calls as error-handling findings:
an unobserved rejection in a PR is a silent failure path the type system approved.
- Verify route params and external input pass a schema parse before reaching business logic
— a string that merely compiles is unvalidated input.
Gotchas
- Skills and instructions are read from the head branch, so guidance changed in this same PR
governs its own review — editing review rules and expecting the old rules is the mistake.
- The route is order-sensitive: ranking after reading wastes the reading; judging tests before
ranking spends the test-quality pass on low-risk files.
- Dismissing a Copilot conversation is not an instruction to Copilot — on re-review the same
comment can return; fix the code or refute the finding in the thread instead.
1---2name: code-review3description: Use when performing a code review in this repository — reviewing a pull request, a branch diff, or a requested re-review. This is the review entry point GitHub Copilot code review loads from .github/skills/ (a review-focused skill name and description, as GitHub's docs recommend); it routes to the deeper review skills this project ships — risk ranking, pass/fail gates, test-quality judgement, whole-project review — adjusted per project stack. Trigger phrases: "review this PR", "review these changes", "code review", "is this safe to merge".4license: MIT5---67# code-review89The review entry point for this repository. GitHub Copilot code review reads agent skills from10`.github/skills/` on the head branch, and is more likely to use a skill whose directory name and11description target review — this file is that entry point. Any other agent asked to review a diff12in this repository follows the same route.1314This file routes; it does not review. The review work lives in sibling skills under15`.ai-badger/skills/` — open the ones the route names, in the order the change warrants.1617## The route1819Work top-down. Stop expanding when the verdict for the change is clear; do not stop before it is.20211. **Rank the diff by blast radius** — open `.ai-badger/skills/review-changes/SKILL.md` when the22 project has it. A 3-line change to shared auth outranks a 200-line change to one leaf23 component; rank before reading, so the deepest checks land on the riskiest units.242. **Run the pass/fail gates** — open `.ai-badger/skills/code-review-checklist/SKILL.md` for25 every review. Sequential phases: build/tests/lint/secrets first, then layering, security,26 contracts. Report every FAIL in the finding shape the checklist defines — item, severity,27 location, evidence, impact, fix.283. **Judge changed tests** — open `.ai-badger/skills/review-tests/SKILL.md` when the diff adds or29 changes test files. A vacuous gate or an unproven red is a finding, not a style note.304. **Name the missing coverage** — open `.ai-badger/skills/design-tests/SKILL.md` when a31 high-risk unit has no covering test. Name the specific missing case (input, expected32 behaviour) — never "consider adding tests".335. **Whole-project review** — open34 `.ai-badger/skills/complete-project-scope-code-review/SKILL.md` only when the request is the35 entire codebase rather than a diff; do not stretch a PR review into one.3637**Baseline when a named sibling is not installed** (opt-in skills ship only when the project asked38for them): do that step inline at its cheapest — diff stat plus `git log` for ranking, the39checklist's Phase 1 gates verbatim, and every high-risk untested unit named individually with its40missing test case. Say which siblings were absent; the review is thinner for it, not silent.4142## Reading Copilot's review (when Copilot ran, not you)4344- Copilot always leaves a "Comment" review, never "Approve" or "Request changes" — its verdict45 does not block merge and does not count toward required approvals. Weigh its comments through46 the checklist; a green Copilot review does not substitute for Phase 1.47- Attributions at the bottom of a review comment name the agent skill or MCP server that produced48 it — follow them when a comment cites this project's skills.49- Re-review after a push is manual unless automatic reviews are configured; resolved50 conversations may repeat on re-review.51- Suggested changes can be accepted in bulk or handed to the Copilot cloud agent via52 "Fix with Copilot" — a suggested change is still a finding; check it against the diff before53 committing it.5455## Review output5657Findings in one shape, severity-ordered — item, severity, location, evidence, impact, fix — then58the merge recommendation: safe to merge / merge with tracked test debt / block. A review that59ends without a recommendation is incomplete; so is one whose recommendation does not follow from60its own findings.6162## Stack adjustments6364The sections below are scaffold-time merges: each ships only when the project's config detects65that stack, so what you read here is the adjustment for THIS project's stacks.666768## python review adjustments6970Apply alongside the generic route when the diff touches Python.7172- Read `.ai-badger/skills/review-tests/references/stack-python.md` **when** judging changed73 pytest tests and the file exists — it is a stub in some catalogs and says so; when it is a74 stub, fall back to the generic passes rather than inventing stack rules.75- Weight fixture isolation and shared-state teardown as correctness findings: a test suite that76 passes only in file order is a non-determinism finding, not a hygiene note.77- Treat unseeded randomness, wall-clock reads, and ambient environment variables in production78 paths as testability findings when no seam exists to control them.79- Run the project's own lint and typecheck from config `commands` **before** approving Phase 1 —80 Python typing drift is invisible to a review that only reads the diff.8182## ts review adjustments8384Apply alongside the generic route when the diff touches TypeScript.8586- The checklist's ts sections (browser security, TypeScript quality) merge into87 `.ai-badger/skills/code-review-checklist/SKILL.md` at scaffold time — zero tolerance for `any`88 in application code and unsafe `as` casts is the floor, not a preference.89- Read `.ai-badger/skills/review-tests/references/stack-ts-react-browser.md` **when** judging90 tests for browser or Node TypeScript — it carries the ecosystem-specific rule bodies the91 generic passes point at.92- Treat unawaited promises and floating `void`-discarded async calls as error-handling findings:93 an unobserved rejection in a PR is a silent failure path the type system approved.94- Verify route params and external input pass a schema parse **before** reaching business logic95 — a string that merely compiles is unvalidated input.9697## Gotchas9899- Skills and instructions are read from the head branch, so guidance changed in this same PR100 governs its own review — editing review rules and expecting the old rules is the mistake.101- The route is order-sensitive: ranking after reading wastes the reading; judging tests before102 ranking spends the test-quality pass on low-risk files.103- Dismissing a Copilot conversation is not an instruction to Copilot — on re-review the same104 comment can return; fix the code or refute the finding in the thread instead.