Spaces:
Sleeping
Sleeping
import streamlit as st | |
from transformers import pipeline | |
st.title("Sentiment Bot") | |
Sentiment_pipeline=pipeline("sentiment-analysis") | |
user_input=st.text_area("Enter the review") | |
if st.button("Analyse:"): | |
result=Sentiment_pipeline(user_input) | |
# print(result[0]['label']) | |
# print(result[0]['score']) | |
st.write("Sentiment", result[0]['label']) | |
st.write("Confidence Score", result[0]['score']) |