Intelligent Harmful Content Detection System Using Machine Learning.
Abstract
-The rapid growth of digital communication and social media platforms has significantly increased the spread of harmful, abusive, offensive, and misleading content, creating serious challenges for maintaining a safe online environment. The increasing volume of user-generated content has made manual moderation difficult, time-consuming, and inefficient. To address this issue, thisproject, IntelligentHarmful Content Detection System Using Machine Learning," aims to develop an intelligent web-based platform capable of detecting and classifying harmful content from both textual inputs and images containing embedded text. The system integrates Machine Learning, Natural Language Processing (NLP), and Optical Character Recognition (OCR) technologies to provide accurate and efficient content moderation. The proposed system employs Logistic Regression as the primary machine learning algorithm for text classification and utilizes OCR to extract text from uploaded images before analysis. The collected textual data undergoes several preprocessing techniques, including text cleaning, case normalization, removal of special characters, stop-word elimination, tokenization, and feature extraction using Term Frequency–Inverse Document Frequency (TF-IDF). The trained model then analyses the processed data and classifies the content as either "Safe" or "Harmful", while also generating a confidence score and identifying harmful keywords that contribute to the prediction. A user-friendly web application developed using Python, the Flask framework, and SQLite enables users to register, log in, analyse text or image content, view real-time detection results, maintain analysis history, generate downloadable reports, and efficiently manage detection records. The system also provides dashboard statistics and an intuitive interface to improve usability and support effective monitoring of harmful online content. This project bridges the gap between Artificial Intelligence and digital safety by providing a fast, reliable, and data-driven solution for automated content moderation. It reduces dependence on manual content review, improves the efficiency of detecting cyber bullying, hate speech, harassment, abusive language, threats, and other harmful online communications, and promotes responsible digital interactions. The project demonstrates the practical application of Machine Learning, NLP, OCR, and modern web technologies in real-world cyber security and social media moderation, contributing to a safer and more secure digital ecosystem. Key Words:harmful content detection, machine learning, OCR, TF-IDF, NLP, Flask.