@meridian-flow/mars-schema 0.28.0 → 0.29.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 (24) hide show
  1. package/fixtures/normalize/agent-translation/normalized.json +36 -18
  2. package/fixtures/normalize/claude-plugin-default/normalized.json +6 -3
  3. package/fixtures/normalize/declared-mars-native/normalized.json +2 -1
  4. package/fixtures/normalize/mixed-claude-and-mars/normalized.json +8 -4
  5. package/fixtures/normalize/opencode-agent/normalized.json +8 -4
  6. package/fixtures/normalize/opencode-predicted/normalized.json +4 -2
  7. package/fixtures/normalize/opencode-with-standard-skill/normalized.json +2 -1
  8. package/fixtures/normalize/pre-v1-mars-permission/normalized.json +6 -3
  9. package/fixtures/normalize/pre-v1-mars-predicted/normalized.json +6 -3
  10. package/fixtures/prepare/claude-reserved-keys/expected.json +4 -2
  11. package/fixtures/prepare/declared-dialect/expected.json +6 -3
  12. package/fixtures/prepare/legacy-execution-non-string/expected/agents/runner.md +5 -0
  13. package/fixtures/prepare/legacy-execution-non-string/expected/mars.toml +4 -0
  14. package/fixtures/prepare/legacy-execution-non-string/expected.json +142 -0
  15. package/fixtures/prepare/legacy-execution-non-string/input/agents/runner.md +8 -0
  16. package/fixtures/prepare/legacy-execution-non-string/input/mars.toml +3 -0
  17. package/fixtures/prepare/legacy-execution-non-string/request.json +3 -0
  18. package/fixtures/prepare/opencode-agent/expected.json +8 -4
  19. package/fixtures/prepare/opencode-commands-dropped/expected.json +2 -1
  20. package/fixtures/read/agent-nested-order/expected.json +6 -3
  21. package/fixtures/read/agent-tools/expected.json +2 -1
  22. package/node/mars_schema_wasm_bg.wasm +0 -0
  23. package/package.json +1 -1
  24. package/web/mars_schema_wasm_bg.wasm +0 -0
@@ -99,7 +99,8 @@
99
99
  {
100
100
  "capability": "bash",
101
101
  "pattern": null,
102
- "action": "deny"
102
+ "action": "deny",
103
+ "origin": "profile"
103
104
  }
104
105
  ],
105
106
  "harness-overrides": {},
@@ -185,57 +186,68 @@
185
186
  {
186
187
  "capability": "*",
187
188
  "pattern": null,
188
- "action": "deny"
189
+ "action": "deny",
190
+ "origin": "profile"
189
191
  },
190
192
  {
191
193
  "capability": "read",
192
194
  "pattern": null,
193
- "action": "allow"
195
+ "action": "allow",
196
+ "origin": "profile"
194
197
  },
195
198
  {
196
199
  "capability": "grep",
197
200
  "pattern": null,
198
- "action": "allow"
201
+ "action": "allow",
202
+ "origin": "profile"
199
203
  },
200
204
  {
201
205
  "capability": "bash",
202
206
  "pattern": "git status *",
203
- "action": "allow"
207
+ "action": "allow",
208
+ "origin": "profile"
204
209
  },
205
210
  {
206
211
  "capability": "agent",
207
212
  "pattern": null,
208
- "action": "allow"
213
+ "action": "allow",
214
+ "origin": "profile"
209
215
  },
210
216
  {
211
217
  "capability": "mcp",
212
218
  "pattern": "github/get_issue",
213
- "action": "allow"
219
+ "action": "allow",
220
+ "origin": "profile"
214
221
  },
215
222
  {
216
223
  "capability": "mcp",
217
224
  "pattern": "github/*",
218
- "action": "allow"
225
+ "action": "allow",
226
+ "origin": "profile"
219
227
  },
220
228
  {
221
229
  "capability": "mcp",
222
230
  "pattern": "docs/*",
223
- "action": "allow"
231
+ "action": "allow",
232
+ "origin": "profile"
224
233
  },
225
234
  {
226
235
  "capability": "write",
227
236
  "pattern": null,
228
- "action": "deny"
237
+ "action": "deny",
238
+ "origin": "profile"
229
239
  },
230
240
  {
231
241
  "capability": "bash",
232
242
  "pattern": "rm *",
233
- "action": "deny"
243
+ "action": "deny",
244
+ "origin": "profile"
234
245
  },
235
246
  {
236
247
  "capability": "agent",
237
248
  "pattern": "untrusted",
238
- "action": "deny"
249
+ "action": "deny",
250
+ "origin": "profile"
239
251
  }
240
252
  ],
241
253
  "harness-overrides": {
@@ -314,17 +326,20 @@
314
326
  {
315
327
  "capability": "*",
316
328
  "pattern": null,
317
- "action": "deny"
329
+ "action": "deny",
330
+ "origin": "profile"
318
331
  },
319
332
  {
320
333
  "capability": "read",
321
334
  "pattern": null,
322
- "action": "allow"
335
+ "action": "allow",
336
+ "origin": "profile"
323
337
  },
324
338
  {
325
339
  "capability": "edit",
326
340
  "pattern": null,
327
- "action": "allow"
341
+ "action": "allow",
342
+ "origin": "profile"
328
343
  }
329
344
  ],
330
345
  "harness-overrides": {},
@@ -384,17 +399,20 @@
384
399
  {
385
400
  "capability": "read",
386
401
  "pattern": null,
387
- "action": "allow"
402
+ "action": "allow",
403
+ "origin": "profile"
388
404
  },
389
405
  {
390
406
  "capability": "grep",
391
407
  "pattern": null,
392
- "action": "allow"
408
+ "action": "allow",
409
+ "origin": "profile"
393
410
  },
394
411
  {
395
412
  "capability": "web_search",
396
413
  "pattern": null,
397
- "action": "deny"
414
+ "action": "deny",
415
+ "origin": "profile"
398
416
  }
399
417
  ],
400
418
  "harness-overrides": {},
@@ -112,17 +112,20 @@
112
112
  {
113
113
  "capability": "*",
114
114
  "pattern": null,
115
- "action": "deny"
115
+ "action": "deny",
116
+ "origin": "profile"
116
117
  },
117
118
  {
118
119
  "capability": "read",
119
120
  "pattern": null,
120
- "action": "allow"
121
+ "action": "allow",
122
+ "origin": "profile"
121
123
  },
122
124
  {
123
125
  "capability": "grep",
124
126
  "pattern": null,
125
- "action": "allow"
127
+ "action": "allow",
128
+ "origin": "profile"
126
129
  }
127
130
  ],
128
131
  "harness-overrides": {},
@@ -92,7 +92,8 @@
92
92
  {
93
93
  "capability": "bash",
94
94
  "pattern": null,
95
- "action": "deny"
95
+ "action": "deny",
96
+ "origin": "profile"
96
97
  }
97
98
  ],
98
99
  "harness-overrides": {},
@@ -97,22 +97,26 @@
97
97
  {
98
98
  "capability": "*",
99
99
  "pattern": null,
100
- "action": "deny"
100
+ "action": "deny",
101
+ "origin": "profile"
101
102
  },
102
103
  {
103
104
  "capability": "read",
104
105
  "pattern": null,
105
- "action": "allow"
106
+ "action": "allow",
107
+ "origin": "profile"
106
108
  },
107
109
  {
108
110
  "capability": "grep",
109
111
  "pattern": null,
110
- "action": "allow"
112
+ "action": "allow",
113
+ "origin": "profile"
111
114
  },
112
115
  {
113
116
  "capability": "glob",
114
117
  "pattern": null,
115
- "action": "allow"
118
+ "action": "allow",
119
+ "origin": "profile"
116
120
  }
117
121
  ],
118
122
  "harness-overrides": {},
@@ -115,22 +115,26 @@
115
115
  {
116
116
  "capability": "write",
117
117
  "pattern": null,
118
- "action": "deny"
118
+ "action": "deny",
119
+ "origin": "profile"
119
120
  },
120
121
  {
121
122
  "capability": "edit",
122
123
  "pattern": null,
123
- "action": "deny"
124
+ "action": "deny",
125
+ "origin": "profile"
124
126
  },
125
127
  {
126
128
  "capability": "bash",
127
129
  "pattern": null,
128
- "action": "deny"
130
+ "action": "deny",
131
+ "origin": "profile"
129
132
  },
130
133
  {
131
134
  "capability": "read",
132
135
  "pattern": null,
133
- "action": "allow"
136
+ "action": "allow",
137
+ "origin": "profile"
134
138
  }
135
139
  ],
136
140
  "harness-overrides": {
@@ -107,12 +107,14 @@
107
107
  {
108
108
  "capability": "write",
109
109
  "pattern": null,
110
- "action": "deny"
110
+ "action": "deny",
111
+ "origin": "profile"
111
112
  },
112
113
  {
113
114
  "capability": "edit",
114
115
  "pattern": null,
115
- "action": "deny"
116
+ "action": "deny",
117
+ "origin": "profile"
116
118
  }
117
119
  ],
118
120
  "harness-overrides": {
@@ -107,7 +107,8 @@
107
107
  {
108
108
  "capability": "write",
109
109
  "pattern": null,
110
- "action": "deny"
110
+ "action": "deny",
111
+ "origin": "profile"
111
112
  }
112
113
  ],
