Review self
Review the current work immediately, fix validated gaps, and confirm with
recurring rounds until the result is stable.
Preserve authority and scope
- Invocation authorizes inspecting the work, making local in-scope fixes, and
running verification. Nothing else.
- Do not commit, push, open or edit a PR, comment, merge, or deploy unless the
user already authorized it.
loop-review supplies that authority when it
calls this skill.
- Keep fixes tied to the original goal. This is not a broad audit, a speculative
refactor, or a dependency upgrade.
- Preserve pre-existing user changes. Record the initial working-tree state and
never sweep-stage or discard files outside the current fix batch.
- Stop and ask when a fix needs a product decision, new authority, or an
irreversible action.
Establish the target
- Reconstruct the requested outcome and its acceptance criteria from the
conversation and the repository.
- Use an explicitly supplied PR, branch, commit range, or path. Otherwise
review the current branch plus staged, unstaged, and untracked changes.
- For a PR, derive the base and head from PR metadata. Otherwise use the
upstream and merge base; do not guess a base when it is ambiguous.
- Read
CLAUDE.md, and convex/_generated/ai/guidelines.md before reviewing
anything under convex/.
- Stop with a short report when there is no reviewable diff.
Run one round
Resnapshot the target from disk: the full base-to-head diff, staged and
unstaged overlays, and untracked file contents. Never review only the latest
commit or trust the previous round's snapshot.
Read the surrounding implementation, tests, and requirements needed to judge
the change.
Review for evidence-backed, actionable gaps:
- requirement completeness and end-to-end wiring, including whether the
frontend and the Convex backend still agree on every validator and shape;
- correctness, error paths, edge cases, state transitions, races, and data
safety;
- authorization on every new or changed Convex function, per
convex-authz;
- unbounded queries, missing indexes, and
Date.now() inside a query;
- i18n: every user-visible string goes through
t() and exists in all six
locale packs;
- missing tests for the behavior the change introduces.
Use read-only subagents for separate lenses when the diff is large. Give them
the raw target and request, never your suspected findings.
Validate every finding against the current code. Reject taste, cosmetic
churn, duplicates, and unrelated nice-to-haves.
Fix the validated in-scope findings in one coherent batch.
Reread the resulting diff, then run the checks the touched paths need:
bun run typecheck && bun run lint && bun run test
Add bun run build when the bundle could break. Verify anything visible in
the running app rather than assuming. Do not rerun an expensive unchanged
check unless new state can affect it.
If the target has a PR, read its failed checks and unresolved feedback as
evidence. Handle threads with one pass of .claude/commands/review-pr.md
only when GitHub writes are authorized, and never enter its polling section:
this skill owns the loop.
Act as a review-pr fallback
When review-pr calls this skill because no external reviewer covered the head:
- Run exactly one complete round against the supplied base, head SHA, and
acceptance criteria, keeping the caller's write authority.
- Do not re-enter
review-pr, call this fallback again, or schedule this
skill's loop.
- Return the reviewed head, findings and fixes, checks run, and a clean or
blocked result. The caller may cache clean only for that exact head.
Recheck at the interval
- Run the first round immediately.
- If the user asked for one pass, stop after it.
- Otherwise schedule the next round with
ScheduleWakeup at the user's
interval, or 300 seconds by default, with a prompt that re-enters
review-self. Never emulate the loop with sleep, while true, or an
abandoned background process, and never claim a pass was scheduled unless the
tool accepted it.
- Keep at most one outstanding wake-up per target.
- Carry a compact state capsule in the scheduled prompt: goal and acceptance
criteria, target and base, head and worktree fingerprints, seen findings and
check IDs, poll count, clean count, interval, and existing authority. Keep it
out of tracked files and revalidate against disk on every wake-up.
- Increment the clean count only when a complete round has no actionable
findings, all verification passes, checks are terminal and successful, no
actionable feedback remains, and the final diff has been reread. Reset it on
any material change.
- Finish after two consecutive clean snapshots separated by the interval.
- Treat pending checks as neither clean nor failed.
Stop safely
Stop and report the exact state when: two clean snapshots establish stability;
the user redirects; the PR is merged or closed or the branch disappears; a
finding needs authority you do not have; the same root finding survives two fix
attempts; the same environment failure blocks three consecutive rounds; or only
unchanged pending state remains for an hour.
Never call a blocked or interrupted result clean.
Communicate
State the target, base, scope, and authority at startup. Report findings, fixes,
failures, and pushes promptly; keep no-op updates to one line. On success or
stop, summarize findings fixed, files changed, checks run, clean-count evidence,
and any unresolved blocker.
1---2name: review-self-53description: Independently review Datehaja's current implementation, working-tree changes, or a pull request; validate findings against the code, fix the in-scope ones, rerun the affected checks, and recheck every five minutes until two clean snapshots. Use when the user says review-self, asks Claude to review its own changes, or wants current work watched for new issues after implementation.4---56# Review self78Review the current work immediately, fix validated gaps, and confirm with9recurring rounds until the result is stable.1011## Preserve authority and scope1213- Invocation authorizes inspecting the work, making local in-scope fixes, and14 running verification. Nothing else.15- Do not commit, push, open or edit a PR, comment, merge, or deploy unless the16 user already authorized it. `loop-review` supplies that authority when it17 calls this skill.18- Keep fixes tied to the original goal. This is not a broad audit, a speculative19 refactor, or a dependency upgrade.20- Preserve pre-existing user changes. Record the initial working-tree state and21 never sweep-stage or discard files outside the current fix batch.22- Stop and ask when a fix needs a product decision, new authority, or an23 irreversible action.2425## Establish the target26271. Reconstruct the requested outcome and its acceptance criteria from the28 conversation and the repository.292. Use an explicitly supplied PR, branch, commit range, or path. Otherwise30 review the current branch plus staged, unstaged, and untracked changes.313. For a PR, derive the base and head from PR metadata. Otherwise use the32 upstream and merge base; do not guess a base when it is ambiguous.334. Read `CLAUDE.md`, and `convex/_generated/ai/guidelines.md` before reviewing34 anything under `convex/`.355. Stop with a short report when there is no reviewable diff.3637## Run one round38391. Resnapshot the target from disk: the full base-to-head diff, staged and40 unstaged overlays, and untracked file contents. Never review only the latest41 commit or trust the previous round's snapshot.422. Read the surrounding implementation, tests, and requirements needed to judge43 the change.443. Review for evidence-backed, actionable gaps:45 - requirement completeness and end-to-end wiring, including whether the46 frontend and the Convex backend still agree on every validator and shape;47 - correctness, error paths, edge cases, state transitions, races, and data48 safety;49 - authorization on every new or changed Convex function, per `convex-authz`;50 - unbounded queries, missing indexes, and `Date.now()` inside a query;51 - i18n: every user-visible string goes through `t()` and exists in all six52 locale packs;53 - missing tests for the behavior the change introduces.544. Use read-only subagents for separate lenses when the diff is large. Give them55 the raw target and request, never your suspected findings.565. Validate every finding against the current code. Reject taste, cosmetic57 churn, duplicates, and unrelated nice-to-haves.586. Fix the validated in-scope findings in one coherent batch.597. Reread the resulting diff, then run the checks the touched paths need:6061 ```bash62 bun run typecheck && bun run lint && bun run test63 ```6465 Add `bun run build` when the bundle could break. Verify anything visible in66 the running app rather than assuming. Do not rerun an expensive unchanged67 check unless new state can affect it.688. If the target has a PR, read its failed checks and unresolved feedback as69 evidence. Handle threads with one pass of `.claude/commands/review-pr.md`70 only when GitHub writes are authorized, and never enter its polling section:71 this skill owns the loop.7273## Act as a review-pr fallback7475When `review-pr` calls this skill because no external reviewer covered the head:7677- Run exactly one complete round against the supplied base, head SHA, and78 acceptance criteria, keeping the caller's write authority.79- Do not re-enter `review-pr`, call this fallback again, or schedule this80 skill's loop.81- Return the reviewed head, findings and fixes, checks run, and a clean or82 blocked result. The caller may cache clean only for that exact head.8384## Recheck at the interval8586- Run the first round immediately.87- If the user asked for one pass, stop after it.88- Otherwise schedule the next round with `ScheduleWakeup` at the user's89 interval, or 300 seconds by default, with a prompt that re-enters90 `review-self`. Never emulate the loop with `sleep`, `while true`, or an91 abandoned background process, and never claim a pass was scheduled unless the92 tool accepted it.93- Keep at most one outstanding wake-up per target.94- Carry a compact state capsule in the scheduled prompt: goal and acceptance95 criteria, target and base, head and worktree fingerprints, seen findings and96 check IDs, poll count, clean count, interval, and existing authority. Keep it97 out of tracked files and revalidate against disk on every wake-up.98- Increment the clean count only when a complete round has no actionable99 findings, all verification passes, checks are terminal and successful, no100 actionable feedback remains, and the final diff has been reread. Reset it on101 any material change.102- Finish after two consecutive clean snapshots separated by the interval.103- Treat pending checks as neither clean nor failed.104105## Stop safely106107Stop and report the exact state when: two clean snapshots establish stability;108the user redirects; the PR is merged or closed or the branch disappears; a109finding needs authority you do not have; the same root finding survives two fix110attempts; the same environment failure blocks three consecutive rounds; or only111unchanged pending state remains for an hour.112113Never call a blocked or interrupted result clean.114115## Communicate116117State the target, base, scope, and authority at startup. Report findings, fixes,118failures, and pushes promptly; keep no-op updates to one line. On success or119stop, summarize findings fixed, files changed, checks run, clean-count evidence,120and any unresolved blocker.