Unable to import the model using HuggingFace and LlamaIndex

#2
by ApplyGPT - opened

Hi,

I'm trying to use this model in Pinecone + Llamaindex. Here is my code:

'''
pinecone_index = pinecone.Index(index_name)
vector_store = PineconeVectorStore(pinecone_index=pinecone_index)

storage_context = StorageContext.from_defaults(
    vector_store=vector_store
)



#embed_model = OpenAIEmbedding(model='text-embedding-ada-002', embed_batch_size=100)
embed_model = LangchainEmbedding(HuggingFaceEmbeddings(model_name = 'CAMeL-Lab/bert-base-arabic-camelbert-da'))

service_context = ServiceContext.from_defaults(embed_model=embed_model)

#Specify chunk size and overlap over here with Node Parser
index = GPTVectorStoreIndex.from_documents(
    docs, storage_context=storage_context,
    service_context=service_context
)

'''

I get the following error:
'''
No sentence-transformers model found with name /Users/reality/.cache/torch/sentence_transformers/CAMeL-Lab_bert-base-arabic-camelbert-da. Creating a new one with MEAN pooling.
'''

Any idea what could be wrong? I checked to make sure my transfomers version was up to date.

Sign up or log in to comment