@disclosureos/schema 1.1.0 → 2.0.0-beta.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,627 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "type": "object",
4
+ "properties": {
5
+ "kind": {
6
+ "type": "string",
7
+ "const": "instrument_research_review"
8
+ },
9
+ "schemaVersion": {
10
+ "type": "string",
11
+ "const": "0.1.0"
12
+ },
13
+ "id": {
14
+ "type": "string",
15
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
16
+ },
17
+ "historyId": {
18
+ "type": "string",
19
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
20
+ },
21
+ "observationId": {
22
+ "type": "string",
23
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
24
+ },
25
+ "contextId": {
26
+ "type": "string",
27
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
28
+ },
29
+ "acquisitionBindingsId": {
30
+ "type": "string",
31
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
32
+ },
33
+ "measurementBindingsId": {
34
+ "type": "string",
35
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
36
+ },
37
+ "purpose": {
38
+ "type": "object",
39
+ "properties": {
40
+ "id": {
41
+ "type": "string",
42
+ "minLength": 1,
43
+ "pattern": "\\S"
44
+ },
45
+ "version": {
46
+ "type": "string",
47
+ "minLength": 1,
48
+ "pattern": "\\S"
49
+ },
50
+ "description": {
51
+ "type": "string",
52
+ "minLength": 1,
53
+ "pattern": "\\S"
54
+ }
55
+ },
56
+ "required": [
57
+ "id",
58
+ "version",
59
+ "description"
60
+ ],
61
+ "additionalProperties": false
62
+ },
63
+ "measurements": {
64
+ "type": "array",
65
+ "items": {
66
+ "type": "object",
67
+ "properties": {
68
+ "measurementRef": {
69
+ "type": "string",
70
+ "pattern": "^measurement:[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
71
+ },
72
+ "calibrationRef": {
73
+ "type": "string",
74
+ "pattern": "^calibration:[A-Za-z0-9][A-Za-z0-9._-]*(?![\\s\\S])"
75
+ },
76
+ "calibrationUse": {
77
+ "anyOf": [
78
+ {
79
+ "type": "object",
80
+ "properties": {
81
+ "state": {
82
+ "type": "string",
83
+ "const": "unreviewed"
84
+ }
85
+ },
86
+ "required": [
87
+ "state"
88
+ ],
89
+ "additionalProperties": false
90
+ },
91
+ {
92
+ "type": "object",
93
+ "properties": {
94
+ "state": {
95
+ "type": "string",
96
+ "const": "reviewed"
97
+ },
98
+ "reviewedBy": {
99
+ "type": "string",
100
+ "minLength": 1,
101
+ "pattern": "\\S"
102
+ },
103
+ "reviewedAt": {
104
+ "type": "string",
105
+ "minLength": 1,
106
+ "pattern": "\\S"
107
+ },
108
+ "outcome": {
109
+ "type": "string",
110
+ "enum": [
111
+ "accepted",
112
+ "rejected",
113
+ "inconclusive"
114
+ ]
115
+ },
116
+ "rationale": {
117
+ "type": "string",
118
+ "minLength": 1,
119
+ "pattern": "\\S"
120
+ },
121
+ "method": {
122
+ "type": "object",
123
+ "properties": {
124
+ "id": {
125
+ "type": "string",
126
+ "minLength": 1,
127
+ "pattern": "\\S"
128
+ },
129
+ "version": {
130
+ "type": "string",
131
+ "minLength": 1,
132
+ "pattern": "\\S"
133
+ },
134
+ "description": {
135
+ "type": "string",
136
+ "minLength": 1,
137
+ "pattern": "\\S"
138
+ }
139
+ },
140
+ "required": [
141
+ "id",
142
+ "version",
143
+ "description"
144
+ ],
145
+ "additionalProperties": false
146
+ },
147
+ "report": {
148
+ "type": "object",
149
+ "properties": {
150
+ "digest": {
151
+ "type": "object",
152
+ "properties": {
153
+ "algorithm": {
154
+ "type": "string",
155
+ "const": "sha256"
156
+ },
157
+ "value": {
158
+ "type": "string",
159
+ "pattern": "^[a-f0-9]{64}(?![\\s\\S])"
160
+ }
161
+ },
162
+ "required": [
163
+ "algorithm",
164
+ "value"
165
+ ],
166
+ "additionalProperties": false
167
+ },
168
+ "mediaType": {
169
+ "type": "string",
170
+ "minLength": 1,
171
+ "pattern": "\\S"
172
+ },
173
+ "byteLength": {
174
+ "type": "integer",
175
+ "minimum": 1,
176
+ "maximum": 9007199254740991
177
+ }
178
+ },
179
+ "required": [
180
+ "digest",
181
+ "mediaType",
182
+ "byteLength"
183
+ ],
184
+ "additionalProperties": false
185
+ }
186
+ },
187
+ "required": [
188
+ "state",
189
+ "reviewedBy",
190
+ "reviewedAt",
191
+ "outcome",
192
+ "rationale",
193
+ "method",
194
+ "report"
195
+ ],
196
+ "additionalProperties": false
197
+ }
198
+ ]
199
+ },
200
+ "timing": {
201
+ "anyOf": [
202
+ {
203
+ "type": "object",
204
+ "properties": {
205
+ "kind": {
206
+ "type": "string",
207
+ "const": "unknown"
208
+ },
209
+ "reason": {
210
+ "type": "string",
211
+ "minLength": 1,
212
+ "pattern": "\\S"
213
+ }
214
+ },
215
+ "required": [
216
+ "kind",
217
+ "reason"
218
+ ],
219
+ "additionalProperties": false
220
+ },
221
+ {
222
+ "type": "object",
223
+ "properties": {
224
+ "kind": {
225
+ "type": "string",
226
+ "const": "bound"
227
+ },
228
+ "lower": {
229
+ "type": "string",
230
+ "minLength": 1,
231
+ "pattern": "\\S"
232
+ },
233
+ "upper": {
234
+ "type": "string",
235
+ "minLength": 1,
236
+ "pattern": "\\S"
237
+ },
238
+ "timeScale": {
239
+ "type": "string",
240
+ "const": "UTC"
241
+ },
242
+ "assumptions": {
243
+ "minItems": 1,
244
+ "type": "array",
245
+ "items": {
246
+ "type": "string",
247
+ "minLength": 1,
248
+ "pattern": "\\S"
249
+ }
250
+ },
251
+ "review": {
252
+ "anyOf": [
253
+ {
254
+ "type": "object",
255
+ "properties": {
256
+ "state": {
257
+ "type": "string",
258
+ "const": "unreviewed"
259
+ }
260
+ },
261
+ "required": [
262
+ "state"
263
+ ],
264
+ "additionalProperties": false
265
+ },
266
+ {
267
+ "type": "object",
268
+ "properties": {
269
+ "state": {
270
+ "type": "string",
271
+ "const": "reviewed"
272
+ },
273
+ "reviewedBy": {
274
+ "type": "string",
275
+ "minLength": 1,
276
+ "pattern": "\\S"
277
+ },
278
+ "reviewedAt": {
279
+ "type": "string",
280
+ "minLength": 1,
281
+ "pattern": "\\S"
282
+ },
283
+ "outcome": {
284
+ "type": "string",
285
+ "enum": [
286
+ "accepted",
287
+ "rejected",
288
+ "inconclusive"
289
+ ]
290
+ },
291
+ "rationale": {
292
+ "type": "string",
293
+ "minLength": 1,
294
+ "pattern": "\\S"
295
+ },
296
+ "method": {
297
+ "type": "object",
298
+ "properties": {
299
+ "id": {
300
+ "type": "string",
301
+ "minLength": 1,
302
+ "pattern": "\\S"
303
+ },
304
+ "version": {
305
+ "type": "string",
306
+ "minLength": 1,
307
+ "pattern": "\\S"
308
+ },
309
+ "description": {
310
+ "type": "string",
311
+ "minLength": 1,
312
+ "pattern": "\\S"
313
+ }
314
+ },
315
+ "required": [
316
+ "id",
317
+ "version",
318
+ "description"
319
+ ],
320
+ "additionalProperties": false
321
+ },
322
+ "report": {
323
+ "type": "object",
324
+ "properties": {
325
+ "digest": {
326
+ "type": "object",
327
+ "properties": {
328
+ "algorithm": {
329
+ "type": "string",
330
+ "const": "sha256"
331
+ },
332
+ "value": {
333
+ "type": "string",
334
+ "pattern": "^[a-f0-9]{64}(?![\\s\\S])"
335
+ }
336
+ },
337
+ "required": [
338
+ "algorithm",
339
+ "value"
340
+ ],
341
+ "additionalProperties": false
342
+ },
343
+ "mediaType": {
344
+ "type": "string",
345
+ "minLength": 1,
346
+ "pattern": "\\S"
347
+ },
348
+ "byteLength": {
349
+ "type": "integer",
350
+ "minimum": 1,
351
+ "maximum": 9007199254740991
352
+ }
353
+ },
354
+ "required": [
355
+ "digest",
356
+ "mediaType",
357
+ "byteLength"
358
+ ],
359
+ "additionalProperties": false
360
+ }
361
+ },
362
+ "required": [
363
+ "state",
364
+ "reviewedBy",
365
+ "reviewedAt",
366
+ "outcome",
367
+ "rationale",
368
+ "method",
369
+ "report"
370
+ ],
371
+ "additionalProperties": false
372
+ }
373
+ ]
374
+ }
375
+ },
376
+ "required": [
377
+ "kind",
378
+ "lower",
379
+ "upper",
380
+ "timeScale",
381
+ "assumptions",
382
+ "review"
383
+ ],
384
+ "additionalProperties": false
385
+ },
386
+ {
387
+ "type": "object",
388
+ "properties": {
389
+ "kind": {
390
+ "type": "string",
391
+ "const": "coverage_interval"
392
+ },
393
+ "lower": {
394
+ "type": "string",
395
+ "minLength": 1,
396
+ "pattern": "\\S"
397
+ },
398
+ "upper": {
399
+ "type": "string",
400
+ "minLength": 1,
401
+ "pattern": "\\S"
402
+ },
403
+ "timeScale": {
404
+ "type": "string",
405
+ "const": "UTC"
406
+ },
407
+ "assumptions": {
408
+ "minItems": 1,
409
+ "type": "array",
410
+ "items": {
411
+ "type": "string",
412
+ "minLength": 1,
413
+ "pattern": "\\S"
414
+ }
415
+ },
416
+ "review": {
417
+ "anyOf": [
418
+ {
419
+ "type": "object",
420
+ "properties": {
421
+ "state": {
422
+ "type": "string",
423
+ "const": "unreviewed"
424
+ }
425
+ },
426
+ "required": [
427
+ "state"
428
+ ],
429
+ "additionalProperties": false
430
+ },
431
+ {
432
+ "type": "object",
433
+ "properties": {
434
+ "state": {
435
+ "type": "string",
436
+ "const": "reviewed"
437
+ },
438
+ "reviewedBy": {
439
+ "type": "string",
440
+ "minLength": 1,
441
+ "pattern": "\\S"
442
+ },
443
+ "reviewedAt": {
444
+ "type": "string",
445
+ "minLength": 1,
446
+ "pattern": "\\S"
447
+ },
448
+ "outcome": {
449
+ "type": "string",
450
+ "enum": [
451
+ "accepted",
452
+ "rejected",
453
+ "inconclusive"
454
+ ]
455
+ },
456
+ "rationale": {
457
+ "type": "string",
458
+ "minLength": 1,
459
+ "pattern": "\\S"
460
+ },
461
+ "method": {
462
+ "type": "object",
463
+ "properties": {
464
+ "id": {
465
+ "type": "string",
466
+ "minLength": 1,
467
+ "pattern": "\\S"
468
+ },
469
+ "version": {
470
+ "type": "string",
471
+ "minLength": 1,
472
+ "pattern": "\\S"
473
+ },
474
+ "description": {
475
+ "type": "string",
476
+ "minLength": 1,
477
+ "pattern": "\\S"
478
+ }
479
+ },
480
+ "required": [
481
+ "id",
482
+ "version",
483
+ "description"
484
+ ],
485
+ "additionalProperties": false
486
+ },
487
+ "report": {
488
+ "type": "object",
489
+ "properties": {
490
+ "digest": {
491
+ "type": "object",
492
+ "properties": {
493
+ "algorithm": {
494
+ "type": "string",
495
+ "const": "sha256"
496
+ },
497
+ "value": {
498
+ "type": "string",
499
+ "pattern": "^[a-f0-9]{64}(?![\\s\\S])"
500
+ }
501
+ },
502
+ "required": [
503
+ "algorithm",
504
+ "value"
505
+ ],
506
+ "additionalProperties": false
507
+ },
508
+ "mediaType": {
509
+ "type": "string",
510
+ "minLength": 1,
511
+ "pattern": "\\S"
512
+ },
513
+ "byteLength": {
514
+ "type": "integer",
515
+ "minimum": 1,
516
+ "maximum": 9007199254740991
517
+ }
518
+ },
519
+ "required": [
520
+ "digest",
521
+ "mediaType",
522
+ "byteLength"
523
+ ],
524
+ "additionalProperties": false
525
+ }
526
+ },
527
+ "required": [
528
+ "state",
529
+ "reviewedBy",
530
+ "reviewedAt",
531
+ "outcome",
532
+ "rationale",
533
+ "method",
534
+ "report"
535
+ ],
536
+ "additionalProperties": false
537
+ }
538
+ ]
539
+ },
540
+ "coverageProbability": {
541
+ "type": "number",
542
+ "exclusiveMinimum": 0,
543
+ "exclusiveMaximum": 1
544
+ }
545
+ },
546
+ "required": [
547
+ "kind",
548
+ "lower",
549
+ "upper",
550
+ "timeScale",
551
+ "assumptions",
552
+ "review",
553
+ "coverageProbability"
554
+ ],
555
+ "additionalProperties": false
556
+ }
557
+ ]
558
+ }
559
+ },
560
+ "required": [
561
+ "measurementRef",
562
+ "calibrationRef",
563
+ "calibrationUse",
564
+ "timing"
565
+ ],
566
+ "additionalProperties": false
567
+ }
568
+ },
569
+ "extensions": {
570
+ "type": "object",
571
+ "propertyNames": {
572
+ "type": "string",
573
+ "pattern": "^[a-z][a-z0-9_-]*(?:\\.[a-z0-9_-]+)+(?![\\s\\S])"
574
+ },
575
+ "additionalProperties": {
576
+ "$ref": "#/$defs/__schema0"
577
+ }
578
+ }
579
+ },
580
+ "required": [
581
+ "kind",
582
+ "schemaVersion",
583
+ "id",
584
+ "historyId",
585
+ "observationId",
586
+ "contextId",
587
+ "acquisitionBindingsId",
588
+ "measurementBindingsId",
589
+ "purpose",
590
+ "measurements"
591
+ ],
592
+ "additionalProperties": false,
593
+ "$defs": {
594
+ "__schema0": {
595
+ "anyOf": [
596
+ {
597
+ "type": "string"
598
+ },
599
+ {
600
+ "type": "number"
601
+ },
602
+ {
603
+ "type": "boolean"
604
+ },
605
+ {
606
+ "type": "null"
607
+ },
608
+ {
609
+ "type": "array",
610
+ "items": {
611
+ "$ref": "#/$defs/__schema0"
612
+ }
613
+ },
614
+ {
615
+ "type": "object",
616
+ "propertyNames": {
617
+ "type": "string"
618
+ },
619
+ "additionalProperties": {
620
+ "$ref": "#/$defs/__schema0"
621
+ }
622
+ }
623
+ ]
624
+ }
625
+ },
626
+ "$id": "urn:disclosureos:experimental:instrument-research-review:0.1.0"
627
+ }