AI Based Emotion Detection for Textual Big Data: Techniques and Contribution

: Online Social Media (OSM) like Facebook and Twitter has emerged as a powerful tool to express via text people’s opinions and feelings about the current surrounding events. Understand ‐ ing the emotions at the fine ‐ grained level of these expressed thoughts is important for system im ‐ provement. Such crucial insights cannot be completely obtained by doing AI ‐ based big data senti ‐ ment analysis; hence, text ‐ based emotion detection using AI in social media big data has become an upcoming area of Natural Language Processing research. It can be used in various fields such as understanding expressed emotions, human–computer interaction, data mining, online education, recommendation systems, and psychology. Even though the research work is ongoing in this do ‐ main, it still lacks a formal study that can give a qualitative (techniques used) and quantitative (con ‐ tributions) literature overview. This study has considered 827 Scopus and 83 Web of Science re ‐ search papers from the years 2005–2020 for the analysis. The qualitative review represents different emotion models, datasets, algorithms, and application domains of text ‐ based emotion detection. The quantitative bibliometric review of contributions presents research details such as publications, volume, co ‐ authorship networks, citation analysis, and demographic research distribution. In the end, challenges and probable solutions are showcased, which can provide future research directions in this area.


Introduction
Out of 7.8 billion people worldwide, 50.64% of the population uses social networks, irrespective of their age [1]. Presently popular social networking sites like Facebook, Instagram, YouTube, WhatsApp, FB messenger, Twitter, and Reddit are used by this population. In addition, Twitter, Instagram, and Reddit are very widely used microblogging sites where people make short, frequent posts from these social networks.
Online Social Media (OSM) platforms provide the opportunity to express, communicate, and share people's opinions, thoughts, views, and perspectives-on local and international issues, matters, and topics-through text, image, audio, and video posts. Posts on social media are public and abundant in emotions. Analyzing and studying these posts from social media may indicate emotional states and the reasons behind those emotions. However, the massive volume of this data makes this analysis very difficult. Artificial Intelligence can help to find emotions, feelings, personal traits, views, and their effects on Figure 1 shows the process flow of text-based emotion detection using artificial intelligence. In any text-based emotion detection system, initially, datasets are created by downloading the data from online social media using APIs like Twitter data can be downloaded by using Tweepy on Python. After data generation, text pre-processing steps involve making the text suitable for any machine or deep learning algorithm to process it. Text preprocessing involves tokenization, text cleaning, normalization, and creating feature vectors/embedding. Particularly, the text from social media, product/customer reviews, etc., consists of slang words, emojis, hashtags, HTML tags, short text, incomplete words, etc., which requires preprocessing. Next, machine or deep learning is applied to generated feature vectors. These feature vectors are fed into any machine learning algorithm or deep learning neural network where feature vectors with emotion labels are trained. Then the trained system is used to classify and predict the labels of unseen text. Here we take a brief look at the applications of text-based emotion detection. Table 1 shows the prominent application domains where text-based emotion detection with artificial intelligence is utilized. Figure 1. Text preprocessing along with process flow of text-based emotion detection using artificial intelligence.

Application Domain Details References
Product Reviews Emotion detection on Amazon product reviews for different products and in different languages using deep learning techniques. [4] Movie Review Introduced the concept of movie emotion maps based on movie reviews using machine learning techniques. [5] Social Media Proposed a model based on transfer learning and attentionbased neural network, used to identify context inconsistency for detecting irony in Twitter. [6] Discussion Forum Proposed simple transfer learning approach using pretrained models for text classification tasks. [7] Chatbots/ Conversational systems Developed a model to detect English textual conversations between a chatbot and a human using deep learning techniques. [8] Text-based emotion detection has spread into multiple application domains like product reviews, service reviews, online social media, conversational agents, etc. Customers provide their feedback about a product/service. This feedback is used by businesses to understand customer requirements, in order to increase customer support. With online social media, people express their thoughts and opinions on a particular societal event. Therefore, it becomes necessary to understand the impact of the societal event on people's emotional states. Nowadays, conversational systems are widely used in various areas like healthcare, financial services, E-learning, entertainment, etc. The primary goals of a conversational agent are entertainment, social contact, and novelty interaction, emphasizing productivity. Therefore, it becomes necessary to study users' emotions in the interaction and understand a user's feelings to respond accordingly. One more important concern is security and privacy preservation as text and speech are users' primary modes of communications. The authors of [9][10][11] discussed privacy persevering concepts with different contexts. From Table 1, the outcome can be inferred; text-based emotion detection is used in various applications domains with different machine learning and deep learning techniques.
The contributions of this paper are as given below:  To represent the qualitative analysis of the relevant research work which is carried out in the last 15 years.  To review the emotion modeling approaches for the text-based sources.  To survey existing AI approaches and publicly available datasets for text-based emotion detection.  To perform bibliometric analysis of text-based emotion detection using artificial intelligence by employing Scopus and web of science databases.
The rest of the paper is organized as follows: Section 2 provides a brief about qualitative analysis. It describes different emotion models, emotion detection approaches, and emotion databases. Section 3 presents the quantitative bibliometric analysis. Section 4 provides the summarizing comments on bibliometric analysis with challenges identified. Section 5 presents future work directions. Section 6 represents the conclusion.

