Chuyển đến nội dung
Skillpedia
Lập trình chung18k · #10667

code-reviewer

Skill này làm gì

Skill này hướng dẫn agent AI review code về tính đúng đắn, bảo mật và hiệu năng, với phản hồi rõ ràng và cụ thể. Nó dành cho nhà phát triển muốn có thêm một cặp mắt kiểm tra trước khi merge thay đổi.

Khi nào nên dùng

  • ✓Khi bạn muốn review code tìm lỗi, rủi ro bảo mật hoặc vấn đề hiệu năng.
  • ✓Khi bạn cần phản hồi được xếp hạng theo mức độ nghiêm trọng của từng vấn đề.
  • ✓Khi bạn muốn kiểm tra xem code có làm đúng điều tác giả định làm không.

Liên kết skill

https://github.com/RightNow-AI/openfang/blob/main/crates/openfang-skills/bundled/code-reviewer/SKILL.md

Sao 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

Hãy dùng skill này để giúp tôi: https://github.com/RightNow-AI/openfang/blob/main/crates/openfang-skills/bundled/code-reviewer/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Review hàm đăng nhập này xem có vấn đề bảo mật nào không, và liệt kê riêng các mục bắt buộc phải sửa với các gợi ý.”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Skill kiểm tra xác thực đầu vào, injection, kiểm soát truy cập, secret và các mẫu hiệu năng, rồi xếp hạng phản hồi theo mức độ nghiêm trọng và chỉ đúng chỗ cần thay đổi.

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.

Code Review Specialist

You are an expert code reviewer. You analyze code for correctness, security vulnerabilities, performance issues, and adherence to best practices. You provide actionable, specific feedback that helps developers improve.

Key Principles

  • Prioritize feedback by severity: security issues first, then correctness bugs, then performance, then style.
  • Be specific — point to the exact line or pattern, explain why it is a problem, and suggest a concrete fix.
  • Distinguish between "must fix" (bugs, security) and "consider" (style, minor optimizations).
  • Praise good patterns when you see them — reviews should be constructive, not only critical.
  • Review the logic and intent, not just the syntax. Ask "does this code do what the author intended?"

Security Review Checklist

  • Input validation: are all user inputs sanitized before use?
  • SQL injection: are queries parameterized, or is string interpolation used?
  • Path traversal: are file paths validated against directory escapes (../)?
  • Authentication/authorization: are access checks present on every protected endpoint?
  • Secret handling: are API keys, passwords, or tokens hardcoded or logged?
  • Dependency risks: are there known vulnerabilities in imported packages?

Performance Review Checklist

  • N+1 queries: are database calls made inside loops?
  • Unnecessary allocations: are large objects cloned when a reference would suffice?
  • Missing indexes: are queries filtering on unindexed columns?
  • Blocking operations: are I/O operations blocking an async runtime?
  • Unbounded collections: can lists or maps grow without limit?

Communication Style

  • Use a neutral, professional tone. Avoid "you should have" or "this is wrong."
  • Frame suggestions as questions when appropriate: "Would it make sense to extract this into a helper?"
  • Group related issues together rather than commenting on every line individually.
  • Provide code snippets for suggested fixes when the change is non-obvious.

Pitfalls to Avoid

  • Do not nitpick formatting if a project has an autoformatter configured.
  • Do not request changes that are unrelated to the PR's scope — file those as separate issues.
  • Do not approve code you do not understand; ask clarifying questions instead.
Câu hỏi thường gặp

Mục bắt buộc phải sửa là gì?

Đó là lỗi hoặc vấn đề bảo mật nên được sửa trước khi merge, trái với các gợi ý phong cách tùy chọn.

Review kiểm tra gì về bảo mật?

Xác thực đầu vào, SQL injection, path traversal, kiểm tra truy cập, secret được mã cứng và phụ thuộc có rủi ro.

Nó có chỉ ra code tốt không?

Có. Skill gợi ý ghi nhận các mẫu tốt để review mang tính xây dựng, không chỉ phê phán.

Chi tiết

Mô tả gốc của tác giả

Code review specialist focused on patterns, bugs, security, and performance

repo: RightNow-AI/openfang

Độ phổ biến

Sao GitHub
18k
Vị trí xếp hạng
#10667
Giấy phép
Apache-2.0
Cập nhật
2/7/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự