--- title: Sentiment-Aware Text Generator emoji: 🤖 colorFrom: purple colorTo: indigo sdk: streamlit app_file: app.py pinned: false --- # Sentiment-Aware Text Generator This app leverages Hugging Face pretrained models to generate paragraphs aligned with the sentiment of an input prompt. ## How It Works 1. The user enters a text prompt into the Streamlit web interface. 2. The app uses a RoBERTa-based sentiment analysis model to classify the sentiment as positive, negative, or neutral. 3. Based on this sentiment, it crafts a prompt for text generation. 4. The Qwen text-generation model generates a paragraph matching the detected sentiment. 5. The app displays both the detected sentiment and the generated paragraph interactively. ## Requirements The app requires Python packages listed in `requirements.txt`, including: - streamlit - transformers - torch ## Running the App To run: https://huggingface.co/spaces/dimoZ/AI_Sentiment_Essay_Generato