Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问clear审计通过

code-reviewer代码审查员

Agent Skill

code-reviewer 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

533

周安装

22

GitHub Stars

21

下载量

174
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:code-reviewer(代码审查员)
来源仓库:https://github.com/matteocervelli/llms
仓库路径:skills/code-reviewer
安装命令:
npx skills add https://github.com/matteocervelli/llms --skill code-reviewer
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/matteocervelli/llms --skill code-reviewer

简介

code-reviewer 用于查找、检索和筛选相关信息。

  • 适合在 Codex、Claude、Cursor、Gemini CLI 中根据关键词或任务场景快速定位候选结果。
  • 通过 npx skills add 命令从指定 GitHub 仓库安装使用。
  • 安装前需确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写操作。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

Code Reviewer Skill

Purpose

This skill provides comprehensive code review guidance covering quality, security, performance, and style. It helps identify issues, suggest improvements, and ensure code meets project standards before committing.

Activation

On-demand via command: /review-code <file-path>

Example:

/review-code src/tools/example/core.py

When to Use

  • Self-review before committing
  • Refactoring existing code
  • Security concerns arise
  • Performance optimization needed
  • Ensuring style guide compliance
  • Code quality improvement
  • Pre-pull request review

Resources

review-checklist.md

Comprehensive code review checklist covering:

  • Code Quality: File organization, naming, type hints, docstrings, error handling
  • Testing: Coverage, quality, edge cases
  • Performance: Algorithm efficiency, memory usage, I/O optimization
  • Security: Input validation, authentication, authorization, data protection
  • Style: PEP 8 compliance, import organization, formatting

security-patterns.md

Security best practices including:

  • OWASP Top 10: Injection, authentication, XSS, etc.
  • Python-Specific Security: eval() usage, pickle security, SQL injection
  • Best Practices: Input validation patterns, secure authentication, data protection

Provides

Code Quality Feedback

  • File size enforcement (500-line limit)
  • Single responsibility principle adherence
  • Type hint completeness
  • Docstring quality (Google-style)
  • Error handling patterns
  • Naming convention compliance

Security Vulnerability Detection

  • Input validation issues
  • SQL injection vulnerabilities
  • XSS vulnerabilities
  • Authentication/authorization flaws
  • Sensitive data exposure
  • Insecure dependencies

Performance Optimization Suggestions

  • Algorithm efficiency improvements
  • Memory usage optimization
  • I/O operation optimization
  • Caching opportunities
  • Database query optimization

Refactoring Recommendations

  • Code duplication removal
  • Complexity reduction
  • Design pattern applications
  • Dependency injection improvements
  • Interface clarity

Style Guide Compliance Checks

  • PEP 8 for Python
  • Import organization
  • Code formatting
  • Comment quality
  • Documentation completeness

Usage Examples

Example 1: Review Python Module

/review-code src/tools/doc_fetcher/core.py

Provides feedback on:

  • Function complexity and size
  • Type hints and docstrings
  • Error handling
  • Security concerns (if any)
  • Performance bottlenecks
  • Style violations

Example 2: Security-Focused Review

/review-code src/api/authentication.py

Focuses on:

  • Authentication patterns
  • Password handling
  • Session management
  • Input validation
  • Authorization checks
  • Token security

Example 3: Performance Review

/review-code src/processors/data_processor.py

Analyzes:

  • Algorithm complexity
  • Memory allocation
  • I/O operations
  • Caching strategy
  • Database queries
  • Batch processing opportunities

Review Categories

1. Code Quality (⭐⭐⭐⭐⭐ Essential)

File Organization

  • ✓ File size ≤ 500 lines
  • ✓ Logical module structure
  • ✓ Clear separation of concerns
  • ✓ Appropriate file naming

Naming Conventions

  • ✓ Descriptive variable names
  • ✓ Clear function names (verb_noun pattern)
  • ✓ Class names (PascalCase)
  • ✓ Constants (UPPER_CASE)
  • ✓ Private members (_prefix)

Type Hints

  • ✓ All function parameters typed
  • ✓ All return types specified
  • ✓ Complex types properly annotated
  • ✓ Optional types used correctly

Docstrings

  • ✓ Google-style format
  • ✓ Clear description
  • ✓ Args documented
  • ✓ Returns documented
  • ✓ Raises documented

Error Handling

  • ✓ Appropriate exception types
  • ✓ Error messages clear
  • ✓ No bare except clauses
  • ✓ Cleanup in finally blocks

2. Testing (⭐⭐⭐⭐ Important)

Test Coverage

  • ✓ 80%+ code coverage
  • ✓ All public functions tested
  • ✓ Edge cases covered
  • ✓ Error paths tested

Test Quality

  • ✓ Clear test names
  • ✓ Arrange-Act-Assert pattern
  • ✓ Independent tests
  • ✓ Appropriate fixtures

3. Performance (⭐⭐⭐ Moderate)

