Skip to content

Document every result's baseline and make the projection baseline selectable (TR2008, TR2026, CBO 2026) - #512

Merged
MaxGhenis merged 11 commits into
masterfrom
nasi-baseline-selectable-20261001
Oct 4, 2026
Merged

MaxGhenis merged 11 commits into
masterfrom
nasi-baseline-selectable-20261001

Conversation

@MaxGhenis

Copy link
Copy Markdown
Contributor

Answers the third NASI follow-up from 2026-10-01 (Jon Schwabish): state the baseline behind every result, and make it selectable between the latest Trustees intermediate assumptions and CBO's long-term projections, with fertility by single year of age rather than one total rate.

What changes

Documentation (docs/baselines.md, new page in the docs book).

  • One table gives the baseline behind each published result: exercises 1 and 3, exercise 2, exercise 4, Registration 18, and gates m6, 2, 2b, 2c and w1.
  • Per-assumption sections cover COLA, AWI, mortality, claiming, DI, fertility, earnings and immigration, with code citations.
  • A "Choosing a baseline" section and a "Fertility by age" section describe the new package.
  • "Known discrepancies" records the A1 §15 AWI wording and the claiming table vintages.

One paper sentence corrected. paper.qmd said the Trustees Report publishes no projected death probabilities by single year of age and sex. The 2008 Report prints none, but OACT publishes them with every Report since 2014. The sentence now says so and cites the 2026 file. No number in the paper changes.

Inputs (data/external/tr2026/, data/external/cbo2026/; accessors in data/tr2026.py and data/cbo2026.py).

  • 2026 Trustees intermediate assumptions:
    • V.C1 COLAs for 2025–2035, then V.B1 CPI-W growth (tagged derived);
    • the VI.G1 AWI;
    • the V.A1 total fertility rate and age-sex-adjusted death rates;
    • OACT's probabilities of death by single age and sex, 1900–2100.
  • CBO 2026:
    • single-year fertility rates for ages 14–49;
    • mortality by age and sex. Read as probabilities of death, these reproduce CBO's published life expectancies within 0.0011 years; read as central rates, they do not;
    • CPI-U and real earnings growth;
    • covered earnings per worker.
  • The 2026 Statistical Supplement's claiming table, with entitlement years through 2025.
  • Every file is SHA-256 pinned, with provenance and a transcription check. Pinned source folders are marked binary in .gitattributes, because git's line-ending normalization would otherwise break the pins on checkout.
  • No cost, income or balance table was captured.

Selectable baselines (src/populace_dynamics/baselines/). get_baseline(name) returns one of three:

  • tr2008_intermediate is the default. It delegates to the constructors the registered tests use.
  • tr2026_intermediate uses the 2026 Trustees assumptions. The Trustees publish only a total fertility rate, so single-age rates scale the NCHS 2024 age shape to each year's total, tagged derived.
  • cbo2026_long_term uses CBO's published single-age rates.

How the new baselines behave:

  • Both splice realized COLAs through 2025 and the realized AWI through 2024.
  • DI rates stay 2008-fit under every baseline, a named gap: neither source publishes DI rates by age.
  • build_track_a_inputs refuses a real-data run under a non-legacy baseline, because such a run would need its own Candidate 2 design: latent-permanent conditioned chained QRF (research memo) #42 registration.
  • baselines/fertility.py adds an opt-in single-age birth step for open populations. It is not gated, it is report-only, and it does not touch the gated fertility law.
  • scripts/describe_baseline.py prints any baseline's input paths.

No published number changes. Every registered result keeps tr2008_intermediate. This PR edits no file in runs/, gates.yaml, engine/loop.py, engine/steps.py, or the v1 modules under cola_track_a/, fra68_track/, ss/ and estimates/cola_age_profile.py.

Invariants (property-based and example tests)

  • tr2008_intermediate equals the existing constructors exactly. Differential tests cover every COLA (2008–2030), AWI (1975–2085), mortality array (2009–2030), claim pmf and DI rate the registered tests read.
  • Every baseline:
    • q(x) lies in [0, 1], and q at age 119 is 1 where the source closes the table;
    • age-specific fertility is non-negative and sums to that year's TFR;
    • the AWI is positive;
    • COLA paths are continuous at splices;
    • claim pmfs sum to 1.
  • Life expectancy recomputed from q(x) matches TR V.A4 and CBO sheet 1 within stated tolerances.
  • The band interpolation preserves each five-year band's sum and stays non-negative.
  • In the birth step, expected births equal the sum of rates over exposed women; zero rates give zero births.

