aw-spec-cli 0.1.5 → 0.1.7

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 (205) hide show
  1. package/assets/.agents/agent.json +1 -1
  2. package/assets/.agents/skills/{aw-spec-orch → appweaver}/SKILL.md +10 -10
  3. package/assets/.agents/skills/{aw-spec-orch-demo → appweaver-demo}/SKILL.md +9 -9
  4. package/assets/.claude/agent.json +1 -1
  5. package/assets/.claude/skills/{aw-spec-orch → appweaver}/SKILL.md +10 -10
  6. package/assets/.claude/skills/{aw-spec-orch-demo → appweaver-demo}/SKILL.md +9 -9
  7. package/assets/.kilocode/agent.json +1 -1
  8. package/assets/.kilocode/workflows/{aw-spec-orch-demo.md → appweaver-demo.md} +9 -9
  9. package/assets/.kilocode/workflows/{aw-spec-orch.md → appweaver.md} +10 -10
  10. package/assets/docs/pharma-constitution.my-ref.md +86 -0
  11. package/dist/utils/paths.js +1 -1
  12. package/dist/utils/paths.js.map +1 -1
  13. package/package.json +1 -1
  14. package/assets/.aw-spec/DESIGN-FORMAT.md +0 -151
  15. package/assets/.aw-spec/ORCH-DIALECT.md +0 -156
  16. package/assets/.aw-spec/RULE-PARTITION.md +0 -126
  17. package/assets/.aw-spec/domain.json +0 -3
  18. package/assets/.aw-spec/extensions/.registry +0 -19
  19. package/assets/.aw-spec/extensions/agent-context/README.md +0 -57
  20. package/assets/.aw-spec/extensions/agent-context/agent-context-config.yml +0 -4
  21. package/assets/.aw-spec/extensions/agent-context/commands/aw-spec.agent-context.update.md +0 -26
  22. package/assets/.aw-spec/extensions/agent-context/extension.yml +0 -37
  23. package/assets/.aw-spec/extensions/agent-context/scripts/bash/update-agent-context.sh +0 -201
  24. package/assets/.aw-spec/extensions/agent-context/scripts/powershell/update-agent-context.ps1 +0 -237
  25. package/assets/.aw-spec/extensions.yml +0 -16
  26. package/assets/.aw-spec/feature.json +0 -3
  27. package/assets/.aw-spec/init-options.json +0 -9
  28. package/assets/.aw-spec/integration.json +0 -15
  29. package/assets/.aw-spec/integrations/aw-spec.manifest.json +0 -9
  30. package/assets/.aw-spec/interpreter/run-skill.py +0 -1158
  31. package/assets/.aw-spec/memory/constitution.md +0 -50
  32. package/assets/.aw-spec/orchestrator/AGENT-PROFILE.md +0 -94
  33. package/assets/.aw-spec/orchestrator/README.md +0 -300
  34. package/assets/.aw-spec/orchestrator/adapters/claude_agent_sdk.py +0 -74
  35. package/assets/.aw-spec/orchestrator/adapters/google_antigravity.py +0 -74
  36. package/assets/.aw-spec/orchestrator/modules/delta-design.orch.yaml +0 -105
  37. package/assets/.aw-spec/orchestrator/modules/delta-spec.orch.yaml +0 -79
  38. package/assets/.aw-spec/orchestrator/modules/domain-select.orch.yaml +0 -81
  39. package/assets/.aw-spec/orchestrator/modules/tech-select.orch.yaml +0 -75
  40. package/assets/.aw-spec/orchestrator/orchestrator.py +0 -1721
  41. package/assets/.aw-spec/orchestrator/rev-templates/ai-rules.reference.md +0 -40
  42. package/assets/.aw-spec/orchestrator/rev-templates/comandrulemap.skeleton.md +0 -59
  43. package/assets/.aw-spec/orchestrator/rev-templates/commandtechrulemap.skeleton.md +0 -97
  44. package/assets/.aw-spec/orchestrator/rev-templates/domain-constitution.skeleton.md +0 -61
  45. package/assets/.aw-spec/orchestrator/rev-templates/domain-requirements.skeleton.md +0 -48
  46. package/assets/.aw-spec/orchestrator/rev-templates/domain-rule-file.skeleton.md +0 -39
  47. package/assets/.aw-spec/orchestrator/rev-templates/technical-constitution.skeleton.md +0 -106
  48. package/assets/.aw-spec/orchestrator/rev-templates/technical-rule-file.skeleton.md +0 -54
  49. package/assets/.aw-spec/orchestrator/workflows/_smoke.orch.yaml +0 -160
  50. package/assets/.aw-spec/orchestrator/workflows/aw-spec-add-component.orch.yaml +0 -244
  51. package/assets/.aw-spec/orchestrator/workflows/aw-spec-adopt.orch.yaml +0 -775
  52. package/assets/.aw-spec/orchestrator/workflows/aw-spec-analyze-delta-design.orch.yaml +0 -248
  53. package/assets/.aw-spec/orchestrator/workflows/aw-spec-analyze-design.orch.yaml +0 -261
  54. package/assets/.aw-spec/orchestrator/workflows/aw-spec-analyze-slice.orch.yaml +0 -425
  55. package/assets/.aw-spec/orchestrator/workflows/aw-spec-build.orch.yaml +0 -188
  56. package/assets/.aw-spec/orchestrator/workflows/aw-spec-characterize.orch.yaml +0 -474
  57. package/assets/.aw-spec/orchestrator/workflows/aw-spec-close-delta.orch.yaml +0 -181
  58. package/assets/.aw-spec/orchestrator/workflows/aw-spec-constitution.orch.yaml +0 -284
  59. package/assets/.aw-spec/orchestrator/workflows/aw-spec-demo.orch.yaml +0 -103
  60. package/assets/.aw-spec/orchestrator/workflows/aw-spec-dependency-tree.orch.yaml +0 -69
  61. package/assets/.aw-spec/orchestrator/workflows/aw-spec-deploy.orch.yaml +0 -85
  62. package/assets/.aw-spec/orchestrator/workflows/aw-spec-design.orch.yaml +0 -382
  63. package/assets/.aw-spec/orchestrator/workflows/aw-spec-finalize-delta.orch.yaml +0 -382
  64. package/assets/.aw-spec/orchestrator/workflows/aw-spec-foundation.orch.yaml +0 -246
  65. package/assets/.aw-spec/orchestrator/workflows/aw-spec-implement-delta.orch.yaml +0 -231
  66. package/assets/.aw-spec/orchestrator/workflows/aw-spec-implement.orch.yaml +0 -258
  67. package/assets/.aw-spec/orchestrator/workflows/aw-spec-inventory.orch.yaml +0 -236
  68. package/assets/.aw-spec/orchestrator/workflows/aw-spec-onboard.orch.yaml +0 -949
  69. package/assets/.aw-spec/orchestrator/workflows/aw-spec-parity.orch.yaml +0 -293
  70. package/assets/.aw-spec/orchestrator/workflows/aw-spec-run.orch.yaml +0 -177
  71. package/assets/.aw-spec/orchestrator/workflows/aw-spec-select-domain.orch.yaml +0 -79
  72. package/assets/.aw-spec/orchestrator/workflows/aw-spec-select-feature.orch.yaml +0 -128
  73. package/assets/.aw-spec/orchestrator/workflows/aw-spec-specify.orch.yaml +0 -412
  74. package/assets/.aw-spec/scripts/bash/aw-inventory.sh +0 -14
  75. package/assets/.aw-spec/scripts/bash/aw-parity.sh +0 -13
  76. package/assets/.aw-spec/scripts/bash/aw-rev-constitution.sh +0 -13
  77. package/assets/.aw-spec/scripts/bash/aw-spec-actions.sh +0 -1899
  78. package/assets/.aw-spec/scripts/bash/aw-xref.sh +0 -15
  79. package/assets/.aw-spec/scripts/bash/common.sh +0 -533
  80. package/assets/.aw-spec/scripts/powershell/aw-inventory.ps1 +0 -14
  81. package/assets/.aw-spec/scripts/powershell/aw-parity.ps1 +0 -13
  82. package/assets/.aw-spec/scripts/powershell/aw-rev-constitution.ps1 +0 -13
  83. package/assets/.aw-spec/scripts/powershell/aw-spec-actions.ps1 +0 -1563
  84. package/assets/.aw-spec/scripts/powershell/aw-xref.ps1 +0 -15
  85. package/assets/.aw-spec/scripts/python/aw-inventory.py +0 -683
  86. package/assets/.aw-spec/scripts/python/aw-parity.py +0 -380
  87. package/assets/.aw-spec/scripts/python/aw-rev-constitution.py +0 -312
  88. package/assets/.aw-spec/scripts/python/aw-xref.py +0 -1330
  89. package/assets/.aw-spec/scripts/python/validate_okf.py +0 -349
  90. package/assets/.aw-spec/templates/constitution-domain-template.md +0 -75
  91. package/assets/.aw-spec/templates/constitution-technical-template.md +0 -70
  92. package/assets/.aw-spec/templates/delta-design-template.md +0 -69
  93. package/assets/.aw-spec/templates/delta-spec-template.md +0 -60
  94. package/assets/.aw-spec/templates/design-template.md +0 -383
  95. package/assets/.aw-spec/templates/okf-concept-template.md +0 -103
  96. package/assets/.aw-spec/templates/parity-manifest-template.json +0 -49
  97. package/assets/.aw-spec/templates/source-map-template.md +0 -85
  98. package/assets/.aw-spec/templates/spec-template.md +0 -252
  99. package/assets/docs/ModularMonolith/ModularMonolith.Reference.pack.txt +0 -25248
  100. package/assets/docs/ModularMonolith/ModularMonolith.pack.txt +0 -5726
  101. package/assets/docs/ModularMonolith/pack-foundation.ps1 +0 -145
  102. package/assets/docs/ModularMonolith/pack-foundation.sh +0 -196
  103. package/assets/docs/ModularMonolith/pack-reference-foundation.ps1 +0 -157
  104. package/assets/docs/ModularMonolith/pack-reference-foundation.sh +0 -209
  105. package/assets/docs/ModularMonolith/unpack-foundation.ps1 +0 -126
  106. package/assets/docs/ModularMonolith/unpack-foundation.sh +0 -217
  107. package/assets/docs/ModularMonolith/unpack-reference-foundation.ps1 +0 -129
  108. package/assets/docs/ModularMonolith/unpack-reference-foundation.sh +0 -218
  109. package/assets/docs/README.md +0 -106
  110. package/assets/docs/VerticalSlice/PACKAGING.md +0 -185
  111. package/assets/docs/VerticalSlice/VerticalSlice.Reference.pack.txt +0 -19318
  112. package/assets/docs/VerticalSlice/VerticalSlice.pack.txt +0 -2833
  113. package/assets/docs/VerticalSlice/pack-foundation.ps1 +0 -145
  114. package/assets/docs/VerticalSlice/pack-foundation.sh +0 -196
  115. package/assets/docs/VerticalSlice/pack-reference-foundation.ps1 +0 -157
  116. package/assets/docs/VerticalSlice/pack-reference-foundation.sh +0 -209
  117. package/assets/docs/VerticalSlice/unpack-foundation.ps1 +0 -126
  118. package/assets/docs/VerticalSlice/unpack-foundation.sh +0 -217
  119. package/assets/docs/VerticalSlice/unpack-reference-foundation.ps1 +0 -129
  120. package/assets/docs/VerticalSlice/unpack-reference-foundation.sh +0 -218
  121. package/assets/docs/architecture/clean-architecture.md +0 -71
  122. package/assets/docs/architecture/cqrs.md +0 -141
  123. package/assets/docs/architecture/eventing.md +0 -83
  124. package/assets/docs/architecture/folder-structure.md +0 -61
  125. package/assets/docs/architecture/modular-monolith.md +0 -47
  126. package/assets/docs/architecture/persistence.md +0 -269
  127. package/assets/docs/architecture/testing.md +0 -55
  128. package/assets/docs/architecture/vertical-slices.md +0 -201
  129. package/assets/docs/components/Email/README.md +0 -119
  130. package/assets/docs/components/Email/ReferenceEndpoints/SendEmailEndpoint.cs +0 -84
  131. package/assets/docs/components/Email/integration.md +0 -300
  132. package/assets/docs/components/Jobs/README.md +0 -113
  133. package/assets/docs/components/Jobs/integration.md +0 -259
  134. package/assets/docs/components/QrGenerator/README.md +0 -85
  135. package/assets/docs/components/QrGenerator/ReferenceEndpoints/GenerateQrEndpoint.cs +0 -57
  136. package/assets/docs/components/QrGenerator/integration.md +0 -230
  137. package/assets/docs/components/README.md +0 -74
  138. package/assets/docs/domain/domain-driven-design.md +0 -212
  139. package/assets/docs/domainspecs/healthcare/ai-rules.domain.md +0 -34
  140. package/assets/docs/domainspecs/healthcare/api-versioning.domain.md +0 -17
  141. package/assets/docs/domainspecs/healthcare/auditing.domain.md +0 -97
  142. package/assets/docs/domainspecs/healthcare/authorization.domain.md +0 -26
  143. package/assets/docs/domainspecs/healthcare/clinical-terms.md +0 -20
  144. package/assets/docs/domainspecs/healthcare/coding-standards.domain.md +0 -26
  145. package/assets/docs/domainspecs/healthcare/comandrulemap.md +0 -100
  146. package/assets/docs/domainspecs/healthcare/commandtechrulemap.md +0 -119
  147. package/assets/docs/domainspecs/healthcare/consent.md +0 -19
  148. package/assets/docs/domainspecs/healthcare/cqrs.domain.md +0 -12
  149. package/assets/docs/domainspecs/healthcare/data-classification.domain.md +0 -28
  150. package/assets/docs/domainspecs/healthcare/dependency-policy.domain.md +0 -11
  151. package/assets/docs/domainspecs/healthcare/dicom.md +0 -15
  152. package/assets/docs/domainspecs/healthcare/domain-driven-design.domain.md +0 -28
  153. package/assets/docs/domainspecs/healthcare/domain-requirements.md +0 -55
  154. package/assets/docs/domainspecs/healthcare/eventing.domain.md +0 -18
  155. package/assets/docs/domainspecs/healthcare/fhir.md +0 -36
  156. package/assets/docs/domainspecs/healthcare/folder-structure.domain.md +0 -23
  157. package/assets/docs/domainspecs/healthcare/hipaa.md +0 -34
  158. package/assets/docs/domainspecs/healthcare/hl7.md +0 -15
  159. package/assets/docs/domainspecs/healthcare/integration-terms.md +0 -21
  160. package/assets/docs/domainspecs/healthcare/persistence.domain.md +0 -20
  161. package/assets/docs/domainspecs/healthcare/terminology.md +0 -30
  162. package/assets/docs/domainspecs/healthcare/testing.domain.md +0 -15
  163. package/assets/docs/domainspecs/healthcare/vertical-slices.domain.md +0 -18
  164. package/assets/docs/domainspecs/healthcare/zero-trust.domain.md +0 -12
  165. package/assets/docs/domainspecs/pharma/ai-rules.domain.md +0 -32
  166. package/assets/docs/domainspecs/pharma/api-versioning.domain.md +0 -20
  167. package/assets/docs/domainspecs/pharma/atc.md +0 -22
  168. package/assets/docs/domainspecs/pharma/auditing.domain.md +0 -90
  169. package/assets/docs/domainspecs/pharma/authorization.domain.md +0 -25
  170. package/assets/docs/domainspecs/pharma/coding-standards.domain.md +0 -28
  171. package/assets/docs/domainspecs/pharma/comandrulemap.md +0 -108
  172. package/assets/docs/domainspecs/pharma/commandtechrulemap.md +0 -119
  173. package/assets/docs/domainspecs/pharma/cqrs.domain.md +0 -16
  174. package/assets/docs/domainspecs/pharma/data-classification.domain.md +0 -24
  175. package/assets/docs/domainspecs/pharma/data-provenance.md +0 -21
  176. package/assets/docs/domainspecs/pharma/dependency-policy.domain.md +0 -11
  177. package/assets/docs/domainspecs/pharma/domain-driven-design.domain.md +0 -36
  178. package/assets/docs/domainspecs/pharma/domain-requirements.md +0 -99
  179. package/assets/docs/domainspecs/pharma/eventing.domain.md +0 -18
  180. package/assets/docs/domainspecs/pharma/fhir.md +0 -31
  181. package/assets/docs/domainspecs/pharma/folder-structure.domain.md +0 -24
  182. package/assets/docs/domainspecs/pharma/hl7.md +0 -17
  183. package/assets/docs/domainspecs/pharma/idmp.md +0 -26
  184. package/assets/docs/domainspecs/pharma/integration-terms.md +0 -21
  185. package/assets/docs/domainspecs/pharma/ndc.md +0 -28
  186. package/assets/docs/domainspecs/pharma/persistence.domain.md +0 -23
  187. package/assets/docs/domainspecs/pharma/pharma-terms.md +0 -27
  188. package/assets/docs/domainspecs/pharma/product-lifecycle.domain.md +0 -30
  189. package/assets/docs/domainspecs/pharma/regulatory-compliance.md +0 -19
  190. package/assets/docs/domainspecs/pharma/terminology.md +0 -32
  191. package/assets/docs/domainspecs/pharma/testing.domain.md +0 -19
  192. package/assets/docs/domainspecs/pharma/vertical-slices.domain.md +0 -17
  193. package/assets/docs/domainspecs/pharma/zero-trust.domain.md +0 -12
  194. package/assets/docs/glossary/ai-rules.md +0 -59
  195. package/assets/docs/governance/api-versioning.md +0 -99
  196. package/assets/docs/governance/coding-standards.md +0 -87
  197. package/assets/docs/governance/dependency-policy.md +0 -40
  198. package/assets/docs/interop/ihe-conformance.md +0 -31
  199. package/assets/docs/requirement-spec.txt +0 -27
  200. package/assets/docs/security/auditing.md +0 -160
  201. package/assets/docs/security/authorization-matrix.md +0 -14
  202. package/assets/docs/security/authorization.md +0 -87
  203. package/assets/docs/security/data-classification.md +0 -38
  204. package/assets/docs/security/zero-trust.md +0 -76
  205. package/assets/docs/technology-constitution.md +0 -172