Efficiency

  • ✓ Optimal algorithm complexity
  • ✓ No unnecessary loops
  • ✓ Efficient data structures
  • ✓ Batch operations where possible

Resource Usage

  • ✓ Memory-efficient
  • ✓ File handles closed
  • ✓ Database connections managed
  • ✓ No resource leaks

Optimization

  • ✓ Caching implemented
  • ✓ Lazy loading used
  • ✓ Async for I/O operations
  • ✓ Query optimization

4. Security (⭐⭐⭐⭐⭐ Critical)

Input Validation

  • ✓ All inputs validated
  • ✓ Type checking
  • ✓ Range checking
  • ✓ Sanitization

Authentication & Authorization

  • ✓ Strong authentication
  • ✓ Proper authorization
  • ✓ Session management
  • ✓ Token validation

Data Protection

  • ✓ No secrets in code
  • ✓ Sensitive data encrypted
  • ✓ SQL parameterized
  • ✓ Output encoding

OWASP Top 10

  • ✓ Injection prevention
  • ✓ Broken auth prevention
  • ✓ XSS prevention
  • ✓ Access control
  • ✓ Security misconfiguration

5. Style (⭐⭐⭐ Moderate)

PEP 8 Compliance

  • ✓ Line length ≤ 88 characters
  • ✓ Indentation (4 spaces)
  • ✓ Blank line usage
  • ✓ Whitespace around operators

Import Organization

  • ✓ Grouped (stdlib, third-party, local)
  • ✓ Alphabetically sorted
  • ✓ No unused imports
  • ✓ Absolute imports preferred

Code Formatting

  • ✓ Black-formatted
  • ✓ Consistent style
  • ✓ Readable layout
  • ✓ Appropriate comments

Review Output Format

# Code Review: <file-path>

## Summary
[Brief overview of file purpose and key findings]

## Quality Score: X/10
[Overall quality score with justification]

## Critical Issues (Must Fix)
- [Issue 1 with location and recommendation]
- [Issue 2 with location and recommendation]

## Important Issues (Should Fix)
- [Issue 1 with location and recommendation]
- [Issue 2 with location and recommendation]

## Suggestions (Consider)
- [Suggestion 1 with rationale]
- [Suggestion 2 with rationale]

## Strengths
- [Positive aspect 1]
- [Positive aspect 2]

## Detailed Analysis

### Code Quality
[Detailed quality assessment]

### Security
[Security assessment and concerns]

### Performance
[Performance analysis]

### Testing
[Test coverage and quality]

### Style
[Style guide compliance]

## Recommendations
1. [Priority 1 recommendation]
2. [Priority 2 recommendation]
3. [Priority 3 recommendation]

## Next Steps
[Suggested actions for improvement]

Best Practices

Constructive Feedback

  • Focus on code, not person
  • Explain "why" behind suggestions
  • Provide specific examples
  • Offer alternative solutions
  • Acknowledge good practices

Priority Levels

  • Critical: Security vulnerabilities, bugs, data loss
  • Important: Poor performance, missing tests, unclear code
  • Suggestions: Style improvements, refactoring opportunities

Context Awareness

  • Consider project stage (prototype vs. production)
  • Respect project conventions
  • Balance perfection with pragmatism
  • Focus on impactful improvements

Common Issues to Check

Python-Specific

  • Using eval() or exec() unsafely
  • Mutable default arguments
  • Catching Exception too broadly
  • Not using context managers for resources
  • String concatenation in loops
  • Missing init.py in packages
  • Incorrect use of class variables
  • Not using generators for large datasets

General Issues

  • Magic numbers (use constants)
  • Deeply nested code (>3 levels)
  • Long functions (>50 lines)
  • Duplicate code
  • Unclear variable names
  • Missing error handling
  • No input validation
  • Hard-coded credentials

Integration with Development Workflow

Pre-Commit Review

Use this skill before committing:

/review-code <file-you-modified>

Pre-Pull Request Review

Review all changed files:

git diff --name-only main | xargs -I {} /review-code {}

Refactoring Review

After refactoring, verify improvements:

/review-code <refactored-file>

Notes

  • Guidance Only: This skill provides review feedback and guidance. It does not automatically fix issues.
  • Comprehensive: Reviews cover multiple dimensions (quality, security, performance, style).
  • Actionable: Feedback includes specific recommendations and examples.
  • Project-Aware: Considers project-specific standards and conventions.

Used When

  • Before committing changes
  • During code refactoring
  • When security review is needed
  • For performance optimization
  • To ensure style compliance
  • Pre-pull request submission
  • Learning best practices
  • Mentoring code quality

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

29.75%
按下载量换算52

Gemini CLI

21.39%
按下载量换算37

OpenCode

15.89%
按下载量换算28

Antigravity

13.99%
按下载量换算24

Claude Code

8.55%
按下载量换算15

Cursor

3.13%
按下载量换算5

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills