Review Scope is an intelligent PR review platform that combines static analysis, semantic context, and AI reasoning to provide comprehensive, fast code reviews on GitHub.
Review Scope analyzes pull requests end-to-end, evaluating code quality, security, performance, and maintainability. It features smart model routing to leverage Free Gemini models for speed and cost-efficiency, while reserving capable models for complex logic.
Key Capabilities:
- π Static Analysis β AST-based rule detection (no LLM required, always free)
- π§ AI-Powered Reviews β Complexity-aware routing between fast (Gemini Flash) and capable (Gemini 3/GPT-5) models
- π Semantic RAG β Retrieves relevant code context from your repository's history
- β‘ Smart Batching β Handles large PRs by intelligently chunking files
- π― Rule Validation β LLM classifies static findings (valid/false-positive/contextual)
- π° BYO API Keys β Transparent pricing, you pay only for what you use
Frontend & Dashboard:
- Next.js 16 (Turbopack)
- TailwindCSS
- NextAuth (GitHub OAuth)
Backend & Processing:
- Node.js Worker (background review jobs)
- Drizzle ORM + PostgreSQL
- Redis (caching & rate limiting)
AI & LLM:
- OpenAI GPT-4 class models (for complex reasoning)
- Gemini Flash models (fast, low-cost reviews)
- Context Engine (RAG + chunking)
Integration:
- GitHub Webhooks (real-time PR events)
- Dodo Payment Gateway (billing integration)
- GitHub API (PR data, code retrieval)
ReviewScope/
βββ apps/
β βββ api/ # REST API & webhooks
β βββ dashboard/ # Next.js web app (pricing, settings, auth)
β βββ worker/ # Node.js background job processor
βββ packages/
β βββ context-engine/ # RAG, chunking, layer assembly
β βββ llm-core/ # LLM routing, prompting, response parsing
β βββ rules-engine/ # Static analysis (JavaScript/TypeScript)
β βββ security/ # Encryption, masking utilities
βββ tsconfig.base.json # Shared TypeScript config
- User Guide - How to install, configure, and use ReviewScope.
- Architecture - Deep dive into the system design and data flow.
- Contributing - Guide for developers who want to contribute to the project.
- Node.js 18+
- PostgreSQL 14+
- Redis URL (docker-compose)
- GitHub App (for webhooks)
- LLM API keys (Gemini & OpenAI)
git clone https://github.com/Review-scope/ReviewScope
cd ReviewScope
npm installCreate .env.local files in each app:
apps/api/.env.local
DATABASE_URL=postgresql://user:pass@localhost/reviewscope
GITHUB_APP_ID=123456
GITHUB_APP_PRIVATE_KEY="-----BEGIN RSA PRIVATE KEY..."
GITHUB_WEBHOOK_SECRET=your_webhook_secret
apps/worker/.env.local
DATABASE_URL=postgresql://user:pass@localhost/reviewscope
REDIS_URL=https://default:password@redis-url.upstash.io
GEMINI_API_KEY=your_gemini_key
OPENAI_API_KEY=your_openai_key
apps/dashboard/.env.local
DATABASE_URL=postgresql://user:pass@localhost/reviewscope
NEXTAUTH_SECRET=generate_with_openssl_rand_base64_32
NEXTAUTH_URL=http://localhost:3000
GITHUB_ID=your_github_app_client_id
GITHUB_SECRET=your_github_app_secret
cd apps/api
npx drizzle-kit generate
npx drizzle-kit migrateTerminal 1 β API:
cd apps/api
npm run devTerminal 2 β Worker:
cd apps/worker
npm run devTerminal 3 β Dashboard:
cd apps/dashboard
npm run devDashboard available at http://localhost:3000
| Feature | Free | Pro | Enterprise |
|---|---|---|---|
| Price | $0 | $15/mo | Contact Sales |
| Repositories | Unlimited | Unlimited | Unlimited |
| Reviews Limit | 60 / month | Unlimited | Unlimited |
| RAG Context | β | β (5 snippets) | β (8+ snippets) |
| Custom Prompts | β | β | β |
| Support | Community | Priority |
All tiers include:
- Static analysis (always free)
- AI reviews via your own API keys
- Unlimited files per PR
- DODO payments seamless upgrades
GitHub PR Event
β
API Webhook Handler
β
Extract PR diff + fetch repo context
β
Queue Review Job (Redis/Bull)
β
Worker: Complexity Scorer
β
Run Static Rules (AST analysis)
β
RAG Retriever (semantic search)
β
Context Engine (assemble layers)
β
LLM Router (Gemini vs GPT-4)
β
Generate Review + Rule Validation
β
Post Comment to GitHub PR
Rules Engine (packages/rules-engine/)
- JavaScript/TypeScript AST parser
- Detects anti-patterns, security issues, code quality problems
- Zero LLM cost, always runs
Context Engine (packages/context-engine/)
- Semantic RAG using Upstash Redis
- Retrieves relevant code snippets from PR history
- Assembles system prompt with all context layers
LLM Core (packages/llm-core/)
- Routes by PR complexity (Gemini for simple, GPT-4 for complex)
- Injects rule violations into prompt
- Parses response including rule validation classifications
Worker (apps/worker/)
- Bull queue for async job processing
- Executes complexity scorer, rules, RAG, LLM calls
- Rate limiting per plan (Free=60/month, Pro/Team=Unlimited)
Edit system prompt per repository:
Dashboard β Repositories β [Select] β Settings β Custom Prompt
Edit apps/worker/src/lib/plans.ts:
FREE: { monthlyReviewsLimit: 60, ragK: 0, allowCustomPrompts: false },
PRO: { monthlyReviewsLimit: Infinity, ragK: 8, allowCustomPrompts: true },Edit packages/llm-core/src/selectModel.ts:
// Complexity thresholds for model routing
if (complexity === "trivial" || complexity === "simple") {
return "gemini-2.5-flash-lite"; // Lowest cost / Free
} else {
return "gemini-3-flash"; // Better reasoning for complex changes
}π§ Email: parasverma7454@gmail.com
π GitHub Issues: ReviewScope Issues
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
All PRs are reviewed by ReviewScope! π€
ReviewScope is proprietary software. See LICENSE file for details. -->
Built with β€οΈ for developers who care about code quality.