@x12i/graphenix-core 2.0.0 → 2.0.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.
@@ -0,0 +1,372 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "https://graphenix.dev/schema/graphenix-format-2.1.0.json",
4
+ "title": "Graphenix Format 2.1.0",
5
+ "description": "JSON Schema for the Graphenix graph description format (version 2.1.0). Execution semantics are out of scope.",
6
+ "type": "object",
7
+ "required": ["formatVersion", "id", "graph"],
8
+ "additionalProperties": false,
9
+ "properties": {
10
+ "formatVersion": {
11
+ "type": "string",
12
+ "const": "2.1.0",
13
+ "description": "Graphenix format version. Must be `2.1.0`."
14
+ },
15
+ "id": {
16
+ "type": "string",
17
+ "description": "Globally unique identifier for this graph within the system."
18
+ },
19
+ "revision": {
20
+ "type": "string",
21
+ "description": "Version/revision of this specific graph document. Not the Graphenix format version."
22
+ },
23
+ "name": {
24
+ "type": "string",
25
+ "description": "Human-readable name for the graph."
26
+ },
27
+ "description": {
28
+ "type": "string",
29
+ "description": "Free-form description of the graph."
30
+ },
31
+ "tags": {
32
+ "type": "array",
33
+ "items": { "type": "string" },
34
+ "description": "Tags for classification, search, and filtering."
35
+ },
36
+ "graph": {
37
+ "$ref": "#/$defs/Graph"
38
+ },
39
+ "types": {
40
+ "type": "array",
41
+ "items": { "$ref": "#/$defs/TypeDefinition" },
42
+ "description": "Custom logical types referenced by nodes and ports."
43
+ },
44
+ "subgraphs": {
45
+ "type": "array",
46
+ "items": { "$ref": "#/$defs/SubgraphDefinition" },
47
+ "description": "Inlined reusable graphs."
48
+ },
49
+ "metadata": {
50
+ "$ref": "#/$defs/DocumentMetadata"
51
+ }
52
+ },
53
+ "$defs": {
54
+ "GraphenixMetadata": {
55
+ "type": "object",
56
+ "description": "Arbitrary metadata with optional dynamic payload under `data`.",
57
+ "additionalProperties": true,
58
+ "properties": {
59
+ "data": {
60
+ "type": "object",
61
+ "description": "Dynamic client payload. Core does not interpret keys.",
62
+ "additionalProperties": true
63
+ }
64
+ }
65
+ },
66
+ "GraphMetadata": {
67
+ "allOf": [
68
+ { "$ref": "#/$defs/GraphenixMetadata" },
69
+ {
70
+ "type": "object",
71
+ "description": "Graph-level metadata including contracts and modelConfig.",
72
+ "properties": {
73
+ "graphEntry": { "$ref": "#/$defs/GraphEntryContract" },
74
+ "graphResponse": { "$ref": "#/$defs/GraphResponseContract" },
75
+ "modelConfig": {
76
+ "type": "object",
77
+ "description": "Graph-wide AI model cases. Validated by profile packages.",
78
+ "additionalProperties": true
79
+ }
80
+ }
81
+ }
82
+ ]
83
+ },
84
+ "DocumentMetadata": {
85
+ "allOf": [
86
+ { "$ref": "#/$defs/GraphenixMetadata" },
87
+ {
88
+ "type": "object",
89
+ "description": "Document-level metadata including graph-level summary contracts.",
90
+ "properties": {
91
+ "graphEntry": { "$ref": "#/$defs/GraphEntryContract" },
92
+ "graphResponse": { "$ref": "#/$defs/GraphResponseContract" },
93
+ "catalogRequests": { "$ref": "#/$defs/WoroxCatalogRequests" }
94
+ }
95
+ }
96
+ ]
97
+ },
98
+ "NodeMetadata": {
99
+ "allOf": [
100
+ { "$ref": "#/$defs/GraphenixMetadata" },
101
+ {
102
+ "type": "object",
103
+ "properties": {
104
+ "catalogBinding": { "$ref": "#/$defs/WoroxCatalogBinding" },
105
+ "catalogRequest": { "$ref": "#/$defs/WoroxCatalogRequest" }
106
+ }
107
+ }
108
+ ]
109
+ },
110
+ "Graph": {
111
+ "type": "object",
112
+ "required": ["nodes", "edges", "inputs", "outputs"],
113
+ "additionalProperties": false,
114
+ "properties": {
115
+ "nodes": {
116
+ "type": "array",
117
+ "items": { "$ref": "#/$defs/Node" }
118
+ },
119
+ "edges": {
120
+ "type": "array",
121
+ "items": { "$ref": "#/$defs/Edge" }
122
+ },
123
+ "inputs": {
124
+ "type": "array",
125
+ "items": { "$ref": "#/$defs/GraphInput" }
126
+ },
127
+ "outputs": {
128
+ "type": "array",
129
+ "items": { "$ref": "#/$defs/GraphOutput" }
130
+ },
131
+ "metadata": {
132
+ "$ref": "#/$defs/GraphMetadata"
133
+ }
134
+ }
135
+ },
136
+ "Node": {
137
+ "type": "object",
138
+ "required": ["id", "kind"],
139
+ "additionalProperties": false,
140
+ "properties": {
141
+ "id": { "type": "string" },
142
+ "name": { "type": "string" },
143
+ "kind": { "type": "string" },
144
+ "inputs": {
145
+ "type": "array",
146
+ "items": { "$ref": "#/$defs/PortDefinition" },
147
+ "default": []
148
+ },
149
+ "outputs": {
150
+ "type": "array",
151
+ "items": { "$ref": "#/$defs/PortDefinition" },
152
+ "default": []
153
+ },
154
+ "parameters": {
155
+ "type": "object",
156
+ "additionalProperties": true,
157
+ "default": {}
158
+ },
159
+ "metadata": { "$ref": "#/$defs/NodeMetadata" },
160
+ "layout": {
161
+ "type": "object",
162
+ "description": "Design-only canvas position; ignored at compile time.",
163
+ "properties": {
164
+ "x": { "type": "number" },
165
+ "y": { "type": "number" }
166
+ },
167
+ "additionalProperties": true
168
+ }
169
+ }
170
+ },
171
+ "PortDefinition": {
172
+ "type": "object",
173
+ "required": ["id", "direction", "type"],
174
+ "additionalProperties": false,
175
+ "properties": {
176
+ "id": { "type": "string" },
177
+ "name": { "type": "string" },
178
+ "direction": { "type": "string", "enum": ["input", "output"] },
179
+ "type": { "type": "string" },
180
+ "required": { "type": "boolean", "default": false },
181
+ "default": {
182
+ "type": ["string", "number", "boolean", "array", "object", "null"]
183
+ }
184
+ }
185
+ },
186
+ "EdgeEndpoint": {
187
+ "type": "object",
188
+ "required": ["nodeId", "portId"],
189
+ "additionalProperties": false,
190
+ "properties": {
191
+ "nodeId": { "type": "string" },
192
+ "portId": { "type": "string" }
193
+ }
194
+ },
195
+ "Edge": {
196
+ "type": "object",
197
+ "required": ["id", "from", "to"],
198
+ "additionalProperties": false,
199
+ "properties": {
200
+ "id": { "type": "string" },
201
+ "from": { "$ref": "#/$defs/EdgeEndpoint" },
202
+ "to": { "$ref": "#/$defs/EdgeEndpoint" },
203
+ "metadata": { "$ref": "#/$defs/GraphenixMetadata" }
204
+ }
205
+ },
206
+ "GraphInput": {
207
+ "type": "object",
208
+ "required": ["id", "type", "target"],
209
+ "additionalProperties": false,
210
+ "properties": {
211
+ "id": { "type": "string" },
212
+ "name": { "type": "string" },
213
+ "type": { "type": "string" },
214
+ "target": { "$ref": "#/$defs/EdgeEndpoint" },
215
+ "contract": { "$ref": "#/$defs/GraphInputContract" },
216
+ "metadata": { "$ref": "#/$defs/GraphenixMetadata" }
217
+ }
218
+ },
219
+ "GraphInputContract": {
220
+ "type": "object",
221
+ "additionalProperties": true,
222
+ "properties": {
223
+ "semanticKind": { "type": "string" },
224
+ "required": { "type": "boolean", "default": false },
225
+ "schema": { "type": "object", "additionalProperties": true },
226
+ "resolver": { "$ref": "#/$defs/GraphInputResolver" }
227
+ }
228
+ },
229
+ "GraphInputResolver": {
230
+ "type": "object",
231
+ "additionalProperties": true,
232
+ "properties": {
233
+ "kind": { "type": "string" },
234
+ "graphId": { "type": "string" },
235
+ "metadataFilter": { "type": "object", "additionalProperties": true }
236
+ }
237
+ },
238
+ "GraphOutput": {
239
+ "type": "object",
240
+ "required": ["id", "type"],
241
+ "additionalProperties": false,
242
+ "properties": {
243
+ "id": { "type": "string" },
244
+ "name": { "type": "string" },
245
+ "type": { "type": "string" },
246
+ "source": { "$ref": "#/$defs/EdgeEndpoint" },
247
+ "contract": { "$ref": "#/$defs/GraphOutputContract" },
248
+ "metadata": { "$ref": "#/$defs/GraphenixMetadata" }
249
+ }
250
+ },
251
+ "GraphOutputContract": {
252
+ "type": "object",
253
+ "additionalProperties": true,
254
+ "properties": {
255
+ "semanticKind": { "type": "string" },
256
+ "required": { "type": "boolean", "default": false },
257
+ "schema": { "type": "object", "additionalProperties": true },
258
+ "description": { "type": "string" }
259
+ }
260
+ },
261
+ "TypeField": {
262
+ "type": "object",
263
+ "required": ["name", "type"],
264
+ "additionalProperties": false,
265
+ "properties": {
266
+ "name": { "type": "string" },
267
+ "type": { "type": "string" },
268
+ "required": { "type": "boolean", "default": false }
269
+ }
270
+ },
271
+ "TypeObject": {
272
+ "type": "object",
273
+ "required": ["id", "kind", "fields"],
274
+ "additionalProperties": false,
275
+ "properties": {
276
+ "id": { "type": "string" },
277
+ "kind": { "const": "object" },
278
+ "description": { "type": "string" },
279
+ "fields": {
280
+ "type": "array",
281
+ "items": { "$ref": "#/$defs/TypeField" }
282
+ },
283
+ "metadata": { "$ref": "#/$defs/GraphenixMetadata" }
284
+ }
285
+ },
286
+ "TypeUnion": {
287
+ "type": "object",
288
+ "required": ["id", "kind", "options"],
289
+ "additionalProperties": false,
290
+ "properties": {
291
+ "id": { "type": "string" },
292
+ "kind": { "const": "union" },
293
+ "description": { "type": "string" },
294
+ "options": {
295
+ "type": "array",
296
+ "items": { "type": "string" }
297
+ },
298
+ "metadata": { "$ref": "#/$defs/GraphenixMetadata" }
299
+ }
300
+ },
301
+ "TypeAlias": {
302
+ "type": "object",
303
+ "required": ["id", "kind", "target"],
304
+ "additionalProperties": false,
305
+ "properties": {
306
+ "id": { "type": "string" },
307
+ "kind": { "const": "alias" },
308
+ "description": { "type": "string" },
309
+ "target": { "type": "string" },
310
+ "metadata": { "$ref": "#/$defs/GraphenixMetadata" }
311
+ }
312
+ },
313
+ "TypeDefinition": {
314
+ "oneOf": [
315
+ { "$ref": "#/$defs/TypeObject" },
316
+ { "$ref": "#/$defs/TypeUnion" },
317
+ { "$ref": "#/$defs/TypeAlias" }
318
+ ]
319
+ },
320
+ "SubgraphDefinition": {
321
+ "type": "object",
322
+ "required": ["id", "graph"],
323
+ "additionalProperties": false,
324
+ "properties": {
325
+ "id": { "type": "string" },
326
+ "name": { "type": "string" },
327
+ "graph": { "$ref": "#/$defs/Graph" },
328
+ "metadata": { "$ref": "#/$defs/GraphenixMetadata" }
329
+ }
330
+ },
331
+ "GraphEntryContract": {
332
+ "type": "object",
333
+ "description": "Graph-level summary contract for graph invocation.",
334
+ "additionalProperties": true,
335
+ "properties": {
336
+ "summary": { "type": "string" },
337
+ "requiredExecutionPaths": { "type": "array", "items": {} },
338
+ "executionSchema": { "type": "object", "additionalProperties": true },
339
+ "notableExecutionPaths": { "type": "array", "items": {} }
340
+ }
341
+ },
342
+ "GraphResponseContract": {
343
+ "type": "object",
344
+ "description": "Graph-level summary contract for the final graph result.",
345
+ "additionalProperties": true,
346
+ "properties": {
347
+ "summary": { "type": "string" },
348
+ "finalOutputSchema": { "type": "object", "additionalProperties": true }
349
+ }
350
+ },
351
+ "WoroxCatalogRequest": {
352
+ "type": "object",
353
+ "additionalProperties": true
354
+ },
355
+ "WoroxCatalogBinding": {
356
+ "type": "object",
357
+ "additionalProperties": true
358
+ },
359
+ "WoroxCatalogRequests": {
360
+ "oneOf": [
361
+ {
362
+ "type": "array",
363
+ "items": { "$ref": "#/$defs/WoroxCatalogRequest" }
364
+ },
365
+ {
366
+ "type": "object",
367
+ "additionalProperties": { "$ref": "#/$defs/WoroxCatalogRequest" }
368
+ }
369
+ ]
370
+ }
371
+ }
372
+ }