Ramji commited on
Commit
b095b79
·
verified ·
1 Parent(s): ae8445c
Files changed (1) hide show
  1. app.py +1 -5
app.py CHANGED
@@ -17,15 +17,11 @@ st.write("This app uses a Finetuned Bart model to summarize long text inputs.")
17
  # Input text area for the user
18
  user_input = st.text_area("Enter text to summarize:", height=300)
19
 
20
- # Set summary parameters (optional)
21
- max_length = st.slider("Maximum Summary Length", 30, 500, 150)
22
- min_length = st.slider("Minimum Summary Length", 10, 100, 30)
23
-
24
  # Summarize when the button is clicked
25
  if st.button("Summarize"):
26
  if user_input:
27
  # Get the summary
28
- summary = summarizer(user_input, max_length=max_length, min_length=min_length, do_sample=False)
29
  # Display the result
30
  st.subheader("Summary")
31
  st.write(summary[0]['summary_text'])
 
17
  # Input text area for the user
18
  user_input = st.text_area("Enter text to summarize:", height=300)
19
 
 
 
 
 
20
  # Summarize when the button is clicked
21
  if st.button("Summarize"):
22
  if user_input:
23
  # Get the summary
24
+ summary = summarizer(user_input)
25
  # Display the result
26
  st.subheader("Summary")
27
  st.write(summary[0]['summary_text'])