Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,12 +1,10 @@
|
|
| 1 |
import os
|
| 2 |
import streamlit as st
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
)
|
| 12 |
-
st.write(response.choices[0].message.content)
|
|
|
|
| 1 |
import os
|
| 2 |
import streamlit as st
|
| 3 |
+
|
| 4 |
+
from transfomers import pipeline
|
| 5 |
+
inp=st.text_input("Enter the text")
|
| 6 |
+
btn=st.button("Submit")
|
| 7 |
+
pipe=pipeline(task='text_classification',model='cardiffnlp/twitter-roberta-base-sentiment-latest')
|
| 8 |
+
|
| 9 |
+
if(inp and btn):
|
| 10 |
+
st.write(pipe(text))
|
|
|
|
|
|