Qualitative Analysis-Techniques Overview
In the field of emotion detection, the journey of emotions was started by Charles Darwin, the famous scientist, in 1872. After that, one of the important developments in the field was the affective computing theory by Rosalind W. Picard in 1997. Rosalind Picard stated that if humans want computers to be truly intelligent and interact naturally with humans, we must make computers capable to identify, interpret, and express emotions. Picard showed that the Turing test could show whether or not a machine can think, and the hidden Markov model was used to show transitions from one emotional state to another given a series of observations over time. It changed the direction in the field of textbased emotion detection. Psychologist Robert Plutchik [12] developed the wheel of emotions in 1980. He categorized eight elementary and primary emotions: trust, joy, surprise, fear, anticipation, sadness, disgust, anger, and also stated that there exists a polar opposite to each primary emotion. Plutchik's wheel of emotions provided a great framework for understanding emotion and its intention. Ref. [13] gives a detailed outline of affecting computing with techniques discussed on emotion recognition from speech. In text-based emotion detection, researchers have proposed many emotion models to understand emotions and expressions behind emotions. Hence, emotion models play an important role in text-based emotion detection. The second significant part of text-based emotion detection is the approach/algorithms used to detect emotions from the text. Different algorithms are used to categorize the text into different emotion categories. Lastly, labeled emotion data is used by algorithms to classify the text; it plays are a very important role in text-based emotion detection. Now, people are becoming more reliant on computers to do daily tasks, emphasizing the need to enhance human-computer interactions. Therefore, it is essential to comprehend emotions expressed in text because the text is the primary mode of human-computer interactions in emails, chatbots, discussion forums, blogs, product/service reviews, and other social media platforms. Emotion models, various approaches, and datasets that play important roles in text-based emotion detection are further elaborated.

Emotion Models-Brief Overview
Emotion models are the foundation of the emotion detection process, as these models define the way of the representation of emotions. Different modeling approaches are used for emotion detection, such as the categorical emotion model, dimensional emotion model, and the componential emotion model.
(1) Categorical Emotion Model [12][13][14][15]-The categorical emotion model is also referred to as a discrete emotion model. The basic idea behind the categorical model is that a few significant emotions are universally accepted. These emotions are independent, that is, emotions are not related to each other. These basic emotions are sadness, happiness, fear, anger, disgust, surprise. The categorical model of emotions comprises placing emotions into distinctive categories or classes. Commonly used models in this category are the Robert Plutchik model, the Paul Ekman model, and the OCC Model. The Paul Ekman model [14] differentiates emotions based on six (6) basic classes. According to his theory, six (6) basic emotions initiate from distinct neural systems due to how a person perceives a situation. As a result, emotions are not dependent. These basic emotions are sadness, happiness, disgust, anger, surprise, and fear. However, other composite emotions, including greed, lust, shame, guilt, pride, and suchlike, could be produced in addition to these emotions. The Robert Plutchik model [12] assumes that few prime emotions appear in contrary sets, and their amalgam creates intricate emotions. Plutchik termed eight primary emotions joy vs. sadness, surprise vs. anticipation, anger vs. fear, and trust vs. disgust in opposite pairs. Plutchik states each emotion has varying degrees of intensity. The Orthony, Clore, and Collins (OCC) model [15] opposed the concept of "basic emotions", as stated by Plutchik and Paul Ekman. Herein, OCC claimed that emotions arise from how human beings perceive events, which differ in terms of their intensity. OCC classified emotions into twenty-two (22) classes, adding sixteen (16) emotions-relief, reproach, envy, self-criticism, shame, appreciation, disappointment, pity, fears-confirmed, admiration, hope, grief, gratification, gloating, like, and dislike-to the emotions Paul Ekman suggested as basic, therefore covering a much broader representation of emotions. According to the researcher's preference, any of the categorical emotional models can be employed to depict emotions. However, because of its larger number of classes, the OCC model has a broader emotional representation scope.
(2) Dimensional Emotion Model [12,16,17]-The dimensional emotion model states that emotions are dependent. They are associated with each other. Emotions are represented by a dimensional space in the dimensional emotion model viz. multidimensional and uni-dimensional and show how emotions are related to each other, focusing on how emotions are linked based on the event's occurrence and its severity: high or low. This model comprises emotion variations in three dimensions.  Valence-This dimension states that emotion is positive or negative.  Arousal-This dimension states emotion is exited or apathetic.  Power-This dimension states degree of emotion.
Commonly used models in this category are Russell's 2D circumplex model, Plutchik's 2D wheel of emotions model, and Russell's 3D model. Russell's 2-dimensional circumplex of affect model [16] denotes emotions with arousal and valence on the vertical and horizontal axes, respectively in a two-dimensional circular space.
The model divides emotions into two categories: arousal and valence. Arousal classifies emotions through activations and deactivations, while valence distinguishes between unpleasantness and pleasantness. The circumplex model of affect asserts that emotions are associated rather than distinct. The horizontal axis of Plutchik's 2-dimensional wheel of emotions [12] represents arousal, while the vertical axis represents valence. The emotions are displayed in homocentric circles on the wheel. The inward emotions are derivatives of the eight primary emotions, followed by the eight primary emotions, and ultimately, the outermost segments of the wheel are permutations of the basic emotions. The emotion wheel depicts in what way related emotions are arranged on the wheel based on their places. Russell and Mehrabian [17] proposed the three-dimensional emotion model that comprises arousal, pleasure or valence, and dominance as the third dimension. As assumed in the 2D model, arousal and valence describe how active/inactive or pleasant/unpleasant emotion is. Dominance is the third component that refers to how much control, experiencers had on their emotions.
(3) Componential Emotion Model [18]-The componential emotion model is also called an appraisal-based model. It is an extension of the dimensional emotion model. According to a componential emotion model, an individual may feel an emotion derived from an event. The outcome relies on the individual's experience, expectations, and possibilities for action. The popular model in this category is appraisal theory. Emotions are observed through variations in motivation, cognition, motor, physiology, feelings, expressions, and reactions, among other things. "Appraisal theories" [18] state that a person can only experience an emotion if it is produced by an appraisal of an entity that directly impacts them and that the outcome is "based on the person's goals, experience, and possibilities for action. Appraisal expressions might be found in the text to describe the events that lead to an emotion. An emotional outcome can best be predicted based on an individual's assessment of the preceding object, event, or situation [19]. As a result, it is necessary to contextualize emotional responses, as the same situation might produce distinct affective responses, and inherent factors can produce identical responses. Figure 2 shows the comparative analysis between different emotion models, including the advantages and disadvantages of each emotion model, popular emotion models in the category, and emotions included in each model. After selecting the emotion model, a significant step is to finalize the approach for text-based emotion detection.

