Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

49 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

PipelineX AI πŸš€

Intelligent ML Automation Platform β€” Automate the complete machine learning lifecycle from data ingestion and preprocessing to model training, evaluation, and export.


πŸ“Έ Preview

PipelineX AI Homepage


πŸ“Œ About the Project

PipelineX AI is a web-based machine learning automation platform built as an Industrial Training Project. It provides a clean, modern interface for data scientists and ML practitioners to manage their entire ML workflow without writing repetitive boilerplate code.

The platform guides users through a structured 8-module pipeline β€” from raw file upload to a downloadable trained model β€” entirely in the browser. No Jupyter notebooks. No local pip installs.


✨ Features

Module Status Description
πŸ“‚ File Upload & Parsing βœ… Complete Upload CSV, Excel, JSON, XML, or HTML β€” auto-parsed into a pandas DataFrame
πŸ“‹ Data Summary βœ… Complete Row/column counts, dtypes, missing value analysis, descriptive statistics
πŸ“Š EDA Visualizations βœ… Complete Histograms with KDE, categorical bar charts, correlation heatmap
🧹 Data Cleaning βœ… Complete Mean/median/mode imputation, IQR outlier detection & handling, duplicate removal, string normalization
βš™οΈ Feature Engineering βœ… Complete LabelEncoder for categoricals, StandardScaler for numerics, per-column selection
🎯 Problem Selection βœ… Complete Classification, Regression, or Clustering β€” target column picker
πŸ€– Model Training βœ… Complete scikit-learn training with 80/20 split, 5 algorithms across 3 problem types
πŸ“ˆ Model Evaluation βœ… Complete Accuracy, RΒ², RMSE, Silhouette Score β€” colour-coded results
πŸ’Ύ Model Export βœ… Complete Download trained model as .pkl via joblib.dump()

πŸ› οΈ Tech Stack

Layer Technology
Backend Python 3.11, Flask 3.1
Database SQLite via Flask-SQLAlchemy ORM
Frontend HTML5, CSS3 (custom dark UI), Jinja2 Templating
Auth Werkzeug (generate_password_hash / check_password_hash)
Data pandas 2.2, NumPy
Visualization matplotlib 3.10, seaborn 0.13
ML scikit-learn 1.6, joblib
Sessions Flask Sessions & Flash Messages

πŸ“ Project Structure

PipelineX_AI/
β”‚
β”œβ”€β”€ app.py                          # Main Flask application & all route definitions
β”‚
β”œβ”€β”€ modules/                        # Business logic β€” one file per pipeline stage
β”‚   β”œβ”€β”€ data_loader.py              # Module 3   β€” File parsing & extension validation
β”‚   β”œβ”€β”€ data_summary.py             # Module 4   β€” Shape, dtypes, missing values, describe()
β”‚   β”œβ”€β”€ eda.py                      # Module 5   β€” Histograms, bar charts, heatmap (Base64)
β”‚   β”œβ”€β”€ cleaning.py                 # Module 6–8 β€” Imputation, outlier handling, deduplication
β”‚   β”œβ”€β”€ feature_engineering.py      # Module 9   β€” LabelEncoder & StandardScaler
β”‚   └── model_training.py           # Module 12–13 β€” Training & evaluation logic
β”‚
β”œβ”€β”€ templates/                      # Jinja2 HTML templates
β”‚   β”œβ”€β”€ index.html                  # Landing / Home page
β”‚   β”œβ”€β”€ login.html                  # Login form
β”‚   β”œβ”€β”€ register.html               # Registration form
β”‚   β”œβ”€β”€ dashboard.html              # User dashboard (protected)
β”‚   β”œβ”€β”€ upload.html                 # Dataset upload form
β”‚   β”œβ”€β”€ summary.html                # Data summary report
β”‚   β”œβ”€β”€ eda.html                    # EDA visualizations page
β”‚   β”œβ”€β”€ cleaning.html               # Data cleaning controls
β”‚   β”œβ”€β”€ feature_engineering.html    # Feature transformation controls
β”‚   β”œβ”€β”€ problem_select.html         # Problem type & target column selection
β”‚   β”œβ”€β”€ train.html                  # Model training & results
β”‚   └── export.html                 # Model export / download
β”‚
β”œβ”€β”€ static/
β”‚   └── style.css                   # Global stylesheet
β”‚
β”œβ”€β”€ uploads/                        # Temporary file storage (gitignored)
β”‚
β”œβ”€β”€ instance/
β”‚   └── users.db                    # SQLite database (auto-generated on first run)
β”‚
β”œβ”€β”€ .gitignore
└── README.md

