m-ric HF staff commited on
Commit
f7623e8
1 Parent(s): 61535fd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -202,7 +202,7 @@ def run_display(text):
202
  yield map, "```text\n" + current_output + "\n```"
203
 
204
 
205
- def select_example(choice, data: gr.SelectData):
206
  output = trip_examples[choice]
207
  dataframe, _ = parse_llm_output(output)
208
  map = create_map_from_markers(dataframe)
@@ -232,8 +232,7 @@ with gr.Blocks(
232
  map = Folium(value=starting_map, height=600, label="Chosen locations")
233
  button.click(run_display, inputs=[text], outputs=[map, display_thoughts])
234
 
235
- gr.Markdown("### Other examples")
236
- clickable_examples = gr.Dropdown(choices=trip_examples.keys())
237
  clickable_examples.input(
238
  select_example, clickable_examples, outputs=[text, map, display_thoughts]
239
  )
 
202
  yield map, "```text\n" + current_output + "\n```"
203
 
204
 
205
+ def select_example(choice):
206
  output = trip_examples[choice]
207
  dataframe, _ = parse_llm_output(output)
208
  map = create_map_from_markers(dataframe)
 
232
  map = Folium(value=starting_map, height=600, label="Chosen locations")
233
  button.click(run_display, inputs=[text], outputs=[map, display_thoughts])
234
 
235
+ clickable_examples = gr.Dropdown(choices=trip_examples.keys(), label="Other examples:", value=description_sf)
 
236
  clickable_examples.input(
237
  select_example, clickable_examples, outputs=[text, map, display_thoughts]
238
  )