3 ms·
Yesterday I read about this embedding model that can be run locally. I read about it here: https://news.ycombinator.com/item?id=35236275 https://news.ycombinat
by rahimnathwani 4y ago
Yesterday I read about this embedding model that can be run locally.
I read about it here:
https://news.ycombinator.com/item?id=35236275 https://news.ycombinator.com/item?id=35236275
But it's been mentioned on HN a few times in the past 3 months:
https://news.ycombinator.com/item?id=35055808 https://news.ycombinator.com/item?id=35055808
https://news.ycombinator.com/item?id=34691307 https://news.ycombinator.com/item?id=34691307
https://news.ycombinator.com/item?id=34034940 https://news.ycombinator.com/item?id=34034940
https://news.ycombinator.com/item?id=34007942 https://news.ycombinator.com/item?id=34007942
It can be used as am embedding model in llama_index (fka gpt_index). Here's a code snippet from one of their users:
from langchain.embeddings.huggingface import HuggingFaceEmbeddings
from llama_index import LangchainEmbedding
def get_embed_model():
model_name = "sentence-transformers/all-MiniLM-L6-v2"
embed_model = LangchainEmbedding(HuggingFaceEmbeddings(model_name=model_name))
return embed_model
get_embed_model()
index = GPTSimpleVectorIndex(documents, embed_model=embed_model)