all-MiniLM-L6-v2
by sentence-transformers
Fast, lightweight sentence embeddings for semantic similarity
sentence-transformers/all-MiniLM-L6-v2mixpeek://text_extractor@v1/st_minilm_l6_v2Overview
all-MiniLM-L6-v2 is a compact sentence embedding model that maps sentences and paragraphs to a 384-dimensional dense vector space. Despite its small size, it achieves strong performance on semantic textual similarity benchmarks.
On Mixpeek, MiniLM is the fastest text embedding option, ideal for real-time search and high-throughput indexing where speed matters more than maximum embedding quality.
Architecture
MiniLM-L6 distilled from a larger teacher model. 6 transformer layers, 384-dim hidden size. Uses mean pooling over token embeddings. Fine-tuned on 1B+ sentence pairs.
Mixpeek SDK Integration
import { Mixpeek } from "mixpeek";const mx = new Mixpeek({ apiKey: "API_KEY" });await mx.collections.ingest({collection_id: "my-collection",source: { url: "https://example.com/document.pdf" },feature_extractors: [{name: "text_embedding",version: "v1",params: {model_id: "sentence-transformers/all-MiniLM-L6-v2"}}]});
Capabilities
- 384-dimensional sentence embeddings
- 5x faster inference than BERT-base
- Strong semantic similarity performance
- Compact model size (80MB)
Use Cases on Mixpeek
Benchmarks
| Dataset | Metric | Score | Source |
|---|---|---|---|
| STS Benchmark (test) | Spearman | 84.6 | SBERT model card |
| MTEB (56 datasets) | Avg Score | 56.26 | MTEB Leaderboard |
Performance
22.7M params — optimized for speed, ideal for high-volume indexing
Specification
Build a pipeline with all-MiniLM-L6-v2
Add this model to a processing pipeline alongside other extractors. Combine with retrieval stages for end-to-end search.
Open Pipeline Builder