ephemeris-cli 0.0.0-stage → 0.4.0

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,628 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "type": "object",
4
+ "additionalProperties": false,
5
+ "title": "Ephemeris forecast artifact v1",
6
+ "description": "Includes all submitted history. The API response is preserved before interpretation; it may be malformed and rejected by describe/plot. Context is never sent to the API. Hashes are integrity checks, not signatures. No Gnomon import exists.",
7
+ "required": [
8
+ "kind",
9
+ "schema_version",
10
+ "artifact_id",
11
+ "created_at",
12
+ "request",
13
+ "request_sha256",
14
+ "response",
15
+ "context",
16
+ "transport",
17
+ "disclosure",
18
+ "interoperability"
19
+ ],
20
+ "properties": {
21
+ "kind": {
22
+ "const": "ephemeris.forecast"
23
+ },
24
+ "schema_version": {
25
+ "const": "1"
26
+ },
27
+ "artifact_id": {
28
+ "type": "string",
29
+ "format": "uuid"
30
+ },
31
+ "created_at": {
32
+ "type": "string",
33
+ "format": "date-time"
34
+ },
35
+ "request": {
36
+ "$ref": "#/$defs/ForecastRequest"
37
+ },
38
+ "request_sha256": {
39
+ "type": "string",
40
+ "pattern": "^[a-f0-9]{64}$"
41
+ },
42
+ "response": {
43
+ "type": "object",
44
+ "additionalProperties": true
45
+ },
46
+ "context": {
47
+ "type": "object",
48
+ "required": [
49
+ "series"
50
+ ],
51
+ "additionalProperties": false,
52
+ "properties": {
53
+ "series": {
54
+ "type": "array",
55
+ "items": {
56
+ "type": "object",
57
+ "additionalProperties": false,
58
+ "properties": {
59
+ "series_id": {
60
+ "type": [
61
+ "string",
62
+ "null"
63
+ ]
64
+ },
65
+ "unit": {
66
+ "type": [
67
+ "string",
68
+ "null"
69
+ ]
70
+ },
71
+ "timezone": {
72
+ "type": [
73
+ "string",
74
+ "null"
75
+ ]
76
+ },
77
+ "target_description": {
78
+ "type": [
79
+ "string",
80
+ "null"
81
+ ]
82
+ },
83
+ "measurement": {
84
+ "enum": [
85
+ "period_total",
86
+ "period_average",
87
+ "point_in_time",
88
+ null
89
+ ]
90
+ },
91
+ "timestamps": {
92
+ "type": [
93
+ "array",
94
+ "null"
95
+ ],
96
+ "items": {
97
+ "type": "string"
98
+ }
99
+ },
100
+ "source_available_at": {
101
+ "type": [
102
+ "string",
103
+ "null"
104
+ ]
105
+ },
106
+ "recorded_as_of": {
107
+ "type": [
108
+ "string",
109
+ "null"
110
+ ]
111
+ },
112
+ "future_covariate_roles": {
113
+ "type": "object",
114
+ "additionalProperties": {
115
+ "enum": [
116
+ "known_future",
117
+ "scenario_assumption",
118
+ "unspecified"
119
+ ]
120
+ }
121
+ },
122
+ "future_axis": {
123
+ "type": "object",
124
+ "required": [
125
+ "kind",
126
+ "values",
127
+ "reason"
128
+ ],
129
+ "properties": {
130
+ "kind": {
131
+ "enum": [
132
+ "steps",
133
+ "timestamps"
134
+ ]
135
+ },
136
+ "values": {
137
+ "type": "array",
138
+ "items": {
139
+ "type": [
140
+ "string",
141
+ "integer"
142
+ ]
143
+ }
144
+ },
145
+ "reason": {
146
+ "type": "string"
147
+ }
148
+ },
149
+ "additionalProperties": false
150
+ },
151
+ "frequency_evidence": {
152
+ "type": "object",
153
+ "required": [
154
+ "basis",
155
+ "regular",
156
+ "missing_periods",
157
+ "coverage"
158
+ ],
159
+ "additionalProperties": true
160
+ }
161
+ },
162
+ "required": [
163
+ "series_id",
164
+ "unit",
165
+ "timezone",
166
+ "target_description",
167
+ "measurement",
168
+ "timestamps",
169
+ "future_axis",
170
+ "frequency_evidence",
171
+ "future_covariate_roles"
172
+ ]
173
+ }
174
+ },
175
+ "scenario_assumptions": {
176
+ "type": "array",
177
+ "items": {
178
+ "type": "string"
179
+ }
180
+ },
181
+ "snapshot_id": {
182
+ "type": [
183
+ "string",
184
+ "null"
185
+ ]
186
+ },
187
+ "source": {
188
+ "type": [
189
+ "object",
190
+ "null"
191
+ ]
192
+ }
193
+ }
194
+ },
195
+ "transport": {
196
+ "type": "object",
197
+ "properties": {
198
+ "origin": {
199
+ "type": "string"
200
+ },
201
+ "idempotency_key": {
202
+ "type": "string"
203
+ },
204
+ "request_id": {
205
+ "type": [
206
+ "string",
207
+ "null"
208
+ ]
209
+ },
210
+ "http_status": {
211
+ "type": "integer"
212
+ },
213
+ "retry_after": {
214
+ "type": [
215
+ "string",
216
+ "null"
217
+ ]
218
+ },
219
+ "idempotency_replayed": {
220
+ "type": [
221
+ "string",
222
+ "null"
223
+ ]
224
+ },
225
+ "credentials_redacted": {
226
+ "type": "boolean"
227
+ }
228
+ },
229
+ "additionalProperties": false
230
+ },
231
+ "disclosure": {
232
+ "type": "object",
233
+ "required": [
234
+ "input_history_included",
235
+ "context_sent_to_api",
236
+ "credentials_included"
237
+ ],
238
+ "properties": {
239
+ "input_history_included": {
240
+ "const": true
241
+ },
242
+ "context_sent_to_api": {
243
+ "const": false
244
+ },
245
+ "credentials_included": {
246
+ "const": false
247
+ },
248
+ "provider_input_note": {
249
+ "type": "string"
250
+ }
251
+ },
252
+ "additionalProperties": false
253
+ },
254
+ "interoperability": {
255
+ "type": "object",
256
+ "properties": {
257
+ "gnomon_import": {
258
+ "const": "not_implemented"
259
+ },
260
+ "recorded_in_ledger": {
261
+ "const": false
262
+ },
263
+ "identity_basis": {
264
+ "type": "string"
265
+ }
266
+ },
267
+ "additionalProperties": false
268
+ }
269
+ },
270
+ "$defs": {
271
+ "Error": {
272
+ "type": "object",
273
+ "required": [
274
+ "error"
275
+ ],
276
+ "properties": {
277
+ "error": {
278
+ "type": "string"
279
+ }
280
+ }
281
+ },
282
+ "Balance": {
283
+ "type": "object",
284
+ "required": [
285
+ "balance_mc",
286
+ "active_holds_mc"
287
+ ],
288
+ "properties": {
289
+ "balance_mc": {
290
+ "type": "string",
291
+ "pattern": "^-?[0-9]+$"
292
+ },
293
+ "active_holds_mc": {
294
+ "type": "string",
295
+ "pattern": "^[0-9]+$"
296
+ }
297
+ }
298
+ },
299
+ "Model": {
300
+ "type": "object",
301
+ "required": [
302
+ "name",
303
+ "price_per_kslot_mc",
304
+ "billing_context_cap"
305
+ ],
306
+ "properties": {
307
+ "name": {
308
+ "type": "string"
309
+ },
310
+ "price_per_kslot_mc": {
311
+ "type": [
312
+ "string",
313
+ "null"
314
+ ]
315
+ },
316
+ "billing_context_cap": {
317
+ "type": [
318
+ "integer",
319
+ "null"
320
+ ]
321
+ }
322
+ },
323
+ "additionalProperties": true
324
+ },
325
+ "ForecastSeries": {
326
+ "type": "object",
327
+ "required": [
328
+ "values"
329
+ ],
330
+ "properties": {
331
+ "values": {
332
+ "oneOf": [
333
+ {
334
+ "type": "array",
335
+ "minItems": 1,
336
+ "items": {
337
+ "type": "number"
338
+ }
339
+ },
340
+ {
341
+ "type": "array",
342
+ "minItems": 1,
343
+ "items": {
344
+ "type": "array",
345
+ "minItems": 1,
346
+ "items": {
347
+ "type": "number"
348
+ }
349
+ }
350
+ }
351
+ ]
352
+ },
353
+ "freq": {
354
+ "type": "string",
355
+ "minLength": 1,
356
+ "description": "Optional per-series frequency. Mixed-frequency batches are split into compatible upstream calls and reassembled in request order."
357
+ },
358
+ "covariates": {
359
+ "$ref": "#/$defs/SeriesCovariates"
360
+ }
361
+ },
362
+ "additionalProperties": true
363
+ },
364
+ "SeriesCovariates": {
365
+ "type": "object",
366
+ "required": [
367
+ "past"
368
+ ],
369
+ "properties": {
370
+ "past": {
371
+ "type": "object",
372
+ "additionalProperties": {
373
+ "type": "array",
374
+ "items": {
375
+ "type": "number"
376
+ }
377
+ },
378
+ "description": "Named historical channels aligned to the series context length."
379
+ },
380
+ "future": {
381
+ "type": "object",
382
+ "additionalProperties": {
383
+ "type": "array",
384
+ "items": {
385
+ "type": "number"
386
+ }
387
+ },
388
+ "description": "Optional known-future channels aligned to the requested horizon. Every future channel must also have past history."
389
+ }
390
+ },
391
+ "additionalProperties": false
392
+ },
393
+ "ForecastRequest": {
394
+ "type": "object",
395
+ "required": [
396
+ "mode",
397
+ "series"
398
+ ],
399
+ "properties": {
400
+ "mode": {
401
+ "type": "string",
402
+ "enum": [
403
+ "explicit",
404
+ "ensemble",
405
+ "route"
406
+ ]
407
+ },
408
+ "model": {
409
+ "type": "string"
410
+ },
411
+ "series": {
412
+ "type": "array",
413
+ "minItems": 1,
414
+ "maxItems": 64,
415
+ "items": {
416
+ "$ref": "#/$defs/ForecastSeries"
417
+ }
418
+ },
419
+ "context_len": {
420
+ "type": "integer",
421
+ "minimum": 1,
422
+ "maximum": 16384
423
+ },
424
+ "horizon": {
425
+ "type": "integer",
426
+ "minimum": 1,
427
+ "maximum": 4096,
428
+ "description": "Maximum 4096 steps. Slots x horizon x quantiles must not exceed 120000 output values; omitted or empty quantiles are budgeted as 21."
429
+ },
430
+ "quantiles": {
431
+ "type": "array",
432
+ "maxItems": 21,
433
+ "items": {
434
+ "type": "number",
435
+ "exclusiveMinimum": 0,
436
+ "exclusiveMaximum": 1
437
+ }
438
+ },
439
+ "top_k": {
440
+ "type": [
441
+ "integer",
442
+ "null"
443
+ ],
444
+ "minimum": 1,
445
+ "maximum": 16,
446
+ "description": "Optional ensemble-only limit on the number of models."
447
+ },
448
+ "combine": {
449
+ "type": "string",
450
+ "enum": [
451
+ "mixture",
452
+ "vincentize"
453
+ ],
454
+ "description": "Optional ensemble combination method."
455
+ }
456
+ },
457
+ "additionalProperties": true
458
+ },
459
+ "ForecastResponse": {
460
+ "type": "object",
461
+ "required": [
462
+ "meta"
463
+ ],
464
+ "properties": {
465
+ "meta": {
466
+ "type": "object",
467
+ "required": [
468
+ "gateway_request_id",
469
+ "billing"
470
+ ],
471
+ "properties": {
472
+ "gateway_request_id": {
473
+ "type": "string"
474
+ },
475
+ "request_id": {
476
+ "type": "string"
477
+ },
478
+ "models_used": {
479
+ "type": "array",
480
+ "items": {
481
+ "type": "string"
482
+ }
483
+ },
484
+ "upstream_request_ids": {
485
+ "type": "array",
486
+ "items": {
487
+ "type": "string"
488
+ },
489
+ "description": "Model request IDs when a mixed-frequency request is split into compatible groups."
490
+ },
491
+ "upstream_calls": {
492
+ "type": "integer",
493
+ "minimum": 1
494
+ },
495
+ "billing": {
496
+ "type": "object",
497
+ "required": [
498
+ "settled_mc",
499
+ "balance_mc"
500
+ ],
501
+ "properties": {
502
+ "settled_mc": {
503
+ "type": "string"
504
+ },
505
+ "balance_mc": {
506
+ "type": "string"
507
+ }
508
+ }
509
+ }
510
+ },
511
+ "additionalProperties": true
512
+ }
513
+ },
514
+ "additionalProperties": true
515
+ },
516
+ "InsufficientCredits": {
517
+ "type": "object",
518
+ "required": [
519
+ "error",
520
+ "balance_mc",
521
+ "required_mc",
522
+ "topup_url"
523
+ ],
524
+ "properties": {
525
+ "error": {
526
+ "type": "string"
527
+ },
528
+ "balance_mc": {
529
+ "type": "string"
530
+ },
531
+ "required_mc": {
532
+ "type": "string"
533
+ },
534
+ "topup_url": {
535
+ "type": "string",
536
+ "format": "uri"
537
+ }
538
+ }
539
+ },
540
+ "UsageRow": {
541
+ "type": "object",
542
+ "required": [
543
+ "requestId"
544
+ ],
545
+ "properties": {
546
+ "requestId": {
547
+ "type": "string"
548
+ },
549
+ "paracastRequestId": {
550
+ "type": [
551
+ "string",
552
+ "null"
553
+ ]
554
+ },
555
+ "estimatedMc": {
556
+ "type": [
557
+ "string",
558
+ "null"
559
+ ]
560
+ },
561
+ "settledMc": {
562
+ "type": [
563
+ "string",
564
+ "null"
565
+ ]
566
+ },
567
+ "status": {
568
+ "type": [
569
+ "integer",
570
+ "null"
571
+ ]
572
+ }
573
+ },
574
+ "additionalProperties": true
575
+ },
576
+ "UsagePage": {
577
+ "type": "object",
578
+ "required": [
579
+ "data",
580
+ "pagination"
581
+ ],
582
+ "properties": {
583
+ "data": {
584
+ "type": "array",
585
+ "items": {
586
+ "$ref": "#/$defs/UsageRow"
587
+ }
588
+ },
589
+ "limit": {
590
+ "type": "integer"
591
+ },
592
+ "offset": {
593
+ "type": "integer"
594
+ },
595
+ "pagination": {
596
+ "type": "object",
597
+ "required": [
598
+ "limit",
599
+ "offset",
600
+ "returned",
601
+ "has_more",
602
+ "next_offset"
603
+ ],
604
+ "properties": {
605
+ "limit": {
606
+ "type": "integer"
607
+ },
608
+ "offset": {
609
+ "type": "integer"
610
+ },
611
+ "returned": {
612
+ "type": "integer"
613
+ },
614
+ "has_more": {
615
+ "type": "boolean"
616
+ },
617
+ "next_offset": {
618
+ "type": [
619
+ "integer",
620
+ "null"
621
+ ]
622
+ }
623
+ }
624
+ }
625
+ }
626
+ }
627
+ }
628
+ }