113
114
  "harness-overrides": {
@@ -103,17 +103,20 @@
103
103
  {
104
104
  "capability": "*",
105
105
  "pattern": null,
106
- "action": "deny"
106
+ "action": "deny",
107
+ "origin": "profile"
107
108
  },
108
109
  {
109
110
  "capability": "read",
110
111
  "pattern": null,
111
- "action": "allow"
112
+ "action": "allow",
113
+ "origin": "profile"
112
114
  },
113
115
  {
114
116
  "capability": "grep",
115
117
  "pattern": null,
116
- "action": "allow"
118
+ "action": "allow",
119
+ "origin": "profile"
117
120
  }
118
121
  ],
119
122
  "harness-overrides": {
@@ -104,17 +104,20 @@
104
104
  {
105
105
  "capability": "*",
106
106
  "pattern": null,
107
- "action": "deny"
107
+ "action": "deny",
108
+ "origin": "profile"
108
109
  },
109
110
  {
110
111
  "capability": "read",
111
112
  "pattern": null,
112
- "action": "allow"
113
+ "action": "allow",
114
+ "origin": "profile"
113
115
  },
114
116
  {
115
117
  "capability": "grep",
116
118
  "pattern": null,
117
- "action": "allow"
119
+ "action": "allow",
120
+ "origin": "profile"
118
121
  }
119
122
  ],
120
123
  "harness-overrides": {},
@@ -64,12 +64,14 @@
64
64
  {
65
65
  "capability": "read",
66
66
  "pattern": null,
67
- "action": "allow"
67
+ "action": "allow",
68
+ "origin": "profile"
68
69
  },
69
70
  {
70
71
  "capability": "write",
71
72
  "pattern": null,
72
- "action": "deny"
73
+ "action": "deny",
74
+ "origin": "profile"
73
75
  }
74
76
  ],
75
77
  "harness-overrides": {
@@ -55,17 +55,20 @@
55
55
  {
56
56
  "capability": "*",
57
57
  "pattern": null,
58
- "action": "deny"
58
+ "action": "deny",
59
+ "origin": "profile"
59
60
  },
60
61
  {
61
62
  "capability": "read",
62
63
  "pattern": null,
63
- "action": "allow"
64
+ "action": "allow",
65
+ "origin": "profile"
64
66
  },
65
67
  {
66
68
  "capability": "agent",
67
69
  "pattern": null,
68
- "action": "allow"
70
+ "action": "allow",
71
+ "origin": "profile"
69
72
  }
70
73
  ],
71
74
  "harness-overrides": {},
