@exaudeus/workrail 3.27.0 → 3.29.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 (160) hide show
  1. package/dist/console/assets/{index-FtTaDku8.js → index-BZ6HkxGf.js} +1 -1
  2. package/dist/console/index.html +1 -1
  3. package/dist/manifest.json +3 -3
  4. package/docs/README.md +57 -0
  5. package/docs/adrs/001-hybrid-storage-backend.md +38 -0
  6. package/docs/adrs/002-four-layer-context-classification.md +38 -0
  7. package/docs/adrs/003-checkpoint-trigger-strategy.md +35 -0
  8. package/docs/adrs/004-opt-in-encryption-strategy.md +36 -0
  9. package/docs/adrs/005-agent-first-workflow-execution-tokens.md +105 -0
  10. package/docs/adrs/006-append-only-session-run-event-log.md +76 -0
  11. package/docs/adrs/007-resume-and-checkpoint-only-sessions.md +51 -0
  12. package/docs/adrs/008-blocked-nodes-architectural-upgrade.md +178 -0
  13. package/docs/adrs/009-bridge-mode-single-instance-mcp.md +195 -0
  14. package/docs/adrs/010-release-pipeline.md +89 -0
  15. package/docs/architecture/README.md +7 -0
  16. package/docs/architecture/refactor-audit.md +364 -0
  17. package/docs/authoring-v2.md +527 -0
  18. package/docs/authoring.md +873 -0
  19. package/docs/changelog-recent.md +201 -0
  20. package/docs/configuration.md +505 -0
  21. package/docs/ctc-mcp-proposal.md +518 -0
  22. package/docs/design/README.md +22 -0
  23. package/docs/design/agent-cascade-protocol.md +96 -0
  24. package/docs/design/autonomous-console-design-candidates.md +253 -0
  25. package/docs/design/autonomous-console-design-review.md +111 -0
  26. package/docs/design/autonomous-platform-mvp-discovery.md +525 -0
  27. package/docs/design/claude-code-source-deep-dive.md +713 -0
  28. package/docs/design/console-cyberpunk-ui-discovery.md +504 -0
  29. package/docs/design/console-execution-trace-candidates-final.md +160 -0
  30. package/docs/design/console-execution-trace-candidates.md +211 -0
  31. package/docs/design/console-execution-trace-design-candidates-v2.md +113 -0
  32. package/docs/design/console-execution-trace-design-review.md +74 -0
  33. package/docs/design/console-execution-trace-discovery.md +394 -0
  34. package/docs/design/console-execution-trace-final-review.md +77 -0
  35. package/docs/design/console-execution-trace-review.md +92 -0
  36. package/docs/design/console-performance-discovery.md +415 -0
  37. package/docs/design/console-ui-backlog.md +280 -0
  38. package/docs/design/daemon-architecture-discovery.md +853 -0
  39. package/docs/design/daemon-design-candidates.md +318 -0
  40. package/docs/design/daemon-design-review-findings.md +119 -0
  41. package/docs/design/daemon-engine-design-candidates.md +210 -0
  42. package/docs/design/daemon-engine-design-review.md +131 -0
  43. package/docs/design/daemon-execution-engine-discovery.md +280 -0
  44. package/docs/design/daemon-gap-analysis.md +554 -0
  45. package/docs/design/daemon-owns-console-plan.md +168 -0
  46. package/docs/design/daemon-owns-console-review.md +91 -0
  47. package/docs/design/daemon-owns-console.md +195 -0
  48. package/docs/design/data-model-erd.md +11 -0
  49. package/docs/design/design-candidates-consolidate-dev-staleness.md +98 -0
  50. package/docs/design/design-candidates-walk-cache-depth-limit.md +80 -0
  51. package/docs/design/design-review-consolidate-dev-staleness.md +54 -0
  52. package/docs/design/design-review-walk-cache-depth-limit.md +48 -0
  53. package/docs/design/implementation-plan-consolidate-dev-staleness.md +142 -0
  54. package/docs/design/implementation-plan-walk-cache-depth-limit.md +141 -0
  55. package/docs/design/layer3b-ghost-nodes-design-candidates.md +229 -0
  56. package/docs/design/layer3b-ghost-nodes-design-review.md +93 -0
  57. package/docs/design/layer3b-ghost-nodes-implementation-plan.md +219 -0
  58. package/docs/design/list-workflows-latency-fix-plan.md +128 -0
  59. package/docs/design/list-workflows-latency-fix-review.md +55 -0
  60. package/docs/design/list-workflows-latency-fix.md +109 -0
  61. package/docs/design/native-context-management-api.md +11 -0
  62. package/docs/design/performance-sweep-2026-04.md +96 -0
  63. package/docs/design/routines-guide.md +219 -0
  64. package/docs/design/sequence-diagrams.md +11 -0
  65. package/docs/design/subagent-design-principles.md +220 -0
  66. package/docs/design/temporal-patterns-design-candidates.md +312 -0
  67. package/docs/design/temporal-patterns-design-review-findings.md +163 -0
  68. package/docs/design/test-isolation-from-config-file.md +335 -0
  69. package/docs/design/v2-core-design-locks.md +2746 -0
  70. package/docs/design/v2-lock-registry.json +734 -0
  71. package/docs/design/workflow-authoring-v2.md +1044 -0
  72. package/docs/design/workflow-docs-spec.md +218 -0
  73. package/docs/design/workflow-extension-points.md +687 -0
  74. package/docs/design/workrail-auto-trigger-system.md +359 -0
  75. package/docs/design/workrail-config-file-discovery.md +513 -0
  76. package/docs/docker.md +110 -0
  77. package/docs/generated/v2-lock-closure-plan.md +26 -0
  78. package/docs/generated/v2-lock-coverage.json +797 -0
  79. package/docs/generated/v2-lock-coverage.md +177 -0
  80. package/docs/ideas/backlog.md +3927 -0
  81. package/docs/ideas/design-candidates-mcp-resilience.md +208 -0
  82. package/docs/ideas/design-review-findings-mcp-resilience.md +119 -0
  83. package/docs/ideas/implementation_plan.md +249 -0
  84. package/docs/ideas/third-party-workflow-setup-design-thinking.md +1948 -0
  85. package/docs/implementation/02-architecture.md +316 -0
  86. package/docs/implementation/04-testing-strategy.md +124 -0
  87. package/docs/implementation/09-simple-workflow-guide.md +835 -0
  88. package/docs/implementation/13-advanced-validation-guide.md +874 -0
  89. package/docs/implementation/README.md +21 -0
  90. package/docs/integrations/claude-code.md +300 -0
  91. package/docs/integrations/firebender.md +315 -0
  92. package/docs/migration/v0.1.0.md +147 -0
  93. package/docs/naming-conventions.md +45 -0
  94. package/docs/planning/README.md +104 -0
  95. package/docs/planning/github-ticketing-playbook.md +195 -0
  96. package/docs/plans/README.md +24 -0
  97. package/docs/plans/agent-managed-ticketing-design.md +605 -0
  98. package/docs/plans/agentic-orchestration-roadmap.md +112 -0
  99. package/docs/plans/assessment-gates-engine-handoff.md +536 -0
  100. package/docs/plans/content-coherence-and-references.md +151 -0
  101. package/docs/plans/library-extraction-plan.md +340 -0
  102. package/docs/plans/mr-review-workflow-redesign.md +1451 -0
  103. package/docs/plans/native-context-management-epic.md +11 -0
  104. package/docs/plans/perf-fixes-design-candidates.md +225 -0
  105. package/docs/plans/perf-fixes-design-review-findings.md +61 -0
  106. package/docs/plans/perf-fixes-new-issues-candidates.md +264 -0
  107. package/docs/plans/perf-fixes-new-issues-review.md +110 -0
  108. package/docs/plans/prompt-fragments.md +53 -0
  109. package/docs/plans/ui-ux-workflow-design-candidates.md +120 -0
  110. package/docs/plans/ui-ux-workflow-discovery.md +100 -0
  111. package/docs/plans/ui-ux-workflow-review.md +48 -0
  112. package/docs/plans/v2-followup-enhancements.md +587 -0
  113. package/docs/plans/workflow-categories-candidates.md +105 -0
  114. package/docs/plans/workflow-categories-discovery.md +110 -0
  115. package/docs/plans/workflow-categories-review.md +51 -0
  116. package/docs/plans/workflow-discovery-model-candidates.md +94 -0
  117. package/docs/plans/workflow-discovery-model-discovery.md +74 -0
  118. package/docs/plans/workflow-discovery-model-review.md +48 -0
  119. package/docs/plans/workflow-source-setup-phase-1.md +245 -0
  120. package/docs/plans/workflow-source-setup-phase-2.md +361 -0
  121. package/docs/plans/workflow-staleness-detection-candidates.md +104 -0
  122. package/docs/plans/workflow-staleness-detection-review.md +58 -0
  123. package/docs/plans/workflow-staleness-detection.md +80 -0
  124. package/docs/plans/workflow-v2-design.md +69 -0
  125. package/docs/plans/workflow-v2-roadmap.md +74 -0
  126. package/docs/plans/workflow-validation-design.md +98 -0
  127. package/docs/plans/workflow-validation-roadmap.md +108 -0
  128. package/docs/plans/workrail-platform-vision.md +420 -0
  129. package/docs/reference/agent-context-cleaner-snippet.md +94 -0
  130. package/docs/reference/agent-context-guidance.md +140 -0
  131. package/docs/reference/context-optimization.md +284 -0
  132. package/docs/reference/example-workflow-repository-template/.github/workflows/validate.yml +125 -0
  133. package/docs/reference/example-workflow-repository-template/README.md +268 -0
  134. package/docs/reference/example-workflow-repository-template/workflows/example-workflow.json +80 -0
  135. package/docs/reference/external-workflow-repositories.md +916 -0
  136. package/docs/reference/feature-flags-architecture.md +472 -0
  137. package/docs/reference/feature-flags.md +349 -0
  138. package/docs/reference/god-tier-workflow-validation.md +272 -0
  139. package/docs/reference/loop-optimization.md +209 -0
  140. package/docs/reference/loop-validation.md +176 -0
  141. package/docs/reference/loops.md +465 -0
  142. package/docs/reference/mcp-platform-constraints.md +59 -0
  143. package/docs/reference/recovery.md +88 -0
  144. package/docs/reference/releases.md +177 -0
  145. package/docs/reference/troubleshooting.md +105 -0
  146. package/docs/reference/workflow-execution-contract.md +998 -0
  147. package/docs/roadmap/README.md +22 -0
  148. package/docs/roadmap/legacy-planning-status.md +103 -0
  149. package/docs/roadmap/now-next-later.md +70 -0
  150. package/docs/roadmap/open-work-inventory.md +389 -0
  151. package/docs/tickets/README.md +39 -0
  152. package/docs/tickets/next-up.md +76 -0
  153. package/docs/workflow-management.md +317 -0
  154. package/docs/workflow-templates.md +423 -0
  155. package/docs/workflow-validation.md +184 -0
  156. package/docs/workflows.md +254 -0
  157. package/package.json +3 -1
  158. package/spec/authoring-spec.json +61 -16
  159. package/workflows/workflow-for-workflows.json +252 -93
  160. package/workflows/workflow-for-workflows.v2.json +188 -77
