assembly-economics/research/ModelMatching.md

12 KiB
Raw Blame History

Model matching and regime flipping

Status: v0.4 (2026-10-13), ASSEMBLY-WP-0012 and WP-0017. The IMM filter passes its synthetic acceptance test (§ 4.2). It runs on the observed US series (§ 4.3). There it is overconfident: its observation noise is not yet calibrated for real data. Its first output is a flip candidate (B3 → B4), not a flip.

Code: simulations/gadm02/matching.py. Data: observed_series.json. Results: results/matching.md (observed), results/matching_synthetic.md (synthetic test).

1. Candidates and fit criterion (T01)

Candidates: band anchor B1–B4 × legitimacy loop off/on, each started from the jurisdiction's calibrated state (calibrate_data.start_state). B1 stays in the set with its misfit recorded, so a return to B1-like growth would be visible.

For each candidate, the adoption indicator is taken as proportional to K_Ω. Two values are fitted: a time offset t0 and a scale s, with log y = log s + log K_Ω(t0 + τ) + ε and ε ~ N(0, σ) (σ per series: BTOS 0.03, Eurostat 0.05). The calibrated K_Ω level range at the end of the window adds a Gaussian level term. All candidates fit the same number of values, so AIC weights reduce to likelihood weights.

The sentiment slope (Pew 2021 → 2026) is not scored yet: the points precede the model start (checkpoint 0). It is switched on once there are sentiment points after checkpoint 0.

2. Results on observed data (T02, T04)

Jurisdiction Data Anchor weights Loop weights Best
US BTOS, 23 biweekly points 2025–2026 B1 0.00 · B2 0.38 · B3 0.40 · B4 0.21 off 0.52 · on 0.48 B3 / loop off (0.23)
EU Eurostat 2023–2025 B1 0.00 · B2 0.03 · B3 0.96 · B4 0.01 off 0.48 · on 0.52 B3 / loop on (0.50)
DE Eurostat 2023–2025 B1 0.00 · B2 0.44 · B3 0.56 · B4 0.00 off 0.49 · on 0.51 B3 / loop on (0.29)

Weights after the BR-009 fix (sentiment anchored at its measured level, WP-0017-T01). Before the fix: US B3 0.44 / B2 0.38 with loop off 1.00; EU B3 0.62; DE B2 0.73.

Readings:

  1. The data rule out B1 everywhere, and B4 for the EU and DE. The present is B2–B3, consistent with the calibration (models/Calibration.md § 3).
  2. The adoption data cannot yet tell the loop on from off. Before the BR-009 fix, every US loop-on candidate failed. The neutral reference made the measured low sentiment (Σ 0.285) brake adoption from the first day. With sentiment anchored at its measured level, today's level is part of the fitted speed, and only changes in sentiment act. The loop weights are then about 0.5 everywhere. The loop becomes identifiable with sentiment observations after checkpoint 0. sig_adopt stays at 1 and is not yet identified.
  3. No regime is established yet. No candidate reaches weight 0.75. Predictions v1 (P-2026-001 … 004) assume growth alignment between B2 and B3, which the matched weights bracket. No predictions v2 are needed (T04).

3. Flipping events (T03)

A flipping event is a change of the regime a jurisdiction operates under, detected when:

  1. the best-weighted candidate changes, and
  2. the new best holds weight ≥ 0.75 at two consecutive evaluations.

Before a first regime is established (weight ≥ 0.75), changes are not flips.

Measured flips come from the regime filter on observed data. Every quarter, each regime's dynamics run forward from the current state estimate over the last quarter, the weights are updated with a switching prior (0.02 per quarter), and the estimate advances with the best regime. Simulated flips are regime crossings inside a model run, for example the B4 boom-bust of BR-005. Flips are recorded in research/FlipRegister.md.

4. Synthetic test (T06): not yet reliable

Truth is simulated from a known candidate. In the switch cases it changes regime at t = 4. It is observed biweekly with 3 % log-noise, with level evidence as wide as the real US target. Three seeds per case (results/matching_synthetic.md).

Indicators Correct regime at start False flips (no-switch truth) Switches detected
adoption only 3 of 6 3 of 6 0 of 6
adoption + annual sentiment 3 of 6 3 of 6 2 of 6 (delays 0.5 y and 3.25 y)

The design went through three stages:

  1. Free re-fitting of t0 and s per window: any candidate matches any segment.
  2. Alignment fixed after the first window: still path-based, so a regime change starting now is not represented.
  3. A forward filter from the current state, with evidence accumulated across quarters.

Each stage reduced false flips. None of them made detection reliable.

Why: with adoption alone, neighbouring anchors (B2/B3/B4) differ by less than measurement noise over a quarter. The loop switch leaves almost no trace in adoption. In sentiment it is confounded by BR-009: the sentiment equation reverts toward neutral from the low measured level.

Requirements before flips may be declared (ASSEMBLY-WP-0017):

  • more discriminating indicators: investment (L5) for self-enhancement, sentiment at least twice a year for the loop, and concentration channels (CB1) for domination dynamics;
  • per-regime state tracking (one state per regime, not one shared estimate);
  • the sentiment equation fixed (BR-009);
  • acceptance criteria: at least 5 of 6 regimes correct at the start, no false flips in 6 no-switch runs, and at least 4 of 6 switches detected within 1.5 years.

4.1 IMM filter with several indicators (WP-0017-T02/T03)

