# aruuuke/creditrisk architecture

> Architecture diagram of the GitHub repository aruuuke/creditrisk, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-03-31). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/aruuuke/creditrisk
- Repository: https://github.com/aruuuke/creditrisk

## Overview

##### Project Type and Purpose
- This is a machine learning/data science project with a focus on credit risk assessment.
- The README makes it clear that the project leverages three core ML techniques. It also provides the context by mentioning that the data comes from a Kaggle dataset.
- The PDFs and notebooks indicate that the work is both documented and exploratory, with each model implemented as a separate notebook.

##### Analyzing the File Structure
- At the top level, the project includes:
- Three Jupyter notebooks: one each for LogisticRegression.ipynb, NeuralNetworks.ipynb, and SVM.ipynb. These represent the implementations of the different ML models.
- CSV files (customer_data.csv, payment_customer_data.csv, payment_data.csv) which serve as data sources.
- Final Project Write-Up.pdf: encapsulating findings and possibly serving as documentation/presentation.
- README.md: provides a concise project description and contextual information.
- This layout implies that the system can be segmented roughly into input data, data processing/model training, and output/documentation.

a. Main Components to Include:
- Data Sources: Represent the CSV files as a grouped data input block.
- Data Preprocessing (if applicable): Although not explicitly separated, preprocess steps may be inherent in the notebooks.
- Model Training Components: Three separate modules—one for Logistic Regression, one for SVM, and one for Neural Networks. Each should be clearly labeled.
- Evaluation/Output: A block that represents the process of assessing the models’ performance (e.g., cross-validation, risk classification metrics).
- Documentation: This block references the Final Project Write-Up.pdf, summarizing the overall results and insights.

b. Relationships and Interactions:
- Optionally, link the evaluation block to the Documentation block to indicate that final insights are collated in the project write-up.

c. Architectural Patterns and Design Principles:
- Emphasis on modularity: Each ML model (Logistic Regression, SVM, Neural Networks) is developed independently, allowing for easy comparison.
- Data-centric design: Highlight the flow from raw data to processed outcomes.
- Interactivity typical of notebook-driven workflows, where experiments and model training are closely coupled with data exploration.

d. Relevant Technologies and Frameworks:
- The use of Jupyter notebooks points to an exploratory and interactive development environment.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Data Sources Block
    subgraph "Data Sources"
        CSV1["customer_data.csv"]:::data
        CSV2["payment_customer_data.csv"]:::data
        CSV3["payment_data.csv"]:::data
    end

    %% Preprocessing Block
    Preproc["Data_Preprocessing"]:::preprocess

    %% Model Training Block
    subgraph "Model Training"
        Model1["Logistic_Regression (Notebook)"]:::model
        Model2["SVM (Notebook)"]:::model
        Model3["Neural_Networks (Notebook)"]:::model
    end

    %% Evaluation Block
    Eval["Evaluation_and_Risk_Classification"]:::eval

    %% Documentation Block
    subgraph "Documentation"
        D1["Project_Write-Up"]:::doc
        D2["README"]:::doc
    end

    %% Connections
    CSV1 & CSV2 & CSV3 --> Preproc
    Preproc --> Model1
    Preproc --> Model2
    Preproc --> Model3
    Model1 --> Eval
    Model2 --> Eval
    Model3 --> Eval
    Eval --> D1
    Eval --> D2

    %% Click Events
    click CSV1 "https://github.com/aruuuke/creditrisk/blob/main/customer_data.csv"
    click CSV2 "https://github.com/aruuuke/creditrisk/blob/main/payment_customer_data.csv"
    click CSV3 "https://github.com/aruuuke/creditrisk/blob/main/payment_data.csv"
    click Model1 "https://github.com/aruuuke/creditrisk/blob/main/LogisticRegression.ipynb"
    click Model2 "https://github.com/aruuuke/creditrisk/blob/main/SVM.ipynb"
    click Model3 "https://github.com/aruuuke/creditrisk/blob/main/NeuralNetworks.ipynb"
    click D1 "https://github.com/aruuuke/creditrisk/blob/main/Final Project Write-Up.pdf"
    click D2 "https://github.com/aruuuke/creditrisk/blob/main/README.md"

    %% Styles
    classDef data fill:#AED6F1,stroke:#1F618D,stroke-width:2px;
    classDef preprocess fill:#F9E79F,stroke:#B7950B,stroke-width:2px;
    classDef model fill:#A9DFBF,stroke:#27AE60,stroke-width:2px;
    classDef eval fill:#F5B7B1,stroke:#C0392B,stroke-width:2px;
    classDef doc fill:#D2B4DE,stroke:#8E44AD,stroke-width:2px;
```
