sysprom 1.15.0 → 1.16.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.
Files changed (55) hide show
  1. package/dist/schema.json +18 -1
  2. package/dist/src/cli/commands/infer.js +31 -2
  3. package/dist/src/endpoint-types.js +23 -0
  4. package/dist/src/index.d.ts +2 -2
  5. package/dist/src/index.js +2 -2
  6. package/dist/src/mcp/server.js +42 -4
  7. package/dist/src/operations/add-node.d.ts +51 -9
  8. package/dist/src/operations/add-plan-task.d.ts +34 -6
  9. package/dist/src/operations/add-relationship.d.ts +48 -8
  10. package/dist/src/operations/check.d.ts +17 -3
  11. package/dist/src/operations/graph.d.ts +17 -3
  12. package/dist/src/operations/index.d.ts +1 -1
  13. package/dist/src/operations/index.js +1 -1
  14. package/dist/src/operations/infer-completeness.d.ts +17 -3
  15. package/dist/src/operations/infer-derived.d.ts +17 -3
  16. package/dist/src/operations/infer-impact.d.ts +1066 -13
  17. package/dist/src/operations/infer-impact.js +157 -39
  18. package/dist/src/operations/infer-lifecycle.d.ts +17 -3
  19. package/dist/src/operations/init-document.d.ts +17 -3
  20. package/dist/src/operations/json-to-markdown.d.ts +17 -3
  21. package/dist/src/operations/mark-task-done.d.ts +34 -6
  22. package/dist/src/operations/mark-task-undone.d.ts +34 -6
  23. package/dist/src/operations/markdown-to-json.d.ts +17 -3
  24. package/dist/src/operations/next-id.d.ts +17 -3
  25. package/dist/src/operations/node-history.d.ts +17 -3
  26. package/dist/src/operations/plan-add-task.d.ts +34 -6
  27. package/dist/src/operations/plan-gate.d.ts +17 -3
  28. package/dist/src/operations/plan-init.d.ts +17 -3
  29. package/dist/src/operations/plan-progress.d.ts +17 -3
  30. package/dist/src/operations/plan-status.d.ts +17 -3
  31. package/dist/src/operations/query-node.d.ts +107 -17
  32. package/dist/src/operations/query-nodes.d.ts +34 -6
  33. package/dist/src/operations/query-relationships.d.ts +31 -5
  34. package/dist/src/operations/remove-node.d.ts +51 -9
  35. package/dist/src/operations/remove-relationship.d.ts +36 -7
  36. package/dist/src/operations/rename.d.ts +34 -6
  37. package/dist/src/operations/search.d.ts +34 -6
  38. package/dist/src/operations/speckit-diff.d.ts +17 -3
  39. package/dist/src/operations/speckit-export.d.ts +17 -3
  40. package/dist/src/operations/speckit-import.d.ts +17 -3
  41. package/dist/src/operations/speckit-sync.d.ts +51 -9
  42. package/dist/src/operations/state-at.d.ts +17 -3
  43. package/dist/src/operations/stats.d.ts +17 -3
  44. package/dist/src/operations/sync.d.ts +51 -9
  45. package/dist/src/operations/task-list.d.ts +17 -3
  46. package/dist/src/operations/timeline.d.ts +17 -3
  47. package/dist/src/operations/trace-from-node.d.ts +51 -9
  48. package/dist/src/operations/update-metadata.d.ts +34 -6
  49. package/dist/src/operations/update-node.d.ts +48 -8
  50. package/dist/src/operations/update-plan-task.d.ts +34 -6
  51. package/dist/src/operations/validate.d.ts +17 -3
  52. package/dist/src/schema.d.ts +70 -10
  53. package/dist/src/schema.js +21 -0
  54. package/package.json +1 -1
  55. package/schema.json +18 -1
@@ -1,6 +1,6 @@
1
1
  import * as z from "zod";
2
2
  import { defineOperation } from "./define-operation.js";
3
- import { Node, SysProMDocument } from "../schema.js";
3
+ import { Node, SysProMDocument, ImpactPolarity, } from "../schema.js";
4
4
  /**
5
5
  * Impact node in the impact trace.
6
6
  */
@@ -9,6 +9,7 @@ const ImpactNode = z.object({
9
9
  node: Node.optional(),
10
10
  impactType: z.enum(["direct", "transitive", "potential"]),
11
11
  distance: z.number().int().nonnegative(),
12
+ polarity: ImpactPolarity.optional(),
12
13
  });
