Fix/loan payment principal split #4343
All Vouch review confidence checks passed
Residual risk 0.35 = Change Risk (0.66) × (1 − Review Confidence (0.47)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.66 · 383 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.356
Shallow Review Depth
shallow_review_depth
0.344
Sensitive Paths
sensitive_paths
0.066
Real PR Conversation Timeline
1 comments
"Review active on #4343"
general
weight: 0.35
jaysbeekay
Correct loan principal/interest splits and show cumulative paid totals
Summary
Validation
| Check | Result |
| --- | --- |
| Full Rails suite | 12,125 tests, 56,358 assertions, 0 failures/errors |
| RuboCop | 2,987 files, no offenses |
| Brakeman | 0 security warnings |
Notes for reviewers
<img width="2228" height="1967" alt="image" src="https://github.com/user-attachments/assets/0628c5e8-5fcc-4e7a-81fe-2657749e3557" />
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
Summary by CodeRabbit
- Loan repayment progress now shows cumulative principal and interest paid, combined totals, and payment percentages as of the selected date.
- Amortized loan payments now separate principal and interest more accurately, improving balance and repayment calculations.
- Repayment details account for linked payments, prepayments, drawdowns, and variable interest rates.
- Loans without amortization terms retain their existing payment behavior.
- Added English and French labels for paid-to-date repayment details.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->