sysprom 1.19.0 → 1.21.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 (75) hide show
  1. package/README.md +3 -0
  2. package/dist/schema.json +4 -43
  3. package/dist/src/cli/commands/add.js +6 -2
  4. package/dist/src/cli/commands/query.js +5 -3
  5. package/dist/src/cli/commands/speckit.js +2 -2
  6. package/dist/src/cli/commands/update.js +6 -4
  7. package/dist/src/endpoint-types.d.ts +4 -0
  8. package/dist/src/endpoint-types.js +22 -116
  9. package/dist/src/json-to-md.js +2 -16
  10. package/dist/src/lifecycle-state.d.ts +9 -0
  11. package/dist/src/lifecycle-state.js +22 -0
  12. package/dist/src/mcp/server.js +3 -6
  13. package/dist/src/md-to-json.js +1 -19
  14. package/dist/src/operations/add-node.d.ts +21 -132
  15. package/dist/src/operations/add-plan-task.d.ts +14 -88
  16. package/dist/src/operations/add-relationship.d.ts +16 -102
  17. package/dist/src/operations/check.d.ts +7 -44
  18. package/dist/src/operations/graph-decision.d.ts +7 -44
  19. package/dist/src/operations/graph-decision.js +0 -1
  20. package/dist/src/operations/graph-dependency.d.ts +7 -44
  21. package/dist/src/operations/graph-dependency.js +3 -23
  22. package/dist/src/operations/graph-refinement.d.ts +7 -44
  23. package/dist/src/operations/graph-shared.js +1 -3
  24. package/dist/src/operations/graph.d.ts +7 -44
  25. package/dist/src/operations/infer-completeness.d.ts +10 -53
  26. package/dist/src/operations/infer-derived.d.ts +7 -44
  27. package/dist/src/operations/infer-derived.js +28 -4
  28. package/dist/src/operations/infer-impact.d.ts +49 -308
  29. package/dist/src/operations/infer-impact.js +22 -3
  30. package/dist/src/operations/infer-lifecycle.d.ts +8 -105
  31. package/dist/src/operations/infer-lifecycle.js +4 -10
  32. package/dist/src/operations/init-document.d.ts +7 -44
  33. package/dist/src/operations/json-to-markdown.d.ts +7 -44
  34. package/dist/src/operations/mark-task-done.d.ts +14 -88
  35. package/dist/src/operations/mark-task-undone.d.ts +14 -88
  36. package/dist/src/operations/markdown-to-json.d.ts +7 -44
  37. package/dist/src/operations/next-id.d.ts +8 -47
  38. package/dist/src/operations/node-history.d.ts +7 -44
  39. package/dist/src/operations/plan-add-task.d.ts +14 -88
  40. package/dist/src/operations/plan-gate.d.ts +7 -44
  41. package/dist/src/operations/plan-init.d.ts +7 -44
  42. package/dist/src/operations/plan-progress.d.ts +7 -44
  43. package/dist/src/operations/plan-status.d.ts +7 -44
  44. package/dist/src/operations/query-node.d.ts +29 -188
  45. package/dist/src/operations/query-nodes.d.ts +15 -89
  46. package/dist/src/operations/query-nodes.js +6 -4
  47. package/dist/src/operations/query-relationships.d.ts +9 -58
  48. package/dist/src/operations/remove-node.d.ts +21 -132
  49. package/dist/src/operations/remove-node.js +11 -1
  50. package/dist/src/operations/remove-relationship.d.ts +15 -101
  51. package/dist/src/operations/rename.d.ts +14 -88
  52. package/dist/src/operations/search.d.ts +14 -88
  53. package/dist/src/operations/speckit-diff.d.ts +7 -44
  54. package/dist/src/operations/speckit-export.d.ts +7 -44
  55. package/dist/src/operations/speckit-import.d.ts +7 -44
  56. package/dist/src/operations/speckit-sync.d.ts +22 -133
  57. package/dist/src/operations/speckit-sync.js +3 -3
  58. package/dist/src/operations/state-at.d.ts +7 -44
  59. package/dist/src/operations/stats.d.ts +7 -44
  60. package/dist/src/operations/sync.d.ts +21 -132
  61. package/dist/src/operations/task-list.d.ts +7 -44
  62. package/dist/src/operations/timeline.d.ts +7 -44
  63. package/dist/src/operations/trace-from-node.d.ts +21 -132
  64. package/dist/src/operations/update-metadata.d.ts +14 -88
  65. package/dist/src/operations/update-node.d.ts +20 -152
  66. package/dist/src/operations/update-plan-task.d.ts +14 -88
  67. package/dist/src/operations/validate.d.ts +7 -44
  68. package/dist/src/operations/validate.js +8 -6
  69. package/dist/src/schema.d.ts +22 -159
  70. package/dist/src/schema.js +4 -26
  71. package/dist/src/speckit/generate.js +10 -7
  72. package/dist/src/speckit/parse.js +6 -3
  73. package/dist/src/speckit/plan.js +1 -1
  74. package/package.json +12 -1
  75. package/schema.json +4 -43