13
14
  /**
14
15
  * Output schema for inferImpactOp.
@@ -34,7 +35,18 @@ const IMPACT_RELATIONSHIPS = new Set([
34
35
  "requires",
35
36
  "produces",
36
37
  "consumes",
38
+ "influence",
37
39
  ]);
40
+ /**
41
+ * Type guard for ImpactPolarity validation.
42
+ * @param val - The value to validate
43
+ * @returns true if the value is a valid ImpactPolarity
44
+ * @example
45
+ * if (isValidPolarity(rel.polarity)) { ... }
46
+ */
47
+ function isValidPolarity(val) {
48
+ return ImpactPolarity.safeParse(val).success;
49
+ }
38
50
  /**
39
51
  * Relationship types that indicate potential impact (weaker signal).
40
52
  */
@@ -48,7 +60,8 @@ const POTENTIAL_IMPACT_RELATIONSHIPS = new Set([
48
60
  *
49
61
  * Traces impact propagation through affect, dependency, and modification
50
62
  * relationships, categorising nodes as directly impacted, transitively
51
- * impacted, or potentially impacted.
63
+ * impacted, or potentially impacted. Supports bidirectional traversal
64
+ * (CHG40) with optional polarity annotations.
52
65
  */
53
66
  export const inferImpactOp = defineOperation({
54
67
  name: "infer-impact",
@@ -56,66 +69,92 @@ export const inferImpactOp = defineOperation({
56
69
  input: z.object({
57
70
  doc: SysProMDocument,
58
71
  startId: z.string(),
72
+ direction: z.enum(["outgoing", "incoming", "bidirectional"]).optional(),
73
+ maxDepth: z.number().int().positive().optional(),
74
+ relationshipFilter: z.array(z.string()).optional(),
59
75
  }),
60
76
  output: ImpactOutput,
61
77
  fn: (input) => {
62
78
  const nodeMap = new Map(input.doc.nodes.map((n) => [n.id, n]));
63
79
  const visited = new Set();
64
80
  const impactedNodes = [];
65
- // Mark source as visited to exclude it from results
81
+ const relationships = input.doc.relationships ?? [];
82
+ const direction = input.direction ?? "outgoing";
66
83
  visited.add(input.startId);
67
- // BFS traversal with impact type tracking
68
- const queue = [];
69
- // Start with direct impacts
70
- const directImpacts = (input.doc.relationships ?? [])
71
- .filter((r) => r.from === input.startId && IMPACT_RELATIONSHIPS.has(r.type))
72
- .map((r) => r.to);
73
- const potentialImpacts = (input.doc.relationships ?? [])
74
- .filter((r) => r.from === input.startId &&
75
- POTENTIAL_IMPACT_RELATIONSHIPS.has(r.type))
76
- .map((r) => r.to);
77
- // Add direct impacts to queue
78
- for (const id of directImpacts) {
79
- queue.push({ id, distance: 1, impactType: "direct" });
80
- }
81
- // Add potential impacts to queue
82
- for (const id of potentialImpacts) {
83
- if (!directImpacts.includes(id)) {
84
- queue.push({ id, distance: 1, impactType: "potential" });
84
+ // Helper: check if relationship type is impactful
85
+ const isImpactRel = (type) => input.relationshipFilter
86
+ ? input.relationshipFilter.includes(type)
87
+ : IMPACT_RELATIONSHIPS.has(type);
88
+ const isPotentialRel = (type) => !input.relationshipFilter && POTENTIAL_IMPACT_RELATIONSHIPS.has(type);
89
+ // Helper: get edges based on direction
90
+ const getEdges = (nodeId) => {
91
+ const edges = [];
92
+ if (direction !== "incoming") {
93
+ // Outgoing edges
94
+ relationships
95
+ .filter((r) => r.from === nodeId)
96
+ .forEach((r) => {
97
+ if (isImpactRel(r.type) || isPotentialRel(r.type)) {
98
+ edges.push({ to: r.to, type: r.type, polarity: r.polarity });
99
+ }
100
+ });
85
101
  }
86
- }
102
+ if (direction !== "outgoing") {
103
+ // Incoming edges
104
+ relationships
105
+ .filter((r) => r.to === nodeId)
106
+ .forEach((r) => {
107
+ if (isImpactRel(r.type) || isPotentialRel(r.type)) {
108
+ edges.push({ to: r.from, type: r.type, polarity: r.polarity });
109
+ }
110
+ });
111
+ }
112
+ return edges;
113
+ };
87
114
  // BFS traversal
115
+ const queue = [];
116
+ // Start: add direct impacts from startId
117
+ const directEdges = getEdges(input.startId);
118
+ for (const edge of directEdges) {
119
+ const impactType = isPotentialRel(edge.type) ? "potential" : "direct";
120
+ queue.push({
121
+ id: edge.to,
122
+ distance: 1,
123
+ impactType,
124
+ polarity: edge.polarity,
125
+ });
126
+ }
88
127
  while (queue.length > 0) {
89
128
  const current = queue.shift();
90
129
  if (!current)
91
130
  break;
92
131
  if (visited.has(current.id))
93
132
  continue;
133
+ if (input.maxDepth && current.distance > input.maxDepth)
134
+ continue;
94
135
  visited.add(current.id);
95
136
  const node = nodeMap.get(current.id);
96
- impactedNodes.push({
137
+ const impactNode = {
97
138
  id: current.id,
98
139
  node,
99
140
  impactType: current.impactType,
100
141
  distance: current.distance,
101
- });
102
- // Find transitive impacts
103
- const transitiveImpacts = (input.doc.relationships ?? [])
104
- .filter((r) => r.from === current.id &&
105
- (IMPACT_RELATIONSHIPS.has(r.type) ||
106
- POTENTIAL_IMPACT_RELATIONSHIPS.has(r.type)))
107
- .map((r) => ({
108
- id: r.to,
109
- impactType: current.distance >= 1
110
- ? "transitive"
111
- : current.impactType,
112
- }));
113
- for (const impact of transitiveImpacts) {
114
- if (!visited.has(impact.id)) {
142
+ };
143
+ // Assign polarity if it's valid
144
+ if (current.polarity && isValidPolarity(current.polarity)) {
145
+ impactNode.polarity = current.polarity;
146
+ }
147
+ impactedNodes.push(impactNode);
148
+ // Find next-hop impacts
149
+ const nextEdges = getEdges(current.id);
150
+ for (const edge of nextEdges) {
151
+ if (!visited.has(edge.to)) {
152
+ const nextImpactType = current.distance >= 1 ? "transitive" : current.impactType;
115
153
  queue.push({
116
- id: impact.id,
154
+ id: edge.to,
117
155
  distance: current.distance + 1,
118
- impactType: impact.impactType,
156
+ impactType: nextImpactType,
157
+ polarity: edge.polarity,
119
158
  });
120
159
  }
121
160
  }
@@ -142,3 +181,82 @@ export const inferImpactOp = defineOperation({
142
181
  };
143
182
  },
144
183
  });
184
+ /**
185
+ * Output schema for impactSummaryOp.
186
+ */
187
+ const ImpactSummaryOutput = z.object({
188
+ hotspots: z.array(z.object({
189
+ nodeId: z.string(),
190
+ node: Node.optional(),
191
+ incomingImpactCount: z.number(),
192
+ outgoingImpactCount: z.number(),
193
+ totalImpact: z.number(),
194
+ })),
195
+ summary: z.object({
196
+ totalNodes: z.number(),
197
+ totalImpactedNodes: z.number(),
198
+ averageDegree: z.number(),
199
+ }),
200
+ });
201
+ /**
202
+ * Analyse the entire document for impact hotspots.
203
+ *
204
+ * Identifies nodes that are heavily impacted or that impact many other nodes.
205
+ * Useful for identifying critical elements and dependencies.
206
+ */
207
+ export const impactSummaryOp = defineOperation({
208
+ name: "infer-impact-summary",
209
+ description: "Analyse the entire document for impact hotspots — nodes with high incoming or outgoing impact",
210
+ input: z.object({
211
+ doc: SysProMDocument,
212
+ }),
213
+ output: ImpactSummaryOutput,
214
+ fn: (input) => {
215
+ const nodeMap = new Map(input.doc.nodes.map((n) => [n.id, n]));
216
+ const relationships = input.doc.relationships ?? [];
217
+ const impactStats = new Map();
218
+ // Count incoming and outgoing impact relationships
219
+ for (const node of input.doc.nodes) {
220
+ impactStats.set(node.id, { incoming: 0, outgoing: 0 });
221
+ }
222
+ for (const rel of relationships) {
223
+ if (IMPACT_RELATIONSHIPS.has(rel.type)) {
224
+ const fromStats = impactStats.get(rel.from);
225
+ const toStats = impactStats.get(rel.to);
226
+ if (fromStats)
227
+ fromStats.outgoing += 1;
228
+ if (toStats)
229
+ toStats.incoming += 1;
230
+ }
231
+ }
232
+ // Build hotspots list
233
+ const hotspots = [];
234
+ for (const [nodeId, stats] of impactStats.entries()) {
235
+ const totalImpact = stats.incoming + stats.outgoing;
236
+ if (totalImpact > 0) {
237
+ hotspots.push({
238
+ nodeId,
239
+ node: nodeMap.get(nodeId),
240
+ incomingImpactCount: stats.incoming,
241
+ outgoingImpactCount: stats.outgoing,
242
+ totalImpact,
243
+ });
244
+ }
245
+ }
246
+ // Sort by total impact (descending)
247
+ hotspots.sort((a, b) => b.totalImpact - a.totalImpact);
248
+ const totalImpactedNodes = hotspots.length;
249
+ const averageDegree = totalImpactedNodes > 0
250
+ ? hotspots.reduce((sum, h) => sum + h.totalImpact, 0) /
251
+ totalImpactedNodes
252
+ : 0;
253
+ return {
254
+ hotspots,
255
+ summary: {
256
+ totalNodes: input.doc.nodes.length,
257
+ totalImpactedNodes,
258
+ averageDegree,
259
+ },
260
+ };
261
+ },
262
+ });
@@ -269,19 +269,31 @@ export declare const inferLifecycleOp: import("./define-operation.js").DefinedOp
269
269
  selects: "selects";
270
270
  requires: "requires";
271
271
  disables: "disables";
272
+ influence: "influence";
272
273
  }> & {
273
- 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";
274
+ 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";
274
275
  };
275
276
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
276
277
  is(value: unknown): value is string | string[];
277
278
  }>;
279
+ polarity: z.ZodOptional<z.ZodEnum<{
280
+ positive: "positive";
281
+ negative: "negative";
282
+ neutral: "neutral";
283
+ uncertain: "uncertain";
284
+ }> & {
285
+ is(value: unknown): value is "positive" | "negative" | "neutral" | "uncertain";
286
+ }>;
287
+ strength: z.ZodOptional<z.ZodNumber>;
278
288
  }, z.core.$loose> & {
279
289
  is(value: unknown): value is {
280
290
  [x: string]: unknown;
281
291
  from: string;
282
292
  to: string;
283
- 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";
293
+ 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";
284
294
  description?: string | string[] | undefined;
295
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
296
+ strength?: number | undefined;
285
297
  };
286
298
  }>>;
287
299
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -369,8 +381,10 @@ export declare const inferLifecycleOp: import("./define-operation.js").DefinedOp
369
381
  [x: string]: unknown;
370
382
  from: string;
371
383
  to: string;
372
- 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";
384
+ 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";
373
385
  description?: string | string[] | undefined;
386
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
387
+ strength?: number | undefined;
374
388
  }[] | undefined;
375
389
  external_references?: {
376
390
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
@@ -186,19 +186,31 @@ export declare const initDocumentOp: import("./define-operation.js").DefinedOper
186
186
  selects: "selects";
187
187
  requires: "requires";
188
188
  disables: "disables";
189
+ influence: "influence";
189
190
  }> & {
190
- 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";
191
+ 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";
191
192
  };
192
193
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
193
194
  is(value: unknown): value is string | string[];
194
195
  }>;
196
+ polarity: z.ZodOptional<z.ZodEnum<{
197
+ positive: "positive";
198
+ negative: "negative";
199
+ neutral: "neutral";
200
+ uncertain: "uncertain";
201
+ }> & {
202
+ is(value: unknown): value is "positive" | "negative" | "neutral" | "uncertain";
203
+ }>;
204
+ strength: z.ZodOptional<z.ZodNumber>;
195
205
  }, z.core.$loose> & {
196
206
  is(value: unknown): value is {
197
207
  [x: string]: unknown;
198
208
  from: string;
199
209
  to: string;
200
- 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";
210
+ 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";
201
211
  description?: string | string[] | undefined;
212
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
213
+ strength?: number | undefined;
202
214
  };
203
215
  }>>;
204
216
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -286,8 +298,10 @@ export declare const initDocumentOp: import("./define-operation.js").DefinedOper
286
298
  [x: string]: unknown;
287
299
  from: string;
288
300
  to: string;
289
- 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";
301
+ 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";
290
302
  description?: string | string[] | undefined;
303
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
304
+ strength?: number | undefined;
291
305
  }[] | undefined;
292
306
  external_references?: {
293
307
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
@@ -184,19 +184,31 @@ export declare const jsonToMarkdownOp: import("./define-operation.js").DefinedOp
184
184
  selects: "selects";
185
185
  requires: "requires";
186
186
  disables: "disables";
187
+ influence: "influence";
187
188
  }> & {
188
- 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";
189
+ 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";
189
190
  };
190
191
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
191
192
  is(value: unknown): value is string | string[];
192
193
  }>;
194
+ polarity: z.ZodOptional<z.ZodEnum<{
195
+ positive: "positive";
196
+ negative: "negative";
197
+ neutral: "neutral";
198
+ uncertain: "uncertain";
199
+ }> & {
200
+ is(value: unknown): value is "positive" | "negative" | "neutral" | "uncertain";
201
+ }>;
202
+ strength: z.ZodOptional<z.ZodNumber>;
193
203
  }, z.core.$loose> & {
194
204
  is(value: unknown): value is {
195
205
  [x: string]: unknown;
196
206
  from: string;
197
207
  to: string;
198
- 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";
208
+ 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";
199
209
  description?: string | string[] | undefined;
210
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
211
+ strength?: number | undefined;
200
212
  };
201
213
  }>>;
