Spaces:
Runtime error
Runtime error
Commit
·
5e8714a
1
Parent(s):
9e8be11
Update app.py
Browse files
app.py
CHANGED
@@ -56,7 +56,7 @@ def classifier(userin):
|
|
56 |
in_emb = classification.sentence_embedder(clean_in, 'Model_bert')
|
57 |
|
58 |
Number = 10
|
59 |
-
broad_scope_predictions = classification.broad_scope_class_predictor(class_embeddings,
|
60 |
|
61 |
return broad_scope_predictions
|
62 |
|
@@ -195,11 +195,13 @@ with gr.Blocks(title='Claimed', theme=theme) as demo:
|
|
195 |
|
196 |
""")
|
197 |
with gr.Row(scale=1, min_width=600):
|
198 |
-
|
199 |
-
|
200 |
-
|
201 |
-
|
202 |
-
|
|
|
|
|
203 |
|
204 |
|
205 |
gr.Markdown("""
|
|
|
56 |
in_emb = classification.sentence_embedder(clean_in, 'Model_bert')
|
57 |
|
58 |
Number = 10
|
59 |
+
broad_scope_predictions = classification.broad_scope_class_predictor(class_embeddings, in_emb, Number, Sensitivity='High')
|
60 |
|
61 |
return broad_scope_predictions
|
62 |
|
|
|
195 |
|
196 |
""")
|
197 |
with gr.Row(scale=1, min_width=600):
|
198 |
+
with gr.Row():
|
199 |
+
userin = gr.Textbox(label="Input",
|
200 |
+
placeholder='Type in your Claim/Description/Abstract Here')
|
201 |
+
output = gr.Textbox(label="Output")
|
202 |
+
with gr.Row():
|
203 |
+
classify_btn = gr.Button("Classify")
|
204 |
+
classify_btn.click(fn=classifier, inputs=userin, outputs=output)
|
205 |
|
206 |
|
207 |
gr.Markdown("""
|