Retry
Browse files
app.py
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
import os
|
2 |
-
os.environ["CUDA_VISIBLE_DEVICES"] = "" # Disable CUDA initialization
|
3 |
os.environ["allow_dangerous_deserialization"] = "True"
|
4 |
print(os.getcwd())
|
5 |
embedding_path="/home/user/app/docs/_embeddings/index.faiss"
|
@@ -283,7 +283,7 @@ class BSIChatbot:
|
|
283 |
global rerankingModel
|
284 |
rerankingModel = RAGPretrainedModel.from_pretrained(self.rerankModelPath)
|
285 |
|
286 |
-
|
287 |
def ragPrompt(self, query, rerankingStep, history):
|
288 |
prompt_in_chat_format = [
|
289 |
{
|
|
|
1 |
import os
|
2 |
+
#os.environ["CUDA_VISIBLE_DEVICES"] = "" # Disable CUDA initialization
|
3 |
os.environ["allow_dangerous_deserialization"] = "True"
|
4 |
print(os.getcwd())
|
5 |
embedding_path="/home/user/app/docs/_embeddings/index.faiss"
|
|
|
283 |
global rerankingModel
|
284 |
rerankingModel = RAGPretrainedModel.from_pretrained(self.rerankModelPath)
|
285 |
|
286 |
+
#@spaces.GPU
|
287 |
def ragPrompt(self, query, rerankingStep, history):
|
288 |
prompt_in_chat_format = [
|
289 |
{
|