Skip to main content

KrishnAutoML

PyPI version Build Status License

KrishnAutoML is a lightweight, beginner-friendly, and production-ready AutoML library for tabular data.
It automates the end-to-end machine learning workflow with minimal user input, while keeping things modular and extensible.


Features

  • Load data from CSV or Pandas DataFrame
  • Automatic problem type detection (classification or regression)
  • Smart preprocessing (missing values, categorical encoding, scaling)
  • Optional EDA reports for insights
  • Train multiple models (LightGBM, XGBoost, CatBoost, Scikit-Learn)
  • Automated model selection and hyperparameter tuning (Optuna / GridSearchCV)
  • Flexible cross-validation (KFold, StratifiedKFold, GroupKFold)
  • Multiple evaluation metrics dynamically
  • Early stopping and GPU support
  • Save models + reproducible pipeline code
  • Auto-generated reports in HTML/Markdown

Installation

From PyPI (after publishing):

pip install krishnautoml

From source:

git clone https://github.com/knight22-21/KrishnAutoML.git
cd KrishnAutoML
pip install -e .[dev]

Quick Start

Python API

from krishnautoml import KrishnAutoML

# Initialize AutoML
automl = KrishnAutoML(target="Survived", problem_type="auto")

# Full pipeline
(
    automl
    .load_data("data/titanic.csv")
    .preprocess()
    .train_models()
    .evaluate()
    .save_model("best_model.pkl")
)

print("Best model metrics:", automl.best_score)

Command Line Interface (CLI)

krishnautoml fit --data data/titanic.csv --target Survived --report

This will:

  • Train models
  • Save best_model.pkl
  • Generate an HTML performance report

Example Output

Metrics (Classification example):

{'accuracy': 0.8567, 'precision': 0.8421, 'recall': 0.8312, 'f1': 0.8350}

Generated Report:

  • Confusion matrix
  • Feature importance
  • ROC-AUC curve
  • Summary of preprocessing steps

Advanced Usage

  • Custom cross-validation:
automl = KrishnAutoML(target="SalePrice", cv_strategy="KFold", n_splits=10)
  • Specify metrics:
automl = KrishnAutoML(target="Survived", metrics=["accuracy", "f1"])
  • Load trained model:
from joblib import load
model = load("best_model.pkl")

Development

Clone and install dev dependencies:

git clone https://github.com/knight22-21/KrishnAutoML.git
cd KrishnAutoML
pip install -e .[dev]

Run tests:

pytest

Lint & format:

flake8 krishnautoml
black krishnautoml

License

MIT License © 2025 \Krishna Tyagi


Contributing

Contributions are welcome!

  • Fork the repo
  • Create a feature branch
  • Submit a PR

Acknowledgements

Release files for krishnautoml 1.0.8

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

Source distribution (sdist)

Source distribution for krishnautoml 1.0.8
File Size Uploaded
krishnautoml-1.0.8.tar.gz 17.9 kB Details

Built distribution (wheel)

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

Total release size: 38.4 kB

Release files / krishnautoml-1.0.8.tar.gz

Download URL krishnautoml-1.0.8.tar.gz
Size 17.9 kB
Tags Source
SHA-256 checksum
How to use checksums
9eb3e9c271a12b57a92e83af63fa3a39bdd2b7802c9ba88d70f2e7b680e4a629
BLAKE2b-256 checksum
How to use checksums
2bb3ef9c36ee7ec97d74da6efff7f97a8ececea8b033e991fb97b4651cd8604a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.3

Release files / krishnautoml-1.0.8-py3-none-any.whl

Download URL krishnautoml-1.0.8-py3-none-any.whl
Size 20.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6c3676117035e5fa09c3464cce5e505ec3b9d3874dec9014574dac22afceb44a
BLAKE2b-256 checksum
How to use checksums
df42f5ce14891a6f6c499543c03bf70802b962fe9d2bcdcbeb35f7e5ab617eb7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.3

Release history Release notifications | RSS feed

This release

1.0.8 This release

2 release files

1.0.7

2 release files

1.0.6

2 release files

1.0.5

2 release files

1.0.4

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

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