review
できること
変更されたコードを、正確性、セキュリティ、品質、性能の観点で確認し、わかりやすい提案とともに結果を報告します。マージの前にもう一人の目でチェックしたい開発者向けです。
使う場面
- ✓コミットやマージの前に、変更したコードをレビューしてほしいとき。
- ✓プルリクエストをレビューし、インラインのコメントを投稿してほしいとき。
- ✓特定のファイルにセキュリティや性能の問題がないか確認したいとき。
スキルのリンク
https://github.com/QwenLM/qwen-code/blob/main/packages/core/src/skills/bundled/review/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“プルリクエスト42番のバグとセキュリティの問題をレビューして、結果をコメントとして投稿してください。”
毎週5つの新しいスキル。1分で読めます。
仕組み
エージェントは差分またはプルリクエストを取得し、プルリクエストのレビューでは独立したワークツリーで作業します。変更に対してレビューを複数回実行し、結果を報告します。依頼があれば、結果を投稿したり修正を適用したりします。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
Code Review
You are an expert code reviewer. Your job is to review code changes and provide actionable feedback.
Critical rules (most commonly violated — read these first):
- For same-repo PR reviews (PR number, or URL whose owner/repo matches a local remote), the worktree is MANDATORY. After argument parsing and remote detection (early in Step 1), the first command that touches code state MUST be
qwen review fetch-pr. Do NOT usegh pr checkout,git checkout <branch>,git switch,git pull,git reset --hard, or any other command that modifies the user's current HEAD or working tree. Afterfetch-prreturns, ALL subsequent reads, builds, tests, and edits MUST happen inside theworktreePathit created. In Step 3 this is enforced deterministically by passingworking_dir: "<worktreePath>"to every review agent, which pins their tools to the worktree; your remaining responsibility is to route setup throughqwen review fetch-pr(nevergh pr checkoutor a branch switch that mutates the main tree). Violating this contaminates the user's local branch state. (Cross-repo PRs with no matching remote use lightweight mode and do NOT create a worktree — see Step 1.) - Two audiences, two languages. Everything posted to the PR — inline comment bodies, body Criticals, any text that lands on the PR page — matches the language of the PR: an English PR gets English, a Chinese PR gets Chinese. The bilingual rendering for Chinese PRs is deterministic when the plan records the flag (
prDescriptionHasHan); when the flag is absent but the plan still names the PR,compose-reviewrecovers the signal from the live description (see Step 7). Do not switch languages mid-review. Everything the local user watches live — your progress narration between steps, the Step 6 terminal report's prose (section headings, labels, finding summaries as restated in the terminal, and the follow-up Tip lines), the Step 8 saved report's descriptive prose and section headings, and thedescriptionparameter of everyagentcall (the task name the TUI/Web Shell displays while the agent runs) — follows the output language preference in your system prompt when one is set; when it isautoor absent, follow the user's input language, and fall back to the PR's language only when neither gives a signal. The findings artifact'ssummary/failureScenarioare PR-bound data — they reach the PR viabodyCriticalsand inlinecomments[]— so they stay in the PR's language; only their terminal restatement follows the output language. The output-language rule applies to descriptions you author on manual specialist calls; generated workflow labels are fixed role keys, preserved verbatim so they map to coverage records. What stays verbatim in every language: the prompt blocks CLI commands build (Step 3D compares them against the record), the CLI-printed lines you relay (theVerdict:line,FIX:lines), code snippets and```suggestionblocks, and the finalReview complete:line (Step 9 forbids rewording it). - Step 7: use Create Review API with
commentsarray for inline comments, exactly once (on an Aone targetsubmitfans the same payload out into onea1call per comment itself — you still run it exactly once, and a partial failure issubmit's to report, never yours to fix by posting comments by hand). Do NOT usegh api .../pulls/.../commentsto post individual comments, and do NOT submit throwaway reviews to test whether an anchor is valid — validate anchors offline againstfiles[].hunks[]from the fetch report. Every review you submit is public and permanent. See Step 7 for the JSON format. - Issue evidence outranks PR framing. For bugfix PRs, the Issue Fidelity agent must obtain issue evidence directly instead of relying on the PR author's framing. Use
"${QWEN_CODE_CLI:-qwen}" review issue-context <pr> --repo <owner/repo> --out <evidence-file>(the exact command is welded into Agent 0's generated prompt): it resolves the platform's strong closing-issue metadata, then fetches each referenced issue's title, body (the reporter's original repro / observed payload / expected behavior), and full comment thread — each from the issue's own repository, because a PR can close an issue in a different repo. The closing-issue set is a discovery hint, not proof: if it is empty but the PR context references an apparent target issue (aRefs/plain link), fetch that issue too after judgin
よくある質問
作業中のコピーは変更されますか?
プルリクエストのレビューは専用のワークツリーで行うため、現在のブランチは切り替わりません。
PRにコメントを投稿できますか?
はい。コメントのオプションを付けると、プルリクエストにインラインのコメントを投稿します。
見つかった問題を修正できますか?
はい。修正のオプションを付けると、結果を作業ツリーに適用します。
詳細
作者による元の説明
Review changed code for correctness, security, code quality, and performance. Use when the user asks to review code changes, a PR, or specific files. Invoke with `/review`, `/review <pr-number>`, `/review <file-path>`, `/review <pr-number> --comment` to post inline comments on the PR, `/review --fix` to apply the findings to your working tree, or `/review <pr-number> --resume` to continue an interrupted review of that PR at an unmoved head (a re-review after new commits is a plain `/review <pr-number>`). Add `--effort low|medium|high` to trade depth for speed (defaults to high for PRs, medium
repo: QwenLM/qwen-code
人気
- GitHubのスター
- 29k
- ランキング
- #9785
- ライセンス
- Apache-2.0
- 更新日
- 2026/11/2
コメント
- …
このリポジトリの他のスキル
codegraph
29kエージェントが、索引化されたコードベースを、呼び出しグラフ、依存関係、デッドコード、ホットスポット、意味検索を通じて分析できるよう支援します。
qwen-code-claw
29kエージェントが、コードベースの理解、バグ修正、リファクタリング、新しいプロジェクトの生成などのコーディング作業を、Qwen Codeに任せられるよう支援します。
structured-debugging
29kエージェントに、難しいバグを段階的に調べる方法を教えます。仮説を立て、的を絞った確認を行い、検証して、修正の前に本当の原因を見つけます。
tmux-real-user-testing
29kエージェントが、tmux内でターミナルアプリを実際のユーザーのように試せるよう支援します。各操作の画面のスナップショットを付けた、読みやすい手順のログを保存します。
似ているスキル
diffs
394k編集内容の実際の共有可能な差分を、手書きの要約ではなく、ビューアーのリンクや画像ファイルとして作成するようエージェントを支援します。
coding-agent
394kCodex、Claude Code、OpenCodeに大きめのコーディング作業をバックグラウンドのワーカーとして渡し、その進捗を確認するようエージェントを支援します。
gh-issues
394kGitHubのイシューを探し、取り組むものを選び、修正を含むプルリクエストを開くようエージェントを支援します。レビューコメントへの対応も含みます。