Update app.py
Browse files
app.py
CHANGED
|
@@ -186,10 +186,11 @@ with gr.Blocks(theme=gr.themes.Default(), css='styles.css') as demo:
|
|
| 186 |
if 'filter' in info:
|
| 187 |
dataset = dataset.filter(info['filter'])
|
| 188 |
dataset = dataset.shuffle(buffer_size=2000).take(num_examples)
|
| 189 |
-
dataset = [[row[info['text_col']]]
|
| 190 |
-
gr.Examples(dataset, [original_prompt_raw
|
| 191 |
-
fn=lambda output: [[o[0]] + [gr.Button(visible=False) for _ in range(MAX_PROMPT_TOKENS)] for o in output],
|
| 192 |
-
run_on_click=True,
|
|
|
|
| 193 |
|
| 194 |
with gr.Group():
|
| 195 |
original_prompt_raw.render()
|
|
|
|
| 186 |
if 'filter' in info:
|
| 187 |
dataset = dataset.filter(info['filter'])
|
| 188 |
dataset = dataset.shuffle(buffer_size=2000).take(num_examples)
|
| 189 |
+
dataset = [[row[info['text_col']]] for row in dataset]
|
| 190 |
+
gr.Examples(dataset, [original_prompt_raw],
|
| 191 |
+
# fn=lambda output: [[o[0]] + [gr.Button(visible=False) for _ in range(MAX_PROMPT_TOKENS)] for o in output],
|
| 192 |
+
# run_on_click=True,
|
| 193 |
+
cache_examples=False)
|
| 194 |
|
| 195 |
with gr.Group():
|
| 196 |
original_prompt_raw.render()
|