Skip to main content

Comparative Analysis of Emotion Recognition Using Large Language Models and Conventional Machine Learning

  • Conference paper
  • First Online:
Data Science and Emerging Technologies (DaSET 2023)

Abstract

Emotions are significant aspects of human existence and influence interaction between individuals and groups, influencing how we think and behave. In this research, we aim to use conventional and neural network models to identify emotions from textual data and compare which performed best. The Go Emotions dataset contained 27 different emotions across 58,000 samples. The approach involves modelling the conventional machine learning models and the neural network-based models and comparing the results over test dataset and choosing the best model. Upon comparing the classification reports for the conventional and neural network-based models on the Ekman taxonomy, conventional machine learning algorithms were outperformed by neural network-based models which gained almost 10% more than conventional models. Conventional models averaged the values around 50% of macro-average F1-score except for the KNN classifier which performed poorly getting the macro-average F1-score of 21%. BERT classifier with Ekman taxonomy including neutral emotion had a macro-average precision of 55% and a sensitivity of 68%. This classifier also outperformed the macro-average F1-score by 106 61%. While the RoBERTa classifier had a macro-average precision of 65%, the recall, or sensitivity, was found to be 53%. This study clearly states that neural network-based models outperformed conventional models. Our study proposed BERT model which achieved a macro-average F1-score of 0.50 across Go Emotion taxonomy.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 189.00
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 249.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

References

  1. Kamath R, Ghoshal A, Eswaran S, Honnavalli P (2022) An enhanced context-based emotion detection model using RoBERTa. In: 2022 IEEE international conference on electronics, computing and communication technologies (CONECCT). IEEE, pp 1–6

    Google Scholar 

  2. Malviya K, Roy B, Saritha SK (2021) A transformers approach to detect depression in social media. In: 2021 international conference on artificial intelligence and smart systems (ICAIS). IEEE, pp 718–723

    Google Scholar 

  3. Meisheri H, Dey L (2018) Tcs research at semeval-2018 task 1: learning robust representations using multi-attention architecture. In: Proceedings of The 12th international workshop on semantic evaluation, pp 291–299

    Google Scholar 

  4. Nimmi K, Janet B, Selvan AK, Sivakumaran N (2022) Pre-trained ensemble model for identification of emotion during COVID-19 based on emergency response support system dataset. Appl Soft Comput 122

    Google Scholar 

  5. Rajendram SM, Mirnalinee TT (2022) Contextual emotion detection on text using gaussian process and tree based classifiers. Intell Data Anal 261:119–132

    Google Scholar 

  6. Senn S, Tlachac M, Flores R, Rundensteiner E (2022) Ensembles of BERT for depression classification. In: 2022 44th annual international conference of the IEEE engineering in medicine & biology society (EMBC). [online] IEEE, pp 4691–4694. Available at: https://ieeexplore.ieee.org/document/9871120/

  7. Ab Nasir AF, Seok Nee E, Sern Choong C, Shahrizan Abdul Ghani A, Abdul Majeed APP, Adam A, Furqan M (2020) Text-based emotion prediction system using machine learning approach. In: IOP conference series: materials science and engineering. Institute of Physics Publishing

    Google Scholar 

  8. Chowanda A, Sutoyo R, Meiliana ST (2021) Exploring text-based emotions recognition machine learning techniques on social media conversation. Procedia Comput Sci 821–828

    Google Scholar 

  9. Saad MM, Jamil N, Hamzah R (2018) Evaluation of support vector machine and decision tree for emotion recognition of malay folklores. Bull Electr Eng Inform 73:479–486

    Article  Google Scholar 

  10. Alm CO, Roth D, Sproat R (2005) Emotions from text: machine learning for text-based emotion prediction. In: Proceedings of human language technology conference and conference on empirical methods in natural language processing, pp 579–586

    Google Scholar 

  11. Desmet B, Hoste V (2013) Emotion detection in suicide notes. Exp Syst Appl 4016:6351–6358

    Article  Google Scholar 

  12. Gievska S, Koroveshovski K, Chavdarova T (2014) A hybrid approach for emotion detection in support of affective interaction. In: 2014 IEEE international conference on data mining workshop, IEEE, pp 352–359

    Google Scholar 

  13. Gupta A, Sahu H, Nanecha N, Kumar P, Roy PP, Chang V (2019) Enhancing text using emotion detected from EEG signals. J Grid Comput 172:325–340

    Article  Google Scholar 

  14. Acheampong FA, Nunoo-Mensah H, Chen W (2021) Transformer models for text-based emotion detection: a review of BERT-based approaches. Artif Intell Rev 548:5789–5829

    Article  Google Scholar 

  15. Santhosh Baboo S, Amirthapriya M (2022) Sentiment analysis and automatic emotion detection analysis of twitter using machine learning classifiers. Int J Mechan Eng

    Google Scholar 

  16. Lee SYM, Chen Y, Huang C-R (2010) A text-driven rule-based system for emotion cause detection. In: Proceedings of the NAACL HLT 2010 workshop on computational approaches to analysis and generation of emotion in text, pp 45–53

    Google Scholar 

  17. Tao J (2004) Context based emotion detection from text input. In: 8th international conference on spoken language processing, ICSLP 2004. International Speech Communication Association, pp 1337–1340

    Google Scholar 

  18. Yousaf A, Umer M, Sadiq S, Ullah S, Mirjalili S, Rupapara V, Nappi M (2021) Emotion recognition by textual tweets classification using voting classifier (LR-SGD). IEEE Access 9:6286–6295

    Article  Google Scholar 

  19. Deshpande M, Rao V (2017) Depression detection using emotion artificial intelligence. GoEmotions: a dataset of fine-grained emotions. arXiv preprint arXiv:2005.00547

  20. Singh G, Brahma D, Rai P, Modi A (2021) Fine-grained emotion prediction by modeling emotion definitions. In: 2021 9th international conference on affective computing and intelligent interaction, ACII 2021. Institute of Electrical and Electronics Engineers Inc.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Thomas Coombs .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2024 The Author(s), under exclusive license to Springer Nature Singapore Pte Ltd.

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Soujanya Rao, M., Coombs, T., Binti Mohamad, N., Kumar, V., Jayabalan, M. (2024). Comparative Analysis of Emotion Recognition Using Large Language Models and Conventional Machine Learning. In: Bee Wah, Y., Al-Jumeily OBE, D., Berry, M.W. (eds) Data Science and Emerging Technologies. DaSET 2023. Lecture Notes on Data Engineering and Communications Technologies, vol 191. Springer, Singapore. https://doi.org/10.1007/978-981-97-0293-0_16

Download citation

Publish with us

Policies and ethics