Sirus1 commited on
Commit
90757b8
·
1 Parent(s): 0dda6bc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -10,7 +10,7 @@ import gradio as gr
10
 
11
 
12
 
13
- print(os.environ["OPENAI_API_KEY"])
14
 
15
  def preprocess(text):
16
  text = text.replace('\n', '')
@@ -79,7 +79,6 @@ def ask_api(question):
79
  if question.strip() == '':
80
  return '[ERROR]: 未输入问题'
81
 
82
- print('test')
83
  return generate_answer(question)
84
 
85
 
@@ -93,6 +92,8 @@ description = """ 本bot旨在根据中华人民共和国的法律回答有关
93
  """
94
 
95
 
 
 
96
  demo = gr.Interface(
97
  title=title,
98
  description=description,
 
10
 
11
 
12
 
13
+
14
 
15
  def preprocess(text):
16
  text = text.replace('\n', '')
 
79
  if question.strip() == '':
80
  return '[ERROR]: 未输入问题'
81
 
 
82
  return generate_answer(question)
83
 
84
 
 
92
  """
93
 
94
 
95
+ print(generate_answer('未成年遭受网络欺凌该怎么办?'))
96
+
97
  demo = gr.Interface(
98
  title=title,
99
  description=description,