Nikhil0987 commited on
Commit
6d7706e
·
verified ·
1 Parent(s): fe656af

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -6
app.py CHANGED
@@ -108,12 +108,16 @@ with st.container():
108
  render_file(pdf_upload1) # Use pdf_upload1 here
109
 
110
  if __name__ == "__main__":
111
- gr.Interface(
112
- [render_first, add_text, generate_response, render_file],
113
- [pdf_upload1, chatbot, txt], # Include pdf_upload1 here
114
- [show_img, chatbot, txt],
115
- title="PDF-Powered Chatbot"
116
- ).launch()
 
 
 
 
117
 
118
 
119
 
 
108
  render_file(pdf_upload1) # Use pdf_upload1 here
109
 
110
  if __name__ == "__main__":
111
+ pdf_upload1 = gr.inputs.File(label="Upload PDF 1") # Define pdf_upload1
112
+ chatbot = gr.outputs.Textbox() # Define chatbot
113
+ txt = gr.inputs.Textbox(label="Enter your query") # Define txt
114
+
115
+ gr.Interface(
116
+ [render_first, add_text, generate_response, render_file],
117
+ [pdf_upload1, chatbot, txt], # Include pdf_upload1, chatbot, txt here
118
+ [show_img, chatbot, txt],
119
+ title="PDF-Powered Chatbot"
120
+ ).launch()
121
 
122
 
123