multi-label / app.py
winain7788's picture
change model
a4a7478
raw
history blame
254 Bytes
import gradio as gr
from transformers import pipeline
sentiment_pipeline = pipeline("sentiment-analysis")
async def process(text):
return await sentiment_pipeline(text)
demo = gr.Interface(fn=process, inputs="text", outputs="json")
demo.launch()