shamim237 commited on
Commit
e674072
·
1 Parent(s): f11b302

Upload 3 files

Browse files
apps/paraphraseApp.py ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import streamlit as st
2
+ from scrap import extract
3
+ from paraphraser import parphrase
4
+
5
+ def app():
6
+ st.title('Paraphraser')
7
+ st.write('Please provide a link or copy and paste this link in the cell below- https://www.amazon.com/dp/B09B9TB61G')
8
+ user_input = st.text_input('Enter website link','')
9
+ with st.spinner('Please wait...'):
10
+ if st.button('Paraphrase'):
11
+ data = extract(user_input)
12
+ output = parphrase(data)
13
+ output = " ".join(output)
14
+ st.write("Paraphrased Text: ")
15
+ st.write(output)
16
+ st.success("Done!")
apps/scraperrApp.py ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import re
2
+ import streamlit as st
3
+ from scrap import extract
4
+
5
+ def app():
6
+ st.title('Scraper')
7
+ st.write('Please provide a link or copy and paste this link- https://www.amazon.com/dp/B09B9TB61G')
8
+ user_input = st.text_input('Enter website link','')
9
+ with st.spinner('Please wait...'):
10
+ if st.button('Scrape'):
11
+ data = extract(user_input)
12
+ sen = []
13
+ for i in data:
14
+ res = len(re.findall(r'\w+', i))
15
+ if res == 2:
16
+ pass
17
+ else:
18
+ res = i.replace('"', "'").replace("\n", "")
19
+ sen.append(res)
20
+
21
+ pas = " ".join(sen)
22
+ st.write("Scrapted data: ")
23
+ st.write(pas)
24
+ st.success("Done!")
apps/summarizerApp.py ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import streamlit as st
2
+ from scrap import extract
3
+ from paraphraser import parphrase
4
+ from summary import text_summary
5
+
6
+
7
+ def app():
8
+ st.title('Summarizer')
9
+ st.write('Please provide a link or copy and paste this link- https://www.amazon.com/dp/B09B9TB61G')
10
+ user_input = st.text_input('Enter website link','')
11
+ with st.spinner('Please wait...'):
12
+ if st.button('Summarize'):
13
+ data = extract(user_input)
14
+ paras = parphrase(data)
15
+ summ = text_summary(paras)
16
+ output1 = " ".join(summ)
17
+ st.write("Text Summary: ")
18
+ st.write(output1)
19
+ st.success('Done!')