matching.py --imm (results/matching_imm.md):

  • Filter: an interacting-multiple-model filter. Each regime keeps its own state, and before each quarter the regime states are mixed by the switching probabilities (0.10 per quarter). Each regime then runs forward, and the weights update with the likelihood of all indicators in the quarter.
  • Indicators: adoption (biweekly, log sd 0.03), gross organism investment (quarterly, log sd 0.05), discovery channel Pd (monthly, sd 0.01) and sentiment (twice a year, sd 0.02).
  • Sentiment: anchored (BR-009 fix).
Case Result
anchor correct at the first evaluation (no-switch truth) 6 of 6
false flips (no-switch truth) 0 of 6
acceleration B2 → B4 detected 3 of 3, delay 1.0–1.5 years
slowdown B3 → B2 right direction 3 of 3, but delay 2.5–3.75 years (outside 1.5)
loop switch off → on 0 of 3

Acceptance (anchor switches ≥ 4 of 6 within 1.5 years): not passed (3 of 6).

Readings:

  1. Accelerations are visible fast. Slowdowns are not. After a slowdown, the paths diverge slowly from a shared state. For the real data: telling B2 from B3 in the US (P-2026-001) will take roughly 2.5–4 years of observations, not one.
  2. The loop state is not identifiable while sentiment is flat. With sentiment anchored, switching the loop on changes nothing visible until perceived benefit moves. The loop is a conditional regime: it can be matched only after a shock to perceived benefit.
  3. More indicators remove false flips; they do not speed up slowdown detection. With adoption alone the IMM filter had 3 of 6 false flips. With all four indicators it had none.

Observed series for the real filter: US adoption (BTOS), US investment (L5, quarterly; operator rough), US discovery channel (StatCounter, monthly), EU and DE adoption (annual). Sentiment points after checkpoint 0 do not exist yet.

4.2 Flips judged on anchors: acceptance passed (WP-0017-T04)

The slow slowdown detection in § 4.1 came from the flip rule, not from the evidence. Investment halves immediately when B3 switches to B2 (0.090 → 0.044), but the new anchor's weight split between B2/loop-off and B2/loop-on, which are indistinguishable while sentiment is flat. Neither reached 0.75. The rule now judges anchor flips on anchor weights (summed over the loop state) and loop flips on loop weights. False flips count both.

Indicators Anchor correct at start False flips Anchor switches within 1.5 y Delays
adoption + investment + Pd + sentiment 6 of 6 0 of 6 6 of 6 0.5 y each (two quarters, the minimum)
adoption + Pd + sentiment (no investment) — 5 of 6 5 of 6 0.5–3.0 y

Acceptance passed with all four indicators (results/matching_imm.md).

Caveats:

  1. Perfect model. Truth and candidates share the model structure. Real data contain misspecification, so real performance is worse.
  2. The investment indicator carries the result. Without it, false flips rise to 5 of 6. The real investment series (L5) covers all information-processing equipment, not AI only. Before measured flips may be declared, an AI-specific investment series is needed (WP-0017-T06).
  3. The loop state stays undetectable while sentiment is flat. Loop flips are therefore not declared from the filter at all until a sentiment shock gives evidence.

4.3 The filter on observed US data (WP-0017-T05)

matching.py now also runs the IMM filter on the observed US series (results/matching.md).

  • Calendar: t 0 = 2025-08-01.
  • Series: adoption (BTOS, biweekly, 22 points after the start), investment (L5b, Census private office construction including data centers, monthly) and discovery (StatCounter, monthly).
  • Start: the static matching weights.
Calendar t (quarter) B2 B3 B4
0.32 (late Nov 2025, start) 0.38 0.40 0.21
0.57 0.00 1.00 0.00
0.82 0.00 1.00 0.00
1.07 (Q3 2026) 0.00 0.00 1.00

Robustness of the last quarter: noise × 2: B4 0.96; noise × 3: B3 0.58 / B4 0.42; without investment: B4 0.69. The search share does not affect the result.

Readings:

  1. The US was in B3 from early to mid-2026. B2 drops out after the first quarter in all variants.
  2. Q3 2026 shows a move toward B4: a flip candidate, not a flip. Two things drive it. Adoption rose from 21.8 % to 23.8 % within about two months, and data-center construction keeps accelerating (L5b +20 % in four months). The move shows without the investment series too (0.69). It is not robust to 3× noise. The rule needs a second quarter at ≥ 0.75, so it is checked at the next review (research/FlipRegister.md, watch list).
  3. The filter is overconfident on real data. Weights jump to 1.00 within one quarter, which a perfect-model noise level allows but real model error does not justify. Calibrating the observation noise against real model residuals is the next step (ASSEMBLY-WP-0015-T07).
  4. Meaning for predictions: a confirmed B4 regime would move the US adoption path of P-2026-001 toward the B4 band. That band peaks early and predicts a plateau or decline by 2030. Predictions are not changed on a candidate.

Checkpoint integration. Full checkpoint records point to results/matching.md, which is re-run at the review of each checkpoint. The unattended runner does not compute regimes, so the approved execution declaration stays unchanged.

4.4 Observation noise from real residuals (WP-0015-T07, step 1)

Residual standard deviations around the best static regime (US, B3/loop off): adoption 0.026, investment (L5b) 0.078, discovery 0.009. With these (never below the assumed noise), the filter result is unchanged: B3 for two quarters, B4 at 1.00 in Q3 2026, no confirmed flip (results/matching.md). The filter's sharpness therefore comes from model-structure uncertainty (all candidates share the GADM structure), not from underestimated measurement noise. The B3 → B4 check waits for Q4 2026 data.