@wefter/opencode 0.2.0 → 0.3.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.
Files changed (96) hide show
  1. package/CHANGELOG.md +43 -25
  2. package/LICENSE +21 -21
  3. package/README.md +128 -125
  4. package/bin/wefter.js +8 -8
  5. package/docs/ARCHITECTURE.md +75 -75
  6. package/docs/INSTALLATION.md +56 -47
  7. package/docs/ROADMAP.md +48 -0
  8. package/docs/SAFETY_MODEL.md +18 -17
  9. package/docs/SELF_AUDIT.md +37 -35
  10. package/docs/WORKFLOWS.md +17 -15
  11. package/package.json +45 -45
  12. package/schemas/documentation-audit-profile.schema.json +55 -55
  13. package/schemas/install-manifest.schema.json +42 -0
  14. package/schemas/product-shaping-config.schema.json +63 -63
  15. package/schemas/product-shaping-contract.schema.json +204 -204
  16. package/schemas/product-shaping-profile.schema.json +39 -39
  17. package/schemas/product-shaping-run-manifest.schema.json +103 -103
  18. package/schemas/run-manifest.schema.json +14 -14
  19. package/schemas/wefter.config.schema.json +62 -62
  20. package/schemas/work-unit-config.schema.json +51 -44
  21. package/schemas/work-unit-profile.schema.json +38 -38
  22. package/schemas/work-unit-review-result.schema.json +13 -13
  23. package/schemas/workflow-manifest.schema.json +31 -21
  24. package/src/cli/main.js +2937 -2646
  25. package/src/workflows/documentation-audit/README.md +37 -37
  26. package/src/workflows/documentation-audit/templates/README.md.tmpl +47 -47
  27. package/src/workflows/documentation-audit/templates/opencode/agent/wefter-doc-audit-consolidator.md.tmpl +27 -27
  28. package/src/workflows/documentation-audit/templates/opencode/agent/wefter-doc-audit-orchestrator.md.tmpl +69 -65
  29. package/src/workflows/documentation-audit/templates/opencode/agent/wefter-doc-audit-profile-builder.md.tmpl +58 -58
  30. package/src/workflows/documentation-audit/templates/opencode/agent/wefter-doc-audit-validator.md.tmpl +26 -26
  31. package/src/workflows/documentation-audit/templates/opencode/agent/wefter-doc-auditor.md.tmpl +31 -28
  32. package/src/workflows/documentation-audit/templates/opencode/skills/documentation-audit/SKILL.md.tmpl +39 -38
  33. package/src/workflows/documentation-audit/templates/prompts/auditor-prompt.md +98 -97
  34. package/src/workflows/documentation-audit/templates/prompts/consolidator-prompt.md +84 -84
  35. package/src/workflows/documentation-audit/templates/prompts/validator-prompt.md +92 -92
  36. package/src/workflows/documentation-audit/workflow.json +24 -24
  37. package/src/workflows/documentation-repair/README.md +11 -11
  38. package/src/workflows/documentation-repair/templates/opencode/agent/wefter-doc-repair-orchestrator.md.tmpl +33 -33
  39. package/src/workflows/documentation-repair/templates/opencode/agent/wefter-doc-repair-planner.md.tmpl +17 -17
  40. package/src/workflows/documentation-repair/templates/opencode/agent/wefter-doc-repair-reviewer.md.tmpl +17 -17
  41. package/src/workflows/documentation-repair/templates/opencode/agent/wefter-doc-repairer.md.tmpl +14 -14
  42. package/src/workflows/documentation-repair/templates/opencode/skills/documentation-repair/SKILL.md.tmpl +17 -17
  43. package/src/workflows/documentation-repair/templates/prompts/repair-apply-prompt.md +43 -43
  44. package/src/workflows/documentation-repair/templates/prompts/repair-plan-prompt.md +73 -73
  45. package/src/workflows/documentation-repair/templates/prompts/repair-review-prompt.md +47 -47
  46. package/src/workflows/documentation-repair/workflow.json +10 -10
  47. package/src/workflows/product-shaping/README.md +1245 -1245
  48. package/src/workflows/product-shaping/compatibility.md +33 -33
  49. package/src/workflows/product-shaping/contracts/product-spec-contract.json +250 -250
  50. package/src/workflows/product-shaping/templates/default-config.json +34 -34
  51. package/src/workflows/product-shaping/templates/default-profile.json +48 -48
  52. package/src/workflows/product-shaping/templates/documentation-audit/workflow-self-audit-auditor-prompt.md +117 -116
  53. package/src/workflows/product-shaping/templates/documentation-audit-profile.json +80 -80
  54. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-auditor.md.tmpl +22 -22
  55. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-domain-modeler.md.tmpl +31 -31
  56. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-intake-analyst.md.tmpl +31 -31
  57. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-orchestrator.md.tmpl +48 -48
  58. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-reference-researcher.md.tmpl +29 -29
  59. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-release-planner.md.tmpl +34 -34
  60. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-repairer.md.tmpl +25 -25
  61. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-shaper.md.tmpl +31 -31
  62. package/src/workflows/product-shaping/templates/opencode/agent/wefter-product-validator.md.tmpl +23 -23
  63. package/src/workflows/product-shaping/templates/opencode/skills/product-shaping/SKILL.md.tmpl +45 -45
  64. package/src/workflows/product-shaping/templates/prompts/domain-modeler-prompt.md +27 -27
  65. package/src/workflows/product-shaping/templates/prompts/intake-prompt.md +30 -30
  66. package/src/workflows/product-shaping/templates/prompts/product-auditor-prompt.md +53 -53
  67. package/src/workflows/product-shaping/templates/prompts/product-repairer-prompt.md +25 -25
  68. package/src/workflows/product-shaping/templates/prompts/product-shaper-prompt.md +26 -26
  69. package/src/workflows/product-shaping/templates/prompts/product-validator-prompt.md +55 -55
  70. package/src/workflows/product-shaping/templates/prompts/reference-research-prompt.md +25 -25
  71. package/src/workflows/product-shaping/templates/prompts/release-planner-prompt.md +34 -34
  72. package/src/workflows/product-shaping/workflow.json +33 -33
  73. package/src/workflows/technical-shaping/README.md +7 -5
  74. package/src/workflows/technical-shaping/workflow.json +14 -10
  75. package/src/workflows/work-unit-implementation/README.md +71 -71
  76. package/src/workflows/work-unit-implementation/templates/default-config.json +46 -46
  77. package/src/workflows/work-unit-implementation/templates/default-profile.json +57 -57
  78. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-orchestrator.md.tmpl +62 -62
  79. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-plan-auditor.md.tmpl +26 -26
  80. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-plan-consolidator.md.tmpl +26 -26
  81. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-plan-repairer.md.tmpl +25 -25
  82. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-plan-validator.md.tmpl +25 -25
  83. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-planner.md.tmpl +27 -27
  84. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-task-implementer.md.tmpl +30 -30
  85. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-task-reviewer.md.tmpl +28 -28
  86. package/src/workflows/work-unit-implementation/templates/opencode/agent/wefter-work-unit-validator.md.tmpl +26 -26
  87. package/src/workflows/work-unit-implementation/templates/opencode/skills/work-unit-implementation/SKILL.md.tmpl +25 -25
  88. package/src/workflows/work-unit-implementation/templates/prompts/plan-auditor-prompt.md +89 -89
  89. package/src/workflows/work-unit-implementation/templates/prompts/plan-consolidator-prompt.md +64 -64
  90. package/src/workflows/work-unit-implementation/templates/prompts/plan-repairer-prompt.md +42 -42
  91. package/src/workflows/work-unit-implementation/templates/prompts/plan-validator-prompt.md +84 -84
  92. package/src/workflows/work-unit-implementation/templates/prompts/planner-prompt.md +150 -150
  93. package/src/workflows/work-unit-implementation/templates/prompts/task-implementation-prompt.md +57 -57
  94. package/src/workflows/work-unit-implementation/templates/prompts/task-review-prompt.md +69 -69
  95. package/src/workflows/work-unit-implementation/templates/prompts/work-unit-validator-prompt.md +50 -50
  96. package/src/workflows/work-unit-implementation/workflow.json +14 -14
