aw-spec-cli 0.1.21 → 0.1.22

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 (39) hide show
  1. package/assets/.appweaver/STACK-PROFILES.md +87 -8
  2. package/assets/.appweaver/orchestrator/modules/delta-plan.orch.yaml +30 -0
  3. package/assets/.appweaver/orchestrator/workflows/aw-spec-analyze-plan.orch.yaml +41 -8
  4. package/assets/.appweaver/orchestrator/workflows/aw-spec-analyze-slice-delta.orch.yaml +62 -2
  5. package/assets/.appweaver/orchestrator/workflows/aw-spec-analyze-slice.orch.yaml +18 -5
  6. package/assets/.appweaver/orchestrator/workflows/aw-spec-finalize-delta.orch.yaml +115 -27
  7. package/assets/.appweaver/orchestrator/workflows/aw-spec-implement.orch.yaml +225 -27
  8. package/assets/.appweaver/orchestrator/workflows/aw-spec-plan.orch.yaml +39 -0
  9. package/assets/.appweaver/orchestrator/workflows/aw-spec-recall-delta.orch.yaml +28 -7
  10. package/assets/.appweaver/orchestrator/workflows/aw-spec-specify.orch.yaml +100 -0
  11. package/assets/.appweaver/orchestrator/workflows/aw-spec-ui-model.orch.yaml +141 -0
  12. package/assets/.appweaver/orchestrator/workflows/aw-spec-ui-prototype.orch.yaml +386 -0
  13. package/assets/.appweaver/orchestrator/workflows/aw-spec-workflow-model.orch.yaml +135 -0
  14. package/assets/.appweaver/scripts/bash/aw-spec-actions.sh +190 -209
  15. package/assets/.appweaver/scripts/bash/aw-xref.sh +4 -1
  16. package/assets/.appweaver/scripts/powershell/aw-spec-actions.ps1 +182 -224
  17. package/assets/.appweaver/scripts/powershell/aw-xref.ps1 +4 -1
  18. package/assets/.appweaver/scripts/python/aw-crstate.py +127 -2
  19. package/assets/.appweaver/scripts/python/aw-gaps.py +119 -0
  20. package/assets/.appweaver/scripts/python/aw-payload-parity.py +17 -1
  21. package/assets/.appweaver/scripts/python/aw-plan-coverage.py +84 -4
  22. package/assets/.appweaver/scripts/python/aw-plangate.py +216 -0
  23. package/assets/.appweaver/scripts/python/aw-principles.py +108 -0
  24. package/assets/.appweaver/scripts/python/aw-stack.py +6 -0
  25. package/assets/.appweaver/scripts/python/aw-xref.py +141 -4
  26. package/assets/.appweaver/stack-profiles/angular.json +26 -0
  27. package/assets/.appweaver/stack-profiles/blazor-wasm.json +38 -0
  28. package/assets/.appweaver/stack-profiles/dotnet-webapi.json +38 -0
  29. package/assets/.appweaver/stack-profiles/java-spring.json +19 -0
  30. package/assets/.appweaver/stack-profiles/nextjs.json +26 -0
  31. package/assets/.appweaver/stack-profiles/node-express.json +26 -0
  32. package/assets/.appweaver/stack-profiles/python-fastapi.json +15 -0
  33. package/assets/.appweaver/stack-profiles/react-vite.json +26 -0
  34. package/assets/.appweaver/stack-profiles/sveltekit.json +26 -0
  35. package/assets/.appweaver/stack-profiles/vue-vite.json +26 -0
  36. package/assets/.appweaver/templates/ui-model-template.md +67 -0
  37. package/assets/.appweaver/templates/workflow-model-template.md +62 -0
  38. package/assets/guardrails/technology/dotnet-webapi/framework-api-map.md +44 -0
  39. package/package.json +1 -1
@@ -13,5 +13,24 @@
13
13
  "detect": [
14
14
  "pom.xml",
15
15
  "build.gradle"
16
+ ],
17
+ "reserved_names": [
18
+ "Character",
19
+ "Class",
20
+ "Enum",
21
+ "Error",
22
+ "Exception",
23
+ "Integer",
24
+ "Module",
25
+ "Number",
26
+ "Object",
27
+ "Package",
28
+ "Process",
29
+ "Record",
30
+ "Runtime",
31
+ "String",
32
+ "System",
33
+ "Thread",
34
+ "Void"
16
35
  ]
17
36
  }
@@ -12,5 +12,31 @@
12
12
  "prototype_run": "npm run dev --prefix prototype",
