open-code-review/internal/tool
kite 77e73e53f8 feat(agent): add LLM-driven file grouping for multi-file co-review
Group functionally related files (e.g., impl + test, handler + model) into
a single review context using an LLM clustering step. This improves review
quality by giving the model cross-file awareness within related changes.

Key changes:
- Add file grouping agent with threshold-based decisions and recursive splitting
- Refactor dispatchSubtasks/executeSubtask to operate on DiffGroup instead of
  individual diffs, supporting combined multi-file diffs with FILE separators
- Add path validation in code_comment tool for multi-file groups
- Add StripDiffHeaders to reduce token usage in prompts
- Add extractJSONArray fallback for filter response parsing robustness
- Persist file group metadata to JSONL and render groups in viewer UI
- Merge intermediate tool-only agent rounds in viewer for cleaner display
- Update prompt templates: remove {{current_file_path}}, use <pending_review_diff>
2026-06-20 21:31:14 +08:00
..
code_comment.go feat(agent): add LLM-driven file grouping for multi-file co-review 2026-06-20 21:31:14 +08:00
code_search.go fix(security): block git ref option injection (#112) 2026-06-13 11:07:59 +08:00
code_search_test.go fix(security): block git ref option injection (#112) 2026-06-13 11:07:59 +08:00
comment_collector.go feat: add review filter to remove provably incorrect comments after subtask 2026-06-09 20:41:42 +08:00
definitions.go fix(tool): make Registry and DiffMap concurrency-safe via freeze semantics 2026-06-06 19:41:11 +08:00
file_find.go fix(security): block git ref option injection (#112) 2026-06-13 11:07:59 +08:00
file_read.go perf(tool): stream file reads line-by-line to avoid full-file memory allocation 2026-06-06 20:59:05 +08:00
file_read_diff.go fix(tool): make Registry and DiffMap concurrency-safe via freeze semantics 2026-06-06 19:41:11 +08:00
file_read_test.go fix(tool): constrain workspace file reads to repo (#109) 2026-06-12 17:57:28 +08:00
filereader.go Fix workspace symlink diff containment (#125) 2026-06-15 00:03:36 +08:00
response_message.go feat: init 2026-05-20 22:03:52 +08:00
stub.go fix(tool): propagate context.Context to all tool providers to enable subprocess cancellation 2026-06-06 19:26:34 +08:00