Update app.py
Browse files
app.py
CHANGED
@@ -45,10 +45,10 @@ with gr.Blocks() as demo:
|
|
45 |
# Phi-2 Chatbot Demo
|
46 |
This chatbot was created using Microsoft's 2.7 billion parameter [phi-2](https://huggingface.co/microsoft/phi-2) Transformer model.
|
47 |
|
48 |
-
In order to reduce the response time on this hardware, `max_new_tokens` has been set to `
|
49 |
""")
|
50 |
|
51 |
-
tokens_slider = gr.Slider(8, 128, value=
|
52 |
|
53 |
chatbot = gr.Chatbot()
|
54 |
msg = gr.Textbox()
|
|
|
45 |
# Phi-2 Chatbot Demo
|
46 |
This chatbot was created using Microsoft's 2.7 billion parameter [phi-2](https://huggingface.co/microsoft/phi-2) Transformer model.
|
47 |
|
48 |
+
In order to reduce the response time on this hardware, `max_new_tokens` has been set to `24` in the text generation pipeline. With this default configuration, it takes approximately `60 seconds` for each response to be generated. Use the slider below to increase or decrease the length of the generated text.
|
49 |
""")
|
50 |
|
51 |
+
tokens_slider = gr.Slider(8, 128, value=24, label="Maximum new tokens", info="A larger `max_new_tokens` parameter value gives you longer text responses but at the cost of a slower response time.")
|
52 |
|
53 |
chatbot = gr.Chatbot()
|
54 |
msg = gr.Textbox()
|