mirror of
https://github.com/affaan-m/ECC.git
synced 2026-10-16 21:25:42 +02:00
`scripts/ci/validate-agents.js` reads only `agents/`, so the translated copies under `docs/<locale>/agents/` were never validated against the agent they describe — and drifted. Two kinds of drift, both machine-checkable and both wrong in the same direction (the translations were made from an older revision and never re-synced): - **Model tier, 39 files.** Every one names a costlier tier than ships: haiku -> sonnet, sonnet -> opus. `security-reviewer` reads `opus` in ja-JP and zh-TW; it ships `sonnet`. - **Tool set, 15 files.** `security-reviewer` and `database-reviewer` list `Write` and `Edit` in **all seven locales** — both agents ship read-only (`Read, Grep, Glob, Bash`). `seo-specialist` in zh-CN adds a `Bash` the canonical agent does not have. Documenting a reviewer as able to write is the kind of inaccuracy someone auditing what these agents can touch would act on. Sync `model` and the `tools` set to canonical, preserving each locale's existing list style so the diff is only the values that were wrong. The `["a", "b"]` vs `a, b` formatting difference is left alone: it is consistent per locale and carries no meaning. Add `tests/ci/locale-agent-frontmatter.test.js` so this cannot drift back. `tools` is compared as a set, not a string, so the style difference stays legal; prose is not compared at all. The last case pins the specific failure: a canonical read-only agent may never be documented with Write or Edit. `.kiro/agents/` is deliberately excluded — it uses a different schema (`allowedTools: [read, shell]`, no `model`), not a translation of this one.
925 B
925 B
name, description, model, tools
| name | description | model | tools | |||
|---|---|---|---|---|---|---|
| comment-analyzer | 分析代码注释的准确性、完整性、可维护性和注释腐烂风险。 | haiku |
|
注释分析代理
您确保注释准确、有用且可维护。
分析框架
1. 事实准确性
- 对照代码验证声明
- 检查参数和返回值描述是否与实现一致
- 标记过时的引用
2. 完整性
- 检查复杂逻辑是否有足够解释
- 验证重要副作用和边界情况是否已记录
- 确保公共 API 有足够完整的注释
3. 长期价值
- 标记仅复述代码的注释
- 识别容易快速过时的脆弱注释
- 暴露 TODO / FIXME / HACK 技术债务
4. 误导性元素
- 与代码矛盾的注释
- 对已移除行为的过时引用
- 过度承诺或描述不足的行为
输出格式
按严重程度分组提供建议性发现:
InaccurateStaleIncompleteLow-value