Update app.py
Browse files
app.py
CHANGED
@@ -7,18 +7,18 @@ from PIL import Image
|
|
7 |
## Main page
|
8 |
############
|
9 |
|
10 |
-
st.write("# Code for
|
11 |
|
12 |
-
st.markdown("***Idea is to build a model which will take
|
13 |
-
image = Image.open('
|
14 |
st.image(image)
|
15 |
|
16 |
st.sidebar.write("# Parameter Selection")
|
17 |
maxtags_sidebar = st.sidebar.slider('Number of tags allowed?', 1, 10, 1, key='ehikwegrjifbwreuk')
|
18 |
keywords = st_tags(
|
19 |
-
label='# Enter
|
20 |
text='Press enter to add more',
|
21 |
-
value=['
|
22 |
suggestions=['five', 'six', 'seven', 'eight', 'nine', 'three', 'eleven', 'ten', 'four'],
|
23 |
maxtags=maxtags_sidebar,
|
24 |
key="aljnf")
|
@@ -35,6 +35,6 @@ nlp=pipeline(option)
|
|
35 |
st.sidebar.success("Load Successfully!")
|
36 |
|
37 |
st.write("## Results:")
|
38 |
-
if st.button('Generate
|
39 |
out=nlp(keywords)
|
40 |
st.success(out)
|
|
|
7 |
## Main page
|
8 |
############
|
9 |
|
10 |
+
st.write("# Code for Keywords to Text")
|
11 |
|
12 |
+
st.markdown("***Idea is to build a model which will take keywords as inputs and generate information as outputs.***")
|
13 |
+
image = Image.open('1.png')
|
14 |
st.image(image)
|
15 |
|
16 |
st.sidebar.write("# Parameter Selection")
|
17 |
maxtags_sidebar = st.sidebar.slider('Number of tags allowed?', 1, 10, 1, key='ehikwegrjifbwreuk')
|
18 |
keywords = st_tags(
|
19 |
+
label='# Enter Keywords:',
|
20 |
text='Press enter to add more',
|
21 |
+
value=['Summer'],
|
22 |
suggestions=['five', 'six', 'seven', 'eight', 'nine', 'three', 'eleven', 'ten', 'four'],
|
23 |
maxtags=maxtags_sidebar,
|
24 |
key="aljnf")
|
|
|
35 |
st.sidebar.success("Load Successfully!")
|
36 |
|
37 |
st.write("## Results:")
|
38 |
+
if st.button('Generate Sentence'):
|
39 |
out=nlp(keywords)
|
40 |
st.success(out)
|