Repository navigation
Conversation
liheap_eligible is true when a household is eligible for its state's regular LIHEAP heating or cooling benefit. It reads a new list of state eligibility variables, gov.hhs.liheap.regular_eligibility, as liheap reads its list of payments. Alaska had no eligibility output, so this adds ak_hap_eligible, true when the household has an award. Michigan's Home Heating Credit and Illinois crisis assistance are left out, as in liheap. The list-integrity test now covers the new list and checks that every payment in the national total has its eligibility flag in it. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
hua7450
marked this pull request as ready for review
November 23, 2026 19:06
PavelMakarchuk
approved these changes
Nov 24, 2026
PavelMakarchuk
left a comment
Collaborator
There was a problem hiding this comment.
#11243: Add a national liheap_eligible output
Verdict: APPROVE (head da81ef3096)
The head did not move during the review. The head commit is from 2026-11-23, 2:02pm EST.
Summary
The PR adds liheap_eligible, a national yes/no output on the SPM unit. It reads a new list, gov.hhs.liheap.regular_eligibility, with adds, in the same way as liheap reads gov.hhs.liheap.regular_payments. The PR also adds ak_hap_eligible (true when ak_hap > 0), because Alaska had no eligibility output. No existing output changes. The list covers every jurisdiction that liheap covers (50 of 51; Michigan stays out, as in liheap), and every cooling eligibility variable in the model. All tests pass at the head, CI is green, and I found no wrong value or behavior.
Findings
CRITICAL
None.
SHOULD ADDRESS
None.
SUGGESTION
- The West Virginia member is an income test only.
policyengine_us/parameters/gov/hhs/liheap/regular_eligibility.yaml:67listswv_lieap_income_eligible. That variable does not check the fuel. Failure case: a 2026 West Virginia household with $15,000 of wages andheating_typeUNSPECIFIED getsliheap_eligible: trueandwv_lieap: 0. In the other 49 jurisdictions, an unset fuel usually gives false. The PR body and the variable documentation describe this. Optional: add a shortwv_lieap_eligible(income test and a supported fuel), or name West Virginia in the documentation ofliheap_eligible. - Program registry.
policyengine_us/programs.yaml(LIHEAP entry, about line 1037) names onlyliheap. The registry has no field for a second output, so no change is necessary. Optional: say in the entrynotesthatliheap_eligibleexists.
What I checked
- Head and state. The head is
da81ef3096(1 commit onmainat0a440f1de8).mainmoved by two commits after that base (Massachusetts HEAP FY2027, #11205). Those commits do not touch the LIHEAP lists. A merge with currentmainis clean. GitHub reports MERGEABLE, BLOCKED (review needed). - Reference. I fetched 42 U.S.C. 8624 from Cornell. The anchor
#b_2exists. It is the income eligibility rule (150% of the poverty level or 60% of state median income, and categorical eligibility). This is a correct citation for an eligibility list. Forak_hap_eligible, I fetched 7 AAC 44.080. Subsection (m) makes a household with fewer than 2.0 points after (a) to (l) ineligible. Soak_hap > 0is a correct eligibility test. Both Alaska URLs return 200. - List coverage. I loaded the system and checked each of the 61 members: all are bool, SPM unit, YEAR and state-gated. I compared the list with the 62 payments in
regular_payments. Every payment has its gate on the list:defined_forfor most;al_liheap,fl_liheapandok_liheapread their flag in the formula; the three California payments each requireca_liheap_basic_eligible(directly, or throughca_liheap_utility_eligibleand the liquid-fuel formula). I searched all state folders for cooling eligibility variables. All 11 (AL, AR, DE, GA, KY, LA, NE, NJ, OK, SC, VA) are on the list. - No conflict or double count. No other variable is named
liheap_eligible. The new variable is an output only. Nothing in the model reads it, and it is not in a benefit or net income total. - Formula.
addson a bool variable returns bool. A household with two true flags (Alabama heating and cooling) gives true, not 2. - Default for states without a model. Michigan gives false. A state flag is false outside its state, so no other state leaks in.
- Tests at the head.
policyengine-core testongov/hhs/liheapandgov/states/ak/dpa/hap: 177 passed.test_aggregate_list_integrity.py: 42 passed, including the new list-to-payment test. I also merged the head with the open Alaska HAP PR #11229 (it changesak_hap_base_benefit). The Alaska and LIHEAP tests pass on that merge (187 passed). - Hand-computed cases (2026, one adult, $15,000 of wages, $1,800 of electricity, $600 of gas, cooling expense), in one vectorized simulation:
- Alabama with electric heat: both Alabama flags true,
liheap_eligibletrue,liheap$1,020. - Texas with electric heat: true, $1,200.
- Georgia with no fuel: heating flag false, cooling flag true, so
liheap_eligibletrue andliheap$400. - Michigan with gas heat: false, $0.
- Alaska with no place code:
ak_hap$0 andak_hap_eligiblefalse. - West Virginia with no fuel: true with a $0 payment (Suggestion 1).
- California with electric heat: true, $484.
- Alabama with electric heat: both Alabama flags true,
- Format and changelog.
ruff format --checkandruff checkpass on the three changed Python files. The fragmentchangelog.d/liheap-eligible.added.mdis top level and the type is valid. - CI. All 40 checks pass, including Microsimulation, Household API Partners and all baseline and contrib shards.
- Overlap. Open PRs #11229 (Alaska HAP) and #11235 (Hawaii LIHEAP) touch related files. Neither conflicts textually. #11229 passes the new tests when merged (see above).
- Partner tests. No file under
tests/policy/baseline/partners/changes.
Not verified
- I did not run a microsimulation. CI runs one and passes. In the current data,
heating_typeis unset, so this output is false for most records outside the cooling states. The documentation says so. - I did not check each state's eligibility variable against its own state rules. This PR only aggregates them.
- I did not check the HHS LIHEAP guidance documents. The statute is enough for the one reference that this PR adds.
This was referenced Nov 24, 2026
This branch has not been deployed
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.
Adds
liheap_eligible, a national output that is true when a household is eligible for its state's regular LIHEAP heating or cooling benefit, andak_hap_eligiblefor Alaska.Closes #11114
What and why
liheapgives the national payment total, but a caller who wants eligibility has to know each state's variable name.liheap_eligiblereads a list of state eligibility variables, asliheapreads its list of payments.gov.hhs.liheap.regular_eligibility: 61 state eligibility variables. Each is a yes/no output on the SPM unit.liheap_eligible(SPM unit, yes/no, year): true when any listed variable is true. It usesaddson the list, asliheapdoes.ak_hap_eligible: Alaska had no eligibility output.No existing output changes.
The issue's four points
ak_hap_eligible, true whenak_hapis above $0liheapleaves it outil_liheap_eligibleis the regular heating flagheating_typeunsetheating_typeis a required input; #9754 tracks the defaultAlaska follows the award, not the base benefit
Alaska's award function applies every condition of 7 AAC 44. It tests the 2.0-point minimum of 44.080(m) after the dwelling share (h) and the utility-allowance reduction (l). A household can therefore have a positive
ak_hap_base_benefitand no award, so the flag isak_hap > 0.ak_hap_eligible.yamlCase 2 pins this: a subsidized Juneau household has a $525 base benefit, a $0 award, and is not eligible.Three choices in the list
ca_liheap_basic_eligible. Each of its three payments requires it.wv_lieap_income_eligible, its only eligibility output.de_liheap_cooling_eligiblealthoughliheapsums no Delaware cooling payment, because that benefit has no fixed amount.Eligible does not mean a payment above $0
Every payment in
liheapis gated by a variable on the list, so a household with a payment is always eligible. The reverse does not hold. The flag follows each state's own variable and can be true whileliheapis $0:The variable's documentation says so.
Tests
liheap_eligible.yaml, four cases: a Texas household within 150% of the poverty guideline (true); the same household over the limit (false); Delaware cooling eligibility alone, withliheap$0 (true); a Michigan household eligible for the Home Heating Credit (false).ak_hap_eligible.yaml, two cases: a Fairbanks household with a $1,925 award (true); the Juneau household above (false). Both reuse the inputs of existingak_hap.yamlcases.test_aggregate_list_integrity.py: the new list joinsAGGREGATE_LISTS, so the three existing list checks cover it (members are defined variables, members are state-gated, no silent removals between year blocks). One new test,test_liheap_eligibility_lists_the_flag_of_every_listed_payment, fails when a payment joinsgov.hhs.liheap.regular_paymentswithout its eligibility flag joining the new list. YAML cannot compare two parameter lists. The test reuses the module'svariablesfixture and builds no model or simulation.Test plan
make format:ruff format --checkandruff checkpass on the changed Python files (ruff 0.15.5).changelog.d/tests/policy/baseline/partners/changes.axiom: n/a: adds two outputs derived from existing variables; no rule, parameter value or existing result changes
🤖 Generated with Claude Code