MLFCrafter is a Python library designed to simplify the process of creating machine learning pipelines. By allowing for the integration of various data processing, training, and deployment steps, it enables users to develop production-ready ML workflows quickly and efficiently, minimizing code and maximizing productivity.
MLFCrafter is a Python framework that simplifies machine learning pipeline creation through chainable "crafter" components. Build, train, and deploy ML models with minimal code and maximum flexibility.
Writing the same ML boilerplate again and again is exhausting — especially when juggling multiple datasets or experimenting with different models. MLFCrafter was created to solve exactly that.
Here’s why MLFCrafter might be the right tool for you:
✅ Automation without Black Box: You automate repetitive steps, but still keep visibility and control over each stage.
✅ Modular by Design: You can run only the steps you need. Don't want automatic data cleaning ? Just skip CleanerCrafter and plug in your own function.
✅ Readable & Reusable: The API is simple, clean, and built for easy experimentation and reproducibility.
✅ Scikit-learn Compatible: Use your favorite tools and estimators within the pipeline.
✅ Open for Extension: You can build your own custom crafters if needed.
✅ Easy to Learn: MLFCrafter’s intuitive API and clear component structure make it approachable even for users with basic machine learning knowledge. You don’t need to dive deep into complex frameworks to start building.
Complete documentation is available at MLFCrafter Docs
pip install mlfcrafter
from mlfcrafter import MLFChain, DataIngestCrafter, CleanerCrafter, ScalerCrafter, ModelCrafter, ScorerCrafter, DeployCrafter
# Create ML pipeline in one line
chain = MLFChain(
DataIngestCrafter(data_path="data/iris.csv"),
CleanerCrafter(strategy="auto"),
ScalerCrafter(scaler_type="standard"),
ModelCrafter(model_name="random_forest"),
ScorerCrafter(),
DeployCrafter()
)
# Run entire pipeline
results = chain.run(target_column="species")
print(f"Test Score: {results['test_score']:.4f}")
git clone https://github.com/brkcvlk/mlfcrafter.git
cd mlfcrafter
pip install -r requirements-dev.txt
pip install -e .
# Run all tests
python -m pytest tests/ -v
# Run tests with coverage
python -m pytest tests/ -v --cov=mlfcrafter --cov-report=html
# Check code quality
ruff check .
# Auto-fix code issues
ruff check --fix .
# Format code
ruff format .
python example.py
We welcome contributions! Please see our Contributing Guidelines for details.
This project is licensed under the MIT License - see the LICENSE file for details.
Made for the ML Community
No comments yet.
Sign in to be the first to comment.