coldlarry commited on
Commit
4d03146
·
1 Parent(s): bc76e36
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -12,14 +12,14 @@ with gr.Blocks() as demo:
12
  api_input = gr.Textbox(label="OpenAI API Key")
13
  #result = gr.Textbox(label="PDF Summary")
14
  upload_button = gr.Button("Start Analyse")
15
- with gr.Tab("Ask question about your PDF") as my:
16
- my.launch(auth = ('user','admin'), auth_message= "Enter your username and password that you received in on Slack")
17
  question_input = gr.Textbox(label="Your Question", placeholder="Authors of this paper?")
18
  answer = gr.Textbox(label="Answer")
19
  ask_button = gr.Button("Ask")
20
 
21
  app = GUI()
22
  upload_button.click(fn=app.pdf_init, inputs=[api_input, pdf_input])
 
23
  ask_button.click(app.get_answer, inputs=question_input, outputs=answer)
24
 
25
  if __name__ == "__main__":
 
12
  api_input = gr.Textbox(label="OpenAI API Key")
13
  #result = gr.Textbox(label="PDF Summary")
14
  upload_button = gr.Button("Start Analyse")
15
+ with gr.Tab("Ask question about your PDF"):
 
16
  question_input = gr.Textbox(label="Your Question", placeholder="Authors of this paper?")
17
  answer = gr.Textbox(label="Answer")
18
  ask_button = gr.Button("Ask")
19
 
20
  app = GUI()
21
  upload_button.click(fn=app.pdf_init, inputs=[api_input, pdf_input])
22
+ ask_button.launch(auth = ('user','admin'), auth_message= "Enter your username and password that you received in on Slack")
23
  ask_button.click(app.get_answer, inputs=question_input, outputs=answer)
24
 
25
  if __name__ == "__main__":