13
13
  "detect": [
14
14
  "web/next.config.*"
15
+ ],
16
+ "reserved_names": [
17
+ "Array",
18
+ "Date",
19
+ "Document",
20
+ "Element",
21
+ "Error",
22
+ "Event",
23
+ "Headers",
24
+ "History",
25
+ "Image",
26
+ "Location",
27
+ "Map",
28
+ "Node",
29
+ "Notification",
30
+ "Object",
31
+ "Option",
32
+ "Range",
33
+ "Record",
34
+ "Request",
35
+ "Response",
36
+ "Selection",
37
+ "Set",
38
+ "Storage",
39
+ "Text",
40
+ "Worker"
15
41
  ]
16
42
  }
@@ -12,5 +12,31 @@
12
12
  "detect": [
13
13
  "package.json",
14
14
  "src/**/*.ts"
15
+ ],
16
+ "reserved_names": [
17
+ "Array",
18
+ "Date",
19
+ "Document",
20
+ "Element",
21
+ "Error",
22
+ "Event",
23
+ "Headers",
24
+ "History",
25
+ "Image",
26
+ "Location",
27
+ "Map",
28
+ "Node",
29
+ "Notification",
30
+ "Object",
31
+ "Option",
32
+ "Range",
33
+ "Record",
34
+ "Request",
35
+ "Response",
36
+ "Selection",
37
+ "Set",
38
+ "Storage",
39
+ "Text",
40
+ "Worker"
15
41
  ]
16
42
  }
@@ -13,5 +13,20 @@
13
13
  "pyproject.toml",
14
14
  "requirements.txt",
15
15
  "app/main.py"
16
+ ],
17
+ "reserved_names": [
18
+ "Any",
19
+ "Callable",
20
+ "Dict",
21
+ "Generator",
22
+ "Iterator",
23
+ "List",
24
+ "Mapping",
25
+ "Optional",
26
+ "Sequence",
27
+ "Set",
28
+ "Text",
29
+ "Type",
30
+ "Union"
16
31
  ]
17
32
  }
@@ -13,5 +13,31 @@
13
13
  "detect": [
14
14
  "web/package.json",
15
15
  "web/vite.config.*"
16
+ ],
17
+ "reserved_names": [
18
+ "Array",
19
+ "Date",
20
+ "Document",
21
+ "Element",
22
+ "Error",
23
+ "Event",
24
+ "Headers",
25
+ "History",
26
+ "Image",
27
+ "Location",
28
+ "Map",
29
+ "Node",
30
+ "Notification",
31
+ "Object",
32
+ "Option",
33
+ "Range",
34
+ "Record",
35
+ "Request",
36
+ "Response",
37
+ "Selection",
38
+ "Set",
39
+ "Storage",
40
+ "Text",
41
+ "Worker"
16
42
  ]
17
43
  }
@@ -12,5 +12,31 @@
12
12
  "prototype_run": "npm run dev --prefix prototype",
13
13
  "detect": [
14
14
  "web/svelte.config.*"
15
+ ],
16
+ "reserved_names": [
17
+ "Array",
18
+ "Date",
19
+ "Document",
20
+ "Element",
21
+ "Error",
22
+ "Event",
23
+ "Headers",
24
+ "History",
25
+ "Image",
26
+ "Location",
27
+ "Map",
28
+ "Node",
29
+ "Notification",
30
+ "Object",
31
+ "Option",
32
+ "Range",
33
+ "Record",
34
+ "Request",
35
+ "Response",
36
+ "Selection",
37
+ "Set",
38
+ "Storage",
39
+ "Text",
40
+ "Worker"
15
41
  ]
16
42
  }
@@ -13,5 +13,31 @@
13
13
  "detect": [
14
14
  "web/vite.config.*",
15
15
  "web/src/App.vue"
16
+ ],
17
+ "reserved_names": [
18
+ "Array",
19
+ "Date",
20
+ "Document",
21
+ "Element",
22
+ "Error",
23
+ "Event",
24
+ "Headers",
25
+ "History",
26
+ "Image",
27
+ "Location",
28
+ "Map",
29
+ "Node",
30
+ "Notification",
31
+ "Object",
32
+ "Option",
33
+ "Range",
34
+ "Record",
35
+ "Request",
36
+ "Response",
37
+ "Selection",
38
+ "Set",
39
+ "Storage",
40
+ "Text",
41
+ "Worker"
16
42
  ]
17
43
  }