202
214
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -284,8 +296,10 @@ export declare const jsonToMarkdownOp: import("./define-operation.js").DefinedOp
284
296
  [x: string]: unknown;
285
297
  from: string;
286
298
  to: string;
287
- 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";
299
+ 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";
288
300
  description?: string | string[] | undefined;
301
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
302
+ strength?: number | undefined;
289
303
  }[] | undefined;
290
304
  external_references?: {
291
305
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
@@ -187,19 +187,31 @@ export declare const markTaskDoneOp: import("./define-operation.js").DefinedOper
187
187
  selects: "selects";
188
188
  requires: "requires";
189
189
  disables: "disables";
190
+ influence: "influence";
190
191
  }> & {
191
- 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";
192
+ 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";
192
193
  };
193
194
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
194
195
  is(value: unknown): value is string | string[];
195
196
  }>;
197
+ polarity: z.ZodOptional<z.ZodEnum<{
198
+ positive: "positive";
199
+ negative: "negative";
200
+ neutral: "neutral";
201
+ uncertain: "uncertain";
202
+ }> & {
203
+ is(value: unknown): value is "positive" | "negative" | "neutral" | "uncertain";
204
+ }>;
205
+ strength: z.ZodOptional<z.ZodNumber>;
196
206
  }, z.core.$loose> & {
197
207
  is(value: unknown): value is {
198
208
  [x: string]: unknown;
199
209
  from: string;
200
210
  to: string;
201
- 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";
211
+ 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";
202
212
  description?: string | string[] | undefined;
213
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
214
+ strength?: number | undefined;
203
215
  };
204
216
  }>>;