@@ -39,39 +39,18 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
39
39
  gate: "gate";
40
40
  mode: "mode";
41
41
  artefact: "artefact";
42
- artefact_flow: "artefact_flow";
43
42
  decision: "decision";
44
43
  change: "change";
45
44
  view: "view";
46
45
  milestone: "milestone";
47
- version: "version";
48
46
  }> & {
49
- is(value: unknown): value is "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "artefact_flow" | "decision" | "change" | "view" | "milestone" | "version";
47
+ is(value: unknown): value is "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "decision" | "change" | "view" | "milestone";
50
48
  };
51
49
  name: z.ZodString;
52
50
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
53
51
  is(value: unknown): value is string | string[];
54
52
  }>;
55
- status: z.ZodOptional<z.ZodEnum<{
56
- deprecated: "deprecated";
57
- proposed: "proposed";
58
- accepted: "accepted";
59
- active: "active";
60
- implemented: "implemented";
61
- adopted: "adopted";
62
- defined: "defined";
63
- introduced: "introduced";
64
- in_progress: "in_progress";
65
- complete: "complete";
66
- consolidated: "consolidated";
67
- experimental: "experimental";
68
- retired: "retired";
69
- superseded: "superseded";
70
- abandoned: "abandoned";
71
- deferred: "deferred";
72
- }> & {
73
- is(value: unknown): value is "deprecated" | "proposed" | "accepted" | "active" | "implemented" | "adopted" | "defined" | "introduced" | "in_progress" | "complete" | "consolidated" | "experimental" | "retired" | "superseded" | "abandoned" | "deferred";
74
- }>;
53
+ status: z.ZodOptional<z.ZodNever>;
75
54
  lifecycle: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodString]>>>;
76
55
  context: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
77
56
  is(value: unknown): value is string | string[];
@@ -126,8 +105,6 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
126
105
  }>>;
127
106
  propagation: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
128
107
  includes: z.ZodOptional<z.ZodArray<z.ZodString>>;
129
- input: z.ZodOptional<z.ZodString>;
130
- output: z.ZodOptional<z.ZodString>;
131
108
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
132
109
  role: z.ZodEnum<{
133
110
  output: "output";
@@ -171,26 +148,14 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
171
148
  affects: "affects";
172
149
  supersedes: "supersedes";
173
150
  must_preserve: "must_preserve";
174
- performs: "performs";
175
151
  part_of: "part_of";
176
152
  precedes: "precedes";
177
153
  must_follow: "must_follow";
178
- blocks: "blocks";
179
- routes_to: "routes_to";
180
154
  governed_by: "governed_by";
181
155
  modifies: "modifies";
182
- triggered_by: "triggered_by";
183
- applies_to: "applies_to";
184
156
  produces: "produces";
185
- consumes: "consumes";
186
- transforms_into: "transforms_into";
187
- selects: "selects";
188
- requires: "requires";
189
- disables: "disables";
190
- influence: "influence";
191
- justifies: "justifies";
192
157
  }> & {
193
- is(value: unknown): value is "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
158
+ is(value: unknown): value is "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
194
159
  };
195
160
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
196
161
  is(value: unknown): value is string | string[];
@@ -209,7 +174,7 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
209
174
  [x: string]: unknown;
210
175
  from: string;
211
176
  to: string;
212
- type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
177
+ type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
213
178
  description?: string | string[] | undefined;
214
179
  polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
215
180
  strength?: number | undefined;
