Analisis Komparasi Kinerja LSTM dan CNN dalam Deteksi Spam Email Berbasis Deep learning - Maugy Al Kautsar; Galet Guntoro Setiaji; Ahmad Rifa'i (Forum Kerjasama Pendidikan Tinggi (FKPT), 2025)
Spam email remains a critical issue in digital communication due to its potential misuse in spreading false information and online fraud. This study aims to evaluate and compare the performance of two deep learning models Convolutional Neural Network (CNN) and Long Short-Term Memory (LSTM) for text-based spam email classification. The dataset used in this study was obtained from Kaggle and contains 5,572 labeled email entries categorized as spam and non-spam. The preprocessing stage included labeling, cleaning, lowercasing (casefolding), tokenization, stopword removal, and stemming. The data was split into training and testing sets with a 70:30 ratio. Both models were trained using the same configuration and evaluated using accuracy, loss, confusion matrix, and F1-score metrics. The results indicate that the LSTM model achieved the highest accuracy of 98.72% with a loss value of 0.0377, outperforming the CNN model, which achieved 87.78% accuracy and a loss of 0.3659. Based on these findings, LSTM demonstrated superior performance in detecting spam emails using text-based input. This research is expected to serve as a reference for developing more accurate and effective spam detection systems in the future.