Spaces:
Sleeping
Sleeping
File size: 5,538 Bytes
9f70e0c 8081e52 8d927fa 8081e52 8d927fa 8081e52 8d927fa 8081e52 8d927fa 8081e52 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 |
---
title: Loan Recovery
emoji: π
colorFrom: purple
colorTo: green
sdk: streamlit
sdk_version: 1.44.1
app_file: app.py
pinned: false
---
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
# Smart Loan Recovery System
A machine learning-powered system for predicting loan recovery probability with a Streamlit web interface.
## Overview
The Smart Loan Recovery System helps financial institutions predict the likelihood of recovering loans by analyzing various customer and loan attributes. The system uses machine learning algorithms to provide insights that can help prioritize collection efforts and optimize recovery strategies.
## System Workflow

The diagram above illustrates the complete workflow of the Smart Loan Recovery System:
1. **Data Input**: Users can enter individual loan details or upload CSV files for batch processing
2. **Data Processing**: The system preprocesses the data, performs feature engineering and normalization
3. **Random Forest Model**: The prediction engine analyzes the data using the Random Forest algorithm
4. **Results Visualization**: Interactive charts display recovery probability and risk assessment
The bottom section shows the key system components and their relationships, providing a clear overview of the system architecture.
## Features
- **Predictive Analytics**: Uses machine learning to predict loan recovery probability
- **Individual Loan Assessment**: Analyze individual loans for recovery potential
- **Batch Processing**: Process multiple loans at once for efficient analysis
- **Data Visualization**: Interactive charts and graphs for better understanding
- **Risk Factor Identification**: Highlights key factors affecting recovery
## Installation
1. Clone the repository:
```
git clone https://github.com/yourusername/smart-loan-recovery-system.git
cd smart-loan-recovery-system
```
2. Create a virtual environment and install dependencies:
```
python -m venv venv
source venv/Scripts/activate # On Windows
# OR
source venv/bin/activate # On macOS/Linux
pip install -r requirements.txt
```
## Usage
1. Generate sample data and train the Random Forest model:
```
python src/train_model.py
```
2. Run the Streamlit application:
```
streamlit run app.py
```
3. Open your browser and navigate to `http://localhost:8501`
## Project Structure
```
smart-loan-recovery-system/
βββ app.py # Main Streamlit application
βββ data/ # Data directory
β βββ loan_data.csv # Sample loan data
βββ models/ # Trained models
β βββ loan_recovery_random_forest.pkl # Trained Random Forest model
β βββ loan_recovery_random_forest_processor.pkl # Model preprocessor
βββ screenshots/ # Screenshots and diagrams
β βββ system_workflow.svg # System workflow diagram (SVG)
β βββ system_workflow.png # System workflow diagram (PNG)
β βββ system_workflow.html # System workflow diagram (HTML)
β βββ loan_input_form.png # UI screenshot - input form
β βββ prediction_results.png # UI screenshot - results
βββ src/ # Source code
β βββ models/ # ML model implementations
β β βββ loan_recovery_model.py # Loan recovery model class
β βββ preprocessing/ # Data preprocessing
β β βββ data_processor.py # Data processor class
β βββ utils/ # Utility functions
β β βββ data_generator.py # Synthetic data generator
β βββ train_model.py # Script to train models
βββ Smart_Loan_Recovery_System_Documentation.docx # Comprehensive project documentation
βββ README.md # Project overview
βββ requirements.txt # Project dependencies
```
## Machine Learning Model
The system uses a Random Forest model for loan recovery prediction:
**Random Forest**: An ensemble learning method that operates by constructing multiple decision trees. It provides high accuracy and can handle non-linear relationships in the data, making it ideal for loan recovery prediction.
## Web Interface
The Streamlit web interface focuses solely on loan recovery prediction, providing a clean and intuitive interface for users to predict the probability of recovering loans.
### Sample Interface

### Sample Results

The interface allows users to:
- Enter individual loan details with comprehensive input fields
- Upload CSV files for batch processing
- View recovery probability with visual indicators
- Receive recovery assessment and risk factor identification
> Note: The screenshots above show sample results from the application. You'll need to add your own screenshots to the `screenshots` directory after running the application.
## License
This project is licensed under the MIT License - see the LICENSE file for details.
## Contact
For more information, please contact [email protected]
|