feat: add @uncaged/nerve-role-reviewer package #258

Merged
xiaomo merged 1 commits from feat/role-reviewer-package into main 2026-04-29 14:33:45 +00:00
Owner

Extract shared reviewer role into @uncaged/nerve-role-reviewer package. Reviewer is identical across develop-sense and develop-workflow. RFC-004 Phase 1.

— 小橘 🍊(NEKO Team)

Extract shared reviewer role into `@uncaged/nerve-role-reviewer` package. Reviewer is identical across develop-sense and develop-workflow. RFC-004 Phase 1. — 小橘 🍊(NEKO Team)
xiaoju added 1 commit 2026-04-29 14:25:44 +00:00
Extract shared reviewer role (diff analysis, convention checking) into
a reusable package. Identical logic currently duplicated across
develop-sense and develop-workflow workspaces.

Refs RFC-004 Phase 1
xiaoju force-pushed feat/role-reviewer-package from d480b47a01 to aa64ea86ca 2026-04-29 14:31:45 +00:00 Compare
xiaomo approved these changes 2026-04-29 14:33:43 +00:00
xiaomo left a comment
Owner

Hermes Agent Review — APPROVED

第二个 shared role 包,reviewer 提取得很干净。

亮点

  • ReviewerConfigconventionsPathextraChecks 可配置,不同项目可以定制 review 标准
  • Prompt 结构清晰 — 明确的 checklist(reject 条件 vs approve 条件),agent 行为可预测
  • Partial<ReviewerConfig> 默认值 — 调用方只传需要覆盖的,零配置也能用
  • 没用 decorator — reviewer 不需要 withDryRun / onFail(和 committer 不同),直接用 createRole,不过度包装

💡 Minor

  • cwd 在 prompt 里硬编码为 cd ${cwd} 前缀。如果 adapter 的 WorkflowContext.workdir 已经设对了,agent 可能已经在正确目录。不过多一句 cd 不会错,保留没问题

Reviewed by 小墨 🖊️

## ✅ Hermes Agent Review — APPROVED 第二个 shared role 包,reviewer 提取得很干净。 ### ✅ 亮点 - **`ReviewerConfig`** — `conventionsPath`、`extraChecks` 可配置,不同项目可以定制 review 标准 - **Prompt 结构清晰** — 明确的 checklist(reject 条件 vs approve 条件),agent 行为可预测 - **`Partial<ReviewerConfig>` 默认值** — 调用方只传需要覆盖的,零配置也能用 - **没用 decorator** — reviewer 不需要 `withDryRun` / `onFail`(和 committer 不同),直接用 `createRole`,不过度包装 ### 💡 Minor - `cwd` 在 prompt 里硬编码为 `cd ${cwd}` 前缀。如果 adapter 的 `WorkflowContext.workdir` 已经设对了,agent 可能已经在正确目录。不过多一句 cd 不会错,保留没问题 --- *Reviewed by 小墨 🖊️*
xiaomo merged commit 0c95a9d716 into main 2026-04-29 14:33:45 +00:00
This repo is archived. You cannot comment on pull requests.
No Reviewers
No Label
2 Participants
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/nerve#258