Repository navigation
Repay post-2006 Direct Consolidation Loans over the 10-to-30-year standard term - #11696
Conversation
…ndard term Add federal_student_loan_is_consolidated, a Person YEAR input that marks federal_student_loan_balance as a Direct Consolidation Loan that entered repayment on or after July 1, 2006. For flagged borrowers, standard_repayment_payment uses the 34 CFR 685.208(b)(2)(iii) term scale, keyed to the consolidation loan plus the borrower's other education loans counted up to the consolidation loan's amount (685.220(i)(2)(ii), (i)(3)(i)), through a helper shared with consolidated parent PLUS loans. combined_standard_repayment_payment applies one minimum where both balances are under the same paragraph of 685.208(b) and two where they are not. The income-driven repayment cap stays on the 10-year plan (685.209(f)(2)(ii), (f)(3)(ii)). Fixes #10485. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #11696 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 1 6 +5
Lines 24 110 +86
=========================================
+ Hits 24 110 +86
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
hua7450
left a comment
There was a problem hiding this comment.
Thanks, David. The term schedule matches 34 CFR 685.208(b)(2) and 685.220(i):
- 10 to 30 years, set by the consolidation loan plus the borrower's other education loans, which count up to the consolidation loan's amount;
- consolidation loans that entered repayment before July 1, 2006 stay on 10 years;
- before July 1, 2026 the same rules sat at 685.208(c) and (j), and a consolidation loan made from that date is a new Direct Loan, so the existing new-loan flag rightly wins;
- the income-driven cap stays on 10 years, as 685.209(f)(2)(ii) and (f)(3)(ii) say.
All four flag combinations in the combined payment give the expected minimums, a zero balance never adds a second $50 minimum, and the new expected values check out by hand. The candidates.yaml edit follows the existing ruled per-plan reading. Approving.
Optional:
-
Property test (worth doing here).
tests/test_combined_standard_repayment_property.pystill states the old rule and never setsfederal_student_loan_is_consolidated. At 6% with a $30,000 Direct balance and a $3,000 parent PLUS balance:- both flagged: the combined payment is 248.24, not the D + P = 264.93 its invariant 2 predicts;
- only the Direct loan flagged: it is 264.93, not invariant 5's 366.37.
It passes only because the flag stays false. Drawing the flag in the generator and restating invariants 2 and 5 by plan would keep it a real check of this rule.
-
Help text.
federal_ffel_loan_balance(lines 15-17) still says the FFEL balance sets only a consolidated parent PLUS loan's term, andfederal_parent_plus_loan_balancedoesn't say it now sets a consolidated Direct loan's term. The header ofstandard_repayment_payment.yamlstill says 10 years only, and the documentation incombined_standard_repayment_payment.py(lines 28-29) breaks off after "FFEL loans are not". -
Pre-July 2026 citation. Before the 2026 restructuring, this minimum sat at 685.208(c)(2): "A borrower's payments under this repayment plan are at least $50 per month". Adding "(c)(2)" to the title of the existing historical reference in
minimum_payment.yamlwould cover 2016-2025. The value is right. -
Other education loans. The regulation also counts Perkins and FFEL parent PLUS loans. The model has no inputs for them, so the PR body's not-modeled list could name them next to private loans.
-
Repeated case. Case 9 in
standard_repayment_payment.yamlgives the same 333.06 as Case 1 from the same inputs. It can go, or its point (a pre-July 2006 consolidation loan stays on 10 years) can move into Case 1's name.
Fixes #10485
What was wrong
standard_repayment_paymentamortized everyfederal_student_loan_balanceover the 10-year standard plan. Under 34 CFR 685.208(b)(1), the 10-year plan covers Direct Consolidation Loans only if they entered repayment before July 1, 2006. A consolidation loan that entered repayment on or after that date repays under 685.208(b)(2) (685.208(c) and (j) before July 1, 2026). Its term runs 10 to 30 years, set by the total of the consolidation loan and the borrower's other education loans. Those other loans count only up to the consolidation loan's amount (685.220(i)(2)(ii), (i)(3)(i)). #10415 added that scale (standard_repayment.consolidation_repayment_period), but only consolidated parent PLUS loans used it.At 6% with no other loans, main gives $333.06, $555.10 and $888.16 for $30,000, $50,000 and $80,000. The 20-, 25- and 30-year terms give $214.93, $322.15 and $479.64.
What changes
federal_student_loan_is_consolidated(Person, YEAR, bool, default false). It marksfederal_student_loan_balanceas a Direct Consolidation Loan that entered repayment from July 1, 2006 through June 30, 2026 and did not repay parent PLUS loans. A consolidation loan made on or after July 1, 2026 is a new Direct Loan, sohas_federal_student_loan_made_on_or_after_2026_07_01already moves that borrower to the tiered plan. Pre-July 2006 consolidation loans stay unflagged and repay over 10 years.student_loan_amortization_helpers.py: a newstandard_repayment_periodhelper holds the 685.208(b)(2)(iii) / 685.220(i)(3)(i) logic. Bothdirect_standard_amortized_paymentandparent_plus_standard_amortized_paymentnow call it. For a flagged Direct balance, the other education loans arefederal_parent_plus_loan_balanceplusfederal_ffel_loan_balance. This mirrors the parent PLUS helper, which counts the Direct and FFEL balances. The parent PLUS result is unchanged.combined_standard_repayment_payment: before this PR, the two separate payments were added (two minimums) whenever the parent PLUS loan was consolidated. Now that happens when exactly one of the two balances is a post-2006 consolidation loan, so the borrower's loans fall under two plans. Where both are, both loans fall under (b)(2), and the two level payments share one (b)(2)(ii) minimum, just as two (b)(1) loans share one. Theus:standard-plan-minimum-consolidatednote insource_conflicts/candidates.yamlnow describes this rule. It follows the per-plan reading that entry already ruled, so it adds no new reading and no marker.income_driven_repayment_standard_paymentstays on the 10-year term for flagged borrowers. 685.209(f)(2)(ii) and (f)(3)(ii) cap IBR and PAYE payments at what the borrower "would have paid on a 10-year standard repayment plan". That variable never called the Direct helper, so only its documentation changes.minimum_payment.yaml: the first reference title now cites (b)(2)(ii) next to (b)(1)(ii), since the same $50 applies to (b)(2) loans. The value and href are unchanged.Who is affected
The change only affects households that set
federal_student_loan_is_consolidatedto true. No dataset supplies it, and its default is false, so microsimulation results don't change. Household calculations that set it get the consolidation term. For example, a $30,000 consolidation loan at 6% pays $214.93 a month instead of $333.06.Tests
All new cases are appended. No existing expected value changes (6 added, 0 changed).
standard_repayment_payment.yamlCase 8combined_standard_repayment_payment.yamlCase 9Every expected value was worked out by hand from the formula balance × i / (1 − (1 + i)^−n). The YAML comments show the arithmetic. All 6 new cases fail on main (
50af7fba69) because the input doesn't exist there. The "Main" column comes from running the same households on main without the flag. Cases 9, 10 ($5,000 and $3,000) and the IDR column give the same values on both, as they should. Those cases pin the 10-year results that must not move.Local runs on the branch, one process at a time (policyengine-core 3.37.2):
tests/policy/baseline/gov/ed/student_loans/standard_repayment: 43/43tests/policy/baseline/gov/ed/student_loans(integration plus the IBR, ICR, IDR, PAYE, RAP and SAVE folders): 174/174test_combined_standard_repayment_property.py,code_health/test_source_conflicts.py,test_parameter_yaml_keys.py,test_reference_urls.py,test_known_dead_reference_urls.py,test_no_concatenated_reference_urls.py: 407/407.test_source_conflicts.pywas re-run after the candidate edit: 251/251.test_parameter_files.py,test_parameter_scale_thresholds.py,test_student_loan_idr_cap_order_property.py: 37/37No partner test reads any changed variable. Ruff format and check are clean.
Not in this PR
federal_student_loan_balance, so a borrower who holds both a consolidation loan and unconsolidated Direct Loans isn't split between the two plans. The SCF has neither the flag nor a split.standard_repaymententry inprograms.yaml, which Add IBR, PAYE, ICR, SAVE (counterfactual) and standard repayment plan payments #9720's triage suggested. I left it out because Compute student loan payments for tax-dependent borrowers from their own income #10803 edits that file.income_driven_repayment_balance_share,integration.yamlandprograms.yaml. This PR edits none of those files. Onincome_driven_repayment_standard_payment.pyit changes only the docstring, a file Compute student loan payments for tax-dependent borrowers from their own income #10803 doesn't touch. I appended the IDR assertion tostandard_repayment_payment.yamlrather than Compute student loan payments for tax-dependent borrowers from their own income #10803'sincome_driven_repayment_standard_payment.yaml. No other open PR touchesed/student_loans.axiom: TheAxiomFoundation/rulespec-us#1711 queued
🤖 Generated with Claude Code