Makima57 commited on
Commit
1503841
·
verified ·
1 Parent(s): 9a62254

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -3
app.py CHANGED
@@ -46,17 +46,23 @@ def gradio_interface(question, correct_answer):
46
  }
47
 
48
  # Gradio app setup
49
- interface = gr.Interface(
50
  fn=gradio_interface,
51
  inputs=[
52
- gr.Textbox(label="Math Question"),
53
- gr.Textbox(label="Correct Answer"),
54
  ],
55
  outputs=[
56
  gr.JSON(label="Results"), # Display the results in a JSON format
57
  ],
58
  title="Math Question Solver",
59
  description="Enter a math question to get the model prediction and see all generated answers.",
 
 
 
 
 
 
60
  )
61
 
62
  if __name__ == "__main__":
 
46
  }
47
 
48
  # Gradio app setup
49
+ demo = gr.Interface(
50
  fn=gradio_interface,
51
  inputs=[
52
+ gr.Textbox(label="Math Question", placeholder="Enter your math question here..."),
53
+ gr.Textbox(label="Correct Answer", placeholder="Enter the correct answer here..."),
54
  ],
55
  outputs=[
56
  gr.JSON(label="Results"), # Display the results in a JSON format
57
  ],
58
  title="Math Question Solver",
59
  description="Enter a math question to get the model prediction and see all generated answers.",
60
+ theme="huggingface",
61
+ layout="vertical",
62
+ live=True,
63
+ allow_flagging="never",
64
+ show_input=True,
65
+ show_output=True,
66
  )
67
 
68
  if __name__ == "__main__":