agentleFS
dork-labsdork-labs/dorkos/.claude/skills/requesting-code-review/SKILL.md

requesting-code-review

Skill11 starsChanged 48 days agoMITView on GitHub

Guides dispatching a code-reviewer subagent to verify work before proceeding. Use when completing tasks, implementing major features, or before merging to verify work meets requirements.

187 other projects use a version of this, 133 of them edited.

Adopted by

Most recently taken up by

Used with

Projects with it also use chinese-code-review, chinese-commit-conventions and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • Leodorareluctant259Skill

    chinese-code-review

    中文代码审查规范——在保持专业严谨的同时,用符合国内团队文化的方式给出有效反馈

    Also in 8 projects that use this

  • Leodorareluctant259Skill

    chinese-commit-conventions

    中文 Git 提交规范 — 适配国内团队的 commit message 规范和 changelog 自动化

    Also in 8 projects that use this

  • obraSkill

    diagnosing-superpowers

    Use when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.

    Also in 20 projects that use this

  • math-incSkill

    heartmula

    Set up and run HeartMuLa, the open-source music generation model family (Suno-like). Generates full songs from lyrics + tags with multilingual support.

    Also in 9 projects that use this

  • Tommy-ywSkill

    webhook-subscriptions

    Create and manage webhook subscriptions for event-driven agent activation, or for direct push notifications (zero LLM cost). Use when the user wants external services to trigger agent runs OR push notifications to chats.

    Also in 5 projects that use this

  • john-data-chenSkill

    touchdesigner-mcp

    Control a running TouchDesigner instance via twozero MCP — create operators, set parameters, wire connections, execute Python, build real-time visuals. 36 native tools.

    Also in 7 projects that use this

  • +3 more from Leodorareluctant259

The file

We split this skill into the rules it gives an agent

12 rules. 5 are common, 4 are distinctive, and 3 are very specific to this project.

  • 5

    Common

    Most of the 173 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    After each batch of related tasks in spec-driven development (/flow:execute) — holistic batch-level review, not per-task review

    line 16
  2. Common:

    After completing a major feature

    line 17
  3. Common:

    Before merge to main

    line 18
  4. Common:

    When stuck (fresh perspective)

    line 22
  5. Common:

    Before refactoring (baseline check)

    line 23
  6. Common:

    After fixing a complex bug

    line 24
  7. Very specific:

    Use the Agent tool with subagent_type: "code-reviewer".

    line 41
  8. Distinctive:

    Push back: if the reviewer is wrong — provide technical reasoning, show code or tests that prove correctness.

    line 66
  9. Very specific:

    If you checked the branch out somewhere to review it — a worktree, a scratch branch like rv712 or review-549, a detached checkout of the PR …

    line 70
  10. Distinctive:

    Do it in the same turn you report the review.

    line 80
  11. Distinctive:

    Verify against the spec before calling it done

    line 137
  12. Distinctive:

    No implementation detail testing, no arbitrary timeouts

    line 174

“Common” is measured: kept by at least 6 in 10 of the 173 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Requesting Code Review

Dispatch a code-reviewer subagent to catch issues before they cascade. The reviewer gets precisely crafted context for evaluation — never your session's history. This keeps the reviewer focused on the work product, not your thought process, and preserves your own context for continued work.

Core principle: Review early, review often.

When to Request Review

Mandatory:

  • After each batch of related tasks in spec-driven development (/flow:execute) — holistic batch-level review, not per-task review
  • After completing a major feature
  • Before merge to main

Optional but valuable:

  • When stuck (fresh perspective)
  • Before refactoring (baseline check)
  • After fixing a complex bug

Lightweight Alternative

For quick self-review without dispatching a subagent, trace through recently modified functions yourself to verify correctness and completeness inline. Use the full code-reviewer subagent (below) for deeper, more rigorous review.

How to Request

1. Get git SHAs

BASE_SHA=$(git rev-parse HEAD~1)  # or origin/main for full branch review
HEAD_SHA=$(git rev-parse HEAD)

2. Dispatch code-reviewer subagent

Use the Agent tool with subagent_type: "code-reviewer". Supply the following context:

Required context:

  • {WHAT_WAS_IMPLEMENTED} — What you just built
  • {PLAN_OR_REQUIREMENTS} — What it should do (spec path, task description, or requirements)
  • {BASE_SHA} — Starting commit
  • {HEAD_SHA} — Ending commit
  • {DESCRIPTION} — Brief summary of the changes

