RepoPilot

alibaba / open-code-review

Search alibaba/open-code-review

GitHub

Code

How alibaba/open-code-review is laid out, and where to start for common changes.

A
Architecture grade
score 95/100
1
Import cycles
lower is better
400
Files mapped
260 imports between them
100%
Layering
of imports point one way

From the map of which files import which, built when the code was last read in full. It shows what depends on what, not a reading order.

Module map

Shade by
Entry points and orchestratorsFoundationStandaloneinternal117 files · 100+ commitspackage1 file · 6 commitspages54 files · 100+ commitsextensions52 files · 35 commitsacp49 files · 1 commitcmd30 files · 88 commitsexamples4 files · 19 commitsbin1 file · 4 commitsplugins1 file · 21 commits

9 modules, 2 links. A link means one module imports another; thicker lines mean more imports. Select a module to trace it: blue lines go to what it uses, orange lines come from what uses it.

internal11710100+Foundation
package1106Foundation
pages5400100+Standalone
extensions520035Standalone
acp49001Standalone
cmd300188Entry or leaf
examples40019Standalone
bin1014Entry or leaf
plugins10021Standalone

Where to start reading

  1. Repository root
  2. Repository root
  3. Declared command entry
  4. Likely start-up file
  5. Likely start-up file
  6. Suggested starting pointAI
  7. Suggested starting pointAI
  8. Suggested starting pointAI

Find files for a task

AI

Add a New Security Rule

  • Define rule logic following existing rule patterns in internal/delegate/
  • Add rule metadata and detection patterns to rule configuration
  • Register rule in scanning pipeline through batch processor
  • Add corresponding test case for the rule

Support a New LLM Provider

  • Implement new provider in internal/llm/ following chatgpt.go interface pattern
  • Add provider-specific authentication handler
  • Register provider selection logic in agent initialization
  • Add integration tests for new provider

Add a New Comment Generation Rule

  • Define comment formatting logic following existing patterns
  • Integrate comment generation into session pipeline
  • Add comment deduplication strategy if needed
  • Test comment output with format test suite

Trace command behavior

  • Declared by package.json (bin.ocr). Follow its exports or calls to find the implementation.

Trace runtime behavior

Add or update tests

Change build or automation

RepoPilot lists up to 500 files, so a file missing here may still exist.

  • Files marked “likely” are guessed from their names.

Code quality and hotspots

Largest source files

  • Branch points31 per file on average
  • Code issues169 errors, 22 warnings
  • Largest file3,074 lines
  • Hotspot load10 high-risk files

Static checks on the 15 largest source files.

Tests, CI and tooling

  • CIGitHub Actions · Jenkins14 workflows
  • Tests369 test filesGo test · 1.2 test files per source file (file count, not coverage)
  • Dependency updatesCodeQL

Test folders: acp/internal/adapter · acp/cmd/ocr-acp · acp/internal/adapter/presentation

Hotspots

Files that change often and branch heavily, highest first. Branch points count if, loop, case, catch, ternary, && and || in the file.