Tests (targeted, on the host)

  • tests/baselines/ (114), tests/data/test_tr2026_artifact.py, tests/data/test_cbo2026.py, tests/test_baseline_life_table.py and tests/test_ssa_claim_ages_2026.py: all pass, with 64 unit and 175 artifact tests added to the tier manifest.
  • tests/estimates/test_birth_evidence_artifact.py, tests/test_paper_text.py and tests/track_u2/test_u2_isolation.py pass.
  • quarto render docs/baselines.md passes.

axiom: n/a (projection-input data, docs and an opt-in baseline layer; no policy rule changes)

🤖 Generated with Claude Code

MaxGhenis and others added 8 commits October 2, 2026 16:52
data/tr2026.py reads the 2026 Trustees Report's intermediate
assumptions: Table V.C1 COLAs (2025-2035, then annual CPI-W growth from
V.B1, tagged derived), the VI.G1 average wage index (1970-2100), the
V.A1 total fertility rate and age-sex-adjusted death rates, and OACT's
probabilities of death by single age and sex (historical 1900-2023,
Alternative II 2024-2100).

data/cbo2026.py reads CBO's January 2026 demographic projections
(single-year fertility rates for ages 14-49, mortality by age and sex),
the February 2026 long-term economics and the September 2026 Social
Security inputs. CBO publishes no CPI-W, COLA or wage index, so those
paths are derived and tagged as builder defaults awaiting ratification.
The mortality series reproduces CBO's life expectancies as q(x), not
m(x).

Also adds the 2026 Statistical Supplement's Table 6.B5.1 claiming
distribution (entitlement years through 2025). Every file is pinned by
SHA-256 with provenance and a transcription check. No cost, income or
balance table was captured.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The four OACT death-probability CSVs use CRLF line endings. Under
'* text=auto' git stored them LF-normalized, so a fresh checkout would
not match the SHA-256 pins in data/tr2026.py. Mark the tr2026 and
cbo2026 source folders as binary.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Add docs/baselines.md (listed in docs/_quarto.yml after methodology.md).
It sets out, with path:line citations, the assumption vintage, COLA
path, AWI, mortality, claiming, disability, fertility, earnings and
immigration assumptions of exercises 1 and 3 and Registration 18 (TR2008
intermediate), of the realized-income exercises 2 and 4 (with their named
Trustees-vintage deltas and exercise 2's annuity life tables), and of
gates m6, 2, 2b, 2c and w1. It describes the selectable baselines being
added (tr2008_intermediate as the default every registered result keeps,
tr2026_intermediate and cbo2026_long_term), marks each series published
or derived, records the 2008-fit disability rates as a named gap under
every baseline, explains fertility by single year of age and how a
Trustees-consistent schedule is derived from the V.A1 total rate, and
lists known discrepancies, including the A1 section 15 AWI wording
(geometric interpolation) against the single-year VI.F6 table the code
reads.

Correct one sentence in paper/paper.qmd: the 2008 Trustees Report prints
no projected death probabilities by single age and sex, but OACT
publishes them with each Report in downloadable files from the 2014
Report on (2026 DeathProbsE file cited). No number changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
src/populace_dynamics/baselines/ bundles everything a projection reads
besides its cohort: COLA, CPI-W, AWI, mortality by single age, sex and
year, age-specific fertility, the claim-age table and DI rates. Three
baselines are registered:

- tr2008_intermediate (default): delegates to the constructors the
  registered projection tests use; differential tests show exact
  equality for every COLA, AWI, mortality, claiming and DI value those
  tests read.
- tr2026_intermediate: 2026 Trustees intermediate assumptions. The
  Trustees publish only a total fertility rate, so single-year rates
  scale a documented age shape to each year's TFR (tagged derived).
- cbo2026_long_term: CBO's 2026 projections, with CBO's published
  single-year fertility rates for ages 14-49.

The 2026 baselines splice realized COLAs through 2025 and realized AWI
through 2024 before any projected value, and claim ages come from the
2026 Statistical Supplement. DI rates stay 2008-fit under every
baseline, a named gap: neither source publishes DI rates by age.
build_track_a_inputs refuses a real-data run under a non-legacy
baseline; those need their own registered entry point.
baselines/fertility.py adds an opt-in ASFR birth step for open
populations (not gated, report-only; it does not touch the gated
fertility law). scripts/describe_baseline.py prints any baseline's
input paths.

Invariants tested: q in [0, 1]; ASFR non-negative and summing to the
baseline's TFR; positive AWI; continuous COLA splices; claim pmfs sum
to one; interpolation preserves band sums; expected births equal the
sum of rates over exposed women.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs/baselines.md now describes the package as built: get_baseline, the
refusal of real-data runs under non-legacy baselines, describe_baseline,
the realized COLA and AWI splices, CBO's derivation defaults, the q(x)
reading of CBO mortality, the NCHS 2024 default fertility shape and the
2026 Supplement claiming table. The new src modules join the birth-
evidence reducer's post-review exclusions (nothing historical imports
them), and the tier manifest counts the 64 unit and 175 artifact tests
they add.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Oct 3, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
social-security-model Ready Ready Preview Oct 4, 2026 6:30pm UTC

