Spaces:
Sleeping
Sleeping
add accordin
Browse files- gemmademo/_chat.py +20 -18
gemmademo/_chat.py
CHANGED
|
@@ -128,25 +128,27 @@ class GradioChat:
|
|
| 128 |
)
|
| 129 |
|
| 130 |
with gr.Column(scale=1):
|
| 131 |
-
gr.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 132 |
"""
|
| 133 |
-
|
| 134 |
-
|
| 135 |
-
|
| 136 |
-
|
| 137 |
-
|
| 138 |
-
|
| 139 |
-
|
| 140 |
-
|
| 141 |
-
|
| 142 |
-
|
| 143 |
-
|
| 144 |
-
|
| 145 |
-
inputs=chat_interface.textbox,
|
| 146 |
-
)
|
| 147 |
-
task_dropdown.change(
|
| 148 |
-
_update_examples, task_dropdown, examples_list.dataset
|
| 149 |
-
)
|
| 150 |
with gr.Accordion("Model Configuration ⚙️", open=False):
|
| 151 |
temperature_slider = gr.Slider(
|
| 152 |
minimum=0.1,
|
|
|
|
| 128 |
)
|
| 129 |
|
| 130 |
with gr.Column(scale=1):
|
| 131 |
+
with gr.Accordin("Important Pointers", open=False):
|
| 132 |
+
gr.Markdown(
|
| 133 |
+
"""
|
| 134 |
+
## Pointers
|
| 135 |
+
|
| 136 |
+
- First response after model change will be slower (model loading lazily).
|
| 137 |
+
- Switching models clears chat history.
|
| 138 |
+
- Larger models need more memory but give better results.
|
| 139 |
"""
|
| 140 |
+
)
|
| 141 |
+
examples_list = gr.Examples(
|
| 142 |
+
examples=[
|
| 143 |
+
[example]
|
| 144 |
+
for example in _get_examples(self.current_task_name)
|
| 145 |
+
],
|
| 146 |
+
inputs=chat_interface.textbox,
|
| 147 |
+
)
|
| 148 |
+
task_dropdown.change(
|
| 149 |
+
_update_examples, task_dropdown, examples_list.dataset
|
| 150 |
+
)
|
| 151 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 152 |
with gr.Accordion("Model Configuration ⚙️", open=False):
|
| 153 |
temperature_slider = gr.Slider(
|
| 154 |
minimum=0.1,
|