cc-devflow 4.5.1 → 4.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/.claude/skills/cc-act/CHANGELOG.md +14 -0
  2. package/.claude/skills/cc-act/PLAYBOOK.md +26 -1
  3. package/.claude/skills/cc-act/SKILL.md +36 -7
  4. package/.claude/skills/cc-act/assets/PR_BRIEF_TEMPLATE.md +20 -0
  5. package/.claude/skills/cc-act/references/closure-contract.md +8 -0
  6. package/.claude/skills/cc-act/scripts/cc-act-common.sh +6 -1
  7. package/.claude/skills/cc-act/scripts/render-pr-brief.sh +99 -0
  8. package/.claude/skills/cc-act/scripts/verify-act-gate.sh +17 -1
  9. package/.claude/skills/cc-check/CHANGELOG.md +14 -0
  10. package/.claude/skills/cc-check/PLAYBOOK.md +101 -1
  11. package/.claude/skills/cc-check/SKILL.md +128 -7
  12. package/.claude/skills/cc-check/assets/REPORT_CARD_TEMPLATE.json +121 -1
  13. package/.claude/skills/cc-check/references/review-contract.md +88 -0
  14. package/.claude/skills/cc-check/scripts/render-report-card.js +172 -5
  15. package/.claude/skills/cc-check/scripts/verify-gate.sh +21 -0
  16. package/.claude/skills/cc-investigate/CHANGELOG.md +13 -0
  17. package/.claude/skills/cc-investigate/PLAYBOOK.md +105 -4
  18. package/.claude/skills/cc-investigate/SKILL.md +185 -8
  19. package/.claude/skills/cc-investigate/assets/ANALYSIS_TEMPLATE.md +77 -3
  20. package/.claude/skills/cc-investigate/assets/TASKS_TEMPLATE.md +10 -3
  21. package/.claude/skills/cc-investigate/assets/TASK_MANIFEST_TEMPLATE.json +102 -1
  22. package/.claude/skills/cc-investigate/references/investigation-contract.md +146 -0
  23. package/.claude/skills/cc-simplify/CHANGELOG.md +15 -0
  24. package/.claude/skills/cc-simplify/SKILL.md +255 -35
  25. package/CHANGELOG.md +16 -0
  26. package/docs/examples/example-bindings.json +3 -3
  27. package/docs/examples/full-design-blocked/README.md +1 -1
  28. package/docs/examples/full-design-blocked/changes/REQ-002-bulk-invite-import/review/report-card.json +140 -3
  29. package/docs/examples/local-handoff/README.md +1 -1
  30. package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/review/report-card.json +92 -0
  31. package/docs/examples/pdca-loop/README.md +1 -1
  32. package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/handoff/pr-brief.md +20 -0
  33. package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/review/report-card.json +92 -0
  34. package/lib/skill-runtime/review.js +64 -1
  35. package/lib/skill-runtime/schemas.js +150 -3
  36. package/package.json +1 -1
@@ -1,5 +1,19 @@
1
1
  # CC-Act Skill Changelog
2
2
 
3
+ ## v1.6.4 - 2026-04-28
4
+
5
+ - add a readiness dashboard covering review freshness, review quality, specialist facets, QA coverage, browser QA, failure ownership, documentation release, and PR body accuracy
6
+ - require verification to rerun on every cc-act invocation while keeping ship actions idempotent
7
+ - update `verify-act-gate.sh` to recognize `claimEvidence`, review freshness, QA coverage/browser status, and unresolved failure ownership
8
+ - update `render-pr-brief.sh`, shared evidence extraction, and the PR brief template with readiness and PR body accuracy fields
9
+
10
+ ## v1.6.3 - 2026-04-28
11
+
12
+ - require PR briefs and PR bodies to carry the reviewed base/head SHA, review packet summary, finding triage, and QA / claim evidence summary
13
+ - require post-merge closeout to verify the merged result instead of relying only on pre-merge evidence
14
+ - add destructive cleanup confirmation rules for branch, worktree, discard, and archive actions
15
+ - update `render-pr-brief.sh` and the PR brief template with review range and merged-result verification fields
16
+
3
17
  ## v1.6.2 - 2026-04-27
4
18
 
5
19
  - require closeout handoff documents to resolve the runtime output policy before writing PR briefs, release notes, resume indexes, or status handoffs
@@ -25,6 +25,7 @@
25
25
  1. 运行 `scripts/verify-act-gate.sh --dir <requirement-dir>`
26
26
  2. 确认 `review/report-card.json` 是 `pass`,且没有未解释的 gaps / reroute
27
27
  3. 确认 `planning/tasks.md` 不再有未完成项
28
+ 4. 确认 `review.freshness` 新鲜、`runtime.failureOwnership` 无未解释失败、`qa.coverageAudit` / `qa.browserEvidence` 有证据或明确 skip
28
29
 
29
30
  如果 gate 没闭合,直接回 `cc-check` 或 `cc-do`,不要在 `cc-act` 自我安慰。
30
31
 
@@ -70,6 +71,7 @@ Ship 必须属于这 4 种模式之一:
70
71
 
71
72
  - `cc-act` 可以做清理和收尾修复
72
73
  - 但只要现实被改写,就必须重新证明
74
+ - verification 每次进 `cc-act` 都要重新跑;只有 push、PR 更新、文档生成这类动作可以因幂等状态跳过
73
75
 
