Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -35,7 +35,7 @@ def T_on_select(evt: gr.SelectData):
|
|
35 |
f"""\n<a href="https://twitter.com/anyuser/status/{evt.value}"></a></blockquote>"""
|
36 |
else:
|
37 |
html = f"""<h2>{evt.value}</h2>"""
|
38 |
-
return
|
39 |
|
40 |
def single_classification(text, event_model, threshold):
|
41 |
res = classify(text, event_model, HFTOKEN, threshold)
|
@@ -226,8 +226,8 @@ with gr.Blocks(fill_width=True) as demo:
|
|
226 |
with gr.Row():
|
227 |
with gr.Column(scale=4):
|
228 |
T_data_filter = gr.Dropdown(visible=False)
|
229 |
-
T_tweet_embed = gr.HTML(render=False)
|
230 |
gr.ClearButton(components=T_tweet_embed)
|
|
|
231 |
|
232 |
with gr.Column(scale=6):
|
233 |
T_data = gr.DataFrame(headers=["Texts", "event_label", "model_score", "IDs"],
|
|
|
35 |
f"""\n<a href="https://twitter.com/anyuser/status/{evt.value}"></a></blockquote>"""
|
36 |
else:
|
37 |
html = f"""<h2>{evt.value}</h2>"""
|
38 |
+
return html
|
39 |
|
40 |
def single_classification(text, event_model, threshold):
|
41 |
res = classify(text, event_model, HFTOKEN, threshold)
|
|
|
226 |
with gr.Row():
|
227 |
with gr.Column(scale=4):
|
228 |
T_data_filter = gr.Dropdown(visible=False)
|
|
|
229 |
gr.ClearButton(components=T_tweet_embed)
|
230 |
+
T_tweet_embed = gr.HTML()
|
231 |
|
232 |
with gr.Column(scale=6):
|
233 |
T_data = gr.DataFrame(headers=["Texts", "event_label", "model_score", "IDs"],
|