{"id":46044089,"url":"https://github.com/kshula/debt_analysis","last_synced_at":"2026-03-01T07:05:47.618Z","repository":{"id":239001048,"uuid":"798183865","full_name":"kshula/debt_analysis","owner":"kshula","description":"Debt Analysis and Prediction with Machine learning","archived":false,"fork":false,"pushed_at":"2024-05-09T11:22:03.000Z","size":1866,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-05-10T11:57:59.579Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","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/kshula.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}},"created_at":"2024-05-09T09:04:44.000Z","updated_at":"2024-05-09T11:22:07.000Z","dependencies_parsed_at":"2024-05-09T12:08:01.327Z","dependency_job_id":null,"html_url":"https://github.com/kshula/debt_analysis","commit_stats":null,"previous_names":["kshula/debt_analysis"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/kshula/debt_analysis","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kshula%2Fdebt_analysis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kshula%2Fdebt_analysis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kshula%2Fdebt_analysis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kshula%2Fdebt_analysis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kshula","download_url":"https://codeload.github.com/kshula/debt_analysis/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kshula%2Fdebt_analysis/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29963120,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-01T06:55:38.174Z","status":"ssl_error","status_checked_at":"2026-03-01T06:53:04.810Z","response_time":124,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":[],"created_at":"2026-03-01T07:05:47.072Z","updated_at":"2026-03-01T07:05:47.589Z","avatar_url":"https://github.com/kshula.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Debt Analysis and Prediction with Machine learning\n![Debt Service Analysis](images/model.png)\n\nThis project is a Streamlit web application designed for debt service analysis and prediction. It includes features for evaluating lender classification using K-Nearest Neighbors (KNN) and predicting debt service using Random Forest and Gradient Boosting models.\n\n## Features\n\n### 1. Lender Classification with KNN\n![Lender Classification](images/debt.png)\n\nThe application includes a functionality to perform lender classification based on debt characteristics using the K-Nearest Neighbors (KNN) algorithm. The key steps involved are:\n\n- Loading and preprocessing the debt data.\n- Applying KNN to classify lenders based on debt stock and interest arrears.\n- Visualizing the classification results using interactive plots.\n\n### 2. Debt Service Prediction\n\nThe application offers debt service prediction using two machine learning models: Random Forest and Gradient Boosting. The prediction process involves:\n\n- Splitting the dataset into training and testing sets.\n- Training the models on the training data.\n- Evaluating model performance using accuracy and R2 score.\n- Generating future predictions for debt service over specified periods.\n\n## How to Use\n\n1. **Installation**\n\n   Ensure you have Python installed. Clone this repository and navigate to the project directory.\n\n   ```bash\n   git clone https://github.com/kshula/debt_analysis.git\n   cd debt\n   ```\n\n\n    Install the required Python packages using pip and the provided requirements.txt file.\n\n```bash\nCopy code\npip install -r requirements.txt\n```\n## Running the Application\nStart the Streamlit web app by running the following command in your terminal.\n```bash\nCopy code\nstreamlit run main.py\n```\nThis will launch the web application in your default web browser.\n## Navigation\nHome: Displays an overview of debt service over time.\nModel Accuracy: Evaluates model performance on debt service data.\nPredictions: Generates future predictions for debt service using selected models.\nDebt Analysis: Machine learning KNN Analysis\n\n## File Structure\nmain.py: Main Python script containing Streamlit application code.\ndata/: Directory containing dataset files used by the application.\nrequirements.txt: List of Python packages required for the project.\n\n## Contributors\nKampamba Shula","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkshula%2Fdebt_analysis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkshula%2Fdebt_analysis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkshula%2Fdebt_analysis/lists"}