← 返回 Skills 市场
440
总下载
0
收藏
0
当前安装
4
版本数
在 OpenClaw 中安装
/install code-review-cycle-skill
功能描述
执行 Coding ↔ Review 循环。A 写代码 → B Review → A 修改(可选)。支持 codex/claude-code 作为 A 或 B。
使用说明 (SKILL.md)
Code Review Cycle
执行 A(编码) → B(Review) → 决策 的协作流程。
角色职责
| 角色 | 职责 | 权限 |
|---|---|---|
| A (Coder) | 写代码、改文件、实现功能 | ✅ 可写文件 |
| B (Reviewer) | Review 代码、提建议、做决策 | ❌ 只读,不写文件 |
| 主会话 | 调度 A/B、传递上下文、最终决策 | - |
触发方式
/cr \x3C功能描述>
/cr --agent-a codex --agent-b claude-code \x3C功能描述>
/cr --rounds 2 \x3C功能描述> # 最多自动循环 2 轮
参数
| 参数 | 默认值 | 说明 |
|---|---|---|
--agent-a |
codex |
负责写代码的 agent (codex/claude-code) |
--agent-b |
claude-code |
负责 Review 的 agent |
--rounds |
0 |
自动循环轮数(0=只执行 A→B,等你决定) |
--cwd |
当前 workspace | 代码目录 |
流程
- Spawn A → 写代码,输出 diff + 说明
- Spawn B → 只读 Review,输出:严重问题/建议优化/结论(不写文件)
- 决策点:
- 如果
--rounds > 0且 B 认为需要修改 → 自动回到步骤 1(最多 rounds 轮) - 否则 → 等你指令
- 如果
输出格式约定
A 的输出
## [A-Code] 改动摘要
- 文件 1: ...
## [A-Code] 实现说明
...
## [A-Code] 待确认点
1. ...
B 的输出(只读 Review)
## [B-Review] 严重问题
- [ ] ...
## [B-Review] 建议优化
- [ ] ...
## [B-Review] 结论
□ 需要修改(具体问题:#1, #3)
□ 可以直接合并
---
[B 职责说明] 我只负责 Review,不修改任何文件。如需修改,请 A 执行。
示例
/cr 实现用户登录表单验证
/cr --agent-a claude-code --agent-b codex 添加暗色模式切换
/cr --rounds 2 重构 utils/date.ts 增加单元测试
注意事项
- 主会话作为调度器,保留所有历史便于追溯
- 每轮结束后会暂停等你确认(除非 rounds>1)
- A 和 B 的会话是临时的,用完即弃(不保留上下文)
- B 只读不写 — Review 角色不修改任何文件
安全使用建议
This skill appears to do what it says: orchestrate a coder (A) and reviewer (B) loop. Before installing or running it, consider: 1) The reviewer role is only a behavioral constraint in the instructions — the platform or model must enforce 'read-only'; it is not technically enforced by the script. 2) A's output (diffs, code) is passed into B as plain text — do not use this on sensitive/private code or secrets unless you trust the models/providers. 3) The helper script is small and only prints JSON payloads; still review the script locally before running. 4) If you need stronger guarantees (e.g., enforce reviewer cannot write files, avoid exposing whole files), add procedural checks or policy controls in your environment. If any of these concerns are unacceptable, avoid using the skill or run it only on non-sensitive repositories.
功能分析
Type: OpenClaw Skill
Name: code-review-cycle-skill
Version: 0.1.4
The skill implements a legitimate multi-agent workflow for code reviews (Coder vs. Reviewer roles). The code in `run.js` and instructions in `SKILL.md` are consistent with the stated purpose, focusing on orchestrating OpenClaw agent sessions without any evidence of data exfiltration, unauthorized execution, or malicious prompt injection.
能力评估
Purpose & Capability
Name/description (orchestrate a coder + reviewer loop) matches the artifact: SKILL.md describes spawning A/B agents and run.js prints the session payloads. No unrelated credentials, binaries, or install steps are requested.
Instruction Scope
SKILL.md and run.js confine actions to spawning agents and exchanging textual diffs/outputs. However, the 'B only-read' rule is a behavioral constraint expressed in text and not technically enforced by the script — the skill relies on agent-side enforcement. The skill also passes A's output as input to B (expected), which could expose any secrets present in A's output to the reviewer agent.
Install Mechanism
No install spec — instruction-only plus a small helper script (run.js). Nothing is downloaded or written to disk by an installer; lowest-risk install posture.
Credentials
No environment variables, credentials, or config paths are requested. The scope of requested access is minimal and proportional to a code-review orchestrator.
Persistence & Privilege
always is false and the skill doesn't request persistent system modifications. The script and SKILL.md state sessions are temporary and do not retain context; there is no attempt to modify other skills or system-wide settings.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install code-review-cycle-skill - 安装完成后,直接呼叫该 Skill 的名称或使用
/code-review-cycle-skill触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v0.1.4
Version 0.1.4
- Major docs rework: greatly simplified SKILL.md, focusing on usage, roles, and workflow.
- Added a new README.md file.
- Updated default values and option details for `--agent-b` and `--rounds` parameters.
- Clarified the output format for both Coder (A) and Reviewer (B).
- Removed complex setup and ACP/OpenClaw runtime details from user-facing docs.
v0.1.2
- Refactored SKILL.md to use OpenClaw v1 metadata fields for dependencies and homepage link.
- Added emoji icon and homepage URL in the skill metadata.
- Moved binary and environment requirements from top-level requires to metadata.openclaw.requires.
- No changes to core logic or usage.
v0.1.1
Version 0.1.1
- 增加了 `requires` 字段,明确声明对 `git`、`node` 二进制及环境变量(ACP_RUNTIME、OPENCLAW_WORKSPACE)的依赖。
- 新增“Reviewer 只读保障机制”说明,强调 Reviewer 的只读约束应由 prompt、ACP agent 权限、多层机制共同保证,建议 ACP 层强制配置。
- 明确参数 `--rounds` 支持 0,表示每步都需用户确认,并更新了对应说明。
- 指出 `run.js` 仅作为 sessions_spawn payload 示例用途,不实际调用 ACP。
- 调整了部分参数和注意事项描述,提升前置依赖、权限边界等文档清晰度。
v0.1.0
Initial release of code-review-cycle skill for automated code review workflows.
- Automates A (Coder) → B (Reviewer) review cycles using ACP and OpenClaw.
- Supports configuration of agents (codex or claude-code) and number of review rounds.
- Enforces role boundaries: A can write code; B is strictly review-only, read-only.
- Automatically spawns code/review agents in sequence without pausing mid-cycle.
- Provides clear summaries after each review cycle and waits for user decision.
- Requires ACP runtime, OpenClaw, registered agents, and git-initialized workspace.
元数据
常见问题
Code Review Cycle 是什么?
执行 Coding ↔ Review 循环。A 写代码 → B Review → A 修改(可选)。支持 codex/claude-code 作为 A 或 B。 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 440 次。
如何安装 Code Review Cycle?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install code-review-cycle-skill」即可一键安装,无需额外配置。
Code Review Cycle 是免费的吗?
是的,Code Review Cycle 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
Code Review Cycle 支持哪些平台?
Code Review Cycle 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Code Review Cycle?
由 商汤小浣熊(@raccoon-office)开发并维护,当前版本 v0.1.4。
推荐 Skills