@@ -249,10 +214,10 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
249
214
  nodes: {
250
215
  [x: string]: unknown;
251
216
  id: string;
252
- type: "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "artefact_flow" | "decision" | "change" | "view" | "milestone" | "version";
217
+ type: "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "decision" | "change" | "view" | "milestone";
253
218
  name: string;
254
219
  description?: string | string[] | undefined;
255
- status?: "deprecated" | "proposed" | "accepted" | "active" | "implemented" | "adopted" | "defined" | "introduced" | "in_progress" | "complete" | "consolidated" | "experimental" | "retired" | "superseded" | "abandoned" | "deferred" | undefined;
220
+ status?: undefined;
256
221
  lifecycle?: Record<string, string | boolean> | undefined;
257
222
  context?: string | string[] | undefined;
258
223
  options?: {
@@ -276,8 +241,6 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
276
241
  }[] | undefined;
277
242
  propagation?: Record<string, boolean> | undefined;
278
243
  includes?: string[] | undefined;
279
- input?: string | undefined;
280
- output?: string | undefined;
281
244
  external_references?: {
282
245
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
283
246
  identifier: string;
@@ -300,7 +263,7 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
300
263
  [x: string]: unknown;
301
264
  from: string;
302
265
  to: string;
303
- type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
266
+ type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
304
267
  description?: string | string[] | undefined;
305
268
  polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
306
269
  strength?: number | undefined;
@@ -352,39 +315,18 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
352
315
  gate: "gate";
353
316
  mode: "mode";
354
317
  artefact: "artefact";
355
- artefact_flow: "artefact_flow";
356
318
  decision: "decision";
357
319
  change: "change";
358
320
  view: "view";
359
321
  milestone: "milestone";
360
- version: "version";
361
322
  }> & {
362
- is(value: unknown): value is "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "artefact_flow" | "decision" | "change" | "view" | "milestone" | "version";
323
+ is(value: unknown): value is "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "decision" | "change" | "view" | "milestone";
363
324
  };
364
325
  name: z.ZodString;
365
326
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
366
327
  is(value: unknown): value is string | string[];
367
328
  }>;
368
- status: z.ZodOptional<z.ZodEnum<{
369
- deprecated: "deprecated";
370
- proposed: "proposed";
371
- accepted: "accepted";
372
- active: "active";
373
- implemented: "implemented";
374
- adopted: "adopted";
375
- defined: "defined";
376
- introduced: "introduced";
377
- in_progress: "in_progress";
378
- complete: "complete";
379
- consolidated: "consolidated";
380
- experimental: "experimental";
381
- retired: "retired";
382
- superseded: "superseded";
383
- abandoned: "abandoned";
384
- deferred: "deferred";
385
- }> & {
386
- is(value: unknown): value is "deprecated" | "proposed" | "accepted" | "active" | "implemented" | "adopted" | "defined" | "introduced" | "in_progress" | "complete" | "consolidated" | "experimental" | "retired" | "superseded" | "abandoned" | "deferred";
387
- }>;
329
+ status: z.ZodOptional<z.ZodNever>;
388
330
  lifecycle: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodString]>>>;
389
331
  context: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
390
332
  is(value: unknown): value is string | string[];
@@ -439,8 +381,6 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
439
381
  }>>;
440
382
  propagation: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
441
383
  includes: z.ZodOptional<z.ZodArray<z.ZodString>>;
442
- input: z.ZodOptional<z.ZodString>;
443
- output: z.ZodOptional<z.ZodString>;
444
384
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
445
385
  role: z.ZodEnum<{
446
386
  output: "output";
@@ -484,26 +424,14 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
484
424
  affects: "affects";
485
425
  supersedes: "supersedes";
486
426
  must_preserve: "must_preserve";
487
- performs: "performs";
488
427
  part_of: "part_of";
489
428
  precedes: "precedes";
490
429
  must_follow: "must_follow";
491
- blocks: "blocks";
492
- routes_to: "routes_to";
493
430
  governed_by: "governed_by";
494
431
  modifies: "modifies";
495
- triggered_by: "triggered_by";
496
- applies_to: "applies_to";
497
432
  produces: "produces";
498
- consumes: "consumes";
499
- transforms_into: "transforms_into";
500
- selects: "selects";
501
- requires: "requires";
502
- disables: "disables";
503
- influence: "influence";
504
- justifies: "justifies";
505
433
  }> & {
506
- is(value: unknown): value is "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
434
+ is(value: unknown): value is "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
507
435
  };
508
436
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
509
437
  is(value: unknown): value is string | string[];
@@ -522,7 +450,7 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
522
450
  [x: string]: unknown;
523
451
  from: string;
524
452
  to: string;
525
- type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
453
+ type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
526
454
  description?: string | string[] | undefined;
527
455
  polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
528
456
  strength?: number | undefined;
