{"id":29799109,"url":"https://github.com/balavenkatesh3322/loan-default-prediction","last_synced_at":"2026-05-17T01:34:48.136Z","repository":{"id":303385520,"uuid":"1015290452","full_name":"balavenkatesh3322/loan-default-prediction","owner":"balavenkatesh3322","description":"An end-to-end machine learning project to predict loan default risk. Includes Exploratory Data Analysis (EDA), feature engineering, a Gradient Boosting model, and a      proposed system architecture for deployment.","archived":false,"fork":false,"pushed_at":"2025-07-07T09:51:17.000Z","size":13025,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-07-07T10:56:17.351Z","etag":null,"topics":["data-science","deep-learning","feature-engineering","gradient-boosting","loan-default-prediction","machine-learning","scikit-learn","tutorial-exercises"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/balavenkatesh3322.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-07T09:31:09.000Z","updated_at":"2025-07-07T09:51:20.000Z","dependencies_parsed_at":"2025-07-07T11:06:23.426Z","dependency_job_id":null,"html_url":"https://github.com/balavenkatesh3322/loan-default-prediction","commit_stats":null,"previous_names":["balavenkatesh3322/loan-default-prediction"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/balavenkatesh3322/loan-default-prediction","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/balavenkatesh3322%2Floan-default-prediction","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/balavenkatesh3322%2Floan-default-prediction/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/balavenkatesh3322%2Floan-default-prediction/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/balavenkatesh3322%2Floan-default-prediction/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/balavenkatesh3322","download_url":"https://codeload.github.com/balavenkatesh3322/loan-default-prediction/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/balavenkatesh3322%2Floan-default-prediction/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267482004,"owners_count":24094508,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-28T02:00:09.689Z","response_time":68,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-science","deep-learning","feature-engineering","gradient-boosting","loan-default-prediction","machine-learning","scikit-learn","tutorial-exercises"],"created_at":"2025-07-28T08:08:38.789Z","updated_at":"2026-05-17T01:34:43.115Z","avatar_url":"https://github.com/balavenkatesh3322.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Loan Default Prediction\n\nAn end-to-end machine learning project to predict loan default risk. Includes Exploratory Data Analysis (EDA), feature engineering, a Gradient Boosting model, and a proposed system architecture for deployment.\n\n---\n\n## Table of Contents\n\n- [Project Overview](#project-overview)\n- [Features](#features)\n- [System Architecture](#system-architecture)\n- [Model Performance](#model-performance)\n- [Getting Started](#getting-started)\n  - [Prerequisites](#prerequisites)\n  - [Installation](#installation)\n- [Usage](#usage)\n\n---\n\n## Project Overview\n\nFor financial institutions, the ability to predict loan defaults is a critical factor in managing financial risk and maintaining profitability. This project addresses this challenge by building a robust machine learning model to predict the likelihood of a borrower defaulting on a loan.\n\nThe solution involves a complete MLOps workflow, from data ingestion and analysis to model training, deployment, and monitoring. By leveraging a Gradient Boosting Classifier, the model provides a reliable risk score that can be integrated into a real-time loan application system.\n\n## Features\n\n*   **Exploratory Data Analysis (EDA):** A detailed analysis of the dataset is provided in the `eda.ipynb` notebook, including visualizations of feature distributions and correlations.\n*   **Data Cleaning \u0026 Preprocessing:** A robust pipeline handles missing values, converts data types, and scales features to prepare the data for modeling.\n*   **Feature Engineering:** New, insightful features were created to improve model accuracy, such as `Credit_to_Income_Ratio` and `Employment_Years`.\n*   **Imbalanced Data Handling:** The project uses the **SMOTE (Synthetic Minority Over-sampling Technique)** to address the significant class imbalance in the dataset, ensuring the model learns to identify the minority class (defaulters) effectively.\n*   **Model Training \u0026 Tuning:** A Gradient Boosting Classifier is trained and optimized using `GridSearchCV` to achieve the best possible performance.\n*   **End-to-End MLOps Pipeline:** The project includes a proposed system architecture for a complete CI/CD pipeline, covering everything from automated training to model deployment and monitoring.\n\n---\n\n## System Architecture\n\nThe proposed architecture for deploying the model into a production environment is designed for scalability, reliability, and continuous improvement. It consists of an automated ML pipeline for training and a serving infrastructure to deliver real-time predictions.\n\n```mermaid\ngraph TD\n    A[Data Sources] --\u003e B{Data Ingestion};\n    B --\u003e C[Data Preprocessing \u0026 Feature Engineering];\n    C --\u003e D[Model Training \u0026 Tuning];\n    D --\u003e E[Model Registry];\n    E --\u003e F[Model Deployment];\n    F --\u003e G[API Endpoint];\n    G --\u003e H[Loan Application];\n\n    subgraph \"ML Pipeline\"\n        B;\n        C;\n        D;\n    end\n\n    subgraph \"Serving Infrastructure\"\n        E;\n        F;\n        G;\n    end\n\n    subgraph \"Monitoring\"\n        M[Model Monitoring] --\u003e N[Alerting];\n        F --\u003e M;\n    end\n```\n\n---\n\n## Model Performance\n\nThe final Gradient Boosting model was evaluated on a hold-out test set. The key performance metrics are:\n\n*   **AUC-ROC Score:** **[Run the `eda.ipynb` notebook to generate this value]**\n\nBelow are the visualizations of the model's performance and the most important features driving its predictions. \n\n*(To generate these images, please run the `eda.ipynb` notebook.)*\n\n**ROC Curve**\n\n![Diagram](./img/roc.png)\n\n**Top Most Important Features**\n\n![Feature Diagram](./img/coclusion.png)\n\n---\n\n## Getting Started\n\nFollow these instructions to set up and run the project on your local machine.\n\n### Prerequisites\n\n*   Python 3.7+\n*   Jupyter Notebook or JupyterLab\n\n### Installation\n\n1.  **Clone the repository:**\n    ```bash\n    git clone https://github.com/your-username/Loan-Default-Prediction.git\n    cd Loan-Default-Prediction\n    ```\n\n2.  **Install the required packages:**\n    ```bash\n    pip install -r requirements.txt\n    ```\n    *(Note: A `requirements.txt` file is recommended. For now, you can install the packages listed in the notebook.)*\n\n---\n\n## Usage\n\nTo explore the data, train the model, and see the results, run the Jupyter notebook:\n\n```bash\njupyter notebook eda.ipynb\n```\n\nInside the notebook, you can execute the cells sequentially to see the entire process, from data loading to model evaluation.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbalavenkatesh3322%2Floan-default-prediction","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbalavenkatesh3322%2Floan-default-prediction","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbalavenkatesh3322%2Floan-default-prediction/lists"}