@ncoderz/awa 1.7.2 → 1.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (155) hide show
  1. package/LICENSE +23 -16
  2. package/README.md +25 -27
  3. package/dist/chunk-EL7ZWFXO.js +875 -0
  4. package/dist/chunk-EL7ZWFXO.js.map +1 -0
  5. package/dist/{chunk-OQZTQ5ZI.js → chunk-LRQWZCYL.js} +1 -4
  6. package/dist/chunk-LRQWZCYL.js.map +1 -0
  7. package/dist/{config-WL3SLSP6.js → config-EJIXC7D7.js} +2 -2
  8. package/dist/index.js +1257 -452
  9. package/dist/index.js.map +1 -1
  10. package/dist/renumber-TLBGOWZM.js +9 -0
  11. package/dist/renumber-TLBGOWZM.js.map +1 -0
  12. package/package.json +13 -6
  13. package/templates/awa/.agent/skills/spec-merge/SKILL.md +3 -0
  14. package/templates/awa/.agent/skills/spec-tidy/SKILL.md +3 -0
  15. package/templates/awa/.agent/workflows/spec-merge.md +3 -0
  16. package/templates/awa/.agent/workflows/spec-tidy.md +3 -0
  17. package/templates/awa/.agents/skills/spec-merge/SKILL.md +3 -0
  18. package/templates/awa/.agents/skills/spec-tidy/SKILL.md +3 -0
  19. package/templates/awa/.awa/.agent/schemas/ALIGN_REPORT.schema.yaml +1 -1
  20. package/templates/awa/.awa/.agent/schemas/API.schema.yaml +1 -1
  21. package/templates/awa/.awa/.agent/schemas/ARCHITECTURE.schema.yaml +7 -0
  22. package/templates/awa/.awa/.agent/schemas/DESIGN.schema.yaml +1 -1
  23. package/templates/awa/.awa/.agent/schemas/{EXAMPLES.schema.yaml → EXAMPLE.schema.yaml} +4 -4
  24. package/templates/awa/.awa/.agent/schemas/FEAT.schema.yaml +8 -1
  25. package/templates/awa/.awa/.agent/schemas/PLAN.schema.yaml +1 -1
  26. package/templates/awa/.awa/.agent/schemas/README.schema.yaml +1 -1
  27. package/templates/awa/.awa/.agent/schemas/REQ.schema.yaml +1 -1
  28. package/templates/awa/.awa/.agent/schemas/TASK.schema.yaml +1 -1
  29. package/templates/awa/.claude/skills/spec-merge/SKILL.md +3 -0
  30. package/templates/awa/.claude/skills/spec-tidy/SKILL.md +3 -0
  31. package/templates/awa/.gemini/commands/spec-merge.md +3 -0
  32. package/templates/awa/.gemini/commands/spec-tidy.md +3 -0
  33. package/templates/awa/.gemini/skills/spec-merge/SKILL.md +3 -0
  34. package/templates/awa/.gemini/skills/spec-tidy/SKILL.md +3 -0
  35. package/templates/awa/.github/prompts/awa.spec-merge.prompt.md +8 -0
  36. package/templates/awa/.github/prompts/awa.spec-tidy.prompt.md +7 -0
  37. package/templates/awa/.github/skills/spec-merge/SKILL.md +3 -0
  38. package/templates/awa/.github/skills/spec-tidy/SKILL.md +3 -0
  39. package/templates/awa/.kilocode/skills/spec-merge/SKILL.md +3 -0
  40. package/templates/awa/.kilocode/skills/spec-tidy/SKILL.md +3 -0
  41. package/templates/awa/.kilocode/workflows/spec-merge.md +3 -0
  42. package/templates/awa/.kilocode/workflows/spec-tidy.md +3 -0
  43. package/templates/awa/.opencode/commands/spec-merge.md +3 -0
  44. package/templates/awa/.opencode/commands/spec-tidy.md +3 -0
  45. package/templates/awa/.opencode/skills/spec-merge/SKILL.md +3 -0
  46. package/templates/awa/.opencode/skills/spec-tidy/SKILL.md +3 -0
  47. package/templates/awa/.qwen/commands/spec-merge.md +3 -0
  48. package/templates/awa/.qwen/commands/spec-tidy.md +3 -0
  49. package/templates/awa/.qwen/skills/spec-merge/SKILL.md +3 -0
  50. package/templates/awa/.qwen/skills/spec-tidy/SKILL.md +3 -0
  51. package/templates/awa/.roo/skills/spec-merge/SKILL.md +3 -0
  52. package/templates/awa/.roo/skills/spec-tidy/SKILL.md +3 -0
  53. package/templates/awa/.windsurf/skills/spec-merge/SKILL.md +3 -0
  54. package/templates/awa/.windsurf/skills/spec-tidy/SKILL.md +3 -0
  55. package/templates/awa/_delete.txt +4 -0
  56. package/templates/awa/_partials/_cmd.spec-merge.md +6 -0
  57. package/templates/awa/_partials/_cmd.spec-tidy.md +5 -0
  58. package/templates/awa/_partials/_skill.spec-merge.md +6 -0
  59. package/templates/awa/_partials/_skill.spec-tidy.md +6 -0
  60. package/templates/awa/_partials/awa.align.md +1 -1
  61. package/templates/awa/_partials/awa.brainstorm.md +1 -1
  62. package/templates/awa/_partials/awa.code.md +1 -1
  63. package/templates/awa/_partials/awa.core.md +9 -4
  64. package/templates/awa/_partials/awa.design.md +3 -2
  65. package/templates/awa/_partials/awa.documentation.md +1 -1
  66. package/templates/awa/_partials/awa.examples.md +4 -4
  67. package/templates/awa/_partials/awa.feature.md +2 -1
  68. package/templates/awa/_partials/awa.plan.md +2 -2
  69. package/templates/awa/_partials/awa.requirements.md +4 -2
  70. package/templates/awa/_partials/awa.spec-merge.md +97 -0
  71. package/templates/awa/_partials/awa.spec.tidy.md +92 -0
  72. package/templates/awa/_partials/awa.tasks.md +1 -1
  73. package/templates/awa/_partials/awa.upgrade.md +3 -3
  74. package/templates/awa/_partials/awa.usage.md +77 -6
  75. package/templates/awa/_partials/awa.vibe.md +1 -1
  76. package/templates/awa/_tests/claude/.awa/.agent/awa.core.md +126 -0
  77. package/templates/awa/_tests/claude/.awa/.agent/schemas/ALIGN_REPORT.schema.yaml +83 -0
  78. package/templates/awa/_tests/claude/.awa/.agent/schemas/API.schema.yaml +7 -0
  79. package/templates/awa/_tests/claude/.awa/.agent/schemas/ARCHITECTURE.schema.yaml +257 -0
  80. package/templates/awa/_tests/claude/.awa/.agent/schemas/DESIGN.schema.yaml +351 -0
  81. package/templates/awa/_tests/claude/.awa/.agent/schemas/EXAMPLE.schema.yaml +89 -0
  82. package/templates/awa/_tests/claude/.awa/.agent/schemas/FEAT.schema.yaml +142 -0
  83. package/templates/awa/_tests/claude/.awa/.agent/schemas/PLAN.schema.yaml +146 -0
  84. package/templates/awa/_tests/claude/.awa/.agent/schemas/README.schema.yaml +137 -0
  85. package/templates/awa/_tests/claude/.awa/.agent/schemas/REQ.schema.yaml +160 -0
  86. package/templates/awa/_tests/claude/.awa/.agent/schemas/TASK.schema.yaml +204 -0
  87. package/templates/awa/_tests/claude/.claude/agents/awa.md +137 -0
  88. package/templates/awa/_tests/claude/.claude/skills/awa-align/SKILL.md +67 -0
  89. package/templates/awa/_tests/claude/.claude/skills/awa-architecture/SKILL.md +50 -0
  90. package/templates/awa/_tests/claude/.claude/skills/awa-brainstorm/SKILL.md +57 -0
  91. package/templates/awa/_tests/claude/.claude/skills/awa-check/SKILL.md +79 -0
  92. package/templates/awa/_tests/claude/.claude/skills/awa-code/SKILL.md +179 -0
  93. package/templates/awa/_tests/claude/.claude/skills/awa-design/SKILL.md +62 -0
  94. package/templates/awa/_tests/claude/.claude/skills/awa-documentation/SKILL.md +91 -0
  95. package/templates/awa/_tests/claude/.claude/skills/awa-examples/SKILL.md +58 -0
  96. package/templates/awa/_tests/claude/.claude/skills/awa-feature/SKILL.md +56 -0
  97. package/templates/awa/_tests/claude/.claude/skills/awa-plan/SKILL.md +53 -0
  98. package/templates/awa/_tests/claude/.claude/skills/awa-refactor/SKILL.md +53 -0
  99. package/templates/awa/_tests/claude/.claude/skills/awa-requirements/SKILL.md +58 -0
  100. package/templates/awa/_tests/claude/.claude/skills/awa-tasks/SKILL.md +158 -0
  101. package/templates/awa/_tests/claude/.claude/skills/awa-upgrade/SKILL.md +68 -0
  102. package/templates/awa/_tests/claude/.claude/skills/awa-usage/SKILL.md +368 -0
  103. package/templates/awa/_tests/claude/.claude/skills/awa-vibe/SKILL.md +72 -0
  104. package/templates/awa/_tests/claude/.claude/skills/spec-merge/SKILL.md +102 -0
  105. package/templates/awa/_tests/claude/.claude/skills/spec-tidy/SKILL.md +97 -0
  106. package/templates/awa/_tests/claude/CLAUDE.md +132 -0
  107. package/templates/awa/_tests/copilot/.awa/.agent/awa.core.md +126 -0
  108. package/templates/awa/_tests/copilot/.awa/.agent/schemas/ALIGN_REPORT.schema.yaml +83 -0
  109. package/templates/awa/_tests/copilot/.awa/.agent/schemas/API.schema.yaml +7 -0
  110. package/templates/awa/_tests/copilot/.awa/.agent/schemas/ARCHITECTURE.schema.yaml +257 -0
  111. package/templates/awa/_tests/copilot/.awa/.agent/schemas/DESIGN.schema.yaml +351 -0
  112. package/templates/awa/_tests/copilot/.awa/.agent/schemas/EXAMPLE.schema.yaml +89 -0
  113. package/templates/awa/_tests/copilot/.awa/.agent/schemas/FEAT.schema.yaml +142 -0
  114. package/templates/awa/_tests/copilot/.awa/.agent/schemas/PLAN.schema.yaml +146 -0
  115. package/templates/awa/_tests/copilot/.awa/.agent/schemas/README.schema.yaml +137 -0
  116. package/templates/awa/_tests/copilot/.awa/.agent/schemas/REQ.schema.yaml +160 -0
  117. package/templates/awa/_tests/copilot/.awa/.agent/schemas/TASK.schema.yaml +204 -0
  118. package/templates/awa/_tests/copilot/.github/agents/awa.agent.md +137 -0
  119. package/templates/awa/_tests/copilot/.github/prompts/awa.align.prompt.md +67 -0
  120. package/templates/awa/_tests/copilot/.github/prompts/awa.architecture.prompt.md +50 -0
  121. package/templates/awa/_tests/copilot/.github/prompts/awa.brainstorm.prompt.md +57 -0
  122. package/templates/awa/_tests/copilot/.github/prompts/awa.check.prompt.md +79 -0
  123. package/templates/awa/_tests/copilot/.github/prompts/awa.code.prompt.md +179 -0
  124. package/templates/awa/_tests/copilot/.github/prompts/awa.design.prompt.md +62 -0
  125. package/templates/awa/_tests/copilot/.github/prompts/awa.documentation.prompt.md +91 -0
  126. package/templates/awa/_tests/copilot/.github/prompts/awa.examples.prompt.md +58 -0
  127. package/templates/awa/_tests/copilot/.github/prompts/awa.feature.prompt.md +56 -0
  128. package/templates/awa/_tests/copilot/.github/prompts/awa.plan.prompt.md +53 -0
  129. package/templates/awa/_tests/copilot/.github/prompts/awa.refactor.prompt.md +53 -0
  130. package/templates/awa/_tests/copilot/.github/prompts/awa.requirements.prompt.md +58 -0
  131. package/templates/awa/_tests/copilot/.github/prompts/awa.spec-merge.prompt.md +102 -0
  132. package/templates/awa/_tests/copilot/.github/prompts/awa.spec-tidy.prompt.md +96 -0
  133. package/templates/awa/_tests/copilot/.github/prompts/awa.tasks.prompt.md +158 -0
  134. package/templates/awa/_tests/copilot/.github/prompts/awa.upgrade.prompt.md +68 -0
  135. package/templates/awa/_tests/copilot/.github/prompts/awa.vibe.prompt.md +72 -0
  136. package/templates/awa/_tests/copilot/.github/skills/awa-align/SKILL.md +67 -0
  137. package/templates/awa/_tests/copilot/.github/skills/awa-architecture/SKILL.md +50 -0
  138. package/templates/awa/_tests/copilot/.github/skills/awa-brainstorm/SKILL.md +57 -0
  139. package/templates/awa/_tests/copilot/.github/skills/awa-check/SKILL.md +79 -0
  140. package/templates/awa/_tests/copilot/.github/skills/awa-code/SKILL.md +179 -0
  141. package/templates/awa/_tests/copilot/.github/skills/awa-design/SKILL.md +62 -0
  142. package/templates/awa/_tests/copilot/.github/skills/awa-documentation/SKILL.md +91 -0
  143. package/templates/awa/_tests/copilot/.github/skills/awa-examples/SKILL.md +58 -0
  144. package/templates/awa/_tests/copilot/.github/skills/awa-feature/SKILL.md +56 -0
  145. package/templates/awa/_tests/copilot/.github/skills/awa-plan/SKILL.md +53 -0
  146. package/templates/awa/_tests/copilot/.github/skills/awa-refactor/SKILL.md +53 -0
  147. package/templates/awa/_tests/copilot/.github/skills/awa-requirements/SKILL.md +58 -0
  148. package/templates/awa/_tests/copilot/.github/skills/awa-tasks/SKILL.md +158 -0
  149. package/templates/awa/_tests/copilot/.github/skills/awa-upgrade/SKILL.md +68 -0
  150. package/templates/awa/_tests/copilot/.github/skills/awa-usage/SKILL.md +368 -0
  151. package/templates/awa/_tests/copilot/.github/skills/awa-vibe/SKILL.md +72 -0
  152. package/templates/awa/_tests/copilot/.github/skills/spec-merge/SKILL.md +102 -0
  153. package/templates/awa/_tests/copilot/.github/skills/spec-tidy/SKILL.md +97 -0
  154. package/dist/chunk-OQZTQ5ZI.js.map +0 -1
  155. /package/dist/{config-WL3SLSP6.js.map → config-EJIXC7D7.js.map} +0 -0
