skillfed

floret

floret Python bindings

floret v0.10.5 191.1K downloads/30d#9,890 on PyPI346
Permissive license MIT AGING released

What it is and what it does

floret is a Python binding for an extended fastText implementation that combines fastText's subword tokenization with Bloom embeddings (the "hashing trick") to produce word vectors in a compact hash table. Instead of storing every word and subword separately, floret uses a smaller, fixed-size table and distributes entries across multiple hash rows, reducing memory overhead while maintaining coverage for out-of-vocabulary words.

You train floret models using unsupervised learning (CBOW or skip-gram), configure the hash table size and row count via parameters like `bucket` and `hashCount`, and export vectors in standard or floret-specific formats. The package integrates directly with spaCy, allowing you to import trained floret vectors as spaCy language models. It retains all fastText functionality, so you can switch between standard fastText and floret modes by changing the `mode` parameter.

Use it for:

  • Train memory-efficient word embeddings for deployment on resource-constrained devices or large-scale NLP systems.
  • Generate embeddings for rare or misspelled words using subword information without storing full fastText vectors.
  • Integrate compact pre-trained vectors into spaCy pipelines for production NLP applications.
  • Reduce model size in production while maintaining out-of-vocabulary word coverage.
  • Experiment with Bloom hashing trade-offs (hash collisions vs. memory) for embedding quality tuning.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

floret trains compact word embeddings using fastText's subword approach combined with Bloom hashing, producing full-coverage vectors that work with spaCy and reduce memory footprint compared to standard fastText.

Yes, if you need compact word embeddings and are willing to work with an aging, Alpha-status package. The MIT license is permissive, install friction is manageable (precompiled wheels available), and there are no known vulnerabilities. However, verify that floret's memory savings and spaCy integration meet your production requirements before committing to it as a core dependency.

Install

floret on PyPI

pip

pip install floret

uv

uv add floret

poetry

poetry add floret

Installing floret

Before you install

Medium install friction: compiled wheels available for Python 3.6–3.12 across macOS, Linux, and Windows, but requires numpy. Package is aging (last release 2023-11-04, status: Alpha), though the repository remains active.

License in practice

MIT license is permissive; you can use, modify, and distribute floret freely in commercial and private projects with minimal restrictions.

Quickstart

pip install floret

import floret

model = floret.train_unsupervised(
    "data.txt",
    model="cbow",
    mode="floret",
    hashCount=2,
    bucket=50000
)
vector = model.get_word_vector("word")

Requires numpy; compiled extension, so platform-specific wheels must match your Python version and architecture.

Verify before relying

  • Whether floret's memory savings over fastText are quantified or measurable for typical use cases.
  • Current performance or adoption in production NLP pipelines beyond spaCy integration.
  • Whether the Alpha status reflects stability concerns or simply incomplete feature coverage.

Package facts

License MIT (permissive)
Python support not specified
Install friction medium — platform-specific wheel
Runtime dependencies 1 — numpy
Maintenance aging — 1,014 days since the last release
Last repo commit
First released
Downloads 191,118/month — #9,890 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: floret-0.10.5-cp310-cp310-macosx_11_0_arm64.whl; floret-0.10.5-cp310-cp310-macosx_11_0_x86_64.whl; floret-0.10.5-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; floret-0.10.5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; floret-0.10.5-cp310-cp310-win_amd64.whl; floret-0.10.5-cp311-cp311-macosx_11_0_arm64.whl; floret-0.10.5-cp311-cp311-macosx_11_0_x86_64.whl; floret-0.10.5-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; floret-0.10.5-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; floret-0.10.5-cp311-cp311-win_amd64.whl; floret-0.10.5-cp312-cp312-macosx_11_0_arm64.whl; floret-0.10.5-cp312-cp312-macosx_11_0_x86_64.whl; floret-0.10.5-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; floret-0.10.5-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; floret-0.10.5-cp312-cp312-win_amd64.whl; floret-0.10.5-cp36-cp36m-macosx_10_16_x86_64.whl; floret-0.10.5-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; floret-0.10.5-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; floret-0.10.5-cp36-cp36m-win_amd64.whl; floret-0.10.5-cp37-cp37m-macosx_10_16_x86_64.whl

Development Status :: 3 - AlphaIntended Audience :: DevelopersIntended Audience :: Science/ResearchLicense :: OSI Approved :: MIT LicenseOperating System :: MacOSOperating System :: Microsoft :: WindowsOperating System :: POSIXOperating System :: UnixProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: Scientific/EngineeringTopic :: Software Development

Tags

word embeddings fasttextcompact vector representationsbloom hashing embeddingssubword embeddings trainingspacy vector integrationmemory-efficient word vectorsfasttext bloom filter
embeddingsnlpmemory-efficient

More Software Development packages