apb-export 0.2.2__py3-none-any.whl

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 (39) hide show
  1. apb_export/__init__.py +1 -0
  2. apb_export/api.py +98 -0
  3. apb_export/cli.py +562 -0
  4. apb_export/computed.py +135 -0
  5. apb_export/engine.py +717 -0
  6. apb_export/export_rules/__init__.py +0 -0
  7. apb_export/export_rules/documents/_schema/document.schema.json +1280 -0
  8. apb_export/export_rules/documents/_schema/rule.schema.json +1454 -0
  9. apb_export/export_rules/documents/alphapepttools/v0_4/rules.json +98 -0
  10. apb_export/export_rules/documents/explorede/v1_0/rules.json +197 -0
  11. apb_export/export_rules/documents/msmu/v0_4/rules.json +127 -0
  12. apb_export/export_rules/documents/msstats/v4_20/rules.json +66 -0
  13. apb_export/export_rules/documents/perseus/v2/rules.json +59 -0
  14. apb_export/export_rules/documents/prolfqua/v2_11/rules.json +223 -0
  15. apb_export/export_rules/documents/proteopy/v0_1/rules.json +53 -0
  16. apb_export/export_rules/documents/proteopy_ion/v0_1/rules.json +62 -0
  17. apb_export/export_rules/documents/qfeatures/v1_22/rules.json +98 -0
  18. apb_export/export_rules/documents/qpx/v1_1/rules.json +110 -0
  19. apb_export/export_rules/layout.py +60 -0
  20. apb_export/export_rules/loader.py +208 -0
  21. apb_export/export_rules/schema.py +502 -0
  22. apb_export/export_rules/schema_artifact.py +40 -0
  23. apb_export/long_table.py +75 -0
  24. apb_export/outputs.py +90 -0
  25. apb_export/perseus_table.py +100 -0
  26. apb_export/py.typed +1 -0
  27. apb_export/qpx/LICENSE.qpx +81 -0
  28. apb_export/qpx/__init__.py +0 -0
  29. apb_export/qpx/output.py +215 -0
  30. apb_export/qpx/schema.json +662 -0
  31. apb_export/qpx/schema.py +32 -0
  32. apb_export/rows.py +72 -0
  33. apb_export/sources.py +415 -0
  34. apb_export-0.2.2.dist-info/METADATA +159 -0
  35. apb_export-0.2.2.dist-info/RECORD +39 -0
  36. apb_export-0.2.2.dist-info/WHEEL +4 -0
  37. apb_export-0.2.2.dist-info/entry_points.txt +3 -0
  38. apb_export-0.2.2.dist-info/licenses/LICENSE +21 -0
  39. apb_export-0.2.2.dist-info/licenses/src/apb_export/qpx/LICENSE.qpx +81 -0
