# abdullahthescientist/end-to-end-machine-learning-project-with-mlflow architecture

> Architecture diagram of the GitHub repository abdullahthescientist/end-to-end-machine-learning-project-with-mlflow, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow
- Repository: https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow

## Overview

This repository implements an end-to-end tabular ML workflow: download and extract data, validate its schema, split it for training, train an ElasticNet model, and evaluate/log it. `main.py` invokes the five training stages; the stage modules own calls to configuration and component code. A separate Flask-facing prediction entry point is present, but the README is only a title and the prediction implementation was not excerpted, so its internal flow is unclear. The graph omits undocumented template and artifact wiring.

Main entry points: [`src/mlProject/config/configuration.py`](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/config/configuration.py) (Configuration manager), [`main.py`](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/main.py) (Training runner), [`src/mlProject/pipeline/stage_03_data_transformation.py`](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_03_data_transformation.py) (Transformation stage), [`src/mlProject/components/data_ingestion.py`](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/data_ingestion.py) (Data ingestion)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Entry points"]
  node_training_entry["Training runner<br/>[main.py]"]
  node_web_entry["Web app<br/>[app.py]"]
  node_prediction["Prediction pipeline<br/>[prediction.py]"]
end

subgraph group_stages["Training stages"]
  node_ingest_stage["Ingestion stage"]
  node_validation_stage["Validation stage"]
  node_transform_stage["Transformation stage"]
  node_trainer_stage["Trainer stage"]
  node_evaluation_stage["Evaluation stage"]
end

subgraph group_runtime["ML components"]
  node_ingestion["Data ingestion<br/>[data_ingestion.py]"]
  node_validation["Schema validation<br/>[data_validation.py]"]
  node_transformation["Train-test split"]
  node_trainer["ElasticNet trainer<br/>[model_trainer.py]"]
  node_evaluation["Model evaluation"]
end

subgraph group_foundation["Configuration"]
  node_configuration["Configuration manager<br/>[configuration.py]"]
  node_config_types["Config entities<br/>[config_entity.py]"]
  node_common["File utilities<br/>[common.py]"]
end

node_operator(("Workflow operator"))
node_settings["YAML settings<br/>[config.yaml]"]
node_parameters["Model parameters<br/>[params.yaml]"]
node_schema["Column schema<br/>[schema.yaml]"]
node_data_source(("Remote data source"))
node_mlflow[("MLflow tracking")]
node_local_files[("Local data and artifacts")]

node_operator -->|"runs"| node_training_entry
node_operator -.->|"uses"| node_web_entry
node_training_entry -->|"invokes"| node_ingest_stage
node_training_entry -->|"invokes"| node_validation_stage
node_training_entry -->|"invokes"| node_transform_stage
node_training_entry -->|"invokes"| node_trainer_stage
node_training_entry -->|"invokes"| node_evaluation_stage
node_web_entry -->|"imports"| node_prediction
node_ingest_stage -->|"gets settings"| node_configuration
node_ingest_stage -->|"runs"| node_ingestion
node_validation_stage -->|"gets settings"| node_configuration
node_validation_stage -->|"runs"| node_validation
node_transform_stage -->|"gets settings"| node_configuration
node_transform_stage -->|"reads status"| node_validation
node_transform_stage -->|"runs"| node_transformation
node_trainer_stage -->|"gets settings"| node_configuration
node_trainer_stage -->|"runs"| node_trainer
node_evaluation_stage -->|"gets settings"| node_configuration
node_evaluation_stage -->|"runs"| node_evaluation
node_ingestion -->|"downloads"| node_data_source
node_ingestion -->|"extracts data"| node_local_files
node_validation -.->|"validates data"| node_local_files
node_transformation -.->|"reads and splits"| node_local_files
node_trainer -.->|"reads and saves"| node_local_files
node_evaluation -->|"loads model data"| node_local_files
node_evaluation -->|"logs run"| node_mlflow
node_evaluation -->|"saves metrics"| node_common
node_configuration -->|"reads"| node_settings
node_configuration -->|"reads"| node_parameters
node_configuration -->|"reads"| node_schema
node_configuration -->|"creates"| node_config_types
node_configuration -->|"uses"| node_common
node_ingestion -->|"checks size"| node_common

