Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,15 +1,15 @@
|
|
| 1 |
-
import
|
| 2 |
import json
|
| 3 |
|
| 4 |
-
from transformers import pipeline
|
| 5 |
-
classifier = pipeline("zero-shot-classification", model="facebook/bart-large-mnli")
|
| 6 |
|
| 7 |
def tagging(
|
| 8 |
input: str,
|
| 9 |
tags: tuple[str]
|
| 10 |
):
|
| 11 |
text = json.loads(str)
|
| 12 |
-
return text
|
| 13 |
|
| 14 |
app = gr.Interface(fn=tagging, inputs=[
|
| 15 |
gr.Textbox(label="Your input here"),
|
|
|
|
| 1 |
+
import gradio as gr
|
| 2 |
import json
|
| 3 |
|
| 4 |
+
# from transformers import pipeline
|
| 5 |
+
# classifier = pipeline("zero-shot-classification", model="facebook/bart-large-mnli")
|
| 6 |
|
| 7 |
def tagging(
|
| 8 |
input: str,
|
| 9 |
tags: tuple[str]
|
| 10 |
):
|
| 11 |
text = json.loads(str)
|
| 12 |
+
return text
|
| 13 |
|
| 14 |
app = gr.Interface(fn=tagging, inputs=[
|
| 15 |
gr.Textbox(label="Your input here"),
|