Inspiration

Banks lose billions every year approving loans for applicants who default. Traditional credit checks are slow and opaque. We wanted to build a fast, explainable system that gives loan officers a clear decision with reasoning.

What it does

LoanSight scores any loan applicant in real-time and returns:

  • APPROVE / REJECT / REVIEW decision
  • Default probability percentage
  • FICO-style risk score (300–850)
  • Top risk factors explaining the decision
  • What-if analysis: change one feature and see how risk shifts instantly

How we built it

  • Trained an XGBoost pipeline on 150,000 real credit records (Give Me Some Credit dataset)
  • Built a data validation firewall to catch bad/fake inputs before prediction
  • Added missingness indicators as features (missing income is itself a risk signal)
  • Wrapped everything in a clean Streamlit UI with explainability charts

Challenges we ran into

  • Missing data handling: ~20% of income values were missing solved with MNAR indicators + median imputation inside the pipeline
  • Threshold optimization: default rate is only 7%, so we used a cost matrix (FN costs 5x more than FP) to set the decision threshold at 0.25
  • Getting the UI to pass the right feature columns to the trained pipeline

Accomplishments that we're proud of

  • End-to-end modular system: validation → prediction → explanation in one click
  • What-if analysis that updates live as you sweep any feature
  • Clean separation of concerns: preprocess / predict / explain are fully independent

What we learned

  • Real-world ML is 80% data cleaning and 20% modeling
  • Missing data patterns carry predictive signal don't just impute and ignore
  • Explainability is not optional in financial ML it's a requirement

What's next for LoanSight - Credit Risk Engine

  • Deploy on Streamlit Cloud with a public URL
  • Add SHAP waterfall plots for per-applicant deep explanations
  • Batch CSV upload for processing multiple applicants at once
  • Add fairness audit (check for age/income bias in decisions)

Built With

Share this project:

Updates