Text-Based Emotion Detection Approaches
The general approaches used for detecting emotions from the text are the keywordbased approach, rule-based approach, classical learning-based approach, and deep learning-based approach. Figure 3 shows the approaches used for text-based emotion detection.
(1) Keyword-based approach-A keyword-based approach is built on locating the occurrences of a keyword in a given text and matching with the labels stored in the dataset. In this approach, the emotion keyword list is initially defined from standard lexical databases such as WordNet-Affect [20] or WordNet [21]. Next, preprocessing is carried out on the dataset. After that, keyword spotting is done between emotion keywords from the text and predefined keyword lists. Then keyword intensity of emotion is analyzed. Afterward, negation checking is performed to identify negation cues and the scope of the cue, and finally, the emotion label is determined. In our analysis, we surveyed [22][23][24][25], which are centered on a keyword-based approach. To have a better understanding of how this approach works, we examined [22]. In [22], J. Tao explained the keyword-based emotion recognition approach. Each sentence is considered as a combination of content words or Emotion Function Word (EFW). EFWs can take three forms: emotion keyword, modifier word, and metaphor word. Emotion keywords can take six emotion labels from Ekman's emotion model and assigned specific weights. Modifier words consist of words that emphasize strong or weak emotions. Metaphor words show spontaneous expressions or personal characteristics. This approach first applies POS tagger to each sentence and check EFW then assign emotional ratings to EFW. The next step is to give weights to emotion keywords and constructs a link to EFW. Then, scores across all sentences are summed. To determine an overall score, it goes through a fuzzy logic process. In the last step, sentences are assigned suitable emotion labels according to the overall score. Figure 3 outlines the keyword-based approach.
(2) Rule-based approach-The rule-based approach defines logical and grammatical rules to detect emotions from the text. Initially, text preprocessing is done on the emotion dataset. Then, rules for emotion recognition are mined from text using linguistic and statistic theories. In this, probabilistic affinity or lexical affinity is attached to each word. Then, the best of the rules are selected. Lastly, the selected rules are used for emotion detection to detect emotion labels. Refs. [26][27][28][29] surveyed in the rule-based approach. Lee et al. [26] suggested a rule-based approach for identifying emotion cause events. Lee et al. used the Chinese microblogging website-Sina Weibo-as a data corpus. The expressly communicated thoughts or experiences that generate a related emotion are referred to as cause events. Initially, a labeled corpus is constructed based on emotional causes. Then, the grouping of cause events and the place of cause events pertaining to emotional experiences are determined. Then, keywords are defined for every emotion category. Following that, seven groups of linguistic clues are found, along with two groups of linguistic rules to detect emotion causes are developed. The authors constructed 15 linguistic rules to detect emotions. Finally, a system that identifies the causes of emotions is constructed based on linguistic criteria. Figure 3 shows a general overview of the rule-based approach.
(3) Machine Learning/Classical Learning-based Approach- Figure 3 outlines the machine/classical learning-based approach. The machine learning-based approach enables systems to learn and develop as a result of their experiences automatically. Machine learning algorithms classify the text into different emotion classes. There are two categories of machine learning algorithms-supervised or unsupervised. In most of the reviewed papers, supervised machine learning algorithms are widely used. This approach generally starts with the text preprocessing step. Then the useful features are extracted from the text, and only features are selected with the most information gain. After that, with the given feature set and emotion labels, the system is trained. Lastly, the trained system is used to classify the emotion from the unseen text, termed prediction. The authors surveyed Refs. [30][31][32][33][34][35], which used the machine learning-based approach. To better understand how this approach works, we examined [32], where Bruyne et al. presented an emotion classification system for English tweets. Initially, text preprocessing has performed using word and sentence tokenization, stemming, lowercasing, and POS-tagging. Next, feature extraction is accomplished using n-gram features, lexicon features, and various semantic and syntactic features. Then to solve a multi-class multi-label problem, an ensemble of eleven binary classifiers was created for each possible emotion class, anger, anticipation, disgust, trust, fear, love, joy, pessimism, optimism, surprise, and sadness where each model gets the previous models' predictions as supplementary features. To create a multi-label representation of the predictions, the predicted labels are concatenated. (4) Deep Learning-based approach-deep learning is a variant of machine learning in artificial intelligence with networks capable of unsupervised learning from unstructured or unlabeled data. Figure 3 outlines the deep learning-based approach. This approach enables neural networks to learn complex concepts by constructing them from simpler ones. Initial preprocessing is carried out on the dataset. After that, the embedding layer is built, where tokens are represented in the form of numbers. Then, depending on the number of emotion labels, these feature vectors are input into one or more Deep Neural Network layers. Patterns are learned from data and used to predict the labels by using classification. References [8,19,[36][37][38][39][40][41][42][43] surveyed the deep learning-based approach. To have a better understanding of how this approach works, we examined Ref. [41]. A deep learning system for multi-label emotion identification problems for micro-blogs was proposed by Rathnayaka et al. [41]. For preprocessing, they used the Ekphrasis tool. Word normalization, tokenization, spell correction, and segmentation are all performed by Ekphrasis. GloVe, a pre-trained word embedding algorithm, was used. The features from the embedding layer are provided to two Bidirectional-Gated recurrent unit layers. After that, the output of the first Bi-GRU layer is given to the first attention layer. The output combined from the first and second Bi-GRU and embedding layer is given to the second attention layer. Then, combined, two attention layers are provided to a DNN with a sigmoid activation function for classification. The authors used 11 emotion categories to classify emotions: anger, anticipation, disgust, trust, fear, love, joy, pessimism, optimism, surprise, and sadness.
In Table 2, a qualitative analysis of the relevant literature is shown. This table highlights the datasets, algorithm/technique/methods, objectives, advantages, disadvantages, application domain, evaluation performance, and emotions detected, that have been surveyed in different emotion-detection approaches. The table is arranged according to the application domain. In our qualitative analysis, it has been discovered that social media is the application area [43] where prominent research has been done in text-based emotion detection, with little research on conversational systems (chatbots) public monitoring. It has also been discovered that the categorical emotion model is the most used by researchers in text-based emotion detection, while the componential emotion model has been less preferred. The major emotions detected in all the application domains are happiness, anger, fear, surprise, disgust, sadness. Machine learning and deep learning-based approaches performed well on the different evaluation measures like accuracy and precision.

