AjithBharadwaj commited on
Commit
4dafe55
1 Parent(s): 345cd4f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +20 -7
app.py CHANGED
@@ -5,16 +5,29 @@ def generate_blog_title(name, audience, word_count):
5
  return title
6
 
7
  def main():
8
- st.title("Blog Title Generator")
 
 
 
 
 
 
 
 
 
 
 
9
 
10
  st.sidebar.header("Input Parameters")
11
- name = st.sidebar.text_input("Name of the Blog", "10 Tips for Success")
12
- audience = st.sidebar.selectbox("Intended Audience", ["Beginner", "Intermediate", "Expert"])
13
- word_count = st.sidebar.number_input("Word Count", min_value=100, max_value=5000, value=100, step=100)
 
14
 
15
- if st.sidebar.button("Generate Title"):
16
- blog_title = generate_blog_title(name, audience, word_count)
17
- st.success(blog_title)
18
 
19
  if __name__ == "__main__":
20
  main()
 
 
5
  return title
6
 
7
  def main():
8
+ st.title("🔥 Professional Blog Generator 🔥")
9
+ st.markdown(
10
+ """
11
+ <style>
12
+ body {
13
+ background-color: #1E1E1E;
14
+ color: white;
15
+ }
16
+ </style>
17
+ """,
18
+ unsafe_allow_html=True
19
+ )
20
 
21
  st.sidebar.header("Input Parameters")
22
+ name = st.sidebar.text_input("Your Name", "John Doe")
23
+ role = st.sidebar.text_input("Professional Role", "Data Scientist")
24
+ topic = st.sidebar.text_input("Topic", "Machine Learning")
25
+ word_count = st.sidebar.slider("Number of Words", min_value=50, max_value=1000, value=200, step=50)
26
 
27
+ if st.sidebar.button("Generate Blog"):
28
+ blog_content = generate_blog(name, role, topic, word_count)
29
+ st.markdown(blog_content, unsafe_allow_html=True)
30
 
31
  if __name__ == "__main__":
32
  main()
33
+