Shriharsh commited on
Commit
d97e942
·
verified ·
1 Parent(s): fc853a4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -11
app.py CHANGED
@@ -271,27 +271,22 @@ with gr.Blocks() as app:
271
  The information provided by this chatbot is for research and informational purposes only and is not intended to substitute professional medical advice, diagnosis, or treatment. Always seek the advice of your physician or other qualified health provider with any questions you may have regarding a medical condition.
272
  </div>
273
  <br>
274
- <p style="text-align:center;">Example Queries:</p>
275
- <ul style="text-align:center;">
276
- <li>"What is new with type 2 diabetes management research?"</li>
277
- <li>"Tell me about new treatments in diabetes if any."</li>
278
- </ul>
279
  """
280
  )
281
 
282
- # Create a Chatbot component with type set to "messages" and a specified height
283
- chatbot = gr.Chatbot(label="Conversation", type="messages", height=400)
284
-
285
  # Input row for query and PDF file (with PDF box sized smaller)
286
  with gr.Row():
287
- query_input = gr.Textbox(label="Ask a Question", placeholder="Type your diabetes-related query here...", lines=2)
288
- with gr.Column(scale=0.5):
289
  pdf_input = gr.File(label="Upload a PDF (optional, max 10 pages)", file_types=[".pdf"])
290
 
291
  # Row for Submit and Clear buttons
292
  with gr.Row():
293
- submit_button = gr.Button("Submit", variant="primary")
294
  clear_button = gr.Button("Clear")
 
 
 
295
 
296
  # State to maintain conversation history
297
  state = gr.State([])
 
271
  The information provided by this chatbot is for research and informational purposes only and is not intended to substitute professional medical advice, diagnosis, or treatment. Always seek the advice of your physician or other qualified health provider with any questions you may have regarding a medical condition.
272
  </div>
273
  <br>
 
 
 
 
 
274
  """
275
  )
276
 
 
 
 
277
  # Input row for query and PDF file (with PDF box sized smaller)
278
  with gr.Row():
279
+ query_input = gr.Textbox(label="Ask a Question", placeholder="Type your diabetes-related query here...", lines=4)
280
+ with gr.Column(scale=0.4):
281
  pdf_input = gr.File(label="Upload a PDF (optional, max 10 pages)", file_types=[".pdf"])
282
 
283
  # Row for Submit and Clear buttons
284
  with gr.Row():
285
+ submit_button = gr.Button("Ask", variant="secondary")
286
  clear_button = gr.Button("Clear")
287
+
288
+ # Create a Chatbot component with type set to "messages" and a specified height
289
+ chatbot = gr.Chatbot(label="Conversation", type="messages", height=370)
290
 
291
  # State to maintain conversation history
292
  state = gr.State([])