open-code-review/cmd/opencodereview
kite 4ee453fd79
Some checks are pending
CI / test (push) Waiting to run
feat(delegate): add delegation mode for host-agent driven code review (#383)
* feat(delegate): add delegation mode for host-agent driven code review

Add `ocr delegate` subcommand that provides deterministic file selection
and rule resolution without calling any LLM. This enables AI coding agents
to perform reviews themselves using OCR only for engineering scaffolding
(preview which files to review, resolve grouped rules by path).

Includes:
- `ocr delegate preview` — outputs reviewable file list with mode/ref metadata
- `ocr delegate rule <path...>` — outputs review rules grouped by content
- Claude Code plugin command (delegate-review.md)
- Skill definitions for Claude Code, Codex, and Cursor
- Unit tests for internal/delegate package
- README documentation synced across all 5 locales

* fix(delegate): group rules by source, pattern and text

GroupRules keyed groups on rule text alone, so files sharing identical
rule text but resolved from different sources or matched by different
patterns were merged into one group that kept only the first file's
Source/Pattern metadata. Use a composite (source, pattern, text) key so
each group's provenance is accurate for every file it contains.
2026-07-16 13:10:54 +08:00
..
background_file.go fix(background-file) Manage path at git repository root directory Refs:#324 (#327) 2026-07-13 11:27:54 +08:00
background_file_test.go fix(background-file) Manage path at git repository root directory Refs:#324 (#327) 2026-07-13 11:27:54 +08:00
config_cmd.go feat: Add OpenAI Responses API support and refactor protocol handling (#363) 2026-07-15 12:54:52 +08:00
config_cmd_test.go feat: Add OpenAI Responses API support and refactor protocol handling (#363) 2026-07-15 12:54:52 +08:00
config_dispatch_test.go test: improve coverage for cmd/opencodereview package from 42% to 70% 2026-06-27 01:47:48 +08:00
delegate_cmd.go feat(delegate): add delegation mode for host-agent driven code review (#383) 2026-07-16 13:10:54 +08:00
emit_run_result_test.go feat(review): add resumable sessions and session inspection (#306) 2026-07-09 11:43:11 +08:00
flags.go feat: Add OpenAI Responses API support and refactor protocol handling (#363) 2026-07-15 12:54:52 +08:00
flags_test.go feat(review): add resumable sessions and session inspection (#306) 2026-07-09 11:43:11 +08:00
git.go fix(tool): resolve file_read paths against git top-level in monorepos (#309) 2026-07-07 20:06:28 +08:00
git_test.go test: fix golangci-lint errcheck/staticcheck issues in test code (#323) 2026-07-08 22:46:18 +08:00
llm_cmd.go feat(vscode): add full-width BYOK provider config panel (#204) 2026-06-25 10:37:25 +08:00
main.go feat(delegate): add delegation mode for host-agent driven code review (#383) 2026-07-16 13:10:54 +08:00
output.go feat(review): add resumable sessions and session inspection (#306) 2026-07-09 11:43:11 +08:00
output_helpers_test.go feat(review): add resumable sessions and session inspection (#306) 2026-07-09 11:43:11 +08:00
output_test.go test: fix golangci-lint errcheck/staticcheck issues in test code (#323) 2026-07-08 22:46:18 +08:00
procattr_unix.go feat: add standard MCP tool support (#212) 2026-07-01 19:10:16 +08:00
procattr_windows.go feat: add standard MCP tool support (#212) 2026-07-01 19:10:16 +08:00
provider_cmd.go feat: Add OpenAI Responses API support and refactor protocol handling (#363) 2026-07-15 12:54:52 +08:00
provider_cmd_test.go test: fix golangci-lint errcheck/staticcheck issues in test code (#323) 2026-07-08 22:46:18 +08:00
provider_tui.go feat: Add OpenAI Responses API support and refactor protocol handling (#363) 2026-07-15 12:54:52 +08:00
provider_tui_funcs_test.go fix(tui): persist official-tab models and refine saved secret hint (#260) 2026-07-06 20:38:39 +08:00
provider_tui_test.go feat: Add OpenAI Responses API support and refactor protocol handling (#363) 2026-07-15 12:54:52 +08:00
review_cmd.go feat(telemetry): propagate W3C traceparent from parent process (#352) 2026-07-14 11:28:09 +08:00
review_cmd_test.go fix(cli): reject --to without --from in review flags (#151) 2026-06-16 20:26:22 +08:00
rules_cmd.go feat(rules): add ocr rules check command to preview effective rule for a file path 2026-05-26 22:11:39 +08:00
scan_cmd.go feat(telemetry): propagate W3C traceparent from parent process (#352) 2026-07-14 11:28:09 +08:00
scan_cmd_test.go test: improve coverage for cmd/opencodereview package from 42% to 70% 2026-06-27 01:47:48 +08:00
session_cmd.go feat(review): add resumable sessions and session inspection (#306) 2026-07-09 11:43:11 +08:00
session_cmd_test.go feat(review): add resumable sessions and session inspection (#306) 2026-07-09 11:43:11 +08:00
shared.go feat(review): add resumable sessions and session inspection (#306) 2026-07-09 11:43:11 +08:00
shared_test.go test: fix golangci-lint errcheck/staticcheck issues in test code (#323) 2026-07-08 22:46:18 +08:00
shell_unix.go feat: add standard MCP tool support (#212) 2026-07-01 19:10:16 +08:00
shell_windows.go feat: add standard MCP tool support (#212) 2026-07-01 19:10:16 +08:00
smallfiles_test.go test: improve coverage for cmd/opencodereview package from 42% to 70% 2026-06-27 01:47:48 +08:00
version.go feat(cli): display GitHub repository URL in version and help output 2026-06-02 22:50:36 +08:00
viewer_cmd.go feat: init 2026-05-20 22:03:52 +08:00