βš™οΈ Getting Started

Prerequisites

Python 3.8 or higher is required.

python --version

1. Clone the Repository

git clone https://github.com/Shivangverma7/PipelineX_AI.git
cd PipelineX_AI

2. Create a Virtual Environment

# Create
python -m venv venv

# Activate β€” Windows
venv\Scripts\activate

# Activate β€” macOS/Linux
source venv/bin/activate

3. Install Dependencies

pip install flask flask-sqlalchemy werkzeug pandas numpy matplotlib seaborn scikit-learn joblib openpyxl lxml

Or if a requirements.txt is present:

pip install -r requirements.txt

4. Run the Application

python app.py

Then open your browser and navigate to:

http://127.0.0.1:5000

πŸ” Application Routes

Route Method Access Description
/ GET Public Home / Landing page
/register GET, POST Public Create a new account
/login GET, POST Public Sign in with existing credentials
/logout GET Authenticated Clears session, redirects to home
/dashboard GET Authenticated User dashboard
/upload GET, POST Authenticated Upload dataset file
/summary GET Authenticated View data summary report
/eda GET Authenticated View EDA visualizations
/cleaning GET, POST Authenticated Apply data cleaning operations
/feature_engineering GET, POST Authenticated Apply feature transformations
/problem_select GET, POST Authenticated Select problem type and target column
/train GET, POST Authenticated Train model and view evaluation metrics
/export GET Authenticated Download trained model as .pkl

πŸ” Authentication

Password rules enforced at registration:

  • Minimum 8 characters
  • Must contain at least one letter
  • Must contain at least one number
  • Must contain at least one special character

Passwords are stored as salted hashes using Werkzeug's generate_password_hash(). Plaintext passwords are never persisted.


πŸ“€ File Upload β€” modules/data_loader.py (Module 3)

Supported formats: .csv, .xlsx, .xls, .json, .xml, .html, .htm

Max file size: 50 MB

Function Description
allowed_file(filename) Validates the file extension against the allowed set
load_dataframe(filepath) Reads the file and returns a parsed pandas DataFrame

Uploaded files are saved to uploads/, parsed with the appropriate pandas reader (read_csv, read_excel, read_json, read_xml, read_html), and held in a module-level in-memory store for the duration of the session.


πŸ“‹ Data Summary β€” modules/data_summary.py (Module 4)

Function Description
get_summary(df) Returns a dict of all summary data needed to render summary.html

Keys returned by get_summary():

Key Type Contents
rows int Total row count
cols int Total column count
columns_info list of dicts Per-column name, dtype, missing count, missing percentage
stats dict of dicts df.describe() output for all numeric columns (rounded to 3dp)
preview_cols list Column names for the table header
preview_rows list of lists First 5 rows as raw values

πŸ“Š EDA Visualizations β€” modules/eda.py (Module 5)

Function Description
generate_visualizations(df) Generates all plots and returns them as a {name: base64} dict
get_base64_plot() Internal helper β€” saves current figure to a BytesIO buffer and Base64-encodes it

Plots generated:

Plot Columns Used Details
Histograms Up to 6 numeric columns sns.histplot with KDE, dark background, #6c63ff fill
Bar charts Up to 4 categorical columns Top-10 value counts, mako palette, rotated x-labels
Correlation heatmap All numeric columns sns.heatmap, coolwarm palette, annotated with 2dp values

All plots use matplotlib's Agg backend (non-interactive, required for Flask) and are Base64-encoded for direct embedding in HTML β€” no external image hosting or temp files.


