/
wfoperations.js
543 lines (543 loc) · 16.1 KB
/
wfoperations.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
// WARNING:
// This file was auto-generated by ./wf2js.py on: 2022-06-22 08:22:19
//
var wf_operations = {
"annotate": {
"in_arax": false,
"parameters": {}
},
"annotate_edges": {
"in_arax": false,
"parameters": {
"attributes": {
"is_required": false,
"type": "array",
"examples": [
"pmids"
],
"description": "A list of attributes to annotate the edges with. If not included then all available data will be annotated."
}
}
},
"annotate_nodes": {
"in_arax": true,
"parameters": {
"attributes": {
"is_required": false,
"type": "array",
"examples": [
"pmids"
],
"description": "A list of attributes to annotate the nodes with. If not included then all available data will be annotated."
}
}
},
"bind": {
"in_arax": true,
"parameters": {}
},
"complete_results": {
"in_arax": true,
"parameters": {}
},
"enrich_results": {
"in_arax": false,
"parameters": {
"pvalue_threshold": {
"is_required": false,
"type": "number",
"default": "1e-6",
"min": 0,
"max": 1,
"examples": "1e-7",
"description": "The cutoff p-value for enrichment."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"examples": [
"n01"
],
"description": "If specified, then only knodes bound to these qnodes will be examined for enrichment and combination."
}
}
},
"fill": {
"in_arax": true,
"warning": "Only one of the following sets of parameters can be used: [allowlist, qedge_keys] OR [denylist, qedge_keys]",
"parameters": {
"allowlist": {
"is_required": false,
"type": "array",
"minLength": 1,
"examples": [
"icees"
],
"description": "List of knowledge providers/sources that may be used to provide knowledge."
},
"denylist": {
"is_required": false,
"type": "array",
"minLength": 1,
"examples": [
"ctd"
],
"description": "List of knowledge providers/sources that may NOT be used to provide knowledge."
},
"qedge_keys": {
"is_required": false,
"type": "array",
"examples": [
"e00"
],
"description": "A list of qedge keys. If included only edges corresponding to the given qedge keys, as well as their connected nodes, will be filled. If not included all edges will be filled."
}
}
},
"filter_kgraph": {
"in_arax": false,
"parameters": {}
},
"filter_kgraph_continuous_kedge_attribute": {
"in_arax": true,
"parameters": {
"edge_attribute": {
"is_required": true,
"type": "string",
"examples": "normalized_google_distance",
"description": "The name of the edge attribute to filter on."
},
"threshold": {
"is_required": true,
"type": "number",
"examples": 1.2,
"description": "The value to compare attribute values to."
},
"remove_above_or_below": {
"is_required": true,
"type": "string",
"enum": [
"above",
"below"
],
"description": "Indicates whether to remove above or below the given threshold."
},
"qedge_keys": {
"is_required": false,
"type": "array",
"examples": [
"e01"
],
"description": "This indicates if you only want to remove edges with specific edge_keys. If not provided or empty, all edges will be filtered on."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"default": [],
"examples": [
"n01"
],
"description": "This indicates if you only want nodes corresponding to a specific list of qnode_keys to be removed. If not provided or empty, no nodes will be removed when filtering. Allows us to know what to do with the nodes connected to edges that are removed."
}
}
},
"filter_kgraph_discrete_kedge_attribute": {
"in_arax": true,
"parameters": {
"edge_attribute": {
"is_required": true,
"type": "string",
"examples": "provided_by",
"description": "The name of the edge attribute to filter on."
},
"remove_value": {
"is_required": true,
"examples": "infores:semmeddb",
"description": "The value for which all edges containing this value in the specified edge_attribute should be removed."
},
"qedge_keys": {
"is_required": false,
"type": "array",
"examples": [
"e01"
],
"description": "This indicates if you only want to remove edges with specific edge_keys. If not provided or empty, all edges will be filtered on."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"default": [],
"examples": [
"n01"
],
"description": "This indicates if you only want nodes corresponding to a specific list of qnode_keys to be removed. If not provided or empty, no nodes will be removed when filtering. Allows us to know what to do with the nodes connected to edges that are removed"
}
}
},
"filter_kgraph_discrete_knode_attribute": {
"in_arax": false,
"parameters": {
"node_attribute": {
"is_required": true,
"type": "string",
"examples": "molecule_type",
"description": "The name of the node attribute to filter on."
},
"remove_value": {
"is_required": true,
"examples": "small_molecule",
"description": "The value for which all edges containing this value in the specified edge_attribute should be removed."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"examples": [
"n01"
],
"description": "This indicates if you only want to remove nodes corresponding to a specific list of qnode_keys to be removed. If not provided or empty, all nodes will be considered when filtering."
}
}
},
"filter_kgraph_orphans": {
"in_arax": true,
"parameters": {}
},
"filter_kgraph_percentile": {
"in_arax": true,
"parameters": {
"edge_attribute": {
"is_required": true,
"type": "string",
"examples": "normalized_google_distance",
"description": "The name of the edge attribute to filter on."
},
"threshold": {
"is_required": false,
"type": "number",
"default": 95,
"min": 0,
"max": 100,
"examples": 96.8,
"description": "The percentile to threshold on."
},
"remove_above_or_below": {
"is_required": false,
"type": "string",
"enum": [
"above",
"below"
],
"default": "below",
"description": "Indicates whether to remove above or below the given threshold."
},
"qedge_keys": {
"is_required": false,
"type": "array",
"examples": [
"e01"
],
"description": "This indicates if you only want to filter on specific edge_keys. If not provided or empty, all edges will be filtered on."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"default": [],
"examples": [
"n01"
],
"description": "This indicates if you only want nodes corresponding to a specific list of qnode_keys to be removed. If not provided or empty, no nodes will be removed when filtering. Allows us to know what to do with the nodes connected to edges that are removed."
}
}
},
"filter_kgraph_std_dev": {
"in_arax": true,
"parameters": {
"edge_attribute": {
"is_required": true,
"type": "string",
"examples": "normalized_google_distance",
"description": "The name of the edge attribute to filter on."
},
"num_sigma": {
"is_required": false,
"type": "number",
"default": 1,
"min": 0,
"examples": 1.2,
"description": "The number of standard deviations to threshold on."
},
"remove_above_or_below": {
"is_required": false,
"type": "string",
"enum": [
"above",
"below"
],
"default": "below",
"description": "Indictes whether to remove above or below the given threshold."
},
"plus_or_minus_std_dev": {
"is_required": false,
"type": "string",
"enum": [
"plus",
"minus"
],
"default": "plus",
"description": "Indicate whether or not the threshold should be found using plus or minus the standard deviation. E.g. when plus_or_minus_std_dev is set to plus will set the cutoff for filtering as the mean + num_sigma * std_dev while setting plus_or_minus_std_dev to minus will set the cutoff as the mean - num_sigma * std_dev."
},
"qedge_keys": {
"is_required": false,
"type": "array",
"examples": [
"e01"
],
"description": "This indicates if you only want to filter on specific edge_keys. If not provided or empty, all edges will be filtered on."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"default": [],
"examples": [
"n01"
],
"description": "This indicates if you only want nodes corresponding to a specific list of qnode_keys to be removed. If not provided or empty, no nodes will be removed when filtering."
}
}
},
"filter_kgraph_top_n": {
"in_arax": true,
"parameters": {
"edge_attribute": {
"is_required": true,
"type": "string",
"examples": "normalized_google_distance",
"description": "The name of the edge attribute to filter on."
},
"max_edges": {
"is_required": false,
"type": "integer",
"default": 50,
"min": 0,
"examples": 10,
"description": "The number of edges to keep."
},
"keep_top_or_bottom": {
"is_required": false,
"type": "string",
"enum": [
"top",
"bottom"
],
"default": "top",
"description": "Indicate whether or not the the top or bottom n values should be kept."
},
"qedge_keys": {
"is_required": false,
"type": "array",
"examples": [
"e01"
],
"description": "This indicates if you only want to filter on specific edge_keys. If not provided or empty, all edges will be filtered on."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"default": [],
"examples": [
"n01"
],
"description": "This indicates if you only want nodes corresponding to a specific list of qnode_keys to be removed. If not provided or empty, no nodes will be removed when filtering. Allows us to know what to do with the nodes connected to edges that are removed."
}
}
},
"filter_results": {
"in_arax": false,
"parameters": {}
},
"filter_results_top_n": {
"in_arax": true,
"parameters": {
"max_results": {
"is_required": true,
"type": "integer",
"min": 0,
"examples": 50,
"description": "The maximum number of results to return."
}
}
},
"lookup": {
"in_arax": true,
"parameters": {}
},
"lookup_and_score": {
"in_arax": true,
"parameters": {}
},
"overlay": {
"in_arax": false,
"parameters": {}
},
"overlay_compute_jaccard": {
"in_arax": true,
"parameters": {
"intermediate_node_key": {
"is_required": true,
"type": "string",
"examples": "n1",
"description": "A qnode key specifying the intermediate node."
},
"end_node_keys": {
"is_required": true,
"type": "array",
"examples": [
"n0",
"n2"
],
"description": "A list of qnode keys specifying the ending nodes."
},
"virtual_relation_label": {
"is_required": true,
"type": "string",
"examples": "J1",
"description": "The key of the query graph edge that corresponds to the knowledge graph edges that were added by this operation."
}
}
},
"overlay_compute_ngd": {
"in_arax": true,
"parameters": {
"virtual_relation_label": {
"is_required": true,
"type": "string",
"examples": "NGD1",
"description": "An label to help identify the virtual edge in the relation field"
},
"qnode_keys": {
"is_required": true,
"type": "array",
"examples": [
"n00",
"n01"
],
"description": "A list of qnode keys to overlay pairwise edges onto. Must be be a list of at least 2 valid qnodes."
}
}
},
"overlay_connect_knodes": {
"in_arax": true,
"parameters": {}
},
"overlay_fisher_exact_test": {
"in_arax": true,
"parameters": {
"subject_qnode_key": {
"is_required": true,
"type": "string",
"examples": "n1",
"description": "A specific subject query node id."
},
"object_qnode_key": {
"is_required": true,
"type": "string",
"examples": "n2",
"description": "A specific object query node id."
},
"virtual_relation_label": {
"is_required": true,
"type": "string",
"examples": "f1",
"description": "An label to help identify the virtual edge."
},
"rel_edge_key": {
"is_required": false,
"type": "string",
"examples": "e01",
"description": "A specific Qedge id connected to both subject nodes and object nodes in message KG (optional, otherwise all edges connected to both subject nodes and object nodes in message KG are considered)."
}
}
},
"restate": {
"in_arax": false,
"parameters": {}
},
"score": {
"in_arax": true,
"parameters": {}
},
"sort_results": {
"in_arax": false,
"parameters": {}
},
"sort_results_edge_attribute": {
"in_arax": true,
"parameters": {
"edge_attribute": {
"is_required": true,
"type": "string",
"examples": "normalized_google_distance",
"description": "The name of the edge attribute to order by."
},
"ascending_or_descending": {
"is_required": true,
"type": "string",
"enum": [
"ascending",
"descending"
],
"description": "Indicates whether results should be sorted in ascending or descending order."
},
"qedge_keys": {
"is_required": false,
"type": "array",
"examples": [
"e01"
],
"description": "This indicates if you only want to consider edges with specific edge_keys. If not provided or empty, all edges will be looked at."
}
}
},
"sort_results_node_attribute": {
"in_arax": true,
"parameters": {
"node_attribute": {
"is_required": true,
"type": "string",
"examples": "normalized_google_distance",
"description": "The name of the node attribute to order by."
},
"ascending_or_descending": {
"is_required": true,
"type": "string",
"enum": [
"ascending",
"descending"
],
"description": "Indicates whether results should be sorted in ascending or descending order."
},
"qnode_keys": {
"is_required": false,
"type": "array",
"examples": [
"e01"
],
"description": "This indicates if you only want to consider nodes with specific node_keys. If not provided or empty, all nodes will be looked at."
}
}
},
"sort_results_score": {
"in_arax": true,
"parameters": {
"ascending_or_descending": {
"is_required": true,
"type": "string",
"enum": [
"ascending",
"descending"
],
"description": "Indicates whether results should be sorted in ascending or descending order."
}
}
}
}