@@ -1,63 +1,63 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://wefter.dev/schemas/product-shaping-config.schema.json",
4
- "type": "object",
5
- "required": ["version", "workflowName", "releaseId", "specRoot", "runRoot", "contractPath", "processDocPath", "requiredFiles", "completionGate"],
6
- "properties": {
7
- "version": { "const": 1 },
8
- "workflowName": { "const": "product-shaping" },
9
- "releaseId": { "type": "string", "minLength": 1 },
10
- "specRoot": { "$ref": "#/$defs/relativePath", "default": ".wefter/specs" },
11
- "runRoot": { "$ref": "#/$defs/relativePath", "default": ".wefter/runs/product-shaping" },
12
- "contractPath": { "$ref": "#/$defs/relativePath" },
13
- "processDocPath": { "$ref": "#/$defs/relativePath" },
14
- "requiredFiles": {
15
- "type": "array",
16
- "minItems": 17,
17
- "maxItems": 17,
18
- "prefixItems": [
19
- { "const": "README.md" },
20
- { "const": "discovery/SOURCE_MATERIALS.md" },
21
- { "const": "discovery/IDEA_BRIEF.md" },
22
- { "const": "discovery/OPEN_QUESTIONS.md" },
23
- { "const": "references/README.md" },
24
- { "const": "PRODUCT_VISION.md" },
25
- { "const": "product/FEATURE_CATALOG.md" },
26
- { "const": "product/MODULE_ROADMAP.md" },
27
- { "const": "product/DOMAIN_MODEL.md" },
28
- { "const": "product/OPERATIONAL_FLOW.md" },
29
- { "const": "product/PRODUCT_DECISIONS.md" },
30
- { "const": "releases/README.md" },
31
- { "const": "releases/<release-id>/README.md" },
32
- { "const": "releases/<release-id>/SCOPE.md" },
33
- { "const": "releases/<release-id>/DOMAIN_SPEC.md" },
34
- { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" },
35
- { "const": "releases/<release-id>/DELIVERABLES.md" }
36
- ],
37
- "items": false
38
- },
39
- "completionGate": {
40
- "type": "object",
41
- "required": ["requireNoReleaseBlockingQuestions", "requireAdversarialReview", "requireFinalValidation", "readyDeliverableStatuses"],
42
- "properties": {
43
- "requireNoReleaseBlockingQuestions": { "type": "boolean" },
44
- "requireAdversarialReview": { "const": true },
45
- "requireFinalValidation": { "const": true },
46
- "readyDeliverableStatuses": {
47
- "type": "array",
48
- "minItems": 1,
49
- "items": { "enum": ["ready"] }
50
- }
51
- },
52
- "additionalProperties": false
53
- }
54
- },
55
- "additionalProperties": false,
56
- "$defs": {
57
- "relativePath": {
58
- "type": "string",
59
- "minLength": 1,
60
- "pattern": "^(?![A-Za-z]:)(?![\\\\/])(?!.*(?:^|/)\\.\\.(?:/|$))[^\\\\\r\n]+$"
61
- }
62
- }
63
- }
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://wefter.dev/schemas/product-shaping-config.schema.json",
4
+ "type": "object",
5
+ "required": ["version", "workflowName", "releaseId", "specRoot", "runRoot", "contractPath", "processDocPath", "requiredFiles", "completionGate"],
6
+ "properties": {
7
+ "version": { "const": 1 },
8
+ "workflowName": { "const": "product-shaping" },
9
+ "releaseId": { "type": "string", "minLength": 1 },
10
+ "specRoot": { "$ref": "#/$defs/relativePath", "default": ".wefter/specs" },
11
+ "runRoot": { "$ref": "#/$defs/relativePath", "default": ".wefter/runs/product-shaping" },
12
+ "contractPath": { "$ref": "#/$defs/relativePath" },
13
+ "processDocPath": { "$ref": "#/$defs/relativePath" },
14
+ "requiredFiles": {
15
+ "type": "array",
16
+ "minItems": 17,
17
+ "maxItems": 17,
18
+ "prefixItems": [
19
+ { "const": "README.md" },
20
+ { "const": "discovery/SOURCE_MATERIALS.md" },
21
+ { "const": "discovery/IDEA_BRIEF.md" },
22
+ { "const": "discovery/OPEN_QUESTIONS.md" },
23
+ { "const": "references/README.md" },
24
+ { "const": "PRODUCT_VISION.md" },
25
+ { "const": "product/FEATURE_CATALOG.md" },
26
+ { "const": "product/MODULE_ROADMAP.md" },
27
+ { "const": "product/DOMAIN_MODEL.md" },
28
+ { "const": "product/OPERATIONAL_FLOW.md" },
29
+ { "const": "product/PRODUCT_DECISIONS.md" },
30
+ { "const": "releases/README.md" },
31
+ { "const": "releases/<release-id>/README.md" },
32
+ { "const": "releases/<release-id>/SCOPE.md" },
33
+ { "const": "releases/<release-id>/DOMAIN_SPEC.md" },
34
+ { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" },
35
+ { "const": "releases/<release-id>/DELIVERABLES.md" }
36
+ ],
37
+ "items": false
38
+ },
39
+ "completionGate": {
40
+ "type": "object",
41
+ "required": ["requireNoReleaseBlockingQuestions", "requireAdversarialReview", "requireFinalValidation", "readyDeliverableStatuses"],
42
+ "properties": {
43
+ "requireNoReleaseBlockingQuestions": { "type": "boolean" },
44
+ "requireAdversarialReview": { "const": true },
45
+ "requireFinalValidation": { "const": true },
46
+ "readyDeliverableStatuses": {
47
+ "type": "array",
48
+ "minItems": 1,
49
+ "items": { "enum": ["ready"] }
50
+ }
51
+ },
52
+ "additionalProperties": false
53
+ }
54
+ },
55
+ "additionalProperties": false,
56
+ "$defs": {
57
+ "relativePath": {
58
+ "type": "string",
59
+ "minLength": 1,
60
+ "pattern": "^(?![A-Za-z]:)(?![\\\\/])(?!.*(?:^|/)\\.\\.(?:/|$))[^\\\\\r\n]+$"
61
+ }
62
+ }
63
+ }
@@ -1,204 +1,204 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://wefter.dev/schemas/product-shaping-contract.schema.json",
4
- "type": "object",
5
- "required": ["version", "workflowId", "defaultRoots", "vocabulary", "statusEnums", "dynamicCollections", "creationOrderScope", "creationOrder", "utilizationOrder", "precedence", "requiredFiles"],
6
- "properties": {
7
- "version": { "const": 1 },
8
- "workflowId": { "const": "product-shaping" },
9
- "defaultRoots": {
10
- "type": "object",
11
- "required": ["specRoot", "workflowRoot", "runRoot"],
12
- "properties": {
13
- "specRoot": { "const": ".wefter/specs" },
14
- "workflowRoot": { "const": ".wefter/workflows" },
15
- "runRoot": { "const": ".wefter/runs/product-shaping" }
16
- },
17
- "additionalProperties": false
18
- },
19
- "vocabulary": {
20
- "type": "array",
21
- "minItems": 5,
22
- "maxItems": 5,
23
- "prefixItems": [
24
- { "const": "idea" },
25
- { "const": "product specs" },
26
- { "const": "release" },
27
- { "const": "deliverable" },
28
- { "const": "task" }
29
- ],
30
- "items": false
31
- },
32
- "statusEnums": {
33
- "type": "object",
34
- "required": ["feature", "question", "decision", "deliverable"],
35
- "properties": {
36
- "feature": { "const": ["candidate", "core", "future", "rejected", "needs-decision"] },
37
- "question": { "const": ["open", "answered", "deferred", "obsolete"] },
38
- "decision": { "const": ["accepted", "superseded", "rejected"] },
39
- "deliverable": { "const": ["candidate", "ready", "blocked", "deferred", "done"] }
40
- },
41
- "additionalProperties": false
42
- },
43
- "dynamicCollections": {
44
- "type": "object",
45
- "required": ["references"],
46
- "properties": {
47
- "references": {
48
- "type": "object",
49
- "required": ["index", "itemPattern", "listingPattern", "creationOrder", "zeroItemsAllowedWithExplicitIndexStatement", "rule"],
50
- "properties": {
51
- "index": { "const": "references/README.md" },
52
- "itemPattern": { "const": "references/<reference>.md" },
53
- "listingPattern": { "const": "references/<reference>.md" },
54
- "creationOrder": { "type": "string", "minLength": 1 },
55
- "zeroItemsAllowedWithExplicitIndexStatement": { "const": true },
56
- "rule": { "type": "string", "minLength": 1 }
57
- },
58
- "additionalProperties": false
59
- }
60
- },
61
- "additionalProperties": false
62
- },
63
- "creationOrderScope": { "const": "fixed-required-files" },
64
- "creationOrder": { "$ref": "#/$defs/creationOrder" },
65
- "utilizationOrder": { "$ref": "#/$defs/utilizationOrder" },
66
- "precedence": {
67
- "type": "object",
68
- "required": ["release", "product", "decision", "blockingQuestionRule"],
69
- "properties": {
70
- "release": { "$ref": "#/$defs/pathList" },
71
- "product": { "$ref": "#/$defs/pathList" },
72
- "decision": { "type": "string", "minLength": 1 },
73
- "blockingQuestionRule": { "type": "string", "minLength": 1 }
74
- },
75
- "additionalProperties": false
76
- },
77
- "requiredFiles": {
78
- "type": "array",
79
- "minItems": 17,
80
- "maxItems": 17,
81
- "items": {
82
- "type": "object",
83
- "required": ["path", "responsibility", "limits", "createdAfter", "usedBefore", "consumers", "minimumContent", "hardRules"],
84
- "properties": {
85
- "path": { "$ref": "#/$defs/requiredFilePath" },
86
- "responsibility": { "type": "string", "minLength": 1 },
87
- "limits": { "type": "string", "minLength": 1 },
88
- "createdAfter": { "$ref": "#/$defs/pathList" },
89
- "usedBefore": { "$ref": "#/$defs/pathList" },
90
- "consumers": { "$ref": "#/$defs/stringList" },
91
- "minimumContent": { "$ref": "#/$defs/stringList" },
92
- "hardRules": { "$ref": "#/$defs/stringList" }
93
- },
94
- "additionalProperties": false
95
- },
96
- "allOf": [
97
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "README.md" } } } },
98
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "discovery/SOURCE_MATERIALS.md" } } } },
99
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "discovery/IDEA_BRIEF.md" } } } },
100
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "discovery/OPEN_QUESTIONS.md" } } } },
101
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "references/README.md" } } } },
102
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "PRODUCT_VISION.md" } } } },
103
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/FEATURE_CATALOG.md" } } } },
104
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/MODULE_ROADMAP.md" } } } },
105
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/DOMAIN_MODEL.md" } } } },
106
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/OPERATIONAL_FLOW.md" } } } },
107
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/PRODUCT_DECISIONS.md" } } } },
108
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/README.md" } } } },
109
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/README.md" } } } },
110
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/SCOPE.md" } } } },
111
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/DOMAIN_SPEC.md" } } } },
112
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" } } } },
113
- { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/DELIVERABLES.md" } } } }
114
- ]
115
- }
116
- },
117
- "additionalProperties": false,
118
- "$defs": {
119
- "pathList": {
120
- "type": "array",
121
- "items": { "type": "string", "minLength": 1 }
122
- },
123
- "requiredFilePath": {
124
- "enum": [
125
- "README.md",
126
- "discovery/SOURCE_MATERIALS.md",
127
- "discovery/IDEA_BRIEF.md",
128
- "discovery/OPEN_QUESTIONS.md",
129
- "references/README.md",
130
- "PRODUCT_VISION.md",
131
- "product/FEATURE_CATALOG.md",
132
- "product/MODULE_ROADMAP.md",
133
- "product/DOMAIN_MODEL.md",
134
- "product/OPERATIONAL_FLOW.md",
135
- "product/PRODUCT_DECISIONS.md",
136
- "releases/README.md",
137
- "releases/<release-id>/README.md",
138
- "releases/<release-id>/SCOPE.md",
139
- "releases/<release-id>/DOMAIN_SPEC.md",
140
- "releases/<release-id>/ACCEPTANCE_CRITERIA.md",
141
- "releases/<release-id>/DELIVERABLES.md"
142
- ]
143
- },
144
- "creationOrder": {
145
- "type": "array",
146
- "minItems": 17,
147
- "maxItems": 17,
148
- "prefixItems": [
149
- { "const": "README.md" },
150
- { "const": "discovery/SOURCE_MATERIALS.md" },
151
- { "const": "discovery/IDEA_BRIEF.md" },
152
- { "const": "discovery/OPEN_QUESTIONS.md" },
153
- { "const": "references/README.md" },
154
- { "const": "PRODUCT_VISION.md" },
155
- { "const": "product/FEATURE_CATALOG.md" },
156
- { "const": "product/MODULE_ROADMAP.md" },
157
- { "const": "product/DOMAIN_MODEL.md" },
158
- { "const": "product/OPERATIONAL_FLOW.md" },
159
- { "const": "product/PRODUCT_DECISIONS.md" },
160
- { "const": "releases/README.md" },
161
- { "const": "releases/<release-id>/README.md" },
162
- { "const": "releases/<release-id>/SCOPE.md" },
163
- { "const": "releases/<release-id>/DOMAIN_SPEC.md" },
164
- { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" },
165
- { "const": "releases/<release-id>/DELIVERABLES.md" }
166
- ],
167
- "items": false
168
- },
169
- "utilizationOrder": {
170
- "type": "array",
171
- "minItems": 15,
172
- "maxItems": 15,
173
- "prefixItems": [
174
- { "const": "README.md" },
175
- { "const": "releases/<release-id>/README.md" },
176
- { "const": "PRODUCT_VISION.md" },
177
- { "const": "product/PRODUCT_DECISIONS.md" },
178
- { "const": "releases/<release-id>/SCOPE.md" },
179
- { "const": "releases/<release-id>/DOMAIN_SPEC.md" },
180
- { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" },
181
- { "const": "releases/<release-id>/DELIVERABLES.md" },
182
- { "const": "product/DOMAIN_MODEL.md" },
183
- { "const": "product/OPERATIONAL_FLOW.md" },
184
- { "const": "product/FEATURE_CATALOG.md" },
185
- { "const": "product/MODULE_ROADMAP.md" },
186
- { "const": "discovery/OPEN_QUESTIONS.md" },
187
- { "const": "discovery/IDEA_BRIEF.md" },
188
- { "const": "references/" }
189
- ],
190
- "items": false
191
- },
192
- "stringList": {
193
- "type": "array",
194
- "minItems": 1,
195
- "items": { "type": "string", "minLength": 1 }
196
- },
197
- "stringEnum": {
198
- "type": "array",
199
- "minItems": 1,
200
- "uniqueItems": true,
201
- "items": { "type": "string", "minLength": 1 }
202
- }
203
- }
204
- }
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://wefter.dev/schemas/product-shaping-contract.schema.json",
4
+ "type": "object",
5
+ "required": ["version", "workflowId", "defaultRoots", "vocabulary", "statusEnums", "dynamicCollections", "creationOrderScope", "creationOrder", "utilizationOrder", "precedence", "requiredFiles"],
6
+ "properties": {
7
+ "version": { "const": 1 },
8
+ "workflowId": { "const": "product-shaping" },
9
+ "defaultRoots": {
10
+ "type": "object",
11
+ "required": ["specRoot", "workflowRoot", "runRoot"],
12
+ "properties": {
13
+ "specRoot": { "const": ".wefter/specs" },
14
+ "workflowRoot": { "const": ".wefter/workflows" },
15
+ "runRoot": { "const": ".wefter/runs/product-shaping" }
16
+ },
17
+ "additionalProperties": false
18
+ },
19
+ "vocabulary": {
20
+ "type": "array",
21
+ "minItems": 5,
22
+ "maxItems": 5,
23
+ "prefixItems": [
24
+ { "const": "idea" },
25
+ { "const": "product specs" },
26
+ { "const": "release" },
27
+ { "const": "deliverable" },
28
+ { "const": "task" }
29
+ ],
30
+ "items": false
31
+ },
32
+ "statusEnums": {
33
+ "type": "object",
34
+ "required": ["feature", "question", "decision", "deliverable"],
35
+ "properties": {
36
+ "feature": { "const": ["candidate", "core", "future", "rejected", "needs-decision"] },
37
+ "question": { "const": ["open", "answered", "deferred", "obsolete"] },
38
+ "decision": { "const": ["accepted", "superseded", "rejected"] },
39
+ "deliverable": { "const": ["candidate", "ready", "blocked", "deferred", "done"] }
40
+ },
41
+ "additionalProperties": false
42
+ },
43
+ "dynamicCollections": {
44
+ "type": "object",
45
+ "required": ["references"],
46
+ "properties": {
47
+ "references": {
48
+ "type": "object",
49
+ "required": ["index", "itemPattern", "listingPattern", "creationOrder", "zeroItemsAllowedWithExplicitIndexStatement", "rule"],
50
+ "properties": {
51
+ "index": { "const": "references/README.md" },
52
+ "itemPattern": { "const": "references/<reference>.md" },
53
+ "listingPattern": { "const": "references/<reference>.md" },
54
+ "creationOrder": { "type": "string", "minLength": 1 },
55
+ "zeroItemsAllowedWithExplicitIndexStatement": { "const": true },
56
+ "rule": { "type": "string", "minLength": 1 }
57
+ },
58
+ "additionalProperties": false
59
+ }
60
+ },
61
+ "additionalProperties": false
62
+ },
63
+ "creationOrderScope": { "const": "fixed-required-files" },
64
+ "creationOrder": { "$ref": "#/$defs/creationOrder" },
65
+ "utilizationOrder": { "$ref": "#/$defs/utilizationOrder" },
66
+ "precedence": {
67
+ "type": "object",
68
+ "required": ["release", "product", "decision", "blockingQuestionRule"],
69
+ "properties": {
70
+ "release": { "$ref": "#/$defs/pathList" },
71
+ "product": { "$ref": "#/$defs/pathList" },
72
+ "decision": { "type": "string", "minLength": 1 },
73
+ "blockingQuestionRule": { "type": "string", "minLength": 1 }
74
+ },
75
+ "additionalProperties": false
76
+ },
77
+ "requiredFiles": {
78
+ "type": "array",
79
+ "minItems": 17,
80
+ "maxItems": 17,
81
+ "items": {
82
+ "type": "object",
83
+ "required": ["path", "responsibility", "limits", "createdAfter", "usedBefore", "consumers", "minimumContent", "hardRules"],
84
+ "properties": {
85
+ "path": { "$ref": "#/$defs/requiredFilePath" },
86
+ "responsibility": { "type": "string", "minLength": 1 },
87
+ "limits": { "type": "string", "minLength": 1 },
88
+ "createdAfter": { "$ref": "#/$defs/pathList" },
89
+ "usedBefore": { "$ref": "#/$defs/pathList" },
90
+ "consumers": { "$ref": "#/$defs/stringList" },
91
+ "minimumContent": { "$ref": "#/$defs/stringList" },
92
+ "hardRules": { "$ref": "#/$defs/stringList" }
93
+ },
94
+ "additionalProperties": false
95
+ },
96
+ "allOf": [
97
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "README.md" } } } },
98
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "discovery/SOURCE_MATERIALS.md" } } } },
99
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "discovery/IDEA_BRIEF.md" } } } },
100
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "discovery/OPEN_QUESTIONS.md" } } } },
101
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "references/README.md" } } } },
102
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "PRODUCT_VISION.md" } } } },
103
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/FEATURE_CATALOG.md" } } } },
104
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/MODULE_ROADMAP.md" } } } },
105
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/DOMAIN_MODEL.md" } } } },
106
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/OPERATIONAL_FLOW.md" } } } },
107
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "product/PRODUCT_DECISIONS.md" } } } },
108
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/README.md" } } } },
109
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/README.md" } } } },
110
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/SCOPE.md" } } } },
111
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/DOMAIN_SPEC.md" } } } },
112
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" } } } },
113
+ { "contains": { "type": "object", "required": ["path"], "properties": { "path": { "const": "releases/<release-id>/DELIVERABLES.md" } } } }
114
+ ]
115
+ }
116
+ },
117
+ "additionalProperties": false,
118
+ "$defs": {
119
+ "pathList": {
120
+ "type": "array",
121
+ "items": { "type": "string", "minLength": 1 }
122
+ },
123
+ "requiredFilePath": {
124
+ "enum": [
125
+ "README.md",
126
+ "discovery/SOURCE_MATERIALS.md",
127
+ "discovery/IDEA_BRIEF.md",
128
+ "discovery/OPEN_QUESTIONS.md",
129
+ "references/README.md",
130
+ "PRODUCT_VISION.md",
131
+ "product/FEATURE_CATALOG.md",
132
+ "product/MODULE_ROADMAP.md",
133
+ "product/DOMAIN_MODEL.md",
134
+ "product/OPERATIONAL_FLOW.md",
135
+ "product/PRODUCT_DECISIONS.md",
136
+ "releases/README.md",
137
+ "releases/<release-id>/README.md",
138
+ "releases/<release-id>/SCOPE.md",
139
+ "releases/<release-id>/DOMAIN_SPEC.md",
140
+ "releases/<release-id>/ACCEPTANCE_CRITERIA.md",
141
+ "releases/<release-id>/DELIVERABLES.md"
142
+ ]
143
+ },
144
+ "creationOrder": {
145
+ "type": "array",
146
+ "minItems": 17,
147
+ "maxItems": 17,
148
+ "prefixItems": [
149
+ { "const": "README.md" },
150
+ { "const": "discovery/SOURCE_MATERIALS.md" },
151
+ { "const": "discovery/IDEA_BRIEF.md" },
152
+ { "const": "discovery/OPEN_QUESTIONS.md" },
153
+ { "const": "references/README.md" },
154
+ { "const": "PRODUCT_VISION.md" },
155
+ { "const": "product/FEATURE_CATALOG.md" },
156
+ { "const": "product/MODULE_ROADMAP.md" },
157
+ { "const": "product/DOMAIN_MODEL.md" },
158
+ { "const": "product/OPERATIONAL_FLOW.md" },
159
+ { "const": "product/PRODUCT_DECISIONS.md" },
160
+ { "const": "releases/README.md" },
161
+ { "const": "releases/<release-id>/README.md" },
162
+ { "const": "releases/<release-id>/SCOPE.md" },
163
+ { "const": "releases/<release-id>/DOMAIN_SPEC.md" },
164
+ { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" },
165
+ { "const": "releases/<release-id>/DELIVERABLES.md" }
166
+ ],
167
+ "items": false
168
+ },
169
+ "utilizationOrder": {
170
+ "type": "array",
171
+ "minItems": 15,
172
+ "maxItems": 15,
173
+ "prefixItems": [
174
+ { "const": "README.md" },
175
+ { "const": "releases/<release-id>/README.md" },
176
+ { "const": "PRODUCT_VISION.md" },
177
+ { "const": "product/PRODUCT_DECISIONS.md" },
178
+ { "const": "releases/<release-id>/SCOPE.md" },
179
+ { "const": "releases/<release-id>/DOMAIN_SPEC.md" },
180
+ { "const": "releases/<release-id>/ACCEPTANCE_CRITERIA.md" },
181
+ { "const": "releases/<release-id>/DELIVERABLES.md" },
182
+ { "const": "product/DOMAIN_MODEL.md" },
183
+ { "const": "product/OPERATIONAL_FLOW.md" },
184
+ { "const": "product/FEATURE_CATALOG.md" },
185
+ { "const": "product/MODULE_ROADMAP.md" },
186
+ { "const": "discovery/OPEN_QUESTIONS.md" },
187
+ { "const": "discovery/IDEA_BRIEF.md" },
188
+ { "const": "references/" }
189
+ ],
190
+ "items": false
191
+ },
192
+ "stringList": {
193
+ "type": "array",
194
+ "minItems": 1,
195
+ "items": { "type": "string", "minLength": 1 }
196
+ },
197
+ "stringEnum": {
198
+ "type": "array",
199
+ "minItems": 1,
200
+ "uniqueItems": true,
201
+ "items": { "type": "string", "minLength": 1 }
202
+ }
203
+ }
204
+ }
@@ -1,39 +1,39 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://wefter.dev/schemas/product-shaping-profile.schema.json",
4
- "type": "object",
5
- "required": ["version", "workflowName", "variants", "lenses"],
6
- "properties": {
7
- "version": { "const": 1 },
8
- "workflowName": { "const": "product-shaping" },
9
- "variants": {
10
- "type": "array",
11
- "minItems": 1,
12
- "items": {
13
- "type": "object",
14
- "required": ["id", "title", "instruction"],
15
- "properties": {
16
- "id": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]*$" },
17
- "title": { "type": "string", "minLength": 1 },
18
- "instruction": { "type": "string", "minLength": 1 }
19
- },
20
- "additionalProperties": false
21
- }
22
- },
23
- "lenses": {
24
- "type": "array",
25
- "minItems": 1,
26
- "items": {
27
- "type": "object",
28
- "required": ["id", "title", "focus"],
29
- "properties": {
30
- "id": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]*$" },
31
- "title": { "type": "string", "minLength": 1 },
32
- "focus": { "type": "string", "minLength": 1 }
33
- },
34
- "additionalProperties": false
35
- }
36
- }
37
- },
38
- "additionalProperties": false
39
- }
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://wefter.dev/schemas/product-shaping-profile.schema.json",
4
+ "type": "object",
5
+ "required": ["version", "workflowName", "variants", "lenses"],
6
+ "properties": {
7
+ "version": { "const": 1 },
8
+ "workflowName": { "const": "product-shaping" },
9
+ "variants": {
10
+ "type": "array",
11
+ "minItems": 1,
12
+ "items": {
13
+ "type": "object",
14
+ "required": ["id", "title", "instruction"],
15
+ "properties": {
16
+ "id": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]*$" },
17
+ "title": { "type": "string", "minLength": 1 },
18
+ "instruction": { "type": "string", "minLength": 1 }
19
+ },
20
+ "additionalProperties": false
21
+ }
22
+ },
23
+ "lenses": {
24
+ "type": "array",
25
+ "minItems": 1,
26
+ "items": {
27
+ "type": "object",
28
+ "required": ["id", "title", "focus"],
29
+ "properties": {
30
+ "id": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]*$" },
31
+ "title": { "type": "string", "minLength": 1 },
32
+ "focus": { "type": "string", "minLength": 1 }
33
+ },
34
+ "additionalProperties": false
35
+ }
36
+ }
37
+ },
38
+ "additionalProperties": false
39
+ }