cc-devflow 4.5.11 → 4.5.12
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.
- package/.claude/skills/cc-act/CHANGELOG.md +18 -0
- package/.claude/skills/cc-act/PLAYBOOK.md +17 -269
- package/.claude/skills/cc-act/SKILL.md +38 -425
- package/.claude/skills/cc-act/assets/PROJECT_POSTMORTEM_INDEX_TEMPLATE.md +2 -13
- package/.claude/skills/cc-act/assets/PROJECT_POSTMORTEM_TEMPLATE.md +1 -9
- package/.claude/skills/cc-act/assets/PR_BRIEF_TEMPLATE.md +21 -177
- package/.claude/skills/cc-act/references/closure-contract.md +12 -63
- package/.claude/skills/cc-act/references/git-commit-guidelines.md +5 -5
- package/.claude/skills/cc-act/scripts/cc-act-common.sh +5 -322
- package/.claude/skills/cc-act/scripts/detect-ship-target.sh +11 -2
- package/.claude/skills/cc-act/scripts/inspect-git-index.sh +58 -0
- package/.claude/skills/cc-act/scripts/render-pr-brief.sh +40 -440
- package/.claude/skills/cc-act/scripts/verify-act-gate.sh +10 -50
- package/.claude/skills/cc-check/CHANGELOG.md +18 -0
- package/.claude/skills/cc-check/PLAYBOOK.md +19 -273
- package/.claude/skills/cc-check/SKILL.md +33 -456
- package/.claude/skills/cc-check/references/review-contract.md +12 -147
- package/.claude/skills/cc-dev/CHANGELOG.md +15 -0
- package/.claude/skills/cc-dev/PLAYBOOK.md +1 -1
- package/.claude/skills/cc-dev/SKILL.md +52 -137
- package/.claude/skills/cc-dev/scripts/resolve-cc-devflow.sh +181 -0
- package/.claude/skills/cc-do/CHANGELOG.md +11 -0
- package/.claude/skills/cc-do/PLAYBOOK.md +19 -113
- package/.claude/skills/cc-do/SKILL.md +39 -245
- package/.claude/skills/cc-do/references/execution-recovery.md +15 -109
- package/.claude/skills/cc-do/scripts/cc-do-common.sh +5 -57
- package/.claude/skills/cc-do/scripts/check-task-status.sh +35 -65
- package/.claude/skills/cc-do/scripts/mark-task-complete.sh +9 -46
- package/.claude/skills/cc-do/scripts/select-ready-tasks.sh +29 -97
- package/.claude/skills/cc-investigate/CHANGELOG.md +16 -0
- package/.claude/skills/cc-investigate/PLAYBOOK.md +20 -180
- package/.claude/skills/cc-investigate/SKILL.md +64 -246
- package/.claude/skills/cc-investigate/assets/TASKS_TEMPLATE.md +48 -98
- package/.claude/skills/cc-investigate/references/investigation-contract.md +14 -218
- package/.claude/skills/cc-next/CHANGELOG.md +6 -0
- package/.claude/skills/cc-next/PLAYBOOK.md +12 -8
- package/.claude/skills/cc-next/SKILL.md +34 -140
- package/.claude/skills/cc-plan/CHANGELOG.md +16 -0
- package/.claude/skills/cc-plan/PLAYBOOK.md +22 -161
- package/.claude/skills/cc-plan/SKILL.md +45 -295
- package/.claude/skills/cc-plan/assets/TASKS_TEMPLATE.md +30 -228
- package/.claude/skills/cc-plan/references/planning-contract.md +24 -161
- package/.claude/skills/cc-plan/scripts/next-change-key.sh +8 -44
- package/.claude/skills/cc-plan/scripts/parse-task-dependencies.js +2 -2
- package/.claude/skills/cc-plan/scripts/validate-scope.sh +1 -1
- package/.claude/skills/cc-pr-land/SKILL.md +14 -114
- package/.claude/skills/cc-pr-review/CHANGELOG.md +4 -0
- package/.claude/skills/cc-pr-review/SKILL.md +20 -103
- package/.claude/skills/cc-review/CHANGELOG.md +17 -0
- package/.claude/skills/cc-review/PLAYBOOK.md +13 -86
- package/.claude/skills/cc-review/SKILL.md +53 -241
- package/.claude/skills/cc-review/references/e2e-and-plugin-verification.md +2 -2
- package/.claude/skills/cc-review/references/implementation-review-branch.md +7 -147
- package/.claude/skills/cc-review/references/plan-review-branch.md +5 -147
- package/.claude/skills/cc-review/references/review-methods.md +10 -218
- package/.claude/skills/cc-review/scripts/collect-review-context.sh +4 -63
- package/.claude/skills/cc-roadmap/PLAYBOOK.md +1 -1
- package/.claude/skills/cc-roadmap/SKILL.md +3 -3
- package/.claude/skills/cc-simplify/CHANGELOG.md +7 -0
- package/.claude/skills/cc-simplify/SKILL.md +26 -21
- package/.claude/skills/cc-spec-init/PLAYBOOK.md +12 -48
- package/.claude/skills/cc-spec-init/SKILL.md +29 -132
- package/.claude/skills/cc-spec-init/references/spec-contract.md +8 -17
- package/CHANGELOG.md +13 -0
- package/bin/cc-devflow-cli.js +20 -260
- package/bin/cc-devflow.js +44 -7
- package/docs/commands/README.md +1 -1
- package/docs/commands/README.zh-CN.md +1 -1
- package/docs/examples/README.md +1 -1
- package/docs/examples/START-HERE.md +14 -15
- package/docs/examples/example-bindings.json +11 -11
- package/docs/examples/full-design-blocked/README.md +4 -6
- package/docs/examples/full-design-blocked/changes/REQ-002-bulk-invite-import/{planning/tasks.md → task.md} +20 -15
- package/docs/examples/local-handoff/README.md +8 -11
- package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/handoff/pr-brief.md +31 -0
- package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/{planning/tasks.md → task.md} +18 -13
- package/docs/examples/pdca-loop/README.md +6 -9
- package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/handoff/pr-brief.md +9 -11
- package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/{planning/tasks.md → task.md} +18 -13
- package/docs/examples/scripts/check-example-bindings.sh +11 -62
- package/docs/guides/artifact-contract.md +10 -40
- package/docs/guides/getting-started.md +8 -8
- package/docs/guides/getting-started.zh-CN.md +8 -8
- package/docs/guides/minimize-artifacts.md +16 -130
- package/docs/guides/project-postmortem.md +14 -71
- package/lib/compiler/__tests__/skills-registry.test.js +9 -8
- package/lib/compiler/resource-copier.js +29 -0
- package/lib/skill-runtime/__tests__/archive-change.test.js +2 -2
- package/lib/skill-runtime/__tests__/benchmark-skills.test.js +3 -3
- package/lib/skill-runtime/__tests__/cli-bootstrap.integration.test.js +14 -4
- package/lib/skill-runtime/errors.js +3 -3
- package/lib/skill-runtime/index.js +5 -23
- package/lib/skill-runtime/paths.js +5 -52
- package/lib/skill-runtime/query-registry.js +4 -4
- package/lib/skill-runtime/query.js +89 -201
- package/lib/skill-runtime/store.js +4 -40
- package/lib/skill-runtime/trace.js +2 -2
- package/package.json +2 -5
- package/.claude/skills/cc-act/assets/PROJECT_POSTMORTEM_PRINCIPLES_TEMPLATE.md +0 -29
- package/.claude/skills/cc-act/assets/RELEASE_NOTE_TEMPLATE.md +0 -54
- package/.claude/skills/cc-act/scripts/generate-status-report.sh +0 -92
- package/.claude/skills/cc-act/scripts/sync-act-docs.sh +0 -355
- package/.claude/skills/cc-check/assets/REPORT_CARD_TEMPLATE.json +0 -234
- package/.claude/skills/cc-check/scripts/render-report-card.js +0 -438
- package/.claude/skills/cc-check/scripts/verify-gate.sh +0 -85
- package/.claude/skills/cc-do/scripts/build-task-context.sh +0 -175
- package/.claude/skills/cc-do/scripts/record-review-decision.sh +0 -88
- package/.claude/skills/cc-do/scripts/recover-workflow.sh +0 -82
- package/.claude/skills/cc-do/scripts/run-problem-analysis.sh +0 -70
- package/.claude/skills/cc-do/scripts/verify-task-gates.sh +0 -109
- package/.claude/skills/cc-do/scripts/write-task-checkpoint.sh +0 -92
- package/.claude/skills/cc-investigate/assets/TASK_MANIFEST_TEMPLATE.json +0 -224
- package/.claude/skills/cc-plan/assets/TASK_MANIFEST_TEMPLATE.json +0 -178
- package/.claude/skills/cc-spec-init/assets/CHANGE_META_TEMPLATE.json +0 -28
- package/.claude/skills/cc-spec-init/scripts/validate-spec-links.sh +0 -45
- package/docs/examples/full-design-blocked/changes/REQ-002-bulk-invite-import/planning/design.md +0 -234
- package/docs/examples/full-design-blocked/changes/REQ-002-bulk-invite-import/planning/task-manifest.json +0 -488
- package/docs/examples/full-design-blocked/changes/REQ-002-bulk-invite-import/review/report-card.json +0 -189
- package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/handoff/resume-index.md +0 -39
- package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/handoff/status.md +0 -29
- package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/planning/design.md +0 -123
- package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/planning/task-manifest.json +0 -292
- package/docs/examples/local-handoff/changes/REQ-003-audit-log-export/review/report-card.json +0 -136
- package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/handoff/status.md +0 -29
- package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/planning/design.md +0 -124
- package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/planning/task-manifest.json +0 -292
- package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/review/report-card.json +0 -136
- package/docs/get-shit-done-strategy-audit.md +0 -518
- package/docs/skill-runtime-migration.md +0 -46
- package/lib/skill-runtime/__tests__/approve.test.js +0 -92
- package/lib/skill-runtime/__tests__/autopilot.test.js +0 -253
- package/lib/skill-runtime/__tests__/benchmark-artifacts.test.js +0 -165
- package/lib/skill-runtime/__tests__/delegation.test.js +0 -97
- package/lib/skill-runtime/__tests__/dispatch.test.js +0 -237
- package/lib/skill-runtime/__tests__/intent.test.js +0 -203
- package/lib/skill-runtime/__tests__/lifecycle.test.js +0 -169
- package/lib/skill-runtime/__tests__/planner.tdd.test.js +0 -331
- package/lib/skill-runtime/__tests__/prepare-pr.test.js +0 -126
- package/lib/skill-runtime/__tests__/query.test.js +0 -860
- package/lib/skill-runtime/__tests__/readiness.test.js +0 -53
- package/lib/skill-runtime/__tests__/release.test.js +0 -85
- package/lib/skill-runtime/__tests__/review-check-integration.test.js +0 -148
- package/lib/skill-runtime/__tests__/review-records.test.js +0 -619
- package/lib/skill-runtime/__tests__/runtime.integration.test.js +0 -351
- package/lib/skill-runtime/__tests__/schemas.test.js +0 -337
- package/lib/skill-runtime/__tests__/task-contract-migrate.test.js +0 -137
- package/lib/skill-runtime/__tests__/task-contract.test.js +0 -874
- package/lib/skill-runtime/__tests__/team-state.test.js +0 -51
- package/lib/skill-runtime/__tests__/verify-artifacts.test.js +0 -203
- package/lib/skill-runtime/__tests__/worker-run.test.js +0 -275
- package/lib/skill-runtime/__tests__/worker.test.js +0 -56
- package/lib/skill-runtime/__tests__/workflow-context-legacy-fallback.test.js +0 -31
- package/lib/skill-runtime/__tests__/workflow-context.test.js +0 -98
- package/lib/skill-runtime/artifacts.js +0 -88
- package/lib/skill-runtime/context-index.js +0 -545
- package/lib/skill-runtime/delegation.js +0 -533
- package/lib/skill-runtime/intent.js +0 -309
- package/lib/skill-runtime/lifecycle.js +0 -294
- package/lib/skill-runtime/operations/CLAUDE.md +0 -19
- package/lib/skill-runtime/operations/approve.js +0 -81
- package/lib/skill-runtime/operations/autopilot-core.js +0 -337
- package/lib/skill-runtime/operations/autopilot-execution.js +0 -307
- package/lib/skill-runtime/operations/autopilot-shared.js +0 -48
- package/lib/skill-runtime/operations/autopilot.js +0 -163
- package/lib/skill-runtime/operations/dispatch.js +0 -416
- package/lib/skill-runtime/operations/init.js +0 -60
- package/lib/skill-runtime/operations/janitor.js +0 -61
- package/lib/skill-runtime/operations/plan.js +0 -59
- package/lib/skill-runtime/operations/prepare-pr.js +0 -25
- package/lib/skill-runtime/operations/release.js +0 -99
- package/lib/skill-runtime/operations/resume.js +0 -126
- package/lib/skill-runtime/operations/review-records.js +0 -265
- package/lib/skill-runtime/operations/snapshot.js +0 -45
- package/lib/skill-runtime/operations/task-contract.js +0 -593
- package/lib/skill-runtime/operations/verify.js +0 -170
- package/lib/skill-runtime/operations/worker-run.js +0 -531
- package/lib/skill-runtime/operations/worker.js +0 -33
- package/lib/skill-runtime/planner.js +0 -539
- package/lib/skill-runtime/readiness.js +0 -84
- package/lib/skill-runtime/review-records.js +0 -123
- package/lib/skill-runtime/review.js +0 -855
- package/lib/skill-runtime/schemas.js +0 -746
- package/lib/skill-runtime/task-contract.js +0 -188
- package/lib/skill-runtime/team-state.js +0 -122
- package/lib/skill-runtime/workflow-context.js +0 -748
package/docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/{planning/tasks.md → task.md}
RENAMED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
- Requirement version: `REQ-001.v1`
|
|
6
6
|
- Design version: `design.v1`
|
|
7
|
-
- CC-Plan skill version: `3.
|
|
7
|
+
- CC-Plan skill version: `3.10.1`
|
|
8
8
|
- Work branch: `REQ/001-copy-invite-link`
|
|
9
9
|
- Source roadmap item: `RM-001`
|
|
10
10
|
- Source roadmap version: `roadmap.v1`
|
|
@@ -45,20 +45,25 @@
|
|
|
45
45
|
ClaudeCode / Codex 执行本计划时,必须把本文件当成任务模板合同,而不是普通 TODO 列表。
|
|
46
46
|
|
|
47
47
|
- Template source: `assets/TASKS_TEMPLATE.md`
|
|
48
|
-
-
|
|
49
|
-
-
|
|
48
|
+
- CLI resolver: all workflow commands must run through `.claude/skills/cc-dev/scripts/resolve-cc-devflow.sh` or `.codex/skills/cc-dev/scripts/resolve-cc-devflow.sh`; if it cannot prove `query workflow-context` and `next-change-key`, stop blocked.
|
|
49
|
+
- Context first: run resolved CLI `query workflow-context --change <changeId> --change-key <changeKey> --cwd <repo-root> --data-only --no-trace --compact` before opening deep sections.
|
|
50
|
+
- Task selection: use `scripts/select-ready-tasks.sh --tasks devflow/changes/<change-key>/task.md`.
|
|
50
51
|
- Task block rule: read the full task block before coding; title-only execution is invalid.
|
|
51
|
-
- Completion rule: after verification and review gates pass, run
|
|
52
|
-
-
|
|
52
|
+
- Completion rule: after verification and review gates pass, run `scripts/mark-task-complete.sh --tasks devflow/changes/<change-key>/task.md --task <task-id>`.
|
|
53
|
+
- Runtime file ban: do not generate process files beyond this `task.md`.
|
|
53
54
|
|
|
54
55
|
```bash
|
|
55
|
-
cc-
|
|
56
|
-
|
|
56
|
+
DEVFLOW=".claude/skills/cc-dev/scripts/resolve-cc-devflow.sh"
|
|
57
|
+
if [[ ! -f "$DEVFLOW" && -f ".codex/skills/cc-dev/scripts/resolve-cc-devflow.sh" ]]; then
|
|
58
|
+
DEVFLOW=".codex/skills/cc-dev/scripts/resolve-cc-devflow.sh"
|
|
59
|
+
fi
|
|
60
|
+
bash "$DEVFLOW" require query workflow-context next-change-key
|
|
61
|
+
bash "$DEVFLOW" query workflow-context --change <changeId> --change-key <changeKey> --cwd <repo-root> --data-only --no-trace --compactSCRIPT_ROOT=".claude/skills/cc-do/scripts"
|
|
57
62
|
if [[ ! -d "$SCRIPT_ROOT" && -d ".codex/skills/cc-do/scripts" ]]; then
|
|
58
63
|
SCRIPT_ROOT=".codex/skills/cc-do/scripts"
|
|
59
64
|
fi
|
|
60
|
-
bash "$SCRIPT_ROOT/select-ready-tasks.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/
|
|
61
|
-
bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/
|
|
65
|
+
bash "$SCRIPT_ROOT/select-ready-tasks.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/
|
|
66
|
+
bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/ --tasks docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/task.md --task <task-id>
|
|
62
67
|
```
|
|
63
68
|
|
|
64
69
|
## Phase 1: Foundation
|
|
@@ -70,7 +75,7 @@ bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/cha
|
|
|
70
75
|
Read first: `design.md`, `src/features/share/ShareDialog.tsx`
|
|
71
76
|
Verification: `npm test -- src/features/share/ShareDialog.test.tsx`
|
|
72
77
|
Evidence: failing output that shows the missing button / action
|
|
73
|
-
Completion: after verification evidence and required review records exist, run `SCRIPT_ROOT=".claude/skills/cc-do/scripts"; if [[ ! -d "$SCRIPT_ROOT" && -d ".codex/skills/cc-do/scripts" ]]; then SCRIPT_ROOT=".codex/skills/cc-do/scripts"; fi; bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/
|
|
78
|
+
Completion: after verification evidence and required review records exist, run `SCRIPT_ROOT=".claude/skills/cc-do/scripts"; if [[ ! -d "$SCRIPT_ROOT" && -d ".codex/skills/cc-do/scripts" ]]; then SCRIPT_ROOT=".codex/skills/cc-do/scripts"; fi; bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/ --tasks docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/task.md --task T001`; do not hand-edit status.
|
|
74
79
|
Test seam: share dialog UI behavior
|
|
75
80
|
Public verification path: Run the share dialog test and observe the copy action through the rendered dialog
|
|
76
81
|
Allowed mocks: clipboard boundary
|
|
@@ -83,7 +88,7 @@ bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/cha
|
|
|
83
88
|
Read first: `design.md`, `src/features/share/ShareDialog.test.tsx`
|
|
84
89
|
Verification: `npm test -- src/features/share/ShareDialog.test.tsx`
|
|
85
90
|
Evidence: passing output + review notes
|
|
86
|
-
Completion: after verification evidence and required review records exist, run `SCRIPT_ROOT=".claude/skills/cc-do/scripts"; if [[ ! -d "$SCRIPT_ROOT" && -d ".codex/skills/cc-do/scripts" ]]; then SCRIPT_ROOT=".codex/skills/cc-do/scripts"; fi; bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/
|
|
91
|
+
Completion: after verification evidence and required review records exist, run `SCRIPT_ROOT=".claude/skills/cc-do/scripts"; if [[ ! -d "$SCRIPT_ROOT" && -d ".codex/skills/cc-do/scripts" ]]; then SCRIPT_ROOT=".codex/skills/cc-do/scripts"; fi; bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/ --tasks docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/task.md --task T002`; do not hand-edit status.
|
|
87
92
|
Test seam: share dialog UI behavior
|
|
88
93
|
Public verification path: Run the share dialog test and observe the copy action through the rendered dialog
|
|
89
94
|
Allowed mocks: clipboard boundary
|
|
@@ -95,12 +100,12 @@ bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/cha
|
|
|
95
100
|
Goal: 为 `cc-check` 准备本次实现的真实验证证据。
|
|
96
101
|
TDD phase: evidence
|
|
97
102
|
Files: `src/features/share/ShareDialog.tsx`, `src/features/share/ShareDialog.test.tsx`
|
|
98
|
-
Read first: `
|
|
103
|
+
Read first: `task.md`
|
|
99
104
|
Verification:
|
|
100
105
|
- `npm test -- src/features/share/ShareDialog.test.tsx`
|
|
101
106
|
- `npm run lint -- src/features/share/ShareDialog.tsx`
|
|
102
107
|
Evidence: passing test output + clean lint output
|
|
103
|
-
Completion: after verification evidence and required review records exist, run `SCRIPT_ROOT=".claude/skills/cc-do/scripts"; if [[ ! -d "$SCRIPT_ROOT" && -d ".codex/skills/cc-do/scripts" ]]; then SCRIPT_ROOT=".codex/skills/cc-do/scripts"; fi; bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/
|
|
108
|
+
Completion: after verification evidence and required review records exist, run `SCRIPT_ROOT=".claude/skills/cc-do/scripts"; if [[ ! -d "$SCRIPT_ROOT" && -d ".codex/skills/cc-do/scripts" ]]; then SCRIPT_ROOT=".codex/skills/cc-do/scripts"; fi; bash "$SCRIPT_ROOT/mark-task-complete.sh" --manifest docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/ --tasks docs/examples/pdca-loop/changes/REQ-001-copy-invite-link/task.md --task T003`; do not hand-edit status.
|
|
104
109
|
Test seam: share dialog UI behavior
|
|
105
110
|
Public verification path: Run the share dialog test and observe the copy action through the rendered dialog
|
|
106
111
|
Allowed mocks: clipboard boundary
|
|
@@ -17,11 +17,6 @@ fi
|
|
|
17
17
|
skill_version() {
|
|
18
18
|
local skill="$1"
|
|
19
19
|
local file="$ROOT_DIR/.claude/skills/$skill/SKILL.md"
|
|
20
|
-
if [[ ! -f "$file" ]]; then
|
|
21
|
-
echo "Missing skill file: $file" >&2
|
|
22
|
-
exit 1
|
|
23
|
-
fi
|
|
24
|
-
|
|
25
20
|
sed -n 's/^version: //p' "$file" | head -n 1
|
|
26
21
|
}
|
|
27
22
|
|
|
@@ -35,27 +30,15 @@ assert_contains() {
|
|
|
35
30
|
}
|
|
36
31
|
|
|
37
32
|
ROADMAP_VERSION="$(skill_version cc-roadmap)"
|
|
38
|
-
NEXT_VERSION="$(skill_version cc-next)"
|
|
39
|
-
DEV_VERSION="$(skill_version cc-dev)"
|
|
40
33
|
REQ_PLAN_VERSION="$(skill_version cc-plan)"
|
|
41
|
-
INVESTIGATE_VERSION="$(skill_version cc-investigate)"
|
|
42
34
|
REQ_DO_VERSION="$(skill_version cc-do)"
|
|
43
|
-
REQ_REVIEW_VERSION="$(skill_version cc-review)"
|
|
44
|
-
PR_REVIEW_VERSION="$(skill_version cc-pr-review)"
|
|
45
|
-
PR_LAND_VERSION="$(skill_version cc-pr-land)"
|
|
46
35
|
REQ_CHECK_VERSION="$(skill_version cc-check)"
|
|
47
36
|
REQ_ACT_VERSION="$(skill_version cc-act)"
|
|
48
37
|
|
|
49
38
|
for pair in \
|
|
50
39
|
"cc-roadmap:$ROADMAP_VERSION" \
|
|
51
|
-
"cc-next:$NEXT_VERSION" \
|
|
52
|
-
"cc-dev:$DEV_VERSION" \
|
|
53
40
|
"cc-plan:$REQ_PLAN_VERSION" \
|
|
54
|
-
"cc-investigate:$INVESTIGATE_VERSION" \
|
|
55
41
|
"cc-do:$REQ_DO_VERSION" \
|
|
56
|
-
"cc-review:$REQ_REVIEW_VERSION" \
|
|
57
|
-
"cc-pr-review:$PR_REVIEW_VERSION" \
|
|
58
|
-
"cc-pr-land:$PR_LAND_VERSION" \
|
|
59
42
|
"cc-check:$REQ_CHECK_VERSION" \
|
|
60
43
|
"cc-act:$REQ_ACT_VERSION"
|
|
61
44
|
do
|
|
@@ -73,11 +56,10 @@ while IFS= read -r encoded; do
|
|
|
73
56
|
readme="$ROOT_DIR/$(jq -r '.readme' <<<"$encoded")"
|
|
74
57
|
root="$ROOT_DIR/$(jq -r '.root' <<<"$encoded")"
|
|
75
58
|
change_dir="$ROOT_DIR/$(jq -r '.changeDir' <<<"$encoded")"
|
|
76
|
-
|
|
77
|
-
review_dir="$change_dir/review"
|
|
59
|
+
task_file="$change_dir/task.md"
|
|
78
60
|
handoff_dir="$change_dir/handoff"
|
|
79
61
|
|
|
80
|
-
for file in "$readme" "$root/ROADMAP.md" "$root/BACKLOG.md" "$root/roadmap.json" "$
|
|
62
|
+
for file in "$readme" "$root/ROADMAP.md" "$root/BACKLOG.md" "$root/roadmap.json" "$task_file"; do
|
|
81
63
|
if [[ ! -f "$file" ]]; then
|
|
82
64
|
echo "Example $example_id is missing required file: $file" >&2
|
|
83
65
|
exit 1
|
|
@@ -85,40 +67,14 @@ while IFS= read -r encoded; do
|
|
|
85
67
|
done
|
|
86
68
|
|
|
87
69
|
assert_contains "$root/ROADMAP.md" "- Skill version: \`$ROADMAP_VERSION\`"
|
|
88
|
-
assert_contains "$root/ROADMAP.md" "- Roadmap state source: \`roadmap.json\`"
|
|
89
|
-
assert_contains "$root/ROADMAP.md" "## Technical Architecture"
|
|
90
|
-
assert_contains "$root/ROADMAP.md" "\`\`\`mermaid"
|
|
91
70
|
assert_contains "$root/BACKLOG.md" "- Skill version: \`$ROADMAP_VERSION\`"
|
|
92
|
-
assert_contains "$
|
|
93
|
-
assert_contains "$
|
|
94
|
-
assert_contains "$
|
|
95
|
-
assert_contains "$
|
|
96
|
-
assert_contains "$
|
|
97
|
-
assert_contains "$
|
|
98
|
-
|
|
99
|
-
assert_contains "$planning_dir/design.md" "- CC-Plan skill version: \`$REQ_PLAN_VERSION\`"
|
|
100
|
-
assert_contains "$planning_dir/tasks.md" "- CC-Plan skill version: \`$REQ_PLAN_VERSION\`"
|
|
101
|
-
|
|
102
|
-
jq -er --arg roadmap "$ROADMAP_VERSION" --arg reqplan "$REQ_PLAN_VERSION" '
|
|
103
|
-
(.planningMeta.reqPlanSkillVersion // $reqplan) == $reqplan and
|
|
104
|
-
(.status? == null) and
|
|
105
|
-
(.activePhase? == null) and
|
|
106
|
-
(.sourceRoadmap? == null) and
|
|
107
|
-
(.spec? == null) and
|
|
108
|
-
(.executionProtocol? == null) and
|
|
109
|
-
(.planningMeta.requirementBrief? == null) and
|
|
110
|
-
(.planningMeta.ambiguityGate? == null) and
|
|
111
|
-
(.planningMeta.reviewLoop? == null) and
|
|
112
|
-
all(.tasks[]; (.completion? == null) and (.tddPhase | type == "string") and (.testSeam.publicVerificationPath | type == "string"))
|
|
113
|
-
' "$planning_dir/task-manifest.json" >/dev/null
|
|
114
|
-
|
|
115
|
-
assert_contains "$planning_dir/tasks.md" "## Execution Protocol"
|
|
116
|
-
assert_contains "$planning_dir/tasks.md" "cc-devflow query workflow-context"
|
|
117
|
-
assert_contains "$planning_dir/tasks.md" "--data-only --no-trace --compact"
|
|
118
|
-
assert_contains "$planning_dir/tasks.md" "mark-task-complete.sh"
|
|
119
|
-
assert_contains "$planning_dir/tasks.md" "TDD phase:"
|
|
120
|
-
assert_contains "$planning_dir/tasks.md" "Completion:"
|
|
121
|
-
assert_contains "$planning_dir/tasks.md" "Public verification path:"
|
|
71
|
+
assert_contains "$task_file" "- CC-Plan skill version: \`$REQ_PLAN_VERSION\`"
|
|
72
|
+
assert_contains "$task_file" "## Execution Protocol"
|
|
73
|
+
assert_contains "$task_file" "task.md"
|
|
74
|
+
assert_contains "$task_file" "mark-task-complete.sh"
|
|
75
|
+
assert_contains "$task_file" "TDD phase:"
|
|
76
|
+
assert_contains "$task_file" "Completion:"
|
|
77
|
+
assert_contains "$task_file" "Public verification path:"
|
|
122
78
|
|
|
123
79
|
assert_contains "$readme" "## Example Meta"
|
|
124
80
|
assert_contains "$readme" "\`cc-roadmap@$ROADMAP_VERSION\`"
|
|
@@ -128,15 +84,8 @@ while IFS= read -r encoded; do
|
|
|
128
84
|
|
|
129
85
|
if jq -e '.covers | index("cc-act")' <<<"$encoded" >/dev/null; then
|
|
130
86
|
assert_contains "$readme" "\`cc-act@$REQ_ACT_VERSION\`"
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
if [[ -f "$review_dir/report-card.json" ]]; then
|
|
134
|
-
"$ROOT_DIR/.claude/skills/cc-check/scripts/verify-gate.sh" --report "$review_dir/report-card.json" >/dev/null
|
|
135
|
-
fi
|
|
136
|
-
|
|
137
|
-
if jq -e '.covers | index("cc-act")' <<<"$encoded" >/dev/null; then
|
|
138
|
-
if [[ ! -f "$handoff_dir/pr-brief.md" && ! -f "$handoff_dir/resume-index.md" && ! -f "$handoff_dir/release-note.md" && ! -f "$handoff_dir/status.md" ]]; then
|
|
139
|
-
echo "Example $example_id is missing a final handoff file under $handoff_dir" >&2
|
|
87
|
+
if [[ ! -f "$handoff_dir/pr-brief.md" ]]; then
|
|
88
|
+
echo "Example $example_id is missing PR file: $handoff_dir/pr-brief.md" >&2
|
|
140
89
|
exit 1
|
|
141
90
|
fi
|
|
142
91
|
fi
|
|
@@ -1,48 +1,18 @@
|
|
|
1
1
|
# Artifact Contract
|
|
2
2
|
|
|
3
|
-
cc-devflow
|
|
4
|
-
Machine JSON has a third rule: it is CLI-owned. Agents write the human contract
|
|
5
|
-
in `planning/tasks.md`, then run `cc-devflow task-contract compile` / `validate`;
|
|
6
|
-
they must not handwrite `task-manifest.json` or `change-meta.json`.
|
|
3
|
+
cc-devflow keeps the workflow surface intentionally small.
|
|
7
4
|
|
|
8
|
-
##
|
|
5
|
+
## Durable Files
|
|
9
6
|
|
|
10
|
-
|
|
7
|
+
- `devflow/changes/<change-key>/task.md`
|
|
8
|
+
- `devflow/changes/<change-key>/handoff/pr-brief.md` when PR or local handoff needs it
|
|
9
|
+
- `devflow/postmortems/incidents/<date>-<change-key>.md` when a FIX or recurring failure needs a postmortem
|
|
10
|
+
- `devflow/postmortems/INDEX.md` as the postmortem index
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
- Conditional layer: open only when scope, dependency, review, or conflict questions arise.
|
|
14
|
-
- Deep layer: full evidence, reasoning, or historical review, opened only for audit or recovery.
|
|
12
|
+
## State Source
|
|
15
13
|
|
|
16
|
-
|
|
14
|
+
Git records process history. Commit after each completed PDCA or IDCA environment/stage.
|
|
17
15
|
|
|
18
|
-
##
|
|
16
|
+
## Retired Surface
|
|
19
17
|
|
|
20
|
-
|
|
21
|
-
| --- | --- | --- |
|
|
22
|
-
| Roadmap item status and progress | `devflow/roadmap.json` | `devflow/ROADMAP.md`, `devflow/BACKLOG.md`, handoff summaries |
|
|
23
|
-
| Capability/spec sync state | `devflow/changes/<change-key>/change-meta.json` | `planning/tasks.md`, `review/report-card.json`, handoff summaries |
|
|
24
|
-
| Execution task status | `planning/task-manifest.json.tasks[].status` | `planning/tasks.md` checkboxes, recovery summaries |
|
|
25
|
-
| Ready task / phase | derived from `tasks[].status`, `tasks[].phase`, and `tasks[].dependsOn` | `currentTaskId` cache, ready-task selector output |
|
|
26
|
-
| Runtime event log | `execution/tasks/<task-id>/events.jsonl` only for debug/failed runs | recovery summaries |
|
|
27
|
-
| Review verdict | `review/report-card.json.verdict` | PR brief, release note, act gate |
|
|
28
|
-
| PR / remote queue truth | live GitHub API / `gh` output | local review notes and handoff summaries |
|
|
29
|
-
| Project postmortem facts and principles | `devflow/postmortems/` | planning recall, investigation hypotheses, task guardrails |
|
|
30
|
-
|
|
31
|
-
## Duplication Rules
|
|
32
|
-
|
|
33
|
-
- Machine artifacts may reference another owner by id or path, but must not copy its status lifecycle.
|
|
34
|
-
- Markdown projections must state their source instead of becoming editable truth.
|
|
35
|
-
- Derived fields must be described as derived/cache and must be recomputable.
|
|
36
|
-
- A skill must not create a new status field unless it also names the owner, lifecycle, projection readers, and validation gate.
|
|
37
|
-
- Task manifests must not duplicate PRD narrative, review-loop prose, source-trust details, completion shell commands, roadmap progress, or spec sync status.
|
|
38
|
-
- Task manifests and change metadata must be generated or refreshed by CLI/template tooling, not manually edited as process notes.
|
|
39
|
-
- Project postmortems must cite stronger owner artifacts and Git evidence; they do not own roadmap progress, task status, review verdicts, or spec sync state.
|
|
40
|
-
|
|
41
|
-
## Required Check
|
|
42
|
-
|
|
43
|
-
Before changing any skill output, answer:
|
|
44
|
-
|
|
45
|
-
1. Who owns this state?
|
|
46
|
-
2. Is this field consumed directly, or is it a projection?
|
|
47
|
-
3. Can it be recomputed from a stronger source?
|
|
48
|
-
4. What validation fails if this state diverges?
|
|
18
|
+
Do not create process JSON, review ledgers, report cards, status files, resume files, release notes, or principle files.
|
|
@@ -86,20 +86,20 @@ Use the skills in this order:
|
|
|
86
86
|
Typical outputs:
|
|
87
87
|
|
|
88
88
|
- `cc-roadmap` writes `devflow/roadmap.json` as the editable roadmap truth, then generates `devflow/ROADMAP.md` and deprecated `devflow/BACKLOG.md`
|
|
89
|
-
- `cc-spec-init` writes `devflow/specs/INDEX.md
|
|
90
|
-
- `cc-plan` writes `
|
|
91
|
-
- `cc-investigate` writes `
|
|
92
|
-
- `cc-review`
|
|
93
|
-
- `cc-check`
|
|
94
|
-
- `cc-act` writes exactly one final
|
|
89
|
+
- `cc-spec-init` writes `devflow/specs/INDEX.md` and capability specs
|
|
90
|
+
- `cc-plan` writes `task.md#Contract Summary`
|
|
91
|
+
- `cc-investigate` writes `task.md#Root Cause Contract`
|
|
92
|
+
- `cc-review` reports concrete findings in the response; it does not write review process files
|
|
93
|
+
- `cc-check` reports verification facts in the response, PR brief, or Git commit
|
|
94
|
+
- `cc-act` writes exactly one final PR file, `handoff/pr-brief.md`, or incident postmortem files when a real incident needs a corpse report
|
|
95
95
|
|
|
96
96
|
Capability truth lives in `devflow/specs/`.
|
|
97
97
|
Change truth lives in `devflow/changes/<change>/`.
|
|
98
98
|
|
|
99
99
|
- Keep `INDEX.md` plus capability markdown under `devflow/specs/`.
|
|
100
100
|
- Name new change directories as `REQ-<number>-<description>` for requirements or `FIX-<number>-<description>` for bug fixes. `REQ` and `FIX` advance as separate local sequences, so cross-prefix duplicates are valid. Parallel worktrees may still repeat numbers; the full change key, especially the description, distinguishes the work. Old lowercase directories are compatibility reads only.
|
|
101
|
-
- Keep
|
|
102
|
-
-
|
|
101
|
+
- Keep `task.md`, optional `handoff/pr-brief.md`, and incident postmortem files under each `devflow/changes/<change>/`. Do not generate task `context.md`, `checkpoint.json`, review ledgers, status/resume files, release notes, principle files, or AI-written process files.
|
|
102
|
+
- Workflow state is Git-owned: keep `task.md`, commit each completed stage, and do not create process JSON.
|
|
103
103
|
- Legacy `planning/design.md`, `planning/analysis.md`, and `cc-review-*.md` are readable fallback inputs for older changes, not new default writes.
|
|
104
104
|
- Worker prompts, journals, assignments, and session logs belong under `devflow/workspaces/<change>/` as ephemeral scratch.
|
|
105
105
|
|
|
@@ -86,19 +86,19 @@ find .codex/skills -mindepth 2 -maxdepth 2 -name SKILL.md | sort
|
|
|
86
86
|
常见产物:
|
|
87
87
|
|
|
88
88
|
- `cc-roadmap` 产出可编辑真相 `devflow/roadmap.json`,再生成 `devflow/ROADMAP.md` 和 deprecated `devflow/BACKLOG.md`
|
|
89
|
-
- `cc-spec-init` 产出 `devflow/specs/INDEX.md
|
|
90
|
-
- `cc-plan` 产出 `
|
|
91
|
-
- `cc-investigate` 产出 `
|
|
92
|
-
- `cc-review`
|
|
93
|
-
- `cc-check`
|
|
94
|
-
- `cc-act`
|
|
89
|
+
- `cc-spec-init` 产出 `devflow/specs/INDEX.md` 和 capability spec
|
|
90
|
+
- `cc-plan` 产出 `task.md#Contract Summary`
|
|
91
|
+
- `cc-investigate` 产出 `task.md#Root Cause Contract`
|
|
92
|
+
- `cc-review` 在当前回复里报告具体问题,不写 review 过程文件
|
|
93
|
+
- `cc-check` 在当前回复、PR 文件或 Git commit 里记录验证事实
|
|
94
|
+
- `cc-act` 只产出最终 PR 文件 `handoff/pr-brief.md`;真实事故需要尸检时才产出 incident postmortem 文件
|
|
95
95
|
|
|
96
96
|
durable truth 分两层:
|
|
97
97
|
|
|
98
98
|
- `devflow/specs/`:capability 真相,保留 `INDEX.md` 与 `capabilities/*.md`
|
|
99
99
|
- 新 change 目录必须命名为 `REQ-<number>-<description>`(需求)或 `FIX-<number>-<description>`(修复);`REQ` 和 `FIX` 分别维护自己的递增编号,跨前缀同号不是冲突;并行工作树造成重复编号时,完整 change key 的描述负责区分业务内容,旧小写目录只作为历史兼容读取。
|
|
100
|
-
- `devflow/changes/<change
|
|
101
|
-
-
|
|
100
|
+
- `devflow/changes/<change>/`:变更真相,只保留 `task.md`、可选 `handoff/pr-brief.md`,以及真实事故需要的尸检文件。不要生成任务级 `context.md`、`checkpoint.json`、review ledger、status/resume 文件、release note、principles 或 AI 手写过程文件。
|
|
101
|
+
- 流程状态归 Git:保留 `task.md`,每个完成阶段提交 commit,不创建过程 JSON。
|
|
102
102
|
- 历史 `planning/design.md`、`planning/analysis.md` 和 `cc-review-*.md` 是旧 change 的可读 fallback,不再是新默认写入。
|
|
103
103
|
- worker prompt、journal、assignment、session log 统一放到 `devflow/workspaces/<change>/`,作为 ephemeral scratch。
|
|
104
104
|
|
|
@@ -1,137 +1,23 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Minimize Artifacts
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
The goal is simple: keep durable workflow truth readable, small, and measurable.
|
|
3
|
+
The workflow is intentionally Git-first.
|
|
5
4
|
|
|
6
|
-
##
|
|
5
|
+
## Keep
|
|
7
6
|
|
|
8
|
-
|
|
7
|
+
- `task.md`
|
|
8
|
+
- `handoff/pr-brief.md` when a PR or local handoff needs it
|
|
9
|
+
- incident postmortem when a FIX or recurring failure needs it
|
|
9
10
|
|
|
10
|
-
|
|
11
|
+
## Do Not Keep
|
|
11
12
|
|
|
12
|
-
-
|
|
13
|
+
- process JSON
|
|
14
|
+
- review ledgers or finding files
|
|
15
|
+
- report cards
|
|
16
|
+
- status or resume files
|
|
17
|
+
- release notes
|
|
18
|
+
- principles files
|
|
19
|
+
- task context or checkpoint files
|
|
13
20
|
|
|
14
|
-
|
|
21
|
+
## Commit Rule
|
|
15
22
|
|
|
16
|
-
|
|
17
|
-
- `planning/task-manifest.json`
|
|
18
|
-
- `review/review-ledger.jsonl`
|
|
19
|
-
- `review/review-findings.json` when findings exist
|
|
20
|
-
- `execution/tasks/<task-id>/checkpoint.json`
|
|
21
|
-
- `review/report-card.json`
|
|
22
|
-
- one final handoff file under `handoff/`
|
|
23
|
-
|
|
24
|
-
Runtime scratch, worker prompts, journals, assignments, and session logs belong
|
|
25
|
-
under `devflow/workspaces/<change-key>/`, not beside durable change truth.
|
|
26
|
-
|
|
27
|
-
## Feature Plans
|
|
28
|
-
|
|
29
|
-
Feature and scope changes use:
|
|
30
|
-
|
|
31
|
-
- `planning/tasks.md#Contract Summary`
|
|
32
|
-
- `planning/task-manifest.json`
|
|
33
|
-
- `change-meta.json`
|
|
34
|
-
|
|
35
|
-
`Contract Summary` owns the frozen human-readable plan: user story, non-negotiable
|
|
36
|
-
constraints, decisions that must not be reopened, task slices, and verification
|
|
37
|
-
expectations. `task-manifest.json` and `change-meta.json` must be generated or
|
|
38
|
-
updated by `cc-devflow task-contract compile`; agents must not handwrite them.
|
|
39
|
-
|
|
40
|
-
## Bug Investigations
|
|
41
|
-
|
|
42
|
-
Bug, regression, and unexpected-behavior work uses:
|
|
43
|
-
|
|
44
|
-
- `planning/tasks.md#Root Cause Contract`
|
|
45
|
-
- `planning/task-manifest.json`
|
|
46
|
-
- `change-meta.json`
|
|
47
|
-
|
|
48
|
-
`Root Cause Contract` owns the symptom, reproduction evidence, confirmed cause,
|
|
49
|
-
rejected near-causes, repair boundary, and task handoff. `cc-do` should implement
|
|
50
|
-
from that frozen contract instead of reopening investigation during execution.
|
|
51
|
-
`task-manifest.json` and `change-meta.json` must be generated or updated by
|
|
52
|
-
`cc-devflow task-contract compile`; agents must not handwrite them.
|
|
53
|
-
|
|
54
|
-
## Review Records
|
|
55
|
-
|
|
56
|
-
`cc-review` writes structured lifecycle events first:
|
|
57
|
-
|
|
58
|
-
- `review/review-ledger.jsonl`
|
|
59
|
-
- optional `review/review-findings.json`
|
|
60
|
-
- optional rendered Markdown from `cc-devflow review render`
|
|
61
|
-
|
|
62
|
-
Markdown review reports are for human reading when needed. They are not the
|
|
63
|
-
default durable review source.
|
|
64
|
-
|
|
65
|
-
Useful commands:
|
|
66
|
-
|
|
67
|
-
```bash
|
|
68
|
-
npx cc-devflow review start --change REQ-001 --change-key REQ-001-copy-invite-link --base-sha abc123 --head-sha def456
|
|
69
|
-
npx cc-devflow review record-node --change REQ-001 --change-key REQ-001-copy-invite-link --review-id <review-id> --node-id R001 --target planning/tasks.md --status checked --coverage contract --evidence-ref "cmd:npm run verify"
|
|
70
|
-
npx cc-devflow review add-finding --change REQ-001 --change-key REQ-001-copy-invite-link --review-id <review-id> --finding-id F001 --severity important --confidence 8 --display-tier blocking --fingerprint sha256:<hash> --scope "current change" --path planning/tasks.md --evidence "finding evidence" --recommendation "repair action" --route cc-do
|
|
71
|
-
npx cc-devflow review close --change REQ-001 --change-key REQ-001-copy-invite-link --review-id <review-id> --status clean --blocking-count 0 --warning-count 0 --next cc-check
|
|
72
|
-
npx cc-devflow review render --change REQ-001 --change-key REQ-001-copy-invite-link --review-id <review-id> --output review/review-report.md
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
## Legacy Fallback
|
|
76
|
-
|
|
77
|
-
Older changes may still contain:
|
|
78
|
-
|
|
79
|
-
- `planning/design.md`
|
|
80
|
-
- `planning/analysis.md`
|
|
81
|
-
- `review/cc-review-plan.md`
|
|
82
|
-
- `review/cc-review-report.md`
|
|
83
|
-
- `review/cc-review-agent-results.jsonl`
|
|
84
|
-
|
|
85
|
-
Those files remain readable compatibility inputs. New changes should not write
|
|
86
|
-
them by default. When migrating old work, fold feature-plan truth into
|
|
87
|
-
`planning/tasks.md#Contract Summary` and bug-investigation truth into
|
|
88
|
-
`planning/tasks.md#Root Cause Contract`.
|
|
89
|
-
|
|
90
|
-
## Validation Gates
|
|
91
|
-
|
|
92
|
-
Validate one change:
|
|
93
|
-
|
|
94
|
-
```bash
|
|
95
|
-
npx cc-devflow task-contract compile --change REQ-001 --change-key REQ-001-copy-invite-link
|
|
96
|
-
npx cc-devflow task-contract validate --change REQ-001 --change-key REQ-001-copy-invite-link
|
|
97
|
-
```
|
|
98
|
-
|
|
99
|
-
Validate the repository artifact contract:
|
|
100
|
-
|
|
101
|
-
```bash
|
|
102
|
-
npm run verify:artifacts
|
|
103
|
-
```
|
|
104
|
-
|
|
105
|
-
Measure the contract:
|
|
106
|
-
|
|
107
|
-
```bash
|
|
108
|
-
npm run benchmark:artifacts
|
|
109
|
-
```
|
|
110
|
-
|
|
111
|
-
The package-level verification command also includes artifact validation:
|
|
112
|
-
|
|
113
|
-
```bash
|
|
114
|
-
npm run verify
|
|
115
|
-
```
|
|
116
|
-
|
|
117
|
-
Skill entrypoints have a separate context budget:
|
|
118
|
-
|
|
119
|
-
```bash
|
|
120
|
-
npm run benchmark:skills
|
|
121
|
-
```
|
|
122
|
-
|
|
123
|
-
Keep `SKILL.md` files as thin entry contracts. Move low-frequency planning,
|
|
124
|
-
review, and recovery details behind `PLAYBOOK.md` or `references/*` so agents
|
|
125
|
-
open them only when the matching escalation condition appears.
|
|
126
|
-
|
|
127
|
-
## Authoring Rule
|
|
128
|
-
|
|
129
|
-
Before adding a durable file under `devflow/changes/<change-key>/`, answer:
|
|
130
|
-
|
|
131
|
-
1. Which downstream skill reads it by default?
|
|
132
|
-
2. Which state does it own that no existing artifact owns?
|
|
133
|
-
3. Which command fails if it drifts?
|
|
134
|
-
|
|
135
|
-
If those answers are unclear, keep the information in `planning/tasks.md` or
|
|
136
|
-
ephemeral workspace scratch. Machine JSON belongs to the CLI/compiler path, not
|
|
137
|
-
manual agent authoring.
|
|
23
|
+
Each completed PDCA or IDCA environment/stage gets a Git commit. Use the commit graph as the process record.
|
|
@@ -1,78 +1,21 @@
|
|
|
1
|
-
# Project
|
|
1
|
+
# Project Postmortems
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
chat summaries. They are repo-owned evidence that future agents can search before
|
|
5
|
-
planning, investigating, or executing work.
|
|
3
|
+
Postmortems preserve recurring failures without turning every workflow step into a file.
|
|
6
4
|
|
|
7
|
-
##
|
|
5
|
+
## Files
|
|
8
6
|
|
|
9
|
-
|
|
7
|
+
- `devflow/postmortems/INDEX.md`
|
|
8
|
+
- `devflow/postmortems/incidents/<date>-<change-key>.md`
|
|
10
9
|
|
|
11
|
-
|
|
12
|
-
| --- | --- | --- |
|
|
13
|
-
| `INDEX.md` | `cc-act` | Progressive entry point, latest incidents, tags, and search hints |
|
|
14
|
-
| `principles.md` | `cc-act` | Generalized lessons about recurring model, process, and engineering mistakes |
|
|
15
|
-
| `incidents/<date>-<change-key>.md` | `cc-act` | Immutable-ish factual record for one incident, bug, or repeated AI failure |
|
|
10
|
+
## When To Write One
|
|
16
11
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
12
|
+
- closing a `FIX-*`
|
|
13
|
+
- repeated AI, test, release, Git, or architecture failure
|
|
14
|
+
- explicit user request
|
|
20
15
|
|
|
21
|
-
##
|
|
16
|
+
## Rules
|
|
22
17
|
|
|
23
|
-
-
|
|
24
|
-
|
|
25
|
-
-
|
|
26
|
-
|
|
27
|
-
- Incident layer: `incidents/*.md` gives the detailed facts, Git evidence,
|
|
28
|
-
timeline, root cause, detection gap, repair, follow-ups, and search terms.
|
|
29
|
-
|
|
30
|
-
Agents should start with keyword search over the default and principle layers, then
|
|
31
|
-
open incident files only when the tags or failure class match the current task.
|
|
32
|
-
|
|
33
|
-
## Required Incident Evidence
|
|
34
|
-
|
|
35
|
-
Every incident file should include:
|
|
36
|
-
|
|
37
|
-
- Symptom and impact.
|
|
38
|
-
- Trigger and timeline.
|
|
39
|
-
- Confirmed root cause and rejected near-causes.
|
|
40
|
-
- Why the failure escaped planning, investigation, execution, review, or ship.
|
|
41
|
-
- Git evidence: branch, base, head SHA, PR if any, relevant commits, review range,
|
|
42
|
-
and dirty-tree notes when they matter.
|
|
43
|
-
- Verification evidence: commands, exit status, key output, and artifact paths.
|
|
44
|
-
- Follow-up actions: root-cause fixes, detection improvements, and backlog items.
|
|
45
|
-
- AI failure mode: model limitation, pattern-matching trap, missing evidence habit,
|
|
46
|
-
over-broad abstraction, fake compatibility, test-seam mistake, or other reusable
|
|
47
|
-
class.
|
|
48
|
-
- Search terms future agents should use before repeating similar work.
|
|
49
|
-
|
|
50
|
-
## Redaction Guard
|
|
51
|
-
|
|
52
|
-
Postmortems are durable repo artifacts, so they must never preserve secrets,
|
|
53
|
-
tokens, private customer data, personal machine paths, or raw private logs unless
|
|
54
|
-
the repository already treats that exact artifact as public source truth.
|
|
55
|
-
|
|
56
|
-
- Record the command, file path, commit, or artifact pointer that proves the fact.
|
|
57
|
-
- Quote only the minimal output needed to prove the incident.
|
|
58
|
-
- Replace sensitive values with `<redacted>` and add a short redaction summary.
|
|
59
|
-
- If the only available proof is sensitive, cite the owner artifact and describe
|
|
60
|
-
the observed shape instead of copying the raw value.
|
|
61
|
-
|
|
62
|
-
## Read Gates
|
|
63
|
-
|
|
64
|
-
`cc-plan`, `cc-investigate`, and `cc-do` must run a quick local search before they
|
|
65
|
-
freeze direction or touch code:
|
|
66
|
-
|
|
67
|
-
```bash
|
|
68
|
-
rg -n "<capability|module|error|failure-class|model-risk>" devflow/postmortems
|
|
69
|
-
```
|
|
70
|
-
|
|
71
|
-
If `devflow/postmortems/` does not exist, record `no-project-postmortems-yet`.
|
|
72
|
-
If a match exists, load only `INDEX.md`, `principles.md`, and the one or two
|
|
73
|
-
incident files most relevant to the current work.
|
|
74
|
-
|
|
75
|
-
## State Ownership
|
|
76
|
-
|
|
77
|
-
Postmortems do not own task status, roadmap progress, review verdicts, or spec sync
|
|
78
|
-
state. They cite those stronger owners by path, commit, or command output.
|
|
18
|
+
- Use Git evidence, commands, and current files.
|
|
19
|
+
- Redact secrets, customer data, private logs, and local machine paths.
|
|
20
|
+
- Do not create a separate principles file.
|
|
21
|
+
- Do not use postmortems as task, review, or release state.
|
|
@@ -159,9 +159,9 @@ describe('Skills Registry Generator', () => {
|
|
|
159
159
|
expect(execute.writes).toEqual(
|
|
160
160
|
expect.arrayContaining([
|
|
161
161
|
expect.objectContaining({
|
|
162
|
-
path: 'devflow/changes/<change-key>/
|
|
162
|
+
path: 'devflow/changes/<change-key>/task.md',
|
|
163
163
|
durability: 'durable',
|
|
164
|
-
required:
|
|
164
|
+
required: true
|
|
165
165
|
})
|
|
166
166
|
])
|
|
167
167
|
);
|
|
@@ -183,13 +183,14 @@ describe('Skills Registry Generator', () => {
|
|
|
183
183
|
expect.arrayContaining([
|
|
184
184
|
expect.objectContaining({
|
|
185
185
|
path: 'devflow/changes/<change-key>/handoff/pr-brief.md',
|
|
186
|
-
required: false
|
|
187
|
-
|
|
188
|
-
|
|
186
|
+
required: false
|
|
187
|
+
})
|
|
188
|
+
])
|
|
189
|
+
);
|
|
190
|
+
expect(act.writes).not.toEqual(
|
|
191
|
+
expect.arrayContaining([
|
|
189
192
|
expect.objectContaining({
|
|
190
|
-
path: '
|
|
191
|
-
required: false,
|
|
192
|
-
exclusiveGroup: 'handoff'
|
|
193
|
+
path: expect.stringContaining('release')
|
|
193
194
|
})
|
|
194
195
|
])
|
|
195
196
|
);
|