Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
9678f5d
Filter-aware gated provider and constraint-derived band edges (#725, …
juaristi22 Sep 16, 2026
98536ab
Add the scaled_by_ratio value operation for ratio-translated cells (#…
juaristi22 Sep 16, 2026
d1c3c55
Row-level signed exclusions and exact-suffix CGT band naming for fan-…
juaristi22 Sep 16, 2026
4375592
Vendor the HMRC CGT 2024-25 conditioning facts from the pinned Chroni…
juaristi22 Sep 16, 2026
955622f
Condition the UK CGT amounts redraw on age and region on the 2024-25 …
juaristi22 Sep 16, 2026
2e48ddd
Bind HMRC CGT 2024-25 age-band, region-tier and size-of-gain targets …
juaristi22 Sep 16, 2026
6d0721f
Re-pin the UK Chronicle feed to c5e5bf8 and vendor the HMRC CGT Table…
juaristi22 Sep 16, 2026
fab0c43
Draw the CGT joint from Table 3 2024-25, add the asset-type stage and…
juaristi22 Sep 16, 2026
6210b0c
Check the asset-type enum at the transferred boundary and re-pin the …
juaristi22 Sep 17, 2026
408de87
Net the CGT cell-walk rounding and realise the residential flag by we…
juaristi22 Sep 17, 2026
d096805
Round the CGT cell walks systematically and name the UC element exclu…
juaristi22 Sep 17, 2026
da39c39
Draw each CGT plan's amounts on stratified quantiles, the open band o…
juaristi22 Sep 17, 2026
37a91c5
Measure the CGT distribution on twin spines and calibrations (#725)
juaristi22 Sep 17, 2026
72a113d
Split the 16-24 rake group and hold Table 6 gains by age with an expo…
juaristi22 Sep 17, 2026
b18d422
Carry each CGT cell walk's rounding error into the next cell (#725)
juaristi22 Sep 17, 2026
3ba335f
Draw each CGT plan's amounts on weight-proportional quantile strata (…
juaristi22 Sep 17, 2026
d6376f3
Measure the split-plus-tilt rounds and correct the liability reading …
juaristi22 Sep 17, 2026
7d7757c
Regenerate the derived surfaces on the c5e5bf8 feed after rebasing ov…
juaristi22 Sep 17, 2026
04c00aa
Drop the unused math import from the CGT asset-type stage (#725)
juaristi22 Sep 18, 2026
491f7c5
Address Vahid's review round 1 on #939 (#725)
juaristi22 Sep 18, 2026
e488718
Close the two pre-merge residuals from Vahid's approval (#725)
juaristi22 Sep 18, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/467-cgt-band-targets.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Bind the HMRC CGT 2024-25 individual observations by size of gain (Table 2.1a, twelve bands from GBP 3,000 under the incumbent `hmrc/cgt_taxpayers_band_<lower>` and `hmrc/capital_gains_band_<lower>` names, closing #467), by age band (Table 6: taxpayers, gains and liability for the eight adult bands) and by country and region (Table 5 over the twelve-area region tier, restated on the individuals basis by the Table 1 share through `scaled_by_ratio`) as UK calibration targets, alongside the three national totals. The 0-2,999 gain band (below the 2024 annual exempt amount) and the 0-15 age band (no under-16 gainers on the frame) are signed out row by row; the Table 3 fence stays in place and records the promotion.
1 change: 1 addition & 0 deletions changelog.d/725-cgt-age-region-conditioning.changed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The UK CGT amounts redraw (`hmrc_cgt_gains` and its spine projection) now conditions on age and household region as well as the taxable-income proxy: the allocation targets are raked to the Table 6 age and Table 5 region margins (the latter on the individuals basis via the Table 1 share) from the vendored `hmrc_cgt_conditioning_facts.json`, and gainers are walked inside income x age x region cells with a pooled per-income-band fallback where a cell lacks support. The stage summary reports achieved against published at the Table 6 and Table 5 grain and the age x gain-band joint microcosm#725 measured, plus the rake and fallback receipts. The rake also holds Table 6 gains by age as one linear constraint per age group (an exponential tilt of the group's cells that keeps its count), so each age group carries its published gains as well as its taxpayers, and the youngest group is 16-24 on its own (seven age groups) so its rows are no longer ranked under the 25-34 carriers. Each cell walk's signed rounding error is carried into the next cell's boundaries for the same gain band, so a band's walked total within an income band stays within one person's weight of its raked total instead of accumulating the overshoot of many cell walks.
1 change: 1 addition & 0 deletions changelog.d/725-cgt-asset-type-stage.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add the `hmrc_cgt_asset_type_spine` UK spine stage after the CGT amounts redraw. Every liable gainer (net gains above the annual exempt amount) carries a main asset type in the new person column `capital_gains_asset_type` and, where flagged as a residential property disposer, its net gain in `capital_gains_residential_property`. The residential flag is a logistic in log gains solved so the household-weighted count and gains of flagged persons equal HMRC Table 8a 2024-25 restated on the individuals basis by the Table 8b individuals/all share, realised by seeded systematic sampling; the non-residential remainder draws one of the five Table 7 asset types from a size-tilted categorical whose type weights reproduce the fenced Table 7 2023-24 gains shares (diagnostic only). The rows come from the new vendored `hmrc_cgt_asset_type_facts.json`; the stage declares its operations in the manifests, a stage-health gate holds the realised residential totals within 5 percent, an enum-domain gate holds the column to the declared values, and the graph parity fixture carries synthetic facts sized to its frame.
1 change: 1 addition & 0 deletions changelog.d/725-cgt-donor-vintage.changed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The CGT size-band donor stage (`cgt_band_donors`) now takes its nine retained HMRC Table 2.1a bands from the vendored 2024-25 conditioning facts (392,000 individuals, GBP 118.2bn from GBP 12,300 upward) instead of the retired hand-extracted 2023-24 copy `hmrc_cgt_size_bands.json`, so donor starting weights sit on the same vintage as the size-of-gain calibration targets; the reviewed retained-mass pins are asserted at stage time.
1 change: 1 addition & 0 deletions changelog.d/725-cgt-residential-property-targets.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Bind HMRC Table 8a 2024-25 residential property taxpayers and gains (UK residents, all reporting channels, restated on the individuals basis by the Table 8b share through `scaled_by_ratio`) as UK calibration targets `hmrc.cgt.residential_property_taxpayers` and `hmrc.cgt.residential_property_gains`, measured over the liable gainers the asset-type stage flags residential. Table 7's asset-type rows stay fenced.
1 change: 1 addition & 0 deletions changelog.d/725-cgt-table3-joint-2024-25.changed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The UK CGT amounts redraw now draws from HMRC Table 3 for 2024-25 (the 2026 release's joint of individuals and gains by size of gain and taxable income, with the taxable-income bands moved onto the GBP 125,140 Personal Allowance taper edge) copied verbatim from the pinned Chronicle feed into `hmrc_cgt_conditioning_facts.json`, instead of the 2025 release's 2023-24 ODS rescaled onto the 2024-25 band levels. The pinned `Table_3_2025_Size_of_gain_by_income.ods` input, its `verify_pinned_cgt_ods` operation, the `cgt_published_fact_surface` artifact and the `--cgt-ods` build argument are retired; both CGT manifests declare a `verify_vendored_fact_resource` operation that checks the resource's recorded feed against `chronicle_feed.json` before a row is read, and the loader refuses a Table 3 row set whose band totals disagree with the Table 2.1a bands folded onto them beyond publication rounding.
1 change: 1 addition & 0 deletions changelog.d/725-chronicle-feed-repin-c5e5bf8.changed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Re-pin the UK Chronicle consumer feed to `c5e5bf8` (PolicyEngine/chronicle#271 and #273: DESNZ subnational energy and NEED 2024 packages; HMRC CGT Tables 7, 8 and 9), 276,205 rows. Every national and local reference, membership register, census, validation-level block, vendored resource and compile-parity receipt regenerates from the new artifact; no compiled target value moved on either surface, and the `need_energy_facts.json` selection now carries both NEED vintages (456 rows).
1 change: 1 addition & 0 deletions changelog.d/725-filter-aware-gated-provider.changed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
`parameter_gated_threshold` bindings now honour their `filters`, `household_conditions` and a declared `groupby_variable` band after the gate, and accept a geography fan-out predicate, so a gated measure (the AEA-gated CGT taxpayer proxy) can be sliced into published age, region and size-of-gain rows instead of publishing the national population on every row. Numeric universe constraints on a Chronicle fact (`cgt_gain >= 3000`, `age >= 16`) are stamped as `ledger_filter_<variable>_lower_bound` / `_upper_bound` metadata so banded measures can read edges that publishers state as constraints rather than dimensions.
1 change: 1 addition & 0 deletions changelog.d/725-scaled-by-ratio-value-operation.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add the `scaled_by_ratio` value operation for Ledger target references: a published cell is translated by the quotient of two other facts (`base * numerator / denominator`, ratio in (0, 1]), with the base, numerator, denominator, ratio and member fact keys recorded on the compiled spec. It restates HMRC CGT Table 5 country/region cells, which include trusts, on the individuals basis of the national targets using the Table 1 individuals/total share. The runtime candidate prefilter and the authoring compile now keep the facts an operand selector reaches outside the cell's own selector.
Loading
Loading