@@ -562,10 +490,10 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
562
490
  nodes: {
563
491
  [x: string]: unknown;
564
492
  id: string;
565
- type: "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "artefact_flow" | "decision" | "change" | "view" | "milestone" | "version";
493
+ type: "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "decision" | "change" | "view" | "milestone";
566
494
  name: string;
567
495
  description?: string | string[] | undefined;
568
- status?: "deprecated" | "proposed" | "accepted" | "active" | "implemented" | "adopted" | "defined" | "introduced" | "in_progress" | "complete" | "consolidated" | "experimental" | "retired" | "superseded" | "abandoned" | "deferred" | undefined;
496
+ status?: undefined;
569
497
  lifecycle?: Record<string, string | boolean> | undefined;
570
498
  context?: string | string[] | undefined;
571
499
  options?: {
@@ -589,8 +517,6 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
589
517
  }[] | undefined;
590
518
  propagation?: Record<string, boolean> | undefined;
591
519
  includes?: string[] | undefined;
592
- input?: string | undefined;
593
- output?: string | undefined;
594
520
  external_references?: {
595
521
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
596
522
  identifier: string;
@@ -613,7 +539,7 @@ export declare const updatePlanTaskOp: import("./define-operation.js").DefinedOp
613
539
  [x: string]: unknown;
614
540
  from: string;
615
541
  to: string;
616
- type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
542
+ type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
617
543
  description?: string | string[] | undefined;
618
544
  polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
619
545
  strength?: number | undefined;
@@ -52,39 +52,18 @@ export declare const validateOp: import("./define-operation.js").DefinedOperatio
52
52
  gate: "gate";
53
53
  mode: "mode";
54
54
  artefact: "artefact";
55
- artefact_flow: "artefact_flow";
56
55
  decision: "decision";
57
56
  change: "change";
58
57
  view: "view";
59
58
  milestone: "milestone";
60
- version: "version";
61
59
  }> & {
62
- is(value: unknown): value is "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "artefact_flow" | "decision" | "change" | "view" | "milestone" | "version";
60
+ is(value: unknown): value is "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "decision" | "change" | "view" | "milestone";
63
61
  };
64
62
  name: z.ZodString;
65
63
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
66
64
  is(value: unknown): value is string | string[];
67
65
  }>;
68
- status: z.ZodOptional<z.ZodEnum<{
69
- deprecated: "deprecated";
70
- proposed: "proposed";
71
- accepted: "accepted";
72
- active: "active";
73
- implemented: "implemented";
74
- adopted: "adopted";
75
- defined: "defined";
76
- introduced: "introduced";
77
- in_progress: "in_progress";
78
- complete: "complete";
79
- consolidated: "consolidated";
80
- experimental: "experimental";
81
- retired: "retired";
82
- superseded: "superseded";
83
- abandoned: "abandoned";
84
- deferred: "deferred";
85
- }> & {
86
- is(value: unknown): value is "deprecated" | "proposed" | "accepted" | "active" | "implemented" | "adopted" | "defined" | "introduced" | "in_progress" | "complete" | "consolidated" | "experimental" | "retired" | "superseded" | "abandoned" | "deferred";
87
- }>;
66
+ status: z.ZodOptional<z.ZodNever>;
88
67
  lifecycle: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodString]>>>;
89
68
  context: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
90
69
  is(value: unknown): value is string | string[];
@@ -139,8 +118,6 @@ export declare const validateOp: import("./define-operation.js").DefinedOperatio
139
118
  }>>;
140
119
  propagation: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
141
120
  includes: z.ZodOptional<z.ZodArray<z.ZodString>>;
142
- input: z.ZodOptional<z.ZodString>;
143
- output: z.ZodOptional<z.ZodString>;
144
121
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
145
122
  role: z.ZodEnum<{
146
123
  output: "output";
@@ -184,26 +161,14 @@ export declare const validateOp: import("./define-operation.js").DefinedOperatio
184
161
  affects: "affects";
185
162
  supersedes: "supersedes";
186
163
  must_preserve: "must_preserve";
187
- performs: "performs";
188
164
  part_of: "part_of";
189
165
  precedes: "precedes";
190
166
  must_follow: "must_follow";
191
- blocks: "blocks";
192
- routes_to: "routes_to";
193
167
  governed_by: "governed_by";
194
168
  modifies: "modifies";
195
- triggered_by: "triggered_by";
196
- applies_to: "applies_to";
197
169
  produces: "produces";
198
- consumes: "consumes";
199
- transforms_into: "transforms_into";
200
- selects: "selects";
201
- requires: "requires";
202
- disables: "disables";
203
- influence: "influence";
204
- justifies: "justifies";
205
170
  }> & {
206
- is(value: unknown): value is "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
171
+ is(value: unknown): value is "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
207
172
  };
208
173
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
209
174
  is(value: unknown): value is string | string[];
