arggon-harness 0.1.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 (170) hide show
  1. package/README.md +229 -0
  2. package/config/default-opencode.json +21 -0
  3. package/dist/init.d.ts +3 -0
  4. package/dist/init.d.ts.map +1 -0
  5. package/dist/init.js +406 -0
  6. package/dist/init.js.map +1 -0
  7. package/dist/plugin/engine/artifact-graph.d.ts +38 -0
  8. package/dist/plugin/engine/artifact-graph.d.ts.map +1 -0
  9. package/dist/plugin/engine/artifact-graph.js +137 -0
  10. package/dist/plugin/engine/artifact-graph.js.map +1 -0
  11. package/dist/plugin/engine/config.d.ts +21 -0
  12. package/dist/plugin/engine/config.d.ts.map +1 -0
  13. package/dist/plugin/engine/config.js +146 -0
  14. package/dist/plugin/engine/config.js.map +1 -0
  15. package/dist/plugin/engine/delta-apply.d.ts +23 -0
  16. package/dist/plugin/engine/delta-apply.d.ts.map +1 -0
  17. package/dist/plugin/engine/delta-apply.js +153 -0
  18. package/dist/plugin/engine/delta-apply.js.map +1 -0
  19. package/dist/plugin/engine/git.d.ts +32 -0
  20. package/dist/plugin/engine/git.d.ts.map +1 -0
  21. package/dist/plugin/engine/git.js +61 -0
  22. package/dist/plugin/engine/git.js.map +1 -0
  23. package/dist/plugin/engine/integrity.d.ts +45 -0
  24. package/dist/plugin/engine/integrity.d.ts.map +1 -0
  25. package/dist/plugin/engine/integrity.js +98 -0
  26. package/dist/plugin/engine/integrity.js.map +1 -0
  27. package/dist/plugin/engine/registry.d.ts +39 -0
  28. package/dist/plugin/engine/registry.d.ts.map +1 -0
  29. package/dist/plugin/engine/registry.js +191 -0
  30. package/dist/plugin/engine/registry.js.map +1 -0
  31. package/dist/plugin/engine/state.d.ts +31 -0
  32. package/dist/plugin/engine/state.d.ts.map +1 -0
  33. package/dist/plugin/engine/state.js +116 -0
  34. package/dist/plugin/engine/state.js.map +1 -0
  35. package/dist/plugin/engine/task-tracker.d.ts +66 -0
  36. package/dist/plugin/engine/task-tracker.d.ts.map +1 -0
  37. package/dist/plugin/engine/task-tracker.js +124 -0
  38. package/dist/plugin/engine/task-tracker.js.map +1 -0
  39. package/dist/plugin/engine/types.d.ts +349 -0
  40. package/dist/plugin/engine/types.d.ts.map +1 -0
  41. package/dist/plugin/engine/types.js +3 -0
  42. package/dist/plugin/engine/types.js.map +1 -0
  43. package/dist/plugin/engine/validator.d.ts +52 -0
  44. package/dist/plugin/engine/validator.d.ts.map +1 -0
  45. package/dist/plugin/engine/validator.js +457 -0
  46. package/dist/plugin/engine/validator.js.map +1 -0
  47. package/dist/plugin/engine/verifier.d.ts +61 -0
  48. package/dist/plugin/engine/verifier.d.ts.map +1 -0
  49. package/dist/plugin/engine/verifier.js +441 -0
  50. package/dist/plugin/engine/verifier.js.map +1 -0
  51. package/dist/plugin/hooks/context-injection.d.ts +11 -0
  52. package/dist/plugin/hooks/context-injection.d.ts.map +1 -0
  53. package/dist/plugin/hooks/context-injection.js +88 -0
  54. package/dist/plugin/hooks/context-injection.js.map +1 -0
  55. package/dist/plugin/hooks/event-handlers.d.ts +9 -0
  56. package/dist/plugin/hooks/event-handlers.d.ts.map +1 -0
  57. package/dist/plugin/hooks/event-handlers.js +10 -0
  58. package/dist/plugin/hooks/event-handlers.js.map +1 -0
  59. package/dist/plugin/hooks/workflow-gate.d.ts +24 -0
  60. package/dist/plugin/hooks/workflow-gate.d.ts.map +1 -0
  61. package/dist/plugin/hooks/workflow-gate.js +78 -0
  62. package/dist/plugin/hooks/workflow-gate.js.map +1 -0
  63. package/dist/plugin/index.d.ts +423 -0
  64. package/dist/plugin/index.d.ts.map +1 -0
  65. package/dist/plugin/index.js +253 -0
  66. package/dist/plugin/index.js.map +1 -0
  67. package/dist/plugin/tools/spec-artifact-instr.d.ts +7 -0
  68. package/dist/plugin/tools/spec-artifact-instr.d.ts.map +1 -0
  69. package/dist/plugin/tools/spec-artifact-instr.js +73 -0
  70. package/dist/plugin/tools/spec-artifact-instr.js.map +1 -0
  71. package/dist/plugin/tools/spec-change-archive.d.ts +6 -0
  72. package/dist/plugin/tools/spec-change-archive.d.ts.map +1 -0
  73. package/dist/plugin/tools/spec-change-archive.js +62 -0
  74. package/dist/plugin/tools/spec-change-archive.js.map +1 -0
  75. package/dist/plugin/tools/spec-change-list.d.ts +3 -0
  76. package/dist/plugin/tools/spec-change-list.d.ts.map +1 -0
  77. package/dist/plugin/tools/spec-change-list.js +38 -0
  78. package/dist/plugin/tools/spec-change-list.js.map +1 -0
  79. package/dist/plugin/tools/spec-change-new.d.ts +7 -0
  80. package/dist/plugin/tools/spec-change-new.d.ts.map +1 -0
  81. package/dist/plugin/tools/spec-change-new.js +47 -0
  82. package/dist/plugin/tools/spec-change-new.js.map +1 -0
  83. package/dist/plugin/tools/spec-change-status.d.ts +6 -0
  84. package/dist/plugin/tools/spec-change-status.d.ts.map +1 -0
  85. package/dist/plugin/tools/spec-change-status.js +43 -0
  86. package/dist/plugin/tools/spec-change-status.js.map +1 -0
  87. package/dist/plugin/tools/spec-design-critique.d.ts +20 -0
  88. package/dist/plugin/tools/spec-design-critique.d.ts.map +1 -0
  89. package/dist/plugin/tools/spec-design-critique.js +412 -0
  90. package/dist/plugin/tools/spec-design-critique.js.map +1 -0
  91. package/dist/plugin/tools/spec-design-hifi.d.ts +119 -0
  92. package/dist/plugin/tools/spec-design-hifi.d.ts.map +1 -0
  93. package/dist/plugin/tools/spec-design-hifi.js +653 -0
  94. package/dist/plugin/tools/spec-design-hifi.js.map +1 -0
  95. package/dist/plugin/tools/spec-design-wireframe.d.ts +91 -0
  96. package/dist/plugin/tools/spec-design-wireframe.d.ts.map +1 -0
  97. package/dist/plugin/tools/spec-design-wireframe.js +357 -0
  98. package/dist/plugin/tools/spec-design-wireframe.js.map +1 -0
  99. package/dist/plugin/tools/spec-init.d.ts +9 -0
  100. package/dist/plugin/tools/spec-init.d.ts.map +1 -0
  101. package/dist/plugin/tools/spec-init.js +58 -0
  102. package/dist/plugin/tools/spec-init.js.map +1 -0
  103. package/dist/plugin/tools/spec-integrity-check.d.ts +6 -0
  104. package/dist/plugin/tools/spec-integrity-check.d.ts.map +1 -0
  105. package/dist/plugin/tools/spec-integrity-check.js +19 -0
  106. package/dist/plugin/tools/spec-integrity-check.js.map +1 -0
  107. package/dist/plugin/tools/spec-registry-update.d.ts +3 -0
  108. package/dist/plugin/tools/spec-registry-update.d.ts.map +1 -0
  109. package/dist/plugin/tools/spec-registry-update.js +34 -0
  110. package/dist/plugin/tools/spec-registry-update.js.map +1 -0
  111. package/dist/plugin/tools/spec-schema-list.d.ts +3 -0
  112. package/dist/plugin/tools/spec-schema-list.d.ts.map +1 -0
  113. package/dist/plugin/tools/spec-schema-list.js +28 -0
  114. package/dist/plugin/tools/spec-schema-list.js.map +1 -0
  115. package/dist/plugin/tools/spec-specs-apply.d.ts +7 -0
  116. package/dist/plugin/tools/spec-specs-apply.d.ts.map +1 -0
  117. package/dist/plugin/tools/spec-specs-apply.js +49 -0
  118. package/dist/plugin/tools/spec-specs-apply.js.map +1 -0
  119. package/dist/plugin/tools/spec-task-progress.d.ts +8 -0
  120. package/dist/plugin/tools/spec-task-progress.d.ts.map +1 -0
  121. package/dist/plugin/tools/spec-task-progress.js +96 -0
  122. package/dist/plugin/tools/spec-task-progress.js.map +1 -0
  123. package/dist/plugin/tools/spec-validate.d.ts +21 -0
  124. package/dist/plugin/tools/spec-validate.d.ts.map +1 -0
  125. package/dist/plugin/tools/spec-validate.js +182 -0
  126. package/dist/plugin/tools/spec-validate.js.map +1 -0
  127. package/dist/plugin/tools/spec-verify.d.ts +7 -0
  128. package/dist/plugin/tools/spec-verify.d.ts.map +1 -0
  129. package/dist/plugin/tools/spec-verify.js +50 -0
  130. package/dist/plugin/tools/spec-verify.js.map +1 -0
  131. package/dist/plugin/tools/util.d.ts +25 -0
  132. package/dist/plugin/tools/util.d.ts.map +1 -0
  133. package/dist/plugin/tools/util.js +33 -0
  134. package/dist/plugin/tools/util.js.map +1 -0
  135. package/package.json +61 -0
  136. package/src/agents/orchestrator.md +158 -0
  137. package/src/agents/spec-apply.md +114 -0
  138. package/src/agents/spec-archive.md +103 -0
  139. package/src/agents/spec-propose.md +120 -0
  140. package/src/agents/spec-verify.md +103 -0
  141. package/src/commands/spec-init.md +6 -0
  142. package/src/commands/spec-onboard.md +6 -0
  143. package/src/commands/spec-status.md +6 -0
  144. package/src/commands/spec-sync.md +6 -0
  145. package/src/schemas/hybrid.yaml +144 -0
  146. package/src/schemas/spec-driven.yaml +155 -0
  147. package/src/schemas/tdd.yaml +203 -0
  148. package/src/skills/playwright-cli/SKILL.md +388 -0
  149. package/src/skills/playwright-cli/references/element-attributes.md +23 -0
  150. package/src/skills/playwright-cli/references/playwright-tests.md +39 -0
  151. package/src/skills/playwright-cli/references/request-mocking.md +87 -0
  152. package/src/skills/playwright-cli/references/running-code.md +241 -0
  153. package/src/skills/playwright-cli/references/session-management.md +225 -0
  154. package/src/skills/playwright-cli/references/spec-driven-testing.md +305 -0
  155. package/src/skills/playwright-cli/references/storage-state.md +275 -0
  156. package/src/skills/playwright-cli/references/test-generation.md +134 -0
  157. package/src/skills/playwright-cli/references/tracing.md +139 -0
  158. package/src/skills/playwright-cli/references/video-recording.md +143 -0
  159. package/src/skills/spec-init/SKILL.md +61 -0
  160. package/src/skills/spec-onboard/SKILL.md +178 -0
  161. package/src/skills/spec-status/SKILL.md +72 -0
  162. package/src/skills/spec-sync/SKILL.md +63 -0
  163. package/src/templates/config.yaml +14 -0
  164. package/src/templates/design-hifi.yaml +580 -0
  165. package/src/templates/design-tech.yaml +42 -0
  166. package/src/templates/design-wireframe.yaml +114 -0
  167. package/src/templates/proposal.yaml +43 -0
  168. package/src/templates/registry.yaml +3 -0
  169. package/src/templates/spec.yaml +56 -0
  170. package/src/templates/tasks.yaml +58 -0
