@exaudeus/workrail 3.5.0 → 3.6.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.
- package/README.md +4 -1
- package/dist/application/services/validation-engine.js +50 -0
- package/dist/config/feature-flags.js +8 -0
- package/dist/engine/engine-factory.js +4 -2
- package/dist/manifest.json +102 -54
- package/dist/mcp/handler-factory.js +21 -4
- package/dist/mcp/handlers/v2-execution/continue-rehydrate.d.ts +6 -1
- package/dist/mcp/handlers/v2-execution/continue-rehydrate.js +22 -4
- package/dist/mcp/handlers/v2-execution/index.d.ts +6 -1
- package/dist/mcp/handlers/v2-execution/index.js +13 -3
- package/dist/mcp/handlers/v2-execution/start.d.ts +9 -1
- package/dist/mcp/handlers/v2-execution/start.js +74 -36
- package/dist/mcp/handlers/v2-execution-helpers.d.ts +2 -0
- package/dist/mcp/handlers/v2-execution-helpers.js +2 -0
- package/dist/mcp/handlers/v2-reference-resolver.d.ts +14 -0
- package/dist/mcp/handlers/v2-reference-resolver.js +112 -0
- package/dist/mcp/handlers/v2-resolve-refs-envelope.d.ts +5 -0
- package/dist/mcp/handlers/v2-resolve-refs-envelope.js +17 -0
- package/dist/mcp/handlers/v2-workflow.js +2 -0
- package/dist/mcp/output-schemas.d.ts +38 -0
- package/dist/mcp/output-schemas.js +8 -0
- package/dist/mcp/render-envelope.d.ts +21 -0
- package/dist/mcp/render-envelope.js +59 -0
- package/dist/mcp/response-supplements.d.ts +17 -0
- package/dist/mcp/response-supplements.js +58 -0
- package/dist/mcp/step-content-envelope.d.ts +32 -0
- package/dist/mcp/step-content-envelope.js +13 -0
- package/dist/mcp/transports/stdio-entry.js +19 -6
- package/dist/mcp/v2-response-formatter.d.ts +11 -1
- package/dist/mcp/v2-response-formatter.js +168 -1
- package/dist/mcp/workflow-protocol-contracts.js +9 -7
- package/dist/types/workflow-definition.d.ts +16 -0
- package/dist/types/workflow-definition.js +1 -0
- package/dist/utils/condition-evaluator.d.ts +1 -0
- package/dist/utils/condition-evaluator.js +7 -0
- package/dist/v2/durable-core/domain/context-template-resolver.d.ts +2 -0
- package/dist/v2/durable-core/domain/context-template-resolver.js +26 -0
- package/dist/v2/durable-core/domain/prompt-renderer.d.ts +2 -0
- package/dist/v2/durable-core/domain/prompt-renderer.js +93 -15
- package/dist/v2/durable-core/schemas/compiled-workflow/index.d.ts +256 -0
- package/dist/v2/durable-core/schemas/compiled-workflow/index.js +30 -0
- package/package.json +4 -1
- package/spec/authoring-spec.provenance.json +77 -0
- package/spec/authoring-spec.schema.json +370 -0
- package/workflows/coding-task-workflow-agentic.lean.v2.json +132 -30
- package/workflows/workflow-for-workflows.json +27 -1
|
@@ -0,0 +1,370 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "https://workrail.dev/schemas/authoring-spec/v1",
|
|
4
|
+
"title": "WorkRail Authoring Spec Schema",
|
|
5
|
+
"description": "Schema for spec/authoring-spec.json",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": [
|
|
9
|
+
"version",
|
|
10
|
+
"title",
|
|
11
|
+
"purpose",
|
|
12
|
+
"principles",
|
|
13
|
+
"consumedBy",
|
|
14
|
+
"changeProtocol",
|
|
15
|
+
"ruleModel",
|
|
16
|
+
"scopeCatalog",
|
|
17
|
+
"topics"
|
|
18
|
+
],
|
|
19
|
+
"properties": {
|
|
20
|
+
"$schema": {
|
|
21
|
+
"type": "string"
|
|
22
|
+
},
|
|
23
|
+
"version": {
|
|
24
|
+
"type": "integer",
|
|
25
|
+
"minimum": 1
|
|
26
|
+
},
|
|
27
|
+
"title": {
|
|
28
|
+
"type": "string",
|
|
29
|
+
"minLength": 1,
|
|
30
|
+
"maxLength": 128
|
|
31
|
+
},
|
|
32
|
+
"purpose": {
|
|
33
|
+
"type": "string",
|
|
34
|
+
"minLength": 1,
|
|
35
|
+
"maxLength": 512
|
|
36
|
+
},
|
|
37
|
+
"lastReviewed": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"pattern": "^\\d{4}-\\d{2}-\\d{2}$"
|
|
40
|
+
},
|
|
41
|
+
"principles": {
|
|
42
|
+
"type": "array",
|
|
43
|
+
"items": {
|
|
44
|
+
"type": "string",
|
|
45
|
+
"minLength": 1,
|
|
46
|
+
"maxLength": 256
|
|
47
|
+
},
|
|
48
|
+
"minItems": 1
|
|
49
|
+
},
|
|
50
|
+
"consumedBy": {
|
|
51
|
+
"type": "array",
|
|
52
|
+
"items": {
|
|
53
|
+
"type": "string",
|
|
54
|
+
"minLength": 1,
|
|
55
|
+
"maxLength": 64
|
|
56
|
+
},
|
|
57
|
+
"minItems": 1,
|
|
58
|
+
"uniqueItems": true
|
|
59
|
+
},
|
|
60
|
+
"changeProtocol": {
|
|
61
|
+
"type": "array",
|
|
62
|
+
"items": {
|
|
63
|
+
"type": "string",
|
|
64
|
+
"minLength": 1,
|
|
65
|
+
"maxLength": 256
|
|
66
|
+
},
|
|
67
|
+
"minItems": 1
|
|
68
|
+
},
|
|
69
|
+
"ruleModel": {
|
|
70
|
+
"type": "object",
|
|
71
|
+
"additionalProperties": false,
|
|
72
|
+
"required": [
|
|
73
|
+
"levels",
|
|
74
|
+
"statuses",
|
|
75
|
+
"enforcementModes",
|
|
76
|
+
"scopeStyle"
|
|
77
|
+
],
|
|
78
|
+
"properties": {
|
|
79
|
+
"levels": {
|
|
80
|
+
"type": "array",
|
|
81
|
+
"items": {
|
|
82
|
+
"type": "string",
|
|
83
|
+
"enum": ["required", "recommended", "discouraged"]
|
|
84
|
+
},
|
|
85
|
+
"uniqueItems": true
|
|
86
|
+
},
|
|
87
|
+
"statuses": {
|
|
88
|
+
"type": "array",
|
|
89
|
+
"items": {
|
|
90
|
+
"type": "string",
|
|
91
|
+
"enum": ["active", "experimental", "planned", "deprecated"]
|
|
92
|
+
},
|
|
93
|
+
"uniqueItems": true
|
|
94
|
+
},
|
|
95
|
+
"enforcementModes": {
|
|
96
|
+
"type": "array",
|
|
97
|
+
"items": {
|
|
98
|
+
"type": "string",
|
|
99
|
+
"enum": ["runtime", "validator", "ci", "advisory", "planned"]
|
|
100
|
+
},
|
|
101
|
+
"uniqueItems": true
|
|
102
|
+
},
|
|
103
|
+
"scopeStyle": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"minLength": 1,
|
|
106
|
+
"maxLength": 256
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
"scopeCatalog": {
|
|
111
|
+
"type": "array",
|
|
112
|
+
"items": {
|
|
113
|
+
"$ref": "#/$defs/scopeEntry"
|
|
114
|
+
},
|
|
115
|
+
"minItems": 1
|
|
116
|
+
},
|
|
117
|
+
"topics": {
|
|
118
|
+
"type": "array",
|
|
119
|
+
"items": {
|
|
120
|
+
"$ref": "#/$defs/topic"
|
|
121
|
+
},
|
|
122
|
+
"minItems": 1
|
|
123
|
+
},
|
|
124
|
+
"plannedTopics": {
|
|
125
|
+
"type": "array",
|
|
126
|
+
"items": {
|
|
127
|
+
"$ref": "#/$defs/topic"
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
"plannedRules": {
|
|
131
|
+
"type": "array",
|
|
132
|
+
"items": {
|
|
133
|
+
"$ref": "#/$defs/plannedRule"
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
"$defs": {
|
|
138
|
+
"ruleLevel": {
|
|
139
|
+
"type": "string",
|
|
140
|
+
"enum": ["required", "recommended", "discouraged"]
|
|
141
|
+
},
|
|
142
|
+
"ruleStatus": {
|
|
143
|
+
"type": "string",
|
|
144
|
+
"enum": ["active", "experimental", "planned", "deprecated"]
|
|
145
|
+
},
|
|
146
|
+
"enforcementMode": {
|
|
147
|
+
"type": "string",
|
|
148
|
+
"enum": ["runtime", "validator", "ci", "advisory", "planned"]
|
|
149
|
+
},
|
|
150
|
+
"scopeToken": {
|
|
151
|
+
"type": "string",
|
|
152
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z][a-z0-9-]*)*$",
|
|
153
|
+
"minLength": 3,
|
|
154
|
+
"maxLength": 64
|
|
155
|
+
},
|
|
156
|
+
"scopeEntry": {
|
|
157
|
+
"type": "object",
|
|
158
|
+
"additionalProperties": false,
|
|
159
|
+
"required": ["id", "description"],
|
|
160
|
+
"properties": {
|
|
161
|
+
"id": {
|
|
162
|
+
"$ref": "#/$defs/scopeToken"
|
|
163
|
+
},
|
|
164
|
+
"description": {
|
|
165
|
+
"type": "string",
|
|
166
|
+
"minLength": 1,
|
|
167
|
+
"maxLength": 256
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
},
|
|
171
|
+
"topic": {
|
|
172
|
+
"type": "object",
|
|
173
|
+
"additionalProperties": false,
|
|
174
|
+
"required": ["id", "title", "rules"],
|
|
175
|
+
"properties": {
|
|
176
|
+
"id": {
|
|
177
|
+
"$ref": "#/$defs/scopeToken"
|
|
178
|
+
},
|
|
179
|
+
"title": {
|
|
180
|
+
"type": "string",
|
|
181
|
+
"minLength": 1,
|
|
182
|
+
"maxLength": 128
|
|
183
|
+
},
|
|
184
|
+
"rules": {
|
|
185
|
+
"type": "array",
|
|
186
|
+
"items": {
|
|
187
|
+
"$ref": "#/$defs/rule"
|
|
188
|
+
},
|
|
189
|
+
"minItems": 1
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
},
|
|
193
|
+
"rule": {
|
|
194
|
+
"type": "object",
|
|
195
|
+
"additionalProperties": false,
|
|
196
|
+
"required": [
|
|
197
|
+
"id",
|
|
198
|
+
"status",
|
|
199
|
+
"level",
|
|
200
|
+
"scope",
|
|
201
|
+
"rule",
|
|
202
|
+
"why",
|
|
203
|
+
"enforcement"
|
|
204
|
+
],
|
|
205
|
+
"properties": {
|
|
206
|
+
"id": {
|
|
207
|
+
"$ref": "#/$defs/scopeToken"
|
|
208
|
+
},
|
|
209
|
+
"status": {
|
|
210
|
+
"$ref": "#/$defs/ruleStatus"
|
|
211
|
+
},
|
|
212
|
+
"level": {
|
|
213
|
+
"$ref": "#/$defs/ruleLevel"
|
|
214
|
+
},
|
|
215
|
+
"scope": {
|
|
216
|
+
"type": "array",
|
|
217
|
+
"items": {
|
|
218
|
+
"$ref": "#/$defs/scopeToken"
|
|
219
|
+
},
|
|
220
|
+
"minItems": 1,
|
|
221
|
+
"uniqueItems": true
|
|
222
|
+
},
|
|
223
|
+
"rule": {
|
|
224
|
+
"type": "string",
|
|
225
|
+
"minLength": 1,
|
|
226
|
+
"maxLength": 512
|
|
227
|
+
},
|
|
228
|
+
"why": {
|
|
229
|
+
"type": "string",
|
|
230
|
+
"minLength": 1,
|
|
231
|
+
"maxLength": 256
|
|
232
|
+
},
|
|
233
|
+
"enforcement": {
|
|
234
|
+
"type": "array",
|
|
235
|
+
"items": {
|
|
236
|
+
"$ref": "#/$defs/enforcementMode"
|
|
237
|
+
},
|
|
238
|
+
"minItems": 1,
|
|
239
|
+
"uniqueItems": true
|
|
240
|
+
},
|
|
241
|
+
"checks": {
|
|
242
|
+
"type": "array",
|
|
243
|
+
"items": {
|
|
244
|
+
"type": "string",
|
|
245
|
+
"minLength": 1,
|
|
246
|
+
"maxLength": 256
|
|
247
|
+
}
|
|
248
|
+
},
|
|
249
|
+
"antiPatterns": {
|
|
250
|
+
"type": "array",
|
|
251
|
+
"items": {
|
|
252
|
+
"type": "string",
|
|
253
|
+
"minLength": 1,
|
|
254
|
+
"maxLength": 256
|
|
255
|
+
}
|
|
256
|
+
},
|
|
257
|
+
"examples": {
|
|
258
|
+
"type": "array",
|
|
259
|
+
"items": {
|
|
260
|
+
"type": "string",
|
|
261
|
+
"minLength": 1,
|
|
262
|
+
"maxLength": 256
|
|
263
|
+
}
|
|
264
|
+
},
|
|
265
|
+
"exampleRefs": {
|
|
266
|
+
"type": "array",
|
|
267
|
+
"items": {
|
|
268
|
+
"$ref": "#/$defs/exampleRef"
|
|
269
|
+
}
|
|
270
|
+
},
|
|
271
|
+
"sourceRefs": {
|
|
272
|
+
"type": "array",
|
|
273
|
+
"items": {
|
|
274
|
+
"$ref": "#/$defs/sourceRef"
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
},
|
|
279
|
+
"plannedRule": {
|
|
280
|
+
"type": "object",
|
|
281
|
+
"additionalProperties": false,
|
|
282
|
+
"required": [
|
|
283
|
+
"id",
|
|
284
|
+
"status",
|
|
285
|
+
"scope",
|
|
286
|
+
"rule",
|
|
287
|
+
"why",
|
|
288
|
+
"enforcement"
|
|
289
|
+
],
|
|
290
|
+
"properties": {
|
|
291
|
+
"id": {
|
|
292
|
+
"$ref": "#/$defs/scopeToken"
|
|
293
|
+
},
|
|
294
|
+
"status": {
|
|
295
|
+
"$ref": "#/$defs/ruleStatus"
|
|
296
|
+
},
|
|
297
|
+
"scope": {
|
|
298
|
+
"type": "array",
|
|
299
|
+
"items": {
|
|
300
|
+
"$ref": "#/$defs/scopeToken"
|
|
301
|
+
},
|
|
302
|
+
"minItems": 1,
|
|
303
|
+
"uniqueItems": true
|
|
304
|
+
},
|
|
305
|
+
"rule": {
|
|
306
|
+
"type": "string",
|
|
307
|
+
"minLength": 1,
|
|
308
|
+
"maxLength": 512
|
|
309
|
+
},
|
|
310
|
+
"why": {
|
|
311
|
+
"type": "string",
|
|
312
|
+
"minLength": 1,
|
|
313
|
+
"maxLength": 256
|
|
314
|
+
},
|
|
315
|
+
"enforcement": {
|
|
316
|
+
"type": "array",
|
|
317
|
+
"items": {
|
|
318
|
+
"$ref": "#/$defs/enforcementMode"
|
|
319
|
+
},
|
|
320
|
+
"minItems": 1,
|
|
321
|
+
"uniqueItems": true
|
|
322
|
+
},
|
|
323
|
+
"sourceRefs": {
|
|
324
|
+
"type": "array",
|
|
325
|
+
"items": {
|
|
326
|
+
"$ref": "#/$defs/sourceRef"
|
|
327
|
+
}
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
},
|
|
331
|
+
"exampleRef": {
|
|
332
|
+
"type": "object",
|
|
333
|
+
"additionalProperties": false,
|
|
334
|
+
"required": ["path"],
|
|
335
|
+
"properties": {
|
|
336
|
+
"path": {
|
|
337
|
+
"type": "string",
|
|
338
|
+
"minLength": 1,
|
|
339
|
+
"maxLength": 256
|
|
340
|
+
},
|
|
341
|
+
"note": {
|
|
342
|
+
"type": "string",
|
|
343
|
+
"minLength": 1,
|
|
344
|
+
"maxLength": 256
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
},
|
|
348
|
+
"sourceRef": {
|
|
349
|
+
"type": "object",
|
|
350
|
+
"additionalProperties": false,
|
|
351
|
+
"required": ["kind", "path"],
|
|
352
|
+
"properties": {
|
|
353
|
+
"kind": {
|
|
354
|
+
"type": "string",
|
|
355
|
+
"enum": ["schema", "runtime", "validator", "documentation", "example"]
|
|
356
|
+
},
|
|
357
|
+
"path": {
|
|
358
|
+
"type": "string",
|
|
359
|
+
"minLength": 1,
|
|
360
|
+
"maxLength": 256
|
|
361
|
+
},
|
|
362
|
+
"note": {
|
|
363
|
+
"type": "string",
|
|
364
|
+
"minLength": 1,
|
|
365
|
+
"maxLength": 256
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
}
|