Repository navigation
Conversation
policyengine-us now requires an explicit SPM geography: a household without county_fips raises SPMInputError, so 8 verified examples failed. Add a county to each state-only household (Los Angeles 06037, Harris 48201, New York 36061) and update the values the current model returns for them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
5 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
The
skill-examplescheck fails on any PR right now (it surfaced on #97). The currentpolicyengine-us(2.2.1, viapolicyengine6.3.0 andspm-calculator1.0.0) never infers SPM geography from a missing county: a household with onlystate_coderaisesso 8 of the verified examples failed. This adds a county to each of the 9 state-only households, using the same form as
policyengine's own docstring ({"state_code": "NY", "county_fips": "36061"}):060374820136061Asserted values that changed (please review)
Once the examples run, some asserted numbers no longer match. Only the ACA PTC depends on the county chosen (Anderson County, TX reproduces the old 6,250.38). The rest come out the same for any county, so they reflect model changes since this check last passed on
main(2026-09-13):policyengine#0 (CA)household_net_incomepolicyengine-healthcare#0 (TX)aca_ptcpolicyengine-us#1 (NY)snappolicyengine-us#1 (NY)household_net_incomepolicyengine-us#4 (CA)ca_eitcThe prose quoting the SNAP figure is updated to match. The NY net income drop of about $15k is large enough that someone who knows the US model should confirm it is an intended model change rather than a regression. That part of this PR is the one to check.
Test plan
pytest tests/test_skill_examples.pywithpolicyengine[us]installed as in CI: 18 passed, 1 skipped (slow)uv run pytest --ignore=tests/test_skill_examples.py: 178 passedhousehold_net_incomechange (62,681 → 47,929) is expected🤖 Generated with Claude Code