gh-review
Skill này làm gì
Skill này đặt ra quy tắc và giọng điệu để viết review và bình luận trên GitHub. Dành cho lập trình viên review mã và muốn phản hồi trực tiếp, rõ ràng.
Khi nào nên dùng
- ✓Khi bạn yêu cầu agent review một pull request và đăng kết quả lên GitHub.
- ✓Khi bạn muốn bình luận review trực tiếp, không mơ hồ hay mang tính tùy chọn.
- ✓Khi agent sắp đăng bình luận lên GitHub và bạn muốn nó kiểm tra xem đang đăng bằng tài khoản nào trước.
Liên kết skill
https://github.com/mastra-ai/mastra/blob/main/.mastracode/skills/gh-review/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Viết một review GitHub cho pull request này, và làm cho mọi thay đổi bạn yêu cầu đều rõ ràng và bắt buộc.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Skill đưa cho agent một danh sách kiểm tra: xác nhận tài khoản đăng, viết từng yêu cầu kèm vị trí và lý do, rồi đăng một kết luận rõ ràng.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
GitHub review voice
Load this the moment a review or diagnosis is about to become a GitHub comment. The investigation skill owns the evidence; this skill owns what gets written, posting authorization, and how it is posted.
Who is posting
Before drafting, run gh auth status once and record the active account for the target GitHub host in the review record. Do not dump environment variables or expose tokens.
Do not assume the answer. It may be the user's account or a bot account with its own identity; which one it is changes how you act:
- Self-review means the posting account is the PR author. Compare the login above to the PR's
author.login, and decide self-review from that comparison alone—not from who the user is. - Write in the posting account's voice. If it is not the author's account, do not refer to the PR as "mine".
- The user is accountable for the content regardless of which account posts it—which is why the post gate below exists.
Check once per session, not before every post.
The rule
Ask for the changes you want, and every one of them is required. Small requests are still requests—post them. What you never do is label them: there is no "optional", no "nit", no "non-blocking", no "follow-up", no "future PR". The author satisfies the list; the review is not a menu.
Hedging is not politeness; it transfers the decision back to the author while pretending not to. A reviewer who has evidence states the request.
Voice
Be direct about required changes and precise about what the evidence establishes:
- Imperative, present tense. "Advance
attemptbefore the comparison." Not "you might want to consider advancing…". - Pointer, change, reason. Every request names the file and line, says what to change, and gives the consequence or evidence in one or two sentences.
- No pleasantries. No "Thanks for the PR", "Great work overall", "Nice cleanup", "Let me know if you have questions", "Happy to discuss".
- No softened requests. State required changes directly, not as optional suggestions or politeness questions ("You might want to advance
attempt?", "Consider adding a test"). Preserve qualifications that express actual uncertainty or limits of evidence: "the contract does not guarantee this field" must not become "servers never return this field". - No restated verdict. GitHub already shows "requested changes" or "approved" above the body. Never open with "Request changes." / "Approve." / "Verdict:".
- Questions only when the answer changes the request. State what you believe and what changes if the answer differs: "This drops the retry on 429. If that is intentional, document it in the option's JSDoc; otherwise restore the branch at
client.ts:88." - Evidence over assertion. "Ran
pnpm test:memoryon this branch with the second tool call removed: fails atobserver.test.ts:212." Not "this may break the tests". - Plain about severity. If it corrupts data, say it corrupts data.
- Code, not people. Never characterize the author, their effort, or their experience.
Length is set by the requests, not by a budget. Each request is a pointer, the change, and the reason—nothing else—and every request you have evidence for is in the body. Eight requests make an eight-item review; do not shrink the list to look concise, and do not park requests in a "secondary" or "candidate" tier to be added if asked.
Structure of a PR review body
Request changes (fictional example):
The new retry setting reaches the normal path, but recovery still uses the old default. Both paths need to honor the same configured limit.
1. `src/client/retry.ts:41` — Pass the configured limit into the recovery path. It currently retries even when callers disable retries.
2. `src/client/retry.test.ts:88` — Cover the recovery path with retries disabled. The current test only exercises the normal path.
Verified: a recovery-path probe with retries disabled made three attempts.
Approve:
<Brief reason the approach and implementation satisfy the required outcome.>
Verified: <what you actually ran, only if it adds credibility>.
Lead with the review's central conclusion and why it matters, not the event label. Give each numbered request a clear resolving condition; group changes that must land together or state their dependencies. Put the request that most affects correctness first. If the author needs to make a product decision rather than a code change, say what decisio
Câu hỏi thường gặp
Skill này có tự đăng bình luận không?
Nó hướng dẫn cách viết và đăng bình luận, và yêu cầu agent kiểm tra xem đang dùng tài khoản GitHub nào trước.
Agent có thể đánh dấu một yêu cầu là tùy chọn không?
Không. Skill yêu cầu agent tránh các nhãn như “tùy chọn” hoặc “nit”, để mọi yêu cầu đều rõ ràng.
Skill này dành cho ai?
Dành cho người review mã trên GitHub và muốn phản hồi trực tiếp, nhất quán.
Chi tiết
Mô tả gốc của tác giả
Draft and post direct, unhedged GitHub PR reviews and issue comments — every item is a required change with a pointer and reason, PR reviews land as "request changes" or "approve" (never a bare comment), and nothing is marked optional or deferred to a follow-up. Use whenever understand-pr or understand-issue (or any review) is about to draft or post to GitHub.
repo: mastra-ai/mastra
Độ phổ biến
- Sao GitHub
- 29k
- Vị trí xếp hạng
- #9367
- Giấy phép
- —
- Cập nhật
- 2/11/2026
Bình luận
- …
Thêm skill từ kho mã này
debugging-difficult-bugs
29kGiúp agent của bạn gỡ một lỗi khó bằng cách ghi nhật ký những gì chương trình thật sự làm lúc chạy, thay vì đoán chỉ từ các bài kiểm thử.
mastra-frontend
29kGiúp agent của bạn xây dựng màn hình ứng dụng bằng hệ thống thiết kế playground của Mastra, kết hợp các thành phần sẵn có thay vì tạo kiểu từ đầu.
pr-explainer
29kGiúp agent của bạn biến một pull request thành trang HTML độc lập, giải thích thay đổi cho người review một cách rõ ràng.
pr-splitter
29kGiúp agent của bạn chia một pull request lớn, lộn xộn thành nhiều pull request nhỏ dễ review, đồng thời giữ an toàn cho công việc gốc.
Skill tương tự
diffs
394kGiúp agent của bạn tạo một diff có thể chia sẻ về các chỉnh sửa, dưới dạng liên kết xem hoặc file ảnh, thay vì một bản tóm tắt viết tay.
coding-agent
394kGiúp agent của bạn giao một việc lập trình lớn cho Codex, Claude Code hoặc OpenCode chạy nền, rồi theo dõi tiến độ của nó.
gh-issues
394kGiúp agent của bạn tìm issue trên GitHub, chọn những issue cần xử lý và mở pull request với bản sửa, kể cả theo dõi nhận xét đánh giá.