fklearn uses functional programming principles to make it easier to solve real problems with Machine Learning.
The name is a reference to the widely known scikit-learn library.
fklearn Principles
- Validation should reflect real-life situations.
- Production models should match validated models.
- Models should be production-ready with few extra steps.
- Reproducibility and in-depth analysis of model results should be easy to achieve.
Documentation | Getting Started | API Docs | Contributing |
To install via pip:
pip install fklearn
To install with optional dependencies:
pip install fklearn[lgbm] # LightGBM support
pip install fklearn[xgboost] # XGBoost support
pip install fklearn[catboost] # CatBoost support
pip install fklearn[all_models] # All model backends
pip install fklearn[all] # All models + tools
fklearn uses uv for dependency management. uv sync
creates a virtual environment, installs all locked dependencies, and installs
fklearn itself in editable mode (the default for uv projects) so changes
under src/ are picked up without reinstalling.
uv sync # core deps + dev group
uv sync --all-extras # also installs lgbm / xgboost / catboost / tools / demos / docsThe dev dependency group (pytest, ruff, mypy, hypothesis) is included by
default via tool.uv.default-groups, so uv sync alone is enough for most
development workflows.
uv run pytest --cov=src/uv run ruff check src/ tests/
uv run ruff format src/ tests/uv add <package-name> # runtime dependency
uv add --dev <package-name> # dev dependencyRegenerate the lockfile with --default-index https://pypi.org/simple/:
uv lock --default-index https://pypi.org/simple/