MarcdeFalco commited on
Commit
269a39e
1 Parent(s): 9ab2b8f

Upload folder using huggingface_hub

Browse files
Files changed (2) hide show
  1. app.py +5 -4
  2. app.py~ +1 -0
app.py CHANGED
@@ -71,19 +71,19 @@ def generate(prompt, history, temperature=0.9, max_new_tokens=256, top_p=0.95,
71
  additional_inputs=[
72
  gr.Slider(
73
  label="Temperature",
74
- value=0.9,
75
  minimum=0.0,
76
  maximum=1.0,
77
- step=0.05,
78
  interactive=True,
79
  info="Higher values produce more diverse outputs",
80
  ),
81
  gr.Slider(
82
  label="Max new tokens",
83
- value=2048,
84
  minimum=0,
85
  maximum=4096,
86
- step=64,
87
  interactive=True,
88
  info="The maximum numbers of new tokens",
89
  ),
@@ -131,6 +131,7 @@ with gr.Blocks(css=css) as demo:
131
  generate,
132
  additional_inputs=additional_inputs,
133
  theme = gr.themes.Soft(),
 
134
  examples=[ [l.strip()] for l in open("exercices.md").readlines()],
135
  chatbot = gr.Chatbot(
136
  latex_delimiters=[
 
71
  additional_inputs=[
72
  gr.Slider(
73
  label="Temperature",
74
+ value=0.3,
75
  minimum=0.0,
76
  maximum=1.0,
77
+ step=0.1,
78
  interactive=True,
79
  info="Higher values produce more diverse outputs",
80
  ),
81
  gr.Slider(
82
  label="Max new tokens",
83
+ value=1024,
84
  minimum=0,
85
  maximum=4096,
86
+ step=256,
87
  interactive=True,
88
  info="The maximum numbers of new tokens",
89
  ),
 
131
  generate,
132
  additional_inputs=additional_inputs,
133
  theme = gr.themes.Soft(),
134
+ cache_examples=False,
135
  examples=[ [l.strip()] for l in open("exercices.md").readlines()],
136
  chatbot = gr.Chatbot(
137
  latex_delimiters=[
app.py~ CHANGED
@@ -131,6 +131,7 @@ with gr.Blocks(css=css) as demo:
131
  generate,
132
  additional_inputs=additional_inputs,
133
  theme = gr.themes.Soft(),
 
134
  examples=[ [l.strip()] for l in open("exercices.md").readlines()],
135
  chatbot = gr.Chatbot(
136
  latex_delimiters=[
 
131
  generate,
132
  additional_inputs=additional_inputs,
133
  theme = gr.themes.Soft(),
134
+ cache_examples=False,
135
  examples=[ [l.strip()] for l in open("exercices.md").readlines()],
136
  chatbot = gr.Chatbot(
137
  latex_delimiters=[