Skip to main content

🚀 MLPilot

Data In → Insights Out

A production-grade Python Machine Learning Library for tabular datasets that automatically performs EDA, preprocessing, model comparison, hyperparameter tuning, explainability, and exports a deployment-ready inference pipeline.

14+ Models · Auto EDA · Optuna · SHAP · CLI · Python API

Python Scikit-Learn Optuna SHAP License

One command. One pipeline. Production-ready models.


⚡ Quick Start

Install MLPilot:

pip install mlpilotx

Run your first ML pipeline:

mlpilot run --data examples/USA_Housing.csv

Specify the target column manually:

mlpilot run --data examples/USA_Housing.csv --target price

🔥 What MLPilot Does

Instead of writing hundreds of lines of boilerplate code, MLPilot automatically performs:

Stage Description
📂 Load CSV loading & validation
📊 EDA Statistics, missing values & correlations
🧹 Clean Duplicates, sparse columns & outlier handling
⚙️ Feature Engineering Encoding, scaling & transformations
✂️ Split Train / Test split
🔧 Preprocess Scikit-learn preprocessing pipeline
🏆 Compare 14+ Machine Learning models
🎯 Tune Bayesian optimization with Optuna
🔍 Explain SHAP feature importance & visualizations
📦 Export Deployment-ready .joblib pipeline

🔄 Pipeline Workflow

                 Raw Dataset
                      │
                      ▼
              📂 Load Dataset
                      │
                      ▼
            📊 Statistical EDA
                      │
                      ▼
              🧹 Data Cleaning
                      │
                      ▼
         ⚙️ Feature Engineering
                      │
                      ▼
           ✂️ Train / Test Split
                      │
                      ▼
        🔧 Preprocessing Pipeline
                      │
                      ▼
        🏆 Compare 14+ ML Models
                      │
                      ▼
     🎯 Optuna Hyperparameter Tuning
                      │
                      ▼
      🔍 SHAP Explainability Report
                      │
                      ▼
          📈 Model Evaluation
                      │
                      ▼
   📦 Export Production Pipeline (.joblib)

✨ Features

  • 📂 Automatic CSV support
  • 🤖 Automatic Regression & Classification detection
  • 📊 Smart Exploratory Data Analysis
  • 🧹 Missing value & outlier handling
  • ⚙️ Feature engineering pipeline
  • 🏆 Cross-validation model leaderboard
  • 🎯 Bayesian hyperparameter optimization
  • 🔍 SHAP explainability visualizations
  • 📦 Export complete inference pipeline
  • 💻 Rich CLI & Python API support

💻 CLI Usage

Automatic Training

mlpilot run --data examples/heart.csv

Regression

mlpilot run --data examples/USA_Housing.csv --target price

Classification

mlpilot run --data examples/patient_adherence_dataset.csv --target adherence

Custom Output Folder

mlpilot run --data data.csv --output outputs/

🐍 Python API

from ml_pilot import PipelineRunner
from ml_pilot.config import load_config

config = load_config()

runner = PipelineRunner(config)

context = runner.run(
    data_path="examples/USA_Housing.csv",
    target="price"
)

print(context.best_model_name)
print(context.metrics)

📁 Example Datasets

MLPilot includes ready-to-use datasets inside the examples/ folder.

Dataset Task
USA_Housing.csv Regression
insurance.csv Regression
heart.csv Classification
patient_adherence_dataset.csv Classification
Student_performance_data.csv Classification
Food_Delivery_Times.csv Regression
Exam_Score_Prediction.csv Regression
taxi_trip_pricing.csv Regression
personality_synthetic_dataset.csv Classification

Example:

mlpilot run --data examples/insurance.csv --target charges

📦 Generated Artifacts

Every successful run generates:

mlpilot_artifacts/
├── mlpilot_pipeline.joblib
├── leaderboard.csv
├── metrics.json
├── model_comparison.json
├── feature_importances.json
├── eda_report.json
├── run_metadata.json
├── serving_schema.json
├── predict_snippet.py
├── DEPLOY.md
└── shap/
    ├── shap_summary.png
    ├── shap_dependence_*.png
    └── shap_waterfall.png

🧠 Supported Models

Category Models
Linear Linear Regression, Ridge, Lasso, ElasticNet
Tree Decision Tree, Random Forest, Extra Trees
Boosting Gradient Boosting, HistGradientBoosting
Instance KNN, SVR
Neural MLP
Classification Logistic Regression, SGD, Linear SVC, Passive Aggressive

🧪 Edge Case Testing

MLPilot includes dedicated validation datasets.

tests/
└── edge_cases/
    ├── empty.csv
    ├── one_row.csv
    ├── all_null.csv
    ├── duplicate_col.csv
    ├── target_missing.csv
    ├── only_numeric.csv
    └── only_categorical.csv

Run an edge-case test:

mlpilot run --data tests/edge_cases/empty.csv

📂 Project Structure

MLPilot/
├── configs/
│   └── default.yaml
├── examples/
│   ├── USA_Housing.csv
│   ├── insurance.csv
│   ├── heart.csv
│   └── ...
├── src/
│   └── ml_pilot/
│       ├── cli.py
│       ├── config/
│       ├── core/
│       ├── stages/
│       └── utils/
├── tests/
│   ├── edge_cases/
│   ├── test_load.py
│   ├── test_pipeline_smoke.py
│   └── ...
├── LICENSE
├── README.md
└── pyproject.toml

🛠 Tech Stack

  • Python 3.12+
  • Scikit-learn
  • Pandas & NumPy
  • Optuna
  • SHAP
  • Typer + Rich
  • Joblib
  • Plotly

📄 License

This project is licensed under the MIT License.


⭐ If MLPilot helps your workflow, consider starring the repository!

Built with ❤️ by Aditya Sharma

Metadata

Release files for mlpilotx 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mlpilotx 0.1.2
File Size Uploaded
mlpilotx-0.1.2.tar.gz 5.9 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for mlpilotx 0.1.2
File Interpreter ABI Platform
mlpilotx-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 5.9 MB

Release files / mlpilotx-0.1.2.tar.gz

Download URL mlpilotx-0.1.2.tar.gz
Size 5.9 MB
Tags Source
SHA-256 checksum
How to use checksums
071c5ce7d0dfa6cef325bc236c0fb1b3c108ad375c258d73bf03edd94834d321
BLAKE2b-256 checksum
How to use checksums
68e42f506ffe36b74cc1ddc2ac788a2787628703dc878ef68236c7305261b686
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.0

Release files / mlpilotx-0.1.2-py3-none-any.whl

Download URL mlpilotx-0.1.2-py3-none-any.whl
Size 45.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5006d2c2536fa6d857a81a1e9d60f40ee9a0cba406bca9eacd3144df784100af
BLAKE2b-256 checksum
How to use checksums
9b25750deb1e9167d76476743043f6c1d480d9087660e7e30a438959034984e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.0

Release history Release notifications | RSS feed

0.1.3

2 release files

This release

0.1.2 This release

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page