kdevoe commited on
Commit
eb961eb
·
verified ·
1 Parent(s): fcd80cc

Fix button scaling

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -85,16 +85,16 @@ with gr.Blocks() as interface:
85
  gr.Markdown("**Instructions:** Press `Shift + Enter` to submit, and `Enter` for a new line.")
86
 
87
  # Add a clear history button
88
- clear_button = gr.Button("Clear History").style(width=150)
89
  clear_button.click(fn=clear_history, outputs=[chatbot_output])
90
 
91
  # Input box for the user
92
  user_input = gr.Textbox(label="Your Input", placeholder="Type your message here...", lines=2, show_label=True)
93
 
94
  # Sliders for temperature, top_p, and top_k
95
- temperature_slider = gr.Slider(0.1, 1.0, step=0.1, value=1.0, label="Temperature").style(width=500)
96
- top_p_slider = gr.Slider(0.0, 1.0, step=0.1, value=1.0, label="Top-p").style(width=500)
97
- top_k_slider = gr.Slider(1, 100, step=1, value=50, label="Top-k").style(width=500)
98
 
99
  # Define the function to update the chat
100
  def update_chat(input_text, chat_history, temperature, top_p, top_k):
 
85
  gr.Markdown("**Instructions:** Press `Shift + Enter` to submit, and `Enter` for a new line.")
86
 
87
  # Add a clear history button
88
+ clear_button = gr.Button("Clear History", scale=0)
89
  clear_button.click(fn=clear_history, outputs=[chatbot_output])
90
 
91
  # Input box for the user
92
  user_input = gr.Textbox(label="Your Input", placeholder="Type your message here...", lines=2, show_label=True)
93
 
94
  # Sliders for temperature, top_p, and top_k
95
+ temperature_slider = gr.Slider(0.1, 1.0, step=0.1, value=1.0, label="Temperature")
96
+ top_p_slider = gr.Slider(0.0, 1.0, step=0.1, value=1.0, label="Top-p")
97
+ top_k_slider = gr.Slider(1, 100, step=1, value=50, label="Top-k")
98
 
99
  # Define the function to update the chat
100
  def update_chat(input_text, chat_history, temperature, top_p, top_k):