CoolFace
Apppublic

nightey3s/profanity-detection

sourceHugging Faceupdated 2y agoView on Hugging Face
3likes
App README

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

<img src="https://briantham.com/assets/img/projects/qr-code/Profanity-Detection-github-qr-code.svg?sanitize=true" alt="QR Code" width="300" />

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. 1.Text Analysis: Enter text to detect and clean profanity
  2. 2.Audio Analysis: Upload or record audio for profanity detection
  3. 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