74
76
  ## Phase 2.5: Ship Hygiene
75
77
 
@@ -80,6 +82,7 @@ Ship 必须属于这 4 种模式之一:
80
82
  3. 检查提交边界,按逻辑单元拆分,保证提交顺序不引用未来代码。
81
83
  4. 如果有 WIP commit,只能用非破坏性 rebase / fixup 处理,不允许盲目 soft reset。
82
84
  5. push 前比较 local / remote HEAD;PR 前检查是否已有打开 PR / MR。
85
+ 6. 生成 readiness dashboard:review freshness、review quality、QA coverage、browser QA、failure ownership、documentation release、PR body accuracy。
83
86
 
84
87
  ## Phase 3: Build Delivery Pack
85
88
 
@@ -104,6 +107,18 @@ Ship 必须属于这 4 种模式之一:
104
107
  1. `scripts/sync-act-docs.sh --dir <requirement-dir>`
105
108
  2. `scripts/render-pr-brief.sh --dir <requirement-dir>`
106
109
 
110
+ `pr-brief.md` 还必须带上 `cc-check` 的 review range:
111
+
112
+ - reviewed base SHA
113
+ - reviewed head SHA
114
+ - review packet path / summary
115
+ - finding triage summary
116
+ - QA / claim evidence summary
117
+ - readiness dashboard
118
+ - PR body accuracy check
119
+
120
+ 缺这些字段时,可以生成 local handoff,但不能声称 PR body 已经可 review。
121
+
107
122
  ## Phase 4: Sync Docs
108
123
 
109
124
  文档同步不是装饰动作,而是 ship 的一部分。
@@ -125,7 +140,8 @@ Ship 必须属于这 4 种模式之一:
125
140
  - 按 `references/git-commit-guidelines.md` 完成提交
126
141
  - 推送当前分支
127
142
  - 用 `gh pr create` 创建 PR / MR
128
- - PR body 以 `pr-brief.md` 为真相源,并包含 Summary、Test Coverage、Pre-Landing Review、Scope Drift、Plan Completion、Verification Results、Documentation、Test plan
143
+ - PR body 以 `pr-brief.md` 为真相源,并包含 Summary、Test Coverage、Pre-Landing Review、Readiness Dashboard、Scope Drift、Plan Completion、Verification Results、Documentation、Test plan
144
+ - 创建前检查 PR body 是否来自当前 report-card 和当前 diff,不继承旧 body
129
145
 
130
146
  ### `update-pr`
131
147
 
@@ -133,6 +149,7 @@ Ship 必须属于这 4 种模式之一:
133
149
  - 不重新造一个 PR
134
150
  - 刷新已有 PR / MR body
135
151
  - 确保 body 由本次最新 `cc-check` 结果与 doc sync 状态重建,不沿用旧 body
152
+ - PR body 与当前 commits / diff 不一致时,必须先更新 body,再继续交付判断
136
153
 
137
154
  ### `local-handoff`
138
155
 
@@ -142,8 +159,15 @@ Ship 必须属于这 4 种模式之一:
142
159
  ### `post-merge-closeout`
143
160
 
144
161
  - 不做 feature branch PR 动作
162
+ - 在 merged result 上重跑必要 gate,并记录命令、exit status、关键观察
145
163
  - 完成 release note、文档同步、backlog/roadmap 回写、归档
146
164
 
165
+ ### destructive cleanup
166
+
167
+ - 删除 branch、worktree、未合并提交、requirement archive 前,先列出对象
168
+ - 丢弃未合并工作必须要求用户显式确认
169
+ - 无法确认时保留现场,切到 `local-handoff`
170
+
147
171
  如果 `gh` 不可用、push 失败、远端不可达,就不要硬凹 `create-pr` / `update-pr`。切到 `local-handoff`,把阻塞和下一步写清楚。
148
172
 
149
173
  ## Phase 6: Write Back The Learning
@@ -176,6 +200,7 @@ Ship 必须属于这 4 种模式之一:
176
200
  3. reviewer / 接手者 还需不需要追问“所以我现在该看哪个文件”?
177
201
  4. `cc-simplify`、单测、e2e、commit/push 的结果是不是都能追溯?
178
202
  5. PR body / release note / handoff / changelog 说的是不是同一套现实?
203
+ 6. readiness dashboard 有没有 blocker 或 stale warning?
179
204
 
180
205
  如果第 1 或第 3 题答案不是“能”,说明 `cc-act` 仍然太重或太糊。
181
206
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: cc-act
3
- version: 1.6.2
3
+ version: 1.6.4
4
4
  description: 'Use when verified work must be shipped or handed off with a clear landing path: run simplify and required tests, create or update a PR, prepare a local handoff, close out merged work, sync docs, write release notes, and fold follow-ups back into backlog or roadmap.'
5
5
  triggers:
6
6
  - 准备提 PR
@@ -41,7 +41,7 @@ entry_gate:
41
41
  - If simplify, tests, or act changes code or verification scope, return to cc-check immediately.
42
42
  exit_criteria:
43
43
  - The ship mode is explicit, delivery materials match that mode, and the next maintainer has one clear entry point.
