Skip to content

Add the OBR's fuel freeze average and Table 6.3 policy line to the AB2026 harvest - #255

Merged
MaxGhenis merged 13 commits into
mainfrom
uk/ab2026-obr-430-table63
Nov 6, 2026
Merged

MaxGhenis merged 13 commits into
mainfrom
uk/ab2026-obr-430-table63

Conversation

@MaxGhenis

@MaxGhenis MaxGhenis commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

For #230, we add two of the OBR's estimates to the Autumn Budget 2026 harvest. In paragraph 4.30 the OBR estimates the average cut in receipts if the government keeps fuel duty frozen instead of raising it in July 2027, and in Table 6.3 it gives the policy effects on financial transactions. We also fix the findings from the reviews of #246, #249 and #253 that we left for this PR.

Changes

The OBR stager (b389bb93, on uk/ab2026-harvest-staging)

We keep the OBR family's stage.py on the staging branch, and we pushed this commit and three notes commits there (83d5a32e..bae65138). The stager now appends paragraph 4.30's £4 billion a year as row 2800, on ab2026_option__fuel_duty_continued_freeze. As it does for paragraph 3.4's average on row 2527, the stager gives the row the last fiscal year of the averaging window, 2031-32, and names the window in its aggregation: "annual average 2027-28 to 2031-32".

The stager also appends Table 6.3's "Effects of policy on financial transactions" for 2026-27 to 2031-32 as rows 2801–2806, on public_sector_net_debt_change. In paragraph 6.13 the OBR includes timely payment for self assessment in this line, so we key the rows to ab2026__package_government_decisions_since_march_2026 rather than to HM Treasury's Table 6.2 total. We leave every earlier row at its index.

For #249's finding L4, the stager sets two behavioural aggregations to annual. In paragraph 3.17 the OBR attaches "on average from 2028-29" to the £0.4 billion property yield and the £0.6 billion savings yield, and gives each behavioural response per year. So the stager now writes annual on rows 2669 (ISAs) and 2671 (property), and leaves the two yields' averages in place.

The stager reproduces the 535 key registrations we made on main in tranche 2. It writes the OBR family's claims file byte for byte as we commit it here, without primary files or network access. We keep the family's notes and manifest the same on both branches.

The OBR's latest-policy world (182cfbfc and c353349d on staging; e435c775, bb36d90c)

In paragraph 4.30 the OBR forecasts fuel duty receipts on the assumption that the government carries out its latest policy: it freezes the duty until July 2027 and raises it from then. The OBR costs a continued freeze against that forecast, in paragraph 3.43 as well as in paragraph 4.30. So the stager now proposes that world for rows 2740 and 2800, where it had proposed the pre-measures world for both. We register it as obr_october_2026_budget_forecast__policy_parameters in scorecard_db/baselines.py, and the ingest maps the stager's proposal to it.

New tests pin both claims' world and the number of OBR claims in each world. They also pin Table 6.3's six cells as the OBR prints them, with each one's fiscal year and sign, and paragraph 3.17's four aggregations.

Harvest files on main (ab8c6c58)

We copy the OBR family's files from staging. harvest_counts.py now counts 5,959 rows, 2,807 of them the OBR's, and the same number as before for every other family.

Ingest (9d486805, 4598b3bc)

The ingest now reads 5,959 rows and writes 4,688 claims and 1,271 drops: 7 more rows, 1 more claim and 6 more drops than on main. It keeps row 2800 as a revenue_change claim. It drops rows 2801–2806 as macro_fiscal_or_out_of_scope, as it drops paragraph 3.20's change in net debt on row 2688.

RF computes its rows 397–401 from two OBR forecasts, and the ingest drops them as restatements. In its reason, the ingest now names both OBR figures we keep: the effect on borrowing in 2029-30 (paragraph 3.43, row 2740) and the average cut in receipts over 2027-28 to 2031-32 (paragraph 4.30, row 2800). The tests pin the seven rows' outcomes, both figures on the option's key, and the reason's wording.

RF's freeze path against the OBR average (7c00bda9)

A new harvest test checks that RF, in rows 397–401, and the OBR, in row 2800, cost the same option over the same years. It requires one key, one metric and the fiscal years 2027-28 to 2031-32, and it requires RF's five annual cuts, which average £3.98 billion, to round to the OBR's £4 billion.

Tranche 3 (dc7b0f57)

The ingest now gives the property claim the id 9d4e7f8366be16420a10 in place of f59d84db9343c682f25b. So we regenerate STAGING_UNANSWERED.jsonl, in which the tranche 3 stager lists that claim by id, as #249's last reviewer asked. The stager still reads 368 claims, pairs 35 and tallies 333 under the same 16 reasons. It reads claims on eight pe_modifier measures, and we key the ISA claim to none of them.

Registry (592f6088, cabcea6c)