205
217
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -287,8 +299,10 @@ export declare const markTaskDoneOp: import("./define-operation.js").DefinedOper
287
299
  [x: string]: unknown;
288
300
  from: string;
289
301
  to: string;
290
- 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";
302
+ 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";
291
303
  description?: string | string[] | undefined;
304
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
305
+ strength?: number | undefined;
292
306
  }[] | undefined;
293
307
  external_references?: {
294
308
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
@@ -484,19 +498,31 @@ export declare const markTaskDoneOp: import("./define-operation.js").DefinedOper
484
498
  selects: "selects";
485
499
  requires: "requires";
486
500
  disables: "disables";
501
+ influence: "influence";
487
502
  }> & {
488
- 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";
503
+ 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";
489
504
  };
490
505
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
491
506
  is(value: unknown): value is string | string[];
492
507
  }>;
508
+ polarity: z.ZodOptional<z.ZodEnum<{
509
+ positive: "positive";
510
+ negative: "negative";
511
+ neutral: "neutral";
512
+ uncertain: "uncertain";
513
+ }> & {
514
+ is(value: unknown): value is "positive" | "negative" | "neutral" | "uncertain";
515
+ }>;
516
+ strength: z.ZodOptional<z.ZodNumber>;
493
517
  }, z.core.$loose> & {
494
518
  is(value: unknown): value is {
495
519
  [x: string]: unknown;
496
520
  from: string;
497
521
  to: string;
498
- 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";
522
+ 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";
499
523
  description?: string | string[] | undefined;
524
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
525
+ strength?: number | undefined;
500
526
  };
501
527
  }>>;
