Repository navigation
Apply Iowa, Kansas, Louisiana and Maryland rules for a filer who can be claimed as a dependent - #10045
Apply Iowa, Kansas, Louisiana and Maryland rules for a filer who can be claimed as a dependent#10045MaxGhenis wants to merge 48 commits into
Conversation
The federal standard deduction and 17 state formulas read only whether the tax-unit head is claimed elsewhere, so a joint return where one spouse can be claimed was taxed differently depending on which spouse was labelled head. Each formula now applies its jurisdiction's rule for that case (either spouse, single filers only, per spouse, or only when every filer is claimed), using two new label-independent helpers. Adds swap-pair YAML cases and a Hypothesis property test. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… barred The New Mexico, Maine and Hawaii renters gates counted filers who are not claimed elsewhere, so a tax unit with neither a head nor a spouse (252 in the default dataset) looked like one whose every filer was claimed. A new helper, every_filer_is_dependent_elsewhere, requires a claimed filer and no unclaimed one. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ss EITC - Hawaii's dependent standard deduction uses earned income net of the deductible part of self-employment tax, as the N-11 worksheet does. - New Mexico's medical care credit needs a filer who is both 65 or older and not a dependent when a filer is a dependent elsewhere (NMSA 7-2-18.13). - The federal EITC without a qualifying child requires that no filer can be claimed as a dependent (IRC 32(c)(1)(A)(ii)(III), Publication 596), so Missouri's working family credit no longer reaches such a couple. - Hawaii's food/excise credit keeps minor children receiving public support (HRS 235-55.85(c)) on a joint return where one spouse can be claimed. - Comments label the readings the law does not settle, and the property test covers the EITC and the food/excise exemption amount. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… meaning - The federal and Oregon dependent worksheets use earned income net of the deductible part of self-employment tax, as Hawaii's now does. - Hawaii's food/excise minor-child count excludes children who can be claimed by another taxpayer and the filers themselves (Form N-311 line 3). - claimed_as_dependent_on_another_return documents what it stands for: a §151 deduction for the person is allowable to another taxpayer, so a person whose would-be claimer files only for a refund is not one (Publications 501 and 596); rules on actually being claimed read it too. - Hawaii's renters comment labels the mixed joint reading as an inference; the Hawaii dependent threshold cites HRS 235-2.4(a)(3) on its page. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A filer who can be claimed on another return is treated as having no dependents (IRC 152(b)(1); on a joint return either spouse counts) and has no personal exemption (IRC 151(d)(2)); one who is claimed gets no education credits (25A(g)(3)), student loan interest deduction (221(c)) or recovery rebate (6428(d)(2), 6428A(d)(2), 6428B(c)(2)). The model read none of these. Now the child tax credit and credit for other dependents, the under-13 child and dependent care qualifying person, exemptions_count and its RI, DE, OH, OR, WI, HI and NM readers, the recovery rebates, the education credits and the student loan interest deduction apply them symmetrically for joint returns. Georgia keeps its own counts; the HI, WI and Treasury exemption reforms follow the corrected count. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…endent
A return on which the filer (or, if joint, either spouse) can be claimed as a
dependent has no dependents (IRC 152(b)(1)), and these states never applied
that or their own rules for such a filer. Now:
- Iowa: no $40 dependent credits (the personal credits stay, "even if you are
claimed"); a claimed single filer is exempt from tax only with income below
$5,000, a joint return with a claimed spouse is not exempt, and the single
tax reduction worksheet excludes a claimed filer.
- Kansas: a claimed filer has no exemptions in 2021-2023 ("enter '0' in the
Total Kansas exemptions box"); from 2024 the filing-status allowance stays
and dependents are zero; the food sales tax credit counts exemptions the
same way and has no child route.
- Louisiana: no dependent exemption (2021-2024).
- Maryland: no own exemption for a filer who can be claimed (filing status 6)
and no dependent or aged-dependent exemptions; no child tax credit; no
childless EITC on the pro forma federal credit without the minimum age; the
poverty line credit is barred for a claimable filer and, on a joint return,
kept for the other spouse on that spouse's earnings with the poverty level
for the exemptions that spouse may claim (10-709(a)(2)).
The Iowa, Kansas and Maryland dependent-exemption contrib reforms and the
state dependent exemption repeal keep these rules.
Kentucky needs no change: its care and tuition credits read the federal
credits the base branch already corrects; YAML cases pin that.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Tax-General 10-211(c) limits "the amount allowed for each exemption under subsection (b)(1) or (2)" once federal AGI exceeds $100,000 ($150,000 joint, head of household or surviving spouse), and the Resident Booklet's chart says "This reduction applies to the additional dependency exemptions as well". The aged dependent exemption ((b)(2)) was a flat $3,200 at any income; it now takes the same per-exemption amount as the personal exemption. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Child and dependent care: childcare expenses do not count on a return with a claimable filer unless a child under 13 still qualifies (IRC 21(b)(2)(A)(ii)). - Tuition and fees deduction: not allowed to a filer who can be claimed (IRC 222(c)(3)), so the education credit bar no longer makes such a filer eligible. - Recovery rebates: the Armed Forces exception waives the identification rule only, not the exclusion of a spouse who is another taxpayer's dependent. - Georgia: the contributed refundable credit and SB 520 reforms count the same children as ga_ctc_potential through a new ga_ctc_eligible_child. - Education credits and student loan interest read the claimed input directly, since IRC 25A(g)(3) and 221(c) turn on an actual claim. - One reference per source document; quote IRC 24(h)(4)(A) exactly. - Tests: mixed-recipient care, tuition deduction, military rebates, Georgia refund cap, and the swapped New Mexico rebate case; the property test now covers the state readers of the exemption count. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts: # policyengine_us/tests/policy/baseline/gov/states/oh/tax/income/exemptions/personal/oh_personal_exemptions_eligible.yaml
#10024 now separates three facts: is claimed, can be claimed, and the would-be claimant's filing exception. - IRC 152(b)(1) gates (child tax credit, credit for other dependents, under-13 care child and its expenses, dependents in exemptions_count, ARPA dependents, Ohio dependents, the Hawaii and Wisconsin reforms) read head_or_spouse_is_dependent_elsewhere_without_filing_exception, so a filer within the Publication 501 exception keeps their dependents. - Own exemptions, recovery rebates and the tuition deduction read claimability. - Education credits and student loan interest keep reading the claimed input. - Tests: the filing exception and a filer who can be claimed but is not. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
#10024's food/excise credit, Act 115 rebate and renters credit took claimable filers off exemptions_count themselves. exemptions_count now leaves them out (and, outside the filing exception, the return's dependents), so those credits read it as it is; the filing-exception cases were one exemption short. The renters credit also leaves out a dependent who can be claimed by another taxpayer (Schedule X counts only people who cannot be), as the food/excise credit already did. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Education credits: a dependent student is not eligible on a return whose filer can be claimed outside the filing exception (IRC 25A(f)(1)(A)(iii), 152(b)(1)); the filer's own eligibility still turns on an actual claim. - Recovery rebates: no credit when every filer is a dependent of another taxpayer (IRC 6428B(a)); the CARES and CAA child prerequisite is a spouse with a valid SSN, whether or not that spouse is an eligible individual. - Child and dependent care: cdcc_qualifying_childcare_expenses holds the expense rule, and the single-parent work requirement reform and California's expenses read it. - References: Georgia HB 136 page 3; one entry per recovery rebate statute; quote IRC 24(h)(4)(A) exactly in the test comment. - Tests: dependent students, the two rebate cases, the reform and California expenses, and the Hawaii, Wisconsin and Treasury reforms with a claimable filer under both labellings. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Education credits: is_barred_from_education_credits_by_dependency holds the claimed-filer and dependent-student rules; both eligibility formulas and the reconciliation SSN reform's Lifetime Learning Credit read it, so the reform no longer turns a barred student's tuition into that credit. - Child and dependent care: childcare counts when any child under 18 is still a qualifying individual, so an incapacitated child aged 13 to 17 keeps it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Setting meets_eitc_identification_requirements on one person made it an input for every person, so the other spouse lost their SSN too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…claimable-filer-ia-ks-ky-la-md
#10024 now separates claimability (`claimable_as_dependent_on_another_return`) from an actual claim (`claimed_as_dependent_on_another_return`) and adds the claimant filing exception. Each rule now reads the fact its law names: - IRC 152(b)(1) "no dependents" rules (Iowa dependent credit, Kansas dependents and food sales tax credit child, Louisiana dependent exemption, Maryland dependents, aged dependents and CTC, and the childless pro forma EITC) read `head_or_spouse_is_dependent_elsewhere_without_filing_exception`, as the federal formulas do. - Rules whose text says "claimed" read the claim: Iowa's low-income exemption and tax reduction ("not claimed as a dependent on another person's Iowa return") and Kansas's 2021-2023 zero exemptions ("If you are claimed as a dependent"). - Maryland's filing status 6 ("Any person who can be claimed") keeps reading claimability for the own exemption and the poverty line credit. Maryland now counts its own exemptions in `md_personal_exemptions_count` instead of reading federal `exemptions_count`, so a federal-only reform of that count no longer changes Maryland's exemptions (review r1 finding 1). The changelog names the aged dependent AGI limit (r1 finding 2). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
YAML cases for a filer who can be claimed but is not claimed (Iowa exemption and tax reduction, Kansas 2021-2023 exemptions) and for a claimant who meets the filing exception (Iowa dependent credit, Kansas 2024 dependent exemption, Louisiana dependent exemption, Maryland exemption count, CTC and pro forma EITC, and the poverty line credit, which the exception does not restore). New md_personal_exemptions_count.yaml. The property test now draws claimable, claimed and filing-exception patterns, checks the unchanged-when-nobody-is-claimable identities (review r1 finding 3) and adds a filing-exception scope test. Also: the 2021 Iowa exemption anchor is page 38, not 37; Louisiana's 2023 instructions are cited; 422.13(1)(a) is labelled as the filing requirement. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Tax-General 10-709(a)(2) keys the applicable poverty income level to the exemptions the individual "is allowed and claims", and HHS lists guideline amounts only from one person up. The level formula fed a zero exemption count to fpg and got a negative-person extrapolation ($10,150 in 2025), so a claimable single filer earning up to that amount passed (a)(3)(i) and (ii). Return 0 at zero exemptions and require a positive count for eligibility; a claimable filer whose dependent the claimant filing exception allows keeps a level and faces only the (a)(3)(iii) actual-claim test. Restore main's md_poverty_line_credit_earned_income.yaml, which this PR had deleted, so main keeps its 12 regression cases, and re-add round 2's two pretax-contribution cases with only eitc_earned_income, eligibility and credit outputs. Supply one exemption alongside the 15,650 level in the (iii) witnesses and say both are supplied to isolate that test. Restore the "every filer claimable and no exemption allowed: no credit" identity in the property test. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Ready for hub review Round 4 fixes for the review at Items1. Pick-up and merge. Posted the pick-up comment. Merged 2. P2-1: main's test file restored.
3. P2-2: no poverty level at zero exemptions.
Hand values:
This filing-exception case is built the same way as 4. P3-2: witness wording. In 5. P1-1 / P2-3: body. I made every replacement as given: the Microsimulation impact paragraph, the "Poverty line credit" bullet under Maryland's separate returns, invariants 2 (phrase, list item, deleted paragraph), 3, 5 and 6, the reading 11 addition, and the r1 response 3 marker. Other sentences these changes made false, also fixed:
Tests at
|
| File | Result |
|---|---|
.../md/.../poverty_line/is_eligible_md_poverty_line_credit.yaml |
12 passed |
.../md/.../poverty_line/md_poverty_line_credit_earned_income.yaml (main's 12 + 2) |
14 passed |
.../md/.../poverty_line/md_poverty_line_credit_income_level.yaml |
2 passed |
.../md/tax/income/exemptions/md_personal_exemptions_count.yaml |
8 passed |
core/test_claimable_filer_ia_ks_ky_la_md_invariants.py |
6 passed |
test_md_poverty_line_credit_invariants.py |
16 passed |
code_health/test_source_conflicts.py |
103 passed |
| Total | 36 YAML + 125 Python passed, 0 failed |
The Python dependencies came from uv sync --extra dev. ruff format --check and ruff check pass on the three changed Python files. I ran no full suites and no microsimulations.
Mutants (each in its own process, code restored after each and checked with git diff --stat)
| Mutant | Result |
|---|---|
A: level back to fpg(md_personal_exemptions_count, ...) at zero (gate kept) |
Killed by is_eligible_md_poverty_line_credit.yaml:188 "2025 claimable but unclaimed single filer at 10,000 …" and :157 (12,000): level 10,150 ≠ 0. 2 failed, 9 passed |
| B: A plus the count gate removed (the head's behaviour) | Killed by the same two cases (2 failed, 9 passed). A direct calculation shows the 10,000 filer eligible with potential 500, and the 12,000 filer ineligible |
| C: count gate removed, zero level kept | First survived (with a level of 0, any positive AGI already fails (i)). I added line 219 (zero income, 100 tax); it is now killed (1 failed, 11 passed) |
test_claimable_filer_ia_ks_ky_la_md_invariants.py still passes 6 under mutant B, so the restored invariant 3 assertion is sound but doesn't kill B. Its drawn and seeded units don't reach a zero-exemption filer whose income is at most 10,150 and whose Maryland tax is above the EITC. The YAML cases are what kill B.
CI
Pull request run 41854527358 at c9e4bf30f8: still in progress at 16:08Z, 60 minutes after the push (started 15:07Z). So far 27 of 36 jobs have passed and none has failed. The passed jobs include Household API Partners, all four Baseline states shards and every other Baseline shard (household, reform, contrib-hhs, irs, ssa-usda, rest-a, rest-b), and the 11 other Python test jobs. Still running: Microsimulation and eight Contrib shards (states 1-4, congress, other-1, other-2b, other-3). Per the brief, I'm handing off with the run URL rather than waiting longer.
Judgment calls
- Supplying
md_personal_exemptions_count: 1in the three (iii) witnesses (item 4 above). - Re-adding only the pretax pair, trimmed, and not the $500/$500 mixed-spouse pair (item 2 above).
- Adding the zero-income case at line 219, to kill mutant C.
- Marking r1 response 6 and the follow-up's item 6 as superseded, in addition to the three P2-3 sentences.
- Invariant 5's microsimulation-exception sentence now names the Kansas head-of-household change.
What I couldn't check
- The 2025 Resident Booklet.
marylandcomptroller.govandweb.archive.orgwere both refused (proxy 403), so I haven't read the p.23 filing status 6 sentence myself. The code comments paraphrase it without quoting, and the body's reading 11 addition is the brief's text. - The 10-709 statute text (not fetched this session; the quotes are the existing code's and the brief's).
- Population impact, including the 2023 Kansas head-of-household run. Left for the hub, as are the
impact:andaxiom:lines.
Proposed follow-up
Add a zero-exemption Maryland unit to the claimable-filer property generator. Seed a claimable single filer with income below 10,150 and positive Maryland tax, so that invariant 3's new assertion can fail on its own. Today only the YAML cases kill the zero-person extrapolation.
Generated by Claude Code
|
Hub review in progress Superseded by the final round 5 review: #10045 (comment) Generated by Claude Code |
|
Ready for hub review This is a round 5 delta review of
Every round 4 item is fixed as the brief specified. CI is green, and nothing I found is a wrong result or a false claim a reader would rely on. What remains: no test pins the decisive case for reading 11 (P2-1). The test my own mutant passes shows this. METHODOLOGY_CHOICE is yes:
P2P2-1. No test pins reading 11's mixed-spouse level. A mutant that switches to the person-count alternative passes every test. Reading 11 says that for a 2025 joint return with one claimable spouse, "PR counts 1 allowed exemption and uses $15,650; person-count alternative counts 2 and uses $21,150. At $18,000 … the PR income test fails". The code does this. My witness at the head:
At main, the same household is eligible for $900: two persons, $21,150, and min($1,000, 5% × $18,000). Round 2's pretax pair asserted Mutant E (mine) uses
My witness file fails it: 3 failed, 1 passed. Fix: add these cases to - name: 2025 joint return with one claimable spouse uses one allowed exemption's level and fails at 18,000
period: 2025
input:
people:
a: {age: 30, is_tax_unit_head: true, claimable_as_dependent_on_another_return: true}
b: {age: 30, is_tax_unit_spouse: true, employment_income: 18_000}
tax_units:
tax_unit: {members: [a, b], filing_status: JOINT, md_income_tax_before_credits: 1_000, md_married_or_has_child_non_refundable_eitc: 0}
households:
household: {members: [a, b], state_code: MD}
output:
# Tax-General 10-709(a)(2): one allowed exemption (the unclaimable spouse),
# so 15,650, not the two-person 21,150. 18,000 > 15,650.
md_personal_exemptions_count: 1
md_poverty_line_credit_income_level: 15_650
is_eligible_md_poverty_line_credit: false
md_poverty_line_credit_potential: 0
# (plus the same case with the head and spouse labels swapped)
- name: 2025 joint return with both spouses claimable and no filing exception has no level and no credit
period: 2025
input:
people:
a: {age: 30, is_tax_unit_head: true, claimable_as_dependent_on_another_return: true, employment_income: 500}
b: {age: 30, is_tax_unit_spouse: true, claimable_as_dependent_on_another_return: true, employment_income: 500}
tax_units:
tax_unit: {members: [a, b], filing_status: JOINT, md_income_tax_before_credits: 200, md_married_or_has_child_non_refundable_eitc: 0}
households:
household: {members: [a, b], state_code: MD}
output:
md_personal_exemptions_count: 0
md_poverty_line_credit_income_level: 0
is_eligible_md_poverty_line_credit: false
md_poverty_line_credit_potential: 0
- name: 2025 joint return with both spouses claimable and the filing exception keeps the child's level
period: 2025
input:
people:
a: {age: 30, is_tax_unit_head: true, claimable_as_dependent_on_another_return: true, dependent_claimant_filing_exception: true, employment_income: 500}
b: {age: 30, is_tax_unit_spouse: true, claimable_as_dependent_on_another_return: true, dependent_claimant_filing_exception: true, employment_income: 500}
c: {age: 4, is_tax_unit_dependent: true}
tax_units:
tax_unit: {members: [a, b, c], filing_status: JOINT, md_income_tax_before_credits: 200, md_married_or_has_child_non_refundable_eitc: 0}
households:
household: {members: [a, b, c], state_code: MD}
output:
# 0 own + 1 child = 1 exemption: 15,650. min(200, 5% x 1,000) = 50.
md_personal_exemptions_count: 1
md_poverty_line_credit_income_level: 15_650
is_eligible_md_poverty_line_credit: true
md_poverty_line_credit_potential: 50A smaller alternative is to restore P3P3-1. A stale status sentence in the body. Under "Statute-first changes", the paragraph that begins "Merged current main at P3-2. A code comment reads as agreement with the booklet where the code departs from it. Note for the hub: this departure from the booklet, and the (iii) one, carry no P3-3. Hand-off counts. The hand-off says mutants A and B fail "2 failed, 9 passed". That was before line 219 was added. At this head each fails 3 of 12 (below). Also, the body's r1 response 3 has a capitalisation slip: "…equals P3-4. No Checked and soundMain's test file (round 4 P2-1).
Untested since round 2:
The zero-exemption gate (
The brief's reading as quoted is "the amount … that corresponds to the number of exemptions which the individual is allowed and claims". The code matches it in every year (the level reads that year's The five new cases, by hand from the repository's 2025 contiguous guideline (15,650 first person, 5,500 each additional) and the 5% share:
All five match the file, and the file passes at the head (12 passed). The witnesses (lines 59, 90, 121).
Mutants. Each ran in its own process in a scratch worktree, which was restored afterwards (
The defect at main. Main's
At the head these are 0/ineligible and 15,650/ineligible. Readers.
Readers this round makes reachable and worse: none. The change only removes credit from filers with no allowed exemption, who are claimable. Baseline.
Body. Each replacement the brief listed is present verbatim:
The extra edits are accurate against the code:
Invariant 3's new sentence matches the restored assertion ( Tests at the head, one file per process:
That's 51 YAML + 125 Python passed, 0 failed. CI. Pull request run 41854527358 at Scope. Nothing changes under
What I couldn't check
Generated by Claude Code |
No case tested a joint return with one or both spouses claimable, so a person-count level (21,150 rather than one allowed exemption's 15,650) passed every test. Four cases cover a claimable head, a claimable spouse, both claimable without the filing exception, and both with it. The booklet comment now says the model follows the booklet's status 6 bar only when the return has no allowed exemption. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LwQq6K4hbmpvP2YevFmELw
|
Picking this up for the US hub. I'll post a hand-off comment here when it's ready. Generated by Claude Code |
|
Ready for hub review Head: This round builds on Items
Commit Tests at the head (one file per process)
I ran the first five and the two named Python files before the comment edit. After it, I reran Mutant
Hand computations (2025: first person 15,650, each additional 5,500)
CIPull request run 41948195035 at Judgment calls
What I couldn't check
Generated by Claude Code |
PR Review: Apply Iowa, Kansas, Louisiana and Maryland rules for a filer who can be claimed as a dependentSummaryI read the statutes and the claimed years' instructions first, then the code. The PR uses only existing dependency variables:
The new inputs (the Iowa claimant's income and filing status, and an actual claim on another Maryland return) hold facts that no existing variable carries, so nothing is reinvented. These changes match the governing text for the claimed years:
CI is 36/36 green at the head. One critical item and four should items are open:
The branch also conflicts with current main in one test file. Critical (must fix)C1. Maryland: a claimable filer loses the own exemption that Tax-General 10-211(a)(1) allows, and with it the poverty line credit (
Should addressS1. Maryland CTC: the gate in
S2. Update the existing CONTRIBUTING.md#source-conflicts, step 1: "If the backlog already lists the conflict, it updates that item instead." Nine items on main name this PR, and eight still describe main:
Fix: in this PR, set S3. Kansas 2021–2023 head of household: the PR follows the statute against the K-40 instructions but doesn't record the conflict (
S4. The
Suggestions
Verified correctThe law, read first.
The code.
Axiom line assessmentThe line lists eight queued issues and three
CI status
Branch status
Verdict: REQUEST_CHANGES |
DTrim99
left a comment
There was a problem hiding this comment.
Requesting changes per the review above: 1 critical (MD personal exemption count drops a claimable filer's own exemption, which Tax-General 10-211(a)(1) has allowed unconditionally since 2018; main was right), 4 should (unpinned MD CTC gate for 2021-24; 8 stale candidates; unrecorded KS 2021-23 head-of-household choice; stale axiom issues and invalid n/a items), 7 suggestions.
|
Picking this up for the US hub. I'll post a hand-off comment here when it's ready. Generated by Claude Code |
Main's #10053 and this branch both appended cases to the state dependent exemption repeal test. Keep both: main's three California cases first, then this branch's Maryland and Kansas cases, so the branch's diff against main stays a pure append. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…1(a)(1) Section 10-211(a)(1) allows an exemption for "the taxpayer" with no dependency condition. 2018 ch. 575 struck (b)(1)'s reference to the exemptions deductible under IRC 151, so 151(d)(2)'s denial for a dependent no longer reaches Maryland. The booklet's filing status 6 still gives a claimable filer none; the statute governs, as main did. The count now takes every member and drops the dependents only when IRC 152(b)(1) leaves the return none, so a claimable single filer keeps one exemption and the one-person poverty level. With every filer counted, the zero-exemption poverty branch can no longer arise, so it goes. The Maryland dependent-exemption and repeal reforms return to main's filer counts. The claim on another Maryland return now defaults to the federal claim, since a Maryland claimant takes an exemption for each IRC 152 dependent; an input of false still covers a claimant who files no Maryland return. The property test's Hypothesis batches always include the couple that had no Maryland exemption (both spouses claimable, no dependents), and its identity now checks that every filer keeps an exemption. A filing-exception case pins the Maryland reform's dependent gate. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…oring gates Before 2025 md_ctc_eligible tests only AGI, so md_ctc's own IRC 152(b)(1) gate is the one that removes a claimable filer's child, and every claimable-filer case was from 2025. Add 2024 and 2022 claimable cases expecting no credit and a 2024 filing-exception control at $500. No case set the claimant filing exception for the Kansas food sales credit, the Maryland aged dependent exemption or the Iowa reform, so swapping their helper for the plain claimability one passed every test. Add one exception case each. Also replace a Kansas food credit comment that still gave the K-40 Line E rationale the formula no longer uses. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… file The six claimable-filer cases sat in a new agi/md_dependent_care_subtraction.yaml beside the existing agi/subtractions/md_dependent_care_subtraction.yaml. Both paths run in the same Maryland shard, so one file keeps the cases together. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CONTRIBUTING's step 1 updates a backlog item that already lists a conflict. Eight items naming this PR still described main: set their follows, code and years to the readings the branch now implements, and refresh their notes. Add two items. us-md:dependent-taxpayer-own-exemption records Tax-General 10-211(a)(1), as amended by 2018 ch. 575, against the booklet's filing status 6. us-ks:2021-2023-head-of-household-exemption records K.S.A. 79-32,121, whose head-of-household allowance was for tax year 1998 only and which 2022 HB 2239 removed, against the 2021-2023 K-40 instructions' extra exemption. The changelog now names that Kansas change and the Maryland own exemption. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…)(i) The comment said section 10-704 waives only the minimum age. For an individual without a qualifying child, (c)(3)(i) waives both the minimum age and the section 32(m) identification limitation. The formula drops only the minimum age and still applies 32(m), and unlike eitc_demographic_eligible from 2021 it counts only children with a valid identification number. Say so; the code is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Ready for hub review Head: This round answers DTrim99's review (review 5813540259, comment 6709676325) at 1. Main
The property file first failed to import because 2. FindingsC1. Maryland own exemption. Reproduced. The reviewer's witness is a 2025 claimable single filer with AGI and earnings of $10,000, $600 of tax, no EITC and no Maryland claim. At
S1. Maryland CTC gate, 2021-2024. Reproduced statically: before 2025 S2. Stale candidates. All eight items now record
S3. Kansas 2021-2023 head of household. Candidate S4. The axiom line. Kept as it was, per the brief. Drafts for the hub are under Axiom drafts. Suggestions.
3. Rulings for the hubThe hub confirms each call before the PR lands.
4. Axiom draftsI can't read the rulespec-us issues from this session (outside its repository access), so these drafts rely on the review's account of them. Module paths are for the hub to confirm on rulespec-us Comment for #1799 (IA1). Re-pin to
Comment for #1800 (KS1). Re-pin to
Comment for #1801 (MD1). Re-pin to
Comments for #1802 (KY1) and #1803 (LA1). Re-pin to #1793. It belongs to #10267 (merged 2026-10-19). Drop it from this PR's axiom line, or relabel it "#10267's Kentucky 2026 reader". New issue: Kansas food sales tax credit, 2021-2024. Title: "KS: count federal exemptions for the food sales tax credit with a claimable filer (K.S.A. 79-32,271(d))".
New issue: Louisiana dependent exemption, 2021-2024. Title: "LA: no dependent exemption on a return with a claimable filer (R.S. 47:294(B), 2021-2024)".
Proposed axiom line, for the hub to finalize with the new issue numbers:
5. MutantsEach mutant ran in its own git worktree at the final head, in its own test process; the main checkout was never edited. M2's first attempt was killed for memory while two other test processes ran, so I reran it alone. M1's first property-test run failed to import
No mutant for the removed zero-exemption branch: restoring it changes no value, since every count is at least 1. The candidate, changelog, comment and file-move changes have no code to mutate; 6. Tests at the final head and CILocal runs at
Wall times include model start-up; some runs overlapped with one other test process. CI. The latest
7. BodyEvery section now describes the final head. The Maryland rows, readings 5-6, 8 and 10-11, the invariants and the tests reflect C1; readings 12 and 13 are new. The Kentucky limitation and its proposed separate PR are gone (Suggestion 3), and CI cost cites run 41948195035 (Suggestion 7). I condensed the validation tables for older heads into a short review history and dropped the internal ids and local paths they carried. The Hand computations2025 Maryland amounts use $3,200 per exemption (AGI at most $100,000) and the contiguous guideline of $15,650 plus $5,500 per extra person.
Judgment calls
Proposed follow-up issues
DISMISSAL MAPPaths are under
Generated by Claude Code |
PolicyEngine follows the statute for Maryland's own exemption (Tax-General 10-211(a)(1), as 2018 ch. 575 amended it) and for Kansas's 2021-2023 head-of-household add-on (K.S.A. 79-32,121 limits it to tax year 1998). Both candidates move from open to ruled. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Summary
Iowa, Kansas, Louisiana and Maryland each have rules for a filer who can be claimed as a dependent on another return that the model never applied. A return on which the filer (or, if joint, either spouse) can be claimed has no dependents unless the would-be claimant meets the filing exception. That is IRC 152(b)(1); Publication 501 says "you and your spouse can't claim any dependents on your joint return". These states also have their own rules for the claimable or claimed filer. This PR applies the ones the federal fixes do not already cover. Each rule is symmetric between head and spouse and reads the fact its law names, using #10024's split inputs:
head_or_spouse_is_dependent_elsewhere_without_filing_exception, as the federal formulas do.claimed_as_dependent_on_another_return). Iowa's also reads the claiming person's income. Maryland's poverty line credit reads a claim on another Maryland return, an input that defaults to the federal claim.It also fixes one related error in the same formulas (last row of the table). Kentucky claimable-filer coverage follows the federal fixes.
Stacked on the federal claimable-filer PR #10087 (
claimable-filer-federal, merged in at 35a2cbc) and on #10024. The 2026-10-09 audit was written before those changes. The rows they already fix are listed below, with the YAML cases that now pin them.ia_exemption_creditia_is_tax_exempt,ia_reduced_tax,ia_alternate_tax_eligible(+ newia_claimed_filer_income_disqualifiedand claimant inputsia_dependent_claimant_net_income,ia_dependent_claimant_spouse_net_income,ia_dependent_claimant_filing_status)ks_count_exemptions(2021-2023)ks_exemptions(2024+)ks_fstc(2021-2024)la_dependents_exemption(2021-2024)md_personal_exemptions_count(new),md_total_personal_exemptionsexemptions_countmd_aged_dependent_exemptionfederal_eitc_without_age_minimumeitc_demographic_eligiblemd_ctc,md_ctc_eligibleis_eligible_md_poverty_line_credit(+ new inputmd_claimed_as_exemption_on_another_return, which defaults toclaimed_as_dependent_on_another_return;md_poverty_line_credit_income_level)eitc_earned_income. The poverty level uses the exemptions the individual "is allowed and claims", which include every filer's ownmd_aged_dependent_exemption(related fix)The Iowa, Kansas and Maryland dependent-exemption contrib reforms and the state dependent exemption repeal keep these rules (YAML cases added). In
repeal_state_dependent_exemptions.pythis PR changes only the Kansas entry; the Maryland entry is main's, which already counts every filer. #10043 and #10044 also edit that file.Audit rows already fixed by #10024 or the federal branch (not changed here)
eitc) and care credit (cdcc_potential). Pinned inia_eitc.yamlandia_cdcc.yaml.eitc) and care credit (cdcc). Pinned inks_total_eitc.yamlandks_cdcc.yaml.pre_obbba_cdccthrough 2025 and, from 2026, the livecdcc(Use the OBBBA federal credit for Kentucky's 2026 dependent care credit #10267). Both use the federal qualifying-expense dependency gates, pinned inky_cdcc_potential.yaml.eitc), refundable and nonrefundable care credits (cdcc_potential,cdcc), and through them the school readiness credit. Pinned inla_eitc.yamlandla_refundable_cdcc.yaml.cdcc), dependent care subtraction (count_cdcc_eligible,cdcc_relevant_expenses) and local EITC (eitc). The subtraction is pinned inagi/subtractions/md_dependent_care_subtraction.yaml.No tax formula in these five states reads raw childcare expenses; the raw-expense readers are the child care assistance and cash assistance programs.
Maryland's separate returns: how far this models them
Maryland requires a married filer who can be claimed to file separate Maryland returns (filing status 6 for that spouse). The model keeps the federal joint tax unit and applies each rule per filer where the rule is per filer:
It does not compute two separate Maryland returns. These still use the joint unit:
A married person can be claimed only if the couple's joint return is "filed only to claim a refund of withheld income tax or estimated tax paid" (Publication 501), so these are low-income couples. From 2025 the two separate flat standard deductions sum to the joint one ($3,350 x 2 = $6,700), but the separate rate schedules can still give a different tax. Computing the two returns needs each spouse's income as on a separate federal return (Instruction 8), a split the Maryland model does not have.
Review r3 (DTrim99, at 0a28338): responses
md_personal_exemptions_countgives every filer an exemption and keeps the 152(b)(1) dependent gate. The zero-exemption poverty branch is gone, and the Maryland reform and repeal return to main's filer counts. Cases re-derived; new candidateus-md:dependent-taxpayer-own-exemption(reading 12)md_ctc.yaml)follows: statute, the deciding files, the years the code applies and a refreshed noteus-ks:2021-2023-head-of-household-exemption(reading 13); the changelog names the changen/aitemsks_fstc,md_aged_dependent_exemptionand the Iowa and Maryland reformscdcc; the Kentucky limitation and proposed separate PR are removedks_fstc.yamlcommentagi/subtractions/md_dependent_care_subtraction.yaml13d4d12de5, keeping both appended blocks inrepeal_state_dependent_exemptions.yamlReadings
This round (2026-11-09)
md_personal_exemptions_countcounts every member and drops dependents only when 152(b)(1) leaves the return none. A claimable single filer has 1 exemption ($3,200) and the $15,650 level (was 0 and no level). A joint return with one claimable spouse has 2 ($6,400) and $21,150 (was 1, $3,200 and $15,650). The zero-exemption poverty branch is gone. Main's results return for these filersmd_claimed_as_exemption_on_another_returndefaults to the federal claim; an input of false still models a claimant who files no Maryland returnStatute-first changes (2026-11-03)
Following the 2026-10-19 rule (statute over forms and instructions; forms fill gaps) and the 2026-10-20 ruling on the food sales credit, that round changed five readings.
ia_alternate_tax_eligiblenow also requires~ia_claimed_filer_income_disqualified. A 2024 joint return with a claimed spouse whose claimant has $9,001 keeps its $500 regular tax instead of $370.50All readings
These preserve the PR's choices. Items 3 and 6 identify missing inputs or return representation rather than discretion to ignore an explicit legal requirement. Amounts below illustrate the rule at issue, before unrelated tax limits unless stated.
Not modeled (listed, not implemented)
Other findings (not fixed here)
federal_eitc_without_age_minimumomits the federal separate-filer and section 911 conditions thateitc_eligibleapplies.federal_eitc_without_age_minimumstill applies § 32(m) to a childless filer, although 10-704(c)(3)(i) waives it and the booklet (p.22) lets an ITIN filer claim the State credit "disregarding the SSN requirement".eitc_demographic_eligiblefrom 2021 (Let a qualifying child without an SSN establish EITC eligibility from 2021 #10583),federal_eitc_without_age_minimum'shas_childcounts only children with a valid identification number, and it compares fractional ages with the age ceiling (Compare completed years in the childless EITC age ceiling #10585).repeal_state_dependent_exemptions, the overrides for other states are left to their own PRs, such as Apply New Jersey, North Dakota, Ohio, Oklahoma and Pennsylvania rules for a filer who can be claimed as a dependent #10043 and Apply the RI, SC, UT, VT, WV and WI rules for a filer who can be claimed as a dependent #10044.Invariants
Swap invariance. Every changed output, and each of the five states' income taxes, is the same under either head/spouse labelling.
Monotonicity. Marking another filer as claimed never raises:
Left out by design:
Identities. With a filer claimable outside the filing exception: no Louisiana dependent exemption, no Maryland aged dependent exemption or CTC, and no pro forma EITC without a child. Every Maryland filer keeps an exemption, so the count covers both spouses and the poverty level is positive.
Differential. Wherever the federal EITC's eligibility holds, Maryland's
federal_eitc_without_age_minimumequals the federal credit before take-up and filing.Unchanged when nobody can be claimed. The Maryland count equals
tax_unit_size. The poverty level equalstax_unit_fpg. The testedla_dependents_exemptionamount is $1,000 per dependent. The hub microsimulation will check the remaining outputs; the exceptions are the aged dependent AGI fix and the 2021-2023 Kansas head-of-household count.Filing-exception scope. The exception never lowers the 152(b)(1) amounts. It does not change Iowa's exemption (an actual-claim rule) or Maryland's poverty line credit exclusion (an actual Maryland claim).
Tests
YAML. Variable-named cases cover every changed formula and the inherited state readers above:
Expected values come from the law and the repository parameters, with the arithmetic in each case's comments.
This round's cases (at
994d9fab52):md_personal_exemptions_count.yaml: every claimable-filer case re-derived under 10-211(a)(1) (single 1, joint 2, joint with the filing exception 3), plus a 2022 claimable single filer (1, $3,200).md_total_personal_exemptions.yaml,dependent_exemption_reform_test.yaml(Maryland) andrepeal_state_dependent_exemptions.yaml: a claimable single filer $3,200; a joint return with a claimable spouse 2 × $3,200 = $6,400.is_eligible_md_poverty_line_credit.yaml: a claimable single filer at $10,000 has 1 exemption, the $15,650 level and a $500 potential credit; at $12,000, $600. A filer claimed federally is claimed in Maryland by default ($0). Joint returns with one or both spouses claimable use $21,150 (credits $900 and $50); with the filing exception and a child, $26,650.md_poverty_line_credit_income_level.yaml: under the federal exemption repeal, a joint return with a claimable spouse, the filing exception and a child counts 3 and uses $26,650.md_ctc.yaml: 2024 and 2022 claimable filers get $0 althoughmd_ctc_eligibleholds; a 2024 filing-exception control gets $500.ks_fstc.yaml($125 for the child),md_aged_dependent_exemption.yaml($3,200), the Iowa reform ($80 + $100 = $180) and the Maryland reform (2 × $3,200 + $1,000 = $7,400).Property test.
policyengine_us/tests/core/test_claimable_filer_ia_ks_ky_la_md_invariants.pychecks invariants 1-6 with Hypothesis (claimable, claimed and filing-exception draws), a seeded population in the five states for 2022, 2024 and 2026, and an exception-scope population for 2022 and 2025. Every Hypothesis batch now also includes the Maryland couple with both spouses claimable and no dependents, which had no Maryland exemption before this round.Results at
994d9fab52, one file per process: 17 files, 320 cases passed, no failures; every file this round changes, plustest_source_conflicts.py,test_md_poverty_line_credit_invariants.pyandfederal_eitc_without_age_minimum.yaml(whose formula's comment changed).CI cost
The property test runs in the existing Rest Python "core-2" group (shard 4). In run 41948195035 at
0a28338641, its six cases took 10.34 s of test time, and the group ran 266 tests in 19:45 wall with 6.45 GiB peak RSS (6,763,476 kB), from the shard's timing and resource artifacts. This round adds one couple to each Hypothesis batch, in the same simulation. It builds no new simulation. I ran the file locally (Linux, 4 vCPU), alone and back to back. At the merged head13d4d12de5it took 102 s wall (33.14 s in pytest) with 2,144 MiB peak RSS; at the final head, 93 s (28.91 s) with 2,140 MiB. The difference is within run-to-run noise. These are local figures, not Linux CI results. In this round's run 42642815203, the planner put the file in group core-1 (shard 4): its six cases took 14.58 s, and that group ran 588 tests in 27:34.30 wall with 7.05 GiB peak RSS. The groups differ between the two runs, so the group figures don't compare directly.Microsimulation impact
impact: pending a comparison at the final head.
We'll run the default dataset for 2023 (Kansas's consolidated regime), 2025 and 2026, comparing this branch with main. If the dataset sets the dependency inputs for nobody, two changes move baseline totals: Maryland's aged dependent exemption gets the federal AGI limit, and each 2021-2023 Kansas head-of-household return loses one $2,250 exemption (reading 13). The Maryland own exemption now matches main. The Maryland claim input defaults to the federal claim input, so any federal claims in the data would also bar the poverty line credit.
axiom: TheAxiomFoundation/rulespec-us#1799 queued (IA: dependent credits, bounded low-income exemption/tax reduction, EITC/CDCC) | TheAxiomFoundation/rulespec-us#1800 queued (KS: 2024-2025 lawful dependent allowance, EITC/CDCC) | K.S.A. 79-32,271 n/a: expired after 2024 and unencoded | Louisiana 2021-2024 dependent exemption n/a: expired and unencoded | TheAxiomFoundation/rulespec-us#1801 queued (MD: exemptions/aged AGI limits, CTC, sourced EITC/poverty/care composition) | TheAxiomFoundation/rulespec-us#1802 queued (KY: 2024 care and tuition composition) | TheAxiomFoundation/rulespec-us#1793 queued (KY: 2026 care conformity) | TheAxiomFoundation/rulespec-us#1803 queued (LA: EITC, ordinary care/school readiness) | TheAxiomFoundation/rulespec-us#1621 queued (federal: childless EITC dependency gate/claimant exception) | TheAxiomFoundation/rulespec-us#1684 queued (federal: lawful dependency stack) | contrib reforms n/a: PE-only reform.
Review history
repeal_dependent_exemptionsreform no longer reaches it. The changelog names the aged-dependent AGI limit. The property test checks the nobody-claimable identities. Iowa wording and anchors, and a Louisiana 2023 reference, were fixed.ks_fstc.yaml, an Iowa page comment and the property-test cost. Its earned-income source change was later reversed (round 4), and Use the OBBBA federal credit for Kentucky's 2026 dependent care credit #10267 fixed Kentucky's 2026 reader.🤖 Generated with Claude Code