Instructions to use keeeeenw/MicroLlama-text-embedding with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use keeeeenw/MicroLlama-text-embedding with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("keeeeenw/MicroLlama-text-embedding") sentences = [ "A construction worker is standing on a crane placing a large arm on top of a stature in progress.", "The man is wearing black.", "A person standing", "Nobody is standing" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Notebooks
- Google Colab
- Kaggle
Training Script
Hello, Thanks for the great model and detailed training details, I am however still confused as each dataset seems to have separate losses attached to them, Would you be kind enough to share the training script you used ?
Thanks.
Thank you for your question! I followed https://www.sbert.net/docs/sentence_transformer/training_overview.html closely for training this model and you can just swap base model with keeeeenw/MicroLlama and start training.
It has been a while so I don't remember if this was the final version of the training code but this was definitely one of the versions I used and you can use this as reference:
https://huggingface.co/keeeeenw/MicroLlama-text-embedding/blob/main/train.py