Spaces:
Running
Running
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +5 -2
src/streamlit_app.py
CHANGED
@@ -35,8 +35,11 @@ import torch # Import torch
|
|
35 |
# # Load models
|
36 |
|
37 |
# summarizer = pipeline("summarization", model="facebook/bart-large-cnn")
|
38 |
-
|
39 |
-
|
|
|
|
|
|
|
40 |
vector_dbs = {} # Dictionary to store multiple vector databases, keyed by document title
|
41 |
extracted_texts = {} # Dictionary to store extracted text, keyed by document title
|
42 |
current_doc_title = None
|
|
|
35 |
# # Load models
|
36 |
|
37 |
# summarizer = pipeline("summarization", model="facebook/bart-large-cnn")
|
38 |
+
summarizer = pipeline("summarization", model="google/pegasus-xsum")
|
39 |
+
# qa_pipeline = pipeline("question-answering", model="distilbert-base-cased-distilled-squad", device=torch.device("cpu"))
|
40 |
+
qa_pipeline = pipeline("question-answering", model="deepset/tinyroberta-squad2", device=torch.device("cpu"))
|
41 |
+
# embedding_model = HuggingFaceEmbeddings(model_name="all-MiniLM-L6-v2")
|
42 |
+
|
43 |
vector_dbs = {} # Dictionary to store multiple vector databases, keyed by document title
|
44 |
extracted_texts = {} # Dictionary to store extracted text, keyed by document title
|
45 |
current_doc_title = None
|