🧹 Data Cleaning β€” modules/cleaning.py (Modules 6, 7, 8)

Function Signature Description
handle_missing_values (df, strategy='auto') 'auto' β†’ mean/mode; 'median' β†’ median/mode
get_missing_stats (df) Returns {column: missing_count} for columns with nulls
detect_outliers (df) IQR method β€” returns {column: outlier_count} for numeric columns
handle_outliers (df, strategy='remove') 'remove' drops outlier rows; 'cap' clips to IQR bounds (Winsorization)
remove_duplicates (df) Drops exact duplicate rows via df.drop_duplicates()
fix_inconsistencies (df) Strips leading/trailing whitespace from all string (object) columns

βš™οΈ Feature Engineering β€” modules/feature_engineering.py (Module 9)

Function Signature Description
apply_label_encoding (df, columns) Applies sklearn.LabelEncoder β€” converts strings to integers
apply_standard_scaling (df, columns) Applies sklearn.StandardScaler (mean=0, std=1) to numeric columns
get_feature_info (df) Returns {'categorical': [...], 'numeric': [...]} for UI column selection

Transformations are applied to a copy of the DataFrame; the original is never mutated. Only columns that exist in the DataFrame are processed.


πŸ€– Model Training & Evaluation β€” modules/model_training.py (Modules 12, 13)

Function Signature Description
train_model_logic (df, problem_type, algorithm, target_col) Trains the selected model and returns the model object, metrics dict, and test split

Supported algorithms:

Problem Type Algorithm algorithm key
Classification Logistic Regression (max_iter=1000) logistic_regression
Classification Random Forest (100 estimators) random_forest
Regression Linear Regression linear_regression
Regression Decision Tree Regressor decision_tree
Clustering K-Means (k=3, n_init='auto') kmeans

Evaluation metrics by problem type:

Problem Type Metric Function
Classification Accuracy accuracy_score()
Regression RΒ² Score r2_score()
Regression RMSE sqrt(mean_squared_error())
Clustering Silhouette Score silhouette_score()

All supervised models use an 80/20 train-test split with random_state=42. Clustering runs on the full dataset; Silhouette Score is only calculated when more than one cluster label is present.


πŸ—„οΈ Database

The project uses SQLite with SQLAlchemy ORM. users.db is auto-created inside instance/ on the first run β€” no manual setup needed.

User Model:

Column Type Details
id Integer Primary Key, auto-increment
name String(100) User's full name
email String(100) Unique, used for login
password String(200) Werkzeug salted hash β€” never plaintext

🚧 Roadmap

  • User Registration & Login
  • Session Management & Flash Messages
  • Protected Dashboard Route
  • Multi-format Dataset Upload β€” CSV, Excel, JSON, XML, HTML (Module 3)
  • Data Summary Report β€” shape, dtypes, missing values, describe() (Module 4)
  • EDA Visualizations β€” Histograms, Bar Charts, Correlation Heatmap (Module 5)
  • Data Cleaning β€” Imputation, Outlier Handling, Deduplication, String Normalization (Modules 6–8)
  • Feature Engineering β€” LabelEncoder, StandardScaler, per-column selection (Module 9)
  • Problem Selection β€” Classification / Regression / Clustering + target column (Module 10)
  • Model Training β€” 5 algorithms, 80/20 split (Modules 11–12)
  • Model Evaluation β€” Accuracy, RΒ², RMSE, Silhouette Score (Module 13)
  • Model Export β€” .pkl via joblib.dump(), served as file download (Module 14)

🀝 Contributing

Contributions are welcome. Fork the repo, create a feature branch, and open a pull request.

git checkout -b feature/your-feature-name
git commit -m "Add your feature"
git push origin feature/your-feature-name

πŸ“„ License

This project is open source and available under the MIT License.


πŸ‘€ Author

Utkarsh Verma

Shivang Verma


Built as part of an Industrial Training Project Β· 2026

About

No description, website, or topics provided.

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages