agents-relay 2.0.146 → 2.0.147
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/workflow/graph-v2.js +20 -1
- package/package.json +1 -1
- package/workflow/authoritative-unblock.mmd +4 -0
- package/workflow/blocker-resolution.mmd +4 -0
- package/workflow/escalation.mmd +4 -0
- package/workflow/interactive-invocation.mmd +4 -0
- package/workflow/job-lifecycle.mmd +4 -0
- package/workflow/main.mmd +4 -0
- package/workflow/orchestrator-rescue.mmd +4 -0
- package/workflow/planner-orchestration.mmd +4 -0
- package/workflow/planner-trigger.mmd +4 -0
- package/workflow/projection-conflict.mmd +4 -0
- package/workflow/review-lifecycle.mmd +4 -0
- package/workflow/schedule-cycle.mmd +4 -0
- package/workflow/scheduled-run.mmd +4 -0
- package/workflow/task-lifecycle.mmd +4 -0
- package/workflow/task-related-action.mmd +4 -0
- package/workflow/task-resolution.mmd +4 -0
- package/workflow/troubleshooter.mmd +4 -0
|
@@ -24,11 +24,30 @@ function parseLabel(raw, line) {
|
|
|
24
24
|
}
|
|
25
25
|
export function parseGraphV2(source) {
|
|
26
26
|
const lines = source.split(/\r?\n/);
|
|
27
|
+
// Mermaid YAML frontmatter is metadata only; never execute it as graph policy.
|
|
28
|
+
// Preserve original source line positions for diagnostics and coverage reports.
|
|
29
|
+
let graphStart = 0;
|
|
30
|
+
if (lines[0]?.trim() === '---') {
|
|
31
|
+
let closing = -1;
|
|
32
|
+
for (let i = 1; i < lines.length; i += 1) {
|
|
33
|
+
if (lines[i].trim() === '---') {
|
|
34
|
+
closing = i;
|
|
35
|
+
break;
|
|
36
|
+
}
|
|
37
|
+
if (!/^(title|description):\s+[^\r\n]+$/.test(lines[i]))
|
|
38
|
+
fail(i + 1, 'unsupported graph frontmatter field');
|
|
39
|
+
}
|
|
40
|
+
if (closing < 0)
|
|
41
|
+
fail(1, 'unterminated graph frontmatter');
|
|
42
|
+
if (closing === 1)
|
|
43
|
+
fail(1, 'empty graph frontmatter');
|
|
44
|
+
graphStart = closing + 1;
|
|
45
|
+
}
|
|
27
46
|
let direction = null;
|
|
28
47
|
let initial = null;
|
|
29
48
|
const nodes = new Map();
|
|
30
49
|
const edges = [];
|
|
31
|
-
for (let index =
|
|
50
|
+
for (let index = graphStart; index < lines.length; index += 1) {
|
|
32
51
|
const lineNumber = index + 1;
|
|
33
52
|
const line = lines[index].trim();
|
|
34
53
|
if (!line)
|
package/package.json
CHANGED
package/workflow/escalation.mmd
CHANGED
package/workflow/main.mmd
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Main
|
|
3
|
+
description: Presentation-only entry map linking workflow graphs and explaining contract, graph, code, guard, action, and effect ownership.
|
|
4
|
+
---
|
|
1
5
|
%% dashboard: presentation-only — not registered with GraphRuntime or the executable Graph DSL.
|
|
2
6
|
%% PRINCIPLES (this graph is a readable overview, not an executable policy):
|
|
3
7
|
%% CONTRACT defines typed events, permissions and invariants; GRAPH defines legal transitions,
|