click node_training_entry "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/main.py"
click node_web_entry "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/app.py"
click node_prediction "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/prediction.py"
click node_ingest_stage "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_01_data_ingestion.py"
click node_validation_stage "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_02_data_validation.py"
click node_transform_stage "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_03_data_transformation.py"
click node_trainer_stage "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_04_model_trainer.py"
click node_evaluation_stage "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_05_model_evaluation.py"
click node_ingestion "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/data_ingestion.py"
click node_validation "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/data_validation.py"
click node_transformation "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/data_transformation.py"
click node_trainer "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/model_trainer.py"
click node_evaluation "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/model_evaluation.py"
click node_configuration "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/config/configuration.py"
click node_config_types "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/entity/config_entity.py"
click node_common "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/utils/common.py"
click node_settings "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/config/config.yaml"
click node_parameters "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/params.yaml"
click node_schema "https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/schema.yaml"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_training_entry,node_web_entry,node_prediction toneBlue
class node_ingest_stage,node_validation_stage,node_transform_stage,node_trainer_stage,node_evaluation_stage,node_mlflow,node_local_files toneAmber
class node_ingestion,node_validation,node_transformation,node_trainer,node_evaluation toneMint
class node_configuration,node_config_types,node_common toneRose
class node_operator,node_parameters,node_data_source toneIndigo
class node_settings,node_schema toneTeal
```

## Components

### Entry points

- [Training runner](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/main.py): `main.py`
- [Web app](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/app.py): `app.py`
- [Prediction pipeline](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/prediction.py): `src/mlProject/pipeline/prediction.py`

### Training stages

- [Ingestion stage](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_01_data_ingestion.py): `src/mlProject/pipeline/stage_01_data_ingestion.py`
- [Validation stage](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_02_data_validation.py): `src/mlProject/pipeline/stage_02_data_validation.py`
- [Transformation stage](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_03_data_transformation.py): `src/mlProject/pipeline/stage_03_data_transformation.py`
- [Trainer stage](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_04_model_trainer.py): `src/mlProject/pipeline/stage_04_model_trainer.py`
- [Evaluation stage](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/pipeline/stage_05_model_evaluation.py): `src/mlProject/pipeline/stage_05_model_evaluation.py`

### ML components

- [Data ingestion](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/data_ingestion.py): `src/mlProject/components/data_ingestion.py`
- [Schema validation](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/data_validation.py): `src/mlProject/components/data_validation.py`
- [Train-test split](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/data_transformation.py): `src/mlProject/components/data_transformation.py`
- [ElasticNet trainer](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/model_trainer.py): `src/mlProject/components/model_trainer.py`
- [Model evaluation](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/components/model_evaluation.py): `src/mlProject/components/model_evaluation.py`

### Configuration

- [Configuration manager](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/config/configuration.py): `src/mlProject/config/configuration.py`
- [Config entities](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/entity/config_entity.py): `src/mlProject/entity/config_entity.py`
- [File utilities](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/src/mlProject/utils/common.py): `src/mlProject/utils/common.py`

### Other components

- **Workflow operator**
- [YAML settings](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/config/config.yaml): `config/config.yaml`
- [Model parameters](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/params.yaml): `params.yaml`
- [Column schema](https://github.com/abdullahthescientist/end-to-end-machine-learning-project-with-mlflow/blob/main/schema.yaml): `schema.yaml`
- **Remote data source**
- **MLflow tracking**
- **Local data and artifacts**

## Connections

- Workflow operator → Training runner: runs (evidence: `main.py`)
- Workflow operator → Web app: uses
- Training runner → Ingestion stage: invokes (evidence: `main.py`)
- Training runner → Validation stage: invokes (evidence: `main.py`)
- Training runner → Transformation stage: invokes (evidence: `main.py`)
- Training runner → Trainer stage: invokes (evidence: `main.py`)
- Training runner → Evaluation stage: invokes (evidence: `main.py`)
- Web app → Prediction pipeline: imports (evidence: `app.py`)
- Ingestion stage → Configuration manager: gets settings (evidence: `src/mlProject/pipeline/stage_01_data_ingestion.py`)
- Ingestion stage → Data ingestion: runs (evidence: `src/mlProject/pipeline/stage_01_data_ingestion.py`)
- Validation stage → Configuration manager: gets settings (evidence: `src/mlProject/pipeline/stage_02_data_validation.py`)
- Validation stage → Schema validation: runs (evidence: `src/mlProject/pipeline/stage_02_data_validation.py`)
- Transformation stage → Configuration manager: gets settings (evidence: `src/mlProject/pipeline/stage_03_data_transformation.py`)
- Transformation stage → Schema validation: reads status (evidence: `src/mlProject/pipeline/stage_03_data_transformation.py`)
- Transformation stage → Train-test split: runs (evidence: `src/mlProject/pipeline/stage_03_data_transformation.py`)
- Trainer stage → Configuration manager: gets settings (evidence: `src/mlProject/pipeline/stage_04_model_trainer.py`)
- Trainer stage → ElasticNet trainer: runs (evidence: `src/mlProject/pipeline/stage_04_model_trainer.py`)
- Evaluation stage → Configuration manager: gets settings (evidence: `src/mlProject/pipeline/stage_05_model_evaluation.py`)
- Evaluation stage → Model evaluation: runs (evidence: `src/mlProject/pipeline/stage_05_model_evaluation.py`)
- Data ingestion → Remote data source: downloads (evidence: `src/mlProject/components/data_ingestion.py`)
- Data ingestion → Local data and artifacts: extracts data (evidence: `src/mlProject/components/data_ingestion.py`)
- Schema validation → Local data and artifacts: validates data
- Train-test split → Local data and artifacts: reads and splits
- ElasticNet trainer → Local data and artifacts: reads and saves
- Model evaluation → Local data and artifacts: loads model data (evidence: `src/mlProject/components/model_evaluation.py`)
- Model evaluation → MLflow tracking: logs run (evidence: `src/mlProject/components/model_evaluation.py`)
- Model evaluation → File utilities: saves metrics (evidence: `src/mlProject/components/model_evaluation.py`)
- Configuration manager → YAML settings: reads (evidence: `src/mlProject/config/configuration.py`)
- Configuration manager → Model parameters: reads (evidence: `src/mlProject/config/configuration.py`)
- Configuration manager → Column schema: reads (evidence: `src/mlProject/config/configuration.py`)
- Configuration manager → Config entities: creates (evidence: `src/mlProject/config/configuration.py`)
- Configuration manager → File utilities: uses (evidence: `src/mlProject/config/configuration.py`)
- Data ingestion → File utilities: checks size (evidence: `src/mlProject/components/data_ingestion.py`)
