Spaces:
Sleeping
Sleeping
File size: 984 Bytes
345cd4f 4dafe55 ae08c02 4dafe55 345cd4f ae08c02 4dafe55 345cd4f 4dafe55 345cd4f 4dafe55 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 |
import streamlit as st
def generate_blog_title(name, audience, word_count):
title = f"**Title:** {name} - A {audience} Guide to {word_count} Words"
return title
def main():
st.title("🔥 Professional Blog Generator 🔥")
st.markdown(
"""
<style>
body {
background-color: #121212;;
color: white;
}
</style>
""",
unsafe_allow_html=True
)
st.sidebar.header("Input Parameters")
role = st.sidebar.text_input("Who is this intednded for ?", "Ex - Data Scientist")
topic = st.sidebar.text_input("On what Topic should the blog be on ?", "Ex - Machine Learning")
word_count = st.sidebar.slider("Number of Words", min_value=50, max_value=1000, value=200, step=50)
if st.sidebar.button("Generate Blog"):
blog_content = generate_blog(name, role, topic, word_count)
st.markdown(blog_content, unsafe_allow_html=True)
if __name__ == "__main__":
main()
|