Request Review

Review of d9bfc0f found no blocker and asked for these changes:

- docs/baselines.md: the cbo2026_long_term column now states every
  splice the code applies (realized COLAs and TR2026 CPI-W through 2025,
  OACT historical mortality before 2021, the summed-ASFR total fertility
  rate for 2021-2025, the ten-year-to-long-term CPI-U join, the 2025-26
  AWI bridge, held growth after 2056, refusal after 2099).
- project_track_a runs only on invented cohorts; the page and two
  docstrings said "invented or unregistered".
- 2025 values are labelled estimated or provisional, not historical.
- The death-probability sentence in the paper and on the page no longer
  claims the series starts with the 2014 Report. It says what we found:
  the 2014, 2015 and 2026 files answer at OACT's Downloadables address
  and 2010-2013 return "not found" there.
- The OACT model-documentation citation gains its PDF pages (10-12).
- Paper citations name paragraphs, not line numbers that drift.
- tests/baselines/test_isolation.py asserts by syntax-tree scan that no
  registered runner, v1 track module or engine module imports the
  baselines package; only scripts/describe_baseline.py does.
- cbo2026/provenance.md lists the 62556 workbook's five sheet names and
  says it holds no outlay, revenue, cost-rate or balance table.

Tier counts recounted after the merge: unit 5,896, artifact 3,506.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MaxGhenis and others added 2 commits October 4, 2026 14:28
…tality-year example

Delta review of ac4857f (APPROVE) found two minor issues: the scan
ignored relative imports (from ..baselines import ...), so a future one
in a registered module would escape the guard; and the CBO mortality
example said a 2010 opening reads OACT values for 2010-2020, when the
first projected year is 2011.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Keeps both sides' reducer exclusions. Tier manifest by three-way sum
(base 6d4a2b7 + this PR + master 492d5a6): unit 6,029, artifact 3,536.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@MaxGhenis
MaxGhenis merged commit ff3fe30 into master Oct 4, 2026
12 checks passed
@MaxGhenis

Copy link
Copy Markdown
Contributor Author

Merge record: merged at reviewed head 278abd4 (merge commit ff3fe30).

  • Reviews (independent Subfleet agents):
    • d9bfc0f: Opus, REQUEST_CHANGES, docs only, no blocker.
    • ac4857f: GPT-6.1 Sol executing delta review, APPROVE. All 8 earlier findings resolved; 264 targeted tests pass; tier counts match a full collection; 18 ASFR and 12 q(x) cells match the CBO source exactly.
    • 278abd4: Opus confirmation review, APPROVE. Both minor findings fixed (relative-import resolution, mortality-year example); the merge with master kept both reducer lists intact; manifest equals a full collection (unit 6,029, artifact 3,536).
  • CI: every check passed on 278abd4.
  • Scope: no published number changes. Every registered result keeps tr2008_intermediate, and no runs/, gates.yaml, engine/loop.py, engine/steps.py or v1 track module was edited.

MaxGhenis added a commit that referenced this pull request Oct 4, 2026
…eakdowns PR

Keeps both sides' reducer exclusions. Tier manifest from a full
collection, reconciled with master plus this PR's delta: unit 6,401,
artifact 3,904, integration_psid 1,346.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MaxGhenis added a commit that referenced this pull request Oct 5, 2026
Mention the wait for gate_epuf_fill's verdict where the H1 run is
summarized, list forecasts among the second comment's items, disclose
the EPUF overlap in the plan's H1 summary, and record that PR #512
(selectable baselines) merged on 2026-10-04 as ff3fe30.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MaxGhenis added a commit that referenced this pull request Oct 6, 2026
…lation branch

Takes master's version of PR #506's artifact test (#514 narrowed its pin
to the generator's own code). Tier counts are master's plus this branch's
additions: unit 6,166; artifact 3,536; integration_psid 1,341;
reproduction_legacy 520; oracle_policyengine 232 (11,795).

The registered commit 3ba0d02 (tag registration-19-sa1) is unchanged;
this merge only brings the branch up to date for PR #511.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch was successfully deployed

1 active deployment
Preview — 278abd4d Deployed Oct 4, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant