Calibrate salary sacrifice population to HMRC/ASHE headcount targets#268
Merged
vahid-ahmadi merged 4 commits intomainfrom Feb 16, 2026
Merged
Calibrate salary sacrifice population to HMRC/ASHE headcount targets#268vahid-ahmadi merged 4 commits intomainfrom
vahid-ahmadi merged 4 commits intomainfrom
Conversation
Add two-stage imputation: QRF for non-respondents, then headcount-targeted conversion of pension contributors to below-cap SS users. Add three new calibration targets in loss.py (7.7mn total, 3.3mn above cap, 4.3mn below). Source: https://www.gov.uk/government/publications/salary-sacrifice-reform-for-pension-contributions-effective-from-6-april-2029 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Tests total (7.7mn), below-cap (4.3mn), and above-cap (3.3mn) SS user counts. Marked xfail until recalibration. Skipped when enhanced FRS dataset is not available. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Fixes ModuleNotFoundError in CI where setuptools is not installed. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
vahid-ahmadi
added a commit
that referenced
this pull request
Feb 16, 2026
Resolve conflict in utils/loss.py (keep registry delegation). Incorporate salary sacrifice headcount targets from PR #268 into the structured registry (obr.py, compute/income.py, build_loss_matrix.py). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
vahid-ahmadi
added a commit
that referenced
this pull request
Feb 17, 2026
PR #268 added Stage 2 imputation (records at exactly 2k) and headcount calibration targets. The calibrator classified above/below 2k at uprated 2025 prices, but the saved h5 stores 2023 prices where the classification differs (8.55% inflation flips boundary records). Now evaluates SS at base-year prices before thresholding so calibration matches end-user values. Also reduces Stage 2 target to 3M so the calibrator upweights gently rather than overshooting. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
salary_sacrifice.py: converts pension contributors without SS into below-cap (≤£2,000) SS users, moving employee pension contributions to salary sacrifice to keep totals consistentloss.py: total SS users (7.7mn), below-cap (4.3mn), above-cap (3.3mn), anchored at ASHE 2024 with 2.4%/year growth (OBR para 1.7)Context
PE currently undercounts salary sacrifice users (4.5mn vs 7.7mn HMRC estimate). The gap is almost entirely in below-cap contributors — auto-enrolment workers who don't realise their pension is via salary sacrifice. The existing calibration targets only cover monetary amounts (£24bn contributions, tax relief by band) with no headcount constraint.
Test plan
🤖 Generated with Claude Code