rezyek06's picture
Create app.py
0e06909 verified
raw
history blame contribute delete
308 Bytes
from transformers import pipeline
import gradio as gr
model = pipeline(model="seara/rubert-tiny2-ru-go-emotions")
def text_classification(data):
result = model(data)[0]['label']
return result
demo = gr.Interface(fn=text_classification, inputs="textbox", outputs="textbox")
demo.launch(share=True)