Sentence Similarity
sentence-transformers
PyTorch
ONNX
Safetensors
Transformers
bert
feature-extraction
mteb
Eval Results (legacy)
text-embeddings-inference
Instructions to use TaylorAI/bge-micro with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use TaylorAI/bge-micro with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("TaylorAI/bge-micro") sentences = [ "That is a happy person", "That is a happy dog", "That is a very happy person", "Today is a sunny day" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Transformers
How to use TaylorAI/bge-micro with Transformers:
# Load model directly from transformers import AutoTokenizer, AutoModel tokenizer = AutoTokenizer.from_pretrained("TaylorAI/bge-micro") model = AutoModel.from_pretrained("TaylorAI/bge-micro") - Inference
- Notebooks
- Google Colab
- Kaggle
Question on Pooling method
#2
by davidmezzetti - opened
Nice work on these smaller models.
I see that the 1_Pooling/config.json file uses mean pooling but the underlying model configuration is for CLS pooling. Is that expected?
Yeah, I trained this one with mean pooling, if I could go back and do it again I would be more careful to make sure the pooling I used matched how the base model was trained, but oh well. It should probably work okay with CLS pooling since it was trained to distill all logits from the teacher model.