@@ -0,0 +1,67 @@
1
+ # UI Model: [Feature Name]
2
+
3
+ **Aggregate (feature)**: `[Aggregate]`
4
+ **Spec Reference**: `specs/[Aggregate]/spec.md`
5
+ **Workflow Reference**: `specs/[Aggregate]/ui/workflow-model.md`
6
+ **Version**: v1.0
7
+ **Status**: Active
8
+
9
+ ## Overview
10
+
11
+ [Information architecture mapping user workflows into concrete UI surfaces, routes, interaction states, and component hierarchy.]
12
+
13
+ ## UI Surfaces
14
+
15
+ ### Surface 1: [Surface Title — e.g. Project Directory & Workspace]
16
+
17
+ - **Surface Type**: `Page` | `Sub-Page` | `Dialog` | `Drawer` | `Modal` | `View`
18
+ - **Route / Mount Path**: `/projects`
19
+ - **Supported Workflows**: [WF-1, WF-2]
20
+ - **Target Personas**: [Project Manager, PMO Member]
21
+ - **Required Interaction States**:
22
+ - `Loading`: Skeleton placeholders during data retrieval
23
+ - `Empty`: Zero-state graphic with call-to-action
24
+ - `Populated`: Structured table / card layout displaying primary entities
25
+ - `Filtered / Searched`: Dynamic filtering view
26
+ - `Error`: Inline error notification banner
27
+ - **User Actions & Events**:
28
+ - Search & filter inputs
29
+ - Action trigger (e.g. "Create Project" → opens Surface 2)
30
+ - Row item selection (→ opens Surface 3)
31
+ - **Transitions**:
32
+ - `On Click [Action]` → Navigates to or opens `[Surface Name]`
33
+
34
+ ---
35
+
36
+ ### Surface 2: [Surface Title — e.g. Create Project Form]
37
+
38
+ - **Surface Type**: `Drawer` | `Dialog` | `Page`
39
+ - **Route / Mount Path**: `/projects/create` (or Modal on `/projects`)
40
+ - **Supported Workflows**: [WF-1]
41
+ - **Target Personas**: [Project Manager]
42
+ - **Required Interaction States**:
43
+ - `Initial / Ready`: Blank form with active validation rules
44
+ - `Validation Error`: Inline field error callouts (e.g. invalid date range)
45
+ - `Submitting`: Button loading spinner with disabled inputs
46
+ - `Success`: Dismisses modal & appends item to active list with toast confirmation
47
+ - **User Actions & Events**:
48
+ - Input fields & attachment uploads
49
+ - Submit & Cancel controls
50
+ - **Transitions**:
51
+ - `On Submit Success` → Return to `Surface 1` (Populated state)
52
+ - `On Cancel` → Close surface without saving
53
+
54
+ ---
55
+
56
+ ### Surface 3: [Surface Title — e.g. Action Confirmation Modal]
57
+
58
+ - **Surface Type**: `Dialog`
59
+ - **Supported Workflows**: [WF-3]
60
+ - **Target Personas**: [Authorized Roles]
61
+ - **Required Interaction States**:
62
+ - `Prompt`: Mandatory confirmation text & action buttons
63
+ - `Executing`: Disables actions during execution
64
+ - **User Actions & Events**:
65
+ - Confirm & Cancel buttons
66
+ - **Transitions**:
67
+ - `On Confirm` → Execute state transition & update parent surface UI
@@ -0,0 +1,62 @@
1
+ # Workflow Model: [Feature Name]
2
+
3
+ **Aggregate (feature)**: `[Aggregate]`
4
+ **Spec Reference**: `specs/[Aggregate]/spec.md`
5
+ **Version**: v1.0
6
+ **Status**: Active
7
+
8
+ ## Overview
9
+
10
+ [Summary of the user workflows derived from the feature specification.]
11
+
12
+ ## Workflows
13
+
14
+ ### WF-1 - [Workflow Title]
15
+
16
+ - **Actor / Persona**: [Primary user role executing this workflow — e.g. Project Manager]
17
+ - **Goal**: [What the user is trying to accomplish]
18
+ - **Preconditions**: [Initial system state or permissions required]
19
+
20
+ #### Primary Flow
21
+
22
+ 1. [Step 1: User initiates or accesses interaction]
23
+ 2. [Step 2: System presents data or inputs]
24
+ 3. [Step 3: User enters parameters or performs action]
25
+ 4. [Step 4: System processes and validates]
26
+ 5. [Step 5: User views confirmation or resulting state]
27
+
28
+ #### Alternative Paths & Decision Points
29
+
30
+ - **If [Condition / Decision A]**: [Alternative interaction path]
31
+ - **If [Condition / Decision B]**: [Cancellation / Exit path without state mutation]
32
+
33
+ #### Validation & Error Handling
34
+
35
+ - **If [Validation Rule Fails]**: System blocks progression and displays inline error feedback.
36
+
37
+ #### State Transitions
38
+
39
+ - **Initial State**: `[State A]`
40
+ - **Resulting State**: `[State B]`
41
+
42
+ ---
43
+
44
+ ### WF-2 - [Next Workflow Title]
45
+
46
+ - **Actor / Persona**: [User role]
47
+ - **Goal**: [User goal]
48
+ - **Preconditions**: [Preconditions]
49
+
50
+ #### Primary Flow
51
+
52
+ 1. [Step 1]
53
+ 2. [Step 2]
54
+
55
+ #### Alternative Paths & Decision Points
56
+
57
+ - **If [Condition]**: [Flow]
58
+
59
+ #### State Transitions
60
+
61
+ - **Initial State**: `[State]`
62
+ - **Resulting State**: `[State]`
@@ -50,6 +50,50 @@ The auditing interfaces are the ones most often reported missing: they are in a
50
50
  package from the aggregate types, so a project that references `AppWeaver.DomainAbstraction`
51
51
  alone cannot see `IAggregateChild` at all. A rule that requires one requires its package.
52
52
 
53
+ ## The other direction — framework types that shadow DOMAIN names
54
+
55
+ The map above is about a framework type the code cannot find. The opposite failure is a
56
+ framework type it finds *too easily*: a domain noun that the ambient scope already defines.
57
+
58
+ `Microsoft.NET.Sdk.Web` turns on implicit usings, so `System`, `System.Collections.Generic`,
59
+ `System.IO`, `System.Threading.Tasks`, `Microsoft.AspNetCore.Http` and
60
+ `Microsoft.AspNetCore.Routing` are in scope in **every** file without appearing in any
61
+ `using` line. A domain type sharing a name with one of theirs — `Route`, `Task`, `Activity`,
62
+ `Path`, `File`, `Timer`, `Index`, `Range`, `Version`, `Results`, `Endpoint`, `Environment`,
63
+ `Stream`, `Type`, `Queue`, `Stack` — is then an **ambiguous reference, CS0104**:
64
+
65
+ ```csharp
66
+ using Acme.Clinic.Service.Care.Domain; // brings in the domain Route
67
+
68
+ public static Route? Route(string? value) // CS0104: Care.Domain.Route
69
+ // vs Microsoft.AspNetCore.Routing.Route
70
+ ```
71
+
72
+ The conflict is invisible in the file. Nothing in it names `Microsoft.AspNetCore.Routing`,
73
+ so the bare name reads as correct and fails only at build.
74
+
75
+ **The domain name is not the problem and never changes.** It is the ubiquitous language,
76
+ the plan spells it, and the code spells it back verbatim. What changes is how it is
77
+ written at the use site:
78
+
79
+ ```csharp
80
+ public static Domain.Route? Route(string? value) =>
81
+ string.IsNullOrWhiteSpace(value) ? null : Domain.Route.From(value);
82
+ ```
83
+
84
+ - **Qualify with the type's own enclosing namespace segment** — `Domain.Route` — at every
85
+ site the type is named: declarations, parameters, return types, generic arguments and
86
+ `<see cref="…"/>` comments.
87
+ - **Not a `using` alias and not the full namespace path.** One convention, so two features
88
+ never disambiguate the same name two ways.
89
+ - **Never rename the domain type** to avoid the clash, and never drop the domain type in
90
+ favour of the framework one.
91
+
92
+ `/aw-spec-implement` is told which of *this* plan's element names are affected before it
93
+ writes anything — the list comes from the lane's stack profile (`reserved_names` in
94
+ `.appweaver/stack-profiles/<id>.json`), so it is the same answer on every run rather than
95
+ something each pass has to notice for itself.
96
+
53
97
  ## Rules
54
98
 
55
99
  - **Cite a framework type with its namespace** in plans and generated code, and add the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aw-spec-cli",
3
- "version": "0.1.21",
3
+ "version": "0.1.22",
4
4
  "description": "AppWeaver Spec-Driven Development CLI - scaffolds projects with vertical slices, DDD, CQRS, and agent skills",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",