@@ -1,284 +0,0 @@
1
- # =============================================================================
2
- # aw-spec-constitution (orchestrator) — create/update the SPLIT project constitution
3
- #
4
- # Authors TWO composed files, each from its own source, so the forward loop can
5
- # load them per the rule-partition (.aw-spec/RULE-PARTITION.md):
6
- # .aw-spec/memory/constitution.technical.md ← technology base (I–XV) + ai-rules.
7
- # Domain-agnostic. STANDING input to DESIGN + IMPLEMENT (not specify).
8
- # .aw-spec/memory/constitution.domain.md ← the active domain addenda
9
- # (docs/<domain>-constitution.md + domain rule files). Domain principles XVI+.
10
- # SPECIFY-only + gate checklist; deliberately NOT loaded by design/implement.
11
- # A deterministic `compose-constitution` then concatenates them into the composed
12
- # .aw-spec/memory/constitution.md (human/compat view only; the pipeline loads the
13
- # halves directly).
14
- #
15
- # WHY SPLIT: the old single constitution embedded the domain (principles XVI–XX)
16
- # and was standing input to every phase — a domain side-channel into design that
17
- # broke "design's only domain input is the spec." Splitting keeps design/implement
18
- # domain-free while specify still gets the full picture.
19
- #
20
- # The seam is enforced by ORDER: the technical half is authored BEFORE domain-select
21
- # runs, so its context can never contain a domain file. The domain half is authored
22
- # after, from the domain addenda (and may reference the technical base it extends).
23
- #
24
- # Each half is authored and then linted by the deterministic `constitution-verify`
25
- # SCRIPT (residual [ALL_CAPS] placeholders, body-vs-report version, ISO dates) with
26
- # a bounded self-correction loop (max 3) — so the whole skill works under every
27
- # strategy (sdk/sdk-apply/spawn/agent), --checkpoint, or headless.
28
- #
29
- # NOT part of the per-feature pipeline. Project-level, run-once / amend-on-change.
30
- #
31
- # Launch: /aw-spec-orch constitution [strategy] [principles or values…]
32
- # Action semantics: .aw-spec/ORCH-DIALECT.md
33
- # =============================================================================
34
-
35
- name: aw-spec-constitution
36
- description: Create or update the split project constitution — constitution.technical.md (technology base) + constitution.domain.md (active domain addenda), each version-bumped with a Sync Impact Report, then composed into constitution.md. Project-level, run-once/amend — not a per-feature phase.
37
- version: 2.0.0
38
- agent_agnostic: true
39
- dialect: aw-spec.orchestrator/v1
40
-
41
- inputs:
42
- user_input:
43
- description: Principles or values for the project constitution (optional).
44
- required: false
45
- bind: USER_INPUT
46
-
47
- scripts:
48
- actions:
49
- sh: .aw-spec/scripts/bash/aw-spec-actions.sh
50
- ps1: .aw-spec/scripts/powershell/aw-spec-actions.ps1
51
-
52
- # Sticky standards seed = the UNIVERSAL always-on rule only (ai-rules). The technology-
53
- # constitution base the TECHNICAL half ratifies is no longer hardcoded here — it is now
54
- # CONFIGURATION, loaded per-command from docs/domainspecs/<domain>/commandtechrulemap.md
55
- # under "## /aw-spec-constitution" by the tech-select module (see the tech_select step
56
- # below). tech_select runs BEFORE the technical half AND before domain-select, so the
57
- # technical author still sees only the technology base + ai-rules — NO domain file: the
58
- # seam is preserved. The constitution OUTPUT files (constitution.technical.md /
59
- # constitution.domain.md) are referred to directly elsewhere, never mapped. (missing skipped)
60
- standards:
61
- - { path: docs/glossary/ai-rules.md, optional: true }
62
-
63
- vars:
64
- technical_ok: "false" # technical-half validation-loop guard, flipped by constitution-verify
65
- domain_ok: "false" # domain-half validation-loop guard, flipped by constitution-verify
66
-
67
- workflow:
68
-
69
- # 0. TECHNICAL rule files → sticky standards (configuration, not hardcoded). tech-select
70
- # reads docs/domainspecs/<domain>/commandtechrulemap.md under "## /aw-spec-constitution"
71
- # and loads the technology-constitution base into the sticky standards the TECHNICAL
72
- # half ratifies. Placed FIRST — before the technical half AND before domain-select — so
73
- # the technical author sees only technical files: the seam that keeps it domain-free is
74
- # preserved. No blocking gate: an unconfigured project soft-continues (ai-rules seed only).
75
- - id: tech_select
76
- action: include
77
- module: .aw-spec/orchestrator/modules/tech-select.orch.yaml
78
- with: { command: aw-spec-constitution }
79
-
80
- # 1. Ensure both halves exist (copy each template in if missing). Rewrite-in-place
81
- # only — never creates a second template. Composed constitution.md is produced
82
- # later by compose-constitution.
83
- - id: setup_constitution
84
- action: execute_script
85
- script: { ref: actions }
86
- subcommand: setup-constitution
87
- outputs:
88
- - { name: constitution_technical_file, from: "$.constitution_technical_file" }
89
- - { name: constitution_domain_file, from: "$.constitution_domain_file" }
90
- - { name: technical_created, from: "$.technical_created" }
91
- - { name: domain_created, from: "$.domain_created" }
92
-
93
- # 2. Pre-execution hooks: resolve (script) then dispatch (invoking agent).
94
- - id: resolve_pre_hooks
95
- action: execute_script
96
- script: { ref: actions }
97
- subcommand: resolve-hooks
98
- args: ["--phase", "before_constitution"]
99
- outputs:
100
- - { name: before_hooks, from: "$.hooks" }
101
- - id: dispatch_pre_hooks
102
- action: dispatch_hooks
103
- hooks_from_variable: before_hooks
104
-
105
- # ── TECHNICAL HALF ─────────────────────────────────────────────────────────
106
- # Authored FIRST, while the sticky set holds only the technology base + ai-rules
107
- # (domain-select has not run yet). This ordering is what guarantees the technical
108
- # constitution is domain-free.
109
-
110
- # 3. Context: the technical half (template being filled / file being amended) +
111
- # the spec template for Sync-Impact-Report propagation awareness.
112
- - id: gen_technical_ctx
113
- action: build_context
114
- context:
115
- - { path: "{{constitution_technical_file}}" }
116
- - { path: .aw-spec/templates/spec-template.md, optional: true }
117
-
118
- # 4. Author the TECHNICAL constitution (rewrite-in-place).
119
- - id: gen_technical
120
- action: agent_author
121
- output_target: { type: file, path: "{{constitution_technical_file}}" }
122
- task: |
123
- Update the TECHNICAL project constitution (the target file in context). It is
124
- a TEMPLATE with [ALL_CAPS] placeholder tokens. This is the domain-AGNOSTIC half.
125
- Principles/values supplied by the user: {{USER_INPUT}}
126
- Steps:
127
- - Fill EVERY placeholder with concrete text; leave no unexplained [BRACKET]
128
- tokens (justify any intentionally deferred as TODO(<FIELD>): reason).
129
- - Derive values from the user input, the technology-constitution base + ai-rules
130
- (in the standards), and repo context — do NOT invent principles.
131
- - Author ONLY technology-base principles (the I–XV set) + base folder structure,
132
- base conventions/AI rules, and base governance. Do NOT add any domain-specific
133
- principle, identifier, terminology, regulatory, or interoperability rule — those
134
- belong to the paired constitution.domain.md and MUST NOT appear here.
135
- - Bump CONSTITUTION_VERSION by semver (MAJOR incompatible; MINOR new/expanded;
136
- PATCH clarifications). This half versions independently of the domain half.
137
- - Dates ISO YYYY-MM-DD: RATIFICATION_DATE = original adoption (TODO if unknown);
138
- LAST_AMENDED_DATE = today when changed.
139
- - Preserve heading hierarchy exactly. Principles declarative and testable.
140
- - PREPEND a "Sync Impact Report" as an HTML comment at the very top: version
141
- old→new, modified/added/removed principles, dependent artifacts (✅/⚠) + TODOs.
142
- Return the complete updated technical constitution content only.
143
-
144
- # 5. Deterministic validation loop for the technical half (max 3 patch passes).
145
- - id: technical_validation_loop
146
- action: loop
147
- while: "{{technical_ok}} != true"
148
- max_iterations: 3
149
- steps:
150
- - id: tech_lint
151
- action: execute_script
152
- script: { ref: actions }
153
- subcommand: constitution-verify
154
- args: ["--file", "{{constitution_technical_file}}"]
155
- outputs:
156
- - { name: technical_ok, from: "$.ok" }
157
- - { name: technical_issues, from: "$.issues" }
158
- - id: tech_lint_break
159
- action: break
160
- condition: "{{technical_ok}} == true"
161
- - id: patch_technical
162
- action: agent_author
163
- context: ["{{constitution_technical_file}}"]
164
- include_standards: false # rewrite-in-place: only the technical half
165
- output_target: { type: file, path: "{{constitution_technical_file}}" }
166
- task: |
167
- Fix these mechanical defects in the technical constitution (target file in
168
- context), changing NOTHING else — preserve every principle, the heading
169
- hierarchy, and the Sync Impact Report. Fill any listed [ALL_CAPS] placeholder
170
- with concrete text (or a justified TODO(<FIELD>): reason); make the body's
171
- version line AGREE with the Sync Impact Report's new version; ISO YYYY-MM-DD dates.
172
- Defects: {{technical_issues}}
173
- Return the complete updated technical constitution content only.
174
-
175
- # ── DOMAIN HALF ────────────────────────────────────────────────────────────
176
- # 6. Resolve the active domain + load its rule files into the sticky set (D3).
177
- # Gate Continue/Exit when no domain/comandrulemap; then Select all/subset/none.
178
- # Runs AFTER the technical half is done, so it cannot leak into it.
179
- - id: domain_select
180
- action: include
181
- module: .aw-spec/orchestrator/modules/domain-select.orch.yaml
182
- with: { command: aw-spec-constitution }
183
-
184
- # 7. Context for the domain half: the domain template/file + the domain addenda
185
- # source (docs/<domain>-constitution.md). Sticky now also carries the domain
186
- # rule files loaded by domain-select. Skipped when no active domain.
187
- - id: gen_domain_ctx
188
- action: build_context
189
- condition: "{{dg_rulemap_exists}} == true"
190
- context:
191
- - { path: "{{constitution_domain_file}}" }
192
- - { path: "docs/{{domain}}-constitution.my-ref.md", optional: true }
193
- - { path: "docs/{{domain}}-constitution.md", optional: true }
194
-
195
- # 8. Author the DOMAIN addenda (rewrite-in-place). Only when a domain is active.
196
- - id: gen_domain
197
- action: agent_author
198
- condition: "{{dg_rulemap_exists}} == true"
199
- output_target: { type: file, path: "{{constitution_domain_file}}" }
200
- task: |
201
- Update the DOMAIN ADDENDA constitution for domain '{{domain}}' (the target file
202
- in context). It is a TEMPLATE with [ALL_CAPS] placeholder tokens. This half carries
203
- ONLY domain-specific material. Principles/values supplied by the user: {{USER_INPUT}}
204
- Steps:
205
- - Fill EVERY placeholder with concrete text; leave no unexplained [BRACKET] tokens
206
- (justify deferrals as TODO(<FIELD>): reason). NO residual placeholder may remain.
207
- - Derive values from the domain addenda source (docs/{{domain}}-constitution.*) and
208
- the domain rule files (in the standards) — do NOT invent principles.
209
- - Author ONLY the domain layer: domain principles NUMBERED XVI+ (continuing the
210
- technical base which ends at XV), domain folder additions, regulatory posture &
211
- security addenda, and domain governance overrides. For each domain principle,
212
- state which technical principle it EXTENDS. Do NOT restate the technical
213
- principles I–XV or the base governance — reference them.
214
- - Bump CONSTITUTION_VERSION by semver; this half versions independently of the
215
- technical half. Dates ISO YYYY-MM-DD.
216
- - Preserve heading hierarchy exactly. PREPEND a "Sync Impact Report" HTML comment:
217
- version old→new, changed domain principles, dependent artifacts (✅/⚠) + TODOs.
218
- Return the complete updated domain addenda content only.
219
-
220
- # 9. Deterministic validation loop for the domain half (max 3). Skipped if no domain.
221
- - id: domain_validation_loop
222
- action: loop
223
- condition: "{{dg_rulemap_exists}} == true"
224
- while: "{{domain_ok}} != true"
225
- max_iterations: 3
226
- steps:
227
- - id: dom_lint
228
- action: execute_script
229
- script: { ref: actions }
230
- subcommand: constitution-verify
231
- args: ["--file", "{{constitution_domain_file}}"]
232
- outputs:
233
- - { name: domain_ok, from: "$.ok" }
234
- - { name: domain_issues, from: "$.issues" }
235
- - id: dom_lint_break
236
- action: break
237
- condition: "{{domain_ok}} == true"
238
- - id: patch_domain
239
- action: agent_author
240
- context: ["{{constitution_domain_file}}"]
241
- include_standards: false # rewrite-in-place: only the domain half
242
- output_target: { type: file, path: "{{constitution_domain_file}}" }
243
- task: |
244
- Fix these mechanical defects in the domain addenda constitution (target file in
245
- context), changing NOTHING else — preserve every principle, the heading hierarchy,
246
- and the Sync Impact Report. Fill any listed [ALL_CAPS] placeholder (or a justified
247
- TODO(<FIELD>): reason); make the body version AGREE with the Sync Impact Report;
248
- ISO YYYY-MM-DD dates.
249
- Defects: {{domain_issues}}
250
- Return the complete updated domain addenda content only.
251
-
252
- # 10. Compose the two halves into the human/compat constitution.md (deterministic).
253
- # Skips the domain half automatically if it is an unauthored template.
254
- - id: compose_constitution
255
- action: execute_script
256
- script: { ref: actions }
257
- subcommand: compose-constitution
258
- outputs:
259
- - { name: composed_file, from: "$.composed_file" }
260
- - { name: domain_included, from: "$.domain_included" }
261
-
262
- # 11. Post-execution hooks.
263
- - id: resolve_post_hooks
264
- action: execute_script
265
- script: { ref: actions }
266
- subcommand: resolve-hooks
267
- args: ["--phase", "after_constitution"]
268
- outputs:
269
- - { name: after_hooks, from: "$.hooks" }
270
- - id: dispatch_post_hooks
271
- action: dispatch_hooks
272
- hooks_from_variable: after_hooks
273
-
274
- outputs:
275
- constitution_technical_file: "{{constitution_technical_file}}"
276
- constitution_domain_file: "{{constitution_domain_file}}"
277
- composed_file: "{{composed_file}}"
278
- domain_included: "{{domain_included}}"
279
- technical_validation_ok: "{{technical_ok}}"
280
- technical_validation_issues: "{{technical_issues}}"
281
- domain_validation_ok: "{{domain_ok}}"
282
- domain_validation_issues: "{{domain_issues}}"
283
- note: "Split constitution authored: constitution.technical.md (technology base, standing input to design + implement) + constitution.domain.md (domain addenda, standing input to specify + a gate checklist), composed into constitution.md. If a validation_ok is false, the matching validation_issues lists what still needs a manual touch. See each half's Sync Impact Report for its version bump. Suggested commit: 'docs: amend split constitution'."
284
- next: "Loaded per concern — /aw-spec-orch specify loads constitution.domain.md; design + implement load constitution.technical.md. Re-run /aw-spec-orch constitution to amend."
@@ -1,103 +0,0 @@
1
- # =============================================================================
2
- # aw-spec-demo.orch.yaml — a runnable demo workflow for the aw-orchestrator.
3
- # Launch via the parametric skill: /aw-spec-orch demo [strategy]
4
- #
5
- # It walks the exact loop from the diagram:
6
- # build_context → agent_generate (fresh) → agent_review (fresh) → repeat
7
- #
8
- # Run it (safe, no model calls — prints the assembled payloads):
9
- # python3 .aw-spec/orchestrator/orchestrator.py .aw-spec/orchestrator/workflows/aw-spec-demo.orch.yaml
10
- #
11
- # Run it for real (spawns fresh `claude -p --bare` per generation):
12
- # python3 .aw-spec/orchestrator/orchestrator.py .aw-spec/orchestrator/workflows/aw-spec-demo.orch.yaml \
13
- # --transport claude --model opus --budget 0.50
14
- # =============================================================================
15
-
16
- dialect: aw-spec.orchestrator/v1
17
- name: demo-fresh-generation
18
-
19
- vars:
20
- out_dir: .aw-spec/orchestrator/.demo-out
21
- review_pass: "false" # loop guard, flipped by agent_review
22
-
23
- workflow:
24
-
25
- # 1. Builds Complete Context — the interpreter reads standards (→ system) and
26
- # any prior artifacts (→ user context). Optional files are tolerated so the
27
- # demo runs even if the docs/ tree isn't present.
28
- - id: ctx_generate
29
- action: build_context
30
- system:
31
- - { path: docs/architecture/clean-architecture.md, optional: true }
32
- - { path: docs/architecture/cqrs.md, optional: true }
33
- - { path: docs/glossary/ai-rules.md, optional: true }
34
- context:
35
- - { path: "{{out_dir}}/spec.md", optional: true }
36
-
37
- # 2. Invoke Claude Code (FRESH generation) — it decides the file path(s) itself
38
- # (per the loaded folder-structure/architecture standards), writes them with
39
- # its tools, and REPORTS the paths back. The interpreter binds that list.
40
- - id: gen_handler
41
- action: agent_generate
42
- tools: "Read,Write,Edit,Bash"
43
- permission_mode: acceptEdits
44
- task: |
45
- Implement a CQRS command handler `CreateOrderHandler` for a "Create Order"
46
- feature, following the loaded Clean Architecture + CQRS standards. Keep it
47
- compilable C#; no TODOs.
48
- outputs:
49
- - { name: gen_status, from: "$.status" }
50
- - { name: gen_summary, from: "$.summary" }
51
- - { name: gen_files, from: "$.files" } # the paths the agent chose
52
-
53
- # 3. Review the current output — a SECOND fresh generation, read-only, that
54
- # judges the files the generation reported and returns pass/issues.
55
- - id: review_handler
56
- action: agent_review
57
- review_of_var: gen_files
58
- task: |
59
- Review the handler for compliance with the loaded standards (naming, layer
60
- boundaries, CQRS separation). Decide pass/fail.
61
- outputs:
62
- - { name: review_pass, from: "$.pass" }
63
- - { name: review_issues, from: "$.issues" }
64
-
65
- # 4. If review failed, rebuild context (now including the issues) and
66
- # regenerate — up to 3 times. This is the "…continues" cycle.
67
- - id: revise
68
- action: loop
69
- while: "{{review_pass}} != true"
70
- max_iterations: 3
71
- steps:
72
- - id: ctx_revise
73
- action: build_context
74
- vars:
75
- issues: "{{review_issues}}"
76
- system:
77
- - { path: docs/architecture/clean-architecture.md, optional: true }
78
- - { path: docs/architecture/cqrs.md, optional: true }
79
- context_from: gen_files # the files the agent chose last round
80
- - id: regen
81
- action: agent_generate
82
- tools: "Read,Write,Edit"
83
- task: |
84
- Fix these review issues in the file(s) provided in context, preserving
85
- everything already correct: {{issues}}
86
- outputs:
87
- - { name: gen_files, from: "$.files" }
88
- - id: rereview
89
- action: agent_review
90
- review_of_var: gen_files
91
- task: Re-review after the fix. Decide pass/fail.
92
- outputs:
93
- - { name: review_pass, from: "$.pass" }
94
- - { name: review_issues, from: "$.issues" }
95
- - id: stop_when_pass
96
- action: break
97
- condition: "{{review_pass}} == true"
98
-
99
- outputs:
100
- generated: "{{gen_summary}}"
101
- review_pass: "{{review_pass}}"
102
- files: "{{gen_files}}" # decided by the fresh agent, not the interpreter
103
- next: "interpreter continues to the next workflow step"
@@ -1,69 +0,0 @@
1
- # =============================================================================
2
- # aw-spec-dependency-tree (orchestrator) — MR-0.1 of the Migration Pipeline
3
- #
4
- # Scans OKF knowledge bundles (knowledge/) and specs/ across all aggregates,
5
- # parses Depends-On and Cross-References relationships, runs deterministic
6
- # topological wave sorting, traps circular dependency deadlocks, and emits the
7
- # final migration hierarchy tree (specs/migration-tree.md + specs/migration-sequence.json).
8
- #
9
- # Zero LLM for tree calculation: pure deterministic script orchestration via aw-xref.py.
10
- #
11
- # Launch:
12
- # /aw-spec-orch dependency-tree
13
- # /aw-spec-orch tree
14
- # =============================================================================
15
-
16
- name: aw-spec-dependency-tree
17
- description: Scan OKF knowledge bundles and specs across all aggregates, parse Depends-On and Cross-References relationships, run topological wave sorting, trap circular dependency deadlocks, and emit the final migration hierarchy tree (specs/migration-tree.md + specs/migration-sequence.json).
18
- version: 1.0.0
19
- agent_agnostic: true
20
- dialect: aw-spec.orchestrator/v1
21
-
22
- inputs:
23
- user_input:
24
- description: Optional path hints or focus scope.
25
- required: false
26
- bind: USER_INPUT
27
-
28
- scripts:
29
- xref:
30
- sh: .aw-spec/scripts/bash/aw-xref.sh
31
- ps1: .aw-spec/scripts/powershell/aw-xref.ps1
32
-
33
- vars:
34
- aggregate_count: "0"
35
- wave_count: "0"
36
- has_cycles: "false"
37
- tree_file: ""
38
- sequence_file: ""
39
-
40
- workflow:
41
-
42
- # 1. Deterministic graph construction & topological wave sorting via aw-xref.py tree
43
- - id: generate_tree
44
- action: execute_script
45
- script: { ref: xref }
46
- subcommand: tree
47
- outputs:
48
- - { name: aggregate_count, from: "$.aggregate_count" }
49
- - { name: wave_count, from: "$.wave_count" }
50
- - { name: has_cycles, from: "$.has_cycles" }
51
- - { name: tree_file, from: "$.tree_file" }
52
- - { name: sequence_file, from: "$.sequence_file" }
53
-
54
- # 2. Cycle warning gate
55
- - id: check_cycles
56
- action: verify_context
57
- require_value: has_cycles
58
- equals: "false"
59
- on_mismatch: stop
60
- on_mismatch_message: "Circular dependency detected among aggregates (see {{tree_file}}). Seam refactoring is required to break circular dependencies before executing the migration sequence."
61
-
62
- outputs:
63
- aggregate_count: "{{aggregate_count}}"
64
- wave_count: "{{wave_count}}"
65
- has_cycles: "{{has_cycles}}"
66
- tree_file: "{{tree_file}}"
67
- sequence_file: "{{sequence_file}}"
68
- note: "Migration Hierarchy Tree generated in {{tree_file}} and {{sequence_file}}."
69
- next: "Human Gate H0.1: Review specs/migration-tree.md and proceed to /aw-spec-orch mr per slice."
@@ -1,85 +0,0 @@
1
- # =============================================================================
2
- # aw-spec-deploy (orchestrator) — push to the deployment pipeline
3
- #
4
- # Config-driven: runs the command in .aw-spec/deploy.json {"command": "..."}.
5
- # Unconfigured = a clear no-op that reports how to wire it (never a false
6
- # success claim of an actual deploy). Post-deploy hooks carry smoke/rollback.
7
- #
8
- # Launch: /aw-spec-orch deploy [strategy]
9
- # =============================================================================
10
-
11
- name: aw-spec-deploy
12
- description: Push the feature to the configured deployment pipeline (.aw-spec/deploy.json), with pre/post hooks for smoke checks and rollback.
13
- version: 1.0.0
14
- agent_agnostic: true
15
- dialect: aw-spec.orchestrator/v1
16
-
17
- scripts:
18
- actions:
19
- sh: .aw-spec/scripts/bash/aw-spec-actions.sh
20
- ps1: .aw-spec/scripts/powershell/aw-spec-actions.ps1
21
-
22
- vars:
23
- deploy_ok: "false"
24
-
25
- workflow:
26
-
27
- - id: feature_paths
28
- action: execute_script
29
- on_error: continue # never crash raw on 'no feature set' — the gate below explains it
30
- script: { ref: actions }
31
- subcommand: feature-paths
32
- outputs:
33
- - { name: feature_dir, from: "$.feature_dir" }
34
-
35
- - id: require_feature
36
- action: verify_context
37
- require_non_empty: feature_dir
38
- on_empty: stop
39
- on_empty_message: "No active feature. Run /aw-spec-orch select-feature first (pick or create the aggregate, e.g. Order), then re-run deploy."
40
-
41
- # Pre-deploy hooks (e.g. a final smoke/build gate configured by the project).
42
- - id: resolve_pre_hooks
43
- action: execute_script
44
- script: { ref: actions }
45
- subcommand: resolve-hooks
46
- args: ["--phase", "before_deploy"]
47
- outputs:
48
- - { name: before_hooks, from: "$.hooks" }
49
- - id: dispatch_pre_hooks
50
- action: dispatch_hooks
51
- hooks_from_variable: before_hooks
52
-
53
- - id: deploy
54
- action: execute_script
55
- on_error: continue
56
- script: { ref: actions }
57
- subcommand: deploy-dispatch
58
- outputs:
59
- - { name: deploy_ok, from: "$.ok" }
60
- - { name: configured, from: "$.configured" }
61
- - { name: deploy_log, from: "$.log_tail" }
62
-
63
- - id: deploy_gate
64
- action: verify_context
65
- require_true: deploy_ok
66
- on_false: stop
67
- on_false_message: "Deploy command failed. Log: {{deploy_log}}"
68
-
69
- # Post-deploy hooks: smoke checks and, on failure, rollback (project-configured).
70
- - id: resolve_post_hooks
71
- action: execute_script
72
- script: { ref: actions }
73
- subcommand: resolve-hooks
74
- args: ["--phase", "after_deploy"]
75
- outputs:
76
- - { name: after_hooks, from: "$.hooks" }
77
- - id: dispatch_post_hooks
78
- action: dispatch_hooks
79
- hooks_from_variable: after_hooks
80
-
81
- outputs:
82
- feature_dir: "{{feature_dir}}"
83
- deployed: "{{configured}}"
84
- note: "Set .aw-spec/deploy.json {\"command\": \"...\"} to enable an actual deploy; add smoke/rollback via before_deploy/after_deploy hooks."
85
- next: "done"