@acrasie/dev-flow 0.0.0-stage → 1.0.1

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 (58) hide show
  1. package/.codex-plugin/plugin.json +20 -0
  2. package/LICENSE +21 -0
  3. package/README.md +181 -2
  4. package/dist/codex-dev-flow.mjs +3 -0
  5. package/dist/dev-flow.mjs +241 -0
  6. package/docs/adr/0001-hybrid-portable-workflow.md +23 -0
  7. package/docs/adr/0002-share-an-invalidable-context-capsule.md +55 -0
  8. package/docs/adr/0004-scale-assurance-lanes-by-applicable-risk.md +36 -0
  9. package/docs/adr/0006-make-intake-adaptive-user-authoritative-and-token-efficient.md +76 -0
  10. package/docs/adr/0007-collect-opt-in-local-benchmark-feedback.md +82 -0
  11. package/docs/adr/0008-automate-maintainer-releases-with-an-interactive-bun-workflow.md +121 -0
  12. package/docs/adr/0009-separate-intake-decisions-from-shape-discovery.md +200 -0
  13. package/docs/adr/0010-choose-quick-or-plan-after-discovery.md +161 -0
  14. package/docs/adr/0011-separate-fast-local-and-authoritative-ci-quality-gates.md +49 -0
  15. package/docs/adr/0012-use-bun-test-and-require-node-24.md +41 -0
  16. package/docs/adr/0013-layer-source-distribution-and-runtime-tests.md +42 -0
  17. package/docs/adr/0014-ratchet-source-coverage-with-bun.md +51 -0
  18. package/docs/adr/0015-split-fast-and-type-aware-linting.md +41 -0
  19. package/docs/adr/0016-use-husky-with-a-tested-bun-staged-file-adapter.md +45 -0
  20. package/docs/adr/0017-format-conservatively-with-oxfmt.md +45 -0
  21. package/docs/adr/0018-use-a-high-signal-oxlint-policy.md +53 -0
  22. package/docs/adr/0019-gate-deterministic-size-and-observe-timing.md +44 -0
  23. package/docs/adr/0020-support-linux-and-macos-with-targeted-ci.md +41 -0
  24. package/docs/adr/0021-randomize-tests-without-retries.md +35 -0
  25. package/docs/adr/0022-use-one-root-bun-workspace.md +41 -0
  26. package/docs/adr/0024-make-gate-a-minimal-plan-approval.md +74 -0
  27. package/docs/adr/0025-end-the-lifecycle-after-assure.md +55 -0
  28. package/docs/adr/0026-keep-intake-product-stable-and-interview-shape-by-dependency.md +151 -0
  29. package/docs/adr/0027-add-agentic-project-init-and-versioned-engineering-profiles.md +147 -0
  30. package/docs/adr/0028-make-public-documentation-user-first-and-current.md +65 -0
  31. package/docs/adr/0029-make-build-a-native-execution-boundary.md +51 -0
  32. package/docs/adr/0030-unify-product-domain-and-technical-design-interviews.md +240 -0
  33. package/docs/adr/0031-make-assure-the-success-boundary.md +205 -0
  34. package/docs/artifacts.md +47 -0
  35. package/docs/baselines/2026-07-18-p0-lifecycle.json +142 -0
  36. package/docs/design.md +101 -0
  37. package/docs/getting-started.md +204 -0
  38. package/docs/glossary/dev-flow.md +527 -0
  39. package/docs/lifecycle-contract.md +189 -0
  40. package/docs/lifecycle-contract.projection.json +931 -0
  41. package/docs/metrics-protocol.md +113 -0
  42. package/docs/project-profile-contract.md +157 -0
  43. package/docs/runbooks/maintainer-release.md +291 -0
  44. package/docs/target-intake-shape-contract.md +416 -0
  45. package/package.json +68 -4
  46. package/schemas/config.schema.json +104 -0
  47. package/schemas/policy.schema.json +17 -0
  48. package/schemas/project-init-state.schema.json +159 -0
  49. package/schemas/project-profile-local.schema.json +53 -0
  50. package/schemas/project-profile.schema.json +285 -0
  51. package/schemas/state.schema.json +826 -0
  52. package/skills/debug-root-cause/SKILL.md +16 -0
  53. package/skills/design-decisions/SKILL.md +24 -0
  54. package/skills/dev-flow/SKILL.md +306 -0
  55. package/skills/dev-flow/agents/openai.yaml +6 -0
  56. package/skills/discover-change/SKILL.md +31 -0
  57. package/skills/plan-change/SKILL.md +29 -0
  58. package/skills/review-change/SKILL.md +21 -0