@@ -0,0 +1,254 @@
1
+ # Available Workflows
2
+
3
+ > **Auto-generated** from workflow files. Run `workrail list` for the latest.
4
+ >
5
+ > Last updated: 2026-03-24
6
+
7
+ ## Overview
8
+
9
+ WorkRail includes **20 production workflows** across multiple categories.
10
+
11
+ | Category | Count |
12
+ |----------|-------|
13
+ | Development | 1 |
14
+ | Debugging | 2 |
15
+ | Code Review | 2 |
16
+ | Documentation | 3 |
17
+ | Exploration & Analysis | 3 |
18
+ | Learning & Education | 3 |
19
+ | Other | 6 |
20
+
21
+ ---
22
+
23
+ ## Development
24
+
25
+ Feature implementation and coding workflows
26
+
27
+ ### `coding-task-workflow-agentic`
28
+
29
+ **Agentic Task Dev Workflow (Lean • Notes-First • WorkRail Executor)** (v1.0.0)
30
+
31
+ The user guides the agent through understanding the task, selecting an approach, planning in slices, implementing incrementally, and verifying the result through explicit review and validation checkpoints.
32
+
33
+ - **Steps**: 12
34
+ - **File**: `workflows/coding-task-workflow-agentic.lean.v2.json`
35
+
36
+ ## Debugging
37
+
38
+ Bug investigation and troubleshooting
39
+
40
+ ### `bug-investigation`
41
+
42
+ **Bug Investigation** (v1.0.0)
43
+
44
+ A systematic bug investigation workflow that finds the true source of bugs through strategic planning and evidence-based analysis. Guides agents through plan-then-execute phases to avoid jumping to conclusions.
45
+
46
+ - **Steps**: 10
47
+ - **File**: `workflows/bug-investigation.json`
48
+
49
+ ### `bug-investigation-agentic`
50
+
51
+ **Bug Investigation (v2 • Notes-First • WorkRail Executor)** (v2.0.0)
52
+
53
+ A v2-first bug investigation workflow focused on moving from theory to proof with notes-first durability, explicit trigger fields, de-anchored fresh-eye review, and investigation-only handoff boundaries.
54
+
55
+ - **Steps**: 9
56
+ - **File**: `workflows/bug-investigation.agentic.v2.json`
57
+
58
+ ## Code Review
59
+
60
+ Merge request and code review processes
61
+
62
+ ### `mr-review-workflow`
63
+
64
+ **Adaptive MR Review Workflow** (v0.2.0)
65
+
66
+ An adaptive workflow to guide an AI agent in performing a comprehensive code review. It adjusts its rigor based on MR complexity and includes checkpoints for architectural and self-critique to provide deep, actionable feedback.
67
+
68
+ - **Steps**: 10
69
+ - **File**: `workflows/mr-review-workflow.json`
70
+
71
+ ### `mr-review-workflow-agentic`
72
+
73
+ **MR Review Workflow (v2 • Notes-First • Parallel Reviewer Families)** (v2.1.0)
74
+
75
+ A v2-first MR review workflow that uses a shared fact packet, parallel reviewer families, an explicit coverage ledger, and contradiction-driven synthesis to produce high-signal review output without duplicating context gathering.
76
+
77
+ - **Steps**: 9
78
+ - **File**: `workflows/mr-review-workflow.agentic.v2.json`
79
+
80
+ ## Documentation
81
+
82
+ Creating and maintaining documentation
83
+
84
+ ### `document-creation-workflow`
85
+
86
+ **Document Creation Workflow** (v0.0.1)
87
+
88
+ Create BROAD or COMPREHENSIVE documentation spanning multiple components/systems. Perfect for: project READMEs, complete API documentation, user guides covering multiple features, technical specifications for systems. Uses complexity triage (Simple/Standard/Complex) to adapt rigor. For SINGLE, BOUNDED subjects (one class, one integration), use scoped-documentation-workflow instead for better scope discipline.
89
+
90
+ - **Steps**: 11
91
+ - **File**: `workflows/document-creation-workflow.json`
92
+
93
+ ### `documentation-update-workflow`
94
+
95
+ **Documentation Update & Maintenance Workflow** (v1.0.0)
96
+
97
+ UPDATE and MAINTAIN existing documentation. Analyzes Git history to detect staleness, identifies outdated sections, and systematically refreshes docs while preserving valuable content. Perfect for: refreshing docs after code changes, scheduled maintenance, addressing feedback. NOT for creating new docs - use scoped-documentation-workflow or document-creation-workflow for new documentation.
98
+
99
+ - **Steps**: 15
100
+ - **File**: `workflows/documentation-update-workflow.json`
101
+
102
+ ### `scoped-documentation-workflow`
103
+
104
+ **Scoped Documentation Workflow** (v1.0.0)
105
+
106
+ Create documentation for a SINGLE, BOUNDED subject with strict scope enforcement. Perfect for: one class/component, one integration point, one mechanism, one architecture decision. Prevents documentation sprawl through continuous boundary validation (9+/10 scope compliance required). NOT for: project READMEs, multi-component systems, or comprehensive guides - use document-creation-workflow for those.
107
+
108
+ - **Steps**: 10
109
+ - **File**: `workflows/scoped-documentation-workflow.json`
110
+
111
+ ## Exploration & Analysis
112
+
113
+ Understanding codebases and systems
114
+
115
+ ### `adaptive-ticket-creation`
116
+
117
+ **Adaptive Ticket Creation Workflow** (v0.1.0)
118
+
119
+ An intelligent workflow for creating high-quality Jira tickets. Uses LLM-driven path selection to automatically choose between Simple, Standard, or Epic complexity paths based on request analysis.
120
+
121
+ - **Steps**: 9
122
+ - **File**: `workflows/adaptive-ticket-creation.json`
123
+
124
+ ### `wr.discovery`
125
+
126
+ **Discovery Workflow (Bundled • Exploration + Design Synthesis)** (v3.0.0)
127
+
128
+ A bundled upstream thinking workflow that merges the old exploration and design-thinking workflows into one adaptive flow. It chooses between landscape-first, full-spectrum, and design-first paths while preserving a shared notes-first structure for framing, synthesis, challenge, and recommendation or prototype-driven learning.
129
+
130
+ - **Steps**: 12
131
+ - **File**: `workflows/wr.discovery.json`
132
+
133
+ ### `intelligent-test-case-generation`
134
+
135
+ **Intelligent Test Case Generation from Tickets** (v0.0.1)
136
+
137
+ Transforms ticket requirements into systematic test cases using evidence-driven analysis, dual-brain processing (NLP + LLM), document discovery, and progressive scenario expansion. Produces integration and end-to-end tests optimized for developer readability and LLM consumption with confidence scoring and validation loops.
138
+
139
+ - **Steps**: 12
140
+ - **File**: `workflows/intelligent-test-case-generation.json`
141
+
142
+ ## Learning & Education
143
+
144
+ Course design and learning materials
145
+
146
+ ### `personal-learning-course-design`
147
+
148
+ **Personal Learning Course Design Workflow** (v1.0.0)
149
+
150
+ A systematic workflow for designing effective personal learning courses with three thoroughness paths: Quick Start (3-5 days for essential structure), Balanced (1-2 weeks for comprehensive system), and Comprehensive (2-3 weeks for professional-grade pedagogical depth). Adapts complexity based on user time constraints and learning design experience.
151
+
152
+ - **Steps**: 11
153
+ - **File**: `workflows/learner-centered-course-workflow.json`
154
+
155
+ ### `personal-learning-materials-creation-branched`
156
+
157
+ **Personal Learning Materials Creation Workflow (Branched)** (v1.0.0)
158
+
159
+ A systematic workflow for creating high-quality learning materials with three thoroughness paths: Quick Start (essential materials), Balanced (comprehensive system), and Comprehensive (enterprise-grade). Adapts depth and features based on user time constraints and quality goals.
160
+
161
+ - **Steps**: 6
162
+ - **File**: `workflows/personal-learning-materials-creation-branched.json`
163
+
164
+ ### `presentation-creation`
165
+
166
+ **Dynamic Presentation Creation Workflow** (v0.1.0)
167
+
168
+ A comprehensive workflow for creating dynamic, interesting, and insightful presentations. Guides users through audience analysis, content strategy, visual design, and delivery preparation to create compelling presentations that engage and inform.
169
+
170
+ - **Steps**: 9
171
+ - **File**: `workflows/presentation-creation.json`
172
+
173
+ ## Other
174
+
175
+ Miscellaneous workflows
176
+
177
+ ### `cross-platform-code-conversion`
178
+
179
+ **Cross-Platform Code Conversion** (v0.1.0)
180
+
181
+ Guides an agent through converting code from one platform to another (e.g., Android to iOS, iOS to Web). Triages files by difficulty, delegates easy literal translations to parallel subagents, then the main agent tackles platform-specific code requiring design decisions.
182
+
183
+ - **Steps**: 9
184
+ - **File**: `workflows/cross-platform-code-conversion.v2.json`
185
+
186
+ ### `design-thinking-workflow`
187
+
188
+ **Design Thinking Workflow** (v0.0.1)
189
+
190
+ A structured-reflective design thinking process: Empathize → Define → multi-round Ideate → Synthesize → Prototype (learning artifact) → Test plan → Iterate (test/learn/refine).
191
+
192
+ - **Steps**: 11
193
+ - **File**: `workflows/design-thinking-workflow.json`
194
+
195
+ ### `design-thinking-workflow-autonomous-agentic`
196
+
197
+ **Design Thinking Workflow (Autonomous, Tiered Agent Cascade)** (v0.1.0)
198
+
199
+ Autonomous design thinking: minimal human input; doc-first execution; supports Agent Cascade Protocol tiers (Solo/Proxy/Delegation) with explicit fallbacks.
200
+
201
+ - **Steps**: 16
202
+ - **File**: `workflows/design-thinking-workflow-autonomous.agentic.json`
203
+
204
+ ### `relocation-workflow-us`
205
+
206
+ **Relocation Decision Workflow (US v1 — AreaSpec • Custom Areas • Dossier • Evidence • Ranking)** (v0.2.0)
207
+
208
+ A bias-resistant, evidence-driven relocation workflow for the United States. Helps users discover what they care about, generate a broad candidate pool (including optional custom areas), screen it with strict caps, deep-dive shortlisted areas, and produce a master dossier plus per-location profile docs with a transparent, explainable weighted ranking.
209
+
210
+ - **Steps**: 19
211
+ - **File**: `workflows/relocation-workflow-us.json`
212
+
213
+ ### `workflow-diagnose-environment`
214
+
215
+ **Diagnostic: Environment & Subagents** (v1.0.0)
216
+
217
+ Automated capability detection for Agentic IDEs. Probes for subagent access and generates a local configuration file.
218
+
219
+ - **Steps**: 2
220
+ - **File**: `workflows/workflow-diagnose-environment.json`
221
+
222
+ ### `workflow-for-workflows`
223
+
224
+ **Workflow Authoring Workflow (Lean, References-First)** (v2.0.0)
225
+
226
+ Guides an agent through creating a new WorkRail workflow: understand the task, choose the shape, draft the JSON, validate with real validators, review the method, and optionally refine.
227
+
228
+ - **Steps**: 8
229
+ - **File**: `workflows/workflow-for-workflows.v2.json`
230
+
231
+ ---
232
+
233
+ ## Using Workflows
234
+
235
+ Tell your AI agent which workflow to use:
236
+
237
+ ```
238
+ "Use the bug-investigation workflow to debug this issue"
239
+ "Use the coding-task-workflow-agentic to implement this feature"
240
+ ```
241
+
242
+ Or browse programmatically:
243
+
244
+ ```bash
245
+ # List all workflows
246
+ workrail list
247
+
248
+ # Get details about a specific workflow
249
+ workrail list --verbose
250
+ ```
251
+
252
+ ## Creating Custom Workflows
253
+
254
+ See the [Workflow Authoring Guide](authoring.md) to create your own workflows.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@exaudeus/workrail",
3
- "version": "3.27.0",
3
+ "version": "3.29.0",
4
4
  "description": "Step-by-step workflow enforcement for AI agents via MCP",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -24,6 +24,7 @@
