Re:Show HN: Calculator for US individual income tax, from 19...
by analog31 on Wednesday June 29, 2022 @07:19PM
(#31926940)
Imagine if the tax code itself were written in Python.
Of course we all know what comes next...
[ Parent
| on HN ]
Re:Show HN: Calculator for US individual income tax, from 19...
by tmm1 on Wednesday June 29, 2022 @07:36PM
(#31927079)
In 2014, the Policy Simulation Library [1] added a model called Tax-Simulator [2], which is a Python reimplementation of TAXSIM [3][4]. It is available as open-source [5], and designed to let researchers both change existing policy variables and implement new tax reforms in Python.
[2] https://taxcalc.pslmodels.org/
[3] https://taxcalc.pslmodels.org/about/history.html
[4] https://github.com/PSLmodels/Tax-Calculator/blob/master/taxc...
Re:Show HN: Calculator for US individual income tax, from 19...
by MaxGhenis on Wednesday June 29, 2022 @08:32PM
(#31927428)
My team at PolicyEngine [1] is also now further reimplementing Tax-Calculator in the Python-based OpenFisca framework [2]. OpenFisca US [3] includes all tax logic in Tax-Calculator, plus many means-tested benefit programs like SNAP, and some state tax logic (currently only Massachusetts is complete, though we'll finish the country in the next 12-18 months). You can try it in our PolicyEngine US web app [4].
(OpenFisca US is part of the Policy Simulation Library, and it's developed by a number of former Tax-Calculator developers, myself included.)
Re:Show HN: Calculator for US individual income tax, from 19...
by fsflyer on Wednesday June 29, 2022 @08:20PM
(#31927354)
France has an open source implementation of their tax code [0]. The paper [1] gives an overview of the implementation language, mlang.
[0] https://github.com/MLanguage/mlang [1] https://arxiv.org/abs/2011.07966
Re:Show HN: Calculator for US individual income tax, from 19...
by MaxGhenis on Wednesday June 29, 2022 @09:31PM
(#31927773)
France has also developed the OpenFisca framework [1] for tax and benefit rules as code, and its OpenFisca France [2] model is widely used (I think significantly more than mlang). We've extended it to the UK [3] and the US [4].
[2] https://github.com/openfisca/openfisca-france
Re:Show HN: Calculator for US individual income tax, from 19...
by runlevel1 on Wednesday June 29, 2022 @08:15PM
(#31927327)
`policy_current_law.json` is really interesting:
https://github.com/PSLmodels/Tax-Calculator/blob/master/taxc...
Looks like the data in there goes back to 2013/2014. I'd love to see older historical policy data.
Re:Show HN: Calculator for US individual income tax, from 19...
by PopAlongKid on Wednesday June 29, 2022 @07:53PM
(#31927185)
It has been proposed in professional tax forums that this is in fact how tax code should be legislated, using some kind of pseudo-code. Even just using symbols for things such as >=, <, and so on would eliminate a lot of the garbage in the verbal version.
Re:Show HN: Calculator for US individual income tax, from 19...
by philsnow on Thursday June 30, 2022 @02:30AM
(#31929263)
This would be incredible -- it feels like the tax form documentation is written in a dialect of Accounting English from the 50s, and just little things like adding some parentheses to group and/or con/disjunctions would go a long ways.
Nearly every year I don't feel confident that I've filled out my taxes accurately, and it's not for lack of trying.