MasterAlex69 commited on
Commit
c5dc3e4
·
verified ·
1 Parent(s): 00f9a93

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -5
app.py CHANGED
@@ -77,7 +77,7 @@ def test():
77
 
78
  def get_correct_answer(t):
79
 
80
- if len(t) == 0: return 'Сгенерируйте задание...'
81
 
82
  start_index = t.find("(")
83
  end_index = t.find(")", start_index)
@@ -122,11 +122,9 @@ with gr.Blocks(theme = gr.themes.Monochrome()) as iface:
122
  get_correct_answer_input_text = gr.Textbox(label = "Задание")
123
  get_correct_answer_output_text = gr.Textbox(label = "Ответ")
124
 
125
- button_gen_1.click(fn = generate_text_1, outputs = [button_gen_1_output_text, get_correct_answer_input_text])
126
  button_get_correct_answer.click(fn = get_correct_answer, inputs = get_correct_answer_input_text, outputs = get_correct_answer_output_text)
127
-
128
- gr.Markdown("---")
129
-
130
  with gr.Row():
131
 
132
  with gr.Column():
 
77
 
78
  def get_correct_answer(t):
79
 
80
+ if len(t) == 0: return 'Введите задание...'
81
 
82
  start_index = t.find("(")
83
  end_index = t.find(")", start_index)
 
122
  get_correct_answer_input_text = gr.Textbox(label = "Задание")
123
  get_correct_answer_output_text = gr.Textbox(label = "Ответ")
124
 
125
+ button_gen_1.click(fn = generate_text_1, outputs = [button_gen_1_output_text, get_correct_answer_input_text]).then(lambda: gr.Info("Генерация завершена"), None, None)
126
  button_get_correct_answer.click(fn = get_correct_answer, inputs = get_correct_answer_input_text, outputs = get_correct_answer_output_text)
127
+
 
 
128
  with gr.Row():
129
 
130
  with gr.Column():