code-review-en

A set of English-language rules for reviewing code changes in a pull request, which is a proposed update to a code repository. It focuses on understanding the change and finding confirmed problems.

In plain words
What is it for?
Use it to guide reviews of pull requests or merge requests. It helps identify the change's scope, understand how the code fits together, and check the complete set of edits.
Why use it?
It helps avoid shallow reviews that inspect only style or a small part of the change. Reviewers get guidance to consider the full change, its purpose, design, performance, and security.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/oldjii/code-review-mcp/code-review-en
Clone the repo
git clone --depth 1 https://github.com/OldJii/code-review-mcp

Made for: Cursor.

Per session 6 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,662 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00006 $0.01662
Opus 5 $0.00003 $0.00831
Sonnet 5 $0.00001 $0.00332
Haiku 4.5 $0.00001 $0.00166

Measured 2d ago against content hash 7c7caf705418, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

code-review-en scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/code-review-en.mdc · 269 lines

How it starts

The opening of the file, as written. The whole thing — 269 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Code Review Guidelines

Automatically select version based on user input language. Use this file for English input, use code-review.mdc for Chinese input.

Core Principles

Understand First

  • Understand the overall PR/MR purpose before analyzing diff
  • Deep analysis (architecture/logic/performance/security) over style checks
  • Only flag "confirmed issues", not "potential issues"
  • Analyze with context, not in isolation

Review Workflow

Step 1: Determine PR Type

Main repo PR -> Extract module PRs from description
Module PR -> Review directly

Step 2: Get Complete Changes

changes = get_pr_changes(provider, repo, pr_id)
for change in changes["changes"]:
    full_diff = change["diff"]
    analyze(full_diff)

Required: Review all files and complete diffs Forbidden: diff[:100] or changes[:10]

Step 3: Understand PR Context (Do This First)

Before reviewing any diff, answer:

  1. Purpose (from title + description): New feature / Bug fix / Refactor?
  2. Scope (from changes): Which files added/deleted/modified?
  3. Architecture: Class relationships, data flow, design patterns?
  4. Expected Implementation: What should be implemented?

Step 4: Deep Code Analysis

4.1 Understand Diff Intent
  • What role does this diff play in the overall PR?
  • Does it align with the PR purpose?
4.2 Architecture Review
  • Single responsibility?
  • Code duplication?
  • Clear abstraction layers?
  • Reasonable design in overall architecture?
4.3 Logic Review (with context)
  • Boundary conditions: Does caller already ensure non-null?
  • Exception scenarios: Can they actually occur in business flow?
  • State transitions: Complete in context of full state machine?

Avoid false positives: Caller already validated -> Skip

4.4 Performance Review (realistic scenarios)
  • Data volume? Will it actually be a bottleneck?
  • Loop iterations? Actually impact performance?
  • Time cost? Will it actually cause lag?

Read the full file on GitHub · 269 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 269 lines · 6 tokens per session scan A 7c7caf705418

Subscribe to this mod's changes

code-review-en is a cursor rule published in the GitHub repository OldJii/code-review-mcp (5 stars, last pushed 6d ago), licensed MIT. It adds 6 tokens to every session and 1,662 once invoked, about $0.0000 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.