@@ -0,0 +1,158 @@
1
+ ---
2
+ name: awa-tasks
3
+ description: Create or update task list documents. Use this when asked to create tasks, generate implementation steps, or break down requirements and designs into work items.
4
+ ---
5
+
6
+ # Create or Update Task List(s)
7
+
8
+ ## Bootstrap
9
+
10
+ <tool name="read_file">
11
+ <read path=".awa/.agent/awa.core.md" required="true" error="on not found" />
12
+ <read path=".awa/rules/*.md" required="true" />
13
+ <read path=".awa/specs/ARCHITECTURE.md" required="true" error="on not found" />
14
+ <read path=".awa/.agent/schemas/DESIGN.schema.yaml" optional="true" />
15
+ <read path=".awa/.agent/schemas/REQ.schema.yaml" optional="true" />
16
+ <read path=".awa/.agent/schemas/TASK.schema.yaml" required="true" error="on not found" />
17
+ </tool>
18
+
19
+ ## User Input
20
+
21
+ ```text
22
+ ${input}
23
+ ```
24
+
25
+ You **MUST** consider the user input before proceeding (if not empty).
26
+
27
+ ## Inputs
28
+
29
+ <file type="architecture" path=".awa/specs/ARCHITECTURE.md" />
30
+ <file type="feat" path=".awa/specs/FEAT-{CODE}-{feature-name}.md" required="if relevant" />
31
+ <file type="examples" path=".awa/specs/EXAMPLE-{CODE}-{feature-name}-{nnn}.md" required="if relevant" />
32
+ <file type="requirements" path=".awa/specs/REQ-{CODE}-{feature-name}.md" required="if relevant" />
33
+ <file type="design" path=".awa/specs/DESIGN-{CODE}-{feature-name}.md" required="if relevant" />
34
+ <file type="api" path=".awa/specs/API-{CODE}-{feature-name}.md" required="if relevant" />
35
+
36
+ ## Action
37
+
38
+ Update or create the task list document(s) as specified in the instruction above, following awa conventions.
39
+
40
+ ## Process
41
+
42
+ 1. PARSE REQ
43
+ - Extract requirements ({CODE}-{n}) with priorities (must/should/could)
44
+ - Extract acceptance criteria ({CODE}-{n}[.{p}]_AC-{m}) with types
45
+ - Note dependencies between requirements
46
+ - Identify testable criteria
47
+
48
+ 2. PARSE DESIGN
49
+ - Extract components ({CODE}-{ComponentName}) and interfaces
50
+ - Map IMPLEMENTS references (component → ACs)
51
+ - Extract properties ({CODE}_P-{n}) and VALIDATES references
52
+ - Note architectural decisions and constraints
53
+ - Extract error types for error handling tasks
54
+
55
+ 3. IF ARCH PROVIDED
56
+ - Extract project structure for file paths
57
+ - Extract technology stack for setup tasks
58
+ - Note architectural rules as constraints
59
+
60
+ 4. GENERATE TASKS
61
+ - Phase 1: Setup (project initialization, dependencies)
62
+ - Phase 2: Foundation (shared types, core interfaces, error types)
63
+ - Phase 3+: One phase per requirement (priority order: must → should → could)
64
+ - Final Phase: Integration and polish
65
+ - Include test tasks based on properties and ACs
66
+
67
+ 5. VALIDATE
68
+ - Every AC has at least one implementing task
69
+ - Every P has a test task
70
+ - No orphan tasks (all trace to AC or P)
71
+ - Dependencies respect component order from DESIGN
72
+
73
+ ## Task Organization
74
+
75
+ ### From Requirements
76
+
77
+ - Each requirement ({CODE}-{n}) becomes a phase (priority order)
78
+ - All ACs for that requirement → tasks within its phase
79
+ - Subrequirements ({CODE}-{n}.{p}) nest under parent phase
80
+
81
+ ### From Design Components
82
+
83
+ - Each component → one or more implementation tasks
84
+ - Component's IMPLEMENTS list → task's IMPLEMENTS line
85
+ - Component interface → task description specifics
86
+
87
+ ### From Properties
88
+
89
+ - Each property ({CODE}_P-{n}) → test task
90
+ - Property's VALIDATES list → determines test assertions
91
+ - Property type determines test approach:
92
+ - Invariants → property-based tests
93
+ - Specific behaviors → example-based tests
94
+
95
+ ### From Error Types
96
+
97
+ - Each error type → error handling task in Foundation phase
98
+ - Error variants → validation tasks in relevant requirement phases
99
+
100
+ ## Phase Structure
101
+
102
+ ### Phase 1: Setup
103
+
104
+ - Project initialization
105
+ - Dependency installation
106
+ - Configuration scaffolding
107
+ - No requirement labels, no IMPLEMENTS lines
108
+
109
+ ### Phase 2: Foundation
110
+
111
+ - Core types from DESIGN dataModels
112
+ - Error types from DESIGN errorHandling
113
+ - Shared interfaces
114
+ - No requirement labels, IMPLEMENTS only if AC covers foundation
115
+
116
+ ### Phase 3+: Requirements (priority order)
117
+
118
+ Within each requirement phase:
119
+ 1. Types/models specific to this requirement
120
+ 2. Implementation tasks (component by component)
121
+ 3. Test tasks (properties first, then direct AC tests)
122
+
123
+ Each phase should be independently testable after completion.
124
+
125
+ ### Final Phase: Polish
126
+
127
+ - Integration tests across requirements
128
+ - Cross-cutting concerns
129
+ - No requirement labels
130
+
131
+ ### Documentation Phase
132
+
133
+ - Documentation update tasks for any changed user-facing behavior, CLI, API, or configuration
134
+ - If no user-facing changes, include a single task: "No doc changes — internal only"
135
+ - No requirement labels, no IMPLEMENTS lines
136
+
137
+ ## Validation Checklist
138
+
139
+ Before output, verify:
140
+
141
+ - [ ] Every task has correct format (checkbox, ID, description, path)
142
+ - [ ] Every AC appears in at least one IMPLEMENTS line
143
+ - [ ] Every P appears in at least one TESTS line
144
+ - [ ] Requirement labels only on requirement phase tasks
145
+ - [ ] [P] markers only where truly parallelizable
146
+ - [ ] Dependencies match DESIGN component order
147
+ - [ ] Each requirement phase has clear test criteria
148
+ - [ ] Trace summary accounts for all ACs and Ps
149
+ - [ ] Documentation phase present with doc update tasks or explicit "no changes" task
150
+
151
+ ## Outputs
152
+
153
+ <file path=".awa/tasks/TASK-{CODE}-{feature-name}-{nnn}.md" />
154
+
155
+ ## Rules
156
+
157
+ You SHALL clarify open points with user.
158
+ You MAY use todos and tools as needed.
@@ -0,0 +1,68 @@
1
+ ---
2
+ name: awa-upgrade
3
+ description: Upgrade specs to match current schemas. Use this when asked to upgrade, migrate, or update specification documents to conform to schema changes.
4
+ ---
5
+
6
+ # Upgrade Specs to Current Schemas
7
+
8
+ ## Bootstrap
9
+
10
+ <tool name="read_file">
11
+ <read path=".awa/.agent/awa.core.md" required="true" error="on not found" />
12
+ <read path=".awa/rules/*.md" required="true" />
13
+ <read path=".awa/specs/ARCHITECTURE.md" required="true" error="on not found" />
14
+ <read path=".awa/.agent/schemas/ARCHITECTURE.schema.yaml" required="true" error="on not found" />
15
+ <read path=".awa/.agent/schemas/FEAT.schema.yaml" required="true" error="on not found" />
16
+ <read path=".awa/.agent/schemas/EXAMPLE.schema.yaml" required="true" error="on not found" />
17
+ <read path=".awa/.agent/schemas/REQ.schema.yaml" required="true" error="on not found" />
18
+ <read path=".awa/.agent/schemas/DESIGN.schema.yaml" required="true" error="on not found" />
19
+ <read path=".awa/.agent/schemas/TASK.schema.yaml" required="true" error="on not found" />
20
+ <read path=".awa/.agent/schemas/PLAN.schema.yaml" required="true" error="on not found" />
21
+ <read path=".awa/.agent/schemas/ALIGN_REPORT.schema.yaml" required="true" error="on not found" />
22
+ </tool>
23
+
24
+ ## User Input
25
+
26
+ ```text
27
+ ${input}
28
+ ```
29
+
30
+ You **MUST** consider the user input before proceeding (if not empty).
31
+
32
+ ## Inputs
33
+
34
+ <file type="architecture" path=".awa/specs/ARCHITECTURE.md" />
35
+ <file type="feat" path=".awa/specs/FEAT-{CODE}-{feature-name}.md" required="if exists" />
36
+ <file type="examples" path=".awa/specs/EXAMPLE-{CODE}-{feature-name}-{nnn}.md" required="if exists" />
37
+ <file type="requirements" path=".awa/specs/REQ-{CODE}-{feature-name}.md" required="if exists" />
38
+ <file type="design" path=".awa/specs/DESIGN-{CODE}-{feature-name}.md" required="if exists" />
39
+ <file type="api" path=".awa/specs/API-{CODE}-{feature-name}.md" required="if exists" />
40
+ <file type="tasks" path=".awa/tasks/TASK-{CODE}-{feature-name}-{nnn}.md" required="if exists" />
41
+ <file type="plan" path=".awa/plans/PLAN-{nnn}-{plan-name}.md" required="if exists" />
42
+ <file type="align_report" path=".awa/alignment/ALIGN-{x}-WITH-{y}-{nnn}.md" required="if exists" />
43
+ <file type="code" required="if relevant" />
44
+
45
+
46
+ ## Action
47
+
48
+ Upgrade the specified specs to conform to their schemas and traceability rules.
49
+
50
+ 1) ORIENT: Confirm which artifacts to upgrade; clarify missing targets.
51
+ 2) CHECK: Run `awa check` in the terminal to identify schema violations and traceability errors across all target files. Parse the output to build a list of findings to fix.
52
+ 3) FIX: For each reported error, edit the file to resolve the violation — fix section structure, heading levels, missing required content, prohibited patterns, and broken trace IDs.
53
+ 4) RECHECK: Run `awa check` again to verify all errors are resolved. Repeat FIX → RECHECK until the check passes cleanly (warnings and info findings are acceptable).
54
+ 5) REPORT: Summarize changes and remaining questions before finalizing.
55
+
56
+ ## Outputs
57
+
58
+ - Updated spec(s) and supporting templates (as applicable)
59
+
60
+ ## Rules
61
+
62
+ You SHALL avoid destructive edits; propose clarifications when unsure.
63
+ You SHALL follow schema structure strictly (section order, nesting).
64
+ You SHALL obey schema render expectations (omit optional empty sections, avoid prohibited patterns).
65
+ You SHALL upgrade existing trace IDs if necessary.
66
+ You SHALL upgrade existing filenames if necessary.
67
+ You SHALL respect the file line-limits; split logically if needed.
68
+ You MAY use todos and tools as needed.
@@ -0,0 +1,368 @@
1
+ ---
2
+ name: awa-usage
3
+ description: Understand awa, its CLI, and configuration. Use this when asked about awa itself, how to use it, or how to configure it.
4
+ ---
5
+
6
+ # awa — Agent Workflow for AIs
7
+
8
+ ## What awa Is
9
+
10
+ awa is a CLI tool and structured development workflow for AI-assisted coding. It generates agent configuration files from templates and defines a spec-driven development process with full traceability from requirements through code and tests.
11
+
12
+ Key concepts:
13
+
14
+ - **Templates**: Eta-based templates that produce agent config files (`.github/agents/`, `.claude/`, etc.) with conditional output via feature flags
15
+ - **Workflow**: A structured pipeline from architecture through implementation, where every artifact traces to its origin
16
+ - **Traceability**: Code markers (`@awa-impl`, `@awa-test`, `@awa-component`) link source code and tests back to requirements and design
17
+ - **Validation**: `awa check` verifies that all markers resolve to spec IDs and that spec files conform to YAML schemas
18
+
19
+ ## The `.awa/` Directory
20
+
21
+ All spec artifacts live in `.awa/`:
22
+
23
+ .awa/
24
+ ├── .agent/
25
+ │ ├── awa.core.md # Core system prompt (always read first)
26
+ │ └── schemas/
27
+ │ ├── ARCHITECTURE.schema.yaml
28
+ │ ├── FEAT.schema.yaml
29
+ │ ├── EXAMPLE.schema.yaml
30
+ │ ├── REQ.schema.yaml
31
+ │ ├── DESIGN.schema.yaml
32
+ │ ├── API.schema.yaml
33
+ │ ├── TASK.schema.yaml
34
+ │ ├── PLAN.schema.yaml
35
+ │ ├── README.schema.yaml
36
+ │ └── ALIGN_REPORT.schema.yaml
37
+ ├── specs/
38
+ │ ├── ARCHITECTURE.md # System overview
39
+ │ ├── FEAT-{CODE}-*.md # Feature context and motivation
40
+ │ ├── EXAMPLE-{CODE}-*-{nnn}.md # Usage examples per feature
41
+ │ ├── REQ-{CODE}-*.md # Requirements (EARS format)
42
+ │ ├── DESIGN-{CODE}-*.md # Design and components
43
+ │ └── API-{CODE}-*.tsp # TypeSpec API definitions
44
+ ├── tasks/
45
+ │ └── TASK-{CODE}-*-{nnn}.md # Implementation steps
46
+ ├── plans/
47
+ │ └── PLAN-{nnn}-*.md # Ad-hoc plans
48
+ ├── align/
49
+ │ └── ALIGN-{x}-WITH-{y}-{nnn}.md # Alignment reports
50
+ └── rules/
51
+ └── *.md # Project-specific rules
52
+
53
+ ## Workflow Stages
54
+
55
+ ARCHITECTURE → FEAT → REQUIREMENTS → DESIGN → TASKS → CODE & TESTS → DOCUMENTATION
56
+
57
+ | Stage | Artifact | Purpose |
58
+ |-------|----------|---------|
59
+ | Architecture | `ARCHITECTURE.md` | System overview, components, constraints |
60
+ | Feature | `FEAT-{CODE}-*.md` | Context, motivation, scenarios |
61
+ | Requirements | `REQ-{CODE}-*.md` | What must be built (EARS/INCOSE format) |
62
+ | Design | `DESIGN-{CODE}-*.md` | How it gets built — components, interfaces, properties |
63
+ | Tasks | `TASK-{CODE}-*-{nnn}.md` | Step-by-step implementation work items |
64
+ | Code & Tests | Source files | Implementation with traceability markers |
65
+ | Documentation | `README.md`, `docs/` | User-facing docs |
66
+
67
+ Lateral artifacts (produced at any stage): EXAMPLE, PLAN, ALIGN reports.
68
+
69
+ The workflow is flexible. Start top-down (architecture → code), bottom-up (code → extract requirements), or lateral (docs, refactors, ad-hoc plans).
70
+
71
+ ## Traceability Chain
72
+
73
+ IDs and markers create explicit links between artifacts:
74
+
75
+ REQ-{CODE}-*.md
76
+ └── {CODE}-{n}: Requirement title
77
+ └── {CODE}-{n}_AC-{m}: Acceptance criterion
78
+
79
+
80
+ DESIGN-{CODE}-*.md
81
+ └── {CODE}-ComponentName
82
+ ├── IMPLEMENTS: {CODE}-{n}_AC-{m}
83
+ └── {CODE}_P-{n}: Correctness property
84
+
85
+
86
+ Source code
87
+ └── // @awa-component: {CODE}-ComponentName
88
+ └── // @awa-impl: {CODE}-{n}_AC-{m}
89
+
90
+
91
+ Tests
92
+ ├── // @awa-test: {CODE}_P-{n} ← verifies property
93
+ └── // @awa-test: {CODE}-{n}_AC-{m} ← verifies AC
94
+
95
+ ID formats:
96
+
97
+ - `{CODE}-{n}` — requirement (e.g. `DIFF-1`)
98
+ - `{CODE}-{n}.{p}` — subrequirement (e.g. `DIFF-1.1`)
99
+ - `{CODE}-{n}[.{p}]_AC-{m}` — acceptance criterion (e.g. `DIFF-1_AC-1`)
100
+ - `{CODE}_P-{n}` — correctness property (e.g. `DIFF_P-2`)
101
+
102
+ ## CLI Commands
103
+
104
+ awa may be installed locally. Detect the package manager and use the appropriate exec command:
105
+
106
+ npm/npx: npx awa <command>
107
+ yarn: yarn exec awa <command>
108
+ pnpm: pnpm exec awa <command>
109
+ bun: bunx awa <command>
110
+
111
+ ### awa init [output] / awa template generate [output]
112
+
113
+ Generate configuration files from templates. `init` is a top-level convenience command equivalent to `awa template generate`.
114
+
115
+ | Option | Description |
116
+ |--------|-------------|
117
+ | `[output]` | Output directory (positional, optional if set in config) |
118
+ | `-t, --template <source>` | Template source — local path or Git repo |
119
+ | `-f, --features <flag...>` | Feature flags (repeatable) |
120
+ | `--preset <name...>` | Preset names to enable (repeatable) |
121
+ | `--remove-features <flag...>` | Feature flags to remove (repeatable) |
122
+ | `--force` | Overwrite existing files without prompting |
123
+ | `--dry-run` | Preview changes without modifying files |
124
+ | `--delete` | Enable deletion of files listed in template |
125
+ | `-c, --config <path>` | Path to configuration file |
126
+ | `--refresh` | Force re-fetch of cached Git templates |
127
+ | `--all-targets` | Process all named targets from config |
128
+ | `--target <name>` | Process a specific named target |
129
+ | `--overlay <path...>` | Overlay directory paths (repeatable) |
130
+ | `--json` | Output results as JSON (implies --dry-run) |
131
+ | `--summary` | Compact one-line counts summary |
132
+
133
+ ### awa template diff [target]
134
+
135
+ Compare generated template output against an existing target directory. Exit code 0 = match, 1 = differences.
136
+
137
+ | Option | Description |
138
+ |--------|-------------|
139
+ | `[target]` | Target directory (positional, optional if set in config) |
140
+ | `-t, --template <source>` | Template source — local path or Git repo |
141
+ | `-f, --features <flag...>` | Feature flags (repeatable) |
142
+ | `--preset <name...>` | Preset names to enable (repeatable) |
143
+ | `--remove-features <flag...>` | Feature flags to remove (repeatable) |
144
+ | `-c, --config <path>` | Path to configuration file |
145
+ | `--refresh` | Force re-fetch of cached Git templates |
146
+ | `--list-unknown` | Include files in target not present in templates |
147
+ | `--all-targets` | Process all named targets from config |
148
+ | `--target <name>` | Process a specific named target |
149
+ | `-w, --watch` | Watch template directory and re-diff on change |
150
+ | `--overlay <path...>` | Overlay directory paths (repeatable) |
151
+ | `--json` | Output results as JSON |
152
+ | `--summary` | Compact one-line counts summary |
153
+
154
+ ### awa check
155
+
156
+ Check traceability chain integrity and spec schema conformance. Exit code 0 = clean, 1 = errors.
157
+
158
+ | Option | Description |
159
+ |--------|-------------|
160
+ | `-c, --config <path>` | Path to configuration file |
161
+ | `--spec-ignore <pattern...>` | Glob patterns to exclude from spec file scanning (repeatable, appends to config) |
162
+ | `--code-ignore <pattern...>` | Glob patterns to exclude from code file scanning (repeatable, appends to config) |
163
+ | `--json` | Output results as JSON |
164
+ | `--summary` | Compact one-line counts summary |
165
+ | `--allow-warnings` | Allow warnings without failing |
166
+ | `--spec-only` | Run only spec-level checks; skip code-to-spec traceability |
167
+ | `--no-fix` | Skip auto-regeneration of Requirements Traceability sections and Feature Codes table |
168
+
169
+ Before running checks, `awa check` auto-regenerates Requirements Traceability sections in DESIGN and TASK files, and the Feature Codes table in ARCHITECTURE.md. Use `--no-fix` to skip this.
170
+
171
+ Checks performed: orphaned markers, uncovered ACs, broken cross-refs, invalid ID format, orphaned specs, schema validation. Config-only options: `schema-dir`, `schema-enabled`, `ignore-markers`, `spec-only`, `id-pattern`, `cross-ref-patterns`.
172
+
173
+ ### awa trace
174
+
175
+ Navigate the traceability chain and assemble context from specs, code, and tests. Use this to gather focused context before implementing, refactoring, or reviewing.
176
+
177
+ awa trace [ids...] [options]
178
+
179
+ | Option | Description |
180
+ |--------|-------------|
181
+ | `[ids...]` | Traceability ID(s) to trace (e.g. `FEAT-1`, `FEAT-1_AC-2`, `FEAT_P-3`) |
182
+ | `--all` | Trace all known IDs in the project |
183
+ | `--scope <code>` | Limit results to a feature code (e.g. `--scope FEAT`) |
184
+ | `--file <path>` | Resolve IDs from a source file's markers — useful to understand a file's spec connections before changing it |
185
+ | `--task <path>` | Resolve IDs from a task file |
186
+ | `--content` | Output actual file sections instead of locations |
187
+ | `--list` | Output file paths only |
188
+ | `--direction <dir>` | Traversal direction: `both` (default), `forward`, `reverse` |
189
+ | `--depth <n>` | Maximum traversal depth |
190
+ | `--no-code` | Exclude source code (spec-only context) |
191
+ | `--no-tests` | Exclude test files |
192
+ | `--json` | Output results as JSON |
193
+ | `--summary` | Compact one-line counts summary |
194
+ | `--max-tokens <n>` | Cap content output size (implies `--content`) |
195
+ | `-A/-B/-C <n>` | Lines of context after/before/both around a code marker (`--content` only) |
196
+ | `-c, --config <path>` | Path to configuration file |
197
+
198
+ ### awa spec renumber [code]
199
+
200
+ Renumber traceability IDs to match document order, closing gaps in numbering sequences. Exit code 0 = no changes, 1 = changes applied/previewed.
201
+
202
+ | Option | Description |
203
+ |--------|-------------|
204
+ | `[code]` | Feature code to renumber (e.g. DIFF, TRC) |
205
+ | `--all` | Renumber all feature codes |
206
+ | `--dry-run` | Preview changes without modifying files |
207
+ | `--json` | Output results as JSON |
208
+ | `-c, --config <path>` | Path to configuration file |
209
+
210
+ Scans specs and code for traceability IDs, builds a renumber map that closes gaps (e.g. 1, 3, 5 → 1, 2, 3), and propagates all ID changes across spec files, source code, and tests.
211
+
212
+ ### awa spec recode <source> <target>
213
+
214
+ Recode traceability IDs from one feature code to another. Rewrites all IDs, renames spec files, and updates headings. Exit code 0 = no changes, 1 = changes applied/previewed.
215
+
216
+ | Option | Description |
217
+ |--------|-------------|
218
+ | `<source>` | Source feature code to recode from |
219
+ | `<target>` | Target feature code to recode into |
220
+ | `--dry-run` | Preview changes without modifying files |
221
+ | `--json` | Output results as JSON |
222
+ | `--renumber` | Renumber target code after recode |
223
+ | `-c, --config <path>` | Path to configuration file |
224
+
225
+ Builds an offset map so source IDs don't collide with existing target IDs. Use `awa spec merge` if target spec files already exist.
226
+
227
+ ### awa spec merge <source> <target>
228
+
229
+ Merge one feature code into another — combines recode, content merge, and cleanup. Exit code 0 = no changes, 1 = changes applied/previewed.
230
+
231
+ | Option | Description |
232
+ |--------|-------------|
233
+ | `<source>` | Source feature code to merge from |
234
+ | `<target>` | Target feature code to merge into |
235
+ | `--dry-run` | Preview changes without modifying files |
236
+ | `--json` | Output results as JSON |
237
+ | `--renumber` | Renumber target code after merge |
238
+ | `-c, --config <path>` | Path to configuration file |
239
+
240
+ Pipeline: recode source IDs past target's highest → rename/move spec files → warn about stale source refs → optionally renumber. Use `merge` when both codes have existing spec files; use `recode` for a pure rename.
241
+
242
+ ### awa spec codes
243
+
244
+ List all feature codes with requirement counts and scope summaries. Exit code 0 = success.
245
+
246
+ | Option | Description |
247
+ |--------|-------------|
248
+ | `--json` | Output results as JSON |
249
+ | `--summary` | Compact one-line counts summary |
250
+ | `-c, --config <path>` | Path to configuration file |
251
+
252
+ ### awa template test
253
+
254
+ Run template test fixtures. Exit code 0 = all pass, 1 = failures.
255
+
256
+ | Option | Description |
257
+ |--------|-------------|
258
+ | `-t, --template <source>` | Template source — local path or Git repo |
259
+ | `-c, --config <path>` | Path to configuration file |
260
+ | `--update-snapshots` | Update stored snapshots with current output |
261
+ | `--refresh` | Force re-fetch of cached Git templates |
262
+ | `--overlay <path...>` | Overlay directory paths (repeatable) |
263
+ | `--json` | Output results as JSON |
264
+ | `--summary` | Compact one-line counts summary |
265
+
266
+ Discovers `*.toml` fixtures in `_tests/`, renders per fixture, verifies expected files, compares against snapshots.
267
+
268
+ ### awa template features
269
+
270
+ Discover feature flags available in a template.
271
+
272
+ | Option | Description |
273
+ |--------|-------------|
274
+ | `-t, --template <source>` | Template source — local path or Git repo |
275
+ | `-c, --config <path>` | Path to configuration file |
276
+ | `--refresh` | Force re-fetch of cached Git templates |
277
+ | `--overlay <path...>` | Overlay directory paths (repeatable) |
278
+ | `--json` | Output results as JSON |
279
+ | `--summary` | Compact one-line counts summary |
280
+
281
+ ### Global Options
282
+
283
+ `-v, --version` — display version. `-h, --help` — display help.
284
+
285
+ ## Configuration — `.awa.toml`
286
+
287
+ Create `.awa.toml` in the project root. CLI arguments always override config values.
288
+
289
+ # Root options
290
+ output = ".github/agents"
291
+ template = "owner/repo"
292
+ features = ["copilot", "claude"]
293
+ overlay = ["./overlays/company", "./overlays/project"]
294
+ refresh = false
295
+ delete = false
296
+
297
+ # Named presets — expand into feature flags
298
+ [presets]
299
+ full = ["copilot", "claude", "cursor", "windsurf", "kilocode", "opencode", "gemini", "roo", "qwen", "codex", "agy", "agents-md"]
300
+ lite = ["copilot", "claude"]
301
+
302
+ # Per-agent targets — generate different configs in one command
303
+ [targets.claude]
304
+ output = "."
305
+ features = ["claude", "architect", "code"]
306
+
307
+ [targets.copilot]
308
+ output = "."
309
+ features = ["copilot", "code", "vibe"]
310
+
311
+ # Traceability check configuration
312
+ [check]
313
+ spec-globs = [".awa/specs/**/*.md"]
314
+ code-globs = ["src/**/*.{ts,js,tsx,jsx}"]
315
+ markers = ["@awa-impl", "@awa-test", "@awa-component"]
316
+ spec-ignore = []
317
+ code-ignore = ["node_modules/**", "dist/**", "vendor/**", "target/**", "build/**", "out/**", ".awa/**"]
318
+ ignore-markers = []
319
+ id-pattern = "..." # regex for valid traceability IDs
320
+ cross-ref-patterns = ["IMPLEMENTS:", "VALIDATES:"]
321
+ format = "text"
322
+ schema-dir = ".awa/.agent/schemas"
323
+ schema-enabled = true
324
+ allow-warnings = false
325
+ spec-only = false
326
+
327
+ # Update check configuration
328
+ [update-check]
329
+ enabled = true # set to false to disable update checks
330
+ interval = 86400 # seconds between checks (default: 1 day)
331
+
332
+ Target fields: `output`, `template`, `features`, `preset`, `remove-features`. Boolean flags (`force`, `dry-run`, `delete`, `refresh`) apply globally. Target features replace root features entirely.
333
+
334
+ Feature resolution order: start with `--features`, expand `--preset` (append, deduplicate), remove `--remove-features`.
335
+
336
+ Multi-target usage:
337
+
338
+ awa template generate --all-targets # process all targets
339
+ awa template generate --target claude # process one target
340
+ awa template diff --all-targets # diff all targets
341
+
342
+ ## Template Sources
343
+
344
+ Templates can be a local path or a Git repository:
345
+
346
+ - Local path: `./templates/awa`
347
+ - GitHub shorthand: `owner/repo`
348
+ - Full URL: `https://github.com/owner/repo`
349
+ - SSH: `git@github.com:owner/repo`
350
+ - With subdirectory: `owner/repo/path/to/templates`
351
+ - With ref: `owner/repo#branch`, `owner/repo#v1.0.0`
352
+
353
+ Git templates are cached in `~/.cache/awa/templates/`. Use `--refresh` to re-fetch.
354
+
355
+ ## Exit Codes
356
+
357
+ | Command | 0 | 1 | 2 |
358
+ |---------|---|---|---|
359
+ | `awa init` / `awa template generate` | Success | — | Internal error |
360
+ | `awa template diff` | All files match | Differences found | Internal error |
361
+ | `awa check` | All checks pass | Errors found | Internal error |
362
+ | `awa template test` | All fixtures pass | Failures found | Internal error |
363
+ | `awa template features` | Success | Error | — |
364
+ | `awa trace` | Chain found | ID not found / no context | Internal error |
365
+ | `awa spec renumber` | No changes needed | Changes applied/previewed | Internal error |
366
+ | `awa spec recode` | No changes needed | Changes applied/previewed | Error / stale refs |
367
+ | `awa spec merge` | No changes needed | Changes applied/previewed | Error / stale refs |
368
+ | `awa spec codes` | Success | — | Internal error |
@@ -0,0 +1,72 @@
1
+ ---
2
+ name: awa-vibe
3
+ description: Implement an idea from start to finish using the full awa workflow. Use this when asked to take an idea through the complete development cycle.
4
+ ---
5
+
6
+ # Vibe: Idea to Implementation
7
+
8
+ ## Bootstrap
9
+
10
+ <tool name="read_file">
11
+ <read path=".awa/.agent/awa.core.md" required="true" error="on not found" />
12
+ <read path=".awa/rules/*.md" required="true" />
13
+ <read path=".awa/specs/ARCHITECTURE.md" required="if exists" />
14
+ </tool>
15
+
16
+ ## User Input
17
+
18
+ ```text
19
+ ${input}
20
+ ```
21
+
22
+ You **MUST** consider the user input before proceeding (if not empty).
23
+
24
+ ## Inputs
25
+
26
+ <file type="architecture" path=".awa/specs/ARCHITECTURE.md" />
27
+ <file type="feat" path=".awa/specs/FEAT-{CODE}-{feature-name}.md" required="if relevant" />
28
+ <file type="examples" path=".awa/specs/EXAMPLE-{CODE}-{feature-name}-{nnn}.md" required="if relevant" />
29
+ <file type="requirements" path=".awa/specs/REQ-{CODE}-{feature-name}.md" required="if relevant" />
30
+ <file type="design" path=".awa/specs/DESIGN-{CODE}-{feature-name}.md" required="if relevant" />
31
+ <file type="api" path=".awa/specs/API-{CODE}-{feature-name}.md" required="if relevant" />
32
+ <file type="tasks" path=".awa/tasks/TASK-{CODE}-{feature-name}-{nnn}.md" required="if relevant" />
33
+ <file type="code" required="if relevant" />
34
+
35
+ ## Action
36
+
37
+ Take an idea from concept to working implementation, flowing through the awa workflow in the standard direction.
38
+
39
+ ## Process
40
+
41
+ 1. UNDERSTAND: Clarify idea, scope, constraints. Determine starting point.
42
+ 2. Flow through stages, creating/updating specs as needed
43
+ 3. Checkpoint at each transition: confirm direction with user
44
+ 4. Implement code with traceability, write tests
45
+ 5. Verify all acceptance criteria satisfied
46
+
47
+ ## Checkpoints
48
+
49
+ Pause at each stage transition unless user requests autonomous mode:
50
+ - "Architecture defined. Proceed to feature context?"
51
+ - "Feature context captured. Proceed to requirements?"
52
+ - "Requirements captured. Proceed to design?"
53
+ - "Design complete. Proceed to implementation?"
54
+ - "Implementation complete. Update documentation?"
55
+
56
+ ## Outputs
57
+
58
+ - Specs as needed (ARCHITECTURE, FEAT, REQ, DESIGN, TASK)
59
+ - Implemented code with traceability markers
60
+ - Tests covering acceptance criteria
61
+ - Updated documentation if user-facing behavior changed
62
+
63
+ ## Rules
64
+
65
+ You SHALL flow through stages in order, skipping only what exists or isn't needed.
66
+ You SHALL pause at checkpoints unless user requests autonomous mode.
67
+ You SHALL maintain traceability throughout.
68
+ You SHOULD keep each stage minimal; avoid overengineering.
69
+ You SHOULD ask clarifying questions early, not mid-implementation.
70
+ You MAY collapse stages for trivial changes.
71
+ You SHALL update user-facing documentation when implementation changes user-facing behavior, CLI, API, or configuration.
72
+ You MAY use todos and tools as needed.