Leon-Sander / local_multimodal_ai_chat

GNU General Public License v3.0
101 stars 66 forks source link

TypeError: INSTRUCTOR._load_sbert_model() got an unexpected keyword argument 'token' #26

Open tbakil opened 2 months ago

tbakil commented 2 months ago

I get this error I could not find a solution for it! Can any one help me please!!

$ python3 test.py Traceback (most recent call last): File "/home/bakil/demo_bitirme/local_multimodal_ai_chat/test.py", line 4, in vector_db = load_vectordb(create_embeddings()) ^^^^^^^^^^^^^^^^^^^ File "/home/bakil/demo_bitirme/local_multimodal_ai_chat/llm_chains.py", line 25, in create_embeddings return HuggingFaceInstructEmbeddings(model_name=embeddings_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/bakil/demo_bitirme/local_multimodal_ai_chat/chat_venv/lib/python3.11/site-packages/langchain_community/embeddings/huggingface.py", line 158, in init self.client = INSTRUCTOR( ^^^^^^^^^^^ File "/home/bakil/demo_bitirme/local_multimodal_ai_chat/chat_venv/lib/python3.11/site-packages/sentence_transformers/SentenceTransformer.py", line 194, in init modules = self._load_sbert_model( ^^^^^^^^^^^^^^^^^^^^^^^ TypeError: INSTRUCTOR._load_sbert_model() got an unexpected keyword argument 'token'

eekarot commented 1 month ago

you can solve the problem by: pip install sentence_transformers==2.2.2