A hybrid CNN-BiGRU-attention architecture for enhanced spam email classification
摘要
Email spam detection remains a critical challenge in cybersecurity, as malicious emails and phishing attacks continue to impose substantial economic losses and security risks on organizations. This study presents a hybrid deep learning architecture that integrates Convolutional Neural Networks (CNNs), Bidirectional Gated Recurrent Units (BiGRUs), and an attention mechanism for effective spam email classification. The CNN branch captures local lexical patterns and n-gram features, while the BiGRU branch models long-range sequential dependencies in a bidirectional manner. The attention mechanism further enhances performance by selectively emphasizing salient discriminative features within email content. The proposed framework is evaluated on four widely used benchmark datasets using holdout split evaluation, five-fold cross-validation, and external (cross-dataset) validation. Experimental results demonstrate competitive performance, achieving accuracy of 99.53% on TREC-07, 99.15% on Enron, 99.14% on Spam-Assassin, and 98.96% on Ling-Spam, under comparable experimental settings. Notably, these results are obtained using standard consumer-grade hardware without GPU acceleration, highlighting the model's practical deployability in resource-constrained environments. Overall, this study suggests that the proposed framework offers a computationally efficient and practically deployable approach to spam detection, achieving competitive performance with a balanced trade-off between accuracy and generalization.