44
- - Docs, PR text, release notes, handoff artifacts, and test evidence reflect the same proven facts.
44
+ - Docs, PR text, release notes, handoff artifacts, review range, readiness dashboard, PR body accuracy check, and test evidence reflect the same proven facts.
45
45
  - Follow-up items are written back to roadmap/backlog instead of lingering in chat memory.
46
46
  reroutes:
47
47
  - when: Verification is stale, incomplete, or changed during act.
@@ -126,7 +126,8 @@ tool_budget:
126
126
  2. 再读 `planning/design.md` 或 `planning/analysis.md`、`planning/tasks.md`、`planning/task-manifest.json`、`change-meta.json`、相关 capability spec;如果已有 `handoff/resume-index.md`,一并读取,确认这次到底完成了什么。
127
127
  3. 运行 `scripts/verify-act-gate.sh --dir <requirement-dir>`,确认 gate 真的闭合。
128
128
  4. 运行 `scripts/detect-ship-target.sh`,识别当前分支、base branch、PR 状态与推荐 ship 路径。
129
- 5. 如果在 `cc-act` 期间因为 `cc-simplify`、单测、e2e、review 修复而改了代码,必须回 `cc-check`,不能带着旧证明继续 ship
129
+ 5. 检查 `review.freshness`、`runtime.failureOwnership`、`qa.coverageAudit`、`qa.browserEvidence`,确认 readiness dashboard 没有 blocker
130
+ 6. 如果在 `cc-act` 期间因为 `cc-simplify`、单测、e2e、review 修复而改了代码,必须回 `cc-check`,不能带着旧证明继续 ship。
130
131
 
131
132
  ## Ship Modes
132
133
 
@@ -146,7 +147,7 @@ tool_budget:
146
147
  - 但要把 handoff 与下一步写清楚
147
148
  4. `post-merge-closeout`
148
149
  - 当前已在 base branch,或 requirement 已完成合并
149
- - 重点是 release note、doc sync、backlog writeback、归档
150
+ - 重点是 merged-result verification、release note、doc sync、backlog writeback、归档
150
151
 
151
152
  不要发明第五种模糊模式。
152
153
 
@@ -207,9 +208,34 @@ tool_budget:
207
208
  2. Scope completion:PR 简报必须包含 `cc-check` 的 plan completion、scope drift、review finding、验证结果摘要。
208
209
  3. Version and changelog:如果项目有 `VERSION`、`package.json`、`CHANGELOG.md`,先判断是否已 bump / 是否漂移;不要重复 bump,也不要覆盖 changelog。
209
210
  4. Bisectable commits:提交按逻辑单元拆分,顺序保证每个 commit 独立可理解、尽量可验证;小于 50 行且少于 4 文件可单 commit。
210
- 5. Fresh final verification:如果 `cc-act` 中的 review fixdoc sync、version sync 改了代码或运行时输入,重新回 `cc-check`;纯文档/PR body 变化记录即可。
211
+ 5. Fresh final verification:每次进入 `cc-act` 都要重跑 entry gatesimplify、单测、e2e 或记录 skip;只有 push、PR 更新、doc 生成这类动作可以幂等跳过。以前跑过不等于现在仍然可信。
211
212
  6. Push idempotency:push 前比较 local/remote HEAD;已同步就不重复 push,不可用就切 `local-handoff`。
212
213
  7. PR idempotency:已有打开的 PR / MR 只更新 body,不重复创建。
214
+ 8. Review range:PR brief / PR body 必须写清 `cc-check` 审过的 base/head SHA、review packet、finding triage 摘要。
215
+ 9. Post-integration verification:本地合并或 post-merge closeout 后,必须在 merged result 上跑必要 gate;不能只继承合并前绿色。
216
+
217
+ ## Readiness Dashboard
218
+
219
+ PR / handoff 之前必须把 readiness 压成一屏事实:
220
+
221
+ 1. Review freshness:`review.freshness.status` 必须是 `fresh` 或 `not-applicable`。
222
+ 2. Review quality:记录 `review.qualityScore`、specialist facet 覆盖、finding triage 摘要。
223
+ 3. QA coverage:记录 `qa.coverageAudit` 的 coverage、gaps、e2e/eval requirement。
224
+ 4. Browser QA:UI / 用户路径变更必须有 `qa.browserEvidence`,否则要有 skip reason。
225
+ 5. Failure ownership:`runtime.failureOwnership` 不能有未解释的 `in-branch` 或 `ambiguous` failure。
226
+ 6. Documentation release:README / CLAUDE / architecture / handoff / changelog 的同步状态必须可审计。
227
+ 7. PR body accuracy:PR body 必须从当前 `pr-brief.md`、当前 diff、当前 report-card 重建;已有 PR body 只能被刷新,不能被继承。
228
+
229
+ readiness dashboard 有 blocker 时,不能创建或更新 PR,只能 reroute 到 `cc-check` / `cc-do` 或生成 local handoff。
230
+
231
+ ## Integration Safety
232
+
233
+ `cc-act` 可以清理交付路径,但不能悄悄做破坏性动作:
234
+
235
+ 1. 删除 feature branch、删除 worktree、丢弃提交、归档 requirement 前,必须列出受影响对象。
236
+ 2. 丢弃未合并工作必须要求用户显式确认;没有确认时只能转 `local-handoff`。
237
+ 3. branch cleanup 只发生在 merge / PR / discard 语义已经清楚之后。
238
+ 4. `post-merge-closeout` 必须记录 merged-result verification:命令、exit status、关键观察、失败时 reroute。
213
239
 
