sentence-transformers
Embeddings, Retrieval, and Reranking
Install
sentence-transformers on PyPI
pip
pip install sentence-transformersuv
uv add sentence-transformerspoetry
poetry add sentence-transformersPackage facts
| License | Apache-2.0 (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 9 — transformers, tokenizers, huggingface-hub, torch, numpy, scikit-learn, scipy, typing_extensions, tqdm |
| Maintenance | actively maintained — 7 days since the last release |
| Last repo commit | |
| First released | |
| Popularity | one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: sentence_transformers-5.7.0-py3-none-any.whl
Keywords: Transformer Networks, BERT, XLNet, sentence embedding, PyTorch, NLP, deep learning
About sentence-transformers
from the package's own PyPI description — quoted content, verbatim
<!--- BADGES: START --->
HF Models (image) [GitHub - License (image)][#github-license] [PyPI - Python Version (image)][#pypi-package] [PyPI - Package Version (image)][#pypi-package] [Docs - GitHub.io (image)][#docs-package]
<!-- [PyPI - Downloads (image)][#pypi-package] -->
<!--- BADGES: END --->
Sentence Transformers: Embeddings, Retrieval, and Reranking
This framework provides an easy method to compute embeddings for accessing, using, and training state-of-the-art embedding and reranker models. It can be used to compute embeddings using Sentence Transformer models...
Read as markdown · JSON record · Source repository · Homepage
AI interpretation — verify before relying
AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page
Computes dense and sparse text embeddings, and reranking scores using pre-trained transformer models for semantic search, similarity, and information retrieval tasks.
Low friction: pure Python wheel with well-maintained dependencies including transformers, torch, and huggingface-hub. Active development—last commit 2026-08-13—signals strong community support.
Apache-2.0 permissive license allows commercial and private use with minimal restrictions; derivative works and modifications are permitted provided the license and copyright notice are retained.
Usage
pip install sentence-transformers
from sentence_transformers import SentenceTransformer
model = SentenceTransformer("sentence-transformers/all-MiniLM-L6-v2")
embeddings = model.encode(["Hello world", "Hi there"])
print(embeddings.shape)
Requires Python 3.10+; PyTorch 1.11.0+ and transformers v4.41.0+ recommended per documentation.
Verdict: Production-ready embedding framework with no known vulnerabilities, active maintenance, and permissive Apache-2.0 licensing. Broad runtime dependency footprint (transformers, torch, numpy, scikit-learn, scipy, tokenizers, huggingface-hub, typing_extensions, tqdm) is standard for ML workloads; suitable for semantic search, retrieval, and reranking in research and production systems.
Needs verification
- Whether pre-trained model downloads are cached locally or require network access on each instantiation
- GPU memory requirements and inference speed benchmarks for typical embedding models
- Compatibility with quantized or ONNX-format model variants beyond standard PyTorch models
Similar packages
permissive · top 1,000 on PyPI
spacypermissive · top 1,000 on PyPI
simplejsonpermissive · top 1,000 on PyPI
huggingface-hubpermissive · top 100 on PyPI
hf-xetpermissive · top 1,000 on PyPI
pgvectorpermissive · top 1,000 on PyPI
transformerspermissive · top 1,000 on PyPI
datasetspermissive · top 1,000 on PyPI
tokenizerspermissive · top 1,000 on PyPI
pip-apipermissive · top 1,000 on PyPI