WillWEI0103 commited on
Commit
02ec538
·
verified ·
1 Parent(s): dc970a3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -15,20 +15,20 @@ def main():
15
  if text is not None:
16
  st.text('Your Finance news: ')
17
  st.write(text)
18
- st.slider(min_value=0, max_value=100,value=[0,100])
19
  st.divider() # Draws a horizontal rule
20
  #Stage 1: Text Summarization
21
  st.text('Processing Finance News Summarization...')
22
  text_summarize=pipeline("summarization", model="nickmuchi/fb-bart-large-finetuned-trade-the-event-finance-summarizer")
23
  summary=text_summarize(text)[0]['summary_text']
24
  st.write(summary)
25
- st.slider(min_value=0, max_value=100,value=[0,100])
26
  st.divider() # Draws a horizontal rule
27
  #Stage 2: Sentiment Analytics
28
  st.text('Processing Sentiment Analytics...')
29
  label = sentiment(summary)
30
  label=dicts[label]
31
- st.slider(min_value=0, max_value=100,value=[0,100])
32
  st.divider() # Draws a horizontal rule
33
  st.text('The sentiment of finance news is: ')
34
  st.write(label)
 
15
  if text is not None:
16
  st.text('Your Finance news: ')
17
  st.write(text)
18
+ st.slider(label='',min_value=0, max_value=100,value=[0,100])
19
  st.divider() # Draws a horizontal rule
20
  #Stage 1: Text Summarization
21
  st.text('Processing Finance News Summarization...')
22
  text_summarize=pipeline("summarization", model="nickmuchi/fb-bart-large-finetuned-trade-the-event-finance-summarizer")
23
  summary=text_summarize(text)[0]['summary_text']
24
  st.write(summary)
25
+ st.slider(label='',min_value=0, max_value=100,value=[0,100])
26
  st.divider() # Draws a horizontal rule
27
  #Stage 2: Sentiment Analytics
28
  st.text('Processing Sentiment Analytics...')
29
  label = sentiment(summary)
30
  label=dicts[label]
31
+ st.slider(label='',min_value=0, max_value=100,value=[0,100])
32
  st.divider() # Draws a horizontal rule
33
  st.text('The sentiment of finance news is: ')
34
  st.write(label)