File size: 398 Bytes
32443bc
 
 
 
 
51bae80
 
32443bc
 
 
 
 
51bae80
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import streamlit as st
from transformers import pipeline

st.title("Social Media Posts Emotion")

pipeline = pipeline("text-classification","Jingni/transient_data")
pipeline_2 = pipeline("text-classification", "Jingni/tweet_eval")

text = st.write("Enter a social media post to analyze its emotion:")

if text:
    out =pipe(text)
    st.json(out)

if text:
    out2= pipe_2(text)
    st.json(out2)