
AI Code Reviewer

Your Intelligent AI Pair Programmer for GitHub Pull Requests.
Instant summaries, deep code analysis, and actionable security insights.
β¨ Features
- π Dual Mode Operation: Run as a GitHub Action or a local CLI tool.
- π€ Multi-Provider LLM Support: First-class support for OpenAI, Anthropic Claude, Google Gemini, and OpenRouter.
- π§ Intelligent Analysis: Generates executive summaries, walkthroughs, and line-by-line review comments.
- π Security First: dedicated analysis for hardcoded secrets and potential vulnerabilities.
- π» Local Pre-PR Checks: Review your code locally before you even push.
- π¨ Custom Styling: Enforce your team's unique style guide and best practices.
π» Local Development (Pre-PR Check)
Review your changes locally without pushing to GitHub. This is perfect for catching issues early!
1. Installation
Quick Install (Recommended)
curl -sSL https://raw.githubusercontent.com/igcodinap/manque-ai/main/install.sh | bash
Manual Install
go install github.com/igcodinap/manque-ai@latest
2. Configuration
Interactive Setup (Recommended)
manque-ai config init
This wizard will guide you through setting up your LLM provider and API key. Config is saved to ~/.manque-ai/config.yaml.
Other config commands:
manque-ai config show # View current configuration
manque-ai config set provider openai # Set provider
manque-ai config set api_key sk-xxx # Set API key
manque-ai config set model gpt-4o # Set model
manque-ai config clear # Remove configuration
Alternative: Environment Variables
You can also use environment variables (they override config file):
export LLM_PROVIDER=openrouter
export LLM_API_KEY=sk-or-...
export LLM_MODEL=mistralai/mistral-7b-instruct:free
Provider Examples
OpenRouter (Default - Free tier available)
export LLM_PROVIDER=openrouter
export LLM_API_KEY=sk-or-...
# Default model: mistralai/mistral-7b-instruct:free
OpenAI
export LLM_PROVIDER=openai
export LLM_API_KEY=sk-...
export LLM_MODEL=gpt-4o
Anthropic
export LLM_PROVIDER=anthropic
export LLM_API_KEY=sk-ant-...
export LLM_MODEL=claude-sonnet-4-20250514
Local Ollama
export LLM_PROVIDER=openai
export LLM_BASE_URL=http://localhost:11434/v1
export LLM_API_KEY=ollama
export LLM_MODEL=llama3
3. Run Review
# Review changes in your current branch vs main
manque-ai local
# Compare specific branches
manque-ai local --base develop --head feature-login
# Debug mode (see exact API calls and diff sizes)
manque-ai local --debug
4. Update
manque-ai update
π GitHub Action Usage
Integrate directly into your CI/CD pipeline to review every Pull Request automatically.
name: AI Code Review
on:
pull_request:
types: [opened, synchronize]
jobs:
review:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- name: Manque AI
uses: docker://ghcr.io/igcodinap/manque-ai:latest
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
LLM_API_KEY: ${{ secrets.OPENAI_API_KEY }}
LLM_PROVIDER: "openai"
LLM_MODEL: "gpt-4o"
Configuration Options
| Variable |
Description |
Required (Action) |
Required (Local) |
Default |
GH_TOKEN |
GitHub API Token |
β
|
β |
- |
LLM_API_KEY |
LLM Provider Key |
β
|
β
|
- |
LLM_PROVIDER |
openai, anthropic, google, openrouter |
β |
β |
openrouter |
LLM_MODEL |
Specific model ID |
β |
β |
mistralai/mistral-7b-instruct:free |
STYLE_GUIDE_RULES |
Custom instructions for the AI |
β |
β |
- |
UPDATE_PR_TITLE |
Auto-update PR title |
β |
N/A |
true |
UPDATE_PR_BODY |
Auto-update PR description |
β |
N/A |
true |
π οΈ Advanced CLI Usage
The CLI can also be used to review remote PRs or check GitHub Actions context.
# Review a specific remote PR
manque-ai --repo owner/repo --pr 123
# Review by URL
manque-ai --url https://github.com/owner/repo/pull/123
π§ Architecture
The project is built with modularity in mind, separating the "brain" from the interface.
βββ cmd/ # CLI Commands
β βββ root.go # GitHub Action / Remote Review
β βββ local.go # Local Pre-PR Review
βββ pkg/
β βββ review/ # Core Review Engine (Shared Logic)
β βββ ai/ # LLM Client Adapters
β βββ diff/ # Git Diff Parser
β βββ github/ # GitHub API Client
βββ internal/ # Config & Logging
π€ Contributing
We love contributions! Please fork the repository and submit a Pull Request.
π License
MIT Licensed. default_api.