Spaces:
Runtime error
Runtime error
domenicrosati
commited on
Commit
β’
bdb2b00
1
Parent(s):
3e298c6
use natrual questions model
Browse files
app.py
CHANGED
@@ -142,7 +142,7 @@ def init_models():
|
|
142 |
stop = set(stopwords.words('english') + list(string.punctuation))
|
143 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
144 |
question_answerer = pipeline(
|
145 |
-
"question-answering", model='
|
146 |
device=device, handle_impossible_answer=False,
|
147 |
)
|
148 |
reranker = CrossEncoder('cross-encoder/ms-marco-MiniLM-L-6-v2', device=device)
|
|
|
142 |
stop = set(stopwords.words('english') + list(string.punctuation))
|
143 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
144 |
question_answerer = pipeline(
|
145 |
+
"question-answering", model='nlpconnect/roberta-base-squad2-nq',
|
146 |
device=device, handle_impossible_answer=False,
|
147 |
)
|
148 |
reranker = CrossEncoder('cross-encoder/ms-marco-MiniLM-L-6-v2', device=device)
|