Skip to main content

A lightweight, zero-infrastructure feature store for machine learning.

Project description

FTLite

A lightweight, zero-infrastructure feature store for machine learning.

FTLite is an open-source Python library that makes feature management simple without requiring Kubernetes, Spark, Redis, or cloud infrastructure. It focuses on one thing that matters most for production ML: point-in-time correct feature retrieval.

Whether you're training a churn model, fraud detector, recommendation system, or forecasting pipeline, FTLite helps ensure your training features match what would have been available at prediction time—preventing data leakage while keeping the developer experience simple.


Why FTLite?

Modern feature stores are powerful, but often require significant infrastructure and operational overhead.

FTLite is designed for:

  • Individual developers
  • Researchers
  • Students
  • Startups
  • Small ML teams
  • Local-first workflows

No servers.

No Kubernetes.

No metadata databases.

Just Python.


Features

  • Lightweight feature definitions
  • Point-in-time correct historical feature retrieval
  • Offline feature store powered by DuckDB + Parquet
  • Online feature store powered by SQLite
  • Zero infrastructure setup
  • Local feature registry
  • Simple Python API
  • Fast local development
  • Type hints and clean API design

Architecture

                    +----------------+
                    |  Raw Features  |
                    +----------------+
                            |
                            v
                    +----------------+
                    | Offline Store  |
                    | DuckDB/Parquet |
                    +----------------+
                            |
          Historical        | Materialize
         Feature Joins      v
                    +----------------+
                    | Online Store   |
                    |    SQLite      |
                    +----------------+
                            |
                            v
                      Model Inference

Project Structure

ftlite/
│
├── ftlite/
│   ├── __init__.py
│   ├── feature.py          # Entity, Feature, FeatureView, OnDemandFeatureView
│   ├── offline_store.py    # DuckDB + temporal ASOF joins
│   ├── online_store.py     # SQLite online serving store
│   ├── registry.py         # tracks and persists metadata
│   ├── ingestion.py        # appends features to Parquet files
│   ├── client.py           # main FtliteClient orchestrator
│   └── cli.py              # CLI entry point
│
├── tests/
│   ├── __init__.py
│   └── test_client.py
│
├── examples/
│   └── churn_example/
│       ├── __init__.py
│       ├── generate_data.py
│       └── run_churn_store.py
│
├── docs/
│   └── index.md
│
├── pyproject.toml
├── README.md
└── LICENSE

Installation

pip install ftlite

Or install from source:

git clone https://github.com/<your-username>/ftlite.git

cd ftlite

pip install -e .

Quick Example

Define and Register Entity & Features

from ftlite import Entity, Feature, FeatureView, FtliteClient

# Initialize client
client = FtliteClient()

# Define Entity
customer = Entity(
    name="customer_id",
    value_type="INT64"
)
client.register_entity(customer)

# Define Features and FeatureView
age = Feature(name="age", dtype="int32")
balance = Feature(name="balance", dtype="float64")

fv = FeatureView(
    name="customer_fv",
    entities=[customer],
    features=[age, balance],
    source_path="data/customer_features.parquet",
    timestamp_field="timestamp"
)
client.register_feature_view(fv)

Historical Features (Point-in-Time Join)

# Join historical features to observation entity data
historical_df = client.get_historical_features(
    entity_df=entity_df,
    features=[
        "customer_fv:age",
        "customer_fv:balance"
    ],
    timestamp_col="timestamp"
)

Online Features (Low-Latency Serving)

# Retrieve online features for real-time predictions
online_features = client.get_online_features(
    entity_keys=[1001],
    features=[
        "customer_fv:age",
        "customer_fv:balance"
    ]
)

Roadmap

Phase 1

  • Entity definitions
  • Feature definitions
  • Local registry

Phase 2

  • Offline feature store
  • Historical feature retrieval
  • Point-in-time joins
  • Training dataset generation

Phase 3

  • SQLite online store
  • Materialization
  • Online inference API

Phase 4

  • CLI
  • Better documentation
  • Real-world examples
  • Type hints
  • Unit tests

Phase 5

  • Redis backend
  • Feature transformations
  • Feature validation
  • Versioning
  • PyPI release

Design Goals

  • Lightweight
  • Local-first
  • Easy to understand
  • Zero infrastructure
  • Production-friendly
  • Strong correctness guarantees
  • Great developer experience

Tech Stack

Component Technology
Language Python
Offline Store DuckDB
Storage Parquet
Online Store SQLite
Testing Pytest
Formatting Ruff + Black
CI GitHub Actions

Example Use Cases

  • Customer churn prediction
  • Fraud detection
  • Recommendation systems
  • Credit risk modeling
  • Demand forecasting
  • Time-series feature engineering

Contributing

Contributions are welcome!

If you'd like to contribute:

  1. Fork the repository
  2. Create a feature branch
  3. Commit your changes
  4. Open a Pull Request

Please make sure all tests pass before submitting.


Vision

FTLite aims to become the simplest feature store for Python.

Instead of managing infrastructure, developers should spend their time building better machine learning models.


License

MIT License.


⭐ Support the Project

If you find FTLite useful, please consider giving the repository a ⭐ on GitHub. It helps others discover the project and supports future development.

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

ftlite-0.1.2.tar.gz (17.2 kB view details)

Uploaded Source

Built Distribution

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

ftlite-0.1.2-py3-none-any.whl (16.3 kB view details)

Uploaded Python 3

File details

Details for the file ftlite-0.1.2.tar.gz.

File metadata

  • Download URL: ftlite-0.1.2.tar.gz
  • Upload date:
  • Size: 17.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ftlite-0.1.2.tar.gz
Algorithm Hash digest
SHA256 0e9a87f13149f216dd8c88a905dadbd000c59403aad80b69022f6130376eaa69
MD5 41f7614e79ef68e2a0cd05112266c0fe
BLAKE2b-256 37e6895dce150b3d62ea3399fbbf9a249e48689d6b41585c78f3d32594509e46

See more details on using hashes here.

Provenance

The following attestation bundles were made for ftlite-0.1.2.tar.gz:

Publisher: publish.yml on chinmay1182/ftlite

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ftlite-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: ftlite-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 16.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ftlite-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3ca2c343b1e55fc653d70dbb45dd05cb6d5e99a3159a60b97d942b2a8b41bcf1
MD5 a901cb2a0770f29038e1691afc66057c
BLAKE2b-256 ffcc3ac81eef8fd4bc2fc7b9f01d0f8f739b90b07766128bc52f60a1e2824c93

See more details on using hashes here.

Provenance

The following attestation bundles were made for ftlite-0.1.2-py3-none-any.whl:

Publisher: publish.yml on chinmay1182/ftlite

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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