Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -17,6 +17,11 @@ import os
|
|
17 |
import difflib
|
18 |
|
19 |
|
|
|
|
|
|
|
|
|
|
|
20 |
modelPath = "MSEAJYTHTH/NFPC"
|
21 |
faiss_indexPath = "MSEAJYTHTH/NFPC/faiss_index"
|
22 |
|
@@ -32,7 +37,7 @@ embeddings = HuggingFaceEmbeddings(
|
|
32 |
)
|
33 |
|
34 |
|
35 |
-
db = FAISS.load_local(
|
36 |
|
37 |
|
38 |
def find_best_page_content(question, keywords, db):
|
|
|
17 |
import difflib
|
18 |
|
19 |
|
20 |
+
API_URL = "https://huggingface.co/MSEAJYTHTH/NFPC/tree/main/faiss_index"
|
21 |
+
|
22 |
+
|
23 |
+
|
24 |
+
|
25 |
modelPath = "MSEAJYTHTH/NFPC"
|
26 |
faiss_indexPath = "MSEAJYTHTH/NFPC/faiss_index"
|
27 |
|
|
|
37 |
)
|
38 |
|
39 |
|
40 |
+
db = FAISS.load_local(API_URL, embeddings, allow_dangerous_deserialization=True)
|
41 |
|
42 |
|
43 |
def find_best_page_content(question, keywords, db):
|