502
528
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -584,8 +610,10 @@ export declare const markTaskDoneOp: import("./define-operation.js").DefinedOper
584
610
  [x: string]: unknown;
585
611
  from: string;
586
612
  to: string;
587
- 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";
613
+ 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";
588
614
  description?: string | string[] | undefined;
615
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
616
+ strength?: number | undefined;
589
617
  }[] | undefined;
590
618
  external_references?: {
591
619
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
@@ -187,19 +187,31 @@ export declare const markTaskUndoneOp: import("./define-operation.js").DefinedOp
187
187
  selects: "selects";
188
188
  requires: "requires";
189
189
  disables: "disables";
190
+ influence: "influence";
190
191
  }> & {
191
- 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";
192
+ 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";
192
193
  };
193
194
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
194
195
  is(value: unknown): value is string | string[];
195
196
  }>;
197
+ polarity: z.ZodOptional<z.ZodEnum<{
198
+ positive: "positive";
199
+ negative: "negative";
200
+ neutral: "neutral";
201
+ uncertain: "uncertain";
202
+ }> & {
203
+ is(value: unknown): value is "positive" | "negative" | "neutral" | "uncertain";
204
+ }>;
205
+ strength: z.ZodOptional<z.ZodNumber>;
196
206
  }, z.core.$loose> & {
197
207
  is(value: unknown): value is {
198
208
  [x: string]: unknown;
199
209
  from: string;
200
210
  to: string;
201
- 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";
211
+ 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";
202
212
  description?: string | string[] | undefined;
213
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
214
+ strength?: number | undefined;
203
215
  };
204
216
  }>>;