apply_ab2026_key_decisions.py now counts 980 of the harvest's figures on the 86 keys we register, 8 of them on the freeze option and 374 on the Government-decisions package. We had described the freeze option only to 2029-30, and we now name both of the OBR's horizons. We title it "Keep fuel duty frozen instead of the rise in July 2027", and in its scope we name the effect on borrowing in 2029-30 and the average cut in receipts over 2027-28 to 2031-32. Under policyengine-uk 2.151.0, build_ab2026_registry.py --check reproduces data/uk/ab2026_measures.json and REGISTRY_KEYS.md byte for byte.

Notes (f84a42bd, 36359f3a, 4c296aa1, bb36d90c; on staging, e970cd0b, 179eeb6f, bae65138, c353349d)

We apply #246's finding L1 to the IFS notes and bring the notes we corrected on main into staging, so that we keep one text of the IFS and OBR notes on both branches. In the OBR notes we separate the Government-decisions package, to which we key Table 6.3's line, from HM Treasury's total-policy package. We also count 7 rows on the tax-decisions package where we had counted 6. In the RF notes we name the two OBR figures we keep when the ingest drops RF's restatement of the freeze path. In the OBR notes we record the latest-policy world on rows 2740 and 2800.

Ingest tests for #253's low findings (1f7249d3)

The preservation test now lets the ingest add a scoring method only where the stager proposed exchequer_impact_static as the row's metric, and only as static. A new test gives CenTax row 100 a static method and requires that check to fail (L1). The static test now also tries a row with scoring_method: post_behavioural, and requires the ingest to keep it (L2). The decimal tests add £1.2345 billion, where the ingest reads a £100,000 unit from the fourth decimal place, and generate up to six places where they generated three (L3).

Invariants

  1. The OBR stager leaves every row on main at its index and appends rows 2800–2806 after them.
  2. Of main's 4,687 claims, the ingest writes 4,684 with the same id, value, conditions and world. It changes two others only in their behavioural aggregation, to annual, and gives them new ids: property f59d84db9343c682f25b → 9d4e7f8366be16420a10, and ISAs 623e0da250da8d2c9a98 → f049e37d1ca775382b00. It moves the third, row 2740's effect on borrowing, to the latest-policy world, and gives it a new id: 95e6cfa173e3c9b1b215 → 8dfd14bfb5e495ad904f.
  3. The ingest reads 7 more rows, writes 1 more claim and drops 6 more rows, and it writes its one new claim, 5111dfb313e07d38fdd2, from row 2800's £4 billion, with period 2032, in the latest-policy world.
  4. The OBR stager on staging writes the family's claims file byte for byte as we commit it on this branch. We keep the same OBR notes and manifest, and the same IFS notes, on both branches.
  5. RF's five annual cuts on the freeze option average £3.98 billion, and the OBR prints £4 billion a year over the same five years.
  6. The ingest scores two OBR claims, rows 2740 and 2800, against the latest-policy world, 2,702 against the pre-measures world, 1 against RPI uprating since 2010-11 and 7 against none.

Checks

We ran these at bb36d90c, in a clone with origin/main at 81a358d1:

PYTHONPATH=. .venv-tests/bin/python -m pytest --noconftest -n 4 -rs \
  tests/test_ab2026_harvest_contract.py tests/test_ab2026_key_decisions.py \
  tests/test_ab2026_registry.py tests/test_uk_ab2026_harvest.py \
  tests/test_uk_ab2026_ingest.py tests/test_uk_ab2026_counterparts.py tests/test_signs.py
  • All 2,462 tests passed, and pytest skipped none. We linked the policyengine-uk 2.151.0 venv into the clone, so test_the_registry_is_regenerated_byte_for_byte ran. We pass --noconftest to skip the repository database build, which needs files outside our sparse clone.
  • python -B pipeline/stage_uk_ab2026.py stage rewrote nothing, and neither did the OBR stager on staging at c353349d.
  • apply_ab2026_key_decisions.py --check, build_ab2026_registry.py --check and harvest_counts.py --check passed, and so did ruff format --check on the six Python files we changed.
  • We ran 81a358d1's families and this branch's through the ingest and compared the claims to confirm invariants 2 and 3.
  • We found all seven new quotes in both the original 28 October PDF (9e0e9c34…), which we cite in the rows, and the OBR's correction of it (555e0c26…).

We applied 13 mutants one at a time, ran the tests for each, and restored the tree after each:

