Skip to content

Commit 5ebda3d

Browse files
authored
test: materialize deterministic MCP corruption fixtures
Materialize deterministic MCP corruption fixtures for the initial state, graph, and trace operators. Includes materializer script, committed fixture corpus, and focused tests for schema preservation, single-surface mutations, deterministic regeneration, manifest identity consistency, and strict nullable-list handling. Scope: deterministic fixture materialization only; no validator changes, runtime behavior, workflows, package changes, README changes, taxonomy changes, LLM, embedding, fuzzy, cloud, or orchestration behavior.
1 parent 7794f69 commit 5ebda3d

29 files changed

Lines changed: 2185 additions & 0 deletions

File tree

Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
{
2+
"graph_version": "1.0",
3+
"nodes": [
4+
{
5+
"node_id": "system_start",
6+
"label": "System start",
7+
"metadata": {
8+
"phase": "system"
9+
}
10+
},
11+
{
12+
"node_id": "user_request_received",
13+
"label": "User request received",
14+
"metadata": {
15+
"phase": "intake"
16+
}
17+
},
18+
{
19+
"node_id": "capability_scope_checked",
20+
"label": "Capability scope checked",
21+
"metadata": {
22+
"phase": "governance"
23+
}
24+
},
25+
{
26+
"node_id": "tool_schema_validated",
27+
"label": "Tool schema validated",
28+
"metadata": {
29+
"phase": "validation"
30+
}
31+
},
32+
{
33+
"node_id": "read_context",
34+
"label": "Read context",
35+
"metadata": {
36+
"phase": "context"
37+
}
38+
},
39+
{
40+
"node_id": "validate_external_action",
41+
"label": "Validate external action",
42+
"metadata": {
43+
"phase": "validation"
44+
}
45+
},
46+
{
47+
"node_id": "execute_external_action",
48+
"label": "Execute external action",
49+
"metadata": {
50+
"phase": "execution"
51+
}
52+
},
53+
{
54+
"node_id": "verify_result",
55+
"label": "Verify result",
56+
"metadata": {
57+
"phase": "verification"
58+
}
59+
},
60+
{
61+
"node_id": "recovery_path_registered",
62+
"label": "Recovery path registered",
63+
"metadata": {
64+
"phase": "recovery"
65+
}
66+
}
67+
],
68+
"edges": [
69+
{
70+
"source": "system_start",
71+
"target": "user_request_received",
72+
"relation": "TEMPORAL",
73+
"metadata": {}
74+
},
75+
{
76+
"source": "user_request_received",
77+
"target": "capability_scope_checked",
78+
"relation": "PREREQUISITE",
79+
"metadata": {}
80+
},
81+
{
82+
"source": "capability_scope_checked",
83+
"target": "tool_schema_validated",
84+
"relation": "PREREQUISITE",
85+
"metadata": {}
86+
},
87+
{
88+
"source": "tool_schema_validated",
89+
"target": "read_context",
90+
"relation": "DATA_FLOW",
91+
"metadata": {}
92+
},
93+
{
94+
"source": "read_context",
95+
"target": "validate_external_action",
96+
"relation": "PREREQUISITE",
97+
"metadata": {}
98+
},
99+
{
100+
"source": "validate_external_action",
101+
"target": "execute_external_action",
102+
"relation": "CAUSAL",
103+
"metadata": {}
104+
},
105+
{
106+
"source": "execute_external_action",
107+
"target": "verify_result",
108+
"relation": "CAUSAL",
109+
"metadata": {}
110+
},
111+
{
112+
"source": "execute_external_action",
113+
"target": "recovery_path_registered",
114+
"relation": "RECOVERY",
115+
"metadata": {}
116+
},
117+
{
118+
"source": "capability_scope_checked",
119+
"target": "execute_external_action",
120+
"relation": "BLOCKER",
121+
"metadata": {
122+
"state": "enforced"
123+
}
124+
},
125+
{
126+
"source": "capability_scope_checked",
127+
"target": "validate_external_action",
128+
"relation": "CAUSAL",
129+
"metadata": {}
130+
}
131+
]
132+
}
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"state_version": "1.0",
3+
"entities": {},
4+
"capability_boundaries": [
5+
[
6+
"agent",
7+
"capability_scope_checked"
8+
],
9+
[
10+
"capability_scope_checked",
11+
"validate_external_action"
12+
]
13+
],
14+
"allowed_tools": [
15+
"read_context",
16+
"validate_external_action",
17+
"execute_external_action",
18+
"verify_result"
19+
],
20+
"resource_boundaries": [
21+
[
22+
"execute_external_action",
23+
"approved_external_resource"
24+
]
25+
],
26+
"permission_scopes": {
27+
"execute_external_action": [
28+
"requires_human_approval",
29+
"requires_validation_passed"
30+
]
31+
},
32+
"capability_scope": {
33+
"agent": [
34+
"read_context",
35+
"validate_external_action",
36+
"execute_external_action",
37+
"verify_result"
38+
]
39+
}
40+
}
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"events": [
3+
{
4+
"action": "user_request_received",
5+
"step": 1
6+
},
7+
{
8+
"action": "capability_scope_checked",
9+
"step": 2
10+
},
11+
{
12+
"action": "tool_schema_validated",
13+
"step": 3
14+
},
15+
{
16+
"action": "read_context",
17+
"step": 4
18+
},
19+
{
20+
"action": "validate_external_action",
21+
"step": 5
22+
},
23+
{
24+
"action": "execute_external_action",
25+
"step": 6
26+
},
27+
{
28+
"action": "verify_result",
29+
"step": 7
30+
},
31+
{
32+
"action": "recovery_path_registered",
33+
"step": 8
34+
}
35+
]
36+
}
Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
{
2+
"graph_version": "1.0",
3+
"nodes": [
4+
{
5+
"node_id": "system_start",
6+
"label": "System start",
7+
"metadata": {
8+
"phase": "system"
9+
}
10+
},
11+
{
12+
"node_id": "user_request_received",
13+
"label": "User request received",
14+
"metadata": {
15+
"phase": "intake"
16+
}
17+
},
18+
{
19+
"node_id": "capability_scope_checked",
20+
"label": "Capability scope checked",
21+
"metadata": {
22+
"phase": "governance"
23+
}
24+
},
25+
{
26+
"node_id": "tool_schema_validated",
27+
"label": "Tool schema validated",
28+
"metadata": {
29+
"phase": "validation"
30+
}
31+
},
32+
{
33+
"node_id": "read_context",
34+
"label": "Read context",
35+
"metadata": {
36+
"phase": "context"
37+
}
38+
},
39+
{
40+
"node_id": "validate_external_action",
41+
"label": "Validate external action",
42+
"metadata": {
43+
"phase": "validation"
44+
}
45+
},
46+
{
47+
"node_id": "execute_external_action",
48+
"label": "Execute external action",
49+
"metadata": {
50+
"phase": "execution"
51+
}
52+
},
53+
{
54+
"node_id": "verify_result",
55+
"label": "Verify result",
56+
"metadata": {
57+
"phase": "verification"
58+
}
59+
},
60+
{
61+
"node_id": "recovery_path_registered",
62+
"label": "Recovery path registered",
63+
"metadata": {
64+
"phase": "recovery"
65+
}
66+
}
67+
],
68+
"edges": [
69+
{
70+
"source": "system_start",
71+
"target": "user_request_received",
72+
"relation": "TEMPORAL",
73+
"metadata": {}
74+
},
75+
{
76+
"source": "user_request_received",
77+
"target": "capability_scope_checked",
78+
"relation": "PREREQUISITE",
79+
"metadata": {}
80+
},
81+
{
82+
"source": "capability_scope_checked",
83+
"target": "tool_schema_validated",
84+
"relation": "PREREQUISITE",
85+
"metadata": {}
86+
},
87+
{
88+
"source": "tool_schema_validated",
89+
"target": "read_context",
90+
"relation": "DATA_FLOW",
91+
"metadata": {}
92+
},
93+
{
94+
"source": "validate_external_action",
95+
"target": "execute_external_action",
96+
"relation": "CAUSAL",
97+
"metadata": {}
98+
},
99+
{
100+
"source": "execute_external_action",
101+
"target": "verify_result",
102+
"relation": "CAUSAL",
103+
"metadata": {}
104+
},
105+
{
106+
"source": "execute_external_action",
107+
"target": "recovery_path_registered",
108+
"relation": "RECOVERY",
109+
"metadata": {}
110+
},
111+
{
112+
"source": "capability_scope_checked",
113+
"target": "execute_external_action",
114+
"relation": "BLOCKER",
115+
"metadata": {
116+
"state": "enforced"
117+
}
118+
},
119+
{
120+
"source": "capability_scope_checked",
121+
"target": "validate_external_action",
122+
"relation": "CAUSAL",
123+
"metadata": {}
124+
}
125+
]
126+
}
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
"state_version": "1.0",
3+
"entities": {},
4+
"capability_boundaries": [
5+
[
6+
"agent",
7+
"capability_scope_checked"
8+
],
9+
[
10+
"capability_scope_checked",
11+
"validate_external_action"
12+
],
13+
[
14+
"human_approval",
15+
"execute_external_action"
16+
]
17+
],
18+
"allowed_tools": [
19+
"read_context",
20+
"validate_external_action",
21+
"execute_external_action",
22+
"verify_result"
23+
],
24+
"resource_boundaries": [
25+
[
26+
"execute_external_action",
27+
"approved_external_resource"
28+
]
29+
],
30+
"permission_scopes": {
31+
"execute_external_action": [
32+
"requires_human_approval",
33+
"requires_validation_passed"
34+
]
35+
},
36+
"capability_scope": {
37+
"agent": [
38+
"read_context",
39+
"validate_external_action",
40+
"execute_external_action",
41+
"verify_result"
42+
]
43+
}
44+
}

0 commit comments

Comments
 (0)