Downloads · 30 days
22
56% of all-time downloads
IstishadAlamTishad/TensorFluxEmbedder
TensorFluxEmbedder is a sentence similarity model from IstishadAlamTishad. Use it when you need a score for how close two texts are. It is set up for sentence-transformers. The card lists the license as apache-2.0.
TensorFluxEmbedder is a fine-tuned text embedding model covering four domains — general language, web search, scientific literature, and legal documents. Embeddings can be truncated from 768 → 512 → 256 → 128 → 64 dim…
Downloads · 30 days
22
56% of all-time downloads
All-time downloads
39
Public
Parameters
149M
596 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors596 MB · 99%
From the Hugging Face model README
TensorFluxEmbedder is a fine-tuned text embedding model covering four domains — general language, web search, scientific literature, and legal documents. Embeddings can be truncated from 768 → 512 → 256 → 128 → 64 dimensions at inference time with no retraining, letting you directly trade retrieval quality for speed and memory.
| Property | Value |
|---|---|
| Architecture | ModernBERT |
| Embedding dimensions | 768, 512, 256, 128, 64 |
| Max input length | 8,192 tokens |
| Similarity metric | Cosine |
| Language | English |
| License | Apache 2.0 |

NDCG@10 on held-out test sets across all five supported dimensionalities:
| Dims | SciFact NDCG@10 | Legal NDCG@10 | Vector size vs 768d |
|---|---|---|---|
| 768 | 0.718 | 0.422 | 100% |
| 512 | 0.707 | 0.417 | 67% |
| 256 | 0.697 | 0.400 | 33% |
| 128 | 0.665 | 0.345 | 17% |
| 64 | 0.587 | 0.278 | 8% |
256 dimensions is the recommended default for latency-sensitive RAG: it retains 97% of peak SciFact quality at one-third the storage cost.
| Metric | 768d | 512d | 256d | 128d | 64d |
|---|---|---|---|---|---|
| Accuracy@1 | 0.603 | 0.603 | 0.580 | 0.543 | 0.447 |
| Accuracy@10 | 0.860 | 0.843 | 0.840 | 0.810 | 0.743 |
| Recall@1 | 0.576 | 0.573 | 0.553 | 0.524 | 0.434 |
| Recall@10 | 0.851 | 0.831 | 0.829 | 0.795 | 0.727 |
| NDCG@10 | 0.718 | 0.707 | 0.697 | 0.665 | 0.587 |
| MRR@10 | 0.683 | 0.675 | 0.663 | 0.631 | 0.549 |
| MAP@100 | 0.678 | 0.670 | 0.656 | 0.625 | 0.544 |
| Metric | 768d | 512d | 256d | 128d | 64d |
|---|---|---|---|---|---|
| Accuracy@1 | 0.158 | 0.161 | 0.145 | 0.107 | 0.093 |
| Accuracy@10 | 0.702 | 0.692 | 0.675 | 0.598 | 0.491 |
| Recall@1 | 0.158 | 0.161 | 0.145 | 0.107 | 0.093 |
| Recall@10 | 0.702 | 0.692 | 0.675 | 0.598 | 0.491 |
| NDCG@10 | 0.422 | 0.417 | 0.400 | 0.345 | 0.278 |
| MRR@10 | 0.332 | 0.329 | 0.312 | 0.265 | 0.212 |
| MAP@100 | 0.342 | 0.338 | 0.321 | 0.276 | 0.224 |
The legal corpus uses a 1:1 query-to-passage evaluation scheme where each query has exactly one relevant passage in the full corpus, making the task harder than typical multi-relevant benchmarks.
pip install sentence-transformers
Always prefix your inputs to distinguish query intent from document content:
| Input type | Prefix |
|---|---|
| Search query | search_query: |
| Document / passage | search_document: |
from sentence_transformers import SentenceTransformer
model = SentenceTransformer("IstishadAlamTishad/TensorFluxEmbedder")
queries = [
"search_query: What are the procurement rules for small business government contracts?",
]
documents = [
"search_document: Agency procurement regulations require that small business offerors "
"receive fair opportunities pursuant to FAR Part 19.",
"search_document: Antibody neutralization of SARS-CoV-2 spike protein prevents viral "
"entry into host cells via the ACE2 receptor pathway.",
]
q_emb = model.encode(queries, normalize_embeddings=True)
d_emb = model.encode(documents, normalize_embeddings=True)
scores = model.similarity(q_emb, d_emb)
print(scores)
# tensor([[0.79, 0.51]])
Set truncate_dim at load time — no extra downloads, no retraining required:
# Full quality (768d)
model = SentenceTransformer("IstishadAlamTishad/TensorFluxEmbedder")
# Recommended for RAG: 97% quality at 1/3 storage (256d)
model = SentenceTransformer("IstishadAlamTishad/TensorFluxEmbedder", truncate_dim=256)
# Fastest retrieval, ~82% of peak quality (64d)
model = SentenceTransformer("IstishadAlamTishad/TensorFluxEmbedder", truncate_dim=64)
search_query: / search_document:). Omitting it will noticeably degrade retrieval quality.If you use TensorFluxEmbedder in your work, please cite:
@misc{tishad2026tensorfluxembedder,
author = {Istishad Alam Tishad},
title = {TensorFluxEmbedder: A Multi-Domain Embedding Model},
year = {2026},
url = {https://huggingface.co/IstishadAlamTishad/TensorFluxEmbedder},
note = {HuggingFace model repository}
}
Sentence Transformers
@inproceedings{reimers-2019-sentence-bert,
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
author = "Reimers, Nils and Gurevych, Iryna",
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
month = "11",
year = "2019",
publisher = "Association for Computational Linguistics",
url = "https://arxiv.org/abs/1908.10084",
}