Make MLOps easier with an AI-powered framework
Project description
Easy MLOps
Make MLOps easier with an AI-powered framework that abstracts all phases of an MLOps pipeline.
Overview
Easy MLOps is a comprehensive framework that simplifies the entire machine learning operations pipeline. With a single command, you can:
- Data Preprocessing: Automatic handling of missing values, feature scaling, and categorical encoding
- Model Training: Intelligent model selection and hyperparameter tuning
- Model Deployment: Automated model packaging and endpoint creation
- Model Observability: Built-in monitoring, logging, and performance tracking
Installation
From Source
git clone https://github.com/umbertocicciaa/easy-mlops.git
cd easy-mlops
pip install -e .
Using pip (once published)
pip install easy-mlops
Using Docker
Build the image locally and expose the CLI:
docker build -t easy-mlops .
docker run --rm easy-mlops --help
Mount data and persist model artifacts by binding host directories:
docker run --rm \
-v "$(pwd)/data:/data" \
-v "$(pwd)/models:/app/models" \
easy-mlops train /data/dataset.csv --target price
The container entrypoint is easy-mlops, so any CLI subcommand can be passed as usual.
Quick Start
1. Train a Model
Train a machine learning model with a single command:
easy-mlops train data.csv --target price
This will:
- Load and preprocess your data
- Automatically detect the problem type (classification/regression)
- Train an appropriate model
- Deploy the model with all artifacts
- Set up monitoring and logging
2. Make Predictions
Use your deployed model to make predictions:
easy-mlops predict new_data.csv models/deployment_20240101_120000
3. Check Model Status
Get information about your deployed model:
easy-mlops status models/deployment_20240101_120000
4. View Observability Reports
Generate detailed monitoring reports:
easy-mlops observe models/deployment_20240101_120000
CLI Commands
easy-mlops train
Train a machine learning model on your data.
Usage:
easy-mlops train DATA_PATH [OPTIONS]
Options:
-t, --target TEXT: Name of the target column-c, --config PATH: Path to configuration file (YAML)--no-deploy: Skip deployment step (only train the model)
Examples:
# Basic training
easy-mlops train data.csv --target label
# With custom configuration
easy-mlops train data.json -t price -c config.yaml
# Train without deploying
easy-mlops train data.csv --target label --no-deploy
easy-mlops predict
Make predictions using a deployed model.
Usage:
easy-mlops predict DATA_PATH MODEL_DIR [OPTIONS]
Options:
-c, --config PATH: Path to configuration file (YAML)-o, --output PATH: Output file for predictions (JSON format)
Examples:
# Basic prediction
easy-mlops predict new_data.csv models/deployment_20240101_120000
# Save predictions to file
easy-mlops predict data.json models/latest -o predictions.json
easy-mlops status
Get status and metrics for a deployed model.
Usage:
easy-mlops status MODEL_DIR [OPTIONS]
Options:
-c, --config PATH: Path to configuration file (YAML)
Example:
easy-mlops status models/deployment_20240101_120000
easy-mlops observe
Generate observability report for a deployed model.
Usage:
easy-mlops observe MODEL_DIR [OPTIONS]
Options:
-c, --config PATH: Path to configuration file (YAML)-o, --output PATH: Output file for the report
Examples:
# View report in terminal
easy-mlops observe models/deployment_20240101_120000
# Save report to file
easy-mlops observe models/latest -o report.txt
easy-mlops init
Initialize a new MLOps project with default configuration.
Usage:
easy-mlops init [OPTIONS]
Options:
-o, --output PATH: Output path for the configuration file (default: mlops-config.yaml)
Example:
easy-mlops init -o my-config.yaml
Configuration
Easy MLOps uses YAML configuration files to customize behavior. Generate a default configuration:
easy-mlops init
Configuration Structure
preprocessing:
handle_missing: drop # Options: drop, mean, median, mode
scale_features: true
encode_categorical: true
training:
test_size: 0.2
random_state: 42
cv_folds: 5
model_type: auto # Options: auto, random_forest_classifier, random_forest_regressor, logistic_regression, linear_regression
deployment:
output_dir: ./models
save_format: joblib
create_endpoint: false
observability:
track_metrics: true
log_predictions: true
alert_threshold: 0.8
Features
Automatic Data Preprocessing
- Missing Value Handling: Multiple strategies (drop, mean, median, mode)
- Feature Scaling: StandardScaler for numerical features
- Categorical Encoding: Automatic label encoding for categorical variables
- Multiple Format Support: CSV, JSON, and Parquet files
Intelligent Model Training
- Problem Type Detection: Automatically detects classification vs regression
- Model Selection: Chooses appropriate algorithms based on your data
- Cross-Validation: Built-in k-fold cross-validation
- Performance Metrics: Comprehensive metrics for model evaluation
Streamlined Deployment
- Model Artifacts: Saves model, preprocessor, and metadata
- Versioning: Timestamped deployments for easy tracking
- Endpoint Creation: Optional prediction endpoint script generation
- Reproducibility: All components saved for consistent predictions
Built-in Observability
- Metrics Tracking: Automatic logging of model performance metrics
- Prediction Logging: Track all predictions for analysis
- Performance Monitoring: Detect metric degradation over time
- Reporting: Generate detailed monitoring reports
Supported Data Formats
- CSV (
.csv) - JSON (
.json) - Parquet (
.parquet)
Supported Model Types
Classification
- Random Forest Classifier
- Logistic Regression
Regression
- Random Forest Regressor
- Linear Regression
Project Structure
easy-mlops/
├── easy_mlops/
│ ├── __init__.py
│ ├── cli.py # CLI interface
│ ├── pipeline.py # Main pipeline orchestrator
│ ├── config/ # Configuration management
│ ├── preprocessing/ # Data preprocessing
│ ├── training/ # Model training
│ ├── deployment/ # Model deployment
│ └── observability/ # Model monitoring
├── pyproject.toml
├── requirements.txt
└── README.md
Requirements
- Python >= 3.8
- click >= 8.0.0
- pandas >= 1.3.0
- scikit-learn >= 1.0.0
- joblib >= 1.0.0
- pyyaml >= 6.0
- rich >= 10.0.0
Development
Running Tests
pytest
Code Formatting
black easy_mlops/
Documentation
Project documentation is powered by MkDocs and the Material theme. Source files live in docs/, and the site configuration is mkdocs.yml.
# Serve docs locally (http://localhost:8000)
make docs-serve
# Build static site into site/
make docs-build
The GitHub Actions workflow .github/workflows/docs.yml automatically builds and deploys the site to GitHub Pages on pushes to main. Enable GitHub Pages in the repository settings (source: “GitHub Actions”). For manual publishing or previews outside CI, run:
make docs-deploy
Type Checking
mypy easy_mlops/
License
MIT License
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Author
Umberto Ciccia
Links
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file make_mlops_easy-0.1.0.tar.gz.
File metadata
- Download URL: make_mlops_easy-0.1.0.tar.gz
- Upload date:
- Size: 22.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8cdbe02668c0dd83488d681d9c3f50f3b9b2a9fe960e972dab6f1a48d70d6d4e
|
|
| MD5 |
34bccad42db6170693563fc04bcd14ca
|
|
| BLAKE2b-256 |
a2ec4f293dc4aca4997685a78bf1a825813964e18b88a834b921e2b9793ed488
|
Provenance
The following attestation bundles were made for make_mlops_easy-0.1.0.tar.gz:
Publisher:
publish.yml on umbertocicciaa/easy-mlops
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
make_mlops_easy-0.1.0.tar.gz -
Subject digest:
8cdbe02668c0dd83488d681d9c3f50f3b9b2a9fe960e972dab6f1a48d70d6d4e - Sigstore transparency entry: 603754141
- Sigstore integration time:
-
Permalink:
umbertocicciaa/easy-mlops@d1335f8c34f982e36b9cd25e5932a7cb740bf3d2 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/umbertocicciaa
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d1335f8c34f982e36b9cd25e5932a7cb740bf3d2 -
Trigger Event:
release
-
Statement type:
File details
Details for the file make_mlops_easy-0.1.0-py3-none-any.whl.
File metadata
- Download URL: make_mlops_easy-0.1.0-py3-none-any.whl
- Upload date:
- Size: 20.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
99567e93fe4608fa385889d14750d474e46d34ec2f685a21ef2299589ab50268
|
|
| MD5 |
af55525af32da1e30a0e21daf23dd947
|
|
| BLAKE2b-256 |
c506a423b14810bc2df88edb5aed75a9badff84226093a85d9692ff8db3ae8d7
|
Provenance
The following attestation bundles were made for make_mlops_easy-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on umbertocicciaa/easy-mlops
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
make_mlops_easy-0.1.0-py3-none-any.whl -
Subject digest:
99567e93fe4608fa385889d14750d474e46d34ec2f685a21ef2299589ab50268 - Sigstore transparency entry: 603754194
- Sigstore integration time:
-
Permalink:
umbertocicciaa/easy-mlops@d1335f8c34f982e36b9cd25e5932a7cb740bf3d2 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/umbertocicciaa
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d1335f8c34f982e36b9cd25e5932a7cb740bf3d2 -
Trigger Event:
release
-
Statement type: