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
@@ -0,0 +1,135 @@
1
+ # =============================================================================
2
+ # aw-spec-workflow-model (orchestrator) — Derive Workflow Model from Feature Spec
3
+ #
4
+ # Stage 2 of the 4-Stage Spec-Driven UI Generation Pipeline.
5
+ # Consumes active feature's spec.md (+ active delta-spec.md) and derives user-oriented
6
+ # workflows (Actors, Goals, Primary Steps, Decisions, Alt Paths, Validation Failures, State Transitions).
7
+ # Writes output artifact to `specs/<Feature>/ui/workflow-model.md`.
8
+ #
9
+ # Launch:
10
+ # /appweaver workflow-model [strategy] [guidance]
11
+ # =============================================================================
12
+
13
+ name: aw-spec-workflow-model
14
+ description: Derive the Workflow Model (specs/<Feature>/ui/workflow-model.md) from the active feature's spec.md, describing user goals, interaction steps, decision branches, validation rules, and state transitions.
15
+ version: 1.0.0
16
+ agent_agnostic: true
17
+ dialect: aw-spec.orchestrator/v1
18
+
19
+ inputs:
20
+ user_input:
21
+ description: Optional guidance or specific workflow emphasis.
22
+ required: false
23
+ bind: USER_INPUT
24
+
25
+ scripts:
26
+ actions:
27
+ sh: .appweaver/scripts/bash/aw-spec-actions.sh
28
+ ps1: .appweaver/scripts/powershell/aw-spec-actions.ps1
29
+
30
+ vars:
31
+ feature: ""
32
+ feature_dir: ""
33
+ feature_slug: ""
34
+ spec_file: ""
35
+ spec_exists: "false"
36
+ active_change: ""
37
+ has_change: "false"
38
+ domain: ""
39
+ prototype_root: ""
40
+
41
+ workflow:
42
+
43
+ # 1. Resolve active feature and paths
44
+ - id: feature_paths
45
+ action: execute_script
46
+ on_error: continue
47
+ script: { ref: actions }
48
+ subcommand: feature-paths
49
+ outputs:
50
+ - { name: feature, from: "$.feature" }
51
+ - { name: feature_dir, from: "$.feature_dir" }
52
+ - { name: feature_slug, from: "$.feature_slug" }
53
+ - { name: spec_file, from: "$.spec_file" }
54
+ - { name: spec_exists, from: "$.spec_exists" }
55
+ - { name: domain, from: "$.domain" }
56
+ - { name: prototype_root, from: "$.prototype_root" }
57
+
58
+ - id: require_feature
59
+ action: verify_context
60
+ require_non_empty: feature_dir
61
+ on_empty: stop
62
+ on_empty_message: "No active feature selected. Run /appweaver select-feature first."
63
+
64
+ - id: require_spec
65
+ action: verify_context
66
+ require_true: spec_exists
67
+ on_false: stop
68
+ on_false_message: "No specification found for this feature. Run /appweaver specify first."
69
+
70
+ # 2. Check active change requests
71
+ - id: version_read
72
+ action: execute_script
73
+ on_error: continue
74
+ script: { ref: actions }
75
+ subcommand: version-read
76
+ args: ["--feature-dir", "{{feature_dir}}"]
77
+ outputs:
78
+ - { name: active_change, from: "$.active_change" }
79
+ - { name: has_change, from: "$.has_change" }
80
+
81
+ # 3. Assemble specification & template context
82
+ - id: ctx_workflow
83
+ action: build_context
84
+ vars:
85
+ feature_name: "{{feature}}"
86
+ feature_dir: "{{feature_dir}}"
87
+ user_preferences: "{{USER_INPUT}}"
88
+ context:
89
+ - "{{spec_file}}"
90
+ - { path: "{{feature_dir}}/changes/{{active_change}}/delta-spec.md", optional: true }
91
+ - { path: ".appweaver/templates/workflow-model-template.md", optional: true }
92
+ - { path: ".appweaver/memory/constitution.ui.md", optional: true }
93
+
94
+ # 4. Generate Workflow Model Artifact (specs/<Feature>/ui/workflow-model.md)
95
+ - id: generate_workflow_model
96
+ action: agent_generate
97
+ tools: "Read,Write,Edit,Bash"
98
+ permission_mode: acceptEdits
99
+ task: |
100
+ You are authoring Stage 2 (Workflow Model) of the 4-Stage Spec-Driven UI Pipeline for feature `{{feature_name}}`.
101
+
102
+ Target Artifact Path: `{{feature_dir}}/ui/workflow-model.md`
103
+
104
+ Instructions:
105
+ 1. Read the feature specification (`spec.md` + active `delta-spec.md`) in context.
106
+ 2. Identify ALL discrete user workflows required to fulfill the feature's capabilities, functional requirements (FRs), business rules (BRs), and user personas.
107
+ 3. For EACH user workflow (WF-1, WF-2, ...), detail:
108
+ - **Actor / Persona**: Which role executes this flow (e.g. Project Manager, Delivery Head).
109
+ - **Goal**: Clear statement of user goal.
110
+ - **Preconditions**: Initial system state, permissions, or prerequisite conditions.
111
+ - **Primary Flow**: Step-by-step numbered interaction steps from start to completion.
112
+ - **Decision Points & Alternative Paths**: Clear branch logic (e.g. If user cancels, If user requests correction).
113
+ - **Validation Failures & Error Handling**: Inline system reaction when business rules or validations fail.
114
+ - **State Transitions**: `[Initial State]` → `[Resulting State]`.
115
+ 4. Format the output according to `.appweaver/templates/workflow-model-template.md`.
116
+ 5. Create the directory `{{feature_dir}}/ui/` if it does not exist, and write the authored markdown content to `{{feature_dir}}/ui/workflow-model.md`.
117
+
118
+ User Guidance:
119
+ {{user_preferences}}
120
+
121
+ End your final reply with a summary and a ```json fence:
122
+ ```json
123
+ {
124
+ "status": "ok",
125
+ "feature": "{{feature_name}}",
126
+ "workflow_model_path": "{{feature_dir}}/ui/workflow-model.md"
127
+ }
128
+ ```
129
+ outputs:
130
+ - { name: result, from: "$" }
131
+
132
+ outputs:
133
+ feature: "{{feature}}"
134
+ workflow_model_path: "{{feature_dir}}/ui/workflow-model.md"
135
+ next: "Run /appweaver ui-model to derive the UI Model surfaces and interaction structure."