Dataset/Corpora
Following the selection of a model to classify the emotions, appropriate data acquisition is the next important step in text-based emotion detection. In emotion detection from text, researchers either create their datasets according to study or use available datasets. Datasets available for text-based emotion detection research are labeled or annotated customized datasets. These annotated datasets are created with the help of expert human annotators from respective fields. Researchers have preferred existing datasets or created their datasets according to experiments' requirements to specific application domains. Most of the datasets are easily available and can be downloaded freely. Most datasets are multi-labeled datasets that are suitable for emotion detection from text. There are few structured datasets with annotations designed for text-based emotion detection, publicly available for research purposes. Information for many datasets is collected from online social media platforms such as Facebook, Twitter, Reddit, etc. Data collected from online social media has been in the form of tweets, posts, comments, while some datasets are built from Google news, newspapers, essays, letters, travel guides, conversations, story tales, etc. Publicly available datasets used for text-based emotions from different fields are listed in Table 3.

Quantitative Analysis-Bibliometric Contributions Analysis
Bibliometric analysis is referred to as a statistical examination of published scientific journals, books, or papers. This analysis provides insights into the contribution of various countries, institutes, authors, and journals in the research area. A detailed study of existing literature in this field will help to evaluate the quality of research work with its merits and demerits and provides support to researchers in shaping and enhancing further research actions. The applicability of bibliometric analysis differs with the factors that are being analyzed and methods being used in various subject areas like those that we surveyed in the manufacturing field [53] and in the medical field [54]. The aim is to provide new ideas and ongoing development in the area by visually reflecting and mapping the literature on text-based emotion detection using artificial intelligence over the past 16 years in terms of augmentation, potency, social, and abstract structure. First, this survey depicts research using artificial intelligence with citation data and publication data between 2005 and 2021 (augmentation). Second, this study finds the research areas and the popular journals impacting the field's growth, along with the important authors and prominent countries in text-based emotion detection using artificial intelligence (potency). Third, the study indicates the collaborative connection between the authors and the countries (social structure). Fourth, the study exposes the current focus (abstract structure) of the research on text-based emotion detection using artificial intelligence over the past years.

