Technical Companion · Mathematical Specification & Out-of-Sample Record

How the two models work—and how they performed in past elections

To keep the live 2026 election pages focused on current races, this companion page collects the mathematical equations, interactive sandboxes, out-of-sample backtests from 2006 to 2024, and synthetic voter experiments behind both models.

1. Model Equations & Interactive Sandbox

Two architectures over the same election data

Both models ingest the same historical election returns, Census demographics, and live 2026 polling feed, but aggregate information in opposite directions. Play with the sliders below to see how each equation responds to national swings, local shocks, and turnout shifts.

Bottom-Up Swarm Roll-Up

Partitions each of the 3,157 U.S. counties into 10 race × education voter cells, shifts each group by national swing δnat and CES responsiveness βg, and aggregates up to districts and states.

p̂c = Σg wc,g tc,g pc,g / Σg wc,g tc,g
+0.08
Baseline
County Roll-Up Share
54.2%
Expected turnout: 61.4%

Top-Down Seat Logit Model

Starts from each district's 2024 presidential vote on the redrawn 2026 map, adds incumbency, expert ratings, and precision-weighted polls, and simulates 40,000 correlated national, state, and seat shocks.

pi,r = σ(ℓi + δr + us(i),r + ei,r)
51.0%
+0.08
+0.00
Simulated Dem Vote Share
53.0%
σ(0.04 + 0.08 + 0.00) = 53.0%

2. Out-of-Sample Historical Validation (2006–2024)

How both models performed on past elections

Every backtest is strictly out-of-sample: county priors, demographic swing elasticities, and rating weights are fit using only elections prior to the target cycle.

Presidential States (2012–2024)
198 / 204
Swarm (97.1%) · Top-Down called 196 / 204 (96.1%) across 4 cycles
2024 County Accuracy
1.31 pp
Top-Down MAE across 3,113 counties · Swarm MAE: 1.60 pp
Senate Backtests (2018–2024)
85 / 92
92.4% of contested Senate races called correctly out of sample (Brier 0.050)
House Midterms (2018 & 2022)
768 / 791
97.1% of contested House districts called correctly (2018: 383/393; 2022: 385/398)

Presidential Out-of-Sample Accuracy by Cycle

Cycle Swarm State Calls Top-Down State Calls Swarm County MAE Top-Down County MAE
201250 / 5150 / 512.63 pp2.13 pp
201648 / 5148 / 515.62 pp3.00 pp
202049 / 5149 / 512.25 pp2.08 pp
202451 / 5149 / 511.60 pp1.31 pp

Midterm House & Senate Backtest Summary

Chamber & Cycle Contested Races Called Right Close Races Right Vote Share MAE
2018 House393383 (97.5%)72 / 742.38 pp
2022 House398385 (96.7%)69 / 772.53 pp
2018–2024 Senate9285 (92.4%)21 / 282.98 pp
2010–2018 Swing Baseline1,030941 (91.4%)117 / 140—

3. Empirical Social Coupling & Dynamic LLM Voter Pool

Watch synthetic voters communicate, form & sever friendships, and shift opinions

To test how peer conversations and social sorting shape election outcomes, stratified synthetic voter personas (conditioned on Census CVAP cells, CES survey baselines, and date-bounded campaign news digests) interact in a co-evolving social network. Below, you can watch and control a live pool of LLM voter personas as they converse, form homophilous friendships, sever cross-pressured ties, and shift their vote probabilities $p_i(t)$.

Friend Ties: 42 Formed: +0 Broken: -0 Opinions Shifted: 0
1.2×
0.36
● Dem  ● Undecided  ● Rep  |  Outer ring = Initial Prior $p_i(0)$ — +New Tie  ┄ Broken Tie  — Active Dialogue
Live Dyad · Click any voter node on the graph to inspect 4-Turn Exchange
Initializing live LLM voter pool…
Live Stream: Communications, Friendships & Opinion Shifts

Measured Friedkin–Johnsen Susceptibility (β̂) by Pairing Bucket (175 Pairs, 700 Turns)

Pairing Bucket Model Pairs Measured β̂ (Mean) Measured β̂ (Median) |ΔP(Dem)| Moved Toward Peer Backfired
Browse 4-Turn Synthetic Voter Dialogues (Buckets A–D)
Inspect Date-Bounded Campaign News Topic Salience & Agent Reactions (2012–2026)

During simulation runs, agents in the news-conditioned arm received a date-bounded digest of 40 national political and economic news stories from the preceding six weeks. To comply strictly with news archive licensing terms, verbatim headlines and article text are never redistributed here; instead, we display the derived macro-issue salience breakdown of each wave alongside the LLM agents' own synthesized commentary.

—

Sampled Model-Generated Voter Reactions to This Wave (T−21d Digest Arm)

4. Required Data Licenses & Attributions

Sources requiring attribution under Creative Commons & academic licenses

Only datasets whose licenses legally require attribution (Creative Commons Attribution CC BY / CC BY-SA) are listed below. U.S. federal government works in the public domain under 17 U.S.C. § 105 and CC0 datasets require no attribution and are omitted.

  • MIT Election Data and Science Lab (MEDSL): U.S. House (1976–2024, doi:10.7910/DVN/IG0UN2), U.S. President (1976–2024, doi:10.7910/DVN/42MVDX), U.S. Senate (1976–2024, doi:10.7910/DVN/PEJ5QU), and precinct/county official returns (2016–2024). Licensed under CC BY 4.0.
  • Voting and Election Science Team (VEST): 2016 and 2020 precinct boundaries and election returns (University of Florida & Wichita State University, Harvard Dataverse doi:10.7910/DVN/NH5S2I). Licensed under CC BY 4.0.
  • Harvard Election Data Archive (HEDA): Ansolabehere, Stephen, Maxwell Palmer, and Amanda Lee (2014), 2012 Precinct-Level Election Data (Harvard Dataverse doi:10.7910/DVN/YN4TLR). Licensed under CC BY 3.0.
  • Cooperative Election Study (CES): Kuriwaki, Shiro et al. / Schaffner, Brian, Stephen Ansolabehere, and Marissa Shih, Cumulative CES Common Content (2006–2024, Harvard Dataverse doi:10.7910/DVN/II2DB6). Licensed under CC BY 4.0.
  • Multi-Office County Returns (1990–2024): Heideman, A. (2026), County-Level U.S. Presidential, Senate, and House Returns (Zenodo doi:10.5281/zenodo.22976553). Licensed under CC BY 4.0.
  • OpenElections Project: Certified Indiana 2020 precinct election returns (openelections-data-in). Licensed under CC BY 4.0.
  • University of Florida Election Lab: Early voting statistics and consolidated race ratings, directed by Michael P. McDonald. Licensed under CC BY 4.0.
  • FiveThirtyEight & Wikipedia Contributors: Historical pollster ratings and polling archives (fivethirtyeight/data, CC BY 4.0) and state/district polling table compilations from Wikipedia articles (licensed under CC BY-SA 4.0).
Return to the 2026 Forecast Home, explore the Interactive Swarm Atlas, browse the Seat-by-Seat Forecast, read the Blog Post, or ☕ Buy Me a Coffee.