@@ -222,7 +187,7 @@ export declare const validateOp: import("./define-operation.js").DefinedOperatio
222
187
  [x: string]: unknown;
223
188
  from: string;
224
189
  to: string;
225
- type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
190
+ type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
226
191
  description?: string | string[] | undefined;
227
192
  polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
228
193
  strength?: number | undefined;
@@ -262,10 +227,10 @@ export declare const validateOp: import("./define-operation.js").DefinedOperatio
262
227
  nodes: {
263
228
  [x: string]: unknown;
264
229
  id: string;
265
- type: "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "artefact_flow" | "decision" | "change" | "view" | "milestone" | "version";
230
+ type: "intent" | "concept" | "capability" | "element" | "realisation" | "invariant" | "principle" | "policy" | "protocol" | "stage" | "role" | "gate" | "mode" | "artefact" | "decision" | "change" | "view" | "milestone";
266
231
  name: string;
267
232
  description?: string | string[] | undefined;
268
- status?: "deprecated" | "proposed" | "accepted" | "active" | "implemented" | "adopted" | "defined" | "introduced" | "in_progress" | "complete" | "consolidated" | "experimental" | "retired" | "superseded" | "abandoned" | "deferred" | undefined;
233
+ status?: undefined;
269
234
  lifecycle?: Record<string, string | boolean> | undefined;
270
235
  context?: string | string[] | undefined;
271
236
  options?: {
@@ -289,8 +254,6 @@ export declare const validateOp: import("./define-operation.js").DefinedOperatio
289
254
  }[] | undefined;
290
255
  propagation?: Record<string, boolean> | undefined;
291
256
  includes?: string[] | undefined;
292
- input?: string | undefined;
293
- output?: string | undefined;
294
257
  external_references?: {
295
258
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
296
259
  identifier: string;
@@ -313,7 +276,7 @@ export declare const validateOp: import("./define-operation.js").DefinedOperatio
313
276
  [x: string]: unknown;
314
277
  from: string;
315
278
  to: string;
316
- type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "performs" | "part_of" | "precedes" | "must_follow" | "blocks" | "routes_to" | "governed_by" | "modifies" | "triggered_by" | "applies_to" | "produces" | "consumes" | "transforms_into" | "selects" | "requires" | "disables" | "influence" | "justifies";
279
+ type: "refines" | "realises" | "implements" | "depends_on" | "constrained_by" | "affects" | "supersedes" | "must_preserve" | "part_of" | "precedes" | "must_follow" | "governed_by" | "modifies" | "produces";
317
280
  description?: string | string[] | undefined;
318
281
  polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
319
282
  strength?: number | undefined;
@@ -1,7 +1,8 @@
1
1
  import * as z from "zod";
2
2
  import { defineOperation } from "./define-operation.js";
3
3
  import { SysProMDocument } from "../schema.js";
4
- import { isValidEndpointPair, RELATIONSHIP_ENDPOINT_TYPES, } from "../endpoint-types.js";
4
+ import { isValidEndpointPair, isViewReadModelDependsOnRelationship, RELATIONSHIP_ENDPOINT_TYPES, } from "../endpoint-types.js";
5
+ import { hasLifecycleState } from "../lifecycle-state.js";
5
6
  /** Zod schema for the result of validating a SysProM document. */
6
7
  export const ValidationResult = z.object({
7
8
  valid: z.boolean(),
@@ -75,21 +76,22 @@ export const validateOp = defineOperation({
75
76
  const OPERATIONAL_REL_TYPES = new Set([
76
77
  "depends_on",
77
78
  "constrained_by",
78
- "requires",
79
79
  "affects",
80
80
  "must_preserve",
81
- "performs",
82
81
  "must_follow",
83
82
  "part_of",
84
83
  "governed_by",
85
84
  "modifies",
86
- "applies_to",
87
85
  "produces",
88
- "consumes",
89
86
  ]);
90
87
  for (const r of input.doc.relationships ?? []) {
88
+ const fromNode = nodeMap.get(r.from);
91
89
  const toNode = nodeMap.get(r.to);
92
- if (toNode?.status === "retired" && OPERATIONAL_REL_TYPES.has(r.type)) {
90
+ if (fromNode &&
91
+ toNode &&
92
+ hasLifecycleState(toNode, "retired") &&
93
+ OPERATIONAL_REL_TYPES.has(r.type) &&
94
+ !isViewReadModelDependsOnRelationship(r.type, fromNode.type, toNode.type)) {
93
95
  issues.push(`Operational relationship ${r.type} targets retired node ${r.to}`);
94
96
  }
95
97
  }