Skip to content

Commit 3756b54

Browse files
authored
Update generation (#64)
* generate_schema adds unique property * update workflow and operation with new generation script * remove unused imports, change unique location * update operations.json with new format * fix version numbering
1 parent f700482 commit 3756b54

File tree

3 files changed

+34
-3
lines changed

3 files changed

+34
-3
lines changed

schema/build/generate_schema.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ def generate_component(op: str):
3131
op,
3232
],
3333
},
34+
"unique": (True if data.get("unique") else False),
3435
"parameters": data["parameters"],
3536
},
3637
"required": [

schema/operation.json

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"$schema": "https://json-schema.org/draft-07/schema",
3-
"$id": "https://standards.ncats.io/operation/1.1.0/schema",
3+
"$id": "https://standards.ncats.io/operation/1.2.0/schema",
44
"anyOf": [
55
{
66
"$ref": "#/$defs/OperationAnnotate"
@@ -104,6 +104,7 @@
104104
"annotate"
105105
]
106106
},
107+
"unique": true,
107108
"parameters": {}
108109
},
109110
"required": [
@@ -121,6 +122,7 @@
121122
"annotate_edges"
122123
]
123124
},
125+
"unique": true,
124126
"parameters": {
125127
"type": "object",
126128
"properties": {
@@ -152,6 +154,7 @@
152154
"annotate_nodes"
153155
]
154156
},
157+
"unique": true,
155158
"parameters": {
156159
"type": "object",
157160
"properties": {
@@ -183,6 +186,7 @@
183186
"bind"
184187
]
185188
},
189+
"unique": false,
186190
"parameters": {}
187191
},
188192
"required": [
@@ -200,6 +204,7 @@
200204
"complete_results"
201205
]
202206
},
207+
"unique": false,
203208
"parameters": {}
204209
},
205210
"required": [
@@ -217,6 +222,7 @@
217222
"enrich_results"
218223
]
219224
},
225+
"unique": true,
220226
"parameters": {
221227
"type": "object",
222228
"properties": {
@@ -256,6 +262,7 @@
256262
"fill"
257263
]
258264
},
265+
"unique": true,
259266
"parameters": {
260267
"type": "object",
261268
"oneOf": [
@@ -329,6 +336,7 @@
329336
"filter_kgraph"
330337
]
331338
},
339+
"unique": false,
332340
"parameters": {}
333341
},
334342
"required": [
@@ -346,6 +354,7 @@
346354
"filter_kgraph_continuous_kedge_attribute"
347355
]
348356
},
357+
"unique": false,
349358
"parameters": {
350359
"type": "object",
351360
"properties": {
@@ -412,6 +421,7 @@
412421
"filter_kgraph_discrete_kedge_attribute"
413422
]
414423
},
424+
"unique": false,
415425
"parameters": {
416426
"type": "object",
417427
"properties": {
@@ -468,6 +478,7 @@
468478
"filter_kgraph_discrete_knode_attribute"
469479
]
470480
},
481+
"unique": false,
471482
"parameters": {
472483
"type": "object",
473484
"properties": {
@@ -513,6 +524,7 @@
513524
"filter_kgraph_orphans"
514525
]
515526
},
527+
"unique": false,
516528
"parameters": {}
517529
},
518530
"required": [
@@ -530,6 +542,7 @@
530542
"filter_kgraph_percentile"
531543
]
532544
},
545+
"unique": false,
533546
"parameters": {
534547
"type": "object",
535548
"properties": {
@@ -598,6 +611,7 @@
598611
"filter_kgraph_std_dev"
599612
]
600613
},
614+
"unique": false,
601615
"parameters": {
602616
"type": "object",
603617
"properties": {
@@ -674,6 +688,7 @@
674688
"filter_kgraph_top_n"
675689
]
676690
},
691+
"unique": false,
677692
"parameters": {
678693
"type": "object",
679694
"properties": {
@@ -741,6 +756,7 @@
741756
"filter_results"
742757
]
743758
},
759+
"unique": false,
744760
"parameters": {}
745761
},
746762
"required": [
@@ -758,6 +774,7 @@
758774
"filter_results_top_n"
759775
]
760776
},
777+
"unique": false,
761778
"parameters": {
762779
"type": "object",
763780
"properties": {
@@ -789,6 +806,7 @@
789806
"lookup"
790807
]
791808
},
809+
"unique": true,
792810
"parameters": {}
793811
},
794812
"required": [
@@ -806,6 +824,7 @@
806824
"lookup_and_score"
807825
]
808826
},
827+
"unique": true,
809828
"parameters": {}
810829
},
811830
"required": [
@@ -823,6 +842,7 @@
823842
"overlay"
824843
]
825844
},
845+
"unique": false,
826846
"parameters": {}
827847
},
828848
"required": [
@@ -840,6 +860,7 @@
840860
"overlay_compute_jaccard"
841861
]
842862
},
863+
"unique": false,
843864
"parameters": {
844865
"type": "object",
845866
"properties": {
@@ -888,6 +909,7 @@
888909
"overlay_compute_ngd"
889910
]
890911
},
912+
"unique": false,
891913
"parameters": {
892914
"type": "object",
893915
"properties": {
@@ -930,6 +952,7 @@
930952
"overlay_connect_knodes"
931953
]
932954
},
955+
"unique": false,
933956
"parameters": {}
934957
},
935958
"required": [
@@ -947,6 +970,7 @@
947970
"overlay_fisher_exact_test"
948971
]
949972
},
973+
"unique": false,
950974
"parameters": {
951975
"type": "object",
952976
"properties": {
@@ -994,6 +1018,7 @@
9941018
"restate"
9951019
]
9961020
},
1021+
"unique": true,
9971022
"parameters": {}
9981023
},
9991024
"required": [
@@ -1011,6 +1036,7 @@
10111036
"score"
10121037
]
10131038
},
1039+
"unique": true,
10141040
"parameters": {}
10151041
},
10161042
"required": [
@@ -1028,6 +1054,7 @@
10281054
"sort_results"
10291055
]
10301056
},
1057+
"unique": false,
10311058
"parameters": {}
10321059
},
10331060
"required": [
@@ -1045,6 +1072,7 @@
10451072
"sort_results_edge_attribute"
10461073
]
10471074
},
1075+
"unique": false,
10481076
"parameters": {
10491077
"type": "object",
10501078
"properties": {
@@ -1094,6 +1122,7 @@
10941122
"sort_results_node_attribute"
10951123
]
10961124
},
1125+
"unique": false,
10971126
"parameters": {
10981127
"type": "object",
10991128
"properties": {
@@ -1143,6 +1172,7 @@
11431172
"sort_results_score"
11441173
]
11451174
},
1175+
"unique": false,
11461176
"parameters": {
11471177
"type": "object",
11481178
"properties": {

schema/workflow.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"$schema": "https://json-schema.org/draft-07/schema",
3-
"$id": "https://standards.ncats.io/workflow/1.1.0/schema",
3+
"$id": "https://standards.ncats.io/workflow/1.2.0/schema",
44
"type": "array",
55
"items": {
6-
"$ref": "https://standards.ncats.io/operation/1.1.0/schema"
6+
"$ref": "https://standards.ncats.io/operation/1.2.0/schema"
77
}
88
}

0 commit comments

Comments
 (0)