arjunanand13 commited on
Commit
0509daa
·
verified ·
1 Parent(s): 19b3ae3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -38,7 +38,8 @@ class Chatbot:
38
  self.llm = HuggingFacePipeline(pipeline=self.generate_text)
39
 
40
  try:
41
- self.vectorstore = FAISS.load_local('faiss_index', HuggingFaceEmbeddings(model_name="sentence-transformers/all-mpnet-base-v2", model_kwargs={"device": "cuda"}))
 
42
  print("Loaded embedding successfully")
43
  except ImportError as e:
44
  print("FAISS could not be imported. Make sure FAISS is installed correctly.")
 
38
  self.llm = HuggingFacePipeline(pipeline=self.generate_text)
39
 
40
  try:
41
+ # self.vectorstore = FAISS.load_local('faiss_index', HuggingFaceEmbeddings(model_name="sentence-transformers/all-mpnet-base-v2", model_kwargs={"device": "cuda"}))
42
+ self.vectorstore = FAISS.load_local('faiss_index', HuggingFaceEmbeddings(model_name="self.vectorstore = FAISS.load_local('faiss_index', HuggingFaceEmbeddings(model_name="sentence-transformers/all-mpnet-base-v2", model_kwargs={"device": "cuda"}))", model_kwargs={"device": "cuda"}))
43
  print("Loaded embedding successfully")
44
  except ImportError as e:
45
  print("FAISS could not be imported. Make sure FAISS is installed correctly.")