test0422 / app.py
grimzaeye's picture
Update app.py
dca3d49 verified
raw
history blame contribute delete
339 Bytes
import gradio as gr
from transformers import pipeline
sentiment = pipeline('sentiment-analysis')
def get_sentiment(input_text):
return sentiment(input_text)
# Gradio ์ธํ„ฐํŽ˜์ด์Šค ์„ค์ •
iface = gr.Interface(fn=get_sentiment, title="Sentiment Analysis", inputs="text", outputs="text")
# ์ธํ„ฐํŽ˜์ด์Šค ์‹คํ–‰
iface.launch()