Skip to main content

Composable sklearn-compatible pipeline builder for feature engineering, validation, resampling, and monitoring.

Project description

skpipeline-forge

skpipeline-forge is a composable, sklearn-compatible pipeline builder for tabular ML workflows.

It helps you define reusable transformation stacks as objects, then apply them consistently across:

  • training
  • scoring
  • optional imbalance handling
  • monitoring/reporting hooks

Install

pip install skpipeline-forge

Quickstart

from pipeline_forge import FeaturePipelineBuilder

builder = FeaturePipelineBuilder(target_col="target", random_seed=42)

(
    builder
    .validate_schema(required_cols=["city", "hour", "age", "balance"], strict=False)
    .group_rare_categories(categorical_cols=["city"], min_freq=0.02)
    .target_encode(categorical_cols=["city"], drop_original=True)
    .encode_cyclical_time(period_map={"hour": 24})
    .add_interaction_features(numeric_cols=["age", "balance"])
    .scaler("robust")
    .random_oversampling(sampling_strategy=1.0)
)

builder.build_pipeline()

What You Get

  • Fluent API for chaining transformations
  • sklearn/imblearn-compatible pipelines
  • Feature engineering + resampling in one object
  • Extra pipeline layers for validation, selection, postprocessing, monitoring, explainability
  • Built-in common transformers for tabular data

Documentation

Package Notes

  • Python: >=3.10,<4.0
  • Main runtime deps: scikit-learn, imbalanced-learn, pandas, numpy, mlflow, prophet
  • Tests: pytest

Development

poetry install --with dev
poetry run pytest -q
poetry build

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

skpipeline_forge-1.0.0.tar.gz (24.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

skpipeline_forge-1.0.0-py3-none-any.whl (31.9 kB view details)

Uploaded Python 3

File details

Details for the file skpipeline_forge-1.0.0.tar.gz.

File metadata

  • Download URL: skpipeline_forge-1.0.0.tar.gz
  • Upload date:
  • Size: 24.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.2 CPython/3.12.3 Linux/6.17.0-14-generic

File hashes

Hashes for skpipeline_forge-1.0.0.tar.gz
Algorithm Hash digest
SHA256 c647ad1c89937ee2d44a00b308ea833af06d30af6ad8d2f52f16efd24fbbf71f
MD5 5b86ebbd1c9ffe68c96b48c0d179166e
BLAKE2b-256 d07bc329e816cabee3e6f0870c08f18ded6c44cb0c8433cd3c7cbbd62041fd41

See more details on using hashes here.

File details

Details for the file skpipeline_forge-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: skpipeline_forge-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 31.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.2 CPython/3.12.3 Linux/6.17.0-14-generic

File hashes

Hashes for skpipeline_forge-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2a8a25adb59d7e5cff676bf96419c421dce96787e6a473c7c421c9d128708a4b
MD5 bac272e242a55da91dce31a0fe8d76b9
BLAKE2b-256 62d2d57dd9df71d59cb4275107d53a9bd3a4705817e72f2df3205a749b6274c2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page