Spaces:
Sleeping
Sleeping
Update app.py
Browse filesremove keyword extraction
app.py
CHANGED
@@ -10,7 +10,7 @@ from rouge import Rouge
|
|
10 |
from datasets import load_dataset
|
11 |
from extractive_summarization import summarize_with_textrank, summarize_with_lsa
|
12 |
from abstractive_summarization import summarize_with_bart_cnn, summarize_with_bart_ft, summarize_with_led, summarize_with_t5
|
13 |
-
from keyword_extraction import extract_keywords
|
14 |
from keyphrase_extraction import extract_sentences_with_obligations
|
15 |
from hybrid_summarization import summarize_hybrid
|
16 |
|
@@ -42,7 +42,7 @@ def main():
|
|
42 |
# Left column: Radio buttons for summarizer choice
|
43 |
with col1:
|
44 |
radio_options = ["Hybrid (RAKE + BART Fine-tuned)", "Abstractive (LongT5)", "Abstractive (LED)", 'Abstractive (BART Fine-tuned)', "Abstractive (BART-large-CNN)", 'Extractive (TextRank)',
|
45 |
-
"Extractive (Latent Semantic Analysis)", 'Keyphrase Extraction (RAKE)'
|
46 |
|
47 |
radio_selection = st.radio("Choose type of summarizer:", radio_options)
|
48 |
|
@@ -106,9 +106,9 @@ def main():
|
|
106 |
st.session_state.summary = summary
|
107 |
|
108 |
# Perform Keyword Extraction
|
109 |
-
if radio_selection == "Keyword Extraction (RAKE)":
|
110 |
-
|
111 |
-
|
112 |
|
113 |
# Perform Keyphrase Extraction
|
114 |
if radio_selection == "Keyphrase Extraction (RAKE)":
|
|
|
10 |
from datasets import load_dataset
|
11 |
from extractive_summarization import summarize_with_textrank, summarize_with_lsa
|
12 |
from abstractive_summarization import summarize_with_bart_cnn, summarize_with_bart_ft, summarize_with_led, summarize_with_t5
|
13 |
+
#from keyword_extraction import extract_keywords
|
14 |
from keyphrase_extraction import extract_sentences_with_obligations
|
15 |
from hybrid_summarization import summarize_hybrid
|
16 |
|
|
|
42 |
# Left column: Radio buttons for summarizer choice
|
43 |
with col1:
|
44 |
radio_options = ["Hybrid (RAKE + BART Fine-tuned)", "Abstractive (LongT5)", "Abstractive (LED)", 'Abstractive (BART Fine-tuned)', "Abstractive (BART-large-CNN)", 'Extractive (TextRank)',
|
45 |
+
"Extractive (Latent Semantic Analysis)", 'Keyphrase Extraction (RAKE)']
|
46 |
|
47 |
radio_selection = st.radio("Choose type of summarizer:", radio_options)
|
48 |
|
|
|
106 |
st.session_state.summary = summary
|
107 |
|
108 |
# Perform Keyword Extraction
|
109 |
+
#if radio_selection == "Keyword Extraction (RAKE)":
|
110 |
+
# summary = extract_keywords(file_content)
|
111 |
+
# st.session_state.summary = summary
|
112 |
|
113 |
# Perform Keyphrase Extraction
|
114 |
if radio_selection == "Keyphrase Extraction (RAKE)":
|