MarMont commited on
Commit
8f17179
·
1 Parent(s): f637d11

add examples

Browse files
Files changed (1) hide show
  1. app.py +8 -7
app.py CHANGED
@@ -517,6 +517,12 @@ def optimized_bertopic(df):
517
  return top_tweets
518
 
519
  global examples
 
 
 
 
 
 
520
 
521
  def main(dataset, model, progress=gr.Progress(track_tqdm=True)):
522
  global df
@@ -563,17 +569,12 @@ def main(dataset, model, progress=gr.Progress(track_tqdm=True)):
563
 
564
 
565
  iface = gr.Interface(fn=main,
566
- inputs=[gr.Dropdown(["katip,katipunan",
567
- "bgc,bonifacio global city",
568
- "cubao",
569
- "taft",
570
- "pobla,poblacion"],
571
- label="Dataset"),
572
  gr.Dropdown(["LDA",
573
  "BERTopic"],
574
  label="Model")
575
  ],
576
- # examples=examples,
577
  outputs=["text",
578
  "text",
579
  "text"],
 
517
  return top_tweets
518
 
519
  global examples
520
+ examples = [ "katip,katipunan",
521
+ "bgc,bonifacio global city",
522
+ "pobla,poblacion",
523
+ "cubao",
524
+ "taft"
525
+ ]
526
 
527
  def main(dataset, model, progress=gr.Progress(track_tqdm=True)):
528
  global df
 
569
 
570
 
571
  iface = gr.Interface(fn=main,
572
+ inputs=["text",
 
 
 
 
 
573
  gr.Dropdown(["LDA",
574
  "BERTopic"],
575
  label="Model")
576
  ],
577
+ examples=examples,
578
  outputs=["text",
579
  "text",
580
  "text"],