24
24
  },
25
25
  "files": [
26
26
  "dist",
27
+ "docs",
27
28
  "spec",
28
29
  "workflows",
29
30
  "web"
@@ -46,6 +47,7 @@
46
47
  "validate:authoring-spec": "node scripts/validate-authoring-spec.js",
47
48
  "validate:authoring-docs": "node scripts/generate-authoring-docs.js --check",
48
49
  "validate:workflow-discovery": "node scripts/validate-workflow-discovery.js",
50
+ "validate:feature-coverage": "node scripts/validate-feature-coverage.js",
49
51
  "precommit": "npm run validate:registry",
50
52
  "preinstall": "node -e \"const v=parseInt(process.versions.node.split('.')[0],10); if(v<20){console.error('WorkRail requires Node.js >=20. Current: '+process.versions.node+'\\nPlease upgrade: https://nodejs.org/'); process.exit(1);}\"",
51
53
  "dev:mcp": "pkill -f \"$(pwd)/dist/mcp-server.js\" 2>/dev/null; sleep 0.5; WORKRAIL_TRANSPORT=http WORKRAIL_ENABLE_SESSION_TOOLS=true node dist/mcp-server.js",
@@ -3,7 +3,7 @@
3
3
  "version": 3,
4
4
  "title": "WorkRail Authoring Rules",
5
5
  "purpose": "Canonical current rules for authoring good WorkRail workflows. workflow.schema.json remains the source of truth for legal structure.",
6
- "lastReviewed": "2026-04-04",
6
+ "lastReviewed": "2026-04-16",
7
7
  "principles": [
8
8
  "Schema defines what is valid. These rules define what is good.",
9
9
  "Prefer current authoring rules over design rationale or historical notes.",
@@ -200,6 +200,22 @@
200
200
  {
201
201
  "id": "legacy.patterns",
202
202
  "description": "Older authoring patterns that should now be discouraged or avoided"
203
+ },
204
+ {
205
+ "id": "workflow.references",
206
+ "description": "The workflow-level references array declaring external documents surfaced at start time."
207
+ },
208
+ {
209
+ "id": "workflow.assessments",
210
+ "description": "The workflow-level assessments array declaring reusable assessment gate definitions."
211
+ },
212
+ {
213
+ "id": "step.assessment-refs",
214
+ "description": "The step-level assessmentRefs array referencing declared assessment gate definitions."
215
+ },
216
+ {
217
+ "id": "step.assessment-consequences",
218
+ "description": "The step-level assessmentConsequences array declaring blocking consequences when gate dimension levels are met."
203
219
  }
204
220
  ],
205
221
  "topics": [
@@ -647,6 +663,7 @@
647
663
  ],
648
664
  "checks": [
649
665
  "If the workflow delegates work to subagents, declare `wr.features.subagent_guidance`.",
666
+ "If the workflow uses optional capabilities (delegation, web, code execution), declare `wr.features.capabilities`.",
650
667
  "If the workflow uses Memory MCP for context recall or persistence, declare `wr.features.memory_context`.",
651
668
  "Do not duplicate feature-injected guidance in metaGuidance or step prompts. Let the compiler handle it."
652
669
  ],
@@ -684,6 +701,35 @@
684
701
  "antiPatterns": [
685
702
  "Inventing feature IDs like `wr.features.my_custom_thing`"
686
703
  ]
704
+ },
705
+ {
706
+ "id": "declare-capabilities-for-optional-tool-use",
707
+ "status": "active",
708
+ "level": "recommended",
709
+ "scope": [
710
+ "workflow.features"
711
+ ],
712
+ "rule": "Declare `wr.features.capabilities` when the workflow depends on optional capabilities (delegation, web access, code execution, etc.) that may not be available in every environment.",
713
+ "why": "The capabilities feature injects constraint and graceful-degradation guidance at every step. Without it, agents silently assume optional capabilities are available and produce brittle workflows that fail in restricted environments.",
714
+ "enforcement": [
715
+ "advisory"
716
+ ],
717
+ "sourceRefs": [
718
+ {
719
+ "kind": "runtime",
720
+ "path": "src/application/services/compiler/feature-registry.ts",
721
+ "note": "Canonical feature definition for wr.features.capabilities, including injected constraints and procedure steps."
722
+ }
723
+ ],
724
+ "checks": [
725
+ "If the workflow uses delegation, web access, code execution, or any other capability that may be unavailable, declare `wr.features.capabilities`.",
726
+ "If delegation is also used, declare both `wr.features.capabilities` and `wr.features.subagent_guidance` -- they inject different guidance.",
727
+ "Do not declare `wr.features.capabilities` for workflows that only use standard file/tool access available in all environments."
728
+ ],
729
+ "antiPatterns": [
730
+ "Skipping `wr.features.capabilities` for a workflow that delegates to subagents or fetches from the web, leaving agents with no degradation guidance when the capability is absent",
731
+ "Declaring `wr.features.capabilities` for a workflow that only uses universally-available tools like Read, Write, and Bash"
732
+ ]
687
733
  }
