Team Ai
Apppublic

dev114/sentiment-analysis

sourceHugging Faceotherupdated 5y agoView on Hugging Face
1likes
app.py11 linesDownload Raw Back to root
1import gradio as gr2 3from transformers import pipeline4 5sentiment = pipeline("sentiment-analysis")6 7def get_sentiment(input_text):8  return sentiment(input_text)9  10iface = gr.Interface(fn = get_sentiment, inputs = "text", outputs = ['text'], title ='Sentiment Analysis', description="Get Sentiment Negative/Positive for the given input")11iface.launch()