Problem Statement
Summary
Running ocr review on a medium-sized monorepo feature branch (~173 reviewable files, ~22k lines changed) took 8 minutes 48 seconds with default concurrency. This makes it impractical to use in interactive code-review workflows or in CI for large Go/Python monorepos.
Environment
- ocr version: @alibaba-group/open-code-review (latest at time of writing)
- Project: Single Go module monorepo with Python services
- Branch diff: 318 files changed, +22,673 / -1,999 lines
- Files reviewed by OCR: 173 files
- Command:
ocr review --audience agent
--from main
--to xxx
--background "..."
--timeout 5
--concurrency 8
- Elapsed time: 8m 48s
- Token usage: ~1,382,845 tokens (~1,336,570 input / ~46,275 output)
Observed behavior
- The review completed successfully but consumed nearly 9 minutes for a routine feature-branch diff.
- No progress UI is emitted when --audience agent is used, so the user has no feedback during the wait.
- With default --timeout 10, worst-case runtime for similarly sized branches could approach or exceed 20–30 minutes.
Expected behavior
- A branch of this size should complete in under 2–3 minutes in interac
- CI usage should ideally finish in under 5 minutes.
- There should be visible progress or a --watch/--progress option even
Possible improvements
- Smarter file filtering / diff summarization
- Skip or collapse generated code (e.g. kitex_gen/, hertz_gen/, pbgen/, mock binaries) more aggressively.
- Provide a built-in exclude pattern for common generated directories
- Incremental / cached review
- Cache per-file review results keyed by file hash so unchanged files between review runs are not re-analyzed.
- Support --since-last-review to only review files changed since the
- Tiered review strategy
- Fast pass: identify high-risk files first (security-sensitive paths, new files, large diffs).
- Deep pass: optional, only on flagged files.
- Streaming / progress in agent mode
- Emit NDJSON or line-delimited progress events so CI/agent consumers can report status.
- Add --progress flag for agent mode.
- Configurable cost/time budget
- Add --max-tokens / --max-time flags to cap total review cost and time, returning partial results instead of running to completion.
Proposed Solution
maybe there is an fast mode
Alternatives Considered
No response
Affected Area
Review Agent / LLM interaction
Additional Context
No response
Problem Statement
Summary
Running ocr review on a medium-sized monorepo feature branch (~173 reviewable files, ~22k lines changed) took 8 minutes 48 seconds with default concurrency. This makes it impractical to use in interactive code-review workflows or in CI for large Go/Python monorepos.
Environment
ocr review --audience agent
--from main
--to xxx
--background "..."
--timeout 5
--concurrency 8
Observed behavior
Expected behavior
Possible improvements
Proposed Solution
maybe there is an fast mode
Alternatives Considered
No response
Affected Area
Review Agent / LLM interaction
Additional Context
No response