KushJaggi commited on
Commit
6955531
·
1 Parent(s): a36182a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -51,13 +51,13 @@ css="""
51
  #col-container {max-width: 700px; margin-left: auto; margin-right: auto;}
52
  """
53
 
54
- title = """
55
  <div style="text-align: center;max-width: 700px;">
56
  <h1>Chat with PDF</h1>
57
  <p style="text-align: center;">Upload a .pdf from local machine, click the "Load PDF🚀" button, <br />
58
  When ready, you are all set to start asking questions from the pdf</p>
59
  </div>
60
- """
61
 
62
 
63
  with gr.Blocks(css=css) as demo:
@@ -72,7 +72,7 @@ with gr.Blocks(css=css) as demo:
72
  load_pdf = gr.Button("Load pdf to langchain")
73
 
74
  chatbot = gr.Chatbot([], elem_id="chatbot").style(height=350)
75
- question = gr.Textbox(label="Question", placeholder="Type your question and hit Enter ")
76
  submit_btn = gr.Button("Send message")
77
  #load_pdf.click(loading_pdf, None, langchain_status, queue=False)
78
  repo_id.change(pdf_changes, inputs=[pdf_doc, repo_id], outputs=[langchain_status], queue=False)
@@ -84,4 +84,4 @@ with gr.Blocks(css=css) as demo:
84
  bot, chatbot, chatbot
85
  )
86
 
87
- demo.launch()
 
51
  #col-container {max-width: 700px; margin-left: auto; margin-right: auto;}
52
  """
53
 
54
+ title =
55
  <div style="text-align: center;max-width: 700px;">
56
  <h1>Chat with PDF</h1>
57
  <p style="text-align: center;">Upload a .pdf from local machine, click the "Load PDF🚀" button, <br />
58
  When ready, you are all set to start asking questions from the pdf</p>
59
  </div>
60
+
61
 
62
 
63
  with gr.Blocks(css=css) as demo:
 
72
  load_pdf = gr.Button("Load pdf to langchain")
73
 
74
  chatbot = gr.Chatbot([], elem_id="chatbot").style(height=350)
75
+ question = gr.Textbox(label="Question", placeholder="Type your Question and hit Enter ")
76
  submit_btn = gr.Button("Send message")
77
  #load_pdf.click(loading_pdf, None, langchain_status, queue=False)
78
  repo_id.change(pdf_changes, inputs=[pdf_doc, repo_id], outputs=[langchain_status], queue=False)
 
84
  bot, chatbot, chatbot
85
  )
86
 
87
+ demo.launch(True)