Spaces:
Sleeping
Sleeping
FrancoisHB
commited on
Commit
•
9f27a52
1
Parent(s):
624b7b6
Commit Test SRT
Browse files
app.py
CHANGED
@@ -1,15 +1,8 @@
|
|
|
|
1 |
from transformers import pipeline
|
2 |
|
3 |
-
|
4 |
-
|
5 |
-
summary = summarizer(input_text, max_length=max_length)
|
6 |
-
return summary[0]['summary_text']
|
7 |
|
8 |
-
|
9 |
-
|
10 |
-
summary = summarize_text(input_text)
|
11 |
-
print("Summary:")
|
12 |
-
print(summary)
|
13 |
-
|
14 |
-
if __name__ == "__main__":
|
15 |
-
main()
|
|
|
1 |
+
import streamlit as st
|
2 |
from transformers import pipeline
|
3 |
|
4 |
+
pipe = pipeline('sentiment-analysis')
|
5 |
+
text = st.text_area('enter some text:')
|
|
|
|
|
6 |
|
7 |
+
if text:
|
8 |
+
out = pipe()
|
|
|
|
|
|
|
|
|
|
|
|