← all repositories
qdrant/quaterion

Similarity learning that fits on a laptop GPU

Quaterion exists to make fine-tuning embedding models for semantic search and recommendations fast enough to run on a laptop GPU, even with small datasets.

662 stars Python ML FrameworksRAG · Search
quaterion
Not currently ranked — collecting fresh signals.
star history

What it does

Quaterion is a PyTorch Lightning-based framework for fine-tuning similarity learning models. It targets the gap between generic pre-trained models and specialized tasks like semantic search, recommendations, or anomaly detection. The framework keeps training lightweight by caching embeddings and providing customizable head layers, so you don’t need to retrain a massive backbone from scratch.

The interesting bit

The framework splits itself into two packages—quaterion for training and quaterion-models for inference—to keep production dependencies slim. It also explicitly supports ONNX export, though the README admits that isn’t always convenient.

Key highlights

  • Built-in embedding cache that claims to enable huge batch sizes and “thousands of epochs” on laptop GPUs
  • Small-data-friendly head layers designed to adapt pre-trained backbones with minimal labeled data
  • Modular architecture: swap out encoders, heads, or losses for “large-scale and sophisticated training pipelines”
  • Separates training and inference into two packages to avoid dragging heavy PyTorch dependencies into production
  • Ships with tutorials for NLP (Q&A), computer vision (similar cars), and advanced topics like vector collapse prevention

Caveats

  • The framework splits into two packages (quaterion and quaterion-models), so you’ll need to juggle training and inference dependencies separately.
  • Speed claims (“thousands of epochs on a laptop GPU”) are qualitative; the README doesn’t provide benchmarks or hardware specifics.
  • ONNX export is supported, but the README notes it “is not always possible or convenient” for every model.

Verdict

Worth exploring if you’re fine-tuning embeddings for semantic search, recommendations, or anomaly detection and want PyTorch Lightning’s scaffolding plus a built-in caching shortcut. Less compelling if you need hard performance numbers or guaranteed ONNX portability for every architecture.

Frequently asked

What is qdrant/quaterion?
Quaterion exists to make fine-tuning embedding models for semantic search and recommendations fast enough to run on a laptop GPU, even with small datasets.
Is quaterion open source?
Yes — qdrant/quaterion is open source, released under the Apache-2.0 license.
What language is quaterion written in?
qdrant/quaterion is primarily written in Python.
How popular is quaterion?
qdrant/quaterion has 662 stars on GitHub.
Where can I find quaterion?
qdrant/quaterion is on GitHub at https://github.com/qdrant/quaterion.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.