688
734
  ]
689
735
  },
@@ -941,12 +987,14 @@
941
987
  "level": "recommended",
942
988
  "scope": [
943
989
  "workflow.assessments",
944
- "step.assessmentRefs",
945
- "step.assessmentConsequences"
990
+ "step.assessment-refs",
991
+ "step.assessment-consequences"
946
992
  ],
947
993
  "rule": "Use assessment gates when a step needs the agent to submit a bounded, durable judgment before the workflow can safely advance -- not for generic scoring or ceremony.",
948
994
  "why": "Assessment gates force explicit structured reasoning at a decision point and durably record the result. Generic scoring that never affects routing adds noise without value.",
949
- "enforcement": ["advisory"],
995
+ "enforcement": [
996
+ "advisory"
997
+ ],
950
998
  "sourceRefs": [
951
999
  {
952
1000
  "kind": "example",
@@ -978,7 +1026,9 @@
978
1026
  ],
979
1027
  "rule": "Each dimension in an assessment must capture a distinct failure mode that the other dimensions cannot catch. A dimension that restates existing workflow state (such as a generic 'confidence' dimension that mirrors the workflow's confidence band) adds ceremony without structure.",
980
1028
  "why": "The value of multiple dimensions is that each one independently blocks advancement for a different reason. Correlated or vague dimensions collapse to a single gate with extra steps.",
981
- "enforcement": ["advisory"],
1029
+ "enforcement": [
1030
+ "advisory"
1031
+ ],
982
1032
  "checks": [
983
1033
  "Each dimension is independently checkable without needing to know the result of the others.",
984
1034
  "No dimension restates a context variable the workflow already computes (e.g. recommendationConfidenceBand).",
@@ -995,12 +1045,14 @@
995
1045
  "status": "active",
996
1046
  "level": "required",
997
1047
  "scope": [
998
- "step.assessmentRefs",
999
- "step.assessmentConsequences"
1048
+ "step.assessment-refs",
1049
+ "step.assessment-consequences"
1000
1050
  ],
1001
1051
  "rule": "A step may declare one or more assessmentRefs and at most one assessmentConsequences entry. When assessmentConsequences is present, at least one ref is required. Use anyEqualsLevel as the trigger -- the engine checks all submitted dimensions across all referenced assessments and fires if any equals that level.",
1002
1052
  "why": "Multiple refs allow composing separate orthogonal assessment definitions (e.g. quality-gate + coverage-gate) behind a single blocking consequence, without forcing unrelated dimensions into one monolithic definition.",
1003
- "enforcement": ["schema"],
1053
+ "enforcement": [
1054
+ "validator"
1055
+ ],
1004
1056
  "checks": [
1005
1057
  "At least one assessmentRefs entry when assessmentConsequences is present.",
1006
1058
  "No more than one assessmentConsequences entry per step.",
@@ -1484,12 +1536,5 @@
1484
1536
  ]
1485
1537
  }
1486
1538
  ],
1487
- "plannedRules": [],
1488
- "changelog": [
1489
- {
1490
- "version": 3,
1491
- "date": "2026-03-21",
1492
- "summary": "Baseline version at staleness feature introduction."
1493
- }
1494
- ]
1539
+ "plannedRules": []
1495
1540
  }