code-review
БесплатноБез исполняемых скриптовНе проверенDeep code review of PR or materialized candidate-patch changes for correctness, safety, and MAUI conventions. Uses independence-first assessment (code before…
от dotnet★ 23 319 звёзд на GitHubОб этом скилле
Code Review Skill
Standalone skill that evaluates PR code changes for correctness, safety, performance, and consistency with .NET MAUI conventions. Can be invoked directly by users or by other agents/skills.
Trigger phrases: "review code for PR #XXXXX", "code review PR #XXXXX", "review this PR's code", "analyze code changes in PR", "check PR code quality"
Do NOT use for: "what does PR #XXXXX do?", "summarize PR", "describe the changes", or any informational query — just answer those directly without invoking this skill.
How this differs from other skills:
pr-review— End-to-end PR workflow (4 phases: pre-flight, gate, try-fix, report). Use when you want the full pipeline including test verification and fix attempts.pr-finalize— Verifies PR title/description match implementation + light code review. Use before merging.code-review(this skill) — Deep code-only review with MAUI domain rules. Use when you want a thorough code analysis without running tests or modifying the PR.
Core Principles
- Independence-first — Form your assessment from the code BEFORE reading the PR description. This prevents anchoring on the author's framing
- Full-context — Read entire source files, not just diffs. Check callers, consumers, and git history
- Empirical grounding — Reference specific code, line numbers, and call sites. No vague concerns
- Severity calibration — Distinguish errors from warnings from suggestions. Not everything is critical
- Failure-mode probing — Challenge your own conclusions with real failure scenarios, not softballs
- Propagation-aware guards — For an early return, idempotency flag, or latch above downstream side effects, trace every set/clear path and a repeat call after recipients or state change. If that trace exposes concrete misbehavior, do not dismiss it as rare or rationalize it into
LGTM: useNEEDS_DISCUSSIONwhile the failure remains unresolved, orNEEDS_CHANGESwhen the exact state transition verifies a ❌ Error. - Authentication is not availability — A public GitHub PR remains reviewable when
ghis unauthenticated. Never stop or ask for a token merely because aghcommand failed; pivot immediately to anonymous public REST/web retrieval.
Inputs
| Input | Required | Description |
|---|---|---|
pr_number |
Conditional | GitHub PR number for a live-PR review |
review_input |
Conditional | Materialized candidate diff plus supporting source files; use when no live PR is available |
Exactly one review source is required.
Outputs
| Field | Description |
|---|---|
verdict |
LGTM, NEEDS_CHANGES, or NEEDS_DISCUSSION |
confidence |
high, medium, or low |
findings |
Categorized findings with severity levels |
Review Workflow
Step 1: Gather Code Context (No PR Narrative)
Do NOT read the PR description or issue yet.
For a materialized review_input, read its candidate diff first, then every
supporting source file in full. Trace callers, consumers, and producers available
in the snapshot. Do not fetch PR narrative, external pages, or repository history
that the fixture does not provide. Then continue at Step 1.5.
For a live pr_number:
If a retrieval command fails, the PR is still available. A failing or
unauthenticated command is a fact about that one tool, not about the review.
gh api also requires authentication, so it is not an unauthenticated fallback.
For public dotnet/maui PRs, pivot to anonymous read-only retrieval:
# Candidate patch:
curl -fsSL -H 'Accept: application/vnd.github.patch' \
https://api.github.com/repos/dotnet/maui/pulls/<PR_NUMBER>
# Changed-file metadata and patches:
curl -fsSL \
'https://api.github.com/repos/dotnet/maui/pulls/<PR_NUMBER>/files?per_page=100'
Equivalent web_fetch calls are acceptable. Use response raw_url values or
https://raw.githubusercontent.com/dotnet/maui/<HEAD_SHA>/<PATH> for full
changed-file contents. A local checkout with git diff is another valid route.
Anonymous API rate limiting may require fewer targeted requests, but it is not
an authentication blocker. Never ask the caller to provide a token or paste the
diff until anonymous retrieval and local checkout routes have both failed.
Get the diff:
gh pr diff <PR_NUMBER> --repo dotnet/mauiRead full source files for every changed file (not just diff hunks):
gh pr diff <PR_NUMBER> --repo dotnet/maui --name-only # Then read each file in fullCheck callers and consumers of changed methods/properties:
- Use LSP
findReferencesandincomingCallsfor modified symbols - Understand how the changed code is used
- Use LSP
Review git history of changed files:
git log --oneline -10 -- <changed-file>
Step 1.5: Trace External Output Contracts (Always Active)
When changed code classifies ex
Установить code-review в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл code-review?
Deep code review of PR or materialized candidate-patch changes for correctness, safety, and MAUI conventions. Uses independence-first assessment (code before narrative) and delegates to the maui-expert-reviewer agent for per-dimension sub-agent evaluation. Triggers on: "review code for PR", "code review PR", "review candidate patch", "analyze code changes", "check PR code quality". Do NOT use for: summarizing PRs, describing what changed, general PR questions, running tests, or fixing code.
Как установить скилл code-review?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл code-review запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic