Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -2,9 +2,9 @@ import gradio as gr
|
|
2 |
|
3 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification, pipeline
|
4 |
|
5 |
-
tokenizer = AutoTokenizer.from_pretrained("
|
6 |
model = AutoModelForSequenceClassification.from_pretrained(
|
7 |
-
"ua-l/
|
8 |
)
|
9 |
|
10 |
topic_classifier = pipeline(
|
@@ -28,7 +28,7 @@ def predict(question):
|
|
28 |
|
29 |
return topics
|
30 |
|
31 |
-
inputs = gr.Textbox(lines=2, label="Enter the
|
32 |
|
33 |
outputs = gr.JSON(label="Output")
|
34 |
|
|
|
2 |
|
3 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification, pipeline
|
4 |
|
5 |
+
tokenizer = AutoTokenizer.from_pretrained("ua-l/is-legal-question")
|
6 |
model = AutoModelForSequenceClassification.from_pretrained(
|
7 |
+
"ua-l/is-legal-question"
|
8 |
)
|
9 |
|
10 |
topic_classifier = pipeline(
|
|
|
28 |
|
29 |
return topics
|
30 |
|
31 |
+
inputs = gr.Textbox(lines=2, label="Enter the question", value="Як отримати виплати ВПО?")
|
32 |
|
33 |
outputs = gr.JSON(label="Output")
|
34 |
|