A Machine Learning-Based Framework for Detection and Classification of Spam and Malicious Textual Content on X Using Large-Scale Social Media Data

This study presents a hybrid CNN-BiLSTM deep learning approach for detecting spam accounts and harmful content on X. The proposed method combines textual features with account-level metadata and compares its performance with traditional machine learning algorithms, including Logistic Regression, Naïve Bayes, SVM, and Random Forest. Experimental results on a dataset of 50,000 tweets achieved 97% accuracy, 96% precision, 96% recall, and 96% F1-score. The findings demonstrate that the proposed hybrid approach effectively improves spam and harmful content detection while providing a reliable and scalable solution for enhancing social media security.