205
217
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -287,8 +299,10 @@ export declare const markTaskUndoneOp: import("./define-operation.js").DefinedOp
287
299
  [x: string]: unknown;
288
300
  from: string;
289
301
  to: string;
290
- 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";
302
+ 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";
291
303
  description?: string | string[] | undefined;
304
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
305
+ strength?: number | undefined;
292
306
  }[] | undefined;
293
307
  external_references?: {
294
308
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";
@@ -484,19 +498,31 @@ export declare const markTaskUndoneOp: import("./define-operation.js").DefinedOp
484
498
  selects: "selects";
485
499
  requires: "requires";
486
500
  disables: "disables";
501
+ influence: "influence";
487
502
  }> & {
488
- 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";
503
+ 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";
489
504
  };
490
505
  description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]> & {
491
506
  is(value: unknown): value is string | string[];
492
507
  }>;
508
+ polarity: z.ZodOptional<z.ZodEnum<{
509
+ positive: "positive";
510
+ negative: "negative";
511
+ neutral: "neutral";
512
+ uncertain: "uncertain";
513
+ }> & {
514
+ is(value: unknown): value is "positive" | "negative" | "neutral" | "uncertain";
515
+ }>;
516
+ strength: z.ZodOptional<z.ZodNumber>;
493
517
  }, z.core.$loose> & {
494
518
  is(value: unknown): value is {
495
519
  [x: string]: unknown;
496
520
  from: string;
497
521
  to: string;
498
- 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";
522
+ 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";
499
523
  description?: string | string[] | undefined;
524
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
525
+ strength?: number | undefined;
500
526
  };
501
527
  }>>;
502
528
  external_references: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -584,8 +610,10 @@ export declare const markTaskUndoneOp: import("./define-operation.js").DefinedOp
584
610
  [x: string]: unknown;
585
611
  from: string;
586
612
  to: string;
587
- 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";
613
+ 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";
588
614
  description?: string | string[] | undefined;
615
+ polarity?: "positive" | "negative" | "neutral" | "uncertain" | undefined;
616
+ strength?: number | undefined;
589
617
  }[] | undefined;
590
618
  external_references?: {
591
619
  role: "output" | "input" | "context" | "evidence" | "source" | "standard" | "prior_art";