DorkOS-specific review concerns to include:

  • FSD layer violations (shared <- entities <- features <- widgets)
  • Transport interface compliance (HttpTransport and mock transports)
  • SDK import confinement — each runtime SDK stays in its adapter directory: @anthropic-ai/claude-agent-sdk → services/runtimes/claude-code/, @openai/codex-sdk → services/runtimes/codex/, @opencode-ai/sdk → services/runtimes/opencode/
  • os.homedir() ban (must use lib/dork-home.ts)
  • TSDoc on exports
  • Tailwind class sorting (prettier-plugin-tailwindcss)
  • Barrel import conventions (import from index.ts, never internal paths)

3. Act on feedback

  • Critical — Fix immediately. Bugs, security issues, data loss risks.
  • Important — Fix before proceeding. Architecture problems, missing tests, error handling gaps.
  • Minor — Note for later. Code style, optimization opportunities.
  • Push back if the reviewer is wrong — provide technical reasoning, show code or tests that prove correctness.

4. Clean up the review workspace

If you checked the branch out somewhere to review it — a worktree, a scratch branch like rv712 or review-549, a detached checkout of the PR head — delete it once you have reported. Review checkouts are disposable by construction: they duplicate a branch that already lives on origin, so nothing is lost.

/worktree:prune          # what would go, and why
/worktree:prune --fix    # remove it

Do it in the same turn you report the review. This is the step whose absence produced the mess: on 2026-08-01 the repo held 116 worktrees at ~3.5 GB each, and 47 of the 107 removed were review checkouts — the largest single category, from the one workflow that never said to clean up after itself (research/20260801_worktree-and-branch-sweep.md). Nothing else in the repo will collect them for you, because a review leaves no PR and no ticket behind for /flow:done to notice.

Run it from the main checkout, not from inside the review worktree. A worktree you are standing in reports current-worktree and is deliberately never removed, so running the sweep from inside the thing you are trying to delete silently does nothing.

The janitor refuses anything it cannot prove is safe, so run it rather than deleting by hand — in particular it will not touch a checkout you left uncommitted work in, including files that only git status --ignored can see.

Example

[Just completed the batch of tasks for the Telegram relay adapter]

You: Batch complete — let me request a holistic review before the next batch.

BASE_SHA=$(git rev-parse origin/main)  # or the SHA where the batch started
HEAD_SHA=$(git rev-parse HEAD)

[Dispatch code-reviewer subagent]
  WHAT_WAS_IMPLEMENTED: Telegram relay adapter with message formatting and rate limiting
  PLAN_OR_REQUIREMENTS: specs/telegram-adapter/02-specification.md, Tasks 1-3
  BASE_SHA: a7981ec
  HEAD_SHA: 3df7661
  DESCRIPTION: Added TelegramAdapter implementing RelayAdapter interface, with
    Markdown-to-Telegram formatting, rate limiter, and retry logic

[Subagent returns]:
  Strengths: Clean adapter interface, good test coverage, proper rate limiting
  Issues:
    Important: Missing FSD barrel export in features/relay/index.ts
    Minor: Magic number (30) for rate limit window — extract to constant
  Assessment: Ready to proceed with fixes

You: [Fix barrel export, extract constant]
[Continue to the next batch]

Integration with Workflows

Spec-Driven Development (/flow:execute):

  • Review holistically after each batch of related tasks — one review covering the whole batch beats per-task reviews
  • Catch FSD violations and architecture drift early
  • Fix before moving to the next batch

Feature Development:

  • Review after completing the feature
  • Verify against the spec before calling it done

Ad-Hoc Development:

  • Review before merge to main
  • Review when stuck for a fresh perspective

Review Checklist (DorkOS-Specific)

The code-reviewer subagent should evaluate against these project standards:

Architecture:

  • Hexagonal architecture boundaries respected
  • Transport interface used correctly (no direct HTTP in components)
  • Runtime SDK imports confined to their adapter directories (claude-code / codex / opencode under services/runtimes/)
  • Path aliases used correctly (@/* for app-local, @dorkos/* for cross-package)

Client (FSD):

  • Layer imports flow one direction: shared <- entities <- features <- widgets
  • Components import from barrel index.ts, never internal module paths
  • Zustand for UI state, TanStack Query for server state (not mixed)
  • Motion library for animations (not raw CSS transitions)

Server:

  • Routes use runtimeRegistry.getDefault() for runtime access
  • lib/dork-home.ts for data directory, lib/resolve-root.ts for working directory
  • Zod-validated env vars in env.ts
  • TSDoc on all exported functions and classes

Testing:

  • Tests in __tests__/ alongside source
  • Client tests use mock Transport via TransportProvider
  • Server tests use FakeAgentRuntime from @dorkos/test-utils
  • No implementation detail testing, no arbitrary timeouts

Red Flags

Never:

  • Skip review because "it's simple"
  • Ignore Critical issues
  • Proceed with unfixed Important issues
  • Argue with valid technical feedback

If reviewer is wrong:

  • Push back with technical reasoning
  • Show code or tests that prove correctness
  • Request clarification on the concern

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.