Prompt2Image-Generator converts text prompts into images using Hugging Face's sd-community/sdxl-flash model and a Gradio interface. API keys are securely managed via environment variables.
-
Clone the repository:
git clone https://github.com/yourusername/Prompt2Image-Generator.git cd Prompt2Image-Generator -
Install dependencies:
pip install gradio requests huggingface_hub Pillow transformers -
Set your Hugging Face API key:
export HF_API_KEY="your_api_key_here" -
Run the application:
python app.py