Abstract
Transformer-based models have gained traction for giving breakthrough performance on various Natural Language Processing (NLP) tasks in recent years. A number of studies have been conducted to understand the type of information learned by the model and its performance on different tasks. YouTube comments can serve as a rich source for multilingual data, which can be used to train state-of-the-art models. In this study, two transformer-based models, multilingual Bidirectional Encoder Representations from Transformers (mBERT) and RoBERTa, are fine-tuned and evaluated on code-mixed ‘Hinglish’ data. The representations learned by the intermediate layers of the models are also studied by using them as features for machine learning classifiers. The results show a significant improvement compared to the baseline for both datasets using the feature-based method, with the highest accuracy of 92.73% for Kabita Kitchen’s channel and 87.42% for Nisha Madhulika’s channel. Explanations of the model predictions using the Local Interpretable Model-Agnostic Explanations (LIME) technique show that the model is using significant features for classification and can be trusted.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
References
YouTube India Statistics. https://www.statista.com/statistics/280685/number-of-monthly-unique-youtube-users/. Accessed 26 July 2022
Arora, G.: iNLTK: natural language toolkit for Indic languages. arXiv preprint arXiv:2009.12534 (2020)
Jain, K., Deshpande, A., Shridhar, K., Laumann, F., Dash, A.: Indic-transformers: an analysis of transformer language models for Indian languages. arXiv preprint arXiv:2011.02323 (2020)
Kaur, G., Kaushik, A., Sharma, S.: Cooking is creating emotion: a study on Hinglish sentiments of YouTube cookery channels using semi-supervised approach. Big Data Cogn. Comput. 3(3), 37 (2019)
Donthula, S.K., Kaushik, A.: Man is what he eats: a research on Hinglish sentiments of YouTube cookery channels using deep learning. Int. J. Recent Technol. Eng. (IJRTE) 8(2S11), 930–937 (2019)
Yadav, S., Kaushik, A., Sharma, S.: Cooking well, with love, is an art: transformers on YouTube Hinglish data. In: 2021 International Conference on Computational Performance Evaluation (ComPE), pp. 836–841. IEEE (2021)
Vaswani, A., et al.: Attention is all you need. In: Advances in Neural Information Processing Systems, vol. 30 (2017)
Devlin, J., Chang, M.W., Lee, K., Toutanova, K.: BERT: pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805 (2018)
Polignano, M., Basile, P., De Gemmis, M., Semeraro, G., Basile, V.: ALBERTO: Italian BERT language understanding model for NLP challenging tasks based on tweets. In: 6th Italian Conference on Computational Linguistics, CLiC-it 2019, vol. 2481, pp. 1–6. CEUR (2019)
de Vries, W., van Cranenburgh, A., Bisazza, A., Caselli, T., van Noord, G., Nissim, M.: BERTje: a Dutch BERT model. arXiv preprint arXiv:1912.09582 (2019)
Lee, S., Jang, H., Baik, Y., Park, S., Shin, H.: KR-BERT: a small-scale Korean-specific language model. arXiv preprint arXiv:2008.03979 (2020)
Martin, L., et al.: CamemBERT: a tasty French language model. arXiv preprint arXiv:1911.03894 (2019)
Adadi, A., Berrada, M.: Peeking inside the black-box: a survey on explainable artificial intelligence (XAI). IEEE Access 6, 52138–52160 (2018)
Ribeiro, M.T., Singh, S., Guestrin, C.: “why should i trust you?” Explaining the predictions of any classifier. In: Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, pp. 1135–1144 (2016)
Liu, Y., et al.: RoBERTA: a robustly optimized BERT pretraining approach. arXiv preprint arXiv:1907.11692 (2019)
Kabita’s Kitchen Cookery Channel. https://www.Youtube.com/ channel/CChqsCRFePrP2X897iQkyAA. Accessed 10 July 2022
Nisha Madhulika’s Cookery Channel. https://www.Youtube.com/user/NishaMadhulika. Accessed 10 July 2022
Kaushik, A., Kaur, G.: YouTube cookery channels viewers comments in Hinglish, May 2019. https://doi.org/10.5281/zenodo.2841848
Mathew, B., Saha, P., Yimam, S.M., Biemann, C., Goyal, P., Mukherjee, A.: HateXplain: a benchmark dataset for explainable hate speech detection. In: Proceedings of the AAAI Conference on Artificial Intelligence, vol. 35, no. 17, pp. 14867–14875 (2021)
Rogers, A., Kovaleva, O., Rumshisky, A.: A primer in BERTology: what we know about how BERT works. Trans. Assoc. Comput. Linguist. 8, 842–866 (2020)
Sang, E.F., De Meulder, F.: Introduction to the CoNLL-2003 shared task: language-independent named entity recognition. arXiv preprint cs/0306050 (2003)
Yang, J., Zhao, H.: Deepening hidden representations from pre-trained language models. arXiv preprint arXiv:1911.01940 (2019)
Su, T.C., Cheng, H.C.: SesameBERT: attention for anywhere. In: 2020 IEEE 7th International Conference on Data Science and Advanced Analytics (DSAA), pp. 363–369. IEEE (2020)
McCoy, R.T., Pavlick, E., Linzen, T.: Right for the wrong reasons: diagnosing syntactic heuristics in natural language inference. arXiv preprint arXiv:1902.01007 (2019)
Kazhuparambil, S., Kaushik, A.: Classification of Malayalam-English mix-code comments using current state of art. In: 2020 IEEE International Conference for Innovation in Technology (INOCON), pp. 1–6. IEEE (2020)
Patwa, P., et al.: SemEval-2020 task 9: overview of sentiment analysis of code-mixed tweets. In: Proceedings of the Fourteenth Workshop on Semantic Evaluation, pp. 774–790 (2020)
Bhange, M., Kasliwal, N.: HinglishNLP at SemEval-2020 task 9: fine-tuned language models for Hinglish sentiment detection. In: Proceedings of the Fourteenth Workshop on Semantic Evaluation, pp. 934–939 (2020)
Szczepański, M., Pawlicki, M., Kozik, R., Choraś, M.: New explainability method for BERT-based model in fake news detection. Sci. Rep. 11(1), 1–13 (2021)
BERT Word Embeddings Tutorial. https://mccormickml.com/2019/05/14/BERT-word-embeddings-tutorial/. Accessed 13 July 2022
A Visual Guide to Using BERT for the First Time. https://jalammar.github.io/a-visual-guide-to-using-bert-for-the-first-time/. Accessed 13 July 2022
Wolf, T., et al.: HuggingFace’s transformers: state-of-the-art natural language processing. arXiv preprint arXiv:1910.03771 (2019)
Paszke, A., et al.: Pytorch: an imperative style, high-performance deep learning library. In: Wallach, H., Larochelle, H., Beygelzimer, A., d’Alché-Buc, F., Fox, E., Garnett, R. (eds.) Advances in Neural Information Processing Systems, vol. 32, pp. 8024–8035. Curran Associates, Inc. (2019). https://papers.neurips.cc/paper/9015-pytorch-an-imperative-style-high-performance-deep-learning-library.pdf
Scikit Learn: Machine Learning in Python. https://scikit-learn.org/stable/. Accessed 25 Oct 2022
Shah, S.R., Kaushik, A.: Sentiment analysis on Indian indigenous languages: a review on multilingual opinion mining. arXiv preprint arXiv:1911.12848 (2019)
Bishop, C.M., Nasrabadi, N.M.: Pattern Recognition and Machine Learning, vol. 4, no. 4. Springer, New York (2006)
Hand, D.J., Till, R.J.: A simple generalisation of the area under the ROC curve for multiple class classification problems. Mach. Learn. 45(2), 171–186 (2001)
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2023 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Yadav, S., Kaushik, A. (2023). Contextualized Embeddings from Transformers for Sentiment Analysis on Code-Mixed Hinglish Data: An Expanded Approach with Explainable Artificial Intelligence. In: M, A.K., et al. Speech and Language Technologies for Low-Resource Languages . SPELLL 2022. Communications in Computer and Information Science, vol 1802. Springer, Cham. https://doi.org/10.1007/978-3-031-33231-9_7
Download citation
DOI: https://doi.org/10.1007/978-3-031-33231-9_7
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-33230-2
Online ISBN: 978-3-031-33231-9
eBook Packages: Computer ScienceComputer Science (R0)