import streamlit as st from transformers import pipeline p = pipeline('sentiment-analysis') t = st.text_area('enter text') if t: out = p(t) st.json(out)