CLCreditLens
OverviewUnderwritingPortfolioMonitoringFair lendingGovernanceAI assistance

A portfolio project by Siddharth Hiraou. Every figure is generated from the model artifacts in the repository and reproducible with make train. Trained on synthetic data, not a real lender, and no real applicants.

For compliance and legal

Fair lending

Whether the model approves protected groups at similar rates, measured and not asserted. This one does not pass on age, and that is stated here rather than buried.

The question this page answers

Would a regulator find that we treat some groups worse than others?

A lender does not have to intend discrimination to be liable for it. US fair lending law looks at effect: if a protected group is approved at well under four-fifths the rate of the most-approved group, that alone triggers scrutiny. Which means this cannot be a page you generate once and file. It is regenerated on every model change, and it is allowed to come back red.

Gender, approval-rate ratio

0.9777

Passes the four-fifths rule.

Age band, approval-rate ratio

0.3843

Fails. 18-24 approved at 38% of 65+.

Gap among those who would repay

0.4921

Even comparing only creditworthy applicants, age bands are approved at different rates.

Independently cross-checked

exact match

Every figure computed twice, once here, once with Microsoft's Fairlearn library.

Gender

Worst group M against reference F.

passes four-fifths
GroupnApproval rateObserved bad rateMean PDCalibration gap
F10,80860.46%16.76%17.42%+0.0067
M5,46859.11%16.92%17.75%+0.0084

Age band

Worst group 18-24 against reference 65+.

fails four-fifths
GroupnApproval rateObserved bad rateMean PDCalibration gap
18-2496634.16%26.40%28.67%+0.0227
25-343,09646.58%22.29%22.72%+0.0044
35-445,44457.26%17.98%18.56%+0.0058
45-544,54568.01%13.11%14.29%+0.0117
55-641,85678.56%10.24%10.23%-0.0001
65+36988.89%7.05%6.43%-0.0061

Could we fix it, and what would it cost?

Moving one cutoff for everyone is the only lever a lender may lawfully pull.

Approval rateDisparate impactEqual-opportunity gapBad rate among approvedFour-fifths
40%0.22730.56344.55%fails
50%0.30510.53205.57%fails
60%0.38430.49216.74%fails
70%0.47940.40758.18%fails
80%0.62010.266310.10%fails
90%0.76500.146112.64%fails

Most of the measured disparity is a property of where the cutoff sits, not of the model's ranking. Loosening from 40% to 90% approval more than triples the disparate impact ratio, and still does not reach 0.80, while the bad rate among approved rises from 4.6% to 12.6%. Moving a single cutoff costs no AUC; it changes who is approved, never the ranking.

The fix that would work, and why we cannot use it

Different cutoffs per group. Modelled to size the trade-off, never to ship.

StrategyApproval rateDisparate impactEqual-opportunity gapBad rate among approved
threshold_optimizer[demographic_parity]96.0%0.99860.013414.86%
threshold_optimizer[equalized_odds]96.0%0.97310.003414.92%

These are unlawful to deploy. Setting a different decision threshold by protected class is disparate treatment under US fair lending law, even when the intent is to reduce disparate impact. The optimiser establishes what parity would cost; it does not propose shipping it.

Read the last column before the third. Parity is bought by approving 96% of applicants, which more than doubles the bad rate among approved from 6.7% to 14.9%. A disparity number read without that column would be badly misleading.

Why you cannot satisfy every fairness definition at once

Calibration-by-group and equalized odds cannot both hold when base rates differ across groups. That is a mathematical result, not an implementation gap. This model prioritises calibration (a predicted PD means the same thing for every band, within about a percentage point) and consequently does not satisfy equalized odds. That is a policy choice, and it is recorded as one in the model card.

Step 5 of 7

Next · Governance

Can we defend it in two years?

→