@@ -0,0 +1,159 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "Dev Flow agentic Project INIT session state",
4
+ "type": "object",
5
+ "additionalProperties": false,
6
+ "required": [
7
+ "schemaVersion",
8
+ "sessionId",
9
+ "profileId",
10
+ "revision",
11
+ "status",
12
+ "decisions",
13
+ "staleDecisionKeys",
14
+ "updatedAt"
15
+ ],
16
+ "properties": {
17
+ "schemaVersion": { "type": "integer", "const": 1 },
18
+ "sessionId": { "$ref": "#/$defs/id" },
19
+ "profileId": { "$ref": "#/$defs/id" },
20
+ "revision": { "type": "integer", "minimum": 1 },
21
+ "status": {
22
+ "type": "string",
23
+ "enum": ["discovering", "awaiting_decision", "awaiting_approval", "blocked"]
24
+ },
25
+ "decisions": {
26
+ "type": "array",
27
+ "maxItems": 512,
28
+ "items": {
29
+ "type": "object",
30
+ "additionalProperties": false,
31
+ "required": ["key", "value", "source", "sourceRefs", "dependsOn"],
32
+ "properties": {
33
+ "key": { "$ref": "#/$defs/key" },
34
+ "value": { "$ref": "#/$defs/text" },
35
+ "source": {
36
+ "type": "string",
37
+ "enum": ["user", "repository", "policy", "official_documentation", "user_asserted"]
38
+ },
39
+ "sourceRefs": { "$ref": "#/$defs/refs" },
40
+ "dependsOn": {
41
+ "type": "array",
42
+ "uniqueItems": true,
43
+ "maxItems": 64,
44
+ "items": { "$ref": "#/$defs/key" }
45
+ }
46
+ }
47
+ }
48
+ },
49
+ "activeQuestion": {
50
+ "type": "object",
51
+ "additionalProperties": false,
52
+ "required": [
53
+ "id",
54
+ "decisionKey",
55
+ "prompt",
56
+ "evidenceRefs",
57
+ "options",
58
+ "recommendedOptionId",
59
+ "recommendationBasis",
60
+ "recommendationConfidence",
61
+ "parentDecisionKeys",
62
+ "directConsequences"
63
+ ],
64
+ "properties": {
65
+ "id": { "$ref": "#/$defs/id" },
66
+ "decisionKey": { "$ref": "#/$defs/key" },
67
+ "prompt": { "$ref": "#/$defs/text" },
68
+ "evidenceRefs": { "$ref": "#/$defs/refs" },
69
+ "options": {
70
+ "type": "array",
71
+ "minItems": 2,
72
+ "maxItems": 3,
73
+ "items": {
74
+ "type": "object",
75
+ "additionalProperties": false,
76
+ "required": ["id", "label", "impact"],
77
+ "properties": {
78
+ "id": { "$ref": "#/$defs/id" },
79
+ "label": { "type": "string", "minLength": 1, "maxLength": 200 },
80
+ "impact": { "$ref": "#/$defs/text" }
81
+ }
82
+ }
83
+ },
84
+ "recommendedOptionId": { "$ref": "#/$defs/id" },
85
+ "recommendationBasis": { "$ref": "#/$defs/text" },
86
+ "recommendationConfidence": {
87
+ "type": "string",
88
+ "enum": ["high", "medium", "low"]
89
+ },
90
+ "parentDecisionKeys": {
91
+ "type": "array",
92
+ "uniqueItems": true,
93
+ "maxItems": 64,
94
+ "items": { "$ref": "#/$defs/key" }
95
+ },
96
+ "directConsequences": {
97
+ "type": "array",
98
+ "maxItems": 16,
99
+ "items": { "$ref": "#/$defs/text" }
100
+ }
101
+ }
102
+ },
103
+ "staleDecisionKeys": {
104
+ "type": "array",
105
+ "uniqueItems": true,
106
+ "maxItems": 512,
107
+ "items": { "$ref": "#/$defs/key" }
108
+ },
109
+ "candidateContentDigest": { "$ref": "#/$defs/digest" },
110
+ "blockedReason": { "$ref": "#/$defs/text" },
111
+ "updatedAt": { "$ref": "#/$defs/timestamp" }
112
+ },
113
+ "$defs": {
114
+ "id": {
115
+ "type": "string",
116
+ "minLength": 1,
117
+ "maxLength": 128,
118
+ "pattern": "^[a-z0-9][a-z0-9._-]*$"
119
+ },
120
+ "key": {
121
+ "type": "string",
122
+ "minLength": 1,
123
+ "maxLength": 128,
124
+ "pattern": "^[a-z0-9][a-z0-9._/-]*$"
125
+ },
126
+ "text": { "type": "string", "minLength": 1, "maxLength": 2000 },
127
+ "refs": {
128
+ "type": "array",
129
+ "maxItems": 64,
130
+ "uniqueItems": true,
131
+ "items": { "type": "string", "minLength": 1, "maxLength": 500 }
132
+ },
133
+ "digest": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
134
+ "timestamp": {
135
+ "type": "string",
136
+ "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{3})?Z$"
137
+ }
138
+ },
139
+ "allOf": [
140
+ {
141
+ "if": { "properties": { "status": { "const": "awaiting_decision" } } },
142
+ "then": { "properties": { "activeQuestion": true }, "required": ["activeQuestion"] },
143
+ "else": { "not": { "required": ["activeQuestion"] } }
144
+ },
145
+ {
146
+ "if": { "properties": { "status": { "const": "awaiting_approval" } } },
147
+ "then": {
148
+ "properties": { "candidateContentDigest": true },
149
+ "required": ["candidateContentDigest"]
150
+ },
151
+ "else": { "not": { "required": ["candidateContentDigest"] } }
152
+ },
153
+ {
154
+ "if": { "properties": { "status": { "const": "blocked" } } },
155
+ "then": { "properties": { "blockedReason": true }, "required": ["blockedReason"] },
156
+ "else": { "not": { "required": ["blockedReason"] } }
157
+ }
158
+ ]
159
+ }
@@ -0,0 +1,53 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "Dev Flow local project engineering profile overlay",
4
+ "type": "object",
5
+ "additionalProperties": false,
6
+ "required": ["schemaVersion", "profileId", "servicePaths", "preferences"],
7
+ "properties": {
8
+ "schemaVersion": { "type": "integer", "const": 1 },
9
+ "profileId": { "$ref": "#/$defs/id" },
10
+ "sharedContentDigest": { "$ref": "#/$defs/digest" },
11
+ "servicePaths": {
12
+ "type": "array",
13
+ "maxItems": 128,
14
+ "items": {
15
+ "type": "object",
16
+ "additionalProperties": false,
17
+ "required": ["serviceId", "path"],
18
+ "properties": {
19
+ "serviceId": { "$ref": "#/$defs/id" },
20
+ "path": { "type": "string", "minLength": 1, "maxLength": 2000 }
21
+ }
22
+ }
23
+ },
24
+ "preferences": {
25
+ "type": "array",
26
+ "maxItems": 128,
27
+ "items": {
28
+ "type": "object",
29
+ "additionalProperties": false,
30
+ "required": ["key", "value"],
31
+ "properties": {
32
+ "key": { "$ref": "#/$defs/key" },
33
+ "value": { "type": "string", "minLength": 1, "maxLength": 2000 }
34
+ }
35
+ }
36
+ }
37
+ },
38
+ "$defs": {
39
+ "id": {
40
+ "type": "string",
41
+ "minLength": 1,
42
+ "maxLength": 64,
43
+ "pattern": "^[a-z0-9][a-z0-9._-]*$"
44
+ },
45
+ "key": {
46
+ "type": "string",
47
+ "minLength": 1,
48
+ "maxLength": 128,
49
+ "pattern": "^[a-z0-9][a-z0-9._/-]*$"
50
+ },
51
+ "digest": { "type": "string", "pattern": "^[a-f0-9]{64}$" }
52
+ }
53
+ }
@@ -0,0 +1,285 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "Dev Flow shared project engineering profile",
4
+ "type": "object",
5
+ "additionalProperties": false,
6
+ "required": ["schemaVersion", "profileId", "revision", "contentDigest", "content", "approval"],
7
+ "properties": {
8
+ "schemaVersion": { "type": "integer", "const": 1 },
9
+ "profileId": { "$ref": "#/$defs/id" },
10
+ "revision": { "type": "integer", "minimum": 1 },
11
+ "contentDigest": { "$ref": "#/$defs/digest" },
12
+ "content": {
13
+ "type": "object",
14
+ "additionalProperties": false,
15
+ "required": ["project", "stack", "topology", "decisions", "diagramRefs"],
16
+ "properties": {
17
+ "project": {
18
+ "type": "object",
19
+ "additionalProperties": false,
20
+ "required": ["id", "name"],
21
+ "properties": {
22
+ "id": { "$ref": "#/$defs/id" },
23
+ "name": { "$ref": "#/$defs/text" }
24
+ }
25
+ },
26
+ "stack": {
27
+ "type": "array",
28
+ "minItems": 1,
29
+ "maxItems": 64,
30
+ "items": {
31
+ "type": "object",
32
+ "additionalProperties": false,
33
+ "required": ["id", "role", "sourceRefs"],
34
+ "properties": {
35
+ "id": { "$ref": "#/$defs/id" },
36
+ "role": { "$ref": "#/$defs/text" },
37
+ "version": { "$ref": "#/$defs/shortText" },
38
+ "sourceRefs": { "$ref": "#/$defs/sourceRefs" }
39
+ }
40
+ }
41
+ },
42
+ "topology": {
43
+ "type": "object",
44
+ "additionalProperties": false,
45
+ "required": ["rootServiceId", "services"],
46
+ "properties": {
47
+ "rootServiceId": { "$ref": "#/$defs/id" },
48
+ "services": {
49
+ "type": "array",
50
+ "minItems": 1,
51
+ "maxItems": 128,
52
+ "items": {
53
+ "type": "object",
54
+ "additionalProperties": false,
55
+ "required": ["id", "responsibility", "dependencies", "contracts", "sourceRefs"],
56
+ "properties": {
57
+ "id": { "$ref": "#/$defs/id" },
58
+ "responsibility": { "$ref": "#/$defs/text" },
59
+ "dependencies": {
60
+ "type": "array",
61
+ "uniqueItems": true,
62
+ "maxItems": 64,
63
+ "items": { "$ref": "#/$defs/id" }
64
+ },
65
+ "contracts": {
66
+ "type": "array",
67
+ "uniqueItems": true,
68
+ "maxItems": 64,
69
+ "items": { "$ref": "#/$defs/text" }
70
+ },
71
+ "profileRef": { "$ref": "#/$defs/profileRef" },
72
+ "sourceRefs": { "$ref": "#/$defs/sourceRefs" }
73
+ }
74
+ }
75
+ }
76
+ }
77
+ },
78
+ "decisions": {
79
+ "type": "array",
80
+ "minItems": 1,
81
+ "maxItems": 512,
82
+ "items": {
83
+ "type": "object",
84
+ "additionalProperties": false,
85
+ "required": [
86
+ "key",
87
+ "category",
88
+ "value",
89
+ "rationale",
90
+ "provenance",
91
+ "sourceFingerprints",
92
+ "dependsOn"
93
+ ],
94
+ "properties": {
95
+ "key": { "$ref": "#/$defs/key" },
96
+ "category": {
97
+ "type": "string",
98
+ "enum": [
99
+ "stack",
100
+ "source_structure",
101
+ "architecture",
102
+ "dependency_direction",
103
+ "naming",
104
+ "error_handling",
105
+ "testing",
106
+ "quality",
107
+ "frontend",
108
+ "api",
109
+ "data",
110
+ "security",
111
+ "concurrency",
112
+ "performance",
113
+ "compatibility",
114
+ "migration",
115
+ "observability",
116
+ "deployment",
117
+ "rollback",
118
+ "operations"
119
+ ]
120
+ },
121
+ "value": { "$ref": "#/$defs/text" },
122
+ "rationale": { "$ref": "#/$defs/text" },
123
+ "provenance": {
124
+ "type": "object",
125
+ "additionalProperties": false,
126
+ "required": ["kind", "sourceRefs", "capturedAt"],
127
+ "properties": {
128
+ "kind": {
129
+ "type": "string",
130
+ "enum": [
131
+ "user",
132
+ "repository",
133
+ "policy",
134
+ "official_documentation",
135
+ "user_asserted"
136
+ ]
137
+ },
138
+ "sourceRefs": { "$ref": "#/$defs/sourceRefs" },
139
+ "capturedAt": { "$ref": "#/$defs/timestamp" }
140
+ }
141
+ },
142
+ "sourceFingerprints": {
143
+ "type": "array",
144
+ "maxItems": 64,
145
+ "items": {
146
+ "type": "object",
147
+ "additionalProperties": false,
148
+ "required": ["sourceRef", "value"],
149
+ "properties": {
150
+ "sourceRef": { "$ref": "#/$defs/sourceRef" },
151
+ "value": { "$ref": "#/$defs/fingerprint" }
152
+ }
153
+ }
154
+ },
155
+ "dependsOn": {
156
+ "type": "array",
157
+ "uniqueItems": true,
158
+ "maxItems": 64,
159
+ "items": { "$ref": "#/$defs/key" }
160
+ }
161
+ }
162
+ }
163
+ },
164
+ "domainDocumentation": {
165
+ "type": "object",
166
+ "additionalProperties": false,
167
+ "required": [
168
+ "contextMode",
169
+ "glossaryPath",
170
+ "rulesPath",
171
+ "adrDirectory",
172
+ "language",
173
+ "identityConvention",
174
+ "linkConvention",
175
+ "sourceFingerprints"
176
+ ],
177
+ "properties": {
178
+ "contextMode": { "enum": ["single", "multiple"] },
179
+ "glossaryPath": { "$ref": "#/$defs/repositoryPath" },
180
+ "rulesPath": { "$ref": "#/$defs/repositoryPath" },
181
+ "adrDirectory": { "$ref": "#/$defs/repositoryPath" },
182
+ "contextMapPath": { "$ref": "#/$defs/repositoryPath" },
183
+ "language": { "$ref": "#/$defs/shortText" },
184
+ "identityConvention": { "$ref": "#/$defs/text" },
185
+ "linkConvention": { "$ref": "#/$defs/text" },
186
+ "sourceFingerprints": {
187
+ "type": "array",
188
+ "maxItems": 64,
189
+ "items": {
190
+ "type": "object",
191
+ "additionalProperties": false,
192
+ "required": ["sourceRef", "value"],
193
+ "properties": {
194
+ "sourceRef": { "$ref": "#/$defs/sourceRef" },
195
+ "value": { "$ref": "#/$defs/fingerprint" }
196
+ }
197
+ }
198
+ }
199
+ },
200
+ "allOf": [
201
+ {
202
+ "if": {
203
+ "properties": { "contextMode": { "const": "multiple" } },
204
+ "required": ["contextMode"]
205
+ },
206
+ "then": {
207
+ "properties": { "contextMapPath": {} },
208
+ "required": ["contextMapPath"]
209
+ }
210
+ }
211
+ ]
212
+ },
213
+ "diagramRefs": {
214
+ "type": "array",
215
+ "uniqueItems": true,
216
+ "maxItems": 32,
217
+ "items": { "$ref": "#/$defs/repositoryPath" }
218
+ }
219
+ }
220
+ },
221
+ "approval": {
222
+ "type": "object",
223
+ "additionalProperties": false,
224
+ "required": [
225
+ "schemaVersion",
226
+ "actor",
227
+ "approvedAt",
228
+ "profileId",
229
+ "revision",
230
+ "contentDigest",
231
+ "receiptDigest"
232
+ ],
233
+ "properties": {
234
+ "schemaVersion": { "type": "integer", "const": 1 },
235
+ "actor": { "type": "string", "const": "user" },
236
+ "approvedAt": { "$ref": "#/$defs/timestamp" },
237
+ "profileId": { "$ref": "#/$defs/id" },
238
+ "revision": { "type": "integer", "minimum": 1 },
239
+ "contentDigest": { "$ref": "#/$defs/digest" },
240
+ "receiptDigest": { "$ref": "#/$defs/digest" }
241
+ }
242
+ }
243
+ },
244
+ "$defs": {
245
+ "id": {
246
+ "type": "string",
247
+ "minLength": 1,
248
+ "maxLength": 64,
249
+ "pattern": "^[a-z0-9][a-z0-9._-]*$"
250
+ },
251
+ "key": {
252
+ "type": "string",
253
+ "minLength": 1,
254
+ "maxLength": 128,
255
+ "pattern": "^[a-z0-9][a-z0-9._/-]*$"
256
+ },
257
+ "shortText": { "type": "string", "minLength": 1, "maxLength": 128 },
258
+ "text": { "type": "string", "minLength": 1, "maxLength": 2000 },
259
+ "digest": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
260
+ "timestamp": {
261
+ "type": "string",
262
+ "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{3})?Z$"
263
+ },
264
+ "fingerprint": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
265
+ "sourceRef": { "type": "string", "minLength": 1, "maxLength": 500 },
266
+ "sourceRefs": {
267
+ "type": "array",
268
+ "minItems": 1,
269
+ "maxItems": 64,
270
+ "uniqueItems": true,
271
+ "items": { "$ref": "#/$defs/sourceRef" }
272
+ },
273
+ "repositoryPath": {
274
+ "type": "string",
275
+ "minLength": 1,
276
+ "maxLength": 500,
277
+ "pattern": "^(?!/)(?![A-Za-z]:[\\\\/])(?!.*(?:^|/)\\.\\.(?:/|$)).+$"
278
+ },
279
+ "profileRef": {
280
+ "type": "string",
281
+ "minLength": 1,
282
+ "maxLength": 500
283
+ }
284
+ }
285
+ }