214
240
  ## Documentation Release
215
241
 
@@ -245,11 +271,12 @@ tool_budget:
245
271
  - `local-handoff`:不假装已经发出,只生成可接手材料
246
272
  - `post-merge-closeout`:跳过 PR,完成发布与闭环回写
247
273
  11. 处理 PR / MR body:从当前 `pr-brief.md`、最新验证、review、doc sync、TODO/backlog 结果重新渲染,不复用旧 body。
248
- 12. 回写 `devflow/roadmap/backlog.md` / `devflow/roadmap/roadmap.md`:
274
+ 12. `handoff/pr-brief.md` 写入 readiness dashboard 与 PR body accuracy check;已有 PR body 与当前事实不一致时先刷新再继续。
275
+ 13. 回写 `devflow/roadmap/backlog.md` / `devflow/roadmap/roadmap.md`:
249
276
  - 新发现的 follow-up
250
277
  - 被推迟但必须保留的事项
251
278
  - 因本次结果而改变优先级的事项
252
- 13. 如果 requirement 真正闭环,更新状态摘要并归档;否则把下一位接手者的入口写清楚。
279
+ 14. 如果 requirement 真正闭环,更新状态摘要并归档;否则把下一位接手者的入口写清楚。
253
280
 
254
281
  ## Output
255
282
 
@@ -261,6 +288,7 @@ tool_budget:
261
288
  - 单测 / e2e 的通过证据,或明确记录的 skip / blocker
262
289
  - 必要时创建或更新的 PR / MR
263
290
  - PR / MR body 中的 Summary、Test Coverage、Pre-Landing Review、Scope Drift、Plan Completion、Verification Results、Documentation、Test plan
291
+ - readiness dashboard 和 PR body accuracy check
264
292
 
265
293
  ## Good Output
266
294
 
@@ -300,6 +328,7 @@ tool_budget:
300
328
  10. `create-pr` / `update-pr` 模式默认要求提交历史符合 `references/git-commit-guidelines.md`,并完成正确的 push、PR 创建或更新动作。
301
329
  11. CHANGELOG 只能基于当前 diff / commit history / release truth 更新,不允许覆盖既有历史条目。
302
330
  12. PR / MR body 每次都从当前事实重建,不沿用旧 body 或旧测试输出。
331
+ 13. Verification 每次执行 `cc-act` 都必须重新运行;只有已完成且可证明幂等的动作可以跳过。
303
332
 
304
333
  ## Exit Criteria
305
334
 
@@ -24,6 +24,25 @@
24
24
  - Base branch:
25
25
  - PR / MR:
26
26
 
27
+ ## Review Range
28
+
29
+ - Reviewed base SHA:
30
+ - Reviewed head SHA:
31
+ - Review packet:
32
+ - Finding triage:
33
+ - QA / claim evidence:
34
+
35
+ ## Readiness Dashboard
36
+
37
+ - Review freshness:
38
+ - Review quality:
39
+ - Specialist review facets:
40
+ - QA coverage:
41
+ - Browser QA:
42
+ - Failure ownership:
43
+ - Documentation release:
44
+ - PR body accuracy:
45
+
27
46
  ## Summary
28
47
 
29
48
  -
@@ -36,6 +55,7 @@
36
55
 
37
56
  - `review/report-card.json` verdict:
38
57
  - Fresh evidence:
58
+ - Merged-result verification:
39
59
 
40
60
  ## Documentation Sync
41
61
 
@@ -8,6 +8,8 @@
8
8
  4. `planning/tasks.md` 不能还有未完成项
9
9
  5. 交付材料必须只总结现实,不补编故事
10
10
  6. 如果文件结构变了,就同步对应目录的 `CLAUDE.md`
11
+ 7. PR / handoff 必须记录 `cc-check` 审过的 base/head SHA、review packet、finding triage 摘要
12
+ 8. readiness dashboard 必须说明 review freshness、QA coverage、browser evidence、failure ownership、documentation release、PR body accuracy
11
13
 
12
14
  ## Ship Decision Contract
13
15
 
@@ -29,6 +31,10 @@
29
31
  5. VERSION / package / changelog 漂移必须先分类处理,不能重复 bump 或覆盖发布历史
30
32
  6. PR / MR body 必须从当前事实重建,不能沿用旧验证输出
31
33
  7. push / PR 创建必须具备幂等检查:已同步则跳过,已存在 PR 则更新
34
+ 8. 本地合并或 post-merge closeout 后必须在 merged result 上重跑必要 gate
35
+ 9. 删除 branch、worktree、未合并提交、归档 requirement 前必须列出对象;丢弃未合并工作需要显式确认
36
+ 10. verification 每次进入 `cc-act` 都必须重新跑;只有 push、PR 更新、文档生成等动作可以因为幂等状态跳过
37
+ 11. PR body accuracy 必须对照当前 report-card、当前 diff、当前 commits;旧 body 不能作为证据源
32
38
 
33
39
  ## Memory Consolidation
34
40
 
@@ -45,5 +51,7 @@
45
51
  - reviewer 能接手
46
52
  - maintainer 知道怎么验证
