contract-driven-delivery 1.10.0 → 1.12.0
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/CHANGELOG.md +72 -0
- package/README.md +532 -135
- package/assets/CLAUDE.template.md +34 -0
- package/assets/CODEX.template.md +39 -0
- package/assets/agents/backend-engineer.md +15 -0
- package/assets/agents/change-classifier.md +57 -1
- package/assets/agents/ci-cd-gatekeeper.md +15 -0
- package/assets/agents/contract-reviewer.md +15 -0
- package/assets/agents/dependency-security-reviewer.md +2 -0
- package/assets/agents/e2e-resilience-engineer.md +15 -0
- package/assets/agents/frontend-engineer.md +15 -0
- package/assets/agents/monkey-test-engineer.md +15 -0
- package/assets/agents/qa-reviewer.md +15 -0
- package/assets/agents/repo-context-scanner.md +2 -0
- package/assets/agents/spec-architect.md +15 -0
- package/assets/agents/spec-drift-auditor.md +2 -0
- package/assets/agents/stress-soak-engineer.md +15 -0
- package/assets/agents/test-strategist.md +15 -0
- package/assets/agents/ui-ux-reviewer.md +2 -0
- package/assets/agents/visual-reviewer.md +2 -0
- package/assets/cdd/context-policy.json +25 -0
- package/assets/cdd/model-policy.json +5 -0
- package/assets/contracts/api/api-contract.md +3 -0
- package/assets/contracts/api/api-inventory.md +7 -0
- package/assets/contracts/api/error-format.md +7 -0
- package/assets/contracts/business/business-rules.md +3 -0
- package/assets/contracts/ci/ci-gate-contract.md +3 -0
- package/assets/contracts/css/css-contract.md +3 -0
- package/assets/contracts/css/design-tokens.md +7 -0
- package/assets/contracts/data/data-shape-contract.md +3 -0
- package/assets/contracts/env/env-contract.md +3 -0
- package/assets/hooks/pre-commit +1 -1
- package/assets/skills/cdd-close/SKILL.md +150 -0
- package/assets/skills/cdd-new/SKILL.md +94 -35
- package/assets/skills/cdd-resume/SKILL.md +114 -0
- package/assets/skills/contract-driven-delivery/templates/change-classification.md +9 -8
- package/assets/skills/contract-driven-delivery/templates/tasks.md +7 -0
- package/assets/specs-templates/change-classification.md +9 -8
- package/assets/specs-templates/context-manifest.md +49 -0
- package/assets/specs-templates/tasks.md +9 -0
- package/dist/cli/index.js +1846 -152
- package/docs/release-checklist.md +39 -0
- package/package.json +12 -6
|
@@ -23,4 +23,38 @@ This repository follows the Contract-Driven Delivery workflow.
|
|
|
23
23
|
- `specs/changes/<id>/` records why decisions were made (passive archive — read only when investigating history).
|
|
24
24
|
- To start any non-trivial change, use `/cdd-new <description>` in Claude Code.
|
|
25
25
|
|
|
26
|
+
## CDD Kit Commands
|
|
27
|
+
|
|
28
|
+
| command | when to use |
|
|
29
|
+
|---|---|
|
|
30
|
+
| `/cdd-new <description>` | start a new tracked change (scaffolds all artifacts, runs full agent flow) |
|
|
31
|
+
| `/cdd-resume <id>` | continue an in-progress change after a session break |
|
|
32
|
+
| `/cdd-close <id>` | close a completed change: promote learnings, archive |
|
|
33
|
+
| `cdd-kit list` | show all active changes and their status |
|
|
34
|
+
| `cdd-kit gate <id>` | verify a change is gate-ready (run before PR) |
|
|
35
|
+
| `cdd-kit gate <id> --strict` | full gate with pending-task enforcement (pre-commit default) |
|
|
36
|
+
| `cdd-kit archive <id>` | physically move a completed change to `specs/archive/<year>/` |
|
|
37
|
+
| `cdd-kit abandon <id> --reason <text>` | mark a change as abandoned; preserves directory for git history |
|
|
38
|
+
| `cdd-kit migrate <id> \| --all` | upgrade pre-v1.11 change directories to new format (frontmatter + tier format) |
|
|
39
|
+
| `cdd-kit validate` | run all contract validators |
|
|
40
|
+
| `cdd-kit detect-stack` | detect the project tech stack |
|
|
41
|
+
|
|
26
42
|
Run `cdd-kit detect-stack` to verify the detected tech stack.
|
|
43
|
+
|
|
44
|
+
## Context Governance
|
|
45
|
+
|
|
46
|
+
For context-governed changes, read `specs/changes/<change-id>/context-manifest.md` before using file-reading or broad search tools.
|
|
47
|
+
|
|
48
|
+
- Read only paths allowed by the manifest or approved expansions.
|
|
49
|
+
- If more context is needed, stop and write a Context Expansion Request in the manifest.
|
|
50
|
+
- Record every file read through tools in the relevant `agent-log/*.md` under `- files-read:`.
|
|
51
|
+
|
|
52
|
+
Required `agent-log/*.md` format:
|
|
53
|
+
|
|
54
|
+
```md
|
|
55
|
+
- files-read:
|
|
56
|
+
- contracts/api/api-contract.md
|
|
57
|
+
- src/server/routes/users.ts
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Every entry must be a repo-relative path. Do not omit files, use absolute paths, or use `..`.
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# CODEX.md
|
|
2
|
+
|
|
3
|
+
This project uses Contract-Driven Delivery (CDD).
|
|
4
|
+
|
|
5
|
+
## Workflow
|
|
6
|
+
|
|
7
|
+
- Treat `contracts/` as the current source of truth.
|
|
8
|
+
- Treat `specs/changes/<change-id>/` as active work context.
|
|
9
|
+
- Treat `specs/archive/` as historical context only; do not use it for current planning unless explicitly asked.
|
|
10
|
+
- Start non-trivial work by creating a change with `cdd-kit new <change-id>`.
|
|
11
|
+
- Run `cdd-kit context-scan` before classification when project context may be stale.
|
|
12
|
+
- Run `cdd-kit gate <change-id>` before proposing a commit or PR.
|
|
13
|
+
|
|
14
|
+
## Context Governance
|
|
15
|
+
|
|
16
|
+
Read `specs/changes/<change-id>/context-manifest.md` before using file-reading or search tools.
|
|
17
|
+
|
|
18
|
+
- Read only paths allowed by the manifest or approved expansions.
|
|
19
|
+
- Do not use broad repository search unless the manifest authorizes it.
|
|
20
|
+
- If more context is needed, stop and write a Context Expansion Request in the manifest.
|
|
21
|
+
- Record every file read through tools in the relevant `agent-log/*.md` under `- files-read:`.
|
|
22
|
+
|
|
23
|
+
Required `agent-log/*.md` format:
|
|
24
|
+
|
|
25
|
+
```md
|
|
26
|
+
- files-read:
|
|
27
|
+
- contracts/api/api-contract.md
|
|
28
|
+
- src/server/routes/users.ts
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Every entry must be a repo-relative path. Do not omit files, use absolute paths, or use `..`.
|
|
32
|
+
|
|
33
|
+
## Hot And Cold Data
|
|
34
|
+
|
|
35
|
+
- Hot: `contracts/`, source files, tests, CI config.
|
|
36
|
+
- Warm: current `specs/changes/<change-id>/`.
|
|
37
|
+
- Cold: `specs/archive/`.
|
|
38
|
+
|
|
39
|
+
Cold historical data is evidence, not current requirements.
|
|
@@ -30,6 +30,12 @@ Before editing production code, read the change artifacts, API/env/data/business
|
|
|
30
30
|
- Read-after-write consistency — a write followed by an immediate read on a replica may return stale data.
|
|
31
31
|
- Pagination — always sort by a stable column + tie-breaker (id), never offset-paginate over mutable data.
|
|
32
32
|
|
|
33
|
+
## Read scope
|
|
34
|
+
|
|
35
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
36
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
37
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
38
|
+
|
|
33
39
|
## Handoff
|
|
34
40
|
|
|
35
41
|
Report changed files, contract updates, tests added, commands run, known risks, and next reviewer.
|
|
@@ -49,6 +55,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
49
55
|
- change-id: <id>
|
|
50
56
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
51
57
|
- status: complete | needs-review | blocked
|
|
58
|
+
- files-read:
|
|
59
|
+
- <repo-relative path read through tools>
|
|
52
60
|
- artifacts:
|
|
53
61
|
- <evidence-type>: <concrete pointer>
|
|
54
62
|
- <evidence-type>: <concrete pointer>
|
|
@@ -70,3 +78,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
70
78
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
71
79
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
72
80
|
without a pointer.
|
|
81
|
+
|
|
82
|
+
## Read scope
|
|
83
|
+
|
|
84
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
85
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
86
|
+
|
|
87
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -7,7 +7,19 @@ model: claude-opus-4-7
|
|
|
7
7
|
|
|
8
8
|
You are the change classifier for Contract-Driven Delivery.
|
|
9
9
|
|
|
10
|
-
Your job is to stop premature implementation. Read the user request and
|
|
10
|
+
Your job is to stop premature implementation. Read the user request and deterministic project context, then produce a classification report and context-manifest draft.
|
|
11
|
+
|
|
12
|
+
## Context boundaries
|
|
13
|
+
|
|
14
|
+
During initial classification, read only:
|
|
15
|
+
- `specs/changes/<change-id>/change-request.md`
|
|
16
|
+
- `specs/changes/<change-id>/context-manifest.md`
|
|
17
|
+
- `specs/context/project-map.md`
|
|
18
|
+
- `specs/context/contracts-index.md`
|
|
19
|
+
|
|
20
|
+
Do not read `contracts/`, `src/`, `tests/`, or use broad search during initial classification unless the manifest already authorizes it. If the indexes are insufficient, add a Context Expansion Request to the manifest draft instead of reading outside this packet.
|
|
21
|
+
|
|
22
|
+
Use `project-map.md` to identify candidate source/test paths and `contracts-index.md` to identify candidate contract paths. Do not invent paths that are absent from the project map or contracts index.
|
|
11
23
|
|
|
12
24
|
## Tier mapping
|
|
13
25
|
|
|
@@ -85,6 +97,47 @@ Note: `archive.md` is created during change close-out, not at classification tim
|
|
|
85
97
|
## Required Agents
|
|
86
98
|
...
|
|
87
99
|
|
|
100
|
+
## Context Manifest Draft
|
|
101
|
+
|
|
102
|
+
### Affected Surfaces
|
|
103
|
+
- <surface or module>
|
|
104
|
+
|
|
105
|
+
### Allowed Paths
|
|
106
|
+
- specs/changes/<change-id>/
|
|
107
|
+
- specs/context/project-map.md
|
|
108
|
+
- specs/context/contracts-index.md
|
|
109
|
+
- <candidate repo-relative path from project-map or contracts-index>
|
|
110
|
+
|
|
111
|
+
### Required Contracts
|
|
112
|
+
- <contract path from contracts-index, or none>
|
|
113
|
+
|
|
114
|
+
### Required Tests
|
|
115
|
+
- <test path or test directory from project-map, or none>
|
|
116
|
+
|
|
117
|
+
### Agent Work Packets
|
|
118
|
+
|
|
119
|
+
#### <agent-name>
|
|
120
|
+
- allowed:
|
|
121
|
+
- specs/changes/<change-id>/
|
|
122
|
+
- <repo-relative path>
|
|
123
|
+
|
|
124
|
+
### Context Expansion Requests
|
|
125
|
+
- request-id: CER-001
|
|
126
|
+
requested_paths:
|
|
127
|
+
- <repo-relative path>
|
|
128
|
+
reason: <why the index is insufficient>
|
|
129
|
+
status: pending
|
|
130
|
+
|
|
131
|
+
## Inferred Acceptance Criteria
|
|
132
|
+
(List 3-8 testable acceptance criteria derived from the change request. Format: `AC-N: <criterion>`. These will be used by test-strategist to populate the Acceptance Criteria → Test Mapping table.)
|
|
133
|
+
- AC-1:
|
|
134
|
+
- AC-2:
|
|
135
|
+
- AC-3:
|
|
136
|
+
|
|
137
|
+
## Tasks Not Applicable
|
|
138
|
+
(List task IDs from tasks.md that are NOT applicable to this change, using the format `2.2, 2.3, 4.2`. Main Claude will mark these as [-] in tasks.md.)
|
|
139
|
+
- not-applicable:
|
|
140
|
+
|
|
88
141
|
## Clarifications or Assumptions
|
|
89
142
|
...
|
|
90
143
|
```
|
|
@@ -99,6 +152,8 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
99
152
|
- change-id: <id>
|
|
100
153
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
101
154
|
- status: complete | needs-review | blocked
|
|
155
|
+
- files-read:
|
|
156
|
+
- <repo-relative path read through tools>
|
|
102
157
|
- artifacts:
|
|
103
158
|
- <evidence-type>: <concrete pointer>
|
|
104
159
|
- <evidence-type>: <concrete pointer>
|
|
@@ -110,6 +165,7 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
110
165
|
- `risk`: low|medium|high|critical
|
|
111
166
|
- `required-artifacts`: list
|
|
112
167
|
- `required-reviewers`: list of agent names
|
|
168
|
+
- `context-manifest-draft`: allowed paths and agent work packets based only on `project-map.md` and `contracts-index.md`
|
|
113
169
|
|
|
114
170
|
### Rules
|
|
115
171
|
- NEVER omit this log file. `cdd-kit gate` rejects changes whose agent-log
|
|
@@ -56,6 +56,12 @@ CI/CD is mandatory. Every change must have a `ci-gates.md` plan, even if the pla
|
|
|
56
56
|
mergeable / blocked / informational-risk
|
|
57
57
|
```
|
|
58
58
|
|
|
59
|
+
## Read scope
|
|
60
|
+
|
|
61
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
62
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
63
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
64
|
+
|
|
59
65
|
## Machine-Verifiable Evidence
|
|
60
66
|
|
|
61
67
|
After completing your task, write or append to `specs/changes/<change-id>/agent-log/<your-agent-name>.md`
|
|
@@ -66,6 +72,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
66
72
|
- change-id: <id>
|
|
67
73
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
68
74
|
- status: complete | needs-review | blocked
|
|
75
|
+
- files-read:
|
|
76
|
+
- <repo-relative path read through tools>
|
|
69
77
|
- artifacts:
|
|
70
78
|
- <evidence-type>: <concrete pointer>
|
|
71
79
|
- <evidence-type>: <concrete pointer>
|
|
@@ -87,3 +95,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
87
95
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
88
96
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
89
97
|
without a pointer.
|
|
98
|
+
|
|
99
|
+
## Read scope
|
|
100
|
+
|
|
101
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
102
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
103
|
+
|
|
104
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -55,6 +55,12 @@ Record dependency or migration impacts in `contracts.md` only as contract-level
|
|
|
55
55
|
approved / changes-required
|
|
56
56
|
```
|
|
57
57
|
|
|
58
|
+
## Read scope
|
|
59
|
+
|
|
60
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
61
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
62
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
63
|
+
|
|
58
64
|
## Machine-Verifiable Evidence
|
|
59
65
|
|
|
60
66
|
After completing your task, include an **## Agent Log** section at the end of your response with this exact structure (lines starting with `- ` are required). The calling skill will write this block to `specs/changes/<change-id>/agent-log/contract-reviewer.md`.
|
|
@@ -65,6 +71,8 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
65
71
|
- change-id: <id>
|
|
66
72
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
67
73
|
- status: complete | needs-review | blocked
|
|
74
|
+
- files-read:
|
|
75
|
+
- <repo-relative path read through tools>
|
|
68
76
|
- artifacts:
|
|
69
77
|
- <evidence-type>: <concrete pointer>
|
|
70
78
|
- <evidence-type>: <concrete pointer>
|
|
@@ -86,3 +94,10 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
86
94
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
87
95
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
88
96
|
without a pointer.
|
|
97
|
+
|
|
98
|
+
## Read scope
|
|
99
|
+
|
|
100
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
101
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
102
|
+
|
|
103
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -72,6 +72,8 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
72
72
|
- change-id: <id>
|
|
73
73
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
74
74
|
- status: complete | needs-review | blocked
|
|
75
|
+
- files-read:
|
|
76
|
+
- <repo-relative path read through tools>
|
|
75
77
|
- artifacts:
|
|
76
78
|
- <evidence-type>: <concrete pointer>
|
|
77
79
|
- <evidence-type>: <concrete pointer>
|
|
@@ -33,6 +33,12 @@ Your tests must prove that real user journeys and realistic failure modes behave
|
|
|
33
33
|
|
|
34
34
|
Record test files, scenarios, fixtures/mocks, commands, screenshots/videos, and mutation checks.
|
|
35
35
|
|
|
36
|
+
## Read scope
|
|
37
|
+
|
|
38
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
39
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
40
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
41
|
+
|
|
36
42
|
## Machine-Verifiable Evidence
|
|
37
43
|
|
|
38
44
|
After completing your task, write or append to `specs/changes/<change-id>/agent-log/<your-agent-name>.md`
|
|
@@ -43,6 +49,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
43
49
|
- change-id: <id>
|
|
44
50
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
45
51
|
- status: complete | needs-review | blocked
|
|
52
|
+
- files-read:
|
|
53
|
+
- <repo-relative path read through tools>
|
|
46
54
|
- artifacts:
|
|
47
55
|
- <evidence-type>: <concrete pointer>
|
|
48
56
|
- <evidence-type>: <concrete pointer>
|
|
@@ -64,3 +72,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
64
72
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
65
73
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
66
74
|
without a pointer.
|
|
75
|
+
|
|
76
|
+
## Read scope
|
|
77
|
+
|
|
78
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
79
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
80
|
+
|
|
81
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -28,6 +28,12 @@ Before editing, read the change artifacts, API contract, CSS/UI contract, compon
|
|
|
28
28
|
- Bundle size — dynamic import heavy routes; avoid full lodash / moment imports.
|
|
29
29
|
- Note: avoid double-submit / rapid-action implementation bugs — but do not author monkey tests here; that is `monkey-test-engineer`'s scope.
|
|
30
30
|
|
|
31
|
+
## Read scope
|
|
32
|
+
|
|
33
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
34
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
35
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
36
|
+
|
|
31
37
|
## Handoff
|
|
32
38
|
|
|
33
39
|
Report changed screens, component states covered, screenshots/videos if generated, tests added, commands run, and remaining UI risks.
|
|
@@ -47,6 +53,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
47
53
|
- change-id: <id>
|
|
48
54
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
49
55
|
- status: complete | needs-review | blocked
|
|
56
|
+
- files-read:
|
|
57
|
+
- <repo-relative path read through tools>
|
|
50
58
|
- artifacts:
|
|
51
59
|
- <evidence-type>: <concrete pointer>
|
|
52
60
|
- <evidence-type>: <concrete pointer>
|
|
@@ -68,3 +76,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
68
76
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
69
77
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
70
78
|
without a pointer.
|
|
79
|
+
|
|
80
|
+
## Read scope
|
|
81
|
+
|
|
82
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
83
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
84
|
+
|
|
85
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -36,6 +36,12 @@ Use fuzz payloads, Playwright action sequences, property-based tests, and target
|
|
|
36
36
|
- Adversarial corpora — common boundaries (empty, max-int, NaN, Unicode RTL, Zero-Width Joiner, surrogate pairs, BOM); SQL/JS injection strings.
|
|
37
37
|
- Determinism — every monkey test must seed its randomness; record the seed on failure for replay.
|
|
38
38
|
|
|
39
|
+
## Read scope
|
|
40
|
+
|
|
41
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
42
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
43
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
44
|
+
|
|
39
45
|
## Machine-Verifiable Evidence
|
|
40
46
|
|
|
41
47
|
After completing your task, write or append to `specs/changes/<change-id>/agent-log/<your-agent-name>.md`
|
|
@@ -46,6 +52,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
46
52
|
- change-id: <id>
|
|
47
53
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
48
54
|
- status: complete | needs-review | blocked
|
|
55
|
+
- files-read:
|
|
56
|
+
- <repo-relative path read through tools>
|
|
49
57
|
- artifacts:
|
|
50
58
|
- <evidence-type>: <concrete pointer>
|
|
51
59
|
- <evidence-type>: <concrete pointer>
|
|
@@ -66,3 +74,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
66
74
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
67
75
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
68
76
|
without a pointer.
|
|
77
|
+
|
|
78
|
+
## Read scope
|
|
79
|
+
|
|
80
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
81
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
82
|
+
|
|
83
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -67,6 +67,12 @@ Invoke `spec-drift-auditor` at the following points (do not wait for issues to s
|
|
|
67
67
|
approved / blocked / approved-with-risk
|
|
68
68
|
```
|
|
69
69
|
|
|
70
|
+
## Read scope
|
|
71
|
+
|
|
72
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
73
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
74
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
75
|
+
|
|
70
76
|
## Machine-Verifiable Evidence
|
|
71
77
|
|
|
72
78
|
After completing your task, include an **## Agent Log** section at the end of your response with this exact structure (lines starting with `- ` are required). The calling skill will write this block to `specs/changes/<change-id>/agent-log/qa-reviewer.md`.
|
|
@@ -77,6 +83,8 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
77
83
|
- change-id: <id>
|
|
78
84
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
79
85
|
- status: complete | needs-review | blocked
|
|
86
|
+
- files-read:
|
|
87
|
+
- <repo-relative path read through tools>
|
|
80
88
|
- artifacts:
|
|
81
89
|
- <evidence-type>: <concrete pointer>
|
|
82
90
|
- <evidence-type>: <concrete pointer>
|
|
@@ -99,3 +107,10 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
99
107
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
100
108
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
101
109
|
without a pointer.
|
|
110
|
+
|
|
111
|
+
## Read scope
|
|
112
|
+
|
|
113
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
114
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
115
|
+
|
|
116
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -92,6 +92,8 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
92
92
|
- change-id: <id>
|
|
93
93
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
94
94
|
- status: complete | needs-review | blocked
|
|
95
|
+
- files-read:
|
|
96
|
+
- <repo-relative path read through tools>
|
|
95
97
|
- artifacts:
|
|
96
98
|
- <evidence-type>: <concrete pointer>
|
|
97
99
|
- <evidence-type>: <concrete pointer>
|
|
@@ -85,6 +85,12 @@ Your output goes into `specs/changes/<id>/design.md`. It must capture architectu
|
|
|
85
85
|
Reference file paths instead of duplicating implementation content.
|
|
86
86
|
Target: `design.md` ≤ 150 lines.
|
|
87
87
|
|
|
88
|
+
## Read scope
|
|
89
|
+
|
|
90
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
91
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
92
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
93
|
+
|
|
88
94
|
## Machine-Verifiable Evidence
|
|
89
95
|
|
|
90
96
|
After completing your task, write or append to `specs/changes/<change-id>/agent-log/<your-agent-name>.md`
|
|
@@ -95,6 +101,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
95
101
|
- change-id: <id>
|
|
96
102
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
97
103
|
- status: complete | needs-review | blocked
|
|
104
|
+
- files-read:
|
|
105
|
+
- <repo-relative path read through tools>
|
|
98
106
|
- artifacts:
|
|
99
107
|
- <evidence-type>: <concrete pointer>
|
|
100
108
|
- <evidence-type>: <concrete pointer>
|
|
@@ -116,3 +124,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
116
124
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
117
125
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
118
126
|
without a pointer.
|
|
127
|
+
|
|
128
|
+
## Read scope
|
|
129
|
+
|
|
130
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
131
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
132
|
+
|
|
133
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -61,6 +61,8 @@ Use this exact structure (lines starting with `- ` are required):
|
|
|
61
61
|
- audit-id: <YYYY-MM-DD>-drift
|
|
62
62
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
63
63
|
- status: complete | needs-review | blocked
|
|
64
|
+
- files-read:
|
|
65
|
+
- <repo-relative path read through tools>
|
|
64
66
|
- artifacts:
|
|
65
67
|
- <evidence-type>: <concrete pointer>
|
|
66
68
|
- <evidence-type>: <concrete pointer>
|
|
@@ -60,6 +60,12 @@ Use realistic load profiles rather than arbitrary request loops.
|
|
|
60
60
|
...
|
|
61
61
|
```
|
|
62
62
|
|
|
63
|
+
## Read scope
|
|
64
|
+
|
|
65
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
66
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
67
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
68
|
+
|
|
63
69
|
## Machine-Verifiable Evidence
|
|
64
70
|
|
|
65
71
|
After completing your task, write or append to `specs/changes/<change-id>/agent-log/<your-agent-name>.md`
|
|
@@ -70,6 +76,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
70
76
|
- change-id: <id>
|
|
71
77
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
72
78
|
- status: complete | needs-review | blocked
|
|
79
|
+
- files-read:
|
|
80
|
+
- <repo-relative path read through tools>
|
|
73
81
|
- artifacts:
|
|
74
82
|
- <evidence-type>: <concrete pointer>
|
|
75
83
|
- <evidence-type>: <concrete pointer>
|
|
@@ -91,3 +99,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
91
99
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
92
100
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
93
101
|
without a pointer.
|
|
102
|
+
|
|
103
|
+
## Read scope
|
|
104
|
+
|
|
105
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
106
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
107
|
+
|
|
108
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -64,6 +64,12 @@ Your output goes into `specs/changes/<id>/test-plan.md`. It must answer WHAT to
|
|
|
64
64
|
Implementation detail belongs in the test files, not in test-plan.md.
|
|
65
65
|
Target: `test-plan.md` ≤ 100 lines.
|
|
66
66
|
|
|
67
|
+
## Read scope
|
|
68
|
+
|
|
69
|
+
- Allowed: `contracts/`, `tests/`, `src/`, and the change directory provided in `CURRENT_CHANGE_ID` at the top of your prompt
|
|
70
|
+
- **Before reading any file**: confirm the CURRENT_CHANGE_ID from your prompt header. If not provided, ask the caller: "What is the current change-id?" before proceeding.
|
|
71
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
72
|
+
|
|
67
73
|
## Machine-Verifiable Evidence
|
|
68
74
|
|
|
69
75
|
After completing your task, write or append to `specs/changes/<change-id>/agent-log/<your-agent-name>.md`
|
|
@@ -74,6 +80,8 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
74
80
|
- change-id: <id>
|
|
75
81
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
76
82
|
- status: complete | needs-review | blocked
|
|
83
|
+
- files-read:
|
|
84
|
+
- <repo-relative path read through tools>
|
|
77
85
|
- artifacts:
|
|
78
86
|
- <evidence-type>: <concrete pointer>
|
|
79
87
|
- <evidence-type>: <concrete pointer>
|
|
@@ -95,3 +103,10 @@ with this exact structure (lines starting with `- ` are required):
|
|
|
95
103
|
- Evidence must be concrete: file:line, command name + last-10-line stdout,
|
|
96
104
|
contract path + section, test name, etc. NEVER write "verified" or "OK"
|
|
97
105
|
without a pointer.
|
|
106
|
+
|
|
107
|
+
## Read scope
|
|
108
|
+
|
|
109
|
+
- Allowed: `contracts/`, `tests/`, `src/`, `specs/changes/<current-change-id>/`
|
|
110
|
+
- Forbidden: other `specs/changes/` directories, `specs/archive/`
|
|
111
|
+
|
|
112
|
+
Read only the current change's directory. Do NOT glob `specs/changes/**` — it pulls historical data into context and wastes tokens.
|
|
@@ -59,6 +59,8 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
59
59
|
- change-id: <id>
|
|
60
60
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
61
61
|
- status: complete | needs-review | blocked
|
|
62
|
+
- files-read:
|
|
63
|
+
- <repo-relative path read through tools>
|
|
62
64
|
- artifacts:
|
|
63
65
|
- <evidence-type>: <concrete pointer>
|
|
64
66
|
- <evidence-type>: <concrete pointer>
|
|
@@ -61,6 +61,8 @@ After completing your task, include an **## Agent Log** section at the end of yo
|
|
|
61
61
|
- change-id: <id>
|
|
62
62
|
- timestamp: <ISO 8601, e.g. 2026-04-27T14:30:00Z>
|
|
63
63
|
- status: complete | needs-review | blocked
|
|
64
|
+
- files-read:
|
|
65
|
+
- <repo-relative path read through tools>
|
|
64
66
|
- artifacts:
|
|
65
67
|
- <evidence-type>: <concrete pointer>
|
|
66
68
|
- <evidence-type>: <concrete pointer>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"forbiddenPaths": [
|
|
3
|
+
".claude/worktrees/**",
|
|
4
|
+
".git/**",
|
|
5
|
+
"node_modules/**",
|
|
6
|
+
"dist/**",
|
|
7
|
+
"build/**",
|
|
8
|
+
"assets/**",
|
|
9
|
+
"specs/archive/**",
|
|
10
|
+
"specs/changes/*"
|
|
11
|
+
],
|
|
12
|
+
"contextExpansion": {
|
|
13
|
+
"mode": "auto-safe",
|
|
14
|
+
"autoApprovePatterns": [
|
|
15
|
+
"src/**",
|
|
16
|
+
"tests/**",
|
|
17
|
+
"contracts/**",
|
|
18
|
+
"specs/changes/<current-change-id>/**"
|
|
19
|
+
]
|
|
20
|
+
},
|
|
21
|
+
"audit": {
|
|
22
|
+
"requireFilesRead": true,
|
|
23
|
+
"unknownFilesRead": "warn-for-legacy-fail-for-new"
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
contract: business
|
|
3
|
+
summary: Business decision tables, rule inventory, and change policy for behavior updates.
|
|
4
|
+
owner: application-team
|
|
5
|
+
surface: domain-behavior
|
|
3
6
|
schema-version: 0.1.0
|
|
4
7
|
last-changed: 2026-04-27
|
|
5
8
|
breaking-change-policy: deprecate-2-minors
|