@orangecharts/wrun-chart-host 0.3.0 → 0.5.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.
- package/README.md +23 -6
- package/dist/constants/exchange-names.leaf.d.ts +8 -0
- package/dist/constants/exchange-names.leaf.js +101 -0
- package/dist/constants/kscript-data-interval-restrictions.constants.d.ts +15 -0
- package/dist/constants/kscript-data-interval-restrictions.constants.js +40 -0
- package/dist/constants/opra-compliance.constants.d.ts +19 -0
- package/dist/constants/opra-compliance.constants.js +19 -0
- package/dist/constants/replay-ladder.leaf.d.ts +30 -0
- package/dist/constants/replay-ladder.leaf.js +99 -0
- package/dist/constants/scriptEditor/builtin-script-snippets.d.ts +133 -0
- package/dist/constants/scriptEditor/builtin-script-snippets.js +451 -0
- package/dist/constants/scriptEditor/cme-official-scripts.constants.d.ts +168 -0
- package/dist/constants/scriptEditor/cme-official-scripts.constants.js +398 -0
- package/dist/constants/scriptEditor/converted-script-id.leaf.d.ts +8 -0
- package/dist/constants/scriptEditor/converted-script-id.leaf.js +10 -0
- package/dist/constants/scriptEditor/execution.constants.d.ts +4 -0
- package/dist/constants/scriptEditor/execution.constants.js +14 -0
- package/dist/constants/wrun-prefix-safe.constants.d.ts +23 -0
- package/dist/constants/wrun-prefix-safe.constants.js +26 -0
- package/dist/host-env.d.ts +321 -24
- package/dist/host-env.js +15 -0
- package/dist/host-ports.types.d.ts +857 -35
- package/dist/index.d.ts +149 -2
- package/dist/index.js +149 -2
- package/dist/instances/script-engine-worker-ohlcv-transfer.d.ts +31 -0
- package/dist/instances/script-engine-worker-ohlcv-transfer.js +164 -0
- package/dist/interfaces/market-event.interface.d.ts +231 -0
- package/dist/interfaces/market-event.interface.js +15 -0
- package/dist/interfaces/opra-realtime.interface.d.ts +70 -134
- package/dist/interfaces/opra-realtime.interface.js +34 -59
- package/dist/interfaces/replay.interface.d.ts +285 -0
- package/dist/interfaces/replay.interface.js +1 -0
- package/dist/kscript-data/controls/live-ohlcv-merge.util.d.ts +1 -0
- package/dist/kscript-data/controls/live-ohlcv-merge.util.js +93 -0
- package/dist/kscript-data/controls/live-trades-merge.util.d.ts +5 -1
- package/dist/kscript-data/controls/live-trades-merge.util.js +2 -2
- package/dist/market-data/billing.interface.d.ts +219 -0
- package/dist/market-data/billing.interface.js +58 -0
- package/dist/market-data/venue-governed.util.d.ts +2 -0
- package/dist/market-data/venue-governed.util.js +10 -0
- package/dist/market-data/venue.d.ts +122 -0
- package/dist/market-data/venue.js +1 -0
- package/dist/market-data/venues/index.d.ts +97 -0
- package/dist/market-data/venues/index.js +33 -0
- package/dist/market-data/venues/opra.contract.copy.json +35 -0
- package/dist/market-data/venues/opra.d.ts +70 -0
- package/dist/market-data/venues/opra.js +74 -0
- package/dist/replay/replayIndicatorRows.d.ts +31 -0
- package/dist/replay/replayIndicatorRows.js +117 -0
- package/dist/replay/replayLadder.d.ts +85 -0
- package/dist/replay/replayLadder.js +388 -0
- package/dist/utility/auth/server-clock.util.d.ts +81 -0
- package/dist/utility/auth/server-clock.util.js +238 -0
- package/dist/utility/chart/builtin-identity.util.d.ts +18 -0
- package/dist/utility/chart/builtin-identity.util.js +51 -0
- package/dist/utility/chart/cache-alignment.util.d.ts +454 -0
- package/dist/utility/chart/cache-alignment.util.js +926 -0
- package/dist/utility/chart/chart-data-fetch-generation.util.d.ts +15 -0
- package/dist/utility/chart/chart-data-fetch-generation.util.js +22 -0
- package/dist/utility/chart/chart-mount-epoch.util.d.ts +5 -0
- package/dist/utility/chart/chart-mount-epoch.util.js +29 -0
- package/dist/utility/chart/chart-time-domain.util.d.ts +12 -0
- package/dist/utility/chart/chart-time-domain.util.js +23 -0
- package/dist/utility/chart/color-customization.leaf.d.ts +10 -0
- package/dist/utility/chart/color-customization.leaf.js +16 -0
- package/dist/utility/chart/date-labelled-interval.leaf.d.ts +15 -0
- package/dist/utility/chart/date-labelled-interval.leaf.js +19 -0
- package/dist/utility/chart/footprint-tick-grid.util.d.ts +106 -0
- package/dist/utility/chart/footprint-tick-grid.util.js +167 -0
- package/dist/utility/chart/gesture-timing.leaf.d.ts +29 -0
- package/dist/utility/chart/gesture-timing.leaf.js +29 -0
- package/dist/utility/chart/governed-contract-coin.util.d.ts +22 -0
- package/dist/utility/chart/governed-contract-coin.util.js +39 -0
- package/dist/utility/chart/host-bar-placement.util.d.ts +107 -0
- package/dist/utility/chart/host-bar-placement.util.js +447 -0
- package/dist/utility/chart/index-host-tier.util.d.ts +31 -0
- package/dist/utility/chart/index-host-tier.util.js +118 -0
- package/dist/utility/chart/index-mode-admission.util.d.ts +34 -0
- package/dist/utility/chart/index-mode-admission.util.js +67 -0
- package/dist/utility/chart/indicator-error-message.util.d.ts +35 -0
- package/dist/utility/chart/indicator-error-message.util.js +44 -0
- package/dist/utility/chart/indicator-run-interval.util.d.ts +130 -0
- package/dist/utility/chart/indicator-run-interval.util.js +268 -0
- package/dist/utility/chart/kscript-apply-fingerprint.util.d.ts +65 -0
- package/dist/utility/chart/kscript-apply-fingerprint.util.js +357 -0
- package/dist/utility/chart/kscript-chart-flush.leaf.d.ts +22 -0
- package/dist/utility/chart/kscript-chart-flush.leaf.js +13 -0
- package/dist/utility/chart/kscript-data-interval-restriction.leaf.d.ts +6 -0
- package/dist/utility/chart/kscript-data-interval-restriction.leaf.js +27 -0
- package/dist/utility/chart/kscript-integration-decision.leaf.d.ts +89 -0
- package/dist/utility/chart/kscript-integration-decision.leaf.js +80 -0
- package/dist/utility/chart/kscript-live-coalesce.util.d.ts +76 -0
- package/dist/utility/chart/kscript-live-coalesce.util.js +156 -0
- package/dist/utility/chart/kscript-live-rest-pace.util.d.ts +34 -0
- package/dist/utility/chart/kscript-live-rest-pace.util.js +134 -0
- package/dist/utility/chart/kscript-live-source-identity.util.d.ts +98 -0
- package/dist/utility/chart/kscript-live-source-identity.util.js +121 -0
- package/dist/utility/chart/kscript-mounted-plot-set.leaf.d.ts +48 -0
- package/dist/utility/chart/kscript-mounted-plot-set.leaf.js +145 -0
- package/dist/utility/chart/kscript-perf-tracker.util.d.ts +243 -0
- package/dist/utility/chart/kscript-perf-tracker.util.js +522 -0
- package/dist/utility/chart/kscript-run-interval-projection.util.d.ts +43 -0
- package/dist/utility/chart/kscript-run-interval-projection.util.js +471 -0
- package/dist/utility/chart/kscript-run-result-equality.util.d.ts +38 -0
- package/dist/utility/chart/kscript-run-result-equality.util.js +89 -0
- package/dist/utility/chart/kscript-settings-revision.leaf.d.ts +2 -0
- package/dist/utility/chart/kscript-settings-revision.leaf.js +12 -0
- package/dist/utility/chart/kscript-source-degrade.leaf.d.ts +63 -0
- package/dist/utility/chart/kscript-source-degrade.leaf.js +68 -0
- package/dist/utility/chart/kscript-source-retention.util.d.ts +134 -0
- package/dist/utility/chart/kscript-source-retention.util.js +218 -0
- package/dist/utility/chart/kscript-standin-identity.leaf.d.ts +57 -0
- package/dist/utility/chart/kscript-standin-identity.leaf.js +61 -0
- package/dist/utility/chart/kscript-titancharts-preparation.util.d.ts +15 -0
- package/dist/utility/chart/kscript-titancharts-preparation.util.js +376 -0
- package/dist/utility/chart/kscript-titancharts-render-keys.constants.d.ts +9 -0
- package/dist/utility/chart/kscript-titancharts-render-keys.constants.js +130 -0
- package/dist/utility/chart/kscript-venue-policy.util.d.ts +217 -0
- package/dist/utility/chart/kscript-venue-policy.util.js +324 -0
- package/dist/utility/chart/live-cadence.util.d.ts +38 -0
- package/dist/utility/chart/live-cadence.util.js +37 -0
- package/dist/utility/chart/live-feed-series-match.leaf.d.ts +13 -0
- package/dist/utility/chart/live-feed-series-match.leaf.js +21 -0
- package/dist/utility/chart/local-engine-self-heal-backoff.util.d.ts +46 -0
- package/dist/utility/chart/local-engine-self-heal-backoff.util.js +46 -0
- package/dist/utility/chart/local-engine-uninit.leaf.d.ts +21 -0
- package/dist/utility/chart/local-engine-uninit.leaf.js +22 -0
- package/dist/utility/chart/local-kscript-source-revalidation.util.d.ts +62 -0
- package/dist/utility/chart/local-kscript-source-revalidation.util.js +123 -0
- package/dist/utility/chart/local-kscript-warmup-depth.util.d.ts +214 -0
- package/dist/utility/chart/local-kscript-warmup-depth.util.js +376 -0
- package/dist/utility/chart/local-technical-script-live-apply-coalescer.util.d.ts +85 -0
- package/dist/utility/chart/local-technical-script-live-apply-coalescer.util.js +197 -0
- package/dist/utility/chart/local-technical-script-range.leaf.d.ts +72 -0
- package/dist/utility/chart/local-technical-script-range.leaf.js +126 -0
- package/dist/utility/chart/mixed-mode.util.d.ts +167 -0
- package/dist/utility/chart/mixed-mode.util.js +139 -0
- package/dist/utility/chart/ohlcv-row-readiness.util.d.ts +36 -0
- package/dist/utility/chart/ohlcv-row-readiness.util.js +90 -0
- package/dist/utility/chart/opra-user-scripts-gate.util.d.ts +19 -0
- package/dist/utility/chart/opra-user-scripts-gate.util.js +32 -0
- package/dist/utility/chart/overlay-execution-guard-key.leaf.d.ts +8 -0
- package/dist/utility/chart/overlay-execution-guard-key.leaf.js +10 -0
- package/dist/utility/chart/price-precision.util.d.ts +40 -0
- package/dist/utility/chart/price-precision.util.js +70 -0
- package/dist/utility/chart/profile-block-size.util.d.ts +64 -0
- package/dist/utility/chart/profile-block-size.util.js +141 -0
- package/dist/utility/chart/protected-kscript-degenerate-rows.leaf.d.ts +11 -0
- package/dist/utility/chart/protected-kscript-degenerate-rows.leaf.js +29 -0
- package/dist/utility/chart/protected-kscript-empty-output.util.d.ts +28 -0
- package/dist/utility/chart/protected-kscript-empty-output.util.js +84 -0
- package/dist/utility/chart/run-interval-unservable.leaf.d.ts +9 -0
- package/dist/utility/chart/run-interval-unservable.leaf.js +20 -0
- package/dist/utility/chart/run-interval-warmup.leaf.d.ts +19 -0
- package/dist/utility/chart/run-interval-warmup.leaf.js +35 -0
- package/dist/utility/chart/titan-constants.pin.d.ts +9 -5
- package/dist/utility/chart/titan-constants.pin.js +18 -5
- package/dist/utility/chart/warmup-backfill-retry.leaf.d.ts +9 -0
- package/dist/utility/chart/warmup-backfill-retry.leaf.js +9 -0
- package/dist/utility/chart/window-geometry.leaf.d.ts +119 -0
- package/dist/utility/chart/window-geometry.leaf.js +391 -0
- package/dist/utility/chart/window-owner.leaf.d.ts +19 -0
- package/dist/utility/chart/window-owner.leaf.js +24 -0
- package/dist/utility/chart/wrun-bar-session-facts.util.d.ts +11 -2
- package/dist/utility/chart/wrun-bar-session-facts.util.js +10 -3
- package/dist/utility/chart/wrun-run-result.util.d.ts +5 -1
- package/dist/utility/chart/wrun-run-result.util.js +20 -14
- package/dist/utility/common/data-processing.util.d.ts +138 -0
- package/dist/utility/common/data-processing.util.js +346 -0
- package/dist/utility/common/visible-timeout.util.d.ts +13 -4
- package/dist/utility/common/visible-timeout.util.js +23 -8
- package/dist/utility/exchange-format.leaf.d.ts +1 -0
- package/dist/utility/exchange-format.leaf.js +47 -0
- package/dist/utility/html-escape.leaf.d.ts +11 -0
- package/dist/utility/html-escape.leaf.js +20 -0
- package/dist/utility/market-events/earnings-scope.util.d.ts +60 -0
- package/dist/utility/market-events/earnings-scope.util.js +92 -0
- package/dist/utility/market-events/market-events.util.d.ts +147 -0
- package/dist/utility/market-events/market-events.util.js +392 -0
- package/dist/utility/market-events/zoned-clock.util.d.ts +1 -0
- package/dist/utility/market-events/zoned-clock.util.js +11 -0
- package/dist/utility/options/option-venue-disclosure.util.d.ts +43 -0
- package/dist/utility/options/option-venue-disclosure.util.js +56 -0
- package/dist/utility/scriptEditor/package-semver.util.d.ts +51 -0
- package/dist/utility/scriptEditor/package-semver.util.js +120 -0
- package/dist/utility/scriptEditor/temp-script-id.util.d.ts +18 -0
- package/dist/utility/scriptEditor/temp-script-id.util.js +25 -0
- package/dist/utility/symbol-selection/markets-request-from-symbols.leaf.d.ts +20 -0
- package/dist/utility/symbol-selection/markets-request-from-symbols.leaf.js +81 -0
- package/dist/utility/v2/governed-tier.leaf.d.ts +103 -0
- package/dist/utility/v2/governed-tier.leaf.js +113 -0
- package/dist/utility/watchlist/import/import-request.leaf.d.ts +10 -0
- package/dist/utility/watchlist/import/import-request.leaf.js +10 -0
- package/dist/utility/wrun/sources/lanes/option_daily.d.ts +43 -15
- package/dist/utility/wrun/sources/lanes/option_daily.js +78 -20
- package/dist/utility/wrun/sources/lanes/option_stats_10m.d.ts +14 -10
- package/dist/utility/wrun/sources/lanes/option_stats_10m.js +5 -4
- package/dist/utility/wrun/sources/lanes/series.js +2 -2
- package/dist/utility/wrun/sources/opra-option-lanes.util.d.ts +22 -3
- package/dist/utility/wrun/sources/opra-option-lanes.util.js +38 -7
- package/dist/utility/wrun/sources/registry.js +31 -1
- package/dist/utility/wrun/sources/row-lane-registry.js +5 -5
- package/dist/utility/wrun/sources/row-lanes/option_contract_state.d.ts +49 -0
- package/dist/utility/wrun/sources/row-lanes/option_contract_state.js +75 -20
- package/dist/utility/wrun/sources/row-lanes/option_strikes.d.ts +49 -0
- package/dist/utility/wrun/sources/row-lanes/option_strikes.js +57 -47
- package/dist/utility/wrun/sources/row-lanes/option_surface.d.ts +36 -4
- package/dist/utility/wrun/sources/row-lanes/option_surface.js +6 -12
- package/dist/utility/wrun/sources/wrun-poll-lane.types.d.ts +37 -3
- package/dist/utility/wrun/sources/wrun-poll-lanes.util.d.ts +128 -2
- package/dist/utility/wrun/sources/wrun-poll-lanes.util.js +233 -51
- package/dist/utility/wrun/sources/wrun-row-lane.types.d.ts +0 -8
- package/dist/utility/wrun/sources/wrun-row-lanes.util.d.ts +26 -24
- package/dist/utility/wrun/sources/wrun-row-lanes.util.js +85 -104
- package/dist/utility/wrun/wrun-alert-outputs.registry.d.ts +166 -0
- package/dist/utility/wrun/wrun-alert-outputs.registry.js +219 -0
- package/dist/utility/wrun/wrun-bar-count.util.d.ts +83 -0
- package/dist/utility/wrun/wrun-bar-count.util.js +259 -0
- package/dist/utility/wrun/wrun-chart-context-names.util.d.ts +84 -0
- package/dist/utility/wrun/wrun-chart-context-names.util.js +186 -0
- package/dist/utility/wrun/wrun-chart-market-facts.util.d.ts +253 -0
- package/dist/utility/wrun/wrun-chart-market-facts.util.js +731 -0
- package/dist/utility/wrun/wrun-cloud-opra-stamp.util.d.ts +28 -0
- package/dist/utility/wrun/wrun-cloud-opra-stamp.util.js +45 -0
- package/dist/utility/wrun/wrun-coin-lane-live.util.d.ts +18 -0
- package/dist/utility/wrun/wrun-coin-lane-live.util.js +47 -0
- package/dist/utility/wrun/wrun-deadline.util.js +2 -1
- package/dist/utility/wrun/wrun-debug-output.util.d.ts +39 -0
- package/dist/utility/wrun/wrun-debug-output.util.js +63 -0
- package/dist/utility/wrun/wrun-declared-warmup.util.d.ts +113 -0
- package/dist/utility/wrun/wrun-declared-warmup.util.js +181 -0
- package/dist/utility/wrun/wrun-draft-legend-note.util.d.ts +43 -0
- package/dist/utility/wrun/wrun-draft-legend-note.util.js +158 -0
- package/dist/utility/wrun/wrun-draft-overlay.util.d.ts +181 -0
- package/dist/utility/wrun/wrun-draft-overlay.util.js +357 -0
- package/dist/utility/wrun/wrun-draw-skipped.leaf.d.ts +16 -0
- package/dist/utility/wrun/wrun-draw-skipped.leaf.js +16 -0
- package/dist/utility/wrun/wrun-earnings-facts.util.d.ts +42 -0
- package/dist/utility/wrun/wrun-earnings-facts.util.js +131 -0
- package/dist/utility/wrun/wrun-first-run-depth.util.d.ts +32 -0
- package/dist/utility/wrun/wrun-first-run-depth.util.js +118 -0
- package/dist/utility/wrun/wrun-gate-plane-readers.util.d.ts +24 -0
- package/dist/utility/wrun/wrun-gate-plane-readers.util.js +31 -0
- package/dist/utility/wrun/wrun-held-lanes.util.d.ts +32 -0
- package/dist/utility/wrun/wrun-held-lanes.util.js +94 -0
- package/dist/utility/wrun/wrun-host-visible-clock.util.d.ts +2 -0
- package/dist/utility/wrun/wrun-host-visible-clock.util.js +17 -0
- package/dist/utility/wrun/wrun-host.service.d.ts +266 -0
- package/dist/utility/wrun/wrun-host.service.js +655 -0
- package/dist/utility/wrun/wrun-inert-legend.util.d.ts +33 -0
- package/dist/utility/wrun/wrun-inert-legend.util.js +125 -0
- package/dist/utility/wrun/wrun-input-requirements.leaf.d.ts +155 -0
- package/dist/utility/wrun/wrun-input-requirements.leaf.js +450 -0
- package/dist/utility/wrun/wrun-integration-route.util.d.ts +51 -0
- package/dist/utility/wrun/wrun-integration-route.util.js +59 -0
- package/dist/utility/wrun/wrun-latest-history.leaf.d.ts +8 -0
- package/dist/utility/wrun/wrun-latest-history.leaf.js +8 -0
- package/dist/utility/wrun/wrun-legend-hover.lazy.d.ts +12 -0
- package/dist/utility/wrun/wrun-legend-hover.lazy.js +96 -0
- package/dist/utility/wrun/wrun-lifecycle-runtime.util.d.ts +21 -0
- package/dist/utility/wrun/wrun-lifecycle-runtime.util.js +21 -0
- package/dist/utility/wrun/wrun-live-hidden-hold.util.d.ts +23 -0
- package/dist/utility/wrun/wrun-live-hidden-hold.util.js +13 -0
- package/dist/utility/wrun/wrun-live-intake.util.d.ts +374 -0
- package/dist/utility/wrun/wrun-live-intake.util.js +2027 -0
- package/dist/utility/wrun/wrun-live-patch.util.d.ts +116 -0
- package/dist/utility/wrun/wrun-live-patch.util.js +523 -0
- package/dist/utility/wrun/wrun-live-tick.util.d.ts +619 -0
- package/dist/utility/wrun/wrun-live-tick.util.js +4974 -0
- package/dist/utility/wrun/wrun-loading-owner.util.d.ts +58 -0
- package/dist/utility/wrun/wrun-loading-owner.util.js +89 -0
- package/dist/utility/wrun/wrun-official-scope.leaf.d.ts +29 -0
- package/dist/utility/wrun/wrun-official-scope.leaf.js +36 -0
- package/dist/utility/wrun/wrun-oi-lane.util.d.ts +27 -0
- package/dist/utility/wrun/wrun-oi-lane.util.js +42 -0
- package/dist/utility/wrun/wrun-opra-stats.leaf.d.ts +29 -10
- package/dist/utility/wrun/wrun-opra-stats.leaf.js +29 -10
- package/dist/utility/wrun/wrun-options-stop.util.d.ts +52 -0
- package/dist/utility/wrun/wrun-options-stop.util.js +123 -0
- package/dist/utility/wrun/wrun-overlay-drivers.util.d.ts +719 -0
- package/dist/utility/wrun/wrun-overlay-drivers.util.js +1180 -0
- package/dist/utility/wrun/wrun-overlay-lifecycle.lazy.d.ts +50 -0
- package/dist/utility/wrun/wrun-overlay-lifecycle.lazy.js +131 -0
- package/dist/utility/wrun/wrun-overlay-lifecycle.util.d.ts +118 -0
- package/dist/utility/wrun/wrun-overlay-lifecycle.util.js +466 -0
- package/dist/utility/wrun/wrun-overlay-metadata.util.d.ts +45 -0
- package/dist/utility/wrun/wrun-overlay-metadata.util.js +112 -0
- package/dist/utility/wrun/wrun-overlay-recovery.util.d.ts +114 -0
- package/dist/utility/wrun/wrun-overlay-recovery.util.js +971 -0
- package/dist/utility/wrun/wrun-overlay-run.util.d.ts +858 -0
- package/dist/utility/wrun/wrun-overlay-run.util.js +11013 -0
- package/dist/utility/wrun/wrun-panel-mount.lazy.d.ts +10 -0
- package/dist/utility/wrun/wrun-panel-mount.lazy.js +68 -0
- package/dist/utility/wrun/wrun-panel-mount.util.d.ts +392 -0
- package/dist/utility/wrun/wrun-panel-mount.util.js +2346 -0
- package/dist/utility/wrun/wrun-param-map.util.d.ts +19 -4
- package/dist/utility/wrun/wrun-param-map.util.js +40 -47
- package/dist/utility/wrun/wrun-param-values.util.d.ts +9 -3
- package/dist/utility/wrun/wrun-param-values.util.js +5 -5
- package/dist/utility/wrun/wrun-pause-dim.util.d.ts +52 -0
- package/dist/utility/wrun/wrun-pause-dim.util.js +153 -0
- package/dist/utility/wrun/wrun-plot-gate.types.d.ts +23 -0
- package/dist/utility/wrun/wrun-plot-gate.types.js +7 -0
- package/dist/utility/wrun/wrun-prefix-cohort.util.d.ts +93 -0
- package/dist/utility/wrun/wrun-prefix-cohort.util.js +484 -0
- package/dist/utility/wrun/wrun-prefix-lanes.util.d.ts +114 -0
- package/dist/utility/wrun/wrun-prefix-lanes.util.js +486 -0
- package/dist/utility/wrun/wrun-prefix-proof.util.d.ts +317 -0
- package/dist/utility/wrun/wrun-prefix-proof.util.js +630 -0
- package/dist/utility/wrun/wrun-refusal-surface.util.d.ts +73 -0
- package/dist/utility/wrun/wrun-refusal-surface.util.js +380 -0
- package/dist/utility/wrun/wrun-refusal-text.util.d.ts +15 -0
- package/dist/utility/wrun/wrun-refusal-text.util.js +40 -0
- package/dist/utility/wrun/wrun-replay-lane.util.d.ts +139 -0
- package/dist/utility/wrun/wrun-replay-lane.util.js +520 -0
- package/dist/utility/wrun/wrun-replay-rows.util.d.ts +21 -0
- package/dist/utility/wrun/wrun-replay-rows.util.js +172 -0
- package/dist/utility/wrun/wrun-row-source-factory.d.ts +53 -0
- package/dist/utility/wrun/wrun-row-source-factory.js +435 -0
- package/dist/utility/wrun/wrun-run-cells.util.d.ts +36 -0
- package/dist/utility/wrun/wrun-run-cells.util.js +46 -0
- package/dist/utility/wrun/wrun-run-interval-projection.types.d.ts +14 -0
- package/dist/utility/wrun/wrun-run-interval-projection.types.js +1 -0
- package/dist/utility/wrun/wrun-run-interval-session.util.d.ts +133 -0
- package/dist/utility/wrun/wrun-run-interval-session.util.js +121 -0
- package/dist/utility/wrun/wrun-run-interval.util.d.ts +98 -0
- package/dist/utility/wrun/wrun-run-interval.util.js +207 -0
- package/dist/utility/wrun/wrun-run-retained.util.d.ts +122 -0
- package/dist/utility/wrun/wrun-run-retained.util.js +255 -0
- package/dist/utility/wrun/wrun-sandbox-row-source.d.ts +184 -0
- package/dist/utility/wrun/wrun-sandbox-row-source.js +444 -0
- package/dist/utility/wrun/wrun-script-inputs.util.js +4 -4
- package/dist/utility/wrun/wrun-series-stream.util.d.ts +86 -0
- package/dist/utility/wrun/wrun-series-stream.util.js +537 -0
- package/dist/utility/wrun/wrun-sheet-remembered.util.d.ts +21 -0
- package/dist/utility/wrun/wrun-sheet-remembered.util.js +36 -0
- package/dist/utility/wrun/wrun-signal-sound-reasons.leaf.d.ts +7 -0
- package/dist/utility/wrun/wrun-signal-sound-reasons.leaf.js +12 -0
- package/dist/utility/wrun/wrun-socket-row-source.js +4 -2
- package/dist/utility/wrun/wrun-source-rows.util.d.ts +175 -3
- package/dist/utility/wrun/wrun-source-rows.util.js +294 -8
- package/dist/utility/wrun/wrun-stats-strip.util.d.ts +46 -0
- package/dist/utility/wrun/wrun-stats-strip.util.js +87 -0
- package/dist/utility/wrun/wrun-table-chrome.util.d.ts +163 -0
- package/dist/utility/wrun/wrun-table-chrome.util.js +557 -0
- package/dist/utility/wrun/wrun-text-params.util.d.ts +11 -6
- package/dist/utility/wrun/wrun-text-params.util.js +19 -30
- package/dist/utility/wrun/wrun-transient-rerun.util.d.ts +64 -0
- package/dist/utility/wrun/wrun-transient-rerun.util.js +317 -0
- package/dist/utility/wrun/wrun-twin-lookback.util.d.ts +10 -0
- package/dist/utility/wrun/wrun-twin-lookback.util.js +43 -0
- package/dist/utility/wrun/wrun-warmup-head-store.util.d.ts +41 -0
- package/dist/utility/wrun/wrun-warmup-head-store.util.js +120 -0
- package/dist/utility/wrun-alert-params.leaf.d.ts +24 -0
- package/dist/utility/wrun-alert-params.leaf.js +24 -0
- package/dist/utils/replay/replay-buffer-math.d.ts +148 -0
- package/dist/utils/replay/replay-buffer-math.js +684 -0
- package/dist/workers/wrun/wrun-abi-host.d.ts +190 -0
- package/dist/workers/wrun/wrun-abi-host.js +1201 -0
- package/dist/workers/wrun/wrun-engine-handler.d.ts +37 -0
- package/dist/workers/wrun/wrun-engine-handler.js +211 -0
- package/package.json +3 -3
|
@@ -0,0 +1,454 @@
|
|
|
1
|
+
export declare const BARS_PER_BUCKET = 250;
|
|
2
|
+
export declare const BARS_PER_PIECE = 50;
|
|
3
|
+
interface FetchParams {
|
|
4
|
+
from: number;
|
|
5
|
+
period: number;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Aligns a timestamp to bucket boundaries for cache optimization
|
|
9
|
+
*/
|
|
10
|
+
export declare function alignTimestampToBucket(timestampMs: number, intervalMs: number, direction?: 'floor' | 'ceil'): number;
|
|
11
|
+
/**
|
|
12
|
+
* Complete-bucket stamps for a fetched window (data-loading plan A51): the
|
|
13
|
+
* canonical 250-bar bucket starts (unix SECONDS, the same grid
|
|
14
|
+
* getOptimizedFetchParams cuts on) that lie FULLY inside
|
|
15
|
+
* [fromSec, fromSec + periodSec) and whose bucket end is at or before
|
|
16
|
+
* `nowMs` (the server's now). The floating latest window (fromSec === 0) is never stamped: its
|
|
17
|
+
* absolute span is decided at the worker and it always ends on the forming
|
|
18
|
+
* bar. A partially covered bucket is never stamped; the caller writes the
|
|
19
|
+
* result only from a complete, non-aborted terminal.
|
|
20
|
+
*/
|
|
21
|
+
export declare function completeBucketStartsForWindow(fromSec: number, periodSec: number, intervalMs: number, nowMs?: number): number[];
|
|
22
|
+
/**
|
|
23
|
+
* The wire frontier span one complete terminal earns for its asked window
|
|
24
|
+
* (fix 2 of the indicator re-fetch investigation, 2026-09-28): the window
|
|
25
|
+
* from its start through the open of the first bar it does NOT confirm, on
|
|
26
|
+
* the interval grid. The end is the earlier of the window's end and `nowMs`,
|
|
27
|
+
* floored to the grid: a window that reaches into the bar forming at `nowMs`
|
|
28
|
+
* confirms only the bars closed before it, so the forming bar never advances
|
|
29
|
+
* the frontier, and a window that ends inside a closed bar confirms only the
|
|
30
|
+
* bars before that one. Null for the floating latest window (`fromSec` 0:
|
|
31
|
+
* its absolute span is decided at the worker) and for a window that holds no
|
|
32
|
+
* whole bar. Seconds in, milliseconds out (the entry's own units). Calendar
|
|
33
|
+
* bars (1M 3M 6M 1Y) floor and close on their calendar boundaries: on the
|
|
34
|
+
* average-month grid October 6 floors to October 1 22:30Z, after the October
|
|
35
|
+
* open, and the forming month read as confirmed.
|
|
36
|
+
*/
|
|
37
|
+
export declare function wireFrontierSpanForWindow(fromSec: number, periodSec: number, intervalMs: number, nowMs: number): {
|
|
38
|
+
fromMs: number;
|
|
39
|
+
throughMs: number;
|
|
40
|
+
} | null;
|
|
41
|
+
/**
|
|
42
|
+
* The part of a planned window the wire was actually asked for (plan A51):
|
|
43
|
+
* a control's request payload may narrow the planned [fromSec, fromSec +
|
|
44
|
+
* periodSec) window (the book controls trim to the OB replay cap through
|
|
45
|
+
* applyObReplayCap, so nothing after the last 3-minute boundary is asked), and
|
|
46
|
+
* a complete-bucket stamp must never cover a tail that was never asked.
|
|
47
|
+
* A payload without a numeric absolute `from`/`period` (index-mode arrays,
|
|
48
|
+
* controls that carry no window) is taken to have asked the planned window;
|
|
49
|
+
* a floating payload (`from` 0) has no absolute span and returns null; a
|
|
50
|
+
* payload disjoint from the plan returns null. Seconds throughout.
|
|
51
|
+
*/
|
|
52
|
+
export declare function askedWindowWithinPlanned(fromSec: number, periodSec: number, payload: unknown): {
|
|
53
|
+
fromSec: number;
|
|
54
|
+
periodSec: number;
|
|
55
|
+
} | null;
|
|
56
|
+
/**
|
|
57
|
+
* Calculates aligned time range for data fetching with cache optimization
|
|
58
|
+
*
|
|
59
|
+
* @param from - Start timestamp in seconds (0 means latest window)
|
|
60
|
+
* @param period - Time period in seconds
|
|
61
|
+
* @param interval - Chart interval ('1m', '5m', '1h', '1d', etc.)
|
|
62
|
+
* @returns Array of aligned timestamps ensuring valid integer values
|
|
63
|
+
*
|
|
64
|
+
* Remark:
|
|
65
|
+
* - Bucket: Large immutable data, always fetch for buckets in lazy load
|
|
66
|
+
* - Piece: Small immutable data, only fetch in first load. This is because data cache would have a short TTL if we fetch until now. Piece serves as a small cache before a bucket is formed.
|
|
67
|
+
* - Remnant: Small mutable data with short TTL, only fetch in first load.
|
|
68
|
+
*/
|
|
69
|
+
export declare function getOptimizedFetchParams(from: number, period: number, interval: string): FetchParams[];
|
|
70
|
+
/**
|
|
71
|
+
* The main lane's default window (unix seconds) before a preserved span or an
|
|
72
|
+
* armed view widens it: `barsPeriodSec` (bars x interval, the period the boot
|
|
73
|
+
* lanes send as their floating `from: 0` window) back from `nowSec`.
|
|
74
|
+
* - A live market never starts before the epoch: 250 bars of 3M or longer
|
|
75
|
+
* reach before 1970, the gateway reads a start at or below zero as the
|
|
76
|
+
* floating window anyway, and a negative start splits on the bucket grid
|
|
77
|
+
* into overlapping floating asks. Clamped, the window IS the boot lanes'
|
|
78
|
+
* floating window (`from: 0`, the same period), so the two ask alike.
|
|
79
|
+
* - An economic series keeps a signed start (history before 1970) and asks
|
|
80
|
+
* its short window at a calendar interval.
|
|
81
|
+
*/
|
|
82
|
+
export declare function defaultMainWindowSec(input: {
|
|
83
|
+
nowSec: number;
|
|
84
|
+
barsPeriodSec: number;
|
|
85
|
+
interval: string;
|
|
86
|
+
economic: boolean;
|
|
87
|
+
}): {
|
|
88
|
+
fromSec: number;
|
|
89
|
+
periodSec: number;
|
|
90
|
+
};
|
|
91
|
+
type MainPlanAskKind = 'bucket' | 'piece' | 'remnant' | 'whole' | 'tail-boot' | 'count';
|
|
92
|
+
export type MainPlanWhy = 'uncovered-closed-bucket' | 'not-wire-validated' | 'forming-tail' | 'authoritative-reload' | 'tail-boot' | 'dry-identity' | 'unplanned';
|
|
93
|
+
interface MainPlanCommitWindow {
|
|
94
|
+
fromSec: number;
|
|
95
|
+
toSec: number;
|
|
96
|
+
}
|
|
97
|
+
export interface MainPlanAsk {
|
|
98
|
+
kind: MainPlanAskKind;
|
|
99
|
+
/** Unix seconds; the tail-boot ask leaves the shape to the dispatcher. */
|
|
100
|
+
from: number;
|
|
101
|
+
period: number;
|
|
102
|
+
/** Count lane only: the bar limit anchored at now. */
|
|
103
|
+
limit?: number;
|
|
104
|
+
why: MainPlanWhy;
|
|
105
|
+
/** Set on every ask narrower than the demand window: the commit merges inside it and never replaces outside. */
|
|
106
|
+
commitWindow?: MainPlanCommitWindow;
|
|
107
|
+
/** The dry lane's frontier ask: leaves as ONE request with these exact bounds, never aligned to the bucket grid. */
|
|
108
|
+
verbatim?: boolean;
|
|
109
|
+
/**
|
|
110
|
+
* Partial-bucket asks only: the end (ms bar open) of the receipt that
|
|
111
|
+
* holds the bucket's first bar and ends inside it, the instant through
|
|
112
|
+
* which the re-delivered overlap is wire-validated. The dispatcher hands it
|
|
113
|
+
* to the poison detector as the compare bound (`receiptFrontierTs`), so an
|
|
114
|
+
* island's overlap is compared even when the chain from the entry's first
|
|
115
|
+
* row ends long before the ask (per-bucket receipts: a lying island keeps
|
|
116
|
+
* its canary). Absent on asks planned without such a receipt.
|
|
117
|
+
*/
|
|
118
|
+
coverEndMs?: number;
|
|
119
|
+
}
|
|
120
|
+
/** A bucket the planner judged on a receipt holding its first bar (ring diagnostic). */
|
|
121
|
+
export interface MainPlanBucketCover {
|
|
122
|
+
/** The bucket start (unix seconds). */
|
|
123
|
+
bucket: number;
|
|
124
|
+
/** The receipt's end (ms bar open). */
|
|
125
|
+
coverEndMs: number;
|
|
126
|
+
/** True = the receipt reached the bucket's last bar and the bucket was skipped; false = re-asked from the receipt's last piece. */
|
|
127
|
+
skipped: boolean;
|
|
128
|
+
}
|
|
129
|
+
type MainPlanPaintOutcome = 'hit-fresh' | 'hit-stale' | 'miss';
|
|
130
|
+
interface MainPlanPaint {
|
|
131
|
+
outcome: MainPlanPaintOutcome;
|
|
132
|
+
/** First and last bar of the read entry (ms). */
|
|
133
|
+
firstTs?: number;
|
|
134
|
+
lastTs?: number;
|
|
135
|
+
/**
|
|
136
|
+
* The derived contiguous receipt frontier (ms); absent = no receipt covers
|
|
137
|
+
* the first row. The dry lane's tail, and the period lane's one-chain
|
|
138
|
+
* fallback (`[firstTs, wireFrontierTs]`) when `wireReceipts` is absent.
|
|
139
|
+
*/
|
|
140
|
+
wireFrontierTs?: number;
|
|
141
|
+
/**
|
|
142
|
+
* The entry's coalesced wire receipts over the rows the read returned (ms
|
|
143
|
+
* bar opens; the read clamps them to the mounted rows and coalesces them on
|
|
144
|
+
* the interval grid: `normalizeWireReceipts` and `clampWireReceiptsToBars`
|
|
145
|
+
* in ohlcv-cache.service). The period lane judges every closed bucket on
|
|
146
|
+
* the ONE receipt holding its first bar (the 2026-10-02 08:59Z dump), so an
|
|
147
|
+
* island past a hole counts for the buckets it covers whole.
|
|
148
|
+
*/
|
|
149
|
+
wireReceipts?: ReadonlyArray<readonly [fromTs: number, toTs: number]>;
|
|
150
|
+
/** The read belt (barsConsistentWithInterval, foreign-grid classifier) passed; false refuses every skip. */
|
|
151
|
+
beltPassed?: boolean;
|
|
152
|
+
rows?: number;
|
|
153
|
+
/**
|
|
154
|
+
* The instant (ms) through which the wire answered for this identity PAST
|
|
155
|
+
* the entry's tail bar (fix-forward U1, the review of S2): the end of a
|
|
156
|
+
* validated window that holds the tail, `mainTailValidatedThroughMs`. The
|
|
157
|
+
* windows are this chart's evidence united with the entry's own tail
|
|
158
|
+
* verdict (fix-forward X: provenance, so a chart re-initialized on the
|
|
159
|
+
* identity reads the answer the entry carries).
|
|
160
|
+
* Absent = no such answer, and the dry lane's frontier rule never applies.
|
|
161
|
+
* Never the cache write time: comparison and historical reads write the
|
|
162
|
+
* same entry and prove nothing about the sessions past its tail.
|
|
163
|
+
*/
|
|
164
|
+
tailValidatedThroughMs?: number;
|
|
165
|
+
/** The entry's rows are on screen (a paint), not held in the staged slot. */
|
|
166
|
+
onScreen?: boolean;
|
|
167
|
+
}
|
|
168
|
+
export interface MainPlanInput {
|
|
169
|
+
/** The captured kill-switch value (rides the chart context token). */
|
|
170
|
+
enabled: boolean;
|
|
171
|
+
/** The RESOLVED demand window in unix seconds, never the default window. */
|
|
172
|
+
window: {
|
|
173
|
+
fromSec: number;
|
|
174
|
+
periodSec: number;
|
|
175
|
+
};
|
|
176
|
+
interval: string;
|
|
177
|
+
nowMs: number;
|
|
178
|
+
paint: MainPlanPaint | null;
|
|
179
|
+
/** The mounted series range (diagnostic only: the main rule subtracts receipts, not mounted rows). */
|
|
180
|
+
mountedRange?: {
|
|
181
|
+
fromSec: number;
|
|
182
|
+
periodSec: number;
|
|
183
|
+
} | null;
|
|
184
|
+
/** Live main known-empty spans for this identity and interval (ms). */
|
|
185
|
+
knownEmptySpans?: ReadonlyArray<{
|
|
186
|
+
fromMs: number;
|
|
187
|
+
toMs: number;
|
|
188
|
+
}>;
|
|
189
|
+
/** Windows a same-identity main request already has in flight (unix seconds). */
|
|
190
|
+
identityPending?: ReadonlyArray<{
|
|
191
|
+
from: number;
|
|
192
|
+
period: number;
|
|
193
|
+
}>;
|
|
194
|
+
/** Venue evidence that the identity has nothing newer than the window start. */
|
|
195
|
+
dryIdentity?: {
|
|
196
|
+
/** A wire-authoritative served-empty head window on this identity is still live. */
|
|
197
|
+
servedEmptyHeadLive: boolean;
|
|
198
|
+
/** Last known trade across mounted intervals and the live feed (ms), when known. */
|
|
199
|
+
lastKnownTradeMs?: number | null;
|
|
200
|
+
sessionBound: boolean;
|
|
201
|
+
/**
|
|
202
|
+
* The walk-back (tail-boot ask) for this per-interval identity served
|
|
203
|
+
* empty inside DRY_IDENTITY_PROBE_MS (main-tail-boot.util): the wire has
|
|
204
|
+
* answered; PLAN sends nothing and the poll chain's probe owns liveness.
|
|
205
|
+
* The dry lane's frontier ask records the same probe when it serves
|
|
206
|
+
* empty (fix-forward S2). A closed verdict of the entry that still
|
|
207
|
+
* stands (`isMainClosedVerdictLive`, fix-forward X) is the same answer
|
|
208
|
+
* read from provenance.
|
|
209
|
+
*/
|
|
210
|
+
probed?: boolean;
|
|
211
|
+
};
|
|
212
|
+
/** Revision-prone series (FRED metadata present): never skip a closed bucket. */
|
|
213
|
+
revisionProne?: boolean;
|
|
214
|
+
/**
|
|
215
|
+
* The captured `data-load-receipt-settle` verdict (rides the chart context
|
|
216
|
+
* token): the dry lane parks on the painted tail only when a receipt covers
|
|
217
|
+
* that tail bar (`dryFrontierTailMs`). Absent or false plans as before.
|
|
218
|
+
*/
|
|
219
|
+
receiptSettle?: boolean;
|
|
220
|
+
/**
|
|
221
|
+
* With `receiptSettle` on, the rows the read mounts or stages (ms bar
|
|
222
|
+
* opens first): the period and dry-frontier lanes add one heal ask per
|
|
223
|
+
* canonical bucket holding a row no receipt covers that the demand plan
|
|
224
|
+
* never reaches (`unprovenMountHealAsks`). Absent plans the demand window
|
|
225
|
+
* alone.
|
|
226
|
+
*/
|
|
227
|
+
mountRows?: ReadonlyArray<ReadonlyArray<number>>;
|
|
228
|
+
/**
|
|
229
|
+
* The caller's whole ask leaves the wire as ONE request whatever its shape:
|
|
230
|
+
* the boot lane's floating `from: 0` window, `skipCacheAlignment` (lite
|
|
231
|
+
* panes, replay buffers) and historical mode. A miss keeps that request;
|
|
232
|
+
* the canonical bucket family is for the whole ask the transport would
|
|
233
|
+
* otherwise split into bucket, piece and remnant. False once the entry
|
|
234
|
+
* holds receipts (fix-forward AA): the wire's earlier word subtracts and
|
|
235
|
+
* the tail leaves as residuals; the whole window of a receipted governed
|
|
236
|
+
* pane was re-bought on every layout toggle (`hit-unsplit`).
|
|
237
|
+
*/
|
|
238
|
+
wholeUnsplit?: boolean;
|
|
239
|
+
/** Count lane (tradfi, forex, commodity, dex): one count ask anchored at now. */
|
|
240
|
+
indexMode?: boolean;
|
|
241
|
+
countLane?: {
|
|
242
|
+
cachedLastTs?: number;
|
|
243
|
+
/** Today's limit (mounted rows, else numberOfCandles). */
|
|
244
|
+
todayLimit: number;
|
|
245
|
+
numberOfCandles: number;
|
|
246
|
+
demandBars: number;
|
|
247
|
+
};
|
|
248
|
+
}
|
|
249
|
+
type MainPlanLane = 'period' | 'count' | 'tail-boot' | 'dry-frontier' | 'whole';
|
|
250
|
+
export interface MainPlanResult {
|
|
251
|
+
lane: MainPlanLane;
|
|
252
|
+
asks: MainPlanAsk[];
|
|
253
|
+
/** Canonical bucket starts (unix seconds) skipped as wire-validated closed buckets. */
|
|
254
|
+
skippedBuckets: number[];
|
|
255
|
+
knownEmptyBuckets: number[];
|
|
256
|
+
pendingBuckets: number[];
|
|
257
|
+
/** The receipt each skipped or partial bucket was judged on (period lane only; empty elsewhere). */
|
|
258
|
+
covers: MainPlanBucketCover[];
|
|
259
|
+
/** Bucket starts (unix seconds) the heal asks over unreceipted mounted rows reach (`unprovenMountHealAsks`); absent when none leaves. */
|
|
260
|
+
unprovenMountBuckets?: number[];
|
|
261
|
+
reason: string;
|
|
262
|
+
}
|
|
263
|
+
/**
|
|
264
|
+
* The instant (ms) through which validated windows answer for a series past
|
|
265
|
+
* its tail bar (fix-forward U1): the end of the span that holds the tail bar
|
|
266
|
+
* or starts at the very next bar (a served window past the last row touches
|
|
267
|
+
* it), else null. Pure; the caller gathers the spans (the wire terminals'
|
|
268
|
+
* windows, the coverage PLAN proved, the answered window a cancel keeps).
|
|
269
|
+
*/
|
|
270
|
+
export declare function mainTailValidatedThroughMs(spans: ReadonlyArray<{
|
|
271
|
+
fromMs: number;
|
|
272
|
+
toMs: number;
|
|
273
|
+
}>, tailMs: number, intervalMs: number): number | null;
|
|
274
|
+
/**
|
|
275
|
+
* How far behind its clock a wire answer may end and still count as reaching
|
|
276
|
+
* it (fix-forward X): a served window ends at the clock of its dispatch, and
|
|
277
|
+
* the terminal that judges it lands one round trip later.
|
|
278
|
+
*/
|
|
279
|
+
export declare const MAIN_CLOSED_VERDICT_CLOCK_SLACK_MS = 60000;
|
|
280
|
+
export interface MainTailVerdict {
|
|
281
|
+
/** The bar the verdict was judged on (ms). */
|
|
282
|
+
tailTs: number;
|
|
283
|
+
/** The instant through which validated windows answer past that bar. */
|
|
284
|
+
throughMs: number;
|
|
285
|
+
/**
|
|
286
|
+
* The answer past the tail holds at least one whole bar and no row: the
|
|
287
|
+
* tail is the last trade as far as the wire answered. A forming tail bar
|
|
288
|
+
* of a trading venue is never dry (the answer ends inside the bar).
|
|
289
|
+
*/
|
|
290
|
+
dry: boolean;
|
|
291
|
+
/**
|
|
292
|
+
* Dry, and the answer reaches the clock the wire serves through on a
|
|
293
|
+
* window the wire served EMPTY: nothing traded from the tail to now. A
|
|
294
|
+
* reply that mounted rows up to its clock (the walk-back's newest rows, a
|
|
295
|
+
* tail piece) is such a window past its last bar (fix-forward AA: the
|
|
296
|
+
* terminal records the span from the bar after the mounted tail to the
|
|
297
|
+
* window's end as served empty), so it is the closed verdict too; before
|
|
298
|
+
* AA it only validated the tail and the next visit asked its demand window
|
|
299
|
+
* once (fix-forward S2's shape).
|
|
300
|
+
*/
|
|
301
|
+
closed: boolean;
|
|
302
|
+
}
|
|
303
|
+
/**
|
|
304
|
+
* The tail verdict validated coverage earns (fix-forward X, the 2026-09-27
|
|
305
|
+
* 19:35Z dump: a 1h visit of a closed NQZ6 pane asked the span from its
|
|
306
|
+
* frontier to now in two asks, and the served-empty terminal of the first
|
|
307
|
+
* walked back 14 days over it). `spans` is the union of what the wire
|
|
308
|
+
* answered for the series: the terminals of this refetch, the coverage PLAN
|
|
309
|
+
* proved, the answer kept past the tail (the entry's provenance included).
|
|
310
|
+
* `emptySpans` are the windows among them the wire served empty.
|
|
311
|
+
* `servedNowMs` is the clock the wire serves through (the embargo bound on a
|
|
312
|
+
* delayed lane). Null when no span holds the tail. Pure.
|
|
313
|
+
*/
|
|
314
|
+
export declare function resolveMainTailVerdict(input: {
|
|
315
|
+
spans: ReadonlyArray<{
|
|
316
|
+
fromMs: number;
|
|
317
|
+
toMs: number;
|
|
318
|
+
}>;
|
|
319
|
+
emptySpans: ReadonlyArray<{
|
|
320
|
+
fromMs: number;
|
|
321
|
+
toMs: number;
|
|
322
|
+
}>;
|
|
323
|
+
tailMs: number;
|
|
324
|
+
intervalMs: number;
|
|
325
|
+
servedNowMs: number;
|
|
326
|
+
}): MainTailVerdict | null;
|
|
327
|
+
/**
|
|
328
|
+
* A closed verdict still stands (fix-forward X): it was judged on the tail
|
|
329
|
+
* the reader holds, and it is younger than the probe spacing. It expires the
|
|
330
|
+
* way the served-empty probe does: past the spacing the demand window is
|
|
331
|
+
* asked once and its answer records the next verdict. Pure.
|
|
332
|
+
*/
|
|
333
|
+
export declare function isMainClosedVerdictLive(verdict: {
|
|
334
|
+
tailTs: number;
|
|
335
|
+
throughMs: number;
|
|
336
|
+
recordedAtMs: number;
|
|
337
|
+
} | null | undefined, tailMs: number | null | undefined, nowMs: number, spacingMs: number): boolean;
|
|
338
|
+
/**
|
|
339
|
+
* The window a closed-venue probe asks (fix-forward Z, the review of Y): the
|
|
340
|
+
* GAP from the instant the tail is validated through (`reachMs`: the closed
|
|
341
|
+
* verdict's reach, else the validated reach) to the clock the wire serves
|
|
342
|
+
* through, so the probe's window touches the coverage it extends and the
|
|
343
|
+
* continuity rule of lane Y holds for it. The poll chain spaces these probes
|
|
344
|
+
* five minutes apart; a 1m chart's 2-bar poll window started minutes past the
|
|
345
|
+
* verdict's reach, every probe was refused as a gap, the entry's validated
|
|
346
|
+
* instant stopped at the last visit and the next re-initialization walked
|
|
347
|
+
* back 14 days once the demand window had slid past it.
|
|
348
|
+
* - The whole gap (fix-forward AB, the review of Z): the caller splits it
|
|
349
|
+
* into bucket-bounded chunks (`splitMainClosedProbeWindow`) and sends them
|
|
350
|
+
* one after the other inside the one cycle, so the reach touches the clock
|
|
351
|
+
* after every probe. Capped at one bucket per probe, a 1s chart fell 50 s
|
|
352
|
+
* further behind on every probe (250 s of bucket against 300 s of spacing)
|
|
353
|
+
* and the verdict never closed again.
|
|
354
|
+
* - The floating 2-bar window (`from: 0`, `pollPeriodSec`) where that window
|
|
355
|
+
* already starts a bar before the reach (a 1h chart's two hours, a 1m probe
|
|
356
|
+
* inside the bar after the reach): its answer overlaps the coverage, so the
|
|
357
|
+
* probe of a held identity leaves on its cadence whether or not widening is
|
|
358
|
+
* needed, and the dry memo and the closed verdict keep refreshing.
|
|
359
|
+
* - Null when nothing is validated past the tail: the caller keeps its own
|
|
360
|
+
* window and its own gates.
|
|
361
|
+
* Pure; unix seconds.
|
|
362
|
+
*/
|
|
363
|
+
export declare function resolveMainClosedProbeWindow(input: {
|
|
364
|
+
reachMs: number | null | undefined;
|
|
365
|
+
servedNowMs: number;
|
|
366
|
+
intervalMs: number;
|
|
367
|
+
pollPeriodSec: number;
|
|
368
|
+
}): {
|
|
369
|
+
from: number;
|
|
370
|
+
period: number;
|
|
371
|
+
} | null;
|
|
372
|
+
/**
|
|
373
|
+
* The asks a closed-venue probe window leaves as (fix-forward AB, the review
|
|
374
|
+
* of Z): an absolute window longer than one canonical bucket is split into
|
|
375
|
+
* the fewest contiguous chunks of at most a bucket each, evenly (a gap one
|
|
376
|
+
* second past a bucket is two half-bucket asks, never a bucket and a
|
|
377
|
+
* sliver), the last ending where the window ends. The caller sends them one
|
|
378
|
+
* after the other, the way the split-child pipeline sends chunk children:
|
|
379
|
+
* each chunk's served-empty answer touches the coverage the chunk before it
|
|
380
|
+
* extended, so the continuity rule holds for every one and the verdict
|
|
381
|
+
* reaches the clock inside the cycle. The floating 2-bar window (`from: 0`)
|
|
382
|
+
* and a window without a bar interval leave whole. Pure; unix seconds.
|
|
383
|
+
*/
|
|
384
|
+
export declare function splitMainClosedProbeWindow(window: {
|
|
385
|
+
from: number;
|
|
386
|
+
period: number;
|
|
387
|
+
}, intervalMs: number): Array<{
|
|
388
|
+
from: number;
|
|
389
|
+
period: number;
|
|
390
|
+
}>;
|
|
391
|
+
/** What a verdict patch that landed on the cache entry carried, per cache key. */
|
|
392
|
+
export interface LandedMainTailVerdict {
|
|
393
|
+
tailTs: number;
|
|
394
|
+
throughMs: number;
|
|
395
|
+
/** When a CLOSED verdict of this tail was last patched; null while the tail is only validated. */
|
|
396
|
+
closedAtMs: number | null;
|
|
397
|
+
}
|
|
398
|
+
/**
|
|
399
|
+
* The record of a cache key after one more patch landed (fix-forward Z, the
|
|
400
|
+
* review of Y): patches of one tail MERGE, the way the store merges them. Two
|
|
401
|
+
* panes that share a key complete in either order, so a closed verdict that
|
|
402
|
+
* reaches less far than the record (inside the clock slack) is a closure the
|
|
403
|
+
* store took: the record keeps the furthest reach and the newest closure.
|
|
404
|
+
* Dropped whole, the closure stayed unrecorded and every terminal of that
|
|
405
|
+
* verdict wrote the entry again. A patch of another tail replaces the record.
|
|
406
|
+
* Pure.
|
|
407
|
+
*/
|
|
408
|
+
export declare function mergeLandedMainTailVerdict(held: LandedMainTailVerdict | null | undefined, landed: LandedMainTailVerdict): LandedMainTailVerdict;
|
|
409
|
+
export declare function planMainRefetchAsks(input: MainPlanInput): MainPlanResult;
|
|
410
|
+
/**
|
|
411
|
+
* The span a staged family mounts (fix-forward lane S1, the 2026-09-27 ETH
|
|
412
|
+
* to BTC production dump): the staged rows' span (first row to last row plus
|
|
413
|
+
* one bar, the row-to-range convention of `mainRowsToFetchRange`) united
|
|
414
|
+
* with the asks the plan sends into them. The family's last terminal mounts
|
|
415
|
+
* exactly this, so the overlay kick base reads it as the span main will
|
|
416
|
+
* mount before any terminal lands; the kicks then cover it and the post-main
|
|
417
|
+
* compare finds nothing to re-ask. A count ask (period 0) adds nothing. Null
|
|
418
|
+
* without staged rows or an interval, or when the rows are not a span.
|
|
419
|
+
*/
|
|
420
|
+
export declare function stagedFamilyMountSpan(stagedRows: ReadonlyArray<ReadonlyArray<number>>, asks: ReadonlyArray<{
|
|
421
|
+
from: number;
|
|
422
|
+
period: number;
|
|
423
|
+
}>, intervalMs: number): {
|
|
424
|
+
from: number;
|
|
425
|
+
period: number;
|
|
426
|
+
} | null;
|
|
427
|
+
type MainOverlapVerdict = 'clean' | 'drift' | 'evict';
|
|
428
|
+
export interface MainOverlapPoisonInput {
|
|
429
|
+
mounted: readonly (readonly number[])[];
|
|
430
|
+
reply: readonly (readonly number[])[];
|
|
431
|
+
intervalMs: number;
|
|
432
|
+
/** The residual's own window (ms, end exclusive). */
|
|
433
|
+
windowFromMs: number;
|
|
434
|
+
windowToMs: number;
|
|
435
|
+
/** The receipted frontier (ms): rows past it are new data, never compared. */
|
|
436
|
+
compareThroughMs?: number;
|
|
437
|
+
nowMs: number;
|
|
438
|
+
/** Rows whose close is younger than this are skipped (FRESH_CLOSE_HOLD_MS). */
|
|
439
|
+
freshCloseHoldMs?: number;
|
|
440
|
+
/** Mounted timestamps that are not wire rows (synthetic gap markers) or that carry a newer live stamp. */
|
|
441
|
+
skipTs?: ReadonlySet<number>;
|
|
442
|
+
tickSize?: number;
|
|
443
|
+
volumeEpsilon?: number;
|
|
444
|
+
}
|
|
445
|
+
export interface MainOverlapPoisonResult {
|
|
446
|
+
verdict: MainOverlapVerdict;
|
|
447
|
+
reason?: 'timestamp-set' | 'grid';
|
|
448
|
+
compared: number;
|
|
449
|
+
driftTs: number[];
|
|
450
|
+
missingInReply: number[];
|
|
451
|
+
missingInMounted: number[];
|
|
452
|
+
}
|
|
453
|
+
export declare function detectMainOverlapPoison(input: MainOverlapPoisonInput): MainOverlapPoisonResult;
|
|
454
|
+
export {};
|