AI-powered code quality analysis with automated fix suggestions and GitHub PR integration.
Get up and running locally in seconds.
git clone https://github.com/whoshotu/Dr.Code-II.git
cd Dr.Code-II
./setup.sh # Interactive — picks your AI provider, ports, and starts servicesThe setup wizard will prompt you to choose an AI provider (Ollama, OpenAI, Gemini, or Anthropic), configure ports, and launch the containers automatically.
Access the dashboard at http://localhost:3001.
Dr.Code-II is a self-hosted AI code review platform that analyzes pull requests, detects security risks and anti-patterns, and posts structured inline comments back to GitHub — all powered by a local LLM. No code leaves your infrastructure.
- Optional AI Providers: Support for local Ollama or hosted providers (OpenAI, Gemini, Anthropic).
- Auto Port Detection: Automatically selects the next available port for backend and frontend services.
- Setup Orchestration: Persistent setup re-run menu for changing configurations without data loss.
- Trash & Archive: Non-destructive "soft-delete" for analysis reports and sessions.
- GitHub PR Integration: Automated review on PR open/synchronize with HMAC signature verification.
- Encrypted Storage: All API keys and tokens are encrypted with Fernet before persistence.
GitHub PR ──webhook──▶ FastAPI Backend ──▶ Rule-based Detection + LLM Analysis ──▶ Inline PR Comments
│
SQLite
│
React Dashboard
- Webhook received — GitHub notifies the backend of PR activity.
- Analysis runs — Rule-based checks combined with LLM analysis detect issues.
- Comments posted — Structured review comments appear on the exact lines with fix suggestions.
| Module | Description |
|---|---|
| Analyzer | Hybrid rule + LLM detection for security risks, anti-patterns, and code smells. |
| Orchestrator | Intelligent setup script managing ports, providers, and environment state. |
| Trash System | Secure archival storage for trashing/restoring analysis data. |
| GitHub Bot | Real-time PR interaction and code injection layer. |
- Quickstart: 2-minute setup.
- Development Guide: Manual setup, troubleshooting, and advanced config.
- All API keys and tokens are encrypted with Fernet symmetric encryption.
- Webhook payloads are verified via HMAC SHA-256 when a secret is configured.
- Minimal data exposure: Analysis runs locally or within your trusted environment.
GPL 3 License — see LICENSE for details.