ZongqianLi commited on
Commit
6302321
·
verified ·
1 Parent(s): f881630

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -1,14 +1,13 @@
1
  import streamlit as st
2
  from transformers import pipeline
3
 
4
- # 初始化管道
5
  pipe = pipeline("question-answering", model="ZongqianLi/bert-base-cased-scqa2")
6
 
7
- # 创建文本输入区域以供用户输入上下文和问题
8
- context = st.text_area("Enter the context here")
 
9
  question = st.text_input("Enter your question here")
10
 
11
- # 当获取到问题和上下文后,执行问题回答
12
  if context and question:
13
  out = pipe({
14
  'question': question,
 
1
  import streamlit as st
2
  from transformers import pipeline
3
 
 
4
  pipe = pipeline("question-answering", model="ZongqianLi/bert-base-cased-scqa2")
5
 
6
+ st.write("Here's our first attempt at using data to create a table:")
7
+
8
+ context = st.text_input("Enter the context here")
9
  question = st.text_input("Enter your question here")
10
 
 
11
  if context and question:
12
  out = pipe({
13
  'question': question,