Search Strategy
For this analysis, two parallel searches were performed on Elsevier's Scopus and Clarivate Analytics' Web of Science databases. All the searches and document retrieval were performed on the last week of March 2021. The first search targeted text-based and consists of only one search keyword in focus: ["text-based"]. The subsequent search was aimed to get research focusing on artificial intelligence. Following keywords included in search in the topic field ["artificial intelligence," "deep learning," "machine learning," "natural language processing"]. In the next search, emotion detection keywords related to text-based were inputted. The following keywords included in the title field: ["emotion detection," "sentiment analysis," "emotion analysis," "emotion recognition," "chatbots," "conversational agents," "social media," "Twitter," "Facebook," Reddit," "Instagram," "reviews"].
The OR Boolean operator is used between keywords while searching to obtain a greater number of appropriate documents. Additionally, in Web of Science searches, asterisks are used as wildcards. Web of Science permits you to use asterisks as a wildcard in all the searches that accept words and groups of words. All of the searches were restricted to journal articles and reviews that were written between 2005 and 2021. The English language was implemented in the search. This search approach retrieved a total of 910 documents: 827 documents from Scopus and 83 from Web of Science. After extracting the duplicates, a total of 902 research papers were chosen and included in the paper. Each document's publication title, publication year, Journal/Source title, the number of citations are considered for analysis. Thus, the abstract, the title, the keywords, and cited references were retrieved. Figure 4 shows the methodological outline of the search strategy and data analysis approach used to retrieve the Scopus and Web of Science documents.

Data Analysis Procedure
The documents retrieved in the earlier search were examined using illustrative and bibliometric methods to provide a general outline of the progress going in text-based emotion detection using artificial intelligence. To describe the development curve in the research on text-based emotion detection using artificial intelligence, publication count and citations per year were obtained. The tables were created to describe the summary of the research in terms of subject areas, journals/source titles, publication types, countries, funding agencies contributing to the growth of the research field. Bibliometric analysis is performed in VOS viewer and Gephi software to study and visually illustrate the social and abstract formation of the field. VOS viewer is a free software for visualizing and exploring bibliometric maps [55]. In VOS viewer, the types of analysis are co-occurrence, co-authorship, citations, co-citations, bibliographic coupling, and units of analysis are authors, organizations, keywords, documents sources, countries, or references depending on the attention of the analysis.
The units of analysis are often depicted in the graphs as circular nodes or rectangular frames. The node/frame size represents the number of publications, authors, or keywords, etc. A link, which is a connection or a relation between the two nodes, is called an Edge. An Edge may represent bibliographic coupling links between publications, co-authorship links between authors, and co-occurrence links between keyword nodes, and each edge is a strength of that relationship. A cluster is a set of nodes included in a map relating to each other, and the color of each node denotes to which cluster a node belongs. The software constructs the bibliometric maps in three steps using a distance-based method [56]. The software approximates the differences between the nodes in the first stage. Then it creates a two-dimensional map in the second step, with the distance between nodes reflecting their similarity. The VOS viewer groups closely related nodes into clusters in the third stage [56]. Co-authorship and bibliographic coupling analyses were done to survey the social structure of research on text-based emotion detection using artificial intelligence. The units of analysis considered authors, organizations, countries/territories, documents, and sources. Each node in the map represents one of the units of analysis, and the nodes' relationships are shown by the edges linking them. The clusters correspond to collaboration networks that exist between groups of authors or countries. Finally, the field's abstract structure was discovered via a keyword co-occurrence analysis. The unit of analysis considered the keywords of the authors. If two keywords appear in the publication, their co-occurrence link is stronger. Clusters of co-occurring keywords correspond to the current focus of the research on text-based emotion detection using artificial intelligence over the past 15 years. The second bibliometric software Gephi is a free and opensource software for analyzing and visualizing large network graphs. A network in Gephi comprises two parts: a list of the vertices/nodes that make up the network and a list of the edges (interactions between nodes). Two attributes are attached to the nodes: a label and a numeric attribute. The color of the nodes is determined by attribute. In addition, the size of a node is determined by its "Degree Centrality" value (its number of connections). Centrality is an essential metric to analyze the position of a node in a network.

Data Collection
This bibliometric analysis utilized Elsevier's Scopus and Clarivate Analytics' Web of Science (WoS) databases for document retrieval. First, the search started with the "textbased" keyword introduced in the WoS and Scopus. Afterward, the results were narrowed down by the specific selection criteria and years. Table 4 shows the list of keywords used for document retrieval from Scopus and Web of Science. We initially retrieved search query results from Scopus, which were 1011, and that from Web of Science were 234. After applying some selection criteria-we considered papers written only in English; considered only conference papers, articles, reviews as document type; limited our search from 2005 to 2021; and restricted research areas to computer science, engineering, psychology, social sciences, and decision sciences-we obtained 827 publications from Scopus and 83 publications from Web of Science as a result, after applying the selection criteria. Then, removing duplicates (08) from both databases, we had 902 publications for analysis. The final query was given as: "Text-based" AND "Artificial Intelligence" OR "Deep Learning" OR "Machine Learning" OR "Natural Language Processing" AND "Emotion Detection" OR "Sentiment analysis" OR "Emotion Analysis" OR "Emotion Recognition" OR "Chatbots" OR "Conversational agents" OR "Social Media" OR "Twitter" OR "Facebook," Reddit" OR "Instagram" OR "Reviews." Table 4. Representative data collection procedure.
Search Query "Text-Based*" AND "Artificial Intelligence*" OR "Deep Learning*" OR "Machine Learning*" OR "Natural Language Processing*." AND "Emotion Detection*" OR "Sentiment analysis*" OR "Emotion Analysis*" OR "Emotion Recognition*" OR "Chatbots," OR "Conversational agents*" OR "Social Media*" OR "Twitter" OR "Facebook" OR "Reddit" OR "Instagram" OR "Reviews" Elsevier's Scopus and Clarivate Analytics' Web of Science (WoS) database platforms were used for retrieving the documents for the analysis. On the above-specified query search, 1011 research publications were retrieved from Scopus, and 324 research publications were retrieved from Web of Science. Scopus's main publications written in the English language were 827, and on Web of Science, publications written in the English language were 83 in number. We excluded publications written in different languages, as specified in Table 5. In this survey, we considered only articles published in journals, conference proceedings, and reviews from the Scopus database and Web of Science database. We excluded book chapters, books, notes, etc. Detailed information is provided in Table 6.

Analysis Based on Yearly Publication Distribution
In exploratory data analysis, publication count per year is analyzed for both Scopus and Web of Science. For publication years from 2005 to 2021, 16 years are taken into consideration. By analyzing the data, we can see text-based emotion detection. This area has become the center of attention for many researchers after 2017. It has been gradually increasing year by year. The publication count reveals rapid growth in 2020, with 160 publications retrieved from Scopus and 23 publications retrieved from Web of Science. More papers are expected to be retrieved in the future. Figure 5 and Table 7 show yearly publications.

Analysis Based on Geographical/Country Wise
Geographical analysis is a study of the regional geographical locations (country/territory) where research in the particular field has been done significantly. In the area of text-based emotion detection, predominant countries are shown in Figure 6. Research publications from Scopus and Web of Science in different locations are illustrated using a radar map. This map shows major contributing countries with their research counts in the field of text-based emotion detection. India tops with count 145, followed by the United States with 134, and China, with 120, places at third on the Scopus database. In contrast, on Web of Science, China (combining Peoples R China and China) leads with 39, followed by the United States with 20. Table 8 shows the 15 major contributing countries in the area of text-based emotion detection.

Analysis Based on Subject Area
In subject area analysis, researchers from different fields try to solve the problem from their perspectives. Table 9 shows subject area analysis. In our analysis, computer science, engineering, and psychology are the subject areas from Scopus and Web of Science with major publications in text-based emotion detection. Other subject areas, such decision sciences social sciences, also considered the study of text-based emotion detection significantly using artificial intelligence. Figure 7 shows the categorization of research done in various fields.  Statistical analysis based on funding agencies shows the universities and organizations contributing funds to the research field. Figure 8 shows the topmost universities and organizations that provide funds to the projects in text-based emotion detection from Scopus and Web of Science. Figure 8 and Table 10 show combined major funding agencies from Scopus and Web of Science in the area of text-based emotion detection. In addition, the national natural science foundation of China and the European Commission national science foundation play a vital role in providing funds in this field. Some other funding agencies include the ministry of education China, the ministry of science and technology Taiwan, and many others.    Information processing management 2(2.41) 10

Scopus WOS
Information systems and e business management 2(2.41)

Analysis Based on Author
Author-based statistical analysis provides the information of publication count per author. The number of publications from Scopus and Web of Science is used to determine the most productive authors. On Scopus, Alexandra Balahur leads the race with a total of nine publications, whereas on Web of Science, the leading author is ARAKI K with two publications. Figures 11 and 12 show the topmost authors from Scopus and Web of Science, respectively.

Network Analysis
In network analysis, citations or common keywords were examined, and the relationships between publications based on authorship were visualized. VOS viewer and Gephi, which are bibliometric tools, were used for representing network graphs. Figure  13 shows the linkage between the top 53 highly cited authors with their co-authors, source titles, and paper title. For example, the maximum number of citations received by a publication titled "Sentiment in short strength detection informal text" is 1028, written by Thelwall M.et al. Table 13 shows the top 10 highly cited authors with publication title and the number of citations exclusively in sentiment analysis and emotion detection. The figure's network analysis is carried out using Gephi.   Figure 14 shows the clustered network analysis of authors with their co-authors, source titles, and publication title based on modularity measures from both Scopus and Web of Science. Modularity is a unit of network or graph structure that shows the strength of a network's division into modules (too termed clusters, groups, or communities). The different clusters with different colors show the strength of dividing a network into modules. The network analysis of the figure is carried out using Gephi.

Analysis Based on Author Keyword Co-Occurrence
Authors or researchers use suitable keywords while retrieving the documents from databases. These keywords play a significant role in searching the documents. We focused on the authors' keywords, which reflect the publications' main research areas. A network diagram, a well-known bibliometric tool, was used to visualize the author keyword cooccurrence relationship. Each node in this figure represents a keyword, and an edge connecting two nodes represents the co-occurrence of two words. Initially, we obtained 1777 keywords as a result. We selected the keywords which have a minimum of five occurrences. Of the 1777 keywords, 64 met the threshold. Then, for each of the 64 keywords, the total strength of co-occurrence links with another keyword was calculated. The keywords with the greatest total link strength were selected. Then, we could verify the selected keywords and remove unwanted or repeated keywords. The keyword co-occurrence network diagram is shown in Figure 15. We can examine that keywords with a high occurrence signify the research area's scope, which consists of Deep Learning, Sentiment Analysis, Emotion Detection, and Machine Learning. Network analysis of Figure 15 is carried out using VOS Viewer. Table 14 highlights the top 20 author keywords, their total link strength, and occurrences

Analysis Based on Co-Authorship
Co-authorship is a form of collaboration in which two or more researchers report their findings on the same topic. As a result, co-authorship networks are regarded as groups of researchers who collaborate. Nodes in co-authorship networks reflect the researchers or authors. Initially, we obtained 2053 authors as a result.
We selected the authors who have two minimum numbers of documents and one minimum citation of the author. Of the 2053 authors, 207 met the threshold. Then for each of the 207 authors, the total strength of co-authorship links with other authors was calculated. First, the authors with the greatest total link strength were selected. Then only the largest set of connected authors were selected. Figure 16 shows the co-authorship network diagram. Table 15 shows the top 10 authors with their links and the number of published documents.

Analysis Based on Citations
Citation analysis is a method of determining the relative significance or influence of an author, an article, or a publication by counting the number of times other works have cited the author, document, or publication. To find out how much impact a particular article or author has had by showing which other authors cited the work within their papers. The yearly number of citations is presented in Table 16, from both Scopus and Web of Science databases. The number of citations per year has been steadily increasing. In 2020, 51,655 and 290 citations were noted on Scopus and Web of Science, respectively. Table 16 shows the citations received in text-based emotion detection from 2015 to 2021. It is observed from the table that, in the year 2020, the maximum citations were received. Tables 17 and 18 show the top five publications from Web of Science and citation analysis of the top ten publications from Scopus. The alluvial diagram was designed by analyzing of top 20 highly cited documents in the field of study. Alluvial diagrams are a type of flow diagram originally developed to represent changes in network structure over time. In Figure 17, the alluvial diagram represents the association between authors, years, and source titles of highly cited 20 articles. The year 2014 has received the highest number of citations.

Year Citation Count Scopus
Citation Count Web of Science  2015  2730  58  2016  5997  67  2017  10744  80  2018  20155  123  2019  35939  212  2020  51655  290  2021 15754 80    In publication citation, we visualized the highest cited documents using a network diagram. The topmost cited publication was "Sentiment in short strength detection informal text" by Thelwall et al. (2010). Initially, in this analysis, we obtained 904 documents as a result. We selected the documents which have five minimum numbers of citations. Of the 904 documents, 282 met the threshold. Then, for each of the 282 documents, the number of citation links was calculated. The documents with the largest links were selected.
The documents with the largest citations are shown in the network diagram. In the network graph, we can observe that the top ten highly cited publications with the authors' names are visible. The color chart on the bottom side depicts the degree of large correlation with the year of publication. The network analysis of Figure 18 is carried out using VOS Viewer.

Analysis of Highly Cited Authors
In author citation, we visualized the highest cited author using a network diagram. Initially, we obtained 2053 authors as a result. Next, we selected the documents which have a minimum of 1 (one) document per author and a minimum of 1 (one) number of citations of an author. Of the 2053 documents, 1426 met the threshold. Afterward, for each of the 1426 documents, the number of citation links with another author was considered. The authors with the greatest total links were chosen. From the total link, the largest set of connected items consists of 247 authors. The authors with the largest citations are shown in the network diagram. The sizes of the circles in Figure 19 suggest the authors with large citations. Table 19 shows the highest cited authors with links and number of citations.  Figure 19. Highest cited authors using a network graph.

Analysis of Highly Cited Sources
In source citation, we visualized the highest cited sources using a network diagram. Initially, we obtained 493 sources as a result. Then we selected the sources which have a minimum of 1 (one) number of source documents and a minimum of 1 (one) number of citations of the source. Of the 493 documents, 342 met the threshold. After that, for each of the 342 sources, the number of citation links with other sources was determined. Finally, the sources with the greatest total links were chosen. From the selected link, the largest set of connected items consists of 63 sources. The sources with the largest citations are shown in the network diagram. The sizes of the circles in the diagram suggest the sources with large citations. Figure 20 shows the highest cited sources. Table 20 shows highly cited sources, links, citations, and publication year.  When two works in their bibliographies refer to a third common work, this is known as bibliographic coupling. Two documents are bibliographically coupled if they both cite one or more documents in common. Author Bibliographic Coupling (ABC) states that two researchers who have more common references are more related and have common research interests. In this analysis, we obtained 2053 authors as a result. We selected documents with a minimum of 2 (two) documents per author and a minimum of 2 (two) citations. Of the 2053 documents, 201 met the threshold. After that, for each of the 201 documents, the number of citation links with another author was determined. Finally, the authors with the greatest total links were chosen. From the total link, the largest set of connected items consisted of 190 authors. Thus, author Zhang et al. have large bibliographic coupling.
The authors with the largest citations are shown in the network diagram. The sizes of the circles in Figure 21 suggest authors with large bibliographic couplings. Table 21 shows authors with bibliographic coupling, links, total strength links, and citations.

Analysis Based on Source Bibliographic Coupling
Source Bibliographic Coupling (SBC) is when two authors have a common reference or common source. Initially, we obtained 493 sources as a result. Then we selected the sources with a minimum of 2 (two) number of documents of source and a minimum of 2 (two) number of citations of the source. Of the 493 documents, 72 met the threshold. Then, for each of the 72 sources, the number of citation links with other sources was determined. The sources with the greatest total links were chosen. From the selected link, the largest set of connected items consists of 67 sources. The sizes of the circles in Figure 22 suggest the sources with large bibliographic coupling. "Lecture Notes in Computer Science" has a large source bibliographic coupling. Table 22 shows sources with bibliographic coupling, links, total strength links, and documents.  In Countries Bibliographic Coupling (CBC), we obtained 82 countries. Then we selected the countries with a minimum of 3 (three) number of documents of country and a minimum of 3 (three) number of citations of country. Of the 82 documents, 43 met the threshold. Then for each of the 43 countries, the number of links with other countries was calculated. The countries with the greatest total links were chosen. From the selected link, the largest set of connected items consists of 42 countries. The sizes of the circles in Figure  23 suggest countries with large bibliographic coupling. We can observe that India, the United States, and China have large countries bibliographic coupling. Figure 23 shows countries bibliographic coupling. Table 23 shows countries with bibliographic coupling, links, total strength links, and documents.

Summarizing Comments on Bibliometric Analysis of Text-Based Emotion Detection Using Artificial Intelligence
Artificial Intelligence has become a prominent solution to solve different complex problems in many areas. In the domain of Natural Language Processing (NLP), artificial intelligence has increased in present years. In this survey, the authors aimed to provide a brief review of the research being carried out in text-based emotion detection using artificial intelligence from different views. The authors considered Scopus and Web of Science databases studied concerning the attributes like the publication year, languages, source titles, citations, countries, publication types, subject areas, authors, and finding agencies. Network illustrations are also given to provide a quick perspective of different aspects like keyword-publications, publication-citations, authors-citations, etc. This bibliometric survey will be helpful to researchers who want to contribute to the specified research area. An important detail is that text-based emotion detection using artificial intelligence became well-known after 2017: After 2017, researchers shifted their attention to this field. In summary:  The majority of publications in this area are conference papers accompanied by articles on Scopus, whereas on Web of Science, most publications are articles.  English is the preferred language for publications. However, some publications are available in the Chinese language and very few in Turkish.  The top three countries/territories that made significant contributions to this field are India, the United States, and China both on Scopus and on Web of Science.  The majority of researchers in the subject area chose Computer Science and Engineering as their field of study.  The maximum number of publications of this area are available in "Lecture Notes in Computer Science" on the Scopus database and "IEEE access" on Web of Science.  "Buckley K." is a well-known author who has made significant contributions in the field.  Most cited paper in this field is "Sentiment in short strength detection informal text."  The maximum research fund was provided by the "National Natural Science Foundation of China" in this field.

Summarizing Comments on Qualitative Analysis of Text-Based Emotion Detection Using Artificial Intelligence
From the analyzed literature, the following major challenges have been identified: (1). Difficulties in detecting implicit emotions. One challenge is identifying emotions in the text when no emotion keywords or phrases have been used. Words and sentences used in the text can have different meanings. A single sentence can contain multiple emotions and views, which makes it difficult to detect multiple emotions. This issue needs to be addressed to improve the performance or accuracy of automated emotion detection systems. (2). Difficulty in extracting the semantic information. Many words in written text such as negations and modals affect emotion detection. Words and phrases used in different contexts convey different emotions. So, word semantic ambiguity is one of the issues in identifying correct emotion from the text. (3). Inefficient and Time-Consuming feature extraction and labeling. Most machine learning algorithms require efficient feature extraction to efficiently recognize emotions. However, manual feature extraction is time-consuming and an error-prone task. In addition, mislabeling of emotions may occur in the manual labeling process, making it a difficult task. Therefore, inefficient feature extraction and labeling can directly affect the accuracy of text-based emotion detection. (4). Classifying emotions according to their intensities. Written text can have words or phrases of varying degrees of associations with respect to sentiments and emotions. In detecting emotions from text, the strength of association with a word or a phrase helps to assign emotion scores/intensities to text. Thus, it becomes easy to annotate/label the text with intensities. (5). Detecting emotions from non-standard language. Users on online social platforms use sarcasm, irony, humor, etc., to express emotions. However, social media texts also contain informal words, slang words, misspellings, hashtags, emoticons, abbreviations, etc. Therefore, it becomes difficult to interpret such creative text for automatic text-based emotion detection systems. (6). Performance of existing systems. Major work in text-based emotion detection has been done using machine learning and deep learning techniques. However, most machine learning techniques require annotated datasets, which is time-consuming and dependent on human efficiency, affecting machine learning techniques' performance. On the other hand, deep learning techniques are complex techniques it requires a large amount of data for training. (7). Imbalanced datasets. Very few datasets are available for research purposes, and most of the datasets are limited labeled imbalanced datasets. These datasets are built for specific experiments, and so are dependent on application domains. Machine learning and deep learning require large datasets, so these few imbalanced datasets restrict the work in text-based emotion detection.
The challenges in the field of Text-Based Emotion Detection using Artificial Intelligence are discussed in Table 24 as below: [ [63][64][65][66][67] Affected by text quality-Slang Words, Irony Transfer learning-Transferring the knowledge base to enhance limited annotated irony datasets. [6,61] Unrobustness of some techniques Improve the accuracy of existing systems by optimizing them.
Domain Adaptation-Training a model on labeled data from a source domain and testing an unlabeled target domain. Transfer Learning-Transferring knowledge from a Large dataset to a Small dataset, thus improving the system's accuracy. Attention Based Deep Learning Techniques. [7,36,69-73]

Future Directions for Text-Based Emotion Detection Using Artificial Intelligence
This survey focused on the contribution of the existing literature relevant to Text-Based Emotion Detection using Artificial Intelligence, so some future research directions are proposed in this section. Table 25 shows research gaps with future directions. We have identified major challenges such as imbalanced datasets, non-standard language, the performance of existing systems, text classification, etc. We have also studied the implemented solutions to solve these challenges. We have proposed some future and advanced directions to these challenges in terms of domain adaptation, transfer learning, ensemble methods, pre-trained models, data augmentation, etc. Figure 24 shows future directions.


Imbalanced Datasets-Problems with presently available datasets are limited labeled data, domain-dependent datasets, and imbalanced datasets. Solutions to these problems are domain adaptation and transfer learning. In domain adaptation, the deep learning model is trained in one kind of environment and tested in a different environment. Another possible solution is semi-supervised machine learning or deep learning algorithms.  Accuracy of Existing systems/Models-Ensemble methods with deep learning models can be used to improve existing systems' performance, and accuracy. Ensemble learning combines the predictions from multiple neural network models. Moreover, performance can be improved by training models on large, domain-specific datasets.  Quality of data (Slang words/Emoticons)-A major problem with online social media texts are the use of informal language by users like sarcasm, irony, misspellings, grammatical mistakes, hashtags, emoticons, etc. Pretrained word embeddings or transformer-based word embeddings can be used to solve these problems.
 Improving Text classification-One more problem is text classification, where deep learning techniques like Graph Neural Network (GNN) can be used to improve text classification.  Security of Machine Learning/Deep Learning Models-Another issue is the security of machine learning or deep learning models. The solution to this is adversarial machine learning. The machine learning algorithm is provided with malicious input that is misrepresentative or inaccurate data to misguide the algorithm to verify the algorithm's security.  Scarcity of labeled/annotated data-Deep learning is hungry for data. However, it requires a large amount of data to train the deep learning models. Therefore, more data can produce better performance in deep learning models. Unavailability of labeled data can be solved with data augmentation techniques. Data augmentation techniques like back translation or a thesaurus can be used to solve the scarcity of data. There is a need to expand the research domain to detect implicit emotions, mislabeled emotions, inefficient and time-consuming feature extraction tasks.
Transformer-based word embeddings Improving classification accuracies using machine learning algorithms and deep learning algorithms like GNN's 3 Reinforcing robustness of some techniques/algorithms and improving the accuracy of existing systems by optimizing them.

Conclusions
This survey paper provides important insights into text-based emotion detection's existing approaches using artificial intelligence. It also represents the existing datasets available in this research domain. It is mainly based on the Scopus and Web of Science database platforms. This paper will help researchers know the predominant authors, publication sources, the largest cited publications, etc. Keyword occurrence will help the researchers to decide future directions in the research domain. The future directions and challenges have primarily been discussed: For more difficult emotion detection tasks, new datasets are required. Domain adaptation techniques are required to address technical requirements, such as the need for a large amount of labeled data. Deep learning and ensemble techniques need to be used to improve the robustness of existing systems. Finally, new approaches and datasets should be added to this research study to lower computational costs and improve performance. Artificial Intelligence applied to text-based emotion detection must remain a focus of interest and attract more research, thus producing more research articles, which will improve our understanding of this topic and help its use for worldwide application.