Add Scottish Child Payment baby bonus reform#1474
Conversation
Add parametric reform that provides £12.85/week extra for children under 1 year old on top of the standard £27.15/week SCP amount. The reform is controlled by the gov.contrib.scotland.scottish_child_payment.in_effect parameter (default: false). Changes: - Add baby_bonus.yaml parameter (£12.85/week for age < 1) - Add in_effect.yaml parameter toggle - Update scottish_child_payment variable to support parametric baby bonus - Add structural reform module in reforms/scottland/ - Add 9 YAML tests covering various scenarios 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Revert main scottish_child_payment variable to baseline (no baby bonus logic) - Add structural reform to reforms.py for parameter-triggered activation - Add structural reform integration to simulation.py - Update YAML tests to use reforms: key for structural reform application 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
@PolicyEngine review this |
Code Review - Scottish Child Payment Baby Bonus ReformI've reviewed the PR implementation and found it to be well-structured with comprehensive test coverage. Here are my findings: ✅ Strengths
|
Fixed directory and import typo identified in code review: - Renamed policyengine_uk/reforms/scottland/ → scotland/ - Updated import in reforms.py - Updated all test references in scottish_child_payment_baby_bonus.yaml This addresses the critical issue found in PR review where the directory was named "scottland" instead of "scotland" (missing 'n'). Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
The policy specifies children under 1 receive £40/week TOTAL payment, not a fixed £12.85 bonus added to the base rate. As the base SCP rate inflates over time, this ensures under-1s continue receiving exactly £40/week rather than an increasing amount. Changes: - Changed from base_rate + fixed_bonus to where(age < 1, 40.0, base_rate) - Updated all test comments to reflect £40 as TOTAL payment - Updated docstrings to explain policy correctly Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
After researching the official policy sources, I found that the original implementation did not match the actual Scottish Government policy. I've now pushed a fix. The Actual Policy The Scottish Government policy is: "the Scottish Child Payment will rise to £40 for families with children under the age of one" (https://www.gov.scot/publications/scottish-budget-2026-2027-finance-secretarys-statement-13-january-2026-2/) Key word: "to £40" (not "by £12.85") This means:
The Fix (Now Applied) I've updated the implementation in commit 845e2f7 to use: Calculate per-child weekly amount (age-dependent)PREMIUM_RATE_UNDER_ONE = 40.0 # £40/week fixed total Calculate total for all eligible childrentotal_weekly = benunit.sum(per_child_weekly * is_eligible_child) This ensures under-1s always receive exactly £40/week regardless of base rate inflation. Test Updates I've also updated all test comments in scottish_child_payment_baby_bonus.yaml to explicitly document that £40 is a TOTAL payment, not a base + bonus. Sources Confirming Fixed £40 Total
|
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…riable Enable parametric SCP baby bonus by checking gov.contrib.scotland.scottish_child_payment.in_effect in the base variable. When in_effect=True, children under 1 receive £40/week total instead of the standard rate. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Summary
gov.contrib.scotland.scottish_child_payment.in_effectparameter (default: false)Changes
gov/contrib/scotland/scottish_child_payment/:baby_bonus.yaml- £12.85/week for children under age 1in_effect.yaml- boolean toggle (default false)scottish_child_paymentvariable to conditionally apply baby bonus when reform is activereforms/scottland/scottish_child_payment_reform.pyTest plan
🤖 Generated with Claude Code