Spaces:
Runtime error
Runtime error
Commit
·
6123551
1
Parent(s):
a0ffc1e
Update app.py
Browse files
app.py
CHANGED
@@ -90,3 +90,13 @@ def gr_cosine_similarity(sentence1, sentence2):
|
|
90 |
|
91 |
# return dataframe for space output
|
92 |
return df, cosine_similarity
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
90 |
|
91 |
# return dataframe for space output
|
92 |
return df, cosine_similarity
|
93 |
+
|
94 |
+
gr.Interface(gr_cosine_similarity,
|
95 |
+
[
|
96 |
+
gr.inputs.Textbox(lines=1, placeholder="This movie always makes me cry..", default="", label="Text 1"),
|
97 |
+
gr.inputs.Textbox(lines=1, placeholder="Her dog is sad.", default="", label="Text 2"),
|
98 |
+
|
99 |
+
#gr.outputs.Textbox(type="auto", label="Cosine similarity"),
|
100 |
+
],
|
101 |
+
["dataframe","text"]
|
102 |
+
).launch(debug=True)
|