Research report

Memory-constrained forecasting

Finished: results below are from the final frozen test.

The question

If a forecaster can keep only a fixed number of bytes, is it better to keep a few learned summaries or many raw past values?

19%

lower tail-forecast error at equal memory, best budget

At equal memory the vector state cuts tail-forecast error by up to 19%, and is ahead at every budget.

0.0080.0090.0100.0110.012627690104118132q99 pinball lossResident memory (KB)
  • Scalar history
  • Vector state

Tap a memory budget

Pinball loss at q = 0.99, recency policy, on the held-out test split (3,504 queries, 499 nodes). Lower is better. The axis starts at 0.008, not zero. Bytes match by construction, checked against the memory accountant.

Frontier as a table
Resident KBVector slotsScalar slotsScalar lossVector lossDM p
61.9 KB1140.011610.010092.8 × 10⁻⁵
75.8 KB2280.011740.0094867.7 × 10⁻¹⁰
89.8 KB3420.011730.0096493.6 × 10⁻⁸
103.8 KB4560.011750.01013.6 × 10⁻⁵
117.8 KB5700.011760.010680.011
131.7 KB6840.011570.011010.20

Why it matters

Price spikes are rare, and they carry the risk, so the forecaster is scored on the 99th-percentile tail, not the average. Watching hundreds of grid nodes at once means deciding what to remember.

Method

  • Two forecasters get exactly the same bytes. One spends them on a few 14-wide slots: a node's latest price plus 13 summaries of what the whole grid is doing. The other spends them on 14 times as many slots of that node's own recent history.
  • The comparison was written down before the test data was scored. Nothing looks ahead in time, and the byte counts are checked against the memory accountant.
  • Each memory budget gets its own Diebold–Mariano test on the loss difference, corrected for correlated errors (lag 24), under two keep-policies: recency and a tail oracle.

Data

  • One year of real ERCOT electricity prices: 499 grid nodes and 35,035 intervals. The held-out test holds 3,504 queries.
  • The grid is very redundant. One factor explains 76.6% of price variance and five reach 90%; a synthetic generator needed 387, so it does not behave like the real grid.

Results

Every one of the 12 comparisons favours the vector arm. Each test is reported on its own, with its exact p-value.

The vector arm is ahead in all 12 comparisons; 11 clear p < 0.05 one at a time.

Recency policySlots, vector / scalar−0.00100.0010.0020.003← scalar better · vector better →Tail-oracle policySlots, vector / scalar00.020.040.06← scalar better · vector better →
  • p below 0.0083 (0.05 ÷ 6 budgets)
  • p below 0.05 only
  • p at or above 0.05

Tap a row for its numbers

Each row is one Diebold–Mariano test on the scalar-minus-vector loss difference (HAC variance, lag 24), one test per budget and per comparison. Dot is the difference, bar its 95% interval; right of zero means the vector arm is better. The pooled p-value (p = 8.4 × 10⁻²¹) is flagged by the repo as too optimistic and is not used here.

Tests as a table
PolicyVector / scalar slotsDifference95% intervalDM p
Recency1 / 140.001520.000808 to 0.002232.8 × 10⁻⁵
Recency2 / 280.002250.00153 to 0.002977.7 × 10⁻¹⁰
Recency3 / 420.002090.00134 to 0.002833.6 × 10⁻⁸
Recency4 / 560.001650.000865 to 0.002433.6 × 10⁻⁵
Recency5 / 700.001080.000245 to 0.001910.011
Recency6 / 840.000557-0.000303 to 0.001420.20
Tail oracle1 / 140.03050.0118 to 0.04930.001
Tail oracle2 / 280.03490.0157 to 0.05423.6 × 10⁻⁴
Tail oracle3 / 420.03550.0163 to 0.05462.9 × 10⁻⁴
Tail oracle4 / 560.03460.0157 to 0.05353.3 × 10⁻⁴
Tail oracle5 / 700.03160.0137 to 0.04945.3 × 10⁻⁴
Tail oracle6 / 840.02130.00811 to 0.03440.002

Why summaries work: a handful of factors carry most of what the whole grid is doing.

Real prices need 5 factors for 90% of their variance; the synthetic generator needed 387.

50%60%70%80%90%100%12345678910Variance explainedFactors kept90%
  • Price
  • Tail indicator

Tap a factor count

Cumulative variance explained by the first factors across 499 real grid nodes and 35,035 intervals of one year of real prices. Factors for 95% and 99%: 11 and 38 (prices), 29 and 87 (tail indicator).

Variance as a table
FactorsPrice varianceTail-indicator variance
176.6%61.6%
283.3%71.5%
387.5%78.3%
489.5%81.2%
590.9%83.5%
692.0%84.8%
793.0%85.9%
893.7%86.9%
994.3%87.8%
1094.8%88.6%

A learned memory keeper did not beat a simple baseline at any of three scales. A negative result, kept.

A learned memory keeper never beat the simple H2O-style baseline, at any of three scales.

0.000.040.080.12
  • Keep all
  • H2O-style
  • Learned

Tap a scale

Mean q99 pinball loss on each run's frozen test split at a 25% state budget; lower is better. Keep-all stores everything and is the reference; H2O-style keeps the most-attended entries.

Scales as a table
ScaleStreams × contextKeep allH2O-styleLearned
Small32 × 480.064580.076920.1238
Medium512 × 2560.080540.063190.08072
Full2,048 × 1,0240.11170.10970.1119

An earlier pre-registered claim, that streaming scenario selection would beat batch selection, was not supported.

A pre-registered claim failed: streaming scenario selection did not beat batch selection.

0255075100
  • Median error, with interval

Tap a method

Median absolute error of the 99% CVaR estimate, in percentage points, on the frozen test (k = 96 scenarios kept, 12 exposures, one touch of the test set); lower is better, and bars show 95% bootstrap intervals. The claim was that the streaming reservoir would beat the probability-metric batch method at equal bytes. It did not: its error is 36.3 points higher (interval [−14.9, 68.4]).

Methods as a table
MethodMedian error (pp)Interval lowInterval high
Streaming reservoir60.410.591.9
Probability-metric23.422.127.2
Sequential min-sum22.48.923.8
CVaR-aware23.422.127.2
k-means medoids12.211.220

The honest limits

  • The vector arm is ahead in all 12 comparisons, but not every one is significant on its own. Raw per-budget p-values clear 0.05 in 11 of 12; recency at the largest budget does not (p = 0.20). The repository reports recency as significant at 4 of 6 budgets and the tail oracle at 6 of 6.
  • The pooled p-value (8.4 × 10⁻²¹) is too optimistic because six correlated series are pooled. The per-budget tests are the evidence.
  • Tail-oracle losses are inflated by a mismatch in how the readouts were fit, so only the comparison between arms is meaningful there, not the level.
  • One electricity market, one year of prices, one machine. Other markets are not tested.

What is next

  • The same idea of spending a fixed budget by decision value is applied to a third resource, test-time compute, measured in milliseconds instead of bytes.
  • Open question: why the learned keeper trails the simple baseline at every scale.
Next reportSatellite constellations for disaster response