review-pr

작성자: warpdotdev

풀 리퀘스트 diff를 검토하고 구조화된 피드백을 review.json에 작성하여 워크플로우가 게시할 수 있도록 합니다. pr_diff.txt 및 pr_description.txt와 같은 로컬 아티팩트에서 체크아웃된 PR을 검토하고, GitHub에 직접 게시하는 대신 기계가 읽을 수 있는 리뷰 출력을 생성할 때 사용합니다.

npx skills add https://github.com/warpdotdev/common-skills --skill review-pr

Review PR Skill

Review the current pull request and write the output to review.json.

Context

  • The working directory is the PR branch checkout.
  • The workflow usually provides an annotated diff in pr_diff.txt.
  • The workflow usually provides the PR description in pr_description.txt.
  • If spec_context.md exists, it contains spec context for implementation-vs-spec validation.
  • When the prompt references .agents/skills/review-pr/scripts/resolve_spec_context.py, use that script to materialize spec_context.md on demand instead of expecting spec content to be embedded in the prompt.
  • Focus on files and lines changed by this PR.
  • Do not post comments or reviews to GitHub directly.

Review Scope

  • Prioritize correctness, security, error handling, and meaningful performance issues.
  • Treat comment quality and test quality as first-class review priorities alongside those — not as optional nits to mention only if time allows; check both against the repository's own conventions before finalizing your verdict.
  • If the consuming repository provides a local security-review-pr companion skill or the prompt requests a security pass, apply it as supplemental guidance on code PRs and fold any security findings into the same review.json rather than emitting a separate output.
  • When spec_context.md exists, use the repository's local check-impl-against-spec skill if available and treat material spec drift as a review concern.
  • Include style or nit comments only when you can provide a concrete suggestion block.
  • If a concern involves untouched code, mention it in top-level body instead of an inline comment.
  • Do not suggest adding test cases that only vary constructor inputs or struct fields when the existing test already covers the meaningful behavior. Only suggest new tests when they exercise a distinct code path or edge case.
  • When a PR is clearly a V0 or initial implementation, frame robustness suggestions (timeouts, retries, lifecycle management) as optional future work rather than blocking concerns, unless they risk correctness, security, or data loss.

Repository-specific guidance

Before reviewing, actively check whether the consuming repository ships a companion review-pr-local skill that specializes this one for its own conventions: if the prompt names one, read it there; otherwise look for one in the repository itself (for example, at .agents/skills/review-pr-local/SKILL.md, though a repository may place or name its specialization differently). If a companion exists, read it and apply its guidance as part of this review. If none turns up either way, rely on the core contract alone.

The companion is expected to specialize this skill's commenting and testing guidance with the repository's own conventions. It may never change the output JSON schema, the severity labels, the safety rules, the evidence rules, the suggestion-block constraints, or the diff-line-annotation contract described elsewhere in this skill.

Diff Line Annotations

The diff file uses these prefixes:

  • [OLD:n] for deleted lines on the old side. Use "LEFT".
  • [NEW:n] for added lines on the new side. Use "RIGHT".
  • [OLD:n,NEW:m] for unchanged context. Use "RIGHT" with line m.

Treat these annotations as the only source of truth for inline comment locations. For every inline comment you emit, first identify the exact annotated line in pr_diff.txt (or the inlined PR diff) and copy its path, side, and line number into review.json. Do not infer line numbers from prose, rendered GitHub views, file lengths, surrounding spec text, or unannotated snippets. If you cannot point to a specific [NEW:n], [OLD:n], or [OLD:n,NEW:m] line in the annotated diff, put the feedback in top-level body instead of comments.

Comment Requirements

Every comment body must start with one of these labels:

  • 🚨 [CRITICAL] for bugs, security issues, crashes, or data loss.
  • ⚠️ [IMPORTANT] for logic problems, edge cases, or missing error handling.
  • 💡 [SUGGESTION] for worthwhile improvements or better patterns.
  • 🧹 [NIT] for cleanup only when the comment includes a suggestion block.

A confirmed violation of the repository's commenting or testing guidelines can warrant ⚠️ [IMPORTANT] on its own — regardless of how clean the rest of the PR is. Do not default these to 🧹 [NIT]/💡 [SUGGESTION] just because the surrounding code looks good.