@@ -0,0 +1,5 @@
1
+ ---
2
+ name: runner
3
+ description: Runs things
4
+ ---
5
+ Body
@@ -0,0 +1,4 @@
1
+ [package]
2
+ name = "demo"
3
+ version = "1.0.0"
4
+ schema = 1
@@ -0,0 +1,142 @@
1
+ {
2
+ "classification": {
3
+ "kind": "mars-legacy"
4
+ },
5
+ "manifest": {
6
+ "source_path": "mars.toml",
7
+ "output_path": "mars.toml",
8
+ "reading": {
9
+ "frontmatter": [
10
+ [
11
+ "name",
12
+ "demo"
13
+ ],
14
+ [
15
+ "version",
16
+ "1.0.0"
17
+ ],
18
+ [
19
+ "schema",
20
+ 1
21
+ ]
22
+ ],
23
+ "fields": {
24
+ "name": "demo",
25
+ "version": "1.0.0",
26
+ "schema": 1
27
+ },
28
+ "body": null,
29
+ "diagnostics": []
30
+ },
31
+ "change": {
32
+ "kind": "edited",
33
+ "paths": [
34
+ [
35
+ "package",
36
+ "schema"
37
+ ]
38
+ ]
39
+ }
40
+ },
41
+ "definitions": [
42
+ {
43
+ "kind": "agent",
44
+ "slug": "runner",
45
+ "source_path": "agents/runner.md",
46
+ "output_path": "agents/runner.md",
47
+ "reading": {
48
+ "frontmatter": [
49
+ [
50
+ "name",
51
+ "runner"
52
+ ],
53
+ [
54
+ "description",
55
+ "Runs things"
56
+ ]
57
+ ],
58
+ "fields": {
59
+ "name": "runner",
60
+ "description": "Runs things",
61
+ "harness": null,
62
+ "model": null,
63
+ "mode": null,
64
+ "model-invocable": true,
65
+ "user-invocable": true,
66
+ "approval": null,
67
+ "sandbox": null,
68
+ "network": null,
69
+ "network-allow": [],
70
+ "network-deny": [],
71
+ "effort": null,
72
+ "skills": {
73
+ "load": [],
74
+ "available": []
75
+ },
76
+ "subagents": [],
77
+ "tools": [],
78
+ "harness-overrides": {},
79
+ "model-policies": []
80
+ },
81
+ "body": "Body\n",
82
+ "diagnostics": []
83
+ },
84
+ "change": {
85
+ "kind": "edited",
86
+ "paths": [
87
+ [
88
+ "effort"
89
+ ],
90
+ [
91
+ "mode"
92
+ ],
93
+ [
94
+ "sandbox"
95
+ ]
96
+ ]
97
+ }
98
+ }
99
+ ],
100
+ "payload": [],
101
+ "selection": {
102
+ "definitions": [
103
+ {
104
+ "kind": "agent",
105
+ "slug": "runner",
106
+ "output_path": "agents/runner.md",
107
+ "skills": []
108
+ }
109
+ ],
110
+ "edges": [],
111
+ "uses_providers": []
112
+ },
113
+ "diagnostics": {},
114
+ "changes": {
115
+ "agents/runner.md": [
116
+ {
117
+ "code": "field.execution-ignored",
118
+ "severity": "warning",
119
+ "path": [
120
+ "effort"
121
+ ],
122
+ "message": "agent `runner`: `effort: 3` ignored (not a string); use none, low, medium, high, xhigh or max"
123
+ },
124
+ {
125
+ "code": "field.execution-ignored",
126
+ "severity": "warning",
127
+ "path": [
128
+ "mode"
129
+ ],
130
+ "message": "agent `runner`: `mode: 1` ignored (not a string); use primary or subagent"
131
+ },
132
+ {
133
+ "code": "field.restriction-lost",
134
+ "severity": "warning",
135
+ "path": [
136
+ "sandbox"
137
+ ],
138
+ "message": "agent `runner` lost the restriction `sandbox`: it was dropped, because no harness reads it. Schema v1 does not accept it (`sandbox` must be a string); use default, read-only, workspace-write or danger-full-access"
139
+ }
140
+ ]
141
+ }
142
+ }
@@ -0,0 +1,8 @@
1
+ ---
2
+ name: runner
3
+ description: Runs things
4
+ effort: 3
5
+ mode: 1
6
+ sandbox: false
7
+ ---
8
+ Body
@@ -0,0 +1,3 @@
1
+ [package]
2
+ name = "demo"
3
+ version = "1.0.0"
@@ -0,0 +1,3 @@
1
+ {
2
+ "context": "package"
3
+ }
@@ -75,22 +75,26 @@
75
75
  {
76
76
  "capability": "write",
77
77
  "pattern": null,
78
- "action": "deny"
78
+ "action": "deny",
79
+ "origin": "profile"
79
80
  },
80
81
  {
81
82
  "capability": "edit",
82
83
  "pattern": null,
83
- "action": "deny"
84
+ "action": "deny",
85
+ "origin": "profile"
84
86
  },
85
87
  {
86
88
  "capability": "bash",
87
89
  "pattern": null,
88
- "action": "deny"
90
+ "action": "deny",
91
+ "origin": "profile"
89
92
  },
90
93
  {
91
94
  "capability": "read",
92
95
  "pattern": null,
93
- "action": "allow"
96
+ "action": "allow",
97
+ "origin": "profile"
94
98
  }
95
99
  ],
96
100
  "harness-overrides": {
@@ -55,7 +55,8 @@
55
55
  {
56
56
  "capability": "write",
57
57
  "pattern": null,
58
- "action": "deny"
58
+ "action": "deny",
59
+ "origin": "profile"
59
60
  }
60
61
  ],
61
62
  "harness-overrides": {},
@@ -63,17 +63,20 @@
63
63
  {
64
64
  "capability": "write",
65
65
  "pattern": null,
66
- "action": "allow"
66
+ "action": "allow",
67
+ "origin": "profile"
67
68
  },
68
69
  {
69
70
  "capability": "*",
70
71
  "pattern": null,
71
- "action": "deny"
72
+ "action": "deny",
73
+ "origin": "profile"
72
74
  },
73
75
  {
74
76
  "capability": "bash",
75
77
  "pattern": null,
76
- "action": "ask"
78
+ "action": "ask",
79
+ "origin": "profile"
77
80
  }
78
81
  ],
79
82
  "harness-overrides": {
@@ -30,7 +30,8 @@
30
30
  {
31
31
  "capability": "read",
32
32
  "pattern": null,
33
- "action": "allow"
33
+ "action": "allow",
34
+ "origin": "profile"
34
35
  }
35
36
  ],
36
37
  "harness-overrides": {},
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meridian-flow/mars-schema",
3
- "version": "0.28.0",
3
+ "version": "0.29.0",
4
4
  "description": "Mars agent schema reader and lossless editor",
5
5
  "license": "MIT",
6
6
  "repository": {
Binary file