47
53
  - PR / handoff / release 材料反映同一套事实
54
+ - readiness dashboard 没有 blocker,PR body accuracy 已检查或明确阻塞
55
+ - post-merge closeout 反映 merged result 的验证事实,而不是只反映合并前事实
48
56
  - 下一轮计划入口更清楚
49
57
  - 文档入口可发现,changelog 不丢历史,TODO / backlog 只记录有证据的事项
@@ -234,7 +234,12 @@ req_act_collect_evidence() {
234
234
  local out_file="$2"
235
235
 
236
236
  : > "$out_file"
237
- jq -r '(.evidence // [])[]?' "$report_card" 2>/dev/null | sed '/^$/d' > "$out_file" || true
237
+ jq -r '
238
+ (.evidence // [])[]?,
239
+ ((.claimEvidence // [])[]? | "- " + (.claim // "claim") + ": " + (.status // "unknown") + " via " + (.commandOrArtifact // "artifact") + " - " + (.keyObservation // "")),
240
+ (if .qa.coverageAudit then "- qa.coverage: " + (.qa.coverageAudit.status // "unknown") + ", gaps=" + (((.qa.coverageAudit.gaps // []) | length) | tostring) else empty end),
241
+ (if .qa.browserEvidence then "- qa.browser: " + (.qa.browserEvidence.status // "unknown") + ", mode=" + (.qa.browserEvidence.mode // "unknown") else empty end)
242
+ ' "$report_card" 2>/dev/null | sed '/^$/d' > "$out_file" || true
238
243
  req_act_dedup_file "$out_file"
239
244
  }
240
245
 
@@ -65,6 +65,31 @@ report_verdict="$(req_act_report_verdict "$report_card")"
65
65
  output_language="$(req_act_output_language "$report_card")"
66
66
  design_goal="$(req_act_design_goal "$design_file")"
67
67
  main_risk="$(req_act_main_risk "$design_file")"
68
+ review_base_sha="$(jq -r '[.review.taskReviews.reviewPacket.baseSha?, .review.diffReview.reviewPacket.baseSha?] | map(select(. != null and . != "")) | first // "not recorded"' "$report_card")"
69
+ review_head_sha="$(jq -r '[.review.taskReviews.reviewPacket.headSha?, .review.diffReview.reviewPacket.headSha?] | map(select(. != null and . != "")) | first // "not recorded"' "$report_card")"
70
+ review_packet_summary="$(jq -r '
71
+ [
72
+ .review.taskReviews.reviewPacket.requirements?,
73
+ .review.diffReview.reviewPacket.requirements?
74
+ ]
75
+ | map(select(. != null and . != ""))
76
+ | unique
77
+ | if length == 0 then "not recorded" else join("; ") end
78
+ ' "$report_card")"
79
+ finding_triage_summary="$(jq -r '
80
+ [
81
+ (.review.taskReviews.findings? // []),
82
+ (.review.diffReview.findings? // []),
83
+ (.review.findings? // [])
84
+ ]
85
+ | flatten
86
+ | map(.triageStatus? // .status? // "untriaged")
87
+ | if length == 0 then "no findings" else group_by(.) | map("\(.[0])=\(length)") | join(", ") end
88
+ ' "$report_card")"
89
+ qa_claim_summary="$(jq -r '
90
+ "qa=\(.qa.status? // "not recorded"), claims=" +
91
+ (((.claimEvidence? // []) | map((.claim // "unknown") + ":" + (.status // "unknown")) | join(", ")) // "not recorded")
92
+ ' "$report_card")"
68
93
 
69
94
  tmp_changed="$(mktemp)"
70
95
  tmp_verify="$(mktemp)"
@@ -95,6 +120,56 @@ if [[ -f "$doc_sync_report" ]]; then
95
120
  fi
96
121
  fi
97
122
 
123
+ review_freshness_summary="$(jq -r '
124
+ .review.freshness as $fresh |
125
+ if $fresh == null then
126
+ "not recorded"
127
+ else
128
+ "status=\($fresh.status // "unknown"), reviewed=\($fresh.reviewedCommit // "not recorded"), current=\($fresh.currentCommit // "not recorded"), commitsSinceReview=\($fresh.commitsSinceReview // "unknown")" +
129
+ (if (($fresh.staleReason // "") != "") then ", reason=\($fresh.staleReason)" else "" end)
130
+ end
131
+ ' "$report_card")"
132
+ review_quality_summary="$(jq -r '
133
+ "qualityScore=\(.review.qualityScore // "not recorded")"
134
+ ' "$report_card")"
135
+ specialist_review_summary="$(jq -r '
136
+ (.review.specialistReviews? // [])
137
+ | if length == 0 then
138
+ "no specialist facets recorded"
139
+ else
140
+ map((.name // "unknown") + ":" + (.status // "unknown")) | join(", ")
141
+ end
142
+ ' "$report_card")"
143
+ qa_coverage_summary="$(jq -r '
144
+ .qa.coverageAudit as $coverage |
145
+ if $coverage == null then
146
+ "not recorded"
147
+ else
148
+ "status=\($coverage.status // "unknown"), coverage=\($coverage.coveragePct // "n/a"), gaps=\((($coverage.gaps // []) | length)), e2eRequired=\($coverage.e2eRequired // false), evalRequired=\($coverage.evalRequired // false)"
149
+ end
150
+ ' "$report_card")"
151
+ browser_qa_summary="$(jq -r '
152
+ .qa.browserEvidence as $browser |
153
+ if $browser == null then
154
+ "not recorded"
155
+ else
156
+ "status=\($browser.status // "unknown"), mode=\($browser.mode // "unknown"), routes=\((($browser.affectedRoutes // []) | length)), issues=\((($browser.issues // []) | length)), consoleErrors=\((($browser.consoleErrors // []) | length))" +
157
+ (if (($browser.skipReason // "") != "") then ", skip=\($browser.skipReason)" else "" end)
158
+ end
159
+ ' "$report_card")"
160
+ failure_ownership_summary="$(jq -r '
161
+ (.runtime.failureOwnership? // [])
162
+ | if length == 0 then
163
+ "no open failures recorded"
164
+ else
165
+ group_by(.classification // "unknown")
166
+ | map("\(.[0].classification // "unknown")=\(length)")
167
+ | join(", ")
168
+ end
169
+ ' "$report_card")"
170
+ documentation_release_summary="CLAUDE=${claude_status}; README=${readme_status}"
171
+ pr_body_accuracy_summary="body must be regenerated from this pr-brief, current report-card, and current diff before PR create/update"
172
+
98
173
  {
99
174
  echo "# PR Brief"
100
175
  echo
@@ -120,6 +195,25 @@ fi
120
195
  echo "- PR / MR: none"
121
196
  fi
122
197
  echo
198
+ echo "## Review Range"
199
+ echo
200
+ echo "- Reviewed base SHA: $review_base_sha"
201
+ echo "- Reviewed head SHA: $review_head_sha"
202
+ echo "- Review packet: $review_packet_summary"
203
+ echo "- Finding triage: $finding_triage_summary"
204
+ echo "- QA / claim evidence: $qa_claim_summary"
205
+ echo
206
+ echo "## Readiness Dashboard"
207
+ echo
208
+ echo "- Review freshness: $review_freshness_summary"
209
+ echo "- Review quality: $review_quality_summary"
210
+ echo "- Specialist review facets: $specialist_review_summary"
211
+ echo "- QA coverage: $qa_coverage_summary"
212
+ echo "- Browser QA: $browser_qa_summary"
213
+ echo "- Failure ownership: $failure_ownership_summary"
214
+ echo "- Documentation release: $documentation_release_summary"
215
+ echo "- PR body accuracy: $pr_body_accuracy_summary"
216
+ echo
123
217
  echo "## Summary"
124
218
  echo
125
219
  if [[ -n "$report_summary" ]]; then
@@ -145,6 +239,11 @@ fi
145
239
  echo "## Verification Evidence"
146
240
  echo
147
241
  echo "- \`report-card.json\` verdict: $report_verdict"
242
+ if [[ "$ship_mode" == "post-merge-closeout" ]]; then
243
+ echo "- Merged-result verification: required before closeout; record command, exit status, and key observation"
244
+ else
245
+ echo "- Merged-result verification: not applicable before merge"
246
+ fi
148
247
  if [[ -s "$tmp_evidence" ]]; then
149
248
  while IFS= read -r line; do
150
249
  echo "- $line"
@@ -37,8 +37,16 @@ tasks_file="$(req_act_tasks_path "$CHANGE_DIR")"
37
37
  verdict="$(jq -r '.verdict // "unknown"' "$report_card" 2>/dev/null || echo unknown)"
38
38
  reroute="$(jq -r '.reroute // "unknown"' "$report_card" 2>/dev/null || echo unknown)"
39
39
  spec_sync_ready="$(jq -r '.specSyncReady // false' "$report_card" 2>/dev/null || echo false)"
40
- evidence_count="$(jq -r '(.evidence // []) | length' "$report_card" 2>/dev/null || echo 0)"
40
+ evidence_count="$(jq -r '((.evidence // []) + (.claimEvidence // []) + (.quickGates // []) + (.strictGates // [])) | length' "$report_card" 2>/dev/null || echo 0)"
41
41
  gap_count="$(jq -r '(.gaps // []) | length' "$report_card" 2>/dev/null || echo 0)"
42
+ review_freshness="$(jq -r '.review.freshness.status // "unknown"' "$report_card" 2>/dev/null || echo unknown)"
43
+ failure_ownership_open="$(jq -r '
44
+ (.runtime.failureOwnership? // [])
45
+ | map(select(((.classification? // "") | IN("in-branch", "ambiguous")) and ((.status? // "open") | IN("open", "pending"))))
46
+ | length
47
+ ' "$report_card" 2>/dev/null || echo 0)"
48
+ coverage_status="$(jq -r '.qa.coverageAudit.status // "unknown"' "$report_card" 2>/dev/null || echo unknown)"
49
+ browser_status="$(jq -r '.qa.browserEvidence.status // "unknown"' "$report_card" 2>/dev/null || echo unknown)"
42
50
 
43
51
  remaining_tasks="0"
44
52
  if [[ -f "$tasks_file" ]]; then
@@ -50,6 +58,10 @@ fi
50
58
  [[ "$spec_sync_ready" == "true" ]] || { echo "Gate open: spec_sync_ready=$spec_sync_ready" >&2; exit 1; }
51
59
  [[ "$evidence_count" -gt 0 ]] || { echo "Gate open: evidence is empty" >&2; exit 1; }
52
60
  [[ "$gap_count" -eq 0 ]] || { echo "Gate open: gaps=$gap_count" >&2; exit 1; }
61
+ [[ "$review_freshness" == "fresh" || "$review_freshness" == "not-applicable" ]] || { echo "Gate open: review_freshness=$review_freshness" >&2; exit 1; }
62
+ [[ "$failure_ownership_open" -eq 0 ]] || { echo "Gate open: failure_ownership_open=$failure_ownership_open" >&2; exit 1; }
63
+ [[ "$coverage_status" != "blocked" && "$coverage_status" != "fail" && "$coverage_status" != "pending" ]] || { echo "Gate open: coverage_status=$coverage_status" >&2; exit 1; }
64
+ [[ "$browser_status" != "blocked" && "$browser_status" != "fail" && "$browser_status" != "pending" ]] || { echo "Gate open: browser_status=$browser_status" >&2; exit 1; }
53
65
  [[ "$remaining_tasks" -eq 0 ]] || { echo "Gate open: remaining_tasks=$remaining_tasks" >&2; exit 1; }
54
66
 
55
67
  cat <<EOF
@@ -59,5 +71,9 @@ REROUTE=$reroute
59
71
  SPEC_SYNC_READY=$spec_sync_ready
60
72
  EVIDENCE_COUNT=$evidence_count
61
73
  GAP_COUNT=$gap_count
74
+ REVIEW_FRESHNESS=$review_freshness
75
+ FAILURE_OWNERSHIP_OPEN=$failure_ownership_open
76
+ COVERAGE_STATUS=$coverage_status
77
+ BROWSER_STATUS=$browser_status
62
78
  REMAINING_TASKS=$remaining_tasks
63
79
  EOF
@@ -1,5 +1,19 @@
1
1
  # CC-Check Skill Changelog
2
2
 
3
+ ## v1.8.4 - 2026-04-28
4
+
5
+ - add review freshness, quality score, specialist review facets, and finding confidence fingerprints so stale or noisy review evidence cannot masquerade as current proof
6
+ - add QA coverage audit and browser evidence fields for user-flow, route, screenshot, console, and skip-reason proof
7
+ - add runtime failure ownership so failing commands are classified as in-branch, pre-existing, environment, or ambiguous before verdict selection
8
+ - update the report-card template, renderer, and gate validation for the richer review and QA evidence shape
9
+
10
+ ## v1.8.3 - 2026-04-28
11
+
12
+ - add native claim evidence matrix guidance so each completion claim maps to command or artifact proof
13
+ - add QA regression and test-quality review fields for red/green proof, mock boundaries, and test-only API smells
14
+ - require review packets and finding triage so review results can be audited without chat memory
15
+ - update report-card template, renderer, and gate validation for optional `claimEvidence` and `qa` fields
16
+
3
17
  ## v1.8.2 - 2026-04-27
4
18
 
5
19
  - require verification reports to resolve the runtime output policy before writing human-readable verdicts or summaries
@@ -40,6 +40,11 @@ NO PASS WITHOUT FRESH EVIDENCE
40
40
  - runtime gate
41
41
  - task review proof
42
42
  - requirement diff review
43
+ - claim evidence matrix
44
+ - QA regression / test-quality proof
45
+ - QA coverage and browser evidence
46
+ - review freshness and finding confidence
47
+ - failure ownership
43
48
  - spec sync readiness
44
49
  4. **Freeze Verdict**
45
50
  - 只允许 `pass` / `fail` / `blocked`
@@ -54,13 +59,34 @@ NO PASS WITHOUT FRESH EVIDENCE
54
59
  3. 读取真实输出和退出码
55
60
  4. 把证据写进 `report-card.json`
56
61
  5. 把任务级 review 与需求级 diff review 分开写清楚
62
+ 6. 把每个成功声明映射到 `claimEvidence[]`
63
+ 7. 行为变更必须补 `qa` 证据或例外理由
64
+ 8. 失败输出必须写入 `runtime.failureOwnership[]`
57
65
 
58
66
  ## Verification Layers
59
67
 
60
68
  1. Runtime reality
61
69
  2. Task review proof
62
70
  3. Requirement diff truth
63
- 4. Spec alignment and sync readiness
71
+ 4. Claim evidence matrix
72
+ 5. QA regression and test quality
73
+ 6. QA coverage and browser evidence
74
+ 7. Review freshness and confidence calibration
75
+ 8. Failure ownership
76
+ 9. Spec alignment and sync readiness
77
+
78
+ ## Claim Evidence Matrix
79
+
80
+ 每个“通过”声明都要回答:这条声明由哪条命令或 artifact 证明?
81
+
82
+ - `tests-pass`:本轮 test command、exit 0、0 failures
83
+ - `lint-clean` / `typecheck-clean` / `build-succeeds`:对应 gate 的本轮输出
84
+ - `bug-fixed`:原始症状或回归测试通过
85
+ - `regression-test-works`:red -> green 证据,而不是只绿一次
86
+ - `requirements-met`:逐项 plan / manifest checklist
87
+ - `agent-completed`:VCS diff 或 artifact 证明实际变化
88
+
89
+ 缺少必要 claim 的证据时,verdict 至少是 `blocked`。不要把没有证据的 claim 写进 summary。
64
90
 
65
91
  ## Requirement Diff Review
66
92
 
@@ -71,9 +97,49 @@ NO PASS WITHOUT FRESH EVIDENCE
71
97
  3. `scope drift`:识别多做、少做、做偏。
72
98
  4. `critical pass`:检查数据安全、并发、shell、LLM trust boundary、枚举覆盖、静默失败、文档漂移。
73
99
  5. `adversarial synthesis`:合并外部 review / codex / subagent /人工 finding,去重并标置信度。
100
+ 6. `specialist facets`:按风险记录 testing / security / performance / api-contract / data-migration / design 等审查面;没有覆盖必须写 skip reason。
101
+ 7. `freshness`:确认 review 对应当前 head;review 后新增 commit 时不能继续拿旧审查支撑 `pass`。
74
102
 
75
103
  这些结论进入 `review.diffReview`,不能只写在口头总结里。
76
104
 
105
+ 每层 review 都要带 `reviewPacket`:`baseSha`、`headSha`、`requirements`、`implemented`、`reviewerContext`。缺少审查范围时,review 不能支撑 `pass`。
106
+
107
+ review 还要带 `freshness`:`status`、`reviewedCommit`、`currentCommit`、`commitsSinceReview`、`staleReason`。`status=stale` 或缺失 freshness 时,`pass` 不成立。
108
+
109
+ 每条 finding 都要带 `triageStatus`:
110
+
111
+ - `accepted-fixed`
112
+ - `rejected-with-evidence`
113
+ - `deferred-minor`
114
+ - `clarification-needed`
115
+
116
+ `critical` / `important` finding 未闭环或仍是 `clarification-needed`,不能进入 `cc-act`。
117
+
118
+ 每条 finding 还要带 `confidenceScore`、`fingerprint`、`displayTier`、`suppressionReason`。低置信 finding 只能作为 warning 或 gap,不能伪装成 blocking fact。
119
+
120
+ ## QA Test Quality
121
+
122
+ 行为变化、bugfix、边界条件、用户可见流程必须补 `qa`:
123
+
124
+ - `regressionProof`:red command、red failure reason、green command、是否恢复最终状态
125
+ - `testQuality`:是否验证真实行为、mock 边界、是否存在 test-only production API
126
+ - `tddException`:纯配置、生成文件、throwaway prototype 等例外和替代验证
127
+ - `coverageAudit`:覆盖率、codepath / user-flow map、缺口、是否需要 e2e / eval、测试质量星级
128
+ - `browserEvidence`:UI / 用户路径变更的 affected routes、截图、console、health score、issues,或明确 skip reason
129
+
130
+ 测试只绿过一次,不能证明 regression test 有效;断言 mock 本身,不能证明真实行为。
131
+
132
+ ## Failure Ownership
133
+
134
+ 失败要先归属,再下结论:
135
+
136
+ - `in-branch`:当前分支引入,默认回 `cc-do`
137
+ - `pre-existing`:base branch 也存在,必须有复验证据
138
+ - `environment`:依赖、权限、服务、密钥、平台缺失,通常是 `blocked`
139
+ - `ambiguous`:无法证明归属,默认不能 `pass`
140
+
141
+ 不要把环境红灯、基线红灯、本分支红灯混成一句“测试失败”。
142
+
77
143
  ## Verdict
78
144
 
79
145
  只允许 3 种结论:
@@ -98,12 +164,46 @@ NO PASS WITHOUT FRESH EVIDENCE
98
164
  "verdict": "pass",
99
165
  "overall": "pass",
100
166
  "summary": "one-line reality",
167
+ "claimEvidence": [],
168
+ "runtime": {
169
+ "status": "pass",
170
+ "failureOwnership": []
171
+ },
172
+ "qa": {
173
+ "status": "pass",
174
+ "regressionProof": [],
175
+ "testQuality": [],
176
+ "coverageAudit": {
177
+ "status": "pass",
178
+ "coveragePct": 80,
179
+ "pathMap": [],
180
+ "gaps": [],
181
+ "testsAdded": [],
182
+ "e2eRequired": false,
183
+ "evalRequired": false,
184
+ "qualityStars": "★★"
185
+ },
186
+ "browserEvidence": {
187
+ "status": "skipped",
188
+ "mode": "not-applicable",
189
+ "affectedRoutes": [],
190
+ "screenshots": [],
191
+ "consoleErrors": [],
192
+ "healthScore": null,
193
+ "issues": [],
194
+ "skipReason": "not a UI or user-path change"
195
+ },
196
+ "tddException": null
197
+ },
101
198
  "quickGates": [],
102
199
  "strictGates": [],
103
200
  "review": {
104
201
  "status": "pass",
105
202
  "summary": "",
106
203
  "details": "",
204
+ "freshness": { "status": "fresh", "reviewedCommit": "example-head", "currentCommit": "example-head", "commitsSinceReview": 0, "staleReason": "" },
205
+ "qualityScore": 9,
206
+ "specialistReviews": [],
107
207
  "taskReviews": { "status": "pass", "required": true, "summary": "", "reviewers": [], "findings": [] },
108
208
  "diffReview": { "status": "skipped", "required": false, "summary": "", "reviewers": [], "findings": [] },
109
209
  "findings": []