Open Code Review: AI-Powered Code Review Tool from Alibaba
This repository profile is provided by osrepos.com, an open source repository discovery platform.

Summary
Open Code Review is an AI-powered command-line interface tool for code review, battle-tested at Alibaba's scale. It leverages a hybrid architecture, combining deterministic engineering with an LLM agent, to provide secure, fast, and efficient code analysis. This tool generates precise, line-level comments and supports a multi-language ruleset, ensuring high-quality code reviews.
Repository Information
Topics
Click on any tag to explore related repositories
Use at your own risk
OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.
Introduction
Open Code Review is an AI-powered code review CLI tool, originally developed and battle-tested at Alibaba Group. It has served tens of thousands of developers, identifying millions of code defects with high efficiency and precision. This open-source project offers a robust solution for automated code analysis, leveraging a hybrid architecture that combines deterministic pipelines with an LLM agent.
It reads Git diffs, sends changed files to a configurable LLM via an agent with tool-use capabilities, and generates structured review comments with line-level precision. The agent can read full file contents, search the codebase, inspect other changed files for context, and produce deep reviews, not just surface-level diff feedback. Beyond diff review, ocr scan can review entire files for auditing unfamiliar codebases.
Why Use and Key Benefits
General-purpose AI agents often struggle with code review due to incomplete coverage, inaccurate issue positioning, and inconsistent quality. Open Code Review addresses these challenges with its unique hybrid design, combining deterministic engineering with an intelligent agent.
Deterministic Engineering ensures critical review steps are precise and reliable. This includes accurate file selection, smart bundling of related files for isolated context, and fine-grained rule matching to focus the model's attention. It also features external positioning and reflection modules for improved comment accuracy.
The Agent component excels in dynamic decision-making and context retrieval, utilizing scenario-tuned prompts and a purpose-built toolset optimized for code review. This approach leads to significantly higher precision and F1 scores, while consuming fewer tokens compared to general-purpose agents, as demonstrated by its benchmark results.
Installation
To get started with Open Code Review, ensure you have Git version 2.41 or higher installed. The easiest way to install the CLI tool is via npm:
npm install -g @alibaba-group/open-code-review
After installation, the ocr command will be globally available. For alternative installation methods, including binaries from GitHub Releases or building from source, please refer to the official documentation.
Examples
Before reviewing code, you need to configure your Large Language Model (LLM) provider and model. The CLI provides an interactive setup:
ocr config provider # Select a built-in provider or add a custom one
ocr config model # Pick a model for the active provider
Once configured, you can start reviewing your code using various modes:
cd your-project
# Workspace mode, reviews all staged, unstaged, and untracked changes
ocr review
# Branch range, reviews changes since it diverged from main
ocr review --from main --to feature-branch
# Single commit review
ocr review --commit abc123
# Full-file scan, reviews entire files without git history
ocr scan
# Delegation mode, lets your AI coding agent perform the review
ocr delegate preview
Links
Explore Open Code Review further with these resources:
Related repositories
Similar repositories that may be relevant next.
Awesome-Self-Evolving-Agents: A Curated List for AI Agent Research
September 14, 2026
Awesome-Self-Evolving-Agents is a comprehensive GitHub repository offering a curated collection of resources on self-evolving agents. It includes a systematic survey, research papers, benchmarks, and open-source projects, providing valuable insights into this rapidly advancing field of AI. This repository serves as an essential guide for researchers and developers exploring model-centric, environment-centric, and co-evolutionary approaches.

open-slide: An AI-Native Slide Framework for React Presentations
September 9, 2026
open-slide is a powerful slide framework built for AI agents, enabling users to create presentations by describing them in natural language. Coding agents then generate the React components, while open-slide handles the canvas, scaling, navigation, and presentation modes. This allows agents to focus entirely on content, streamlining the creation of polished, agent-driven decks.

best-skills: Daily-Updated Rankings for Top Agent Skills
September 8, 2026
The LinklyAI/best-skills repository offers daily-updated rankings of the top 100 agent skills. It aggregates data on installs, growth, and social buzz from various platforms like skills.sh, ClawHub, Tencent SkillHub, GitHub, and X. This open-data project provides a comprehensive, cross-ecosystem view of agent skill performance, making it an invaluable resource for developers and researchers.

Context Engineering Kit: Enhance AI Agent Quality with Advanced Skills
September 6, 2026
The Context Engineering Kit is a powerful collection of hand-crafted Claude Code Skills designed to significantly improve the quality and predictability of AI agent results. It offers advanced context engineering techniques with a minimal token footprint, ensuring efficiency and effectiveness across platforms like OpenCode, Cursor, and Gemini CLI. This kit provides granular control over plugins and includes an open-source alternative to CodeRabbit, enhancing development workflows.
Source repository
Open the original repository on GitHub.