@@ -0,0 +1,6 @@
1
+ ---
2
+ description: Initialize the spec/ directory structure for a new project
3
+ ---
4
+
5
+ Load the spec-init skill and follow its instructions.
6
+ Arguments: $ARGUMENTS
@@ -0,0 +1,6 @@
1
+ ---
2
+ description: Guided onboarding tutorial for spec-native
3
+ ---
4
+
5
+ Load the spec-onboard skill and follow its instructions.
6
+ Arguments: $ARGUMENTS
@@ -0,0 +1,6 @@
1
+ ---
2
+ description: Show status of spec changes
3
+ ---
4
+
5
+ Load the spec-status skill and follow its instructions.
6
+ Arguments: $ARGUMENTS
@@ -0,0 +1,6 @@
1
+ ---
2
+ description: Sync delta specs to main specs
3
+ ---
4
+
5
+ Load the spec-sync skill and follow its instructions.
6
+ Arguments: $ARGUMENTS
@@ -0,0 +1,144 @@
1
+ name: hybrid
2
+ version: 1
3
+ description: Combined workflow - spec-driven planning with TDD implementation
4
+
5
+ artifacts:
6
+ - id: proposal
7
+ generates: proposal.yaml
8
+ description: Change proposal with capabilities and acceptance criteria
9
+ template: proposal.yaml
10
+ instruction: |
11
+ Create a proposal that combines:
12
+ 1. Capability-based thinking (what behaviors?)
13
+ 2. Testable acceptance criteria (how to verify?)
14
+
15
+ For each capability:
16
+ - Define the behavior
17
+ - List acceptance criteria
18
+ - Identify test interfaces
19
+ requires: []
20
+
21
+ - id: specs
22
+ generates: specs/*.yaml
23
+ description: Specifications with scenarios and verification
24
+ template: spec.yaml
25
+ instruction: |
26
+ Create specs that are both:
27
+ - Behavior-focused (like spec-driven)
28
+ - Test-oriented (like TDD)
29
+
30
+ For each requirement:
31
+ - Use clear requirement IDs
32
+ - Write Given/When/Then scenarios
33
+ - Add verify blocks with testable assertions
34
+ - Specify test interface when relevant
35
+ requires: [proposal]
36
+
37
+ - id: design-tech
38
+ generates: design-tech.yaml
39
+ description: Technical design with testability considerations
40
+ template: design-tech.yaml
41
+ instruction: |
42
+ Create a design that covers:
43
+ 1. Architecture decisions (spec-driven style)
44
+ 2. Testability decisions (TDD style)
45
+ 3. Implementation approach
46
+
47
+ Balance between:
48
+ - High-level architecture
49
+ - Test-friendly interfaces
50
+ - Practical implementation concerns
51
+ requires: [specs]
52
+
53
+ - id: design-wireframe
54
+ generates: design-wireframe.yaml
55
+ description: Page wireframes with layouts, component placements, user flows, and annotations
56
+ template: design-wireframe.yaml
57
+ optional: true
58
+ instruction: |
59
+ Create wireframe specifications for the change's UI pages.
60
+
61
+ Only create this artifact if the change involves user-facing UI changes.
62
+ If the change is backend-only, infrastructure, or has no visual component,
63
+ skip this artifact.
64
+
65
+ Include:
66
+ 1. Pages - list all UI pages/screens with their layout regions
67
+ 2. Layout - define regions (header, sidebar, main, footer) with ordering
68
+ 3. Components - place UI components (buttons, cards, inputs, etc.) in regions with positions and sizes
69
+ 4. Flows - document user navigation paths between pages
70
+ 5. Annotations - add notes about constraints, edge cases, design decisions
71
+
72
+ Use kebab-case for page IDs, component IDs, and flow IDs.
73
+ Position coordinates use a 12-column grid system (0-11).
74
+
75
+ The optional html_preview flag generates a visual wireframe preview.
76
+ requires: [design-tech]
77
+
78
+ - id: design-hifi
79
+ generates: design-hifi.yaml
80
+ description: High-fidelity design system specification with color, typography, spacing, and components
81
+ template: design-hifi.yaml
82
+ optional: true
83
+ instruction: |
84
+ Create a high-fidelity design system specification.
85
+
86
+ Only create this artifact if the change requires visual design decisions.
87
+ Can be created directly after wireframes, or skipped if only wireframes are needed.
88
+
89
+ Include:
90
+ 1. Color Palette - primary, secondary, accent, neutral, semantic, and surface colors with hex values
91
+ 2. Typography - font families, type scale with sizes/weights/line-heights, hierarchy roles
92
+ 3. Spacing - base unit and spacing scale
93
+ 4. Component Library - button, card, input, and navigation variants with states
94
+ 5. Breakpoints - responsive breakpoints with column counts and rules
95
+
96
+ Use hex format (#RRGGBB) for all colors.
97
+ The type scale should cover h1-h6, body, caption, and small roles.
98
+
99
+ The optional html_preview flag generates a visual style guide preview.
100
+ requires: [design-wireframe]
101
+
102
+ - id: tasks
103
+ generates: tasks.yaml
104
+ description: Tasks organized by feature with optional TDD phases
105
+ template: tasks.yaml
106
+ instruction: |
107
+ Organize tasks by feature/capability.
108
+
109
+ For each feature, you can:
110
+ - Use standard tasks (implement, test, verify)
111
+ - OR use TDD phases (red, green, refactor)
112
+
113
+ Use tdd_phase field when TDD is appropriate:
114
+ - Complex logic that benefits from test-first
115
+ - Critical paths that need high confidence
116
+ - Areas with unclear requirements
117
+
118
+ Use standard tasks for:
119
+ - Simple CRUD operations
120
+ - Configuration changes
121
+ - Documentation updates
122
+
123
+ Mix and match based on what makes sense.
124
+ requires: [specs, design-tech]
125
+
126
+ apply:
127
+ requires: [tasks]
128
+ tracks: tasks.yaml
129
+ instruction: |
130
+ Implement tasks in dependency order.
131
+
132
+ For TDD tasks (with tdd_phase):
133
+ - Follow strict RED-GREEN-REFACTOR cycle
134
+ - Write test first, confirm failure
135
+ - Implement minimal code, confirm pass
136
+ - Refactor, run all tests
137
+
138
+ For standard tasks:
139
+ - Implement the change
140
+ - Write/update tests
141
+ - Verify acceptance criteria
142
+ - Update task status
143
+
144
+ Adapt your approach to the task type.
@@ -0,0 +1,155 @@
1
+ name: spec-driven
2
+ version: 1
3
+ description: Standard spec-driven workflow with proposal, specs, design, and tasks
4
+
5
+ artifacts:
6
+ - id: proposal
7
+ generates: proposal.yaml
8
+ description: Change proposal with why, what, and impact
9
+ template: proposal.yaml
10
+ instruction: |
11
+ Create a proposal that explains:
12
+ 1. WHY this change is needed (problem statement)
13
+ 2. WHAT will change (new/modified capabilities)
14
+ 3. IMPACT on existing code (files, APIs, dependencies)
15
+
16
+ Be specific about capabilities - each becomes a spec file.
17
+ Use kebab-case for capability IDs.
18
+ requires: []
19
+
20
+ - id: specs
21
+ generates: specs/*.yaml
22
+ description: Delta specifications for each capability
23
+ template: spec.yaml
24
+ instruction: |
25
+ Create one spec file per capability listed in the proposal.
26
+
27
+ For NEW capabilities:
28
+ - Use op: add for each requirement
29
+ - Each requirement must have at least one scenario
30
+ - Scenarios use given/when/then format
31
+ - Add verify blocks for testable assertions
32
+
33
+ For MODIFIED capabilities:
34
+ - Read the existing spec from spec/main/<capability>.yaml
35
+ - Use op: modify with the complete updated requirement
36
+ - Use op: add for new requirements
37
+ - Use op: remove for deprecated requirements
38
+
39
+ Use SHALL/MUST for normative requirements.
40
+ Keep requirements focused - one behavior per requirement.
41
+ requires: [proposal]
42
+
43
+ - id: design-tech
44
+ generates: design-tech.yaml
45
+ description: Technical design with architecture decisions
46
+ template: design-tech.yaml
47
+ instruction: |
48
+ Create a design document that explains HOW to implement the change.
49
+
50
+ Include:
51
+ 1. Context - current state and constraints
52
+ 2. Goals - what this design achieves
53
+ 3. Non-goals - what's explicitly out of scope
54
+ 4. Decisions - key technical choices with alternatives considered
55
+ 5. Risks - known issues and mitigations
56
+
57
+ Only create design-tech.yaml if the change:
58
+ - Crosses multiple services/modules
59
+ - Introduces new dependencies
60
+ - Has security/performance/migration complexity
61
+ - Benefits from technical decisions before coding
62
+
63
+ For simple changes, you can skip this artifact.
64
+ requires: [proposal]
65
+
66
+ - id: design-wireframe
67
+ generates: design-wireframe.yaml
68
+ description: Page wireframes with layouts, component placements, user flows, and annotations
69
+ template: design-wireframe.yaml
70
+ optional: true
71
+ instruction: |
72
+ Create wireframe specifications for the change's UI pages.
73
+
74
+ Only create this artifact if the change involves user-facing UI changes.
75
+ If the change is backend-only, infrastructure, or has no visual component,
76
+ skip this artifact.
77
+
78
+ Include:
79
+ 1. Pages - list all UI pages/screens with their layout regions
80
+ 2. Layout - define regions (header, sidebar, main, footer) with ordering
81
+ 3. Components - place UI components (buttons, cards, inputs, etc.) in regions with positions and sizes
82
+ 4. Flows - document user navigation paths between pages
83
+ 5. Annotations - add notes about constraints, edge cases, design decisions
84
+
85
+ Use kebab-case for page IDs, component IDs, and flow IDs.
86
+ Position coordinates use a 12-column grid system (0-11).
87
+
88
+ The optional html_preview flag generates a visual wireframe preview.
89
+ requires: [design-tech]
90
+
91
+ - id: design-hifi
92
+ generates: design-hifi.yaml
93
+ description: High-fidelity design system specification with color, typography, spacing, and components
94
+ template: design-hifi.yaml
95
+ optional: true
96
+ instruction: |
97
+ Create a high-fidelity design system specification.
98
+
99
+ Only create this artifact if the change requires visual design decisions.
100
+ Can be created directly after wireframes, or skipped if only wireframes are needed.
101
+
102
+ Include:
103
+ 1. Color Palette - primary, secondary, accent, neutral, semantic, and surface colors with hex values
104
+ 2. Typography - font families, type scale with sizes/weights/line-heights, hierarchy roles
105
+ 3. Spacing - base unit and spacing scale
106
+ 4. Component Library - button, card, input, and navigation variants with states
107
+ 5. Breakpoints - responsive breakpoints with column counts and rules
108
+
109
+ Use hex format (#RRGGBB) for all colors.
110
+ The type scale should cover h1-h6, body, caption, and small roles.
111
+
112
+ The optional html_preview flag generates a visual style guide preview.
113
+ requires: [design-wireframe]
114
+
115
+ - id: tasks
116
+ generates: tasks.yaml
117
+ description: Implementation task list with dependencies
118
+ template: tasks.yaml
119
+ instruction: |
120
+ Break the implementation into concrete tasks.
121
+
122
+ Each task must:
123
+ - Have a unique ID (t1, t2, t3, ...)
124
+ - Belong to a group (Database, Auth, API, UI, etc.)
125
+ - List dependencies (other task IDs)
126
+ - Estimate complexity (low/medium/high)
127
+ - Estimate time in minutes
128
+ - Reference specs (capability/requirement)
129
+ - List affected files
130
+ - Define acceptance criteria
131
+
132
+ Order tasks by dependency (what must be done first?).
133
+ Keep tasks small enough to complete in one session.
134
+ Each task should be independently verifiable.
135
+ requires: [specs, design-tech]
136
+
137
+ apply:
138
+ requires: [tasks]
139
+ tracks: tasks.yaml
140
+ instruction: |
141
+ Implement tasks in dependency order.
142
+
143
+ For each task:
144
+ 1. Read the task details and acceptance criteria
145
+ 2. Read referenced specs for context
146
+ 3. Implement the changes
147
+ 4. Verify acceptance criteria are met
148
+ 5. Update task status to "done"
149
+
150
+ Pause if:
151
+ - Task is unclear (ask for clarification)
152
+ - Design issue discovered (suggest design update)
153
+ - Error or blocker (report and wait)
154
+
155
+ Keep changes minimal and scoped to the task.
@@ -0,0 +1,203 @@
1
+ name: tdd
2
+ version: 1
3
+ description: Test-driven development with RED-GREEN-REFACTOR vertical slices
4
+
5
+ artifacts:
6
+ - id: proposal
7
+ generates: proposal.yaml
8
+ description: Change proposal with testable acceptance criteria
9
+ template: proposal.yaml
10
+ instruction: |
11
+ Create a proposal focused on BEHAVIORS to implement.
12
+
13
+ For each capability:
14
+ - Define the behavior in testable terms
15
+ - List acceptance criteria that can be verified
16
+ - Identify the public interface to test through
17
+
18
+ Use language like:
19
+ "The system SHALL allow users to..."
20
+ "When X happens, the system MUST..."
21
+ requires: []
22
+
23
+ - id: specs
24
+ generates: specs/*.yaml
25
+ description: Requirements with Gherkin scenarios and verification
26
+ template: spec.yaml
27
+ instruction: |
28
+ Create specs with a TDD focus:
29
+
30
+ For each requirement:
31
+ - Use REQ-N naming (REQ-1, REQ-2, ...)
32
+ - Write scenarios in Gherkin format (Given/When/Then)
33
+ - Specify "Test through: <interface>" for each requirement
34
+ - Add verify blocks with executable test code
35
+
36
+ Example:
37
+ ```yaml
38
+ operations:
39
+ - op: add
40
+ requirement:
41
+ id: REQ-1
42
+ description: The system SHALL export data as CSV
43
+ scenarios:
44
+ - id: export-csv
45
+ given: [user has existing data]
46
+ when: [export is called with format "csv"]
47
+ then: [returns CSV file with all data]
48
+ verify:
49
+ - type: assertion
50
+ code: "result.format === 'csv' && result.data.length > 0"
51
+ ```
52
+
53
+ Each scenario maps directly to a test case.
54
+ requires: [proposal]
55
+
56
+ - id: design-tech
57
+ generates: design-tech.yaml
58
+ description: Technical design with testability decisions
59
+ template: design-tech.yaml
60
+ instruction: |
61
+ Create a design focused on TESTABILITY:
62
+
63
+ Include:
64
+ 1. Testability Decisions
65
+ - How to inject dependencies
66
+ - What interfaces to test through
67
+ - Mocking strategy
68
+ 2. Interface Contracts
69
+ - Public APIs to test through
70
+ - Input/output types
71
+ - Error conditions
72
+ 3. Test Architecture
73
+ - Test file structure
74
+ - Test utilities needed
75
+ - Integration vs unit test boundaries
76
+
77
+ Design principles:
78
+ - Accept dependencies as parameters
79
+ - Return results, don't produce side effects
80
+ - Keep surface area small
81
+ requires: [specs]
82
+
83
+ - id: design-wireframe
84
+ generates: design-wireframe.yaml
85
+ description: Page wireframes with layouts, component placements, user flows, and annotations
86
+ template: design-wireframe.yaml
87
+ optional: true
88
+ instruction: |
89
+ Create wireframe specifications for the change's UI pages.
90
+
91
+ Only create this artifact if the change involves user-facing UI changes.
92
+ If the change is backend-only, infrastructure, or has no visual component,
93
+ skip this artifact.
94
+
95
+ Include:
96
+ 1. Pages - list all UI pages/screens with their layout regions
97
+ 2. Layout - define regions (header, sidebar, main, footer) with ordering
98
+ 3. Components - place UI components (buttons, cards, inputs, etc.) in regions with positions and sizes
99
+ 4. Flows - document user navigation paths between pages
100
+ 5. Annotations - add notes about constraints, edge cases, design decisions
101
+
102
+ Use kebab-case for page IDs, component IDs, and flow IDs.
103
+ Position coordinates use a 12-column grid system (0-11).
104
+
105
+ The optional html_preview flag generates a visual wireframe preview.
106
+ requires: [design-tech]
107
+
108
+ - id: design-hifi
109
+ generates: design-hifi.yaml
110
+ description: High-fidelity design system specification with color, typography, spacing, and components
111
+ template: design-hifi.yaml
112
+ optional: true
113
+ instruction: |
114
+ Create a high-fidelity design system specification.
115
+
116
+ Only create this artifact if the change requires visual design decisions.
117
+ Can be created directly after wireframes, or skipped if only wireframes are needed.
118
+
119
+ Include:
120
+ 1. Color Palette - primary, secondary, accent, neutral, semantic, and surface colors with hex values
121
+ 2. Typography - font families, type scale with sizes/weights/line-heights, hierarchy roles
122
+ 3. Spacing - base unit and spacing scale
123
+ 4. Component Library - button, card, input, and navigation variants with states
124
+ 5. Breakpoints - responsive breakpoints with column counts and rules
125
+
126
+ Use hex format (#RRGGBB) for all colors.
127
+ The type scale should cover h1-h6, body, caption, and small roles.
128
+
129
+ The optional html_preview flag generates a visual style guide preview.
130
+ requires: [design-wireframe]
131
+
132
+ - id: tasks
133
+ generates: tasks.yaml
134
+ description: Vertical slice tasks in RED-GREEN-REFACTOR cycles
135
+ template: tasks.yaml
136
+ instruction: |
137
+ Organize tasks as VERTICAL SLICES - one behavior at a time.
138
+
139
+ For each behavior (requirement):
140
+ 1. RED phase tasks:
141
+ - Write failing test
142
+ - Run test to confirm failure
143
+ 2. GREEN phase tasks:
144
+ - Write minimal implementation
145
+ - Run test to confirm pass
146
+ 3. REFACTOR phase tasks:
147
+ - Clean up code
148
+ - Run all tests
149
+
150
+ Use tdd_phase field: red, green, refactor
151
+
152
+ Example:
153
+ ```yaml
154
+ tasks:
155
+ - id: t1
156
+ group: Export Feature
157
+ description: Write failing test for CSV export
158
+ tdd_phase: red
159
+ depends_on: []
160
+ spec_refs: [export/REQ-1]
161
+ - id: t2
162
+ group: Export Feature
163
+ description: Implement CSV export to pass test
164
+ tdd_phase: green
165
+ depends_on: [t1]
166
+ spec_refs: [export/REQ-1]
167
+ - id: t3
168
+ group: Export Feature
169
+ description: Refactor export code
170
+ tdd_phase: refactor
171
+ depends_on: [t2]
172
+ spec_refs: [export/REQ-1]
173
+ ```
174
+
175
+ NEVER batch all RED tasks together.
176
+ Complete the full cycle for one behavior before starting the next.
177
+ requires: [specs, design-tech]
178
+
179
+ apply:
180
+ requires: [tasks]
181
+ tracks: tasks.yaml
182
+ instruction: |
183
+ Implement using strict TDD cycle:
184
+
185
+ For each behavior:
186
+ 1. RED: Write the failing test FIRST
187
+ - Run the test
188
+ - Confirm it fails (not passes!)
189
+ 2. GREEN: Write minimal code to pass
190
+ - No extra features
191
+ - No anticipating future tests
192
+ - Run the test
193
+ - Confirm it passes
194
+ 3. REFACTOR: Clean up
195
+ - Remove duplication
196
+ - Improve naming
197
+ - Run ALL tests
198
+ - Confirm nothing broke
199
+
200
+ Then move to the next behavior.
201
+
202
+ If a test is hard to write, the design needs work.
203
+ If you're stuck, go back to the design artifact.