Spaces:
Runtime error
Runtime error
Commit
·
62d9a6f
1
Parent(s):
cebfd81
Update app.py
Browse files
app.py
CHANGED
@@ -2,7 +2,7 @@ from transformers import AutoModelForQuestionAnswering, AutoTokenizer, pipeline
|
|
2 |
import gradio as grad
|
3 |
import ast
|
4 |
# mdl_name = "deepset/roberta-base-squad2"
|
5 |
-
mdl_name = "
|
6 |
my_pipeline = pipeline('question-answering', model=mdl_name, tokenizer=mdl_name)
|
7 |
def answer_question(question,context):
|
8 |
text= "{"+"'question': '"+question+"','context': '"+context+"'}"
|
|
|
2 |
import gradio as grad
|
3 |
import ast
|
4 |
# mdl_name = "deepset/roberta-base-squad2"
|
5 |
+
mdl_name = "distilbert-base-cased-distilled-squad"
|
6 |
my_pipeline = pipeline('question-answering', model=mdl_name, tokenizer=mdl_name)
|
7 |
def answer_question(question,context):
|
8 |
text= "{"+"'question': '"+question+"','context': '"+context+"'}"
|