Spaces:
Sleeping
Sleeping
Allen Park
commited on
Commit
·
de4039b
1
Parent(s):
0edf770
put examples in one column (less margin in between)
Browse files
app.py
CHANGED
@@ -229,14 +229,15 @@ with gr.Blocks(css=css, theme=gr.themes.Default(font=[gr.themes.GoogleFont("Plus
|
|
229 |
with gr.Column(scale=1):
|
230 |
reasoning = gr.Textbox(label="Reasoning")
|
231 |
score = gr.Textbox(label="Score (FAIL if Hallucinated, PASS if not)")
|
232 |
-
|
233 |
-
with gr.
|
234 |
-
|
235 |
-
|
236 |
-
|
237 |
-
|
238 |
-
|
239 |
-
|
|
|
240 |
|
241 |
model_dropdown.change(fn=update_client_base_url, inputs=[model_dropdown], outputs=[base_url_state])
|
242 |
u.upload(upload_file, u, [u, file_group, file_name, document])
|
|
|
229 |
with gr.Column(scale=1):
|
230 |
reasoning = gr.Textbox(label="Reasoning")
|
231 |
score = gr.Textbox(label="Score (FAIL if Hallucinated, PASS if not)")
|
232 |
+
with gr.Row():
|
233 |
+
with gr.Column():
|
234 |
+
for idx, example in enumerate(EXAMPLES):
|
235 |
+
template_btn = gr.Button(f"{example['emoji']} {example['question']}", elem_classes="example-button")
|
236 |
+
template_btn.click(
|
237 |
+
fn=select_template,
|
238 |
+
inputs=[gr.State(example)],
|
239 |
+
outputs=[question, document, answer]
|
240 |
+
)
|
241 |
|
242 |
model_dropdown.change(fn=update_client_base_url, inputs=[model_dropdown], outputs=[base_url_state])
|
243 |
u.upload(upload_file, u, [u, file_group, file_name, document])
|