Mutant Result
We shift RF row 401's value by £5 billion 1 failed
We remove paragraph 4.30's row from the OBR file 1 failed
We restore the RF drop reason that named one OBR figure 1 failed
We add static to every claim without a scoring method 1 failed, 1 passed
We overwrite a row's own scoring method with static 1 failed, 1 passed
We limit the amount parser to three decimal places 2 failed
We put row 2800 back on the pre-measures world 3 failed, 6 passed
We put row 2740 back on the pre-measures world 2 failed, 7 passed
We map the latest-policy proposal to the pre-measures world in the ingest 2 failed, 7 passed
We move row 2801 to 2027-28 in every field 1 failed, 8 passed
We reverse row 2801's sign in every field 1 failed, 8 passed
We put row 2669 back on its averaging aggregation 1 failed, 8 passed
We put row 2671 back on its averaging aggregation 1 failed, 8 passed

🤖 Generated with Claude Code

MaxGhenis and others added 11 commits November 5, 2026 19:56
Copy the family's three files byte for byte from staging, preserve the prior notes corrections, and record the receipts average beside RF's series. Regenerate COUNTS.json and update the family tally.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Name both OBR figures in the RF restatement reason. Verify one new receipts claim and six macro drops, and update the accounting and harvest metric checks without moving existing rows.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Read both staged families and check that the five annual receipts cuts round to paragraph 4.30's four billion pounds. The test rejects a changed RF endpoint or a missing OBR paragraph.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Apply #246's L1 wording to identify the deck the coordinator assigned. Keep the OBR key summaries and package scope consistent with the seven additions, and synchronize both families' notes with staging.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Regenerate STAGING_UNANSWERED.jsonl after correcting the behavioural aggregation. Replace its claim id and preserve all 368 claims, 35 counterparts and 333 unanswered entries across 16 reasons.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Update the two decision counts and their generated source notes to eight and 374 rows. Regenerate KEY_DECISIONS.md without the unavailable engine, preserve the harvest pin date, and update the aggregate test pin to 980.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Allow generated static scoring only on the static metric and reject it on CenTax's row. Preserve an existing method and test four-place amounts with generated decimals through six places; each review mutant now fails a test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Update the existing single-figure expectation for paragraph 4.30. Check borrowing and average receipts separately while retaining the borrowing claim's macro verdict.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Keep HM Treasury's total-policy package apart from the OBR's whole Government-decisions package when describing Table 6.3.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
In the new section the OBR, not paragraph 3.17 or a PDF, attaches the
average and prints the quotes, and we cite the original PDF in the rows.
We cut a sentence about our own checking and a reduced passive, and give
the tax-decisions package its 7th row, paragraph 3.4's average. In RF's
notes we split a 45-word sentence on the two OBR figures we keep.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The OBR averages paragraph 4.30's cut in receipts over 2027-28 to 2031-32,
so we drop "until 2029-30" from the option's title and name both of the
OBR's figures in its scope. We regenerate KEY_DECISIONS.md with
apply_ab2026_key_decisions.py, and data/uk/ab2026_measures.json and
REGISTRY_KEYS.md with build_ab2026_registry.py under policyengine-uk 2.151.0.

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

vercel Bot commented Nov 6, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated
policyengine-scorecard Ready Ready Preview Nov 6, 2026 1:47am UTC

Request Review

MaxGhenis and others added 2 commits November 5, 2026 21:24
In paragraphs 3.43 and 4.30 the OBR costs a continued fuel duty freeze
against its forecast on the latest policy, which includes this Budget's
measures. We register that world as
obr_october_2026_budget_forecast__policy_parameters, map the stager's
proposal for rows 2740 and 2800 to it, and copy the regenerated claims
file from staging. Tests pin both claims' world, Table 6.3's six printed
cells (review L1) and paragraph 3.17's four aggregations (review L2).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@MaxGhenis
MaxGhenis marked this pull request as ready for review November 6, 2026 02:48
@MaxGhenis
MaxGhenis merged commit 1a93ec2 into main Nov 6, 2026
13 checks passed
@MaxGhenis
MaxGhenis deleted the uk/ab2026-obr-430-table63 branch November 6, 2026 02:58
@MaxGhenis

MaxGhenis commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor Author

We merged this PR at bb36d90c, where all 13 checks pass and GitHub reports no conflicts. Vercel posted no status on this head, but our typecheck · build job built the app at bb36d90c.

GPT-6.1 Sol reviewed it twice. At cabcea6c it found that we had costed row 2800 against the wrong OBR forecast, swapped the ISA and property rows in this description, and overstated what the stager writes. It also asked for tests that pin Table 6.3's cells and paragraph 3.17's aggregations. At bb36d90c it approved, with two low findings on wording that we fix in #256. There we rewrite the baseline's description, and in one sentence of the OBR notes we name the government as the body that would borrow more and collect less if it kept the freeze.

MaxGhenis added a commit that referenced this pull request Nov 6, 2026
We bring R2 from GPT-6.1 Sol's second review of #255 to staging, so that the
OBR notes match on both branches. In the freeze note we name the government
as the body that would borrow more and collect less if it kept the freeze.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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