@@ -0,0 +1,1454 @@
1
+ {
2
+ "$defs": {
3
+ "AccessionSyntax": {
4
+ "additionalProperties": false,
5
+ "description": "How a target writes protein-group members, like apb2's ``sequence_syntax``.",
6
+ "properties": {
7
+ "separator": {
8
+ "minLength": 1,
9
+ "title": "Separator",
10
+ "type": "string"
11
+ },
12
+ "contaminant_markers": {
13
+ "items": {
14
+ "type": "string"
15
+ },
16
+ "title": "Contaminant Markers",
17
+ "type": "array"
18
+ },
19
+ "contaminant_prefix": {
20
+ "default": "",
21
+ "title": "Contaminant Prefix",
22
+ "type": "string"
23
+ }
24
+ },
25
+ "required": [
26
+ "separator"
27
+ ],
28
+ "title": "AccessionSyntax",
29
+ "type": "object"
30
+ },
31
+ "Accessions": {
32
+ "additionalProperties": false,
33
+ "description": "Protein-group members rewritten by a named ``accession_syntax``.",
34
+ "properties": {
35
+ "name": {
36
+ "description": "The target field; apb2's rules name APB fields.",
37
+ "minLength": 1,
38
+ "title": "Name",
39
+ "type": "string"
40
+ },
41
+ "type": {
42
+ "$ref": "#/$defs/ColumnType",
43
+ "default": "string"
44
+ },
45
+ "width": {
46
+ "anyOf": [
47
+ {
48
+ "$ref": "#/$defs/FloatWidth"
49
+ },
50
+ {
51
+ "type": "null"
52
+ }
53
+ ],
54
+ "default": null,
55
+ "description": "Float width of a number entry; 64 when omitted."
56
+ },
57
+ "required": {
58
+ "default": true,
59
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
60
+ "title": "Required",
61
+ "type": "boolean"
62
+ },
63
+ "fill_value": {
64
+ "$ref": "#/$defs/Scalar",
65
+ "default": null,
66
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
67
+ },
68
+ "drop_missing": {
69
+ "default": false,
70
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
71
+ "title": "Drop Missing",
72
+ "type": "boolean"
73
+ },
74
+ "source": {
75
+ "$ref": "#/$defs/Reference",
76
+ "description": "The APB field; apb2's rules name a vendor column here."
77
+ },
78
+ "fallback": {
79
+ "description": "Tried in order when the result lacks the source; one that answers is logged.",
80
+ "items": {
81
+ "$ref": "#/$defs/Reference"
82
+ },
83
+ "title": "Fallback",
84
+ "type": "array"
85
+ },
86
+ "how": {
87
+ "const": "accessions",
88
+ "title": "How",
89
+ "type": "string"
90
+ },
91
+ "syntax": {
92
+ "minLength": 1,
93
+ "title": "Syntax",
94
+ "type": "string"
95
+ }
96
+ },
97
+ "required": [
98
+ "name",
99
+ "source",
100
+ "how",
101
+ "syntax"
102
+ ],
103
+ "title": "Accessions",
104
+ "type": "object"
105
+ },
106
+ "AllValues": {
107
+ "additionalProperties": false,
108
+ "description": "Every obs annotation column the APB level carries, each under its own name unless a\nrename matches it.",
109
+ "properties": {
110
+ "name": {
111
+ "minLength": 1,
112
+ "title": "Name",
113
+ "type": "string"
114
+ },
115
+ "how": {
116
+ "const": "all_values",
117
+ "title": "How",
118
+ "type": "string"
119
+ },
120
+ "rename": {
121
+ "description": "Tried in order; the first whose pattern matches a column renames it.",
122
+ "items": {
123
+ "$ref": "#/$defs/Rename"
124
+ },
125
+ "title": "Rename",
126
+ "type": "array"
127
+ }
128
+ },
129
+ "required": [
130
+ "name",
131
+ "how"
132
+ ],
133
+ "title": "AllValues",
134
+ "type": "object"
135
+ },
136
+ "AnnotationMap": {
137
+ "additionalProperties": false,
138
+ "description": "Every obs annotation column mapped to its own name; ``uns`` only.",
139
+ "properties": {
140
+ "name": {
141
+ "description": "The target field; apb2's rules name APB fields.",
142
+ "minLength": 1,
143
+ "title": "Name",
144
+ "type": "string"
145
+ },
146
+ "type": {
147
+ "$ref": "#/$defs/ColumnType",
148
+ "default": "string"
149
+ },
150
+ "width": {
151
+ "anyOf": [
152
+ {
153
+ "$ref": "#/$defs/FloatWidth"
154
+ },
155
+ {
156
+ "type": "null"
157
+ }
158
+ ],
159
+ "default": null,
160
+ "description": "Float width of a number entry; 64 when omitted."
161
+ },
162
+ "required": {
163
+ "default": true,
164
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
165
+ "title": "Required",
166
+ "type": "boolean"
167
+ },
168
+ "fill_value": {
169
+ "$ref": "#/$defs/Scalar",
170
+ "default": null,
171
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
172
+ },
173
+ "drop_missing": {
174
+ "default": false,
175
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
176
+ "title": "Drop Missing",
177
+ "type": "boolean"
178
+ },
179
+ "how": {
180
+ "const": "annotation_map",
181
+ "title": "How",
182
+ "type": "string"
183
+ }
184
+ },
185
+ "required": [
186
+ "name",
187
+ "how"
188
+ ],
189
+ "title": "AnnotationMap",
190
+ "type": "object"
191
+ },
192
+ "Axis": {
193
+ "additionalProperties": false,
194
+ "description": "The entries that become the target's observation and variable index.",
195
+ "properties": {
196
+ "obs_key": {
197
+ "minLength": 1,
198
+ "title": "Obs Key",
199
+ "type": "string"
200
+ },
201
+ "var_key": {
202
+ "minLength": 1,
203
+ "title": "Var Key",
204
+ "type": "string"
205
+ }
206
+ },
207
+ "required": [
208
+ "obs_key",
209
+ "var_key"
210
+ ],
211
+ "title": "Axis",
212
+ "type": "object"
213
+ },
214
+ "AxisSource": {
215
+ "additionalProperties": false,
216
+ "description": "The level's observation or variable key column; a composite key is refused.",
217
+ "properties": {
218
+ "axis": {
219
+ "enum": [
220
+ "obs_key",
221
+ "var_key"
222
+ ],
223
+ "title": "Axis",
224
+ "type": "string"
225
+ }
226
+ },
227
+ "required": [
228
+ "axis"
229
+ ],
230
+ "title": "AxisSource",
231
+ "type": "object"
232
+ },
233
+ "CatalogueLayer": {
234
+ "additionalProperties": false,
235
+ "description": "A catalogued layer: ``{\"catalog\": \"confidence_alpha\", \"layers\": \"q_value\"}``.",
236
+ "properties": {
237
+ "catalog": {
238
+ "minLength": 1,
239
+ "title": "Catalog",
240
+ "type": "string"
241
+ },
242
+ "qualifiers": {
243
+ "additionalProperties": {
244
+ "type": "string"
245
+ },
246
+ "description": "Further qualifiers of the request, besides those its key fixes, such as a retention time's unit.",
247
+ "title": "Qualifiers",
248
+ "type": "object"
249
+ },
250
+ "from_level": {
251
+ "anyOf": [
252
+ {
253
+ "const": "protein",
254
+ "type": "string"
255
+ },
256
+ {
257
+ "type": "null"
258
+ }
259
+ ],
260
+ "default": null,
261
+ "description": "Read the field from this level through each variable's protein_assignment, as a layer: a cell takes its protein group's value in its run; a var column's value repeats in every run. The assignment names its group whole, or else the group it leads, as MaxQuant's razor protein does. A group the level lacks reads as missing.",
262
+ "title": "From Level"
263
+ },
264
+ "accept": {
265
+ "default": "present",
266
+ "description": "nonzero rejects a layer or var column holding no finite nonzero value, such as DIA-NN's library q-value without match-between-runs.",
267
+ "enum": [
268
+ "present",
269
+ "nonzero"
270
+ ],
271
+ "title": "Accept",
272
+ "type": "string"
273
+ },
274
+ "layers": {
275
+ "description": "The set's key.",
276
+ "minLength": 1,
277
+ "title": "Layers",
278
+ "type": "string"
279
+ }
280
+ },
281
+ "required": [
282
+ "catalog",
283
+ "layers"
284
+ ],
285
+ "title": "CatalogueLayer",
286
+ "type": "object"
287
+ },
288
+ "CatalogueObs": {
289
+ "additionalProperties": false,
290
+ "description": "A catalogued obs column: ``{\"catalog\": \"obs_annotation_alpha\", \"obs\": \"group\"}``.",
291
+ "properties": {
292
+ "catalog": {
293
+ "minLength": 1,
294
+ "title": "Catalog",
295
+ "type": "string"
296
+ },
297
+ "qualifiers": {
298
+ "additionalProperties": {
299
+ "type": "string"
300
+ },
301
+ "description": "Further qualifiers of the request, besides those its key fixes, such as a retention time's unit.",
302
+ "title": "Qualifiers",
303
+ "type": "object"
304
+ },
305
+ "obs": {
306
+ "description": "The set's key.",
307
+ "minLength": 1,
308
+ "title": "Obs",
309
+ "type": "string"
310
+ }
311
+ },
312
+ "required": [
313
+ "catalog",
314
+ "obs"
315
+ ],
316
+ "title": "CatalogueObs",
317
+ "type": "object"
318
+ },
319
+ "CatalogueVar": {
320
+ "additionalProperties": false,
321
+ "description": "A catalogued var column: ``{\"catalog\": \"apb_alpha\", \"var\": \"protein_assignment\"}``.",
322
+ "properties": {
323
+ "catalog": {
324
+ "minLength": 1,
325
+ "title": "Catalog",
326
+ "type": "string"
327
+ },
328
+ "qualifiers": {
329
+ "additionalProperties": {
330
+ "type": "string"
331
+ },
332
+ "description": "Further qualifiers of the request, besides those its key fixes, such as a retention time's unit.",
333
+ "title": "Qualifiers",
334
+ "type": "object"
335
+ },
336
+ "from_level": {
337
+ "anyOf": [
338
+ {
339
+ "const": "protein",
340
+ "type": "string"
341
+ },
342
+ {
343
+ "type": "null"
344
+ }
345
+ ],
346
+ "default": null,
347
+ "description": "Read the field from this level through each variable's protein_assignment, as a layer: a cell takes its protein group's value in its run; a var column's value repeats in every run. The assignment names its group whole, or else the group it leads, as MaxQuant's razor protein does. A group the level lacks reads as missing.",
348
+ "title": "From Level"
349
+ },
350
+ "accept": {
351
+ "default": "present",
352
+ "description": "nonzero rejects a layer or var column holding no finite nonzero value, such as DIA-NN's library q-value without match-between-runs.",
353
+ "enum": [
354
+ "present",
355
+ "nonzero"
356
+ ],
357
+ "title": "Accept",
358
+ "type": "string"
359
+ },
360
+ "var": {
361
+ "description": "The set's key.",
362
+ "minLength": 1,
363
+ "title": "Var",
364
+ "type": "string"
365
+ }
366
+ },
367
+ "required": [
368
+ "catalog",
369
+ "var"
370
+ ],
371
+ "title": "CatalogueVar",
372
+ "type": "object"
373
+ },
374
+ "ColumnEntry": {
375
+ "anyOf": [
376
+ {
377
+ "$ref": "#/$defs/SourcedEntry"
378
+ },
379
+ {
380
+ "$ref": "#/$defs/ComputedEntry"
381
+ }
382
+ ]
383
+ },
384
+ "ColumnType": {
385
+ "enum": [
386
+ "string",
387
+ "integer",
388
+ "number",
389
+ "boolean"
390
+ ],
391
+ "type": "string"
392
+ },
393
+ "Columns": {
394
+ "additionalProperties": false,
395
+ "description": "The target's observation and variable columns.",
396
+ "properties": {
397
+ "obs": {
398
+ "items": {
399
+ "anyOf": [
400
+ {
401
+ "$ref": "#/$defs/ColumnEntry"
402
+ },
403
+ {
404
+ "$ref": "#/$defs/AllValues"
405
+ }
406
+ ]
407
+ },
408
+ "title": "Obs",
409
+ "type": "array"
410
+ },
411
+ "var": {
412
+ "items": {
413
+ "$ref": "#/$defs/ColumnEntry"
414
+ },
415
+ "minItems": 1,
416
+ "title": "Var",
417
+ "type": "array"
418
+ }
419
+ },
420
+ "required": [
421
+ "var"
422
+ ],
423
+ "title": "Columns",
424
+ "type": "object"
425
+ },
426
+ "ComputedEntry": {
427
+ "discriminator": {
428
+ "mapping": {
429
+ "accessions": "#/$defs/Accessions",
430
+ "annotation_map": "#/$defs/AnnotationMap",
431
+ "constant": "#/$defs/Constant",
432
+ "contaminant": "#/$defs/Contaminant",
433
+ "join_nonempty": "#/$defs/JoinNonempty",
434
+ "layer_minimum": "#/$defs/LayerMinimum",
435
+ "lowercase": "#/$defs/Lowercase",
436
+ "proforma_charge": "#/$defs/ProformaCharge",
437
+ "sequence_length": "#/$defs/SequenceLength",
438
+ "short_name": "#/$defs/ShortName",
439
+ "single_accession": "#/$defs/SingleAccession"
440
+ },
441
+ "propertyName": "how"
442
+ },
443
+ "oneOf": [
444
+ {
445
+ "$ref": "#/$defs/Constant"
446
+ },
447
+ {
448
+ "$ref": "#/$defs/JoinNonempty"
449
+ },
450
+ {
451
+ "$ref": "#/$defs/ProformaCharge"
452
+ },
453
+ {
454
+ "$ref": "#/$defs/SequenceLength"
455
+ },
456
+ {
457
+ "$ref": "#/$defs/Accessions"
458
+ },
459
+ {
460
+ "$ref": "#/$defs/SingleAccession"
461
+ },
462
+ {
463
+ "$ref": "#/$defs/Contaminant"
464
+ },
465
+ {
466
+ "$ref": "#/$defs/Lowercase"
467
+ },
468
+ {
469
+ "$ref": "#/$defs/ShortName"
470
+ },
471
+ {
472
+ "$ref": "#/$defs/AnnotationMap"
473
+ },
474
+ {
475
+ "$ref": "#/$defs/LayerMinimum"
476
+ }
477
+ ]
478
+ },
479
+ "Constant": {
480
+ "additionalProperties": false,
481
+ "description": "The same value everywhere.",
482
+ "properties": {
483
+ "name": {
484
+ "description": "The target field; apb2's rules name APB fields.",
485
+ "minLength": 1,
486
+ "title": "Name",
487
+ "type": "string"
488
+ },
489
+ "type": {
490
+ "$ref": "#/$defs/ColumnType",
491
+ "default": "string"
492
+ },
493
+ "width": {
494
+ "anyOf": [
495
+ {
496
+ "$ref": "#/$defs/FloatWidth"
497
+ },
498
+ {
499
+ "type": "null"
500
+ }
501
+ ],
502
+ "default": null,
503
+ "description": "Float width of a number entry; 64 when omitted."
504
+ },
505
+ "required": {
506
+ "default": true,
507
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
508
+ "title": "Required",
509
+ "type": "boolean"
510
+ },
511
+ "fill_value": {
512
+ "$ref": "#/$defs/Scalar",
513
+ "default": null,
514
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
515
+ },
516
+ "drop_missing": {
517
+ "default": false,
518
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
519
+ "title": "Drop Missing",
520
+ "type": "boolean"
521
+ },
522
+ "how": {
523
+ "const": "constant",
524
+ "title": "How",
525
+ "type": "string"
526
+ },
527
+ "value": {
528
+ "$ref": "#/$defs/JsonValue",
529
+ "description": "Any JSON in uns; a scalar in columns."
530
+ }
531
+ },
532
+ "required": [
533
+ "name",
534
+ "how",
535
+ "value"
536
+ ],
537
+ "title": "Constant",
538
+ "type": "object"
539
+ },
540
+ "Contaminant": {
541
+ "additionalProperties": false,
542
+ "description": "Whether the row is a contaminant: apb2's ``apb_Contaminant``, the contaminants the\nsoftware flags or adds itself, or apb-fasta's FASTA contaminant match where the result\nwas FASTA-checked.",
543
+ "properties": {
544
+ "name": {
545
+ "description": "The target field; apb2's rules name APB fields.",
546
+ "minLength": 1,
547
+ "title": "Name",
548
+ "type": "string"
549
+ },
550
+ "type": {
551
+ "$ref": "#/$defs/ColumnType",
552
+ "default": "string"
553
+ },
554
+ "width": {
555
+ "anyOf": [
556
+ {
557
+ "$ref": "#/$defs/FloatWidth"
558
+ },
559
+ {
560
+ "type": "null"
561
+ }
562
+ ],
563
+ "default": null,
564
+ "description": "Float width of a number entry; 64 when omitted."
565
+ },
566
+ "required": {
567
+ "default": true,
568
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
569
+ "title": "Required",
570
+ "type": "boolean"
571
+ },
572
+ "fill_value": {
573
+ "$ref": "#/$defs/Scalar",
574
+ "default": null,
575
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
576
+ },
577
+ "drop_missing": {
578
+ "default": false,
579
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
580
+ "title": "Drop Missing",
581
+ "type": "boolean"
582
+ },
583
+ "how": {
584
+ "const": "contaminant",
585
+ "title": "How",
586
+ "type": "string"
587
+ }
588
+ },
589
+ "required": [
590
+ "name",
591
+ "how"
592
+ ],
593
+ "title": "Contaminant",
594
+ "type": "object"
595
+ },
596
+ "FloatWidth": {
597
+ "enum": [
598
+ 32,
599
+ 64
600
+ ],
601
+ "type": "integer"
602
+ },
603
+ "JoinNonempty": {
604
+ "additionalProperties": false,
605
+ "description": "Non-empty input values joined with a separator, as apb2's ``join_nonempty``.",
606
+ "properties": {
607
+ "name": {
608
+ "description": "The target field; apb2's rules name APB fields.",
609
+ "minLength": 1,
610
+ "title": "Name",
611
+ "type": "string"
612
+ },
613
+ "type": {
614
+ "$ref": "#/$defs/ColumnType",
615
+ "default": "string"
616
+ },
617
+ "width": {
618
+ "anyOf": [
619
+ {
620
+ "$ref": "#/$defs/FloatWidth"
621
+ },
622
+ {
623
+ "type": "null"
624
+ }
625
+ ],
626
+ "default": null,
627
+ "description": "Float width of a number entry; 64 when omitted."
628
+ },
629
+ "required": {
630
+ "default": true,
631
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
632
+ "title": "Required",
633
+ "type": "boolean"
634
+ },
635
+ "fill_value": {
636
+ "$ref": "#/$defs/Scalar",
637
+ "default": null,
638
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
639
+ },
640
+ "drop_missing": {
641
+ "default": false,
642
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
643
+ "title": "Drop Missing",
644
+ "type": "boolean"
645
+ },
646
+ "how": {
647
+ "const": "join_nonempty",
648
+ "title": "How",
649
+ "type": "string"
650
+ },
651
+ "inputs": {
652
+ "description": "APB references, not entries.",
653
+ "items": {
654
+ "$ref": "#/$defs/Reference"
655
+ },
656
+ "minItems": 2,
657
+ "title": "Inputs",
658
+ "type": "array"
659
+ },
660
+ "separator": {
661
+ "minLength": 1,
662
+ "title": "Separator",
663
+ "type": "string"
664
+ }
665
+ },
666
+ "required": [
667
+ "name",
668
+ "how",
669
+ "inputs",
670
+ "separator"
671
+ ],
672
+ "title": "JoinNonempty",
673
+ "type": "object"
674
+ },
675
+ "JsonValue": {},
676
+ "LayerEntry": {
677
+ "additionalProperties": false,
678
+ "description": "A target matrix read from one APB layer.",
679
+ "properties": {
680
+ "name": {
681
+ "minLength": 1,
682
+ "title": "Name",
683
+ "type": "string"
684
+ },
685
+ "source": {
686
+ "$ref": "#/$defs/Reference",
687
+ "description": "An APB layer: the primary layer or a catalogued one."
688
+ },
689
+ "fallback": {
690
+ "description": "Tried in order when the result lacks the source; one that answers is logged.",
691
+ "items": {
692
+ "$ref": "#/$defs/Reference"
693
+ },
694
+ "title": "Fallback",
695
+ "type": "array"
696
+ },
697
+ "width": {
698
+ "$ref": "#/$defs/FloatWidth",
699
+ "default": 64
700
+ },
701
+ "required": {
702
+ "default": true,
703
+ "description": "An absent source is an error; when false, the layer is left out.",
704
+ "title": "Required",
705
+ "type": "boolean"
706
+ },
707
+ "missing_values": {
708
+ "description": "APB values treated as absent; apb2 lists vendor values here.",
709
+ "items": {
710
+ "type": "number"
711
+ },
712
+ "title": "Missing Values",
713
+ "type": "array"
714
+ },
715
+ "name_by_key": {
716
+ "additionalProperties": {
717
+ "type": "string"
718
+ },
719
+ "description": "The written name per abundance key, or per qualifier=value pair, of the resolved layer, as Perseus names MaxLFQ values (aggregation=maxlfq) LFQ intensity; the first label the layer matches wins, and a layer matching none keeps name.",
720
+ "title": "Name By Key",
721
+ "type": "object"
722
+ },
723
+ "transform": {
724
+ "anyOf": [
725
+ {
726
+ "const": "log2",
727
+ "type": "string"
728
+ },
729
+ {
730
+ "type": "null"
731
+ }
732
+ ],
733
+ "default": null,
734
+ "description": "Applied after missing_values: log2, a value that is not positive becoming missing.",
735
+ "title": "Transform"
736
+ }
737
+ },
738
+ "required": [
739
+ "name",
740
+ "source"
741
+ ],
742
+ "title": "LayerEntry",
743
+ "type": "object"
744
+ },
745
+ "LayerMinimum": {
746
+ "additionalProperties": false,
747
+ "description": "An exported layer's smallest value per variable across observations, missing values left\nout, as one q-value per ion from a per-run layer.",
748
+ "properties": {
749
+ "name": {
750
+ "description": "The target field; apb2's rules name APB fields.",
751
+ "minLength": 1,
752
+ "title": "Name",
753
+ "type": "string"
754
+ },
755
+ "type": {
756
+ "$ref": "#/$defs/ColumnType",
757
+ "default": "string"
758
+ },
759
+ "width": {
760
+ "anyOf": [
761
+ {
762
+ "$ref": "#/$defs/FloatWidth"
763
+ },
764
+ {
765
+ "type": "null"
766
+ }
767
+ ],
768
+ "default": null,
769
+ "description": "Float width of a number entry; 64 when omitted."
770
+ },
771
+ "required": {
772
+ "default": true,
773
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
774
+ "title": "Required",
775
+ "type": "boolean"
776
+ },
777
+ "fill_value": {
778
+ "$ref": "#/$defs/Scalar",
779
+ "default": null,
780
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
781
+ },
782
+ "drop_missing": {
783
+ "default": false,
784
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
785
+ "title": "Drop Missing",
786
+ "type": "boolean"
787
+ },
788
+ "how": {
789
+ "const": "layer_minimum",
790
+ "title": "How",
791
+ "type": "string"
792
+ },
793
+ "layer": {
794
+ "description": "A measurement layer of the same level.",
795
+ "minLength": 1,
796
+ "title": "Layer",
797
+ "type": "string"
798
+ }
799
+ },
800
+ "required": [
801
+ "name",
802
+ "how",
803
+ "layer"
804
+ ],
805
+ "title": "LayerMinimum",
806
+ "type": "object"
807
+ },
808
+ "Lowercase": {
809
+ "additionalProperties": false,
810
+ "description": "The input text in lower case.",
811
+ "properties": {
812
+ "name": {
813
+ "description": "The target field; apb2's rules name APB fields.",
814
+ "minLength": 1,
815
+ "title": "Name",
816
+ "type": "string"
817
+ },
818
+ "type": {
819
+ "$ref": "#/$defs/ColumnType",
820
+ "default": "string"
821
+ },
822
+ "width": {
823
+ "anyOf": [
824
+ {
825
+ "$ref": "#/$defs/FloatWidth"
826
+ },
827
+ {
828
+ "type": "null"
829
+ }
830
+ ],
831
+ "default": null,
832
+ "description": "Float width of a number entry; 64 when omitted."
833
+ },
834
+ "required": {
835
+ "default": true,
836
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
837
+ "title": "Required",
838
+ "type": "boolean"
839
+ },
840
+ "fill_value": {
841
+ "$ref": "#/$defs/Scalar",
842
+ "default": null,
843
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
844
+ },
845
+ "drop_missing": {
846
+ "default": false,
847
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
848
+ "title": "Drop Missing",
849
+ "type": "boolean"
850
+ },
851
+ "source": {
852
+ "$ref": "#/$defs/Reference",
853
+ "description": "The APB field; apb2's rules name a vendor column here."
854
+ },
855
+ "fallback": {
856
+ "description": "Tried in order when the result lacks the source; one that answers is logged.",
857
+ "items": {
858
+ "$ref": "#/$defs/Reference"
859
+ },
860
+ "title": "Fallback",
861
+ "type": "array"
862
+ },
863
+ "how": {
864
+ "const": "lowercase",
865
+ "title": "How",
866
+ "type": "string"
867
+ }
868
+ },
869
+ "required": [
870
+ "name",
871
+ "source",
872
+ "how"
873
+ ],
874
+ "title": "Lowercase",
875
+ "type": "object"
876
+ },
877
+ "MeasurementSource": {
878
+ "additionalProperties": false,
879
+ "description": "The level's primary layer, or the abundance layer the caller picks.",
880
+ "properties": {
881
+ "measurements": {
882
+ "const": "primary_layer",
883
+ "title": "Measurements",
884
+ "type": "string"
885
+ }
886
+ },
887
+ "required": [
888
+ "measurements"
889
+ ],
890
+ "title": "MeasurementSource",
891
+ "type": "object"
892
+ },
893
+ "Measurements": {
894
+ "additionalProperties": false,
895
+ "description": "The target's matrices; the primary layer becomes X.",
896
+ "properties": {
897
+ "primary_layer": {
898
+ "title": "Primary Layer",
899
+ "type": "string"
900
+ },
901
+ "layers": {
902
+ "items": {
903
+ "$ref": "#/$defs/LayerEntry"
904
+ },
905
+ "minItems": 1,
906
+ "title": "Layers",
907
+ "type": "array"
908
+ }
909
+ },
910
+ "required": [
911
+ "primary_layer",
912
+ "layers"
913
+ ],
914
+ "title": "Measurements",
915
+ "type": "object"
916
+ },
917
+ "ObsSource": {
918
+ "additionalProperties": false,
919
+ "description": "An observation annotation column, by its name in the result, such as an SDRF column\napb2's sample annotation added; absent when the result was not annotated with it.",
920
+ "properties": {
921
+ "obs": {
922
+ "minLength": 1,
923
+ "title": "Obs",
924
+ "type": "string"
925
+ }
926
+ },
927
+ "required": [
928
+ "obs"
929
+ ],
930
+ "title": "ObsSource",
931
+ "type": "object"
932
+ },
933
+ "ProformaCharge": {
934
+ "additionalProperties": false,
935
+ "description": "The charge of a ProForma ion, ``SEQ/2`` giving 2.",
936
+ "properties": {
937
+ "name": {
938
+ "description": "The target field; apb2's rules name APB fields.",
939
+ "minLength": 1,
940
+ "title": "Name",
941
+ "type": "string"
942
+ },
943
+ "type": {
944
+ "$ref": "#/$defs/ColumnType",
945
+ "default": "string"
946
+ },
947
+ "width": {
948
+ "anyOf": [
949
+ {
950
+ "$ref": "#/$defs/FloatWidth"
951
+ },
952
+ {
953
+ "type": "null"
954
+ }
955
+ ],
956
+ "default": null,
957
+ "description": "Float width of a number entry; 64 when omitted."
958
+ },
959
+ "required": {
960
+ "default": true,
961
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
962
+ "title": "Required",
963
+ "type": "boolean"
964
+ },
965
+ "fill_value": {
966
+ "$ref": "#/$defs/Scalar",
967
+ "default": null,
968
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
969
+ },
970
+ "drop_missing": {
971
+ "default": false,
972
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
973
+ "title": "Drop Missing",
974
+ "type": "boolean"
975
+ },
976
+ "source": {
977
+ "$ref": "#/$defs/Reference",
978
+ "description": "The APB field; apb2's rules name a vendor column here."
979
+ },
980
+ "fallback": {
981
+ "description": "Tried in order when the result lacks the source; one that answers is logged.",
982
+ "items": {
983
+ "$ref": "#/$defs/Reference"
984
+ },
985
+ "title": "Fallback",
986
+ "type": "array"
987
+ },
988
+ "how": {
989
+ "const": "proforma_charge",
990
+ "title": "How",
991
+ "type": "string"
992
+ }
993
+ },
994
+ "required": [
995
+ "name",
996
+ "source",
997
+ "how"
998
+ ],
999
+ "title": "ProformaCharge",
1000
+ "type": "object"
1001
+ },
1002
+ "Reference": {
1003
+ "anyOf": [
1004
+ {
1005
+ "$ref": "#/$defs/AxisSource"
1006
+ },
1007
+ {
1008
+ "$ref": "#/$defs/MeasurementSource"
1009
+ },
1010
+ {
1011
+ "$ref": "#/$defs/RuleSource"
1012
+ },
1013
+ {
1014
+ "$ref": "#/$defs/CatalogueLayer"
1015
+ },
1016
+ {
1017
+ "$ref": "#/$defs/CatalogueVar"
1018
+ },
1019
+ {
1020
+ "$ref": "#/$defs/CatalogueObs"
1021
+ },
1022
+ {
1023
+ "$ref": "#/$defs/ObsSource"
1024
+ }
1025
+ ]
1026
+ },
1027
+ "Rename": {
1028
+ "additionalProperties": false,
1029
+ "description": "An annotation column whose name matches ``pattern`` is written as text with sorted\ncategories, named as ``re.sub(pattern, replacement, name)`` gives it.",
1030
+ "properties": {
1031
+ "pattern": {
1032
+ "description": "A Python regular expression.",
1033
+ "minLength": 1,
1034
+ "title": "Pattern",
1035
+ "type": "string"
1036
+ },
1037
+ "replacement": {
1038
+ "minLength": 1,
1039
+ "title": "Replacement",
1040
+ "type": "string"
1041
+ },
1042
+ "identifier": {
1043
+ "default": false,
1044
+ "description": "The new name in lower case, each character outside a-z, 0-9 and _ becoming _.",
1045
+ "title": "Identifier",
1046
+ "type": "boolean"
1047
+ }
1048
+ },
1049
+ "required": [
1050
+ "pattern",
1051
+ "replacement"
1052
+ ],
1053
+ "title": "Rename",
1054
+ "type": "object"
1055
+ },
1056
+ "RuleSource": {
1057
+ "additionalProperties": false,
1058
+ "description": "A top-level field of the apb2 rule stored with the level, such as ``software_name``.",
1059
+ "properties": {
1060
+ "rule": {
1061
+ "minLength": 1,
1062
+ "title": "Rule",
1063
+ "type": "string"
1064
+ }
1065
+ },
1066
+ "required": [
1067
+ "rule"
1068
+ ],
1069
+ "title": "RuleSource",
1070
+ "type": "object"
1071
+ },
1072
+ "Scalar": {
1073
+ "anyOf": [
1074
+ {
1075
+ "type": "string"
1076
+ },
1077
+ {
1078
+ "type": "integer"
1079
+ },
1080
+ {
1081
+ "type": "number"
1082
+ },
1083
+ {
1084
+ "type": "boolean"
1085
+ },
1086
+ {
1087
+ "type": "null"
1088
+ }
1089
+ ]
1090
+ },
1091
+ "SequenceLength": {
1092
+ "additionalProperties": false,
1093
+ "description": "The number of characters of a sequence.",
1094
+ "properties": {
1095
+ "name": {
1096
+ "description": "The target field; apb2's rules name APB fields.",
1097
+ "minLength": 1,
1098
+ "title": "Name",
1099
+ "type": "string"
1100
+ },
1101
+ "type": {
1102
+ "$ref": "#/$defs/ColumnType",
1103
+ "default": "string"
1104
+ },
1105
+ "width": {
1106
+ "anyOf": [
1107
+ {
1108
+ "$ref": "#/$defs/FloatWidth"
1109
+ },
1110
+ {
1111
+ "type": "null"
1112
+ }
1113
+ ],
1114
+ "default": null,
1115
+ "description": "Float width of a number entry; 64 when omitted."
1116
+ },
1117
+ "required": {
1118
+ "default": true,
1119
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
1120
+ "title": "Required",
1121
+ "type": "boolean"
1122
+ },
1123
+ "fill_value": {
1124
+ "$ref": "#/$defs/Scalar",
1125
+ "default": null,
1126
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
1127
+ },
1128
+ "drop_missing": {
1129
+ "default": false,
1130
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
1131
+ "title": "Drop Missing",
1132
+ "type": "boolean"
1133
+ },
1134
+ "source": {
1135
+ "$ref": "#/$defs/Reference",
1136
+ "description": "The APB field; apb2's rules name a vendor column here."
1137
+ },
1138
+ "fallback": {
1139
+ "description": "Tried in order when the result lacks the source; one that answers is logged.",
1140
+ "items": {
1141
+ "$ref": "#/$defs/Reference"
1142
+ },
1143
+ "title": "Fallback",
1144
+ "type": "array"
1145
+ },
1146
+ "how": {
1147
+ "const": "sequence_length",
1148
+ "title": "How",
1149
+ "type": "string"
1150
+ }
1151
+ },
1152
+ "required": [
1153
+ "name",
1154
+ "source",
1155
+ "how"
1156
+ ],
1157
+ "title": "SequenceLength",
1158
+ "type": "object"
1159
+ },
1160
+ "ShortName": {
1161
+ "additionalProperties": false,
1162
+ "description": "Per row, the first input holding a non-empty value, cut to its first ``separator``\nmember and, for a ``db|ACC|NAME`` member, to ``NAME``; ``append`` follows after ``_``.\n\nAn input the result does not carry, such as a FASTA column without a FASTA check, is passed\nover; ``append`` is required.",
1163
+ "properties": {
1164
+ "name": {
1165
+ "description": "The target field; apb2's rules name APB fields.",
1166
+ "minLength": 1,
1167
+ "title": "Name",
1168
+ "type": "string"
1169
+ },
1170
+ "type": {
1171
+ "$ref": "#/$defs/ColumnType",
1172
+ "default": "string"
1173
+ },
1174
+ "width": {
1175
+ "anyOf": [
1176
+ {
1177
+ "$ref": "#/$defs/FloatWidth"
1178
+ },
1179
+ {
1180
+ "type": "null"
1181
+ }
1182
+ ],
1183
+ "default": null,
1184
+ "description": "Float width of a number entry; 64 when omitted."
1185
+ },
1186
+ "required": {
1187
+ "default": true,
1188
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
1189
+ "title": "Required",
1190
+ "type": "boolean"
1191
+ },
1192
+ "fill_value": {
1193
+ "$ref": "#/$defs/Scalar",
1194
+ "default": null,
1195
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
1196
+ },
1197
+ "drop_missing": {
1198
+ "default": false,
1199
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
1200
+ "title": "Drop Missing",
1201
+ "type": "boolean"
1202
+ },
1203
+ "how": {
1204
+ "const": "short_name",
1205
+ "title": "How",
1206
+ "type": "string"
1207
+ },
1208
+ "inputs": {
1209
+ "description": "Candidates per row, in order.",
1210
+ "items": {
1211
+ "$ref": "#/$defs/Reference"
1212
+ },
1213
+ "minItems": 1,
1214
+ "title": "Inputs",
1215
+ "type": "array"
1216
+ },
1217
+ "separator": {
1218
+ "default": ";",
1219
+ "description": "Between group members.",
1220
+ "minLength": 1,
1221
+ "title": "Separator",
1222
+ "type": "string"
1223
+ },
1224
+ "append": {
1225
+ "anyOf": [
1226
+ {
1227
+ "$ref": "#/$defs/Reference"
1228
+ },
1229
+ {
1230
+ "type": "null"
1231
+ }
1232
+ ],
1233
+ "default": null
1234
+ }
1235
+ },
1236
+ "required": [
1237
+ "name",
1238
+ "how",
1239
+ "inputs"
1240
+ ],
1241
+ "title": "ShortName",
1242
+ "type": "object"
1243
+ },
1244
+ "SingleAccession": {
1245
+ "additionalProperties": false,
1246
+ "description": "The accession a feature names when its protein list holds exactly one; otherwise missing.\n\nProteoPy's peptide-level data takes one protein per feature; with ``drop_missing`` the\nfeatures naming several proteins are left out, as ProteoPy's own DIA-NN reader does.",
1247
+ "properties": {
1248
+ "name": {
1249
+ "description": "The target field; apb2's rules name APB fields.",
1250
+ "minLength": 1,
1251
+ "title": "Name",
1252
+ "type": "string"
1253
+ },
1254
+ "type": {
1255
+ "$ref": "#/$defs/ColumnType",
1256
+ "default": "string"
1257
+ },
1258
+ "width": {
1259
+ "anyOf": [
1260
+ {
1261
+ "$ref": "#/$defs/FloatWidth"
1262
+ },
1263
+ {
1264
+ "type": "null"
1265
+ }
1266
+ ],
1267
+ "default": null,
1268
+ "description": "Float width of a number entry; 64 when omitted."
1269
+ },
1270
+ "required": {
1271
+ "default": true,
1272
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
1273
+ "title": "Required",
1274
+ "type": "boolean"
1275
+ },
1276
+ "fill_value": {
1277
+ "$ref": "#/$defs/Scalar",
1278
+ "default": null,
1279
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
1280
+ },
1281
+ "drop_missing": {
1282
+ "default": false,
1283
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
1284
+ "title": "Drop Missing",
1285
+ "type": "boolean"
1286
+ },
1287
+ "source": {
1288
+ "$ref": "#/$defs/Reference",
1289
+ "description": "The APB field; apb2's rules name a vendor column here."
1290
+ },
1291
+ "fallback": {
1292
+ "description": "Tried in order when the result lacks the source; one that answers is logged.",
1293
+ "items": {
1294
+ "$ref": "#/$defs/Reference"
1295
+ },
1296
+ "title": "Fallback",
1297
+ "type": "array"
1298
+ },
1299
+ "how": {
1300
+ "const": "single_accession",
1301
+ "title": "How",
1302
+ "type": "string"
1303
+ },
1304
+ "separator": {
1305
+ "default": ";",
1306
+ "description": "The list's separator.",
1307
+ "minLength": 1,
1308
+ "title": "Separator",
1309
+ "type": "string"
1310
+ }
1311
+ },
1312
+ "required": [
1313
+ "name",
1314
+ "source",
1315
+ "how"
1316
+ ],
1317
+ "title": "SingleAccession",
1318
+ "type": "object"
1319
+ },
1320
+ "SourcedEntry": {
1321
+ "additionalProperties": false,
1322
+ "description": "A target field read from one APB source.",
1323
+ "properties": {
1324
+ "name": {
1325
+ "description": "The target field; apb2's rules name APB fields.",
1326
+ "minLength": 1,
1327
+ "title": "Name",
1328
+ "type": "string"
1329
+ },
1330
+ "type": {
1331
+ "$ref": "#/$defs/ColumnType",
1332
+ "default": "string"
1333
+ },
1334
+ "width": {
1335
+ "anyOf": [
1336
+ {
1337
+ "$ref": "#/$defs/FloatWidth"
1338
+ },
1339
+ {
1340
+ "type": "null"
1341
+ }
1342
+ ],
1343
+ "default": null,
1344
+ "description": "Float width of a number entry; 64 when omitted."
1345
+ },
1346
+ "required": {
1347
+ "default": true,
1348
+ "description": "An absent source is an error; when false, the entry is skipped or filled.",
1349
+ "title": "Required",
1350
+ "type": "boolean"
1351
+ },
1352
+ "fill_value": {
1353
+ "$ref": "#/$defs/Scalar",
1354
+ "default": null,
1355
+ "description": "Written when an optional source is absent; \"NaN\" for numbers."
1356
+ },
1357
+ "drop_missing": {
1358
+ "default": false,
1359
+ "description": "A var entry: features whose value is missing or empty are left out and counted, as prolfquapp and msmu need a protein for every feature.",
1360
+ "title": "Drop Missing",
1361
+ "type": "boolean"
1362
+ },
1363
+ "source": {
1364
+ "$ref": "#/$defs/Reference",
1365
+ "description": "The APB field; apb2's rules name a vendor column here."
1366
+ },
1367
+ "fallback": {
1368
+ "description": "Tried in order when the result lacks the source; one that answers is logged.",
1369
+ "items": {
1370
+ "$ref": "#/$defs/Reference"
1371
+ },
1372
+ "title": "Fallback",
1373
+ "type": "array"
1374
+ }
1375
+ },
1376
+ "required": [
1377
+ "name",
1378
+ "source"
1379
+ ],
1380
+ "title": "SourcedEntry",
1381
+ "type": "object"
1382
+ }
1383
+ },
1384
+ "additionalProperties": false,
1385
+ "description": "One level's export, base and level merged: apb2's effective rule, reversed.",
1386
+ "properties": {
1387
+ "modality": {
1388
+ "anyOf": [
1389
+ {
1390
+ "type": "string"
1391
+ },
1392
+ {
1393
+ "type": "null"
1394
+ }
1395
+ ],
1396
+ "default": null,
1397
+ "description": "The MuData modality it fills.",
1398
+ "title": "Modality"
1399
+ },
1400
+ "required": {
1401
+ "default": true,
1402
+ "description": "When false, a result without it is fine.",
1403
+ "title": "Required",
1404
+ "type": "boolean"
1405
+ },
1406
+ "software": {
1407
+ "anyOf": [
1408
+ {
1409
+ "items": {
1410
+ "type": "string"
1411
+ },
1412
+ "minItems": 1,
1413
+ "type": "array"
1414
+ },
1415
+ {
1416
+ "type": "null"
1417
+ }
1418
+ ],
1419
+ "default": null,
1420
+ "description": "The software, as apb2's rule names it, whose results this level exports; every software when omitted. Another software's result skips the level.",
1421
+ "title": "Software"
1422
+ },
1423
+ "axis": {
1424
+ "$ref": "#/$defs/Axis"
1425
+ },
1426
+ "measurements": {
1427
+ "$ref": "#/$defs/Measurements"
1428
+ },
1429
+ "columns": {
1430
+ "$ref": "#/$defs/Columns"
1431
+ },
1432
+ "uns": {
1433
+ "items": {
1434
+ "$ref": "#/$defs/ColumnEntry"
1435
+ },
1436
+ "title": "Uns",
1437
+ "type": "array"
1438
+ },
1439
+ "accession_syntax": {
1440
+ "additionalProperties": {
1441
+ "$ref": "#/$defs/AccessionSyntax"
1442
+ },
1443
+ "title": "Accession Syntax",
1444
+ "type": "object"
1445
+ }
1446
+ },
1447
+ "required": [
1448
+ "axis",
1449
+ "measurements",
1450
+ "columns"
1451
+ ],
1452
+ "title": "LevelRule",
1453
+ "type": "object"
1454
+ }