Skip to content

Commit 53488e7

Browse files
Add model baseline page, update docs (#1289)
* Update CGT and employer NI parameters * Update docs and add model baseline page * Update make * Add jb install * Add jb dep * Update makefile
1 parent d0c7163 commit 53488e7

14 files changed

Lines changed: 639 additions & 445 deletions

File tree

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,3 +80,6 @@ coverage.xml
8080
.hypothesis/
8181
.pytest_cache/
8282
cover/
83+
84+
# Docs
85+
**/_build/

Makefile

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
.PHONY: docs
2+
13
all: install
24
pip install build
35
python -m build
@@ -19,10 +21,12 @@ update-tests:
1921
python policyengine_uk/tests/microsimulation/update_reform_impacts.py
2022

2123
documentation:
22-
jb clean docs/book
23-
jb build docs/book
24+
cd docs/book && jupyter book clean --all -y
25+
cd docs/book && jupyter book build --html
2426
python docs/book/add_plotly_to_book.py docs/book/_build
2527

28+
docs: documentation
29+
2630
changelog:
2731
build-changelog changelog.yaml --output changelog.yaml --update-last-date --start-from 0.1.0 --append-file changelog_entry.yaml
2832
build-changelog changelog.yaml --org PolicyEngine --repo openfisca-uk --output CHANGELOG.md --template .github/changelog_template.md

changelog_entry.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
- bump: minor
2+
changes:
3+
added:
4+
- Docs upgraded to jupyter book 2.
5+
- Model baseline page added.
6+
- Capital gains tax baseline updated.

docs/book/_config.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,3 @@ sphinx:
2525
- "sphinx.ext.napoleon"
2626
- "sphinx_math_dollar"
2727
- "sphinx.ext.mathjax"
28-

docs/book/_toc.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,5 @@ parts:
1515
- file: validation/hbai
1616
- caption: Policy
1717
chapters:
18+
- file: policy/model-baseline
1819
- file: policy/uc-rebalancing

docs/book/myst.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
version: 1
2+
project:
3+
title: PolicyEngine UK documentation
4+
authors:
5+
- name: PolicyEngine
6+
copyright: "2024"
7+
github: https://github.com/policyengine/policyengine-uk
8+
repository:
9+
url: https://github.com/policyengine/policyengine-uk
10+
branch: master
11+
path: docs/book
12+
toc:
13+
- file: index
14+
- title: Usage
15+
children:
16+
- file: usage/getting-started
17+
- file: usage/simulations
18+
- file: usage/scenarios
19+
- title: Assumptions
20+
children:
21+
- file: assumptions/growthfactors
22+
- file: assumptions/water-bills
23+
- title: Validation
24+
children:
25+
- file: validation/hbai
26+
- title: Policy
27+
children:
28+
- file: policy/model-baseline
29+
- file: policy/uc-rebalancing
30+
site:
31+
options:
32+
logo: logo.png
33+
template: book-theme
34+
extensions:
35+
- sphinx.ext.autodoc
36+
- sphinx.ext.viewcode
37+
- sphinx.ext.napoleon
38+
- sphinx_math_dollar
39+
- sphinx.ext.mathjax
40+
config:
41+
html_js_files:
42+
- https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.4/require.min.js
43+
html_theme: furo
44+
pygments_style: default
45+
html_css_files:
46+
- style.css
47+
execute:
48+
execute_notebooks: off

docs/book/policy/model-baseline.md

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
# Model baseline
2+
3+
PolicyEngine UK models the UK tax and benefit system as of 2025, incorporating major reforms from 2020-2025. This page documents the key policy changes by year, working backwards from 2025, showing how each reform is implemented in the codebase.
4+
5+
## 2025 reforms
6+
7+
### Autumn Budget 2024
8+
9+
The government increased the [employer National Insurance rate from 13.8% to 15%](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_1/rates/employer.yaml#L13-L17) and reduced the [employer secondary threshold from £9,100 to £5,000 annually](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_1/thresholds/secondary_threshold.yaml#L26-L30), both taking effect in fiscal year 2025-26.
10+
11+
### Universal Credit rebalancing
12+
13+
Parliament passed legislation to implement Universal Credit rebalancing reforms, with the [rebalancing switch activated in fiscal year 2025-26](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/dwp/universal_credit/rebalancing/active.yaml#L3). The reforms include [graduated standard allowance uplifts](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/dwp/universal_credit/rebalancing/standard_allowance_uplift.yaml) above inflation: 2.3% in 2026-27, 3.1% in 2027-28, 4.0% in 2028-29, and 4.8% in 2029-30. A [new health element of £217.26](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/dwp/universal_credit/rebalancing/new_claimant_health_element.yaml#L3) will be introduced for new claimants in fiscal year 2026-27.
14+
15+
### Benefit uprating
16+
17+
Annual benefit uprating applied 4.1% increases to state pensions and 1.7% to working-age benefits, implemented through the [standard uprating mechanism](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/benefit_uprating_cpi.yaml).
18+
19+
## 2024 reforms
20+
21+
### Autumn Statement 2023
22+
23+
The government announced further National Insurance cuts, reducing the [employee main rate from 10% to 8%](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_1/rates/employee/main.yaml#L22-L27) and the [self-employed Class 4 rate from 9% to 6%](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_4/rates/main.yaml#L16-L21) in fiscal year 2024-25. [Class 2 National Insurance contributions were abolished](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_2/flat_rate.yaml#L14-L19) for self-employed people, with the flat rate set to £0 in fiscal year 2024-25.
24+
25+
### Capital gains tax changes (Autumn Budget 2024)
26+
27+
The government increased capital gains tax rates from 10%/20% to [18% for basic rate taxpayers](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/cgt/basic_rate.yaml#L4) and [24% for higher rate taxpayers](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/cgt/higher_rate.yaml#L4) in fiscal year 2025-26.
28+
29+
### Spring Budget 2024
30+
31+
The government increased the [child benefit high income tax charge threshold from £50,000 to £60,000](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/income_tax/charges/CB_HITC/phase_out_start.yaml#L4) in fiscal year 2024-25.
32+
33+
### Autumn Statement 2023 (Employee NI cut)
34+
35+
An initial National Insurance cut reduced the [employee main rate from 12% to 10%](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_1/rates/employee/main.yaml#L16-L21) in fiscal year 2024-25.
36+
37+
## 2023 reforms
38+
39+
### Autumn Statement 2022
40+
41+
The government reduced the [additional rate income tax threshold from £150,000 to £125,140](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/income_tax/rates/uk.yaml#L74-L78), taking effect in fiscal year 2023-24. The government also began reducing the [capital gains tax annual exempt amount from £12,300 to £6,000](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/cgt/annual_exempt_amount.yaml#L6-L10) in fiscal year 2023-24, with a further reduction to [£3,000 in fiscal year 2024-25](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/cgt/annual_exempt_amount.yaml#L11-L15).
42+
43+
## 2022 reforms
44+
45+
### Spring Statement 2022
46+
47+
The government announced an increase in the [National Insurance primary threshold from £9,880 to £12,570](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_1/thresholds/primary_threshold.yaml#L17-L22), aligning it with the personal allowance in fiscal year 2022-23.
48+
49+
### Autumn Budget 2021 (Health and Social Care Levy)
50+
51+
The government temporarily increased [National Insurance rates by 1.25 percentage points](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/national_insurance/class_1/rates/employee/main.yaml#L4-L10) in fiscal year 2022-23, later reversed the same fiscal year.
52+
53+
### Mini-Budget 2022 (September)
54+
55+
The government announced increases to [stamp duty nil rate thresholds](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/stamp_duty/residential/purchase/main/subsequent.yaml), raising the main threshold from £125,000 to £250,000 and the first-time buyer threshold to £425,000.
56+
57+
### Cost of living support
58+
59+
The government announced cost of living payments: [£650 for means-tested benefit recipients](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/treasury/cost_of_living_support/means_tested_households/amount.yaml#L3), [£300 for pensioners](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/treasury/cost_of_living_support/pensioners/amount.yaml#L3), and [£150 for disability benefit recipients](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/treasury/cost_of_living_support/disabled/amount.yaml#L3), implemented through dedicated [payment calculation variables](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/variables/gov/treasury/cost_of_living_support/cost_of_living_support_payment.py).
60+
61+
### Energy Price Guarantee
62+
63+
Following the energy crisis, the government introduced an [Energy Price Guarantee capping typical household bills at £2,500](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/ofgem/energy_price_guarantee.yaml#L12-L18) in fiscal year 2022-23.
64+
65+
## 2021 reforms
66+
67+
### Autumn Budget 2021
68+
69+
The government reduced the [Universal Credit taper rate from 63% to 55%](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/dwp/universal_credit/means_test/reduction_rate.yaml#L5) and increased [work allowances by £500 annually](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/dwp/universal_credit/means_test/work_allowance/without_housing.yaml#L9) in fiscal year 2021-22.
70+
71+
### End of COVID-19 support
72+
73+
The government ended the [Universal Credit £20 weekly uplift](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/dwp/universal_credit/standard_allowance/amount.yaml) in fiscal year 2021-22, with rates reducing from the elevated 2020-21 levels.
74+
75+
### Stamp duty holiday extension
76+
77+
The government extended the stamp duty holiday with [phased withdrawal of the nil rate increases](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/stamp_duty/residential/purchase/main/subsequent.yaml#L20-L22) during fiscal year 2021-22.
78+
79+
## 2020 reforms
80+
81+
### Summer Economic Update (July 2020)
82+
83+
The government introduced a [stamp duty holiday with nil rates up to £500,000](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/hmrc/stamp_duty/residential/purchase/main/subsequent.yaml#L9-L15) in fiscal year 2020-21 to support the housing market.
84+
85+
### COVID-19 response (March 2020)
86+
87+
Emergency measures included a [£20 weekly increase to Universal Credit standard allowances](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/parameters/gov/dwp/universal_credit/standard_allowance/amount.yaml#L6) and other working-age benefits in fiscal year 2020-21.
88+
89+
## Current baseline (2025)
90+
91+
The model baseline includes all reforms above, resulting in:
92+
- **Income tax**: 20%/40%/45% rates with personal allowance of £12,570 and higher rate threshold of £50,270
93+
- **National Insurance**: 8% employee rate, 15% employer rate, 6% self-employed rate
94+
- **Capital gains tax**: 18%/24% rates with £3,000 annual exempt amount
95+
- **Universal Credit**: 55% taper rate with rebalancing reforms active
96+
- **Benefits**: Standard uprating with targeted cost of living support for 2022
97+
98+
## What is not modelled
99+
100+
The model does not include:
101+
- **PIP reform announced in Autumn Statement 2023**: The government announced reforms to Personal Independence Payment assessments and eligibility criteria, phasing out 25% of claimants between 2025-29. These reforms are [defined as a scenario](https://github.com/PolicyEngine/policyengine-uk/blob/master/policyengine_uk/scenarios/pip_reform.py) but not included in the baseline model
102+
- **Non-domiciled taxation changes**: Remittance basis abolition and four-year exemption regime from fiscal year 2025-26 are not modelled
103+
- **Non-UK resident stamp duty surcharge**: 2% additional rate from fiscal year 2021-22 is not modelled
104+
- **Some devolved tax policies**: Beyond property transaction taxes, other devolved policies may have limited coverage
105+
106+
All parameter values include references to primary legislation and can be found in the [PolicyEngine UK parameters directory](https://github.com/PolicyEngine/policyengine-uk/tree/master/policyengine_uk/parameters).
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
description: Capital gains tax rate on additional rate taxpayers. This parameter is under active development and reforms including it should not be cited.
22
values:
33
2015-01-01: 0.2
4+
2025-04-06: 0.24
45
metadata:
56
unit: /1
67
label: Capital Gains Tax additional rate
8+
reference:
9+
- title: Finance Act 2025(7)
10+
href: https://www.legislation.gov.uk/ukpga/2025/8/section/7
11+
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
description: Capital gains tax rate on basic rate taxpayers. This parameter is under active development and reforms including it should not be cited.
22
values:
33
2015-01-01: 0.1
4+
2025-04-06: 0.18
45
metadata:
56
unit: /1
67
label: Capital Gains Tax basic rate
8+
reference:
9+
- title: Finance Act 2025(7)
10+
href: https://www.legislation.gov.uk/ukpga/2025/8/section/7
11+
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
description: Capital gains tax rate on higher rate taxpayers. This parameter is under active development and reforms including it should not be cited.
22
values:
33
2015-01-01: 0.2
4+
2025-04-06: 0.24
45
metadata:
56
unit: /1
67
label: Capital Gains Tax higher rate
8+
reference:
9+
- title: Finance Act 2025(7)
10+
href: https://www.legislation.gov.uk/ukpga/2025/8/section/7

0 commit comments

Comments
 (0)