--- title: Profanity Detection & Replacement System emoji: 🚫 colorFrom: red colorTo: blue sdk: gradio sdk_version: 5.21.0 app_file: profanity_detector.py pinned: false --- # Profanity Detection & Replacement System This app provides a comprehensive solution for detecting and cleaning profanity from both text and audio content. It uses state-of-the-art machine learning models to analyze content, identify inappropriate language, and generate clean alternatives. ### GitHub Repository QR Code ## Features - 🔍 Real-time profanity detection with adjustable sensitivity - 🔄 Automatic text rephrasing to clean alternatives - 🎤 Speech-to-text conversion with profanity filtering - 🗣️ Text-to-speech generation for clean content - 💻 User-friendly Gradio interface - 🔄 Real-time streaming support for live audio processing ## Models Used - Profanity Detection: `parsawar/profanity_model_3.1` - Text Detoxification: `s-nlp/t5-paranmt-detox` - Speech Recognition: OpenAI Whisper (large-v2) - Text-to-Speech: Microsoft SpeechT5 ## Requirements - Python 3.10 - PyTorch with CUDA support - Gradio - Transformers - OpenAI Whisper - Other dependencies listed in `requirements.txt` ## Interface The app provides three main interaction modes: 1. **Text Analysis**: Enter text to detect and clean profanity 2. **Audio Analysis**: Upload or record audio for profanity detection 3. **Real-time Streaming**: Process live audio with instant profanity filtering ## Technical Details - GPU acceleration supported for faster processing - Memory-optimized with FP16 precision where available - Configurable profanity detection threshold - Built-in error handling and logging - Dark mode support ## Team Members - Brian Tham - Hong Ziyang - Nabil Zafran - Adrian Ian Wong - Lin Xiang Hong