Nighter commited on
Commit
7d058f6
1 Parent(s): 6ea75f7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -8
app.py CHANGED
@@ -116,15 +116,15 @@ with gr.Blocks() as app:
116
  gr.Examples(examples,[context_input, question_input],[distilbert_base_uncased_output, distilbert_base_uncased_score, bert_base_uncased_output, bert_base_uncased_score, roberta_base_output, roberta_base_score, longformer_base_output, longformer_base_score],answer_questions)
117
 
118
  with gr.Tab("Long Answer Prediction"):
119
- gr.Markdown("<center> <h1>Long Answer Prediction</h1> </center><hr>")
120
  with gr.Row():
121
- long_question_input = gr.Textbox(label="Question", placeholder="Enter the question")
122
- answer1_input = gr.Textbox(label="Answer 1", placeholder="Enter answer 1")
123
- answer2_input = gr.Textbox(label="Answer 2", placeholder="Enter answer 2")
124
- submit_btn_long = gr.Button("Submit")
125
-
126
- correct_answer_output = gr.Textbox(label="Correct Answer")
127
- score_output = gr.Number(label="Score")
 
128
 
129
  submit_btn_long.click(fn=predict_correct_answer, inputs=[long_question_input, answer1_input, answer2_input],
130
  outputs=[correct_answer_output, score_output])
 
116
  gr.Examples(examples,[context_input, question_input],[distilbert_base_uncased_output, distilbert_base_uncased_score, bert_base_uncased_output, bert_base_uncased_score, roberta_base_output, roberta_base_score, longformer_base_output, longformer_base_score],answer_questions)
117
 
118
  with gr.Tab("Long Answer Prediction"):
 
119
  with gr.Row():
120
+ with gr.Column():
121
+ long_question_input = gr.Textbox(lines=3,label="Question", placeholder="Enter the question")
122
+ answer1_input = gr.Textbox(lines=3,label="Answer 1", placeholder="Enter answer 1")
123
+ answer2_input = gr.Textbox(lines=3,label="Answer 2", placeholder="Enter answer 2")
124
+ submit_btn_long = gr.Button("Submit")
125
+ with gr.Column():
126
+ correct_answer_output = gr.Textbox(lines=3,label="Correct Answer")
127
+ score_output = gr.Number(label="Score")
128
 
129
  submit_btn_long.click(fn=predict_correct_answer, inputs=[long_question_input, answer1_input, answer2_input],
130
  outputs=[correct_answer_output, score_output])