Spaces:
Runtime error
Runtime error
some description
Browse files
app.py
CHANGED
@@ -2,6 +2,10 @@ import gradio as gr
|
|
2 |
from transformers import AutoModel, AutoTokenizer
|
3 |
from sklearn.neighbors import NearestNeighbors
|
4 |
|
|
|
|
|
|
|
|
|
5 |
available_models = ['2019',
|
6 |
'2020']
|
7 |
|
@@ -64,5 +68,7 @@ def topk(word,model):
|
|
64 |
interface = gr.Interface(fn=topk,
|
65 |
inputs=[gr.Textbox(label="Word"), gr.Dropdown(available_models)],
|
66 |
outputs=gr.outputs.Textbox()
|
67 |
-
|
|
|
|
|
68 |
interface.launch()
|
|
|
2 |
from transformers import AutoModel, AutoTokenizer
|
3 |
from sklearn.neighbors import NearestNeighbors
|
4 |
|
5 |
+
title = "Temporal evolution of word association (Overselling :P)"
|
6 |
+
description = "Based on TimeLMs which is a RoBERTa model finetuned on tweets at periodic interval"
|
7 |
+
article = "This outputs the top 500 similar tokens to the input word, as a list. Stay tuned for more info"
|
8 |
+
|
9 |
available_models = ['2019',
|
10 |
'2020']
|
11 |
|
|
|
68 |
interface = gr.Interface(fn=topk,
|
69 |
inputs=[gr.Textbox(label="Word"), gr.Dropdown(available_models)],
|
70 |
outputs=gr.outputs.Textbox()
|
71 |
+
title = title,
|
72 |
+
description = description,
|
73 |
+
article = article)
|
74 |
interface.launch()
|