Spaces:
Sleeping
Sleeping
shambhuDATA
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
from transformers import AutoModelForQuestionAnswering,AutoTokenizer,pipeline
|
2 |
import streamlit as st
|
3 |
import ast
|
4 |
-
model_name="deepset/roberta-base-
|
5 |
pipe=pipeline('question-answering',model=model_name,tokenizer=model_name)
|
6 |
def answer_question(question,context):
|
7 |
text="{"+"'question': '"+question + "',''context':'"+context+"'}"
|
|
|
1 |
from transformers import AutoModelForQuestionAnswering,AutoTokenizer,pipeline
|
2 |
import streamlit as st
|
3 |
import ast
|
4 |
+
model_name="deepset/roberta-base-squad2"
|
5 |
pipe=pipeline('question-answering',model=model_name,tokenizer=model_name)
|
6 |
def answer_question(question,context):
|
7 |
text="{"+"'question': '"+question + "',''context':'"+context+"'}"
|