Update app.py
Browse files
app.py
CHANGED
|
@@ -37,7 +37,7 @@ with gr.Blocks() as demo:
|
|
| 37 |
gr.Markdown("### QaChat Constantly learning") # Cabeçalho opcional
|
| 38 |
|
| 39 |
# Inputs adicionais ocultos
|
| 40 |
-
system_message = gr.
|
| 41 |
max_tokens = gr.Slider(minimum=1, maximum=2048, value=999, step=1, label="Max new tokens", visible=False)
|
| 42 |
temperature = gr.Slider(minimum=0.1, maximum=4.0, value=0.01, step=0.1, label="Temperature", visible=False)
|
| 43 |
top_p = gr.Slider(minimum=0.1, maximum=1.0, value=0.1, step=0.01, label="Top-p (nucleus sampling)", visible=False)
|
|
@@ -49,7 +49,7 @@ with gr.Blocks() as demo:
|
|
| 49 |
chat_history = gr.State([]) # Estado para armazenar o histórico
|
| 50 |
|
| 51 |
# Definindo a interação
|
| 52 |
-
user_input = gr.
|
| 53 |
submit_button = gr.Button("Send")
|
| 54 |
|
| 55 |
# Ação de enviar
|
|
|
|
| 37 |
gr.Markdown("### QaChat Constantly learning") # Cabeçalho opcional
|
| 38 |
|
| 39 |
# Inputs adicionais ocultos
|
| 40 |
+
system_message = gr.Textbox(value="You are a friendly QaChat.", label="System message", visible=False)
|
| 41 |
max_tokens = gr.Slider(minimum=1, maximum=2048, value=999, step=1, label="Max new tokens", visible=False)
|
| 42 |
temperature = gr.Slider(minimum=0.1, maximum=4.0, value=0.01, step=0.1, label="Temperature", visible=False)
|
| 43 |
top_p = gr.Slider(minimum=0.1, maximum=1.0, value=0.1, step=0.01, label="Top-p (nucleus sampling)", visible=False)
|
|
|
|
| 49 |
chat_history = gr.State([]) # Estado para armazenar o histórico
|
| 50 |
|
| 51 |
# Definindo a interação
|
| 52 |
+
user_input = gr.Textbox(placeholder="Type your question...")
|
| 53 |
submit_button = gr.Button("Send")
|
| 54 |
|
| 55 |
# Ação de enviar
|