Xreview — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited Xreview (Plugin) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
Aggregate score unchanged between these scans.
The primary manifest — the file an agent reads to learn what this artifact does.
Agent-native code review engine for Claude Code and Codex CLI, powered by Codex.
xreview delegates code review to Codex (a separate AI model) so your coding agent gets an independent second opinion. It orchestrates a three-party review loop: Codex reviews, your agent verifies, you decide.
[中文版 README](docs/README.zh-TW.md)
Curious why this exists? I wrote a post about the motivation and how it works: Why I built xreview
When you ask your coding agent to review your code, the xreview skill takes over:
This isn't your agent reviewing its own work. It's a genuinely independent review from a different model, with your agent acting as a verification layer that filters out false positives before presenting to you.
Register the marketplace and install:
/plugin marketplace add davidleitw/xreview
/plugin install xreview@xreview-marketplacePaste this to your Codex CLI session:
Fetch and follow instructions from https://raw.githubusercontent.com/davidleitw/xreview/master/.codex/INSTALL.mdOr install manually:
# Install binary
curl -fsSL https://raw.githubusercontent.com/davidleitw/xreview/master/scripts/install.sh | bash
# Install skill
mkdir -p ~/.agents/skills/xreview
curl -fsSL -o ~/.agents/skills/xreview/SKILL.md https://raw.githubusercontent.com/davidleitw/xreview/master/.agents/skills/xreview/SKILL.mdnpm install -g @openai/codex)Just ask your coding agent to review:
Use xreview to check my code for bugs and security issuesOr be specific about which files:
Use xreview to review store/db.go and handler/exec.go for security vulnerabilitiesThe xreview skill triggers automatically. In Claude Code, you can also invoke it directly with /xreview.
| Category | Examples |
|---|---|
| Security | SQL injection, command injection, hardcoded secrets, missing auth |
| Logic | Nil pointer dereference, race conditions, off-by-one errors |
| Error Handling | Ignored errors, resource leaks, unclosed connections |
| Performance | N+1 queries, unnecessary allocations |
xreview supports language-aware review via --language. When the skill detects that review targets are written in a supported language, it automatically adds language-specific guidelines to the Codex prompt.
| Language | Key | Guidelines |
|---|---|---|
| C++ | cpp | ISO C++ Core Guidelines — memory safety, UB, concurrency, exception safety, ownership, class design |
| Go | go | Effective Go + Go Code Review Comments — goroutine safety, data race, resource leak, error handling, concurrency patterns |
Unsupported languages fall back to general-purpose review (same behavior as without the flag).
Each finding goes through a structured analysis:
F-001: SQL Injection (security/high)
store/db.go:34 — FindUser()
Trigger: user sends malicious string via /user?name=' OR '1'='1
Root cause: fmt.Sprintf concatenates user input directly into SQL query
Impact: attacker can read, modify, or delete any data in the database
-> Fix: changed to parameterized query db.Query("...WHERE name = ?", name)After all findings are addressed, Codex verifies the fixes. If it disagrees with a dismissal or finds an incomplete fix, the loop continues.
xreview keeps itself up to date automatically. During preflight (the first step of every review), it checks GitHub Releases for a newer version. The check is cached locally for 24 hours to avoid slowing things down.
When a new version is available, the skill runs xreview self-update before proceeding. The update downloads a pre-built binary matching your OS and architecture — no Go toolchain required. If the update fails for any reason, xreview continues with the current version.
You can also update manually:
xreview self-updatexreview ships as a standalone Go binary that your coding agent calls under the hood:
| Command | Purpose |
|---|---|
xreview preflight | Check environment (codex installed, API key, version, updates) |
xreview review --files <paths> | Run initial review |
xreview review --files <paths> --language <key> | Review with language-specific guidelines (cpp, go) |
xreview review --session <id> --message "..." | Resume for verification round |
xreview clean --session <id> | Clean up a session |
xreview clean --all | Clean up all sessions |
xreview self-update | Update to the latest version from GitHub Releases |
xreview version | Show version |
git clone https://github.com/davidleitw/xreview.git
cd xreview
go build -o xreview ./cmd/xreview/To load the plugin locally in Claude Code (without installing from marketplace):
claude --plugin-dir .This loads skills/ from the repo root via .claude-plugin/plugin.json. Use /reload-plugins inside the session to hot-reload after editing skill files.
Host Agent xreview (CLI) Codex (reviewer)
(Claude Code / Codex CLI)
| | |
|-- review request ------->| |
| |-- codex exec --------->|
| | (Codex reads code |
| | via git diff/files) |
| |<-- findings (JSON) ----|
| | [snapshot file |
| | checksums] |
|<-- findings (XML) ------| |
| | |
| [verify each finding] | |
| [challenge suspects] -->|-- codex resume ------->|
| |<-- re-evaluate --------|
| | |
| [present Fix Plan] | |
| [user approves] | |
| [fix code] | |
| | |
|-- resume --------------->| [detect changed files |
| | via checksum diff] |
| |-- codex resume ------->|
| | (prompt includes |
| | changed file list) |
| |<-- verify (JSON) ------|
|<-- verify (XML) --------| |
| | |
| [verbal summary] | |
|-- clean ---------------->| |git diff or reads files in read-only mode)/tmp/xreview/sessions/ (ephemeral)--session <session-id>See Roadmap & Design for the full plan. Key directions:
--language currently supports C++ and Go. More languages (Rust, TypeScript, Python) planned./plugin uninstall xreviewrm -rf ~/.agents/skills/xreview# Remove binary (check which location applies)
rm "$(which xreview)"
# Remove version cache
rm -rf ~/.cache/xreview
# Remove session data (optional, stored in /tmp)
rm -rf /tmp/xreviewMIT License — see LICENSE for details.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.