Spaces:
Sleeping
Sleeping
import streamlit as st | |
from StreamlitModel import TextGeneration | |
def main(): | |
st.title("Lyrics Generation") | |
st.text("Enter your prompt here to generate lyrics for your new hit song!") | |
st.text("This is a work in progress, and I will update it as needed") | |
st.text("Please allow a minute for the text to generate") | |
st.text("You can refer to the github repository in the link below for more info") | |
st.write("[Repository](https://github.com/Selbl/LyricGeneration)") | |
# User input for prompt | |
prompt = st.text_area("Enter your prompt here:") | |
# Button to generate text | |
if st.button("Generate Text"): | |
if prompt: | |
# Call your function to generate text | |
generated_text = TextGeneration(prompt) | |
st.subheader("Generated Text:") | |
st.write(generated_text) | |
else: | |
st.warning("Please enter a prompt.") | |
if __name__ == "__main__": | |
main() |