Published 8-sector results predate the July 2026 MTR fix in OG-UK
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 30/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- javascript, python
- Ambito
- data, documentation
Direzione di ricerca
Start with src/data/tpiData.json and the cited OG-UK api.py changes and commits; review the reproduction scripts and current transition-path traces mentioned in the issue. Done means either regenerating the published series on current OG-UK or adding provenance that records the OG-UK commit, policyengine version, generation date, and the MTR and terminal-condition caveats.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
src/data/tpiData.json was generated on 28 April 2026 (commit d57e012). Since then OG-UK has fixed a bug in its marginal-tax-rate estimation that materially changes the tax functions feeding the model. The published sector3 and sector24 series therefore rest on tax rates that OG-UK itself now treats as wrong.
The bug that was fixed
From oguk/api.py:410-416 (OG-UK, commit 3c3ce10, 22 July 2026 — "Support policyengine-uk >= 2.89; fix the silent MTR bugs the pin was masking"):
"the previous code did not divide at all, so
1 - deltawent negative for every multi-adult household andnp.clipfloored it to ZERO (measured: 80% of GBP 25-35k earners at a 0.000 labour MTR)"
Measured on current code, the weighted-mean labour MTR is 0.26. Under the April code path it was ~0 for most middle earners. That is the tax schedule the household block was solving against when these results were produced.
Timeline
| date | commit | event |
|---|---|---|
| 21 Apr 2026 | 3a16cff (OG-UK) |
last OG-UK commit before the dashboard data |
| 28 Apr 2026 | d57e012 (here) |
tpiData.json generated |
| 22 Jul 2026 | 3c3ce10 (OG-UK) |
MTR fix |
| 29-31 Aug 2026 | ad30d7b, fe857a8, d0e6ae5 (OG-UK) |
resource-constraint checks restored/retuned |
oguk/industry_params.py and oguk/oguk_default_parameters.json are byte-identical between April and now, so the sectoral calibration itself has not changed. Only oguk/api.py did (~360 lines).
A second, separate problem
Reproducing an 8-sector transition path on current OG-UK, the solve does not converge over the full horizon:
RuntimeError: Transition path equlibrium not found (RC_error)
The resource-constraint error grows roughly geometrically from t≈4 and the path is non-finite from t=20:
| t | |RC|max | D/Y |
|---|---|---|
| 0 | 5.7e-3 | 0.950 |
| 3 | 1.3e-4 | 0.881 |
| 4 | 2.9e-3 | 0.854 |
| 7 | 1.4e-2 | 0.931 |
| 10 | 8.5e-2 | 0.922 |
| 12-15 | > RC_TPI = 0.2 | — |
| 20+ | nan | nan |
Eliminated by experiment as causes: TPI outer method (Picard and Anderson give bit-identical failures), the level of alpha_G (SS-calibrated 0.252 vs default 0.209), fiscal-closure timing (tG1 4 vs 20, tG2 20 vs 45, rho_G 0.6 vs 0.15), start_year (2026 and 2027), and the MTR change itself (zeroing labour MTRs to emulate the April bug reproduces the divergence exactly). The 8-sector steady state converges cleanly (5.9 min, FOC errors ~1e-12), and the 1-sector transition path converges (6.5 min) — so neither the sectoral calibration nor the transition machinery is broken on its own.
Relevant to this dashboard: the published series covers 2026-2030 only, which is precisely the region where the path is still well-behaved (RC ~1e-3). So these five years may be fine in isolation — but they were solved as part of a global path whose terminal condition is not met, and households are forward-looking. That should be stated rather than assumed.
Suggested actions
- Regenerate
tpiData.jsonon current OG-UK, or - Add a provenance note recording the OG-UK commit,
policyengineversion and generation date behind the published figures, and flag that the 8-sector series predates the MTR fix.
I can prepare either. Reproduction scripts and the full per-period traces are available.
- Lingua principale
- JavaScript
- Stelle
- 0
- Fork
- 0
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di PolicyEngine/og-model-dashboard
-
bug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 42/100
PolicyEngine/og-model-dashboard#6 · 1 commento ·
-
question
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
Tutte le issue di PolicyEngine/og-model-dashboard
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
ClickHouse/clickhouse-js#1130 ·
I maintainer di solito rispondono entro 1 giorno
-
bug claude Minor static-analysis
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
linagora/cozy-flagship-app#1359 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 69/100
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
openlayers/create-ol-app#70 ·