Repository navigation
Add Warm Home Discount receipt rates by group - #2616
Conversation
DESNZ's 2026 impact assessment (para. 40) says around 85% of Pension Credit recipients and around 70% of other means-tested benefit recipients become rebate recipients. Apply these with a seeded household draw, following the UC deductions pattern. Fixes #2615 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
juaristi22
left a comment
There was a problem hiding this comment.
Reviewed 27771b5abd2cd067830d4fc3a4c845621f280dcc.
The 85% Pension Credit / 70% other-benefit receipt rates are supported by DESNZ's impact assessment, paragraphs 38–40. They describe conversion from receiving a qualifying benefit to receiving WHD, so applying them after the underlying benefit's take-up is appropriate. A stable household-ID draw is reasonable for representing full £0/£150 awards and keeping reform comparisons consistent.
C1 — Preserve receipt assignment when survey data is filtered. policyengine_uk/variables/gov/ofgem/warm_home_discount_random_draw.py:24–25 uses total household weight below one million to identify a calculator situation. A constituency or other local subset of representative data falls below that threshold, resetting all draws to zero and awarding WHD to every qualifying household.
Executed native 2026 case: household ID 24 is a 35-year-old with zero earnings and computed UC of £5,098.80. In a 1.6m-weight dataset, its draw is 0.901980 and WHD is £0. In the 400k-weight filtered subset, the same ID, personal circumstances, weight and claim inputs give draw 0 and WHD £150; HBAI income rises from £5,098.80 to £5,248.80. Both simulations are built_from_data=True. Across the 100 retained records, 26 gain a spurious rebate solely from filtering. The dataset is synthetic and this is not an actual-locality cost estimate.
Please use the existing utils/data_source.py::built_from_data provenance contract, as the current UC draw does, rather than a weight-total cutoff. Retain a filtered-data regression through the final rebate/HBAI result. No proposed repair was applied or tested in this read-only review.
On the aggregate comparison, the author's rounded group counts imply £753.9m expected rebates, versus the reported £727m draw. About £26.9m is draw deviation; the expectation is another £52.1m below the IA's £806m annual England/Wales core-rebate spend in Table 7. Report the expected total alongside the realised draw rather than using the realised £0.73bn alone to validate the probabilities. These arithmetic checks do not independently reproduce the private Microcosm release. The IA's 60%/80% scenarios concern overall conversion, not non-PC-specific confidence bounds.
Validation: 38 focused checks passed, including the native defect reproduction, mixed Pension Credit/UC priority, stable draws under amount reforms and record reordering, and final HBAI/fiscal paths. The reproduction's passing assertions record the defect rather than its correction. Official source evidence was checked independently; no material gaps in the reviewed scope. No hosted CI checks were available at capture. Review status: COMPLETE; one confirmed critical finding, C1.
|
@juaristi22 @MaxGhenis #2504 (in the queue) adds the Warm Home Discount for England and Wales and pays every eligible household (~6.9m in 2026-27). DESNZ's impact assessment (DESNZ002(F)-26-EAC, para 40) says only ~85% of Pension Credit and ~70% of other qualifying households actually receive it. This PR adds those receipt rates, taking the cost from ~£1.04bn to ~£0.73bn on Microcosm a133f37a (IA: £0.81bn). María, could you review it? Max, OK with the approach? The open questions in the body (parameter location, mixed households, draw vs exact rates, axiom line) are listed with my suggested defaults. 🤖 Generated with Claude Code |
A region or constituency filtered from the data carries under a million households of weight, so the weight cutoff reset its draws to 0 and gave every qualifying household the rebate. Use built_from_data, as the UC deduction draw does, and add a filtered-subset regression through to HBAI income. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
@juaristi22 thanks, C1 was a real bug. Fixed in 7f0aa80. C1.
The filtered-region and situation cases fail at 27771b5 and pass at 7f0aa80. Expected total. I recomputed it on Microcosm a133f37a (sha256 matches the manifest) and added it to the body. For 2026-27: £754.2m expected (5.03m households), £726.6m drawn, £806m in the IA. So £27.7m of the gap is draw noise and £51.8m is the expected total falling short of the IA, which matches your arithmetic (£753.9m from the rounded counts). The full-data totals don't change with this fix. Tests at 7f0aa80: the 24 Warm Home Discount YAML cases, 🤖 Generated with Claude Code |
juaristi22
left a comment
There was a problem hiding this comment.
Re-reviewed and approved 7f0aa805f8e8c6a75bb6120fdf913718a9162a1b.
C1 is resolved. Receipt draws now use built_from_data instead of the total-weight cutoff. A filtered region or constituency keeps the same household-ID draws, while a household situation retains the documented default even when supplied a large weight.
Replayed the original native 2026 reproduction: household ID 24 now keeps draw 0.9019800425, WHD £0 and HBAI income £5,098.80 in both the 1.6m-weight national dataset and the 400k-weight subset. All 100 retained households match their national draws, rebates and HBAI results exactly; both runs have 74 recipients, with no awards changed by filtering.
Validation: 29 focused checks passed, including the new provenance/high-weight-situation regressions, explicit draw overrides, and the native final-outcome, mixed Pension Credit/UC, common-reform and record-reordering controls. No model source was edited during review.
The 85%/70% conditional receipt-rate assessment is unchanged and its source evidence revalidates. The revised description appropriately separates expected rebates from the realised draw; exact private-population totals remain author-reported rather than independently reproduced here.
Review status: COMPLETE; no open critical findings or material evidence gaps. Only the successful Fix evidence check was present in the hosted CI capture; a hosted full-test pass is not claimed.
Pull request was closed
Aggregate impact on certified data: passBase Checks: 0 broken by this change, 1 failing on both sides, 0 fixed. Moves flagged for review: 17 (thresholds in Notes
Moves flagged for review
Spending by benefit and service
Caseloads
Household income totals
Poverty rates
People in poverty
Inequality
Mean household net income in each side's own deciles
Standard reform costings (change in gov_balance)
Standard reforms: change in each reform's target
Household net income by decileNo household's net income changes in any year. No change in any year: receipts by tax head; government balance, each component counted once; model totals; population. Checks failing on both base and head (1)
Counted-once checkEach of 88 components was raised by £1 per unit in 2026-27, and every head of its totals was read household by household: its own head must rise by exactly £1, no other tax head may move, no other benefit may rise, and the model's own total must move by what its heads moved. A head that breaks a rule is measured again twice: with every other head held at its baseline value, and with every other head held at its value after the first £1 while the component rises again. It fails where either still shows the response. 0 failed; 0 were skipped.
Provenance
Dataset: Receipts by tax head: head levels
Spending by benefit and service: head levels
Caseloads: head levels
Government balance, each component counted once: head levels
Model totals: head levels
Household income totals: head levels
Population: head levels
Poverty rates: head levels
People in poverty: head levels
Inequality: head levels
Mean household net income in each side's own deciles: head levels
Standard reform costings (change in gov_balance): head levels
Standard reforms: change in each reform's target: head levels
|
|
The current head is still |
Fixes #2615
Stacked on #2504. This PR targets #2504's branch (
warm-home-discount) because it needswarm_home_discountand its parameters, which are not on main yet. Merge #2504 first; GitHub then retargets this PR to main.Summary
warm_home_discountpays £150 to every household in England and Wales modelled as receiving a qualifying benefit. This adds a receipt rate by group, from DESNZ's 2026 impact assessment, using the model's existing seeded-draw pattern (uc_deduction_random_draw/uc_has_deduction).gov.ofgem.warm_home_discount.receipt_rate.pension_credit: 0.85, from 2025-04-01.gov.ofgem.warm_home_discount.receipt_rate.other_benefits: 0.70, from 2025-04-01.warm_home_discount_random_draw(Household): a splitmix64 hash ofhousehold_id(salt 2) in any simulation built from data (utils/data_source.py::built_from_data, as the UC deduction draw uses), including a region or constituency filtered from it, and 0 in household situations, so household calculators still show the rebate unless the draw is set.would_receive_warm_home_discount(Household): true if the draw is below the Pension Credit rate when any benefit unit in the household receives Pension Credit, otherwise below the other-benefits rate.warm_home_discountnow also multiplies bywould_receive_warm_home_discount.Evidence
DESNZ, Continuing the Warm Home Discount 2026-2031: final stage impact assessment (DESNZ002(F)-26-EAC, 30 January 2026), para. 40 (page 11): "Out of the 8.3m households estimated to receive a qualifying means-tested benefit in GB, it is estimated that around 5.9m will go on to receive a rebate. This estimate is based on delivery experience of the current scheme, which shows that around 85% of pension credit recipients become WHD recipients, compared to around 70% for all other means-tested benefits." Para. 38 gives the main reason: the recipient, partner or appointee must be named on the electricity bill. Table 8 applies the same two rates to Scotland's new core group, and para. 105 uses 70% overall with 60% and 80% as sensitivities.
The rates apply to households that receive a qualifying benefit, which is what the model's benefit variables already give after their own take-up, so they don't double count benefit take-up.
Aggregate on current data
Microcosm UK 2024-25, release a133f37a (
microcosm_uk_2024_25.h5, sha25664f83900…f914aa, matching the release manifest), England and Wales:This PR's 2026-27 realised total is £79m (10%) below the impact assessment's £806m. With the rates applied exactly, the expectation is 1.26m × 0.85 + 5.65m × 0.70 = 5.03m households, or £754.2m (computed on the data above; £753.9m from the rounded counts). So £27.7m of the gap is draw noise and £51.8m is the expected total falling short of £806m. The draw gives 80% and 68% weighted receipt rather than 85% and 70%, because only 1,791 records (an effective sample of about 370 after weighting) have Pension Credit. The unweighted shares are 84% and 70%. The rest of the gap to £806m is in the model's eligible count (6.91m qualifying households against the roughly 7.5m that 5.4m rebates imply at these rates).
HBAI income falls by the same amounts, since
warm_home_discountis inHBAI_HOUSEHOLD_NET_INCOME_ADDSon #2504.household_net_incomeandgov_spendingare unchanged.Open questions
gov.ofgem.warm_home_discount, as the DWP take-up rates sit undergov.dwp. The UC deduction parameters usegov.simulationfor the same reason; either works.Tests
policyengine_uk/tests/policy/baseline/gov/ofgem/warm_home_discount_receipt.yaml, 7 cases, all in London in 2026 with £1,000 of one benefit:policyengine_uk/tests/test_warm_home_discount_receipt.py, 3 cases on synthetic data: national data gets the hashed draws; a region filtered from it (about 0.4m households of weight, still built from data) keeps every household's draw, rebate and HBAI income from the national run, including £0 for households drawn above the rate; a household situation gets draw 0 and £150 even at a weight of 1e9. The filtered-region and situation cases fail at 27771b5, which used a total-weight cutoff.All 7 YAML cases fail at 20b0384, because
warm_home_discount_random_drawandwould_receive_warm_home_discountdon't exist there. #2504's 17 Warm Home Discount cases anduc_statutory_pay.yamlstill pass unchanged. At 27771b5 all 4,367 YAML policy tests passed. At 7f0aa80 the 24 Warm Home Discount YAML cases anduc_statutory_pay.yamlpass, as do 262 pytest cases (1 skipped) across the new receipt tests, data provenance and data-built imputations, UC deductions, trading loss, HBAI, parameter description and metadata, program registry and build metadata tests.ruff checkandruff format --checkpass on the changed Python. The aggregates above are unchanged at 7f0aa80, since the full dataset was already above the old cutoff.Reproducer: policyengine_uk/tests/policy/baseline/gov/ofgem/warm_home_discount_receipt.yaml::Pension Credit household with a receipt draw of 0.86 doesn't receive the rebate (0.86 >= 85%)
axiom: n/a: a receipt rate from DESNZ delivery statistics, not a legal rule, so there is nothing to encode in rulespec-uk
🤖 Generated with Claude Code