NeoScore is a full-stack credit scoring platform designed for the Indian lending ecosystem, especially targeting thin-file users — individuals with little or no credit history.
It combines a knowledge-distillation ML pipeline, a real-time scoring API, and a Groq-powered AI financial coach to deliver transparent, explainable, and actionable credit insights.
-
📊 Credit Score (300–900) Industry-style scoring mapped to population percentiles
-
🧠 Explainable AI (SHAP + LLM) Understand exactly why a score was assigned
-
🤖 AI Financial Coach Converts model output into human-friendly advice
-
🔄 What-If Simulator Adjust inputs (income, DTI, savings) and see live score changes
-
📈 Counterfactual Recommendations “Do this → gain +X points” actionable insights
-
👤 Persona-Based Demo Prebuilt profiles for quick testing
-
🔐 Google OAuth + History Save and track past credit evaluations
All required trained models and artifacts (teacher model, student model, calibration files, etc.) are available here:
🔗 https://drive.google.com/drive/folders/1ouQRWfIVffsxAdwKYrOwVtDnvFfOJS5q?usp=sharing
- Download all files from the Drive folder
- Place them inside the backend artifacts directory:
backend/artifacts/- Ensure filenames match those expected in your code (e.g.,
student_model.pkl,calibrator.pkl, etc.)
| Layer | Technologies |
|---|---|
| Frontend | Next.js 14 · Zustand · Tailwind CSS · Framer Motion |
| Backend | Flask · MongoDB · Google OAuth · Groq API |
| ML Pipeline | XGBoost (Teacher → Student) · SHAP |
| Score Range | 300–900 |
| Core Innovation | Thin-file scoring using knowledge distillation |
User Input
↓
Frontend (Next.js + Zustand)
↓
Flask API (/api/score)
↓
Feature Engineering
↓
Student Model (XGBoost)
↓
SHAP (Top Features)
↓
Groq LLM (AI Explanation)
↓
Frontend (Score + Insights)
-
Combines 5 Home Credit datasets
-
Engineers 30+ features
-
Creates composite scores:
- Financial Pressure
- Stability Score
- Asset Score
- Income Adequacy
- XGBoost classifier trained on thick-file users
- Uses isotonic calibration for probability accuracy
- Generates soft labels for all users
- Learns from soft labels (not raw targets)
- Works for thin-file users
- Uses monotonic constraints (financial logic)
Score = Percentile × 600 + 300
-
SHAP → identifies top contributing features
-
LLM → converts into human-readable insights
-
Filters out:
- Age
- Region
- Sensitive attributes
| Endpoint | Method | Description |
|---|---|---|
/api/score |
POST | Get score + explanation |
/api/counterfactual |
POST | Suggest improvements |
/api/simulate |
POST | What-if score changes |
/api/features |
GET | Feature metadata |
/chat |
POST | AI assistant |
/auth/login/google |
GET | OAuth login |
| Route | Purpose |
|---|---|
/home |
Persona selection + manual input |
/results |
Score + insights + simulator |
/history |
Score history |
/loans |
Loan recommendations |
/api-docs |
API reference |
git clone https://github.com/your-username/neoscore.git
cd neoscorecd backend
pip install -r requirements.txtCreate .env:
GROQ_API_KEY=your_key_here
MONGO_URI=your_mongo_uri
GOOGLE_CLIENT_ID=your_client_id
GOOGLE_CLIENT_SECRET=your_secretRun server:
python main.pycd frontend
npm install
npm run devcurl -X POST http://localhost:5000/api/score \
-H "Content-Type: application/json" \
-d '{
"features": {
"AMT_INCOME_TOTAL": 500000,
"AMT_CREDIT": 200000,
"EMPLOYED_YEARS": 5
}
}'{
"score": 398,
"risk_tier": "Very Poor",
"ai_explanation": "Here’s what’s going on with your score...",
"top_features": [...]
}Traditional credit scoring:
- Requires credit history
- Not transparent
- Not actionable
NeoScore:
- Works for first-time borrowers
- Fully explainable
- Provides clear improvement steps
- 📱 Mobile app
- 🏦 Banking API integration
- 📊 Personalized financial roadmap
- 🤝 Loan matching system
⭐ If you like this project, consider giving it a star!