Write comments with these constraints:

  • Be concise, direct, and actionable.
  • Do not add compliments or hedging.
  • Prefer single-line comments.
  • Keep ranges to at most 10 lines.
  • Restrict inline comments to lines that appear explicitly in the annotated PR diff.
  • Only create file-level or inline comments for files that exist in this PR's diff.
  • If the relevant file or line is not part of the diff, put the feedback in top-level body instead of comments.
  • Before adding each comment object, verify that its path, side, line, and optional start_line/start_side correspond to real annotations in the same file's diff section.

Suggestion Blocks

When proposing a code change, use:

<replacement code here>

Rules:

  • Match the exact indentation of the original file.
  • Include only replacement code.
  • The block content replaces exactly the lines start_lineline inclusive. Every line inside the block becomes the new file content for that range, and GitHub leaves all other lines untouched.
  • Do not include lines outside that range. Lines above start_line and below line remain in the file; repeating them inside the block causes them to appear twice after the suggestion is committed.
  • Never open the block with a line that already appears immediately above start_line, and never close the block with a line that already appears immediately below line. If you need those lines as anchors, widen start_line or line so they are actually part of the replaced range.
  • Count brace, bracket, paren, and block-delimiter depth ({, [, (, end, etc.) across the original replaced lines and ensure the replacement ends at the same depth. Do not emit phantom closing tokens, and do not drop required ones.
  • When unsure of the surrounding context, widen start_line/line to include enough real lines from the diff rather than guessing at surrounding tokens.
  • For multi-line suggestions, set start_line and start_side to the first line, and line and side to the last line.

Output Format

Create review.json with this shape:

{
  "verdict": "REJECT",
  "body": "## Overview\n...\n\n## Concerns\n- ...\n\n## Verdict\nFound: 1 critical, 2 important, 3 suggestions\n\n**Request changes**",
  "comments": [
    {
      "path": "path/to/file",
      "line": 42,
      "side": "RIGHT",
      "start_line": 40,
      "start_side": "RIGHT",
      "body": "⚠️ [IMPORTANT] Short explanation\n\n```suggestion\nreplacement\n```"
    }
  ]
}

Field rules:

  • verdict is required and must be exactly the string "APPROVE" or "REJECT" (uppercase). Map your final recommendation as: Approve or Approve with nits"APPROVE"; Request changes"REJECT". The verdict and the human-readable recommendation in top-level body must agree.
  • Top-level body is the GitHub review body and is required. Use body, not summary, for the review overview and final recommendation.
  • comments is required and must be an array. Use an empty array when there are no inline comments.
  • path must be relative to the repository root.
  • line is required and must target the correct side.
  • start_line is optional and only for multi-line ranges. When start_line is present, start_side is required and must be "LEFT" or "RIGHT".
  • side must be "LEFT" or "RIGHT".

Body Requirements

The top-level body must include:

  • A high-level overview of the PR.
  • Important concerns and any untouched-code concerns that could not be commented inline.
  • Issue counts in the format Found: X critical, Y important, Z suggestions.
  • A final recommendation of Approve, Approve with nits, or Request changes. This recommendation must match the top-level verdict field (Approve / Approve with nits"APPROVE"; Request changes"REJECT").

Pre-Verdict Audit

Before drafting the top-level body or choosing verdict, complete this audit — a holistic read-through of the diff is not sufficient.

  • Comments: List every comment (doc comment or inline) the diff adds or changes, one by one with its file:line. For each one, check it individually against the repository's own commenting guidelines, whatever form those take — or, if the repository defines none, judge it against the commenting distribution of existing code in the project (density, tone, what existing comments explain vs. omit). Evaluate compliance independently of the comment's writing quality, technical accuracy, or how subtle/important the issue it describes is: none of those qualities excuses a violation of an applicable guideline or a clear mismatch with the codebase's own norms.
  • Tests: Check every test the diff adds or changes against the repository's own testing guidelines, whatever form those take.

Final Checks

Before returning or uploading review.json:

  • Fix invalid JSON if validation fails.
  • Confirm line numbers match the annotated diff.
  • Run the bundled validator against the exact annotated diff you reviewed:
    python3 .agents/skills/review-pr/scripts/validate_review_json.py --review-json review.json --diff pr_diff.txt
    
    If the script reports any invalid comments, fix review.json and rerun it. Do not return or upload review.json until this validator passes. If the script path is not present at that exact location, locate validate_review_json.py under the loaded review-pr skill directory and run that copy with the same arguments.
  • Do not run gh pr review, gh pr comment, gh api, or any other command that posts to GitHub.

Your only output is the final review.json.

warpdotdev의 다른 스킬

council
warpdotdev
모델 다양성을 갖춘 하위 에이전트 위원회를 운영하여 동일한 문제를 여러 관점에서 조사하고, 결과를 비교한 후 최종 권장 사항을 도출합니다. 사용자가 위원회, 추가 의견, 하나의 질문을 평가할 여러 에이전트/모델, 병렬 조사, 레드팀/블루팀 비교, 또는 경쟁 기술 접근법 중 결정을 도와달라고 요청할 때 이 스킬을 사용하세요.
researchcommunicationproject-management
spec-driven-implementation
warpdotdev
구현 전에 PRODUCT.md를 작성하고, 필요시 TECH.md를 작성하며, 구현이 진행됨에 따라 두 문서를 최신 상태로 유지함으로써 주요 기능에 대한 명세 우선 워크플로를 추진합니다. 중요한 기능을 시작할 때, 에이전트 기반 구현을 계획할 때, 또는 사용자가 제품 및 기술 명세를 소스 제어에 포함시키려 할 때 사용하세요.
developmentdocumentproject-management
review-pr
warpdotdev
풀 리퀘스트 diff를 검토하고, 워크플로우가 게시할 수 있도록 구조화된 피드백을 review.json에 작성합니다. 로컬 아티팩트(예: pr_diff.txt, pr_description.txt)에서 체크아웃된 PR을 검토하고, GitHub에 직접 게시하는 대신 기계가 읽을 수 있는 리뷰 출력을 생성할 때 사용합니다.
code-reviewdevelopment
create-pr
warpdotdev
현재 브랜치를 warp 저장소에 풀 리퀘스트로 생성합니다. 사용자가 PR 열기, 풀 리퀘스트 생성, 리뷰를 위한 변경 제출, 또는 병합을 위한 코드 준비를 언급할 때 사용하세요.
developmentcode-review
implement-specs
warpdotdev
승인된 PRODUCT.md와 TECH.md의 기능을 구현하며, 구현이 진행됨에 따라 사양과 코드를 동일한 PR에서 일관되게 유지합니다. 제품 및 기술 사양이 승인되고 다음 단계가 기능 구축일 때 사용하세요.
developmentcode-reviewapi
cross-critique
warpdotdev
논쟁이 있는 질문에 대해 두 번째 라운드를 실행하여 각 하위 에이전트의 독립적인 제안을 다른 작성자에게 전달하고 구조화된 장단점을 요청한 후 종합합니다. 이 스킬은 아키텍처 트레이드오프, 코드 리뷰 불일치, 설계 선택, 경쟁하는 근본 원인 이론 등 논쟁이 있는 결정에 대해 여러 독립적인 제안이나 의견이 있을 때 단독으로 종합하는 것보다 더 날카로운 분석을 원할 때 사용하세요. council 및 research 스킬과 자연스럽게 짝을 이룹니다.
resolve-merge-conflicts
warpdotdev
Resolve Git merge conflicts by extracting only unresolved paths, conflict hunks, and compact diffs instead of loading whole files into context. Use when a merge, rebase, cherry-pick, or stash pop stops on conflicts, when `git status` shows unmerged paths, or when files contain conflict markers.
developmentcode-review
brandalf
warpdotdev
Warp 또는 Oz 브랜드 자산의 제작, 수정, 검토를 안내합니다. 런칭 페이지, 문서, HTML/CSS 컴포넌트, UI 목업, 프롬프트, 소셜 자산, 카피, 프레젠테이션 등 Warp 또는 Oz의 정체성이 분명히 드러나야 하는 모든 브랜드 결과물에 사용하세요.
designcreativemarketing