加载中…
加载中…
sentence-transformers/all-MiniLM-L6-v2 fine-tuned for question-to-passage retrieval over FastAPI documentation.
It maps text to 384-dimensional vectors and was built for the RAG pipeline in
multimodal-rag-copilot.
MultipleNegativesRankingLoss (other passages in a batch act as negatives), 3 epochs,
batch size 32, learning rate 2e-5, trained with sentence-transformers on PyTorch.Held-out documents: 256 synthetic queries searched over 64 passages.
| Model | Recall@1 | Recall@3 | Recall@5 | MRR@10 |
|---|---|---|---|---|
| sentence-transformers/all-MiniLM-L6-v2 (base) | 0.566 | 0.789 | 0.863 | 0.695 |
| This model | 0.730 | 0.906 | 0.965 | 0.831 |
from sentence_transformers import SentenceTransformer
model = SentenceTransformer("Sushmitha2003/minilm-fastapi-docs-retrieval")
embeddings = model.encode(["How do I add a prefix to a router in FastAPI?"], normalize_embeddings=True)