AI code review CLI
that catches
review blockers
Catch review blockers, architectural violations, and security vulnerabilities before they ever reach a human reviewer. MP Sentinel is an AI Code Review CLI — multi-provider, ESM-native, runs 100% locally.
$ npx mp-sentinel
UserService instead.useEffect used for data fetching. Consider using a data loader or React Query pattern.src/lib/service.ts.Local-First
Your code never leaves your machine unencrypted.
Multi-Provider
Gemini, GPT-5, Claude, Grok, OpenRouter — you choose.
CI-Ready
Exit-code gating for GitHub Actions, GitLab CI, and more.
Everything you need for better reviews
MP Sentinel goes beyond surface-level linting to catch what matters — architecture, security, and design patterns.
Multi-Provider AI
Run reviews through Gemini, GPT-5, Claude, Grok or OpenRouter. Switch providers with a single env var — no code changes needed.
Architectural Guardrails
Detect architectural violations — Controllers calling DB directly, useEffect data fetching, SOLID principle breaches — not just trivial lint errors.
3-Layer Security
Smart filtering + secret scrubbing + dry-run mode. Your secrets NEVER leave your machine unencrypted. Designed for enterprise compliance.
Repository Intelligence
Source-index aware. Understands blast radius of hub files, public API risk, test coverage gaps, and key dependency chains.
CI/CD Native
Built-in GitHub Actions + GitLab CI support. Standard exit codes (0/1/2) to gate PRs and MRs. Works in any pipeline.
Agent Adapters & Init (v3.0.3)
Guided init command for fast setup. 7+ agent adapters — Claude Code, Cursor, Copilot, Aider, Roo, Zed, JetBrains Junie — plus per-rule opt-out and expanded MCP preset library.
How It Works
A three-step local review loop. Install once, configure your rules, and let AI catch problems before they ship.
npm install -D mp-sentinelInstall
Add MP Sentinel as a dev dependency — one command, zero config.
Works with npm, pnpm, yarn, and bun.
{
"techStack": ["typescript", "react", "node"],
"rules": ["no-direct-db-in-controllers"]
}Configure
Create a config file with your tech stack, review rules, and AI provider.
Built-in rules cover architecture, security, and style.
mp-sentinel
# or: mp-sentinel --format json > review.jsonReview
Run mp-sentinel — defaults to diffing origin/main…HEAD. Output as console, JSON, or Markdown.
Exit code 1 = issues found. Gate PRs in CI.
CLI that fits your workflow
Review staged changes, specific commits, branches, or arbitrary files — whatever your workflow demands.
Configure once, review everywhere
A single .mp-sentinelrc.json defines your tech stack, rules, AI provider, and MCP context.
{
"techStack": ["typescript", "react", "node", "postgres"],
"rules": ["no-direct-db-in-controllers", "enforce-service-layer"],
"ruleFiles": ["./rules/custom-rules.json"],
"ai": {
"provider": "google",
"model": "gemini-2.5-flash",
"temperature": 0.3
},
"mcp": {
"servers": {
"github": {
"command": "npx",
"args": ["@modelcontextprotocol/server-github"]
}
}
}
}techStack
Defines your project technologies for context-aware reviews.
rules / ruleFiles
Built-in rules plus custom paths for organization-specific guardrails.
ai provider
Switch between Google, OpenAI, Anthropic, xAI, or OpenRouter.
MCP servers
Inject external context (GitHub, docs) into review prompts.
Choose your AI provider
MP Sentinel supports multiple AI providers. Switch between them with a single environment variable — no code changes.
Google Gemini
Best speed-to-cost ratio for most teams.
gemini-2.5-flashOpenAI GPT
Highest review quality. Industry benchmark.
gpt-5.2Anthropic Claude
Strong reasoning and long-context reviews.
claude-sonnet-4-6xAI Grok
Fast reasoning model. Great for CI pipelines.
grok-4-1-fast-reasoningOpenRouter
Try any provider with one API key.
openai/gpt-5.2Models listed above are defaults. You can override them per-provider in your .env config — e.g. "AI_MODEL"="claude-opus-4-7".
Your code stays local
— unless you say so.
A three-layer defense model: intelligent filtering, automated secret scrubbing, and dry-run previews give you full control over what reaches any AI provider.
File Filtering
Allowlist + .gitignore rules + sensitive blocklist. Only relevant files ever reach analysis.
Secret Redaction
Detects and redacts API keys, tokens, and credentials automatically. Patterns match 40+ secret types.
Dry-Run Preview
Preview token estimation and file selection before anything is sent. Zero data egress without approval.
Only filtered, redacted, approved data is transmitted over HTTPS.
Works with your editor
Generate agent rules for your editor of choice. MP Sentinel integrates with the tools you already use.
Frequently asked
questions
Quick answers to common concerns about using MP Sentinel in your workflow.
--dry-run to preview what would be sent — including token estimates — before any data leaves your machine.useEffect used for data fetching instead of a proper loader..mp-sentinelrc.json under "rules" or point to external rule files with "ruleFiles". Rules can target specific patterns, architectural layers, or naming conventions unique to your project.Ship cleaner
code today.
MP Sentinel is a free, MIT-licensed AI code review CLI that catches anti-patterns, security issues, and architectural violations — before they reach production. Runs entirely on your machine. No data leaves without your approval.