Metadata-Version: 2.4
Name: kaizenstat
Version: 0.2.0
Summary: Zero-friction AutoML + Data Cleaning Toolkit
Author: Masuddar Rahman
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Requires-Dist: pandas
Requires-Dist: numpy
Requires-Dist: scikit-learn
Requires-Dist: rich
Requires-Dist: joblib
Provides-Extra: ui
Requires-Dist: streamlit; extra == "ui"
Provides-Extra: gpu
Requires-Dist: xgboost; extra == "gpu"
Provides-Extra: fast
Requires-Dist: polars; extra == "fast"
Provides-Extra: all
Requires-Dist: streamlit; extra == "all"
Requires-Dist: xgboost; extra == "all"
Requires-Dist: polars; extra == "all"
Dynamic: author
Dynamic: description
Dynamic: description-content-type
Dynamic: provides-extra
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# 🚀 KaizenStat

[![PyPI Version](https://img.shields.io/pypi/v/kaizenstat.svg)](https://pypi.org/project/kaizenstat/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Python Version](https://img.shields.io/badge/python-3.8%2B-blue.svg)](https://www.python.org/downloads/)

**KaizenStat** is a zero-friction data validation, automatic cleaning, and AutoML benchmarking toolkit. Diagnose datasets instantly, auto-repair issues, train baseline models, generate standalone Python code, and launch interactive dashboards — all in one command.

---

## ✨ Features

| Command | What it does |
|---|---|
| `kz audit` | 🔍 Diagnostic sweep — duplicates, NaNs, infs, ID columns, imbalance |
| `kz heal` | 🩹 Auto-clean — impute, deduplicate, drop dead columns |
| `kz benchmark` | 🚀 Train & rank ML models with cross-validation |
| `kz auto` | ⚡ Full pipeline in one command (audit → heal → benchmark) |
| `kz explain` | 💬 Plain-English summary of findings and recommendations |
| `kz codegen` | 📝 Generate a standalone Python training script |
| `kz export-model` | 💾 Train best model and save to `.joblib` |
| `kz report` | 📊 Generate interactive HTML report with charts |
| `kz serve` | 🌐 Launch interactive Streamlit web dashboard |

---

## 📦 Installation

```bash
pip install kaizenstat
```

**Optional extras:**

```bash
pip install kaizenstat[ui]     # + Streamlit dashboard
pip install kaizenstat[gpu]    # + XGBoost GPU support
pip install kaizenstat[fast]   # + Polars fast data loading
pip install kaizenstat[all]    # everything
```

---

## 🚀 Quick Start

### Python API

```python
from kaizenstat import KaizenStat

# Full pipeline in one call
KaizenStat.auto("data.csv", target="price")

# Or step-by-step
import pandas as pd
df = pd.read_csv("data.csv")

KaizenStat.audit(df, target="price")
df_clean = KaizenStat.heal(df, target="price")
results = KaizenStat.benchmark(df_clean, target="price")
```

### 💬 Get a Plain-English Explanation

```python
KaizenStat.explain("data.csv", target="price")
```

### 📝 Generate Standalone Code

```python
KaizenStat.codegen("data.csv", target="price", output_path="deploy.py")
```

### 💾 Export & Load Models

```python
# Train + save
KaizenStat.auto("data.csv", target="price")
KaizenStat.save_model(path="model.joblib")

# Load later
pipeline = KaizenStat.load_model("model.joblib")
predictions = pipeline.predict(new_data)
```

### 📊 Generate HTML Report

```python
KaizenStat.report("data.csv", target="price", output_path="report.html")
```

### 🌐 Launch Web Dashboard

```python
KaizenStat.serve("data.csv", target="price")
```

---

## 💻 CLI Usage

```bash
# Diagnostic sweep
kz audit data.csv --target price

# Auto-clean dataset
kz heal data.csv --target price -o clean.csv

# Train & rank models
kz benchmark clean.csv --target price

# Full pipeline
kz auto data.csv --target price

# Plain-English summary
kz explain data.csv --target price

# Generate standalone Python script
kz codegen data.csv --target price -o deploy.py

# Train best model and export
kz export-model data.csv --target price -o model.joblib

# Generate interactive HTML report
kz report data.csv --target price -o report.html

# Launch web dashboard
kz serve data.csv --target price
```

---

## 🛠 Development

```bash
git clone https://github.com/yourusername/kaizenstat.git
cd kaizenstat
pip install -e ".[all]"
```

---

## 📄 License

Distributed under the MIT License.
