Authors: Sufiyan Ansari, Arhaan Shaikh, Usaid Khairdi, Moaiz Kazi
Abstract: Text classification has numerous applications in real world scenarios. Emotion detection from text is one of the vital tasks within natural language processing, which has gained significant attention of researchers over the years. In this study, emotions are detected and classified for better human–computer interaction, sentiment analysis, health management, and smart chattingbots. A number of deep learning models are developed and outperform the traditional models for the classification. Con- volutional Neural Networks (CNN), Long Short-Term Memory (LSTM), and hybrid of CNN and LSTM are used for emotion classification. Furthermore, two traditional machine learning ap- proaches including Logistic Regression and Naive Bayes are also implemented for comparison purpose. Preprocessing is a very important step for a good model. Text normalization, stop words removal, tokenization, and padding are used for data preparation. Word embeddings, specifically pre-trained word2vec, are used to capture the semantic relationship of text features learned from deep learning models. The performance evaluation of these models is done using accuracy, precision, recall, F1-score, and confusion matrix. The experimental results show that the deep learning models have outperformed the traditional models. The hybrid CNN-LSTM model achieved the best results to classify emotions in multi-class problem.