@exaudeus/workrail 3.73.2 → 3.74.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.
- package/dist/cli-worktrain.js +126 -1
- package/dist/console-ui/assets/{index-CfI4I3OX.js → index-CfU3va8H.js} +1 -1
- package/dist/console-ui/index.html +1 -1
- package/dist/coordinators/pr-review.d.ts +11 -1
- package/dist/coordinators/types.d.ts +15 -0
- package/dist/coordinators/types.js +2 -0
- package/dist/manifest.json +17 -9
- package/dist/trigger/coordinator-deps.js +203 -36
- package/docs/authoring.md +23 -0
- package/docs/ideas/backlog.md +100 -65
- package/package.json +1 -1
- package/spec/authoring-spec.json +36 -1
package/spec/authoring-spec.json
CHANGED
|
@@ -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-
|
|
6
|
+
"lastReviewed": "2026-04-28",
|
|
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.",
|
|
@@ -189,6 +189,10 @@
|
|
|
189
189
|
"id": "artifact.verification",
|
|
190
190
|
"description": "Verification or handoff artifacts"
|
|
191
191
|
},
|
|
192
|
+
{
|
|
193
|
+
"id": "artifact.coordinator-result",
|
|
194
|
+
"description": "wr.coordinator_result artifact emitted by coordinator-phase workflows to signal phase completion to the coordinator"
|
|
195
|
+
},
|
|
192
196
|
{
|
|
193
197
|
"id": "delegation.context-packet",
|
|
194
198
|
"description": "Structured context passed to subagents"
|
|
@@ -1429,6 +1433,37 @@
|
|
|
1429
1433
|
"id": "artifacts",
|
|
1430
1434
|
"title": "Artifacts and planning surfaces",
|
|
1431
1435
|
"rules": [
|
|
1436
|
+
{
|
|
1437
|
+
"id": "coordinator-result-artifact-schema",
|
|
1438
|
+
"status": "active",
|
|
1439
|
+
"level": "required",
|
|
1440
|
+
"scope": [
|
|
1441
|
+
"artifact.coordinator-result"
|
|
1442
|
+
],
|
|
1443
|
+
"rule": "When a workflow step signals coordinator phase completion, emit a `wr.coordinator_result` artifact with exactly 4 fields: `outcome` (enum: success|failed|timed_out|await_degraded), `summary` (string), `sessionId` (string), `error` (string|null). No additional fields allowed.",
|
|
1444
|
+
"why": "Coordinators read this artifact to determine whether to proceed, retry, or escalate. Extra fields pollute the schema boundary and break forward compatibility. The 4-field constraint is a hard limit, not a guideline.",
|
|
1445
|
+
"enforcement": [
|
|
1446
|
+
"advisory"
|
|
1447
|
+
],
|
|
1448
|
+
"checks": [
|
|
1449
|
+
"Exactly 4 fields present: outcome, summary, sessionId, error.",
|
|
1450
|
+
"outcome is one of: success, failed, timed_out, await_degraded.",
|
|
1451
|
+
"error is string|null -- null when outcome is success, non-null string when outcome is failed.",
|
|
1452
|
+
"No workflow-specific fields (prUrl, branchName, commitSha, etc.) in wr.coordinator_result. Those belong in workflow-specific artifacts."
|
|
1453
|
+
],
|
|
1454
|
+
"antiPatterns": [
|
|
1455
|
+
"Adding prUrl, branchName, or commitSha to wr.coordinator_result",
|
|
1456
|
+
"Using a free-form notes string instead of the typed outcome enum",
|
|
1457
|
+
"Omitting sessionId (required for coordinator tracing and console parent-child display)"
|
|
1458
|
+
],
|
|
1459
|
+
"sourceRefs": [
|
|
1460
|
+
{
|
|
1461
|
+
"kind": "runtime",
|
|
1462
|
+
"path": "src/coordinators/types.ts",
|
|
1463
|
+
"note": "ChildSessionResult discriminated union -- the runtime type that wr.coordinator_result maps to."
|
|
1464
|
+
}
|
|
1465
|
+
]
|
|
1466
|
+
},
|
|
1432
1467
|
{
|
|
1433
1468
|
"id": "artifact-canonicality",
|
|
1434
1469
|
"status": "active",
|