ryanrwatkins commited on
Commit
26f048e
1 Parent(s): fd9fcfa

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -9
app.py CHANGED
@@ -902,21 +902,15 @@ with gr.Blocks(css=css) as demo:
902
  #total_tokens_str = gr.Markdown(elem_id="total_tokens_str")
903
  btn_clear_conversation = gr.Button("Start New Conversation")
904
 
905
- #temp variable until add more context files
906
- prompt_template = ""
907
- temperature = ""
908
- max_tokens = ""
909
- context_length = ""
910
-
911
- """
912
- with gr.Column():
913
  prompt_template = gr.Dropdown(label="Choose an Expert:", choices=list(prompt_templates.keys()))
914
  prompt_template_preview = gr.Markdown(elem_id="prompt_template_preview")
915
  with gr.Accordion("Advanced parameters", open=False):
916
  temperature = gr.Slider(minimum=0, maximum=2.0, value=0.7, step=0.1, label="Flexibility", info="Higher = More AI, Lower = More Expert")
917
  max_tokens = gr.Slider(minimum=100, maximum=400, value=200, step=1, label="Length of Response.")
918
  context_length = gr.Slider(minimum=1, maximum=5, value=2, step=1, label="Context Length", info="Number of previous questions you have asked.")
919
- """
920
 
921
  btn_submit.click(submit_message, [ input_message, prompt_template, temperature, max_tokens, context_length, state], [input_message, chatbot, state])
922
  input_message.submit(submit_message, [ input_message, prompt_template, temperature, max_tokens, context_length, state], [input_message, chatbot, state])
 
902
  #total_tokens_str = gr.Markdown(elem_id="total_tokens_str")
903
  btn_clear_conversation = gr.Button("Start New Conversation")
904
 
905
+
906
+ with gr.Columnv(visible=False):
 
 
 
 
 
 
907
  prompt_template = gr.Dropdown(label="Choose an Expert:", choices=list(prompt_templates.keys()))
908
  prompt_template_preview = gr.Markdown(elem_id="prompt_template_preview")
909
  with gr.Accordion("Advanced parameters", open=False):
910
  temperature = gr.Slider(minimum=0, maximum=2.0, value=0.7, step=0.1, label="Flexibility", info="Higher = More AI, Lower = More Expert")
911
  max_tokens = gr.Slider(minimum=100, maximum=400, value=200, step=1, label="Length of Response.")
912
  context_length = gr.Slider(minimum=1, maximum=5, value=2, step=1, label="Context Length", info="Number of previous questions you have asked.")
913
+
914
 
915
  btn_submit.click(submit_message, [ input_message, prompt_template, temperature, max_tokens, context_length, state], [input_message, chatbot, state])
916
  input_message.submit(submit_message, [ input_message, prompt_template, temperature, max_tokens, context_length, state], [input_message, chatbot, state])