hoi4-agent-tools 2.2.0 → 2.3.3

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 (72) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/README.md +30 -21
  3. package/dist/hoi4_agent_tools/core/clausewitz-evaluation.js +90 -0
  4. package/dist/hoi4_agent_tools/core/engine.js +5 -0
  5. package/dist/hoi4_agent_tools/core/index.js +57 -1
  6. package/dist/hoi4_agent_tools/core/source/ast-path.js +41 -0
  7. package/dist/hoi4_agent_tools/core/source/index.js +1 -0
  8. package/dist/hoi4_agent_tools/event/algorithms.js +178 -1
  9. package/dist/hoi4_agent_tools/event/graph.js +24 -9
  10. package/dist/hoi4_agent_tools/event/limits.js +5 -2
  11. package/dist/hoi4_agent_tools/event/service.js +182 -45
  12. package/dist/hoi4_agent_tools/mcp/server/create.js +3 -1
  13. package/dist/hoi4_agent_tools/mcp/tools/chaosx.js +13 -63
  14. package/dist/hoi4_agent_tools/mcp/tools/probability.js +413 -0
  15. package/dist/hoi4_agent_tools/mcp/tools/technology.js +4 -1
  16. package/dist/hoi4_agent_tools/probability/adapters.js +344 -0
  17. package/dist/hoi4_agent_tools/probability/compare.js +178 -0
  18. package/dist/hoi4_agent_tools/probability/evaluation.js +649 -0
  19. package/dist/hoi4_agent_tools/probability/index.js +13 -0
  20. package/dist/hoi4_agent_tools/probability/model.js +5 -0
  21. package/dist/hoi4_agent_tools/probability/rational.js +145 -0
  22. package/dist/hoi4_agent_tools/probability/render.js +307 -0
  23. package/dist/hoi4_agent_tools/probability/sequence.js +858 -0
  24. package/dist/hoi4_agent_tools/probability/service.js +1168 -0
  25. package/dist/hoi4_agent_tools/probability/simulation.js +545 -0
  26. package/dist/hoi4_agent_tools/probability/source-analysis.js +458 -0
  27. package/dist/hoi4_agent_tools/probability/sweep.js +265 -0
  28. package/dist/hoi4_agent_tools/probability/trigger-evaluator.js +280 -0
  29. package/dist/hoi4_agent_tools/probability/value-evaluator.js +357 -0
  30. package/dist/hoi4_agent_tools/runtime.js +109 -7
  31. package/dist/hoi4_agent_tools/schemas/probability.js +930 -0
  32. package/dist/hoi4_agent_tools/technology/graph.js +30 -3
  33. package/dist/hoi4_agent_tools/technology/queries.js +70 -3
  34. package/dist/hoi4_agent_tools/technology/service.js +38 -2
  35. package/dist/hoi4_agent_tools/version.js +1 -1
  36. package/docs/README.md +1 -0
  37. package/docs/development.md +2 -0
  38. package/docs/events.md +2 -2
  39. package/docs/probability.md +80 -0
  40. package/docs/research/probability-adapter-evidence.md +64 -0
  41. package/docs/setup.md +2 -0
  42. package/docs/technology.md +4 -2
  43. package/examples/clients/codex-config.toml +3 -0
  44. package/examples/clients/generic.json +8 -0
  45. package/examples/probability/adaptive-event-pool.json +92 -0
  46. package/examples/probability/adaptive-event-sequence-input.json +57 -0
  47. package/examples/probability/event-mtth-scenarios.json +57 -0
  48. package/examples/probability/event-mtth-simulate-input.json +37 -0
  49. package/examples/probability/focus-route-scenarios.json +61 -0
  50. package/examples/probability/focus-route-sweep-input.json +36 -0
  51. package/package.json +19 -8
  52. package/schemas/configuration.schema.json +747 -0
  53. package/schemas/continuous-focus-palette.schema.json +325 -0
  54. package/schemas/custom-weighted-pool.schema.json +298 -0
  55. package/schemas/event-feature-manifest.schema.json +63 -0
  56. package/schemas/focus-plan.schema.json +927 -0
  57. package/schemas/focus-planning-sidecar.schema.json +407 -0
  58. package/schemas/gui-animation-source.schema.json +176 -0
  59. package/schemas/gui-helper.schema.json +301 -0
  60. package/schemas/gui-scenario.schema.json +298 -0
  61. package/schemas/map-operation.schema.json +2284 -0
  62. package/schemas/operation-result.schema.json +327 -0
  63. package/schemas/probability-analysis-result.schema.json +2211 -0
  64. package/schemas/probability-compare-input.schema.json +664 -0
  65. package/schemas/probability-evaluate-input.schema.json +665 -0
  66. package/schemas/probability-inspect-input.schema.json +97 -0
  67. package/schemas/probability-render-input.schema.json +141 -0
  68. package/schemas/probability-scenario-set.schema.json +430 -0
  69. package/schemas/probability-sequence-input.schema.json +886 -0
  70. package/schemas/probability-simulate-input.schema.json +691 -0
  71. package/schemas/probability-sweep-input.schema.json +702 -0
  72. package/server.json +3 -3
@@ -0,0 +1,2211 @@
1
+ {
2
+ "$id": "https://github.com/klimPaskov/hoi4-agent-tools/blob/v2.3.3/schemas/probability-analysis-result.schema.json",
3
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
4
+ "type": "object",
5
+ "properties": {
6
+ "schemaVersion": {
7
+ "type": "string",
8
+ "const": "1.0"
9
+ },
10
+ "status": {
11
+ "type": "string",
12
+ "enum": [
13
+ "complete",
14
+ "partial",
15
+ "blocked",
16
+ "cancelled",
17
+ "stale"
18
+ ]
19
+ },
20
+ "operation": {
21
+ "type": "string",
22
+ "enum": [
23
+ "inspect",
24
+ "evaluate",
25
+ "sweep",
26
+ "simulate",
27
+ "sequence",
28
+ "compare",
29
+ "render"
30
+ ]
31
+ },
32
+ "analysisId": {
33
+ "type": "string"
34
+ },
35
+ "metadata": {
36
+ "type": "object",
37
+ "properties": {
38
+ "workspaceId": {
39
+ "type": "string"
40
+ },
41
+ "workspaceIdentity": {
42
+ "type": "string"
43
+ },
44
+ "sourceRevision": {
45
+ "type": "string"
46
+ },
47
+ "sourceHash": {
48
+ "type": "string"
49
+ },
50
+ "scenarioHash": {
51
+ "type": "string"
52
+ },
53
+ "candidatePoolHash": {
54
+ "type": "string"
55
+ },
56
+ "gameVersion": {
57
+ "type": "string"
58
+ },
59
+ "gameVersionVerification": {
60
+ "type": "object",
61
+ "properties": {
62
+ "status": {
63
+ "type": "string",
64
+ "enum": [
65
+ "workspace_verified",
66
+ "adapter_target_only"
67
+ ]
68
+ },
69
+ "adapterTarget": {
70
+ "type": "string"
71
+ },
72
+ "sourcePath": {
73
+ "type": "string"
74
+ },
75
+ "observedVersion": {
76
+ "type": "string"
77
+ },
78
+ "observedRawVersion": {
79
+ "type": "string"
80
+ },
81
+ "observedChecksum": {
82
+ "type": "string"
83
+ }
84
+ },
85
+ "required": [
86
+ "status",
87
+ "adapterTarget"
88
+ ],
89
+ "additionalProperties": false
90
+ },
91
+ "adapterId": {
92
+ "$ref": "#/$defs/__schema0"
93
+ },
94
+ "adapterVersion": {
95
+ "type": "string"
96
+ },
97
+ "requestedMetrics": {
98
+ "minItems": 1,
99
+ "maxItems": 4,
100
+ "type": "array",
101
+ "items": {
102
+ "$ref": "#/$defs/__schema1"
103
+ }
104
+ },
105
+ "seed": {
106
+ "type": "integer",
107
+ "minimum": -9007199254740991,
108
+ "maximum": 9007199254740991
109
+ },
110
+ "samples": {
111
+ "type": "integer",
112
+ "minimum": 0,
113
+ "maximum": 9007199254740991
114
+ },
115
+ "numericalPrecision": {
116
+ "type": "string"
117
+ },
118
+ "cacheKey": {
119
+ "type": "string"
120
+ }
121
+ },
122
+ "required": [
123
+ "workspaceId",
124
+ "workspaceIdentity",
125
+ "sourceRevision",
126
+ "sourceHash",
127
+ "scenarioHash",
128
+ "candidatePoolHash",
129
+ "gameVersion",
130
+ "gameVersionVerification",
131
+ "adapterId",
132
+ "adapterVersion",
133
+ "numericalPrecision",
134
+ "cacheKey"
135
+ ],
136
+ "additionalProperties": false
137
+ },
138
+ "adapter": {
139
+ "type": "object",
140
+ "properties": {
141
+ "id": {
142
+ "$ref": "#/$defs/__schema0"
143
+ },
144
+ "version": {
145
+ "type": "string"
146
+ },
147
+ "gameVersion": {
148
+ "type": "string"
149
+ },
150
+ "supportedGameVersions": {
151
+ "type": "array",
152
+ "items": {
153
+ "type": "string"
154
+ }
155
+ },
156
+ "selectionRule": {
157
+ "type": "string",
158
+ "enum": [
159
+ "proportional_categorical",
160
+ "uniform_score_race",
161
+ "independent_chance",
162
+ "median_daily_hazard",
163
+ "score_only",
164
+ "custom_declared"
165
+ ]
166
+ },
167
+ "capabilities": {
168
+ "type": "object",
169
+ "properties": {
170
+ "eligibility": {
171
+ "type": "boolean"
172
+ },
173
+ "rawScore": {
174
+ "type": "boolean"
175
+ },
176
+ "normalizedProbability": {
177
+ "type": "boolean"
178
+ },
179
+ "timeDistribution": {
180
+ "type": "boolean"
181
+ },
182
+ "sequence": {
183
+ "type": "boolean"
184
+ }
185
+ },
186
+ "required": [
187
+ "eligibility",
188
+ "rawScore",
189
+ "normalizedProbability",
190
+ "timeDistribution",
191
+ "sequence"
192
+ ],
193
+ "additionalProperties": false
194
+ },
195
+ "completePoolRequired": {
196
+ "type": "boolean"
197
+ },
198
+ "confidence": {
199
+ "type": "string",
200
+ "enum": [
201
+ "documented",
202
+ "documented_with_runtime_boundary",
203
+ "manifest_defined"
204
+ ]
205
+ },
206
+ "sourceBlockTypes": {
207
+ "type": "array",
208
+ "items": {
209
+ "type": "string"
210
+ }
211
+ },
212
+ "candidateDiscoveryRules": {
213
+ "type": "array",
214
+ "items": {
215
+ "type": "string"
216
+ }
217
+ },
218
+ "eligibilityRules": {
219
+ "type": "array",
220
+ "items": {
221
+ "type": "string"
222
+ }
223
+ },
224
+ "modifierOrder": {
225
+ "type": "array",
226
+ "items": {
227
+ "type": "string"
228
+ }
229
+ },
230
+ "poolNormalizationRules": {
231
+ "type": "array",
232
+ "items": {
233
+ "type": "string"
234
+ }
235
+ },
236
+ "evaluationCadence": {
237
+ "type": "string"
238
+ },
239
+ "timingConversion": {
240
+ "type": "array",
241
+ "items": {
242
+ "type": "string"
243
+ }
244
+ },
245
+ "scopeExpectations": {
246
+ "type": "array",
247
+ "items": {
248
+ "type": "string"
249
+ }
250
+ },
251
+ "supportedExpressions": {
252
+ "type": "array",
253
+ "items": {
254
+ "type": "string"
255
+ }
256
+ },
257
+ "unsupportedConstructs": {
258
+ "type": "array",
259
+ "items": {
260
+ "type": "string"
261
+ }
262
+ },
263
+ "evidence": {
264
+ "type": "array",
265
+ "items": {
266
+ "type": "string"
267
+ }
268
+ },
269
+ "testFixtures": {
270
+ "type": "array",
271
+ "items": {
272
+ "type": "string"
273
+ }
274
+ },
275
+ "limitations": {
276
+ "type": "array",
277
+ "items": {
278
+ "type": "string"
279
+ }
280
+ }
281
+ },
282
+ "required": [
283
+ "id",
284
+ "version",
285
+ "gameVersion",
286
+ "supportedGameVersions",
287
+ "selectionRule",
288
+ "capabilities",
289
+ "completePoolRequired",
290
+ "confidence",
291
+ "sourceBlockTypes",
292
+ "candidateDiscoveryRules",
293
+ "eligibilityRules",
294
+ "modifierOrder",
295
+ "poolNormalizationRules",
296
+ "evaluationCadence",
297
+ "timingConversion",
298
+ "scopeExpectations",
299
+ "supportedExpressions",
300
+ "unsupportedConstructs",
301
+ "evidence",
302
+ "testFixtures",
303
+ "limitations"
304
+ ],
305
+ "additionalProperties": false
306
+ },
307
+ "scenarios": {
308
+ "type": "array",
309
+ "items": {
310
+ "type": "object",
311
+ "properties": {
312
+ "id": {
313
+ "type": "string"
314
+ },
315
+ "label": {
316
+ "type": "string"
317
+ },
318
+ "prevalence": {
319
+ "type": "number",
320
+ "minimum": 0,
321
+ "maximum": 1
322
+ },
323
+ "poolComplete": {
324
+ "type": "boolean"
325
+ },
326
+ "supportLevel": {
327
+ "type": "string",
328
+ "enum": [
329
+ "exact",
330
+ "bounded",
331
+ "sampled",
332
+ "score_only",
333
+ "external",
334
+ "unsupported"
335
+ ]
336
+ },
337
+ "candidates": {
338
+ "type": "array",
339
+ "items": {
340
+ "type": "object",
341
+ "properties": {
342
+ "id": {
343
+ "type": "string"
344
+ },
345
+ "eligibility": {
346
+ "type": "string",
347
+ "enum": [
348
+ "true",
349
+ "false",
350
+ "unresolved"
351
+ ]
352
+ },
353
+ "supportLevel": {
354
+ "type": "string",
355
+ "enum": [
356
+ "exact",
357
+ "bounded",
358
+ "sampled",
359
+ "score_only",
360
+ "external",
361
+ "unsupported"
362
+ ]
363
+ },
364
+ "rawValue": {
365
+ "anyOf": [
366
+ {
367
+ "$ref": "#/$defs/__schema2"
368
+ },
369
+ {
370
+ "type": "null"
371
+ }
372
+ ]
373
+ },
374
+ "rawInterval": {
375
+ "type": "object",
376
+ "properties": {
377
+ "min": {
378
+ "type": "number"
379
+ },
380
+ "max": {
381
+ "type": "number"
382
+ }
383
+ },
384
+ "required": [
385
+ "min",
386
+ "max"
387
+ ],
388
+ "additionalProperties": false
389
+ },
390
+ "conditionalProbability": {
391
+ "anyOf": [
392
+ {
393
+ "type": "number",
394
+ "minimum": 0,
395
+ "maximum": 1
396
+ },
397
+ {
398
+ "type": "null"
399
+ }
400
+ ]
401
+ },
402
+ "exactConditionalProbability": {
403
+ "$ref": "#/$defs/__schema2"
404
+ },
405
+ "pathProbability": {
406
+ "anyOf": [
407
+ {
408
+ "type": "number",
409
+ "minimum": 0,
410
+ "maximum": 1
411
+ },
412
+ {
413
+ "type": "null"
414
+ }
415
+ ]
416
+ },
417
+ "exactPathProbability": {
418
+ "$ref": "#/$defs/__schema2"
419
+ },
420
+ "pathProbabilityInterval": {
421
+ "type": "object",
422
+ "properties": {
423
+ "low": {
424
+ "type": "number",
425
+ "minimum": 0,
426
+ "maximum": 1
427
+ },
428
+ "high": {
429
+ "type": "number",
430
+ "minimum": 0,
431
+ "maximum": 1
432
+ }
433
+ },
434
+ "required": [
435
+ "low",
436
+ "high"
437
+ ],
438
+ "additionalProperties": false
439
+ },
440
+ "conditionalProbabilityInterval": {
441
+ "type": "object",
442
+ "properties": {
443
+ "low": {
444
+ "type": "number",
445
+ "minimum": 0,
446
+ "maximum": 1
447
+ },
448
+ "high": {
449
+ "type": "number",
450
+ "minimum": 0,
451
+ "maximum": 1
452
+ }
453
+ },
454
+ "required": [
455
+ "low",
456
+ "high"
457
+ ],
458
+ "additionalProperties": false
459
+ },
460
+ "confidenceInterval": {
461
+ "type": "object",
462
+ "properties": {
463
+ "low": {
464
+ "type": "number",
465
+ "minimum": 0,
466
+ "maximum": 1
467
+ },
468
+ "high": {
469
+ "type": "number",
470
+ "minimum": 0,
471
+ "maximum": 1
472
+ }
473
+ },
474
+ "required": [
475
+ "low",
476
+ "high"
477
+ ],
478
+ "additionalProperties": false
479
+ },
480
+ "sampledFrequency": {
481
+ "type": "number",
482
+ "minimum": 0,
483
+ "maximum": 1
484
+ },
485
+ "effectiveMtthDays": {
486
+ "type": "number",
487
+ "minimum": 0
488
+ },
489
+ "timingModel": {
490
+ "type": "string"
491
+ },
492
+ "timingQuantilesDays": {
493
+ "type": "object",
494
+ "properties": {
495
+ "p10": {
496
+ "type": "number"
497
+ },
498
+ "p50": {
499
+ "type": "number"
500
+ },
501
+ "p90": {
502
+ "type": "number"
503
+ },
504
+ "p95": {
505
+ "type": "number"
506
+ }
507
+ },
508
+ "required": [
509
+ "p10",
510
+ "p50",
511
+ "p90",
512
+ "p95"
513
+ ],
514
+ "additionalProperties": false
515
+ },
516
+ "timingQuantileIntervals": {
517
+ "type": "object",
518
+ "properties": {
519
+ "p10": {
520
+ "type": "object",
521
+ "properties": {
522
+ "low": {
523
+ "type": "number"
524
+ },
525
+ "high": {
526
+ "type": "number"
527
+ }
528
+ },
529
+ "required": [
530
+ "low",
531
+ "high"
532
+ ],
533
+ "additionalProperties": false
534
+ },
535
+ "p50": {
536
+ "type": "object",
537
+ "properties": {
538
+ "low": {
539
+ "type": "number"
540
+ },
541
+ "high": {
542
+ "type": "number"
543
+ }
544
+ },
545
+ "required": [
546
+ "low",
547
+ "high"
548
+ ],
549
+ "additionalProperties": false
550
+ },
551
+ "p90": {
552
+ "type": "object",
553
+ "properties": {
554
+ "low": {
555
+ "type": "number"
556
+ },
557
+ "high": {
558
+ "type": "number"
559
+ }
560
+ },
561
+ "required": [
562
+ "low",
563
+ "high"
564
+ ],
565
+ "additionalProperties": false
566
+ },
567
+ "p95": {
568
+ "type": "object",
569
+ "properties": {
570
+ "low": {
571
+ "type": "number"
572
+ },
573
+ "high": {
574
+ "type": "number"
575
+ }
576
+ },
577
+ "required": [
578
+ "low",
579
+ "high"
580
+ ],
581
+ "additionalProperties": false
582
+ }
583
+ },
584
+ "required": [
585
+ "p10",
586
+ "p50",
587
+ "p90",
588
+ "p95"
589
+ ],
590
+ "additionalProperties": false
591
+ },
592
+ "timingSampleCount": {
593
+ "type": "integer",
594
+ "minimum": 0,
595
+ "maximum": 9007199254740991
596
+ },
597
+ "timingEvaluations": {
598
+ "type": "integer",
599
+ "minimum": 0,
600
+ "maximum": 9007199254740991
601
+ },
602
+ "timingReservoirCapacity": {
603
+ "type": "integer",
604
+ "exclusiveMinimum": 0,
605
+ "maximum": 9007199254740991
606
+ },
607
+ "timingMethod": {
608
+ "type": "string",
609
+ "const": "sampled_discrete_daily_hazard"
610
+ },
611
+ "timingConfidenceMethod": {
612
+ "type": "string",
613
+ "const": "normal_order_statistic"
614
+ },
615
+ "cumulativeChance": {
616
+ "type": "number",
617
+ "minimum": 0,
618
+ "maximum": 1
619
+ },
620
+ "cumulativeChanceInterval": {
621
+ "type": "object",
622
+ "properties": {
623
+ "low": {
624
+ "type": "number",
625
+ "minimum": 0,
626
+ "maximum": 1
627
+ },
628
+ "high": {
629
+ "type": "number",
630
+ "minimum": 0,
631
+ "maximum": 1
632
+ }
633
+ },
634
+ "required": [
635
+ "low",
636
+ "high"
637
+ ],
638
+ "additionalProperties": false
639
+ },
640
+ "rank": {
641
+ "anyOf": [
642
+ {
643
+ "type": "integer",
644
+ "minimum": 1,
645
+ "maximum": 9007199254740991
646
+ },
647
+ {
648
+ "type": "null"
649
+ }
650
+ ]
651
+ },
652
+ "trace": {
653
+ "type": "array",
654
+ "items": {
655
+ "type": "object",
656
+ "properties": {
657
+ "operation": {
658
+ "type": "string",
659
+ "enum": [
660
+ "base",
661
+ "add",
662
+ "factor",
663
+ "eligibility",
664
+ "external_factor",
665
+ "normalization"
666
+ ]
667
+ },
668
+ "expression": {
669
+ "type": "string"
670
+ },
671
+ "applied": {
672
+ "type": "string",
673
+ "enum": [
674
+ "true",
675
+ "false",
676
+ "unresolved"
677
+ ]
678
+ },
679
+ "value": {
680
+ "$ref": "#/$defs/__schema2"
681
+ },
682
+ "before": {
683
+ "$ref": "#/$defs/__schema2"
684
+ },
685
+ "after": {
686
+ "$ref": "#/$defs/__schema2"
687
+ },
688
+ "provenance": {
689
+ "$ref": "#/$defs/__schema3"
690
+ },
691
+ "conditionExpression": {
692
+ "type": "string"
693
+ },
694
+ "note": {
695
+ "type": "string"
696
+ }
697
+ },
698
+ "required": [
699
+ "operation",
700
+ "expression",
701
+ "applied"
702
+ ],
703
+ "additionalProperties": false
704
+ }
705
+ },
706
+ "provenance": {
707
+ "type": "array",
708
+ "items": {
709
+ "$ref": "#/$defs/__schema3"
710
+ }
711
+ },
712
+ "unresolved": {
713
+ "type": "array",
714
+ "items": {
715
+ "$ref": "#/$defs/__schema6"
716
+ }
717
+ }
718
+ },
719
+ "required": [
720
+ "id",
721
+ "eligibility",
722
+ "supportLevel",
723
+ "trace",
724
+ "provenance",
725
+ "unresolved"
726
+ ],
727
+ "additionalProperties": false
728
+ }
729
+ },
730
+ "poolTotal": {
731
+ "$ref": "#/$defs/__schema2"
732
+ },
733
+ "horizonDays": {
734
+ "type": "number",
735
+ "exclusiveMinimum": 0
736
+ },
737
+ "survivalChance": {
738
+ "type": "number",
739
+ "minimum": 0,
740
+ "maximum": 1
741
+ },
742
+ "survivalChanceInterval": {
743
+ "type": "object",
744
+ "properties": {
745
+ "low": {
746
+ "type": "number",
747
+ "minimum": 0,
748
+ "maximum": 1
749
+ },
750
+ "high": {
751
+ "type": "number",
752
+ "minimum": 0,
753
+ "maximum": 1
754
+ }
755
+ },
756
+ "required": [
757
+ "low",
758
+ "high"
759
+ ],
760
+ "additionalProperties": false
761
+ },
762
+ "timingIntervals": {
763
+ "type": "array",
764
+ "items": {
765
+ "type": "object",
766
+ "properties": {
767
+ "startDay": {
768
+ "type": "number",
769
+ "minimum": 0
770
+ },
771
+ "endDay": {
772
+ "type": "number",
773
+ "minimum": 0
774
+ },
775
+ "eligibility": {
776
+ "type": "string",
777
+ "enum": [
778
+ "true",
779
+ "false",
780
+ "unresolved"
781
+ ]
782
+ },
783
+ "effectiveMtthDays": {
784
+ "type": "number",
785
+ "minimum": 0
786
+ },
787
+ "minimumHazardContribution": {
788
+ "type": "number",
789
+ "minimum": 0
790
+ },
791
+ "maximumHazardContribution": {
792
+ "type": "number",
793
+ "minimum": 0
794
+ }
795
+ },
796
+ "required": [
797
+ "startDay",
798
+ "endDay",
799
+ "eligibility",
800
+ "minimumHazardContribution",
801
+ "maximumHazardContribution"
802
+ ],
803
+ "additionalProperties": false
804
+ }
805
+ },
806
+ "summary": {
807
+ "type": "object",
808
+ "properties": {
809
+ "topOutcomes": {
810
+ "type": "array",
811
+ "items": {
812
+ "type": "string"
813
+ }
814
+ },
815
+ "bottomEligibleOutcomes": {
816
+ "type": "array",
817
+ "items": {
818
+ "type": "string"
819
+ }
820
+ },
821
+ "impossibleOutcomes": {
822
+ "type": "array",
823
+ "items": {
824
+ "type": "string"
825
+ }
826
+ },
827
+ "unresolvedOutcomes": {
828
+ "type": "array",
829
+ "items": {
830
+ "type": "string"
831
+ }
832
+ },
833
+ "dominantFactors": {
834
+ "type": "array",
835
+ "items": {
836
+ "type": "string"
837
+ }
838
+ },
839
+ "closestRankReversal": {
840
+ "type": "object",
841
+ "properties": {
842
+ "candidates": {
843
+ "type": "array",
844
+ "prefixItems": [
845
+ {
846
+ "type": "string"
847
+ },
848
+ {
849
+ "type": "string"
850
+ }
851
+ ]
852
+ },
853
+ "gap": {
854
+ "type": "number",
855
+ "minimum": 0
856
+ },
857
+ "metric": {
858
+ "type": "string",
859
+ "enum": [
860
+ "probability",
861
+ "raw_value"
862
+ ]
863
+ }
864
+ },
865
+ "required": [
866
+ "candidates",
867
+ "gap",
868
+ "metric"
869
+ ],
870
+ "additionalProperties": false
871
+ }
872
+ },
873
+ "required": [
874
+ "topOutcomes",
875
+ "bottomEligibleOutcomes",
876
+ "impossibleOutcomes",
877
+ "unresolvedOutcomes",
878
+ "dominantFactors"
879
+ ],
880
+ "additionalProperties": false
881
+ },
882
+ "unresolved": {
883
+ "type": "array",
884
+ "items": {
885
+ "$ref": "#/$defs/__schema6"
886
+ }
887
+ }
888
+ },
889
+ "required": [
890
+ "id",
891
+ "poolComplete",
892
+ "supportLevel",
893
+ "candidates",
894
+ "summary",
895
+ "unresolved"
896
+ ],
897
+ "additionalProperties": false
898
+ }
899
+ },
900
+ "prevalenceAggregate": {
901
+ "type": "object",
902
+ "properties": {
903
+ "prevalenceTotal": {
904
+ "type": "number",
905
+ "minimum": 0
906
+ },
907
+ "candidates": {
908
+ "type": "array",
909
+ "items": {
910
+ "type": "object",
911
+ "properties": {
912
+ "id": {
913
+ "type": "string"
914
+ },
915
+ "eligibilityPrevalence": {
916
+ "type": "number",
917
+ "minimum": 0,
918
+ "maximum": 1
919
+ },
920
+ "weightedConditionalProbability": {
921
+ "type": "number",
922
+ "minimum": 0,
923
+ "maximum": 1
924
+ }
925
+ },
926
+ "required": [
927
+ "id",
928
+ "eligibilityPrevalence"
929
+ ],
930
+ "additionalProperties": false
931
+ }
932
+ }
933
+ },
934
+ "required": [
935
+ "prevalenceTotal",
936
+ "candidates"
937
+ ],
938
+ "additionalProperties": false
939
+ },
940
+ "diagnostics": {
941
+ "type": "array",
942
+ "items": {
943
+ "type": "object",
944
+ "properties": {
945
+ "code": {
946
+ "type": "string",
947
+ "minLength": 1,
948
+ "maxLength": 256
949
+ },
950
+ "severity": {
951
+ "type": "string",
952
+ "enum": [
953
+ "info",
954
+ "warning",
955
+ "error",
956
+ "blocker"
957
+ ]
958
+ },
959
+ "category": {
960
+ "type": "string",
961
+ "enum": [
962
+ "syntax",
963
+ "reference",
964
+ "layout",
965
+ "design",
966
+ "rendering",
967
+ "security",
968
+ "validation",
969
+ "map",
970
+ "configuration"
971
+ ]
972
+ },
973
+ "message": {
974
+ "type": "string",
975
+ "maxLength": 4096
976
+ },
977
+ "location": {
978
+ "$ref": "#/$defs/__schema4"
979
+ },
980
+ "related": {
981
+ "maxItems": 100,
982
+ "type": "array",
983
+ "items": {
984
+ "$ref": "#/$defs/__schema4"
985
+ }
986
+ },
987
+ "operationId": {
988
+ "type": "string",
989
+ "maxLength": 256
990
+ },
991
+ "details": {
992
+ "type": "object",
993
+ "propertyNames": {
994
+ "type": "string",
995
+ "maxLength": 256
996
+ },
997
+ "additionalProperties": {}
998
+ }
999
+ },
1000
+ "required": [
1001
+ "code",
1002
+ "severity",
1003
+ "category",
1004
+ "message"
1005
+ ],
1006
+ "additionalProperties": false
1007
+ }
1008
+ },
1009
+ "unresolved": {
1010
+ "type": "array",
1011
+ "items": {
1012
+ "$ref": "#/$defs/__schema6"
1013
+ }
1014
+ },
1015
+ "sweep": {
1016
+ "type": "object",
1017
+ "properties": {
1018
+ "points": {
1019
+ "type": "array",
1020
+ "items": {
1021
+ "$ref": "#/$defs/__schema7"
1022
+ }
1023
+ },
1024
+ "rankReversals": {
1025
+ "type": "array",
1026
+ "items": {
1027
+ "type": "object",
1028
+ "properties": {
1029
+ "scenarioId": {
1030
+ "type": "string"
1031
+ },
1032
+ "path": {
1033
+ "type": "string"
1034
+ },
1035
+ "between": {
1036
+ "type": "array",
1037
+ "prefixItems": [
1038
+ {
1039
+ "type": "number"
1040
+ },
1041
+ {
1042
+ "type": "number"
1043
+ }
1044
+ ]
1045
+ },
1046
+ "beforeLeader": {
1047
+ "type": "string"
1048
+ },
1049
+ "afterLeader": {
1050
+ "type": "string"
1051
+ }
1052
+ },
1053
+ "required": [
1054
+ "scenarioId",
1055
+ "path",
1056
+ "between",
1057
+ "beforeLeader",
1058
+ "afterLeader"
1059
+ ],
1060
+ "additionalProperties": false
1061
+ }
1062
+ },
1063
+ "breakpoints": {
1064
+ "type": "array",
1065
+ "items": {
1066
+ "$ref": "#/$defs/__schema7"
1067
+ }
1068
+ },
1069
+ "localElasticities": {
1070
+ "type": "array",
1071
+ "items": {
1072
+ "type": "object",
1073
+ "properties": {
1074
+ "scenarioId": {
1075
+ "type": "string"
1076
+ },
1077
+ "path": {
1078
+ "type": "string"
1079
+ },
1080
+ "candidateId": {
1081
+ "type": "string"
1082
+ },
1083
+ "metric": {
1084
+ "type": "string",
1085
+ "enum": [
1086
+ "conditional_probability",
1087
+ "raw_value"
1088
+ ]
1089
+ },
1090
+ "between": {
1091
+ "type": "array",
1092
+ "prefixItems": [
1093
+ {
1094
+ "type": "number"
1095
+ },
1096
+ {
1097
+ "type": "number"
1098
+ }
1099
+ ]
1100
+ },
1101
+ "slope": {
1102
+ "type": "number"
1103
+ },
1104
+ "elasticity": {
1105
+ "type": "number"
1106
+ }
1107
+ },
1108
+ "required": [
1109
+ "scenarioId",
1110
+ "path",
1111
+ "candidateId",
1112
+ "metric",
1113
+ "between",
1114
+ "slope"
1115
+ ],
1116
+ "additionalProperties": false
1117
+ }
1118
+ },
1119
+ "pairwiseInteractions": {
1120
+ "type": "array",
1121
+ "items": {
1122
+ "type": "object",
1123
+ "properties": {
1124
+ "scenarioId": {
1125
+ "type": "string"
1126
+ },
1127
+ "paths": {
1128
+ "type": "array",
1129
+ "prefixItems": [
1130
+ {
1131
+ "type": "string"
1132
+ },
1133
+ {
1134
+ "type": "string"
1135
+ }
1136
+ ]
1137
+ },
1138
+ "candidateId": {
1139
+ "type": "string"
1140
+ },
1141
+ "metric": {
1142
+ "type": "string",
1143
+ "enum": [
1144
+ "conditional_probability",
1145
+ "raw_value"
1146
+ ]
1147
+ },
1148
+ "cell": {
1149
+ "type": "object",
1150
+ "properties": {
1151
+ "left": {
1152
+ "type": "array",
1153
+ "prefixItems": [
1154
+ {
1155
+ "type": "number"
1156
+ },
1157
+ {
1158
+ "type": "number"
1159
+ }
1160
+ ]
1161
+ },
1162
+ "right": {
1163
+ "type": "array",
1164
+ "prefixItems": [
1165
+ {
1166
+ "type": "number"
1167
+ },
1168
+ {
1169
+ "type": "number"
1170
+ }
1171
+ ]
1172
+ }
1173
+ },
1174
+ "required": [
1175
+ "left",
1176
+ "right"
1177
+ ],
1178
+ "additionalProperties": false
1179
+ },
1180
+ "mixedDifference": {
1181
+ "type": "number"
1182
+ },
1183
+ "mixedDifferencePerUnit": {
1184
+ "type": "number"
1185
+ }
1186
+ },
1187
+ "required": [
1188
+ "scenarioId",
1189
+ "paths",
1190
+ "candidateId",
1191
+ "metric",
1192
+ "cell",
1193
+ "mixedDifference",
1194
+ "mixedDifferencePerUnit"
1195
+ ],
1196
+ "additionalProperties": false
1197
+ }
1198
+ }
1199
+ },
1200
+ "required": [
1201
+ "points",
1202
+ "rankReversals",
1203
+ "breakpoints",
1204
+ "localElasticities",
1205
+ "pairwiseInteractions"
1206
+ ],
1207
+ "additionalProperties": false
1208
+ },
1209
+ "simulation": {
1210
+ "type": "array",
1211
+ "items": {
1212
+ "type": "object",
1213
+ "properties": {
1214
+ "scenarioId": {
1215
+ "type": "string"
1216
+ },
1217
+ "samples": {
1218
+ "type": "integer",
1219
+ "exclusiveMinimum": 0,
1220
+ "maximum": 9007199254740991
1221
+ },
1222
+ "seed": {
1223
+ "type": "integer",
1224
+ "minimum": -9007199254740991,
1225
+ "maximum": 9007199254740991
1226
+ },
1227
+ "samplingMethod": {
1228
+ "type": "string",
1229
+ "enum": [
1230
+ "latin_hypercube",
1231
+ "pseudo_random"
1232
+ ]
1233
+ },
1234
+ "rng": {
1235
+ "type": "string",
1236
+ "const": "mulberry32"
1237
+ },
1238
+ "stoppingRule": {
1239
+ "type": "string",
1240
+ "const": "fixed_sample_budget"
1241
+ },
1242
+ "confidenceLevel": {
1243
+ "type": "number",
1244
+ "minimum": 0.5,
1245
+ "maximum": 0.9999
1246
+ },
1247
+ "confidenceMethod": {
1248
+ "type": "string",
1249
+ "const": "wilson_score"
1250
+ },
1251
+ "effectiveSampleSize": {
1252
+ "type": "integer",
1253
+ "minimum": 0,
1254
+ "maximum": 9007199254740991
1255
+ },
1256
+ "globalImportance": {
1257
+ "type": "array",
1258
+ "items": {
1259
+ "type": "object",
1260
+ "properties": {
1261
+ "path": {
1262
+ "type": "string"
1263
+ },
1264
+ "candidateId": {
1265
+ "type": "string"
1266
+ },
1267
+ "metric": {
1268
+ "type": "string",
1269
+ "const": "raw_value"
1270
+ },
1271
+ "score": {
1272
+ "type": "number",
1273
+ "minimum": 0,
1274
+ "maximum": 1
1275
+ },
1276
+ "method": {
1277
+ "type": "string",
1278
+ "const": "absolute_pearson_correlation"
1279
+ },
1280
+ "observations": {
1281
+ "type": "integer",
1282
+ "minimum": 0,
1283
+ "maximum": 9007199254740991
1284
+ }
1285
+ },
1286
+ "required": [
1287
+ "path",
1288
+ "candidateId",
1289
+ "metric",
1290
+ "score",
1291
+ "method",
1292
+ "observations"
1293
+ ],
1294
+ "additionalProperties": false
1295
+ }
1296
+ },
1297
+ "convergence": {
1298
+ "type": "object",
1299
+ "properties": {
1300
+ "firstHalfSamples": {
1301
+ "type": "integer",
1302
+ "minimum": 0,
1303
+ "maximum": 9007199254740991
1304
+ },
1305
+ "secondHalfSamples": {
1306
+ "type": "integer",
1307
+ "minimum": 0,
1308
+ "maximum": 9007199254740991
1309
+ },
1310
+ "maximumFrequencyDelta": {
1311
+ "type": "number",
1312
+ "minimum": 0,
1313
+ "maximum": 1
1314
+ }
1315
+ },
1316
+ "required": [
1317
+ "firstHalfSamples",
1318
+ "secondHalfSamples",
1319
+ "maximumFrequencyDelta"
1320
+ ],
1321
+ "additionalProperties": false
1322
+ },
1323
+ "candidates": {
1324
+ "type": "array",
1325
+ "items": {
1326
+ "type": "object",
1327
+ "properties": {
1328
+ "id": {
1329
+ "type": "string"
1330
+ },
1331
+ "frequency": {
1332
+ "type": "number",
1333
+ "minimum": 0,
1334
+ "maximum": 1
1335
+ },
1336
+ "confidenceInterval": {
1337
+ "type": "object",
1338
+ "properties": {
1339
+ "low": {
1340
+ "type": "number",
1341
+ "minimum": 0,
1342
+ "maximum": 1
1343
+ },
1344
+ "high": {
1345
+ "type": "number",
1346
+ "minimum": 0,
1347
+ "maximum": 1
1348
+ }
1349
+ },
1350
+ "required": [
1351
+ "low",
1352
+ "high"
1353
+ ],
1354
+ "additionalProperties": false
1355
+ },
1356
+ "observedSelections": {
1357
+ "type": "integer",
1358
+ "minimum": 0,
1359
+ "maximum": 9007199254740991
1360
+ },
1361
+ "rawMean": {
1362
+ "type": "number"
1363
+ },
1364
+ "eligibilityFrequency": {
1365
+ "type": "number",
1366
+ "minimum": 0,
1367
+ "maximum": 1
1368
+ },
1369
+ "timingQuantilesDays": {
1370
+ "type": "object",
1371
+ "properties": {
1372
+ "p10": {
1373
+ "type": "number"
1374
+ },
1375
+ "p50": {
1376
+ "type": "number"
1377
+ },
1378
+ "p90": {
1379
+ "type": "number"
1380
+ },
1381
+ "p95": {
1382
+ "type": "number"
1383
+ }
1384
+ },
1385
+ "required": [
1386
+ "p10",
1387
+ "p50",
1388
+ "p90",
1389
+ "p95"
1390
+ ],
1391
+ "additionalProperties": false
1392
+ },
1393
+ "timingQuantileIntervals": {
1394
+ "type": "object",
1395
+ "properties": {
1396
+ "p10": {
1397
+ "type": "object",
1398
+ "properties": {
1399
+ "low": {
1400
+ "type": "number"
1401
+ },
1402
+ "high": {
1403
+ "type": "number"
1404
+ }
1405
+ },
1406
+ "required": [
1407
+ "low",
1408
+ "high"
1409
+ ],
1410
+ "additionalProperties": false
1411
+ },
1412
+ "p50": {
1413
+ "type": "object",
1414
+ "properties": {
1415
+ "low": {
1416
+ "type": "number"
1417
+ },
1418
+ "high": {
1419
+ "type": "number"
1420
+ }
1421
+ },
1422
+ "required": [
1423
+ "low",
1424
+ "high"
1425
+ ],
1426
+ "additionalProperties": false
1427
+ },
1428
+ "p90": {
1429
+ "type": "object",
1430
+ "properties": {
1431
+ "low": {
1432
+ "type": "number"
1433
+ },
1434
+ "high": {
1435
+ "type": "number"
1436
+ }
1437
+ },
1438
+ "required": [
1439
+ "low",
1440
+ "high"
1441
+ ],
1442
+ "additionalProperties": false
1443
+ },
1444
+ "p95": {
1445
+ "type": "object",
1446
+ "properties": {
1447
+ "low": {
1448
+ "type": "number"
1449
+ },
1450
+ "high": {
1451
+ "type": "number"
1452
+ }
1453
+ },
1454
+ "required": [
1455
+ "low",
1456
+ "high"
1457
+ ],
1458
+ "additionalProperties": false
1459
+ }
1460
+ },
1461
+ "required": [
1462
+ "p10",
1463
+ "p50",
1464
+ "p90",
1465
+ "p95"
1466
+ ],
1467
+ "additionalProperties": false
1468
+ },
1469
+ "timingSampleCount": {
1470
+ "type": "integer",
1471
+ "minimum": 0,
1472
+ "maximum": 9007199254740991
1473
+ },
1474
+ "timingEvaluations": {
1475
+ "type": "integer",
1476
+ "minimum": 0,
1477
+ "maximum": 9007199254740991
1478
+ },
1479
+ "timingReservoirCapacity": {
1480
+ "type": "integer",
1481
+ "exclusiveMinimum": 0,
1482
+ "maximum": 9007199254740991
1483
+ },
1484
+ "timingMethod": {
1485
+ "type": "string",
1486
+ "const": "sampled_discrete_daily_hazard"
1487
+ },
1488
+ "timingConfidenceMethod": {
1489
+ "type": "string",
1490
+ "const": "normal_order_statistic"
1491
+ }
1492
+ },
1493
+ "required": [
1494
+ "id",
1495
+ "eligibilityFrequency"
1496
+ ],
1497
+ "additionalProperties": false
1498
+ }
1499
+ }
1500
+ },
1501
+ "required": [
1502
+ "scenarioId",
1503
+ "samples",
1504
+ "seed",
1505
+ "samplingMethod",
1506
+ "rng",
1507
+ "stoppingRule",
1508
+ "confidenceLevel",
1509
+ "confidenceMethod",
1510
+ "effectiveSampleSize",
1511
+ "globalImportance",
1512
+ "convergence",
1513
+ "candidates"
1514
+ ],
1515
+ "additionalProperties": false
1516
+ }
1517
+ },
1518
+ "sequence": {
1519
+ "type": "object",
1520
+ "properties": {
1521
+ "scenarioId": {
1522
+ "type": "string"
1523
+ },
1524
+ "method": {
1525
+ "type": "string",
1526
+ "enum": [
1527
+ "exact_state_distribution",
1528
+ "bounded_beam",
1529
+ "seeded_monte_carlo"
1530
+ ]
1531
+ },
1532
+ "steps": {
1533
+ "type": "integer",
1534
+ "minimum": 0,
1535
+ "maximum": 9007199254740991
1536
+ },
1537
+ "samples": {
1538
+ "type": "integer",
1539
+ "exclusiveMinimum": 0,
1540
+ "maximum": 9007199254740991
1541
+ },
1542
+ "seed": {
1543
+ "type": "integer",
1544
+ "minimum": -9007199254740991,
1545
+ "maximum": 9007199254740991
1546
+ },
1547
+ "rng": {
1548
+ "type": "string",
1549
+ "const": "mulberry32"
1550
+ },
1551
+ "stoppingRule": {
1552
+ "type": "string",
1553
+ "const": "fixed_sample_budget"
1554
+ },
1555
+ "confidenceLevel": {
1556
+ "type": "number",
1557
+ "minimum": 0.5,
1558
+ "maximum": 0.9999
1559
+ },
1560
+ "terminalProbability": {
1561
+ "type": "number",
1562
+ "minimum": 0,
1563
+ "maximum": 1
1564
+ },
1565
+ "stateCount": {
1566
+ "type": "integer",
1567
+ "minimum": 0,
1568
+ "maximum": 9007199254740991
1569
+ },
1570
+ "omittedProbability": {
1571
+ "type": "number",
1572
+ "minimum": 0,
1573
+ "maximum": 1
1574
+ },
1575
+ "candidates": {
1576
+ "type": "array",
1577
+ "items": {
1578
+ "type": "object",
1579
+ "properties": {
1580
+ "id": {
1581
+ "type": "string"
1582
+ },
1583
+ "nextSelectionProbability": {
1584
+ "type": "number",
1585
+ "minimum": 0,
1586
+ "maximum": 1
1587
+ },
1588
+ "expectedSelections": {
1589
+ "type": "number",
1590
+ "minimum": 0
1591
+ },
1592
+ "everSelectedProbability": {
1593
+ "type": "number",
1594
+ "minimum": 0,
1595
+ "maximum": 1
1596
+ },
1597
+ "starvationProbability": {
1598
+ "type": "number",
1599
+ "minimum": 0,
1600
+ "maximum": 1
1601
+ },
1602
+ "expectedFirstSelectionDay": {
1603
+ "type": "number",
1604
+ "minimum": 0
1605
+ },
1606
+ "countDistribution": {
1607
+ "type": "array",
1608
+ "items": {
1609
+ "type": "object",
1610
+ "properties": {
1611
+ "count": {
1612
+ "type": "integer",
1613
+ "minimum": 0,
1614
+ "maximum": 9007199254740991
1615
+ },
1616
+ "probability": {
1617
+ "type": "number",
1618
+ "minimum": 0,
1619
+ "maximum": 1
1620
+ }
1621
+ },
1622
+ "required": [
1623
+ "count",
1624
+ "probability"
1625
+ ],
1626
+ "additionalProperties": false
1627
+ }
1628
+ }
1629
+ },
1630
+ "required": [
1631
+ "id",
1632
+ "nextSelectionProbability",
1633
+ "expectedSelections",
1634
+ "everSelectedProbability",
1635
+ "starvationProbability",
1636
+ "countDistribution"
1637
+ ],
1638
+ "additionalProperties": false
1639
+ }
1640
+ },
1641
+ "categories": {
1642
+ "type": "array",
1643
+ "items": {
1644
+ "type": "object",
1645
+ "properties": {
1646
+ "id": {
1647
+ "type": "string"
1648
+ },
1649
+ "nextSelectionProbability": {
1650
+ "type": "number",
1651
+ "minimum": 0,
1652
+ "maximum": 1
1653
+ },
1654
+ "expectedSelections": {
1655
+ "type": "number",
1656
+ "minimum": 0
1657
+ },
1658
+ "everSelectedProbability": {
1659
+ "type": "number",
1660
+ "minimum": 0,
1661
+ "maximum": 1
1662
+ },
1663
+ "starvationProbability": {
1664
+ "type": "number",
1665
+ "minimum": 0,
1666
+ "maximum": 1
1667
+ },
1668
+ "expectedFirstSelectionDay": {
1669
+ "type": "number",
1670
+ "minimum": 0
1671
+ }
1672
+ },
1673
+ "required": [
1674
+ "id",
1675
+ "nextSelectionProbability",
1676
+ "expectedSelections",
1677
+ "everSelectedProbability",
1678
+ "starvationProbability"
1679
+ ],
1680
+ "additionalProperties": false
1681
+ }
1682
+ },
1683
+ "topPaths": {
1684
+ "type": "array",
1685
+ "items": {
1686
+ "type": "object",
1687
+ "properties": {
1688
+ "candidateIds": {
1689
+ "type": "array",
1690
+ "items": {
1691
+ "type": "string"
1692
+ }
1693
+ },
1694
+ "probability": {
1695
+ "type": "number",
1696
+ "minimum": 0,
1697
+ "maximum": 1
1698
+ },
1699
+ "terminal": {
1700
+ "type": "boolean"
1701
+ },
1702
+ "endDay": {
1703
+ "type": "number",
1704
+ "minimum": 0
1705
+ }
1706
+ },
1707
+ "required": [
1708
+ "candidateIds",
1709
+ "probability",
1710
+ "terminal",
1711
+ "endDay"
1712
+ ],
1713
+ "additionalProperties": false
1714
+ }
1715
+ },
1716
+ "timeline": {
1717
+ "type": "array",
1718
+ "items": {
1719
+ "type": "object",
1720
+ "properties": {
1721
+ "step": {
1722
+ "type": "integer",
1723
+ "minimum": 0,
1724
+ "maximum": 9007199254740991
1725
+ },
1726
+ "day": {
1727
+ "type": "number",
1728
+ "minimum": 0
1729
+ },
1730
+ "leadingCandidate": {
1731
+ "type": "string"
1732
+ },
1733
+ "terminalProbability": {
1734
+ "type": "number",
1735
+ "minimum": 0,
1736
+ "maximum": 1
1737
+ }
1738
+ },
1739
+ "required": [
1740
+ "step",
1741
+ "day",
1742
+ "terminalProbability"
1743
+ ],
1744
+ "additionalProperties": false
1745
+ }
1746
+ }
1747
+ },
1748
+ "required": [
1749
+ "scenarioId",
1750
+ "method",
1751
+ "steps",
1752
+ "terminalProbability",
1753
+ "stateCount",
1754
+ "candidates",
1755
+ "categories",
1756
+ "topPaths",
1757
+ "timeline"
1758
+ ],
1759
+ "additionalProperties": false
1760
+ },
1761
+ "comparison": {
1762
+ "type": "object",
1763
+ "properties": {
1764
+ "beforeAnalysisId": {
1765
+ "type": "string"
1766
+ },
1767
+ "afterAnalysisId": {
1768
+ "type": "string"
1769
+ },
1770
+ "scenarioChanges": {
1771
+ "type": "array",
1772
+ "items": {
1773
+ "type": "object",
1774
+ "properties": {
1775
+ "scenarioId": {
1776
+ "type": "string"
1777
+ },
1778
+ "candidateId": {
1779
+ "type": "string"
1780
+ },
1781
+ "rawDelta": {
1782
+ "type": "number"
1783
+ },
1784
+ "probabilityDelta": {
1785
+ "type": "number"
1786
+ },
1787
+ "timingDeltaDays": {
1788
+ "type": "number"
1789
+ },
1790
+ "cumulativeChanceDelta": {
1791
+ "type": "number"
1792
+ },
1793
+ "rankDelta": {
1794
+ "type": "integer",
1795
+ "minimum": -9007199254740991,
1796
+ "maximum": 9007199254740991
1797
+ },
1798
+ "eligibilityChange": {
1799
+ "type": "object",
1800
+ "properties": {
1801
+ "before": {
1802
+ "type": "string",
1803
+ "enum": [
1804
+ "true",
1805
+ "false",
1806
+ "unresolved"
1807
+ ]
1808
+ },
1809
+ "after": {
1810
+ "type": "string",
1811
+ "enum": [
1812
+ "true",
1813
+ "false",
1814
+ "unresolved"
1815
+ ]
1816
+ }
1817
+ },
1818
+ "required": [
1819
+ "before",
1820
+ "after"
1821
+ ],
1822
+ "additionalProperties": false
1823
+ },
1824
+ "unresolvedDelta": {
1825
+ "type": "integer",
1826
+ "minimum": -9007199254740991,
1827
+ "maximum": 9007199254740991
1828
+ },
1829
+ "attribution": {
1830
+ "type": "array",
1831
+ "items": {
1832
+ "type": "string"
1833
+ }
1834
+ },
1835
+ "changedAstPaths": {
1836
+ "type": "array",
1837
+ "items": {
1838
+ "type": "object",
1839
+ "properties": {
1840
+ "change": {
1841
+ "type": "string",
1842
+ "enum": [
1843
+ "added",
1844
+ "removed"
1845
+ ]
1846
+ },
1847
+ "path": {
1848
+ "type": "string"
1849
+ },
1850
+ "astPath": {
1851
+ "type": "array",
1852
+ "items": {
1853
+ "type": "string"
1854
+ }
1855
+ }
1856
+ },
1857
+ "required": [
1858
+ "change",
1859
+ "path",
1860
+ "astPath"
1861
+ ],
1862
+ "additionalProperties": false
1863
+ }
1864
+ }
1865
+ },
1866
+ "required": [
1867
+ "scenarioId",
1868
+ "candidateId",
1869
+ "unresolvedDelta",
1870
+ "attribution",
1871
+ "changedAstPaths"
1872
+ ],
1873
+ "additionalProperties": false
1874
+ }
1875
+ },
1876
+ "assumptionsChanged": {
1877
+ "type": "boolean"
1878
+ },
1879
+ "adapterChanged": {
1880
+ "type": "boolean"
1881
+ },
1882
+ "regressions": {
1883
+ "type": "array",
1884
+ "items": {
1885
+ "type": "object",
1886
+ "properties": {
1887
+ "code": {
1888
+ "type": "string"
1889
+ },
1890
+ "message": {
1891
+ "type": "string"
1892
+ },
1893
+ "scenarioId": {
1894
+ "type": "string"
1895
+ },
1896
+ "candidateId": {
1897
+ "type": "string"
1898
+ }
1899
+ },
1900
+ "required": [
1901
+ "code",
1902
+ "message"
1903
+ ],
1904
+ "additionalProperties": false
1905
+ }
1906
+ }
1907
+ },
1908
+ "required": [
1909
+ "beforeAnalysisId",
1910
+ "afterAnalysisId",
1911
+ "scenarioChanges",
1912
+ "assumptionsChanged",
1913
+ "adapterChanged",
1914
+ "regressions"
1915
+ ],
1916
+ "additionalProperties": false
1917
+ },
1918
+ "resources": {
1919
+ "type": "array",
1920
+ "items": {
1921
+ "type": "object",
1922
+ "properties": {
1923
+ "uri": {
1924
+ "type": "string",
1925
+ "maxLength": 4096,
1926
+ "format": "uri"
1927
+ },
1928
+ "name": {
1929
+ "type": "string",
1930
+ "minLength": 1,
1931
+ "maxLength": 255
1932
+ },
1933
+ "mimeType": {
1934
+ "type": "string",
1935
+ "minLength": 1,
1936
+ "maxLength": 255
1937
+ },
1938
+ "size": {
1939
+ "type": "integer",
1940
+ "minimum": 0,
1941
+ "maximum": 9007199254740991
1942
+ },
1943
+ "sha256": {
1944
+ "type": "string",
1945
+ "pattern": "^[a-f0-9]{64}$"
1946
+ },
1947
+ "description": {
1948
+ "type": "string",
1949
+ "maxLength": 4096
1950
+ }
1951
+ },
1952
+ "required": [
1953
+ "uri",
1954
+ "name",
1955
+ "mimeType"
1956
+ ],
1957
+ "additionalProperties": false
1958
+ }
1959
+ }
1960
+ },
1961
+ "required": [
1962
+ "schemaVersion",
1963
+ "status",
1964
+ "operation",
1965
+ "analysisId",
1966
+ "metadata",
1967
+ "adapter",
1968
+ "scenarios",
1969
+ "diagnostics",
1970
+ "unresolved",
1971
+ "resources"
1972
+ ],
1973
+ "additionalProperties": false,
1974
+ "$defs": {
1975
+ "__schema0": {
1976
+ "type": "string",
1977
+ "enum": [
1978
+ "event_mean_time_to_happen",
1979
+ "event_option_ai_chance",
1980
+ "decision_ai_will_do",
1981
+ "mission_ai_will_do",
1982
+ "national_focus_ai_will_do",
1983
+ "technology_ai_will_do",
1984
+ "doctrine_ai_will_do",
1985
+ "direct_random",
1986
+ "random_list",
1987
+ "ai_strategy_factor",
1988
+ "custom_weighted_pool"
1989
+ ]
1990
+ },
1991
+ "__schema1": {
1992
+ "type": "string",
1993
+ "enum": [
1994
+ "conditional_probability",
1995
+ "raw_value",
1996
+ "cumulative_chance",
1997
+ "effective_mtth_days"
1998
+ ]
1999
+ },
2000
+ "__schema2": {
2001
+ "type": "object",
2002
+ "properties": {
2003
+ "numerator": {
2004
+ "type": "string",
2005
+ "pattern": "^-?\\d+$"
2006
+ },
2007
+ "denominator": {
2008
+ "type": "string",
2009
+ "pattern": "^\\d+$"
2010
+ },
2011
+ "decimal": {
2012
+ "type": "string"
2013
+ },
2014
+ "value": {
2015
+ "type": "number"
2016
+ }
2017
+ },
2018
+ "required": [
2019
+ "numerator",
2020
+ "denominator",
2021
+ "decimal",
2022
+ "value"
2023
+ ],
2024
+ "additionalProperties": false
2025
+ },
2026
+ "__schema3": {
2027
+ "type": "object",
2028
+ "properties": {
2029
+ "path": {
2030
+ "type": "string"
2031
+ },
2032
+ "rootKind": {
2033
+ "type": "string"
2034
+ },
2035
+ "loadOrder": {
2036
+ "type": "integer",
2037
+ "minimum": -9007199254740991,
2038
+ "maximum": 9007199254740991
2039
+ },
2040
+ "sourceHash": {
2041
+ "type": "string"
2042
+ },
2043
+ "location": {
2044
+ "$ref": "#/$defs/__schema4"
2045
+ },
2046
+ "astPath": {
2047
+ "type": "array",
2048
+ "items": {
2049
+ "type": "string"
2050
+ }
2051
+ },
2052
+ "symbol": {
2053
+ "type": "string"
2054
+ },
2055
+ "helperChain": {
2056
+ "type": "array",
2057
+ "items": {
2058
+ "type": "string"
2059
+ }
2060
+ }
2061
+ },
2062
+ "required": [
2063
+ "path",
2064
+ "rootKind",
2065
+ "loadOrder",
2066
+ "sourceHash"
2067
+ ],
2068
+ "additionalProperties": false
2069
+ },
2070
+ "__schema4": {
2071
+ "type": "object",
2072
+ "properties": {
2073
+ "path": {
2074
+ "type": "string",
2075
+ "minLength": 1,
2076
+ "maxLength": 4096
2077
+ },
2078
+ "start": {
2079
+ "$ref": "#/$defs/__schema5"
2080
+ },
2081
+ "end": {
2082
+ "$ref": "#/$defs/__schema5"
2083
+ },
2084
+ "symbol": {
2085
+ "type": "string",
2086
+ "maxLength": 1024
2087
+ }
2088
+ },
2089
+ "required": [
2090
+ "path",
2091
+ "start",
2092
+ "end"
2093
+ ],
2094
+ "additionalProperties": false
2095
+ },
2096
+ "__schema5": {
2097
+ "type": "object",
2098
+ "properties": {
2099
+ "line": {
2100
+ "type": "integer",
2101
+ "minimum": 1,
2102
+ "maximum": 9007199254740991
2103
+ },
2104
+ "column": {
2105
+ "type": "integer",
2106
+ "minimum": 1,
2107
+ "maximum": 9007199254740991
2108
+ },
2109
+ "offset": {
2110
+ "type": "integer",
2111
+ "minimum": 0,
2112
+ "maximum": 9007199254740991
2113
+ }
2114
+ },
2115
+ "required": [
2116
+ "line",
2117
+ "column",
2118
+ "offset"
2119
+ ],
2120
+ "additionalProperties": false
2121
+ },
2122
+ "__schema6": {
2123
+ "type": "object",
2124
+ "properties": {
2125
+ "code": {
2126
+ "type": "string"
2127
+ },
2128
+ "message": {
2129
+ "type": "string"
2130
+ },
2131
+ "path": {
2132
+ "type": "string"
2133
+ },
2134
+ "candidateId": {
2135
+ "type": "string"
2136
+ },
2137
+ "provenance": {
2138
+ "$ref": "#/$defs/__schema3"
2139
+ },
2140
+ "details": {
2141
+ "type": "object",
2142
+ "propertyNames": {
2143
+ "type": "string"
2144
+ },
2145
+ "additionalProperties": {}
2146
+ }
2147
+ },
2148
+ "required": [
2149
+ "code",
2150
+ "message"
2151
+ ],
2152
+ "additionalProperties": false
2153
+ },
2154
+ "__schema7": {
2155
+ "type": "object",
2156
+ "properties": {
2157
+ "scenarioId": {
2158
+ "type": "string"
2159
+ },
2160
+ "path": {
2161
+ "type": "string"
2162
+ },
2163
+ "value": {
2164
+ "type": "number"
2165
+ },
2166
+ "values": {
2167
+ "type": "object",
2168
+ "propertyNames": {
2169
+ "type": "string"
2170
+ },
2171
+ "additionalProperties": {
2172
+ "type": "number"
2173
+ }
2174
+ },
2175
+ "candidates": {
2176
+ "type": "array",
2177
+ "items": {
2178
+ "type": "object",
2179
+ "properties": {
2180
+ "id": {
2181
+ "type": "string"
2182
+ },
2183
+ "rawValue": {
2184
+ "type": "number"
2185
+ },
2186
+ "conditionalProbability": {
2187
+ "type": "number"
2188
+ },
2189
+ "rank": {
2190
+ "type": "integer",
2191
+ "minimum": -9007199254740991,
2192
+ "maximum": 9007199254740991
2193
+ }
2194
+ },
2195
+ "required": [
2196
+ "id"
2197
+ ],
2198
+ "additionalProperties": false
2199
+ }
2200
+ }
2201
+ },
2202
+ "required": [
2203
+ "scenarioId",
2204
+ "path",
2205
+ "value",
2206
+ "candidates"
2207
+ ],
2208
+ "additionalProperties": false
2209
+ }
2210
+ }
2211
+ }