melbamorph commited on
Commit
be14980
·
verified ·
1 Parent(s): f2c0fff

Update app.py

Browse files

updating gradio again

Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -95,6 +95,9 @@ ui_component = GradioUI(agent) # if this returns a component
95
  with gr.Blocks(theme=theme) as demo:
96
  gr.Markdown("# Chat with BookBrain 📚🤯")
97
 
98
- ui_component.render()
 
 
 
99
 
100
  demo.launch()
 
95
  with gr.Blocks(theme=theme) as demo:
96
  gr.Markdown("# Chat with BookBrain 📚🤯")
97
 
98
+ input_box = gr.Textbox(label="Enter your question for BookBrain")
99
+ output_box = gr.Textbox(label="Response")
100
+ submit_btn = gr.Button("Submit")
101
+ submit_btn.click(fn=self.agent.run, inputs=input_box, outputs=output_box)
102
 
103
  demo.launch()