Skip to Content
ElectronicsElectronics
  • Article
  • Open Access

12 November 2024

24 Pages

A Multi-Level Embedding Framework for Decoding Sarcasm Using Context, Emotion, and Sentiment Feature

,
,
and
1
School of Computer Science, The University of Sydney, Sydney 2006, Australia
2
Department of Cybersecurity, Sydney International School of Technology and Commerce, Sydney 2000, Australia
3
School of Computing, Macquarie University, Sydney 2113, Australia
*
Author to whom correspondence should be addressed.

Abstract

Sarcasm detection in text poses significant challenges for traditional sentiment analysis, as it often requires an understanding of context, word meanings, and emotional undertones. For example, in the sentence “I totally love working on Christmas holiday”, detecting sarcasm depends on capturing the contrast between affective words and their context. Existing methods often focus on single-embedding levels, such as word-level or affective-level, neglecting the importance of multi-level context. In this paper, we propose SAWE (Sentence, Affect, and Word Embeddings), a framework that combines sentence-level, affect-level, and context-dependent word embeddings to improve sarcasm detection. We use pre-trained transformer models SBERT and RoBERTa, enhanced with a bidirectional GRU and self-attention, alongside SenticNet to extract affective words. The combined embeddings are processed through a CNN and classified using a multilayer perceptron (MLP). SAWE is evaluated on two benchmark datasets, Sarcasm Corpus V2 (SV2) and Self-Annotated Reddit Corpus 2.0 (SARC 2.0), outperforming previous methods, particularly on long texts, with a 4.2% improvement on F1-Score for SV2. Our results emphasize the importance of multi-level embeddings and contextual information in detecting sarcasm, demonstrating a new direction for future research.

1. Introduction

Sentiment analysis is a well-researched area of natural language processing (NLP). It is used to determine the polarity of a statement and has been present in various applications such as product analytics and opinion mining to better understand their target audience. Reviews and commentary on social media platforms like Twitter, YouTube, and Reddit present an information-rich multimedia resource to be tapped into, especially in the current era of frequent technological use and advancement.
The issue with trying to determine sentiment using opinions from social media is the popular usage of figurative language such as irony and sarcasm, used to gain traction and virality [1]. In current literature, the usage of ‘sarcasm’ and ‘irony’ are generally interchangeable and are widely acceptable to be conflated together as there is no clear definition in the NLP research community [2]. When a user expresses an opinion with sarcasm, they often use words that contradict their actual sentiment. This poses a challenge for sentiment analysis as the sentiment of a sarcastic text is no longer as direct. This hidden meaning, also typically referred to as incongruity, adds a complex layer of difficulty. This impedes the accuracy of text classification as the nuance of the text is not fully captured and increases the risk of misclassification of a truly negative statement as a positive one. With the rising popularity of using such figurative language, there is, thus, an increasing need for techniques that can distinguish implicit sentiment incongruity.
Automatic sarcasm detection has recently been popular in the NLP and machine learning domains. Sarcasm detection is commonly approached as a binary classification task, although there are works that consider the task to be a multiclass classification [3,4,5]. Sarcasm detection methods range from purely text-based to considering other aspects such as user representations [6,7], mulitmodalities such as visual and acoustic [8,9,10,11], and cognitive features [12,13,14]. We will not go into detail about these works as our study focuses on text-based sarcasm detection with semantic and contextual information.
Early works of text-based sarcasm detection relied heavily on rules based on domain experts’ knowledge or lexical patterns [15,16]. For example, a widely accepted indicator of sarcasm is the contradiction of a positive sentiment and negative situation [17]. Following this, researchers have found that sarcasm has a correlation with implied negative sentiment [18,19]. Unfortunately, these approaches rely on fixed patterns and are restricted to niche domains, making it inflexible to identify more complex sarcastic cues.
More recent research in this field has, thus, shifted from rule-based approaches to feature-based methods. In particular, deep learning-based approaches have gained immense popularity and many models have been proposed for sarcasm detection. Ref. [20] provides an excellent summary of existing automatic sarcasm detection methods. They classify current methods into three categories: sentiment-based, commonsense knowledge-based, and incongruity-based, and identify common features of sarcasm at lexicon, syntax, semantic, and context levels. Our work heavily involves features that are influenced by works that are sentiment-based and incongruity-based and uses word-level and sentence-level embeddings, hence, that will be the focus of our literature review in the following chapter.
In this paper, we propose a novel framework using different levels of embeddings—word, sentence, and affective—to obtain contextual and affective features to detect sarcasm in text. Our work was largely inspired by two works [21,22]. The differences between their work and ours have been listed below:
  • The work by [21] captures emotion, sentiment, context, and sarcasm-related features. Our work captures context features using word and sentence embeddings, and affective features with affective embeddings.
  • Ref. [21] capture context features using CNN. The input text is tokenized using the nltk library. The text representation after CNN is passed through a Fully Connected (FC) Network. In this work, the context features are captured by a hybrid model consisting of a pretrained RoBERTa model that had been previously trained on Twitter sentiment analysis and two layers of Bidirectional GRU (Bi-GRU) with self-attention. The idea behind using the pretrained RoBERTa was to use sentiment analysis as an intermediate task for sarcasm detection, to better capture context features.
  • Ref. [21] use two pretrained transformers (EmoDPTT, SentAPTT) as feature extractors. These transformers were trained on emotion detection and sentiment analysis tasks, respectively. To our understanding, ref. [21] only uses word embeddings but not sentence embeddings or affective embeddings. The use of EmoDPTT and SentAPTT could be equivalent in concept to the affective embeddings. However, in our work, that was calculated differently which was inspired by [22].
  • This work differs from [22] as we used SenticNet’s affective dimensions and elementwise addition instead of EmoLex and elementwise multiplication.
  • In this work, we employed the use of a CNN to extract meaningful information from concatenated embeddings. This CNN has a similar architecture to that of [21] for their context features extraction. The output of our CNN was then passed through an MLP with softmax layer for prediction.
The main contributions of our work are as follows:
  • We present a novel framework of using different embeddings (word, sentence, and affective) to obtain contextual and affective features to detect sarcasm in text. Our method achieves a fairly competitive performance in two benchmark datasets.
  • We introduce a novel algorithm that leverages on SenticNet to form the affective embeddings for the model. To the best of our knowledge, there has been no attempt to utilize the affective dimensions provided by SenticNet in the exact manner as we have.
This paper is structured into seven sections. In Section 1, we introduce the topic of sarcasm detection, emphasizing its importance in fields like sentiment analysis. We provide an overview of our methodology and contributions. Section 2 reviews and compares existing research in sarcasm detection, covering subcategories such as embeddings, modeling incongruity, context, and transfer learning. Section 3 introduces foundational concepts relevant to sarcasm detection, including embeddings, pre-trained language models, transfer learning, and convolutional neural networks, to enhance the understanding of our approach. In Section 4, we outline our research methodology in detail, describing each step of our framework from data preprocessing to the final classifier, while highlighting the influence of previous works. Section 5 presents and discusses our experimental results, comparing them with baseline models on two benchmark datasets. Section 6 offers insights from our ablation study on the impact of different embeddings on the framework’s performance. Finally, Section 7 concludes the paper, summarizing our findings and suggesting directions for future research.

3. Relevant Concepts in Sarcasm Detection

In this section, we briefly explain important topics used in sarcasm detection research to deepen the understanding of our work.

3.1. Embeddings

Embeddings are used to represent text in a continuous, numerical vector space. They are a fundamental part of NLP processes and applications like text classification, acting as features representative of the input text. They can capture semantic meaning, such that words with similar common meanings are grouped closer together in the vector space and result in similar embeddings. Word embeddings usually represent individual words as vectors. They capture relationships between individual words. Popular methods in creating word embeddings include Word2Vec and GloVe.
Sentence embeddings represent the whole sentence and consider the entire sentence rather than individual words. Popular methods to obtain sentence embeddings are Universal Sentence Encoder (USE) or Bidirectional Encoder Representations from Transformers (BERT). Sentence embeddings are usually trained on tasks that require the understanding of relationships between sentences such as in document classification or sentence similarities.
Affective embeddings try to address the limitation of word embeddings where words with opposite sentiment polarity are classified as similar. For example, “good” and “bad” are considered similar, but they represent very different feelings. Affective embeddings are sometimes referred to as sentiment embeddings. Affective information can be taken from resources and lexicons such as WordNet Affect, EmoLex, and SenticNet.

3.2. Pre-Trained Language Models

Given the rising popularity of the NLP research field, there have been a number of publicly available pre-trained language models (LMs). These models have been previously trained on large and vast datasets, meaning that they have already learned some general representations of the human language. Popular pre-trained LMs include transformers like BERT and RoBERTa, which is an optimized version of BERT and trained on more data than the original BERT. Using pre-trained LMs brings multiple benefits, primarily reducing the need for large-labeled datasets for specific tasks. This is particularly useful in sarcasm detection as this research field has very limited task-specific labeled datasets.

3.3. Transfer Learning

Transfer learning is a machine learning technique where a model that has been developed for another task is reused and fine-tuned for a secondary task. The secondary task is usually related to the first task, such as sentiment analysis and sarcasm detection. Transfer learning leverages the prior knowledge that a pre-trained LM has learnt from the previous training. This prior knowledge can then act as a feature for the current task. Improved performance and reduced training times are the main benefits of transfer learning. Similarly, transfer learning is also effective for tasks where there is limited data available.

3.4. Introduction to CNN

Convolutional neural networks (CNN) are deep learning models. Their architecture usually consists of multiple sequential layers to process and learn from the input data. CNNs are often used in image classification. However, there has been previous work that saw success in using CNN for text classification. This has been elaborated in Section 2. Generally, CNNs are made of convolutional layers which apply a sliding filter (kernel) over the input data and perform calculations to produce a feature map.
After each convolutional operation, activation functions such as Rectified Linear Unit (ReLU) can be applied to the model to introduce non-linearity. By doing so, it enables the model to generalize better when capturing more complex patterns in the data. ReLU causes the feature map values to only contain positive values, with previously negative pixel values replaced with zero. The last layers of CNNs are usually a fully connected (FC) layer where a linear transformation is applied to its input. Hence, FC layers are also known as linear layers. The final layer for a classification CNN is a softmax layer which outputs a class label probability distribution.

4. Methodology

Our study was inspired majorly by the works of [21,22]. Ref. [21] proposed a framework for using different text representations to detect sarcasm while the findings of the work done by [22] indicated that using affective and contextual embeddings improved performance in sarcasm detection. In our work we, thus, decided to investigate the use of combining different embeddings—word, affective, and sentence—to achieve the same target task. The overall framework is visualized in Figure 1.
Figure 1. Overview of proposed framework.

4.1. Data Preprocessing

Due to the nature of the provided SARC 2.0 dataset, we followed the publicly available code written by the authors to transform it into a simplified version. For both datasets, we loaded the data using the pandas library and removed rows with empty values. For the class column, we mapped non-sarcastic samples to 0 and sarcastic samples to 1. To prepare the textual data for tokenization, we conducted the following preprocessing operations:
  • Replaced urls with a single whitespace
  • Replaced XML-escaped characters with a single whitespace. For the ampersand sign (&), we replace it with “and”.
  • Replaced mentions with a single whitespace
  • Replaced hashtags with a single whitespace
  • Reduced multiple whitespaces into a single whitespace
Emotions are converted into the corresponding unicode using the library unicodedata, then replaced with their corresponding unicode Common Locale Data Repository (CLDR) short names. If the CLDR name contained more than one word, i.e., “frowning face”, then the two words were joined together using an underscore: “frowning face”. We split the SV2 dataset into 80% training and 20% testing sets with stratification to ensure equal representation of class labels in each set. The original SARC data has already been split into training and testing subsets.

4.2. Sentence Embeddings Vector (S)

SBERT utilizes a siamese and triplet network architecture to obtain semantically meaningful sentence embeddings. The model takes a sentence as input and outputs a vector of embeddings containing captured semantic information within the sentence. These sentence embeddings can then be used in downstream tasks such as clustering or semantic searches. Following the success of Sentence-BERT (SBERT) [71], we employed the use of their pretrained model, all-MiniLM-L6-v2, in our framework to encode sentences. We chose to use this specific variant as it was fast and lightweight while providing good-quality performance. Additionally, the pretrained model had been finetuned on several training datasets and, thus, allowed us to leverage the transfer-learning of prior semantic information for our target task. The resulting sentence vector had a dimension of [batchsize, 384].
For example, given a piece of text, “abandon my aah”, our SBERT model will encode the sentence into embeddings and return the following tensor ([−1.5066 × 10−2, 5.9213 × 10−2,…, −6.3333 × 10−2, −3.1194 × 10−2]).

4.3. Affective Embeddings Vector (A)

4.3.1. Embeddings from SenticNet

SenticNet is a knowledge base that provides conceptual and affective information to enable machines to have a better and deeper interpretation of human emotions. Not only does SenticNet provide sentiment polarity and emotion detection, but it was also trained with commonsense knowledge to have a richer contextual understanding of texts. SenticNet is publicly available for download [72]. The embeddings from the latest English variant of SenticNet, SenticNet 8 [72], were used in this study. In the CSV file provided by SenticNet, the column headers include the concept name, affective dimensions (introspection, attitude, temper, and sensitivity), emotion labels (primary and secondary emotion), semantically similar words and sentiment polarity. The sentiment polarity scores ranged from [−1 to 1], with −1 representing negative sentiment and 1 representing positive sentiment. SenticNet provides large amounts of information, however, in our study, we chose to focus on the emotion labels built around four independent affective dimensions—introspection, attitude, temper, and sensitivity, in addition to the sentiment polarity score. We stored this simplified version of SenticNet in a dictionary with concept names as the key and the aforementioned information as the values.

4.3.2. Calculation of Affective Vectors

Given an input sentence, we first tokenized it in its lowercase form using the word tokenize function from the popular Python library nltk for natural language processing. To collect the affective words in a sentence, for each token, we compared it to the SenticNet dictionary and extracted its corresponding information from the dictionary. In the event that there are no matches found, a vector of zeroes is returned. The calculation of the affective vectors was inspired by the emotion affective intensity with the sentiment feature approach developed by [22]. In their work, they leverage the NRC Emotion Intensity Lexicon [36] and NRC Emotion Lexicon [34]. Their calculation involves element-wise multiplication of their feature vectors containing 4 emotions and 2 sentiments (anger, fear, sadness, joy, positive, negative) with a frequency of affective word vectors. Their sentiments are binary values, 0 and 1.
Our method differs in that our feature vectors are composed of introspection, temper, attitude, sensitivity, positive polarity score, and negative polarity score, where the sentiment scores can range from [−1 to 1]. We applied an element-wise addition to our vectors to preserve the magnitude of the sign and average it with the number of existing words before multiplying it with the frequency vector. For example, in the sentence “abandon my aah”, the feature vectors for each word are as follows:
Wabandon = (−0.329, 0, 0, 0, 0, −0.329),
Wmy = (0, 0, 0, 0, 0, 0),
Waah = (−0.514, 0, 0, 0, 0, −0.514)
After the elementwise addition, the resulting vector is (−0.843, 0, 0, 0, 0, −0.843). There are only 2 words from that sentence that exist in the SenticNet dictionary, and the resulting vector is, thus, divided by 2. The frequency vector is (2, 0, 0, 0, 0, 2) and the final affective vector is (−0.843, 0, 0, 0, 0, −0.843). The resulting dimensions of the returned tensor are [batchsize, 6].

4.4. Context-Dependent Word Embeddings Vector (WE)

4.4.1. RoBERTa Layer

The Robustly optimized BERT approach (RoBERTA) is an improved variant of Bidirectional Encoder Representations from Transformers (BERT) and has shown immense success in text classification tasks. The RoBERTa model we chose, cardiffnlp/twitter-roberta-base-sentimentlatest which is publicly available on HuggingFace, had been trained and fine-tuned for sentiment analysis on approximately 124 million tweets from 2018 to 2021 [73]. To leverage the benefits of intermediate task transfer learning where sentiment analysis is used as the auxiliary task, we froze all the layers except the last layer in the RoBERTa model to preserve the pretrained layer weights. To tokenize the text, we used the tokenizer from the pretrained model using the HuggingFace transformers library. The text is padded and truncated to max length, which is a hyperparameter we experimented with. More details can be found in Section 5.
The tokenized text is then fed into the pretrained model which provides deep contextual embeddings from the transformer layers and attention mechanisms to capture nuanced semantic relationships within the text. We extracted the features from the last hidden state to pass them into the BiGRU layer.

4.4.2. BiGRU with Self-Attention Layer

Bidirectional GRU (BiGRU) consists of 2 Gated Recurrent Units (GRU) running in parallel where one GRU processes the input sequence in a forward direction while the other processes the input sequence in a backward direction. By processing the sequence in both directions, past and future contexts can be captured which is essential for context-dependent tasks such as sarcasm detection. We added two BiGRU layers on top of our RoBERTa layer, creating a RoBERTa-BiGRU hybrid model. This approach complements and takes advantage of the strengths of both architectures in capturing different aspects of the text, allowing for better generalization and robustness. We applied a self-attention mechanism in our model to further enhance and refine the capturing of global context and long-range dependencies. Our resulting context-dependent word embedding vector was a tensor with dimensions [batchsize, 256], where our hidden dimensions were size 128. Using the same example for the text “abandon my aah”, the returned tensor would look like ([5.9108 × 10−1, −3.4041 × 10−1,…, 1.4299 × 10−1]).

4.5. Normalization and Concatenation of Vectors

We normalized the embeddings from the previous steps before concatenation (Figure 2). This ensures a balanced contribution for each model’s embeddings towards the final representation. While there are many ways of fusing features together, in this study we chose to use simple concatenation, following the works of [21,51]. It is a simple, computationally inexpensive approach that allows the stacking of diverse linguistic features from multiple models and creates a powerful vector representation. The resulting vector dimensions were [batchsize, 646] and the vector was fed into a CNN for further feature extraction.
Figure 2. Normalization and concatenation of vectors.

4.6. Convolutional Neural Network and Multilayer Perceptron (CNN-MLP)

For our final classifier, we proceeded with a hybrid model of convolutional neural network (CNN) followed by a multilayer perceptron (MLP), a feedforward neural network, which has been widely used in the field of sentiment analysis. The model architecture is visualized in Figure 3. Our architecture extended the final classifier architecture used in the work of [21] by introducing two additional layers, with one layer having the Rectified Linear Unit (ReLU) activation function applied. This was to introduce non-linearity into the network to help the model learn more complex patterns about the data. The output of our CNN-MLP classifier was class probabilities for the given input sequence. We then used these logits to calculate the accuracy and F1-score.
Figure 3. CNN-MLP Architecture.

5. Experimental Results and Discussions

5.1. Implementation Details

The experiments were conducted on a single Intelfi Core i7 and in a PyTorch version 2.2.1 environment. We employed an Adam optimizer with a Cross Entropy loss function. We implemented our model using the Pytorch Lightning API [74], version 1.4.0. We initialized all random states to 42 with the function seed everything. We chose to conduct batch sampling for more stable training. The hyperparameters we experimented empirically with were max length of texts {80, 256}, learning rate {1 × 10−3, 1 × 10−5}, number of epochs = {3, 5, 10} and batch size {32, 128, 256}. The best parameters were chosen based on model performance on the test dataset. We test our dataset on two benchmark datasets. The fixed parameters are reported in Table 1.
Table 1. Fixed parameters of our framework. Input dimensions here refer to the input to the MLP classifier.

5.2. Evaluation Metrics

Due to the inconsistency of metrics across datasets, in our study we chose to compare Accuracy and F1-Score as they were the most common metrics used. We relied on BinaryAccuracy and BinaryF1Score functions from the torchmetrics library to track our metrics during training and testing.
Accuracy = (TP + TN)/(TP + FP + FN + TN),
Accuracy is straightforwardly the ratio of correctly predicted examples to the total number of examples in the dataset. It measures the overall correctness of the model.
The F1-score was calculated by taking the harmonic mean of precision and recall. Precision is the ratio of correctly predicted examples to total predicted positives, meaning it measures the accuracy of positive predictions. Recall is the ratio of correctly predicted observations to total examples in the actual class, meaning the sum of the number of examples that are predicted to be sarcastic and are labelled sarcastic in the labelled dataset and the number of examples predicted to be not sarcastic but are actually labelled sarcastic. Hence, recall measures the ability of the model to correctly identify all positive examples. F1-score offers a more nuanced and comprehensive evaluation metric for the model’s performance by balancing recall and precision.
Recall (R) = TP/(TP + FN)
Precision (P) = TP/(TP + FP)
F1-Score = 2 × ((P × R)/(P + R))
We emphasize that our main evaluation metric was the F1-score. Note that accuracy and F1-score are the most popular evaluation metrics.

5.3. Benchmark Evaluations

Overview of Datasets

The datasets used in this study were Sarcasm Corpus V2 (SV2) [75] and Self-Annotated Reddit Corpus (SARC) [67].
The overall statistics regarding the number of samples in the datasets can be found in Table 2. We provide statistics of the length of sentences and the total number of words in Table 3, repeated words inclusive. We calculated these statistics by applying the word tokenize function from the nltk library for every sample in each dataset to obtain the number of words.
Table 2. Sample-level statistics per dataset.
Table 3. Word-level statistics per dataset.
SV2 is a labelled subset of the Internet Argument Corpus (IAC), containing posts specifically for sarcasm. The dataset comes with three types of samples: generic (GEN), hyperbole (HYP), and rhetoric (RQ). In our study, we used only the GEN subset. It is a balanced dataset, containing 3260 posts for each class. On average, each piece of text in this dataset contained 51 words. Its standard deviation was quite high at 36.1, suggesting that this dataset had a wide variety in text length. Examples of sarcastic sentences in this dataset include: “Depends on when the baby bird died. run along little boy…let the adults debate”, “You don’t see protesters walking around going “I wanna marry my dog” or “beastiality rocks” do you?!”, etc.
The original unbalanced SARC 2.0 contained a total of 533 million comments from the social media site Reddit, where 1.34 million of them are classified as sarcastic. As that corpus is extremely large, we opted for the slightly smaller subsets with balanced distributions for each class, at 128,541 each. From Table 3, we note that the average length of text in this dataset tended to be much shorter than the one in SV2. The lower standard deviation also suggests the text lengths are probably more consistent. We used these statistics to drive our empirical testing of hyperparameters.

5.4. Sarcasm Corpus V2 (SV2)

Both our models outperformed all of the previously proposed methods as listed in Table 4 on both metrics. Our best baseline model was trained for 10 epochs with a learning rate of 0.001, batch size 256 and max length of 80. Our method improved previously proposed sarcasm detection methods by about 6.2%. The improvement of our model achieved competitive or equivalent performance with state-of-the-art neural network models, emphasizing the effectiveness of our proposed method. This supports our belief that a multi-level embedding approach is suited for sarcasm detection. Taking this sentence from the dataset as an example: “Depends on when the baby bird died. run along little boy…let the adults debate”, using Word2Vec to detect sarcastic intent would be difficult. This sentence heavily relies on contextual clues and nuances such as “run along” having a more patronizing tone. This tone would likely be picked up by the RoBERTa and SBERT models in our SAWE framework. Furthermore, the rich representation by the concatenated vector provides more robustness via a broader linguistic scope at the word and sentence level.
Table 4. Results on SV2 dataset.

5.5. Self-Annotated Reddit Corpus (SARC)

In comparison to the SV2 dataset, our model did not perform as outstandingly in the SARC 2.0 dataset, although it did show improvements compared to some baselines as listed in Table 5. We observed that the baseline models that our model outperformed (Bag-of-Words (BOW), CNN, and CNN-SVM) are models that are only able to capture local semantic information given an input text and fail to capture the implicit incongruity between words that is needed for sarcasm detection. This observation implies that our model was capable of capturing some incongruity within the text in order to perform slightly better.
Table 5. Results on SARC 2.0 dataset.
The best-performing models are from the works of [48,78]. Ref. [48] uses ELMo embeddings into a BiLSTM, highlighting the superior performance of ELMo embeddings to capture more meaningful sarcastic information at a character level. This suggests an avenue for future research. Ref. [78] employed a self-attention GRU with multiple heads where multiple self-attention mechanisms could run in parallel. This allowed the model to capture more intricate dependencies between words and have better generalization and robustness. We note that our model also employed self-attention, although we did not use multiple heads as [78,79,80] did.
The difference between the two datasets is text length and structure complexity. SV2 has longer texts on average than SARC, as evident in Table 3. This suggests that our model showcased better performance for texts with longer text length than for short text and serves as a point of investigation. The hyperparameters of our best comparable model on the SARC 2.0 dataset are as follows: a learning rate of 0.00001, 3 epochs, a batch size of 32 and a max length of 20.

5.6. Experiments

In this section, we briefly go over the training evaluation metrics for both datasets and hyperparameters testing. We conducted extensive experiments to fine-tune our model. We used early stopping to end training when the validation loss stopped improving, to prevent overfitting.
We observe that for both datasets, we achieved a decreasing training loss which appeared relatively stable with no sharp drops or fluctuations. This indicates that our model had stable training (Figure 4). We note that for the SV2 dataset, the training loss seemed to be decreasing at a faster rate than for the SARC 2.0 dataset. We attribute this to the smaller dataset size for SV2 as seen in Table 4. Given that the trend in training loss seems relatively stable, we are inclined to believe there was no obvious overfitting in our model.
Figure 4. (a) Training evaluation metrics for the best-performing models on SV2; (b) Training evaluation metrics for the best-performing models on SARC 2.0 dataset.

5.7. Testing Batch Size

For each dataset, we tested a batch size of 32 and 128. We present our findings in Figure 5, Figure 6 and Figure 7. We note that a larger batch size for the SV2 dataset produced less fluctuations in the F1-score and accuracy.
Figure 5. (a) Impact of batch sizes on training accuracy on SARC 2.0 dataset; (b) Impact of batch sizes on training accuracy on SV2.
Figure 6. (a) Impact of batch sizes on F1-Score on SARC 2.0 dataset; (b) Impact of batch sizes on F1-Score on SV2.
Figure 7. (a) Impact of batch sizes on training loss on SARC 2.0 dataset; (b) Impact of batch sizes on training loss on SV2.

5.8. Testing Learning Rate

We tested a learning rate of 0.00001 and 0.001 on the SARC 2.0 dataset. We present our findings in Figure 8. We note that a smaller learning rate may have been more ideal for this dataset.
Figure 8. (a) Impact of learning rate on training accuracy on SARC 2.0 dataset; (b) Impact of learning rate on F1-Score on SARC 2.0 dataset; (c) Impact of learning rate on training loss on SARC 2.0 dataset.

5.9. Testing Max Length

We experimented with values of 80 and 256 on the SARC 2.0 dataset and present our findings in Figure 9. We note that there did not seem to be much difference in accuracy performance, but there was some obvious deviation with the F1-score. This means that there were trade-offs between precision and recall in our model’s performance. Our work would benefit from further investigation using those metrics.
Figure 9. (a) Impact of max length on training accuracy on SARC 2.0 dataset; (b) Impact of max length on F1-Score on SARC 2.0 dataset; (c) Impact of max length on training loss on SARC 2.0 dataset.
With evidence from Table 3, we can infer that our model would benefit from a smaller max length for this dataset. We used this information during the fine-tuning of our model and experimented with small max lengths of 15, 20, and 30. We found that the model began to overfit for lengths below 20. This might have been due to incomplete information as a result of the truncated context of the sentence. Careful consideration must be given to determine the most optimal max length for best performance.

6. Ablation Studies

An ablation study aims to evaluate the overall performance of a system when certain components are removed to understand each component’s effect. In our ablation study, we investigated the impact and contribution of each derived embedding vector on the model’s performance. This is done by systematically removing one module at a time and training the new model, i.e., removing the affective embedding vector creation and training the model with only the remaining two sentence embedding vectors and context-dependent word embedding vector. We measured the impact using the same evaluation metrics, as well as the average time taken per epoch. We conducted the study on the SV2 dataset, with the following hyperparameters: a learning rate of 0.00001, 3 epochs, a max length of 256, and a batch size of 256 to ensure a controlled experiment. We present our findings in Table 6.
Table 6. Results of ablation study on SV2.
From Table 6, we observe that the context-dependent word embedding vector had the largest impact across all evaluation metrics from the significant decrease in performance across all metrics. This is aligned with our expectations as our word embedding vector was generated by the hybrid model consisting of RoBERTa and BiGRU which effectively captures contextual information which is crucial for sarcasm detection, as supported earlier in our literature review. The results in Table 6 emphasize the importance of context as a defining feature in sarcasm detection.
Interestingly, our affective embeddings vector appears to slightly degrade our model performance on the SV2 dataset when our model uses the CNN component, but shows improvement when the model does not have the CNN component but uses the affective embeddings. We attribute this to the affective embeddings adding noise to the features which the CNN extracts from. Overall, it appears that the affective embeddings have the least impact on the model performance.
From the confusion matrix in Figure 10, we note that the addition of CNN helped in lowering the number of false positives and increasing the number of true positives. However, there was a slight increase in false negatives. Overall, from Table 6, we observe that the addition of CNN improves model performance across all metrics by up to 1%.
Figure 10. (a) Confusion Matrix of SAWE on SV2; (b) Confusion Matrix of SAWE-CNN on SV2.
From the confusion matrix in Figure 11 and Table 7, we observe that the addition of CNN improved the model performance on the SARC 2.0 dataset. Similar to the SV2 dataset, the context-dependent word embeddings had the greatest impact on model performance across all metrics. Interestingly, the absence of affective embeddings had a greater impact on the metrics on this dataset when compared to its smaller impact on the SV2 dataset. This could be due to a possibly increased presence of affective words used in SARC 2.0 compared to SV2. For SARC 2.0, the sentence embeddings have the least impact on model performance. This could be due to SARC 2.0 containing short texts, as we observed in Table 3 and hence knowing the semantic meaning of short text might not be entirely useful.
Figure 11. (a) Confusion Matrix of SAWE on SARC; (b) Confusion Matrix of SAWE-CNN on SARC.
Table 7. Results of ablation study on SARC 2.0.

7. Conclusions

In this research study, we presented SAWE, a multi-aspect embeddings-based framework for text-based sarcasm detection. Some existing methods have a fixed perspective with a focus on a singular-embedding level, usually only at the word level, while others consider affective information within the sentence but ignore contextual information from a local and global point of view.
In our proposed framework, we viewed the sentence from multiple levels: sentence, affect, and word level. Additionally, we also extracted aspects such as contextual information across sentence and word levels and calculated an affective vector by extracting affect words in a sentence and utilizing SenticNet to obtain affect information. We evaluated our model on two benchmark datasets and found that our model outperformed previously proposed baselines, even outperforming state-of-the-art models for one dataset.
Limitations to our study are the complete reliance on a singular-affective lexicon and the inefficiency of our framework when dealing with larger datasets. Suggested areas for future research include incorporating a character-level embedding vector in addition to sentence, affect, and word levels. Another area to consider is multiple heads for self-attention, following the success of the attention mechanism.

Author Contributions

Conceptualization, Supervision, M.K.N.; methodology, M.K.N.; software, T.Z.C.K.; validation, M.K.N., T.Z.C.K. and S.S.C.; formal analysis, M.K.N.; investigation, M.K.N. and T.Z.C.K.; resources, N.S.; data curation, T.Z.C.K.; writing—original draft preparation, M.K.N.; writing—review and editing, M.K.N. and T.Z.C.K.; visualization, T.Z.C.K. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

The datasets used in this study are Sarcasm Corpus V2 (SV2) [75] and Self-Annotated Reddit Corpus (SARC) [67]. These datasets are publicly available and can be accessed as referenced in the respective citations.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Peng, W.; Adikari, A.; Alahakoon, D.; Gero, J. Discovering the Influence of Sarcasm in Social Media Responses. July 2019. Available online: https://wires.onlinelibrary.wiley.com/doi/full/10.1002/widm.1331 (accessed on 24 May 2024).
  2. Van Hee, C. Can Machines Sense Irony?: Exploring Automatic Irony Detection on Social Media. Ph.D. Dissertation, Ghent University, Ghent, Belgium, 2017. [Google Scholar]
  3. Reyes, A.; Rosso, P.; Veale, T. A multidimensional approach for detecting irony in Twitter. Lang. Resour. Eval. 2013, 47, 239–268. [Google Scholar] [CrossRef] [Scilit]
  4. Barbieri, F.; Saggion, H.; Ronzano, F. Modelling Sarcasm in Twitter, a Novel Approach. In Proceedings of the 5th Workshop on Computational Approaches to Subjectivity, Sentiment and Social Media Analysis, Baltimore, MD, USA, 27 June 2014; Balahur, A., van der Goot, E., Steinberger, R., Montoyo, A., Eds.; Association for Computational Linguistics: Baltimore, MD, USA, 2014; pp. 50–58. [Google Scholar] [CrossRef] [Scilit]
  5. Oprea, S.; Magdy, W. iSarcasm: A Dataset of Intended Sarcasm. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, Online, 5–10 July 2020; Jurafsky, D., Chai, J., Schluter, N., Tetreault, J., Eds.; Association for Computational Linguistics: Baltimore, MD, USA, 2020; pp. 1279–1289. [Google Scholar] [CrossRef] [Scilit]
  6. Du, Y.; Li, T.; Pathan, M.S.; Teklehaimanot, H.K.; Yang, Z. An Effective Sarcasm Detection Approach Based on Sentimental Context and Individual Expression Habits. Cogn. Comput. 2022, 14, 78–90. [Google Scholar] [CrossRef] [Scilit]
  7. Amir, S.; Wallace, B.C.; Lyu, H.; Silva, P.C.M.J. Modelling Context with User Embeddings for Sarcasm Detection in Social Media. July 2016. Available online: https://arxiv.org/abs/1607.00976v2 (accessed on 25 May 2024).
  8. Razali, M.S.; Halin, A.A.; Norowi, N.M.; Doraisamy, S.C. The importance of multimodality in sarcasm detection for sentiment analysis. In Proceedings of the 2017 IEEE 15th Student Conference on Research and Development (SCOReD), Putrajaya, Malaysia, 13–14 December 2017; pp. 56–60. [Google Scholar] [CrossRef] [Scilit]
  9. Chauhan, D.S.; Dhanush, S.R.; Ekbal, A.; Bhattacharyya, P. Sentiment and Emotion help Sarcasm? A Multi-task Learning Framework for Multi-Modal Sarcasm, Sentiment and Emotion Analysis. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, Online, 5–10 July 2020; Jurafsky, D., Chai, J., Schluter, N., Tetreault, J., Eds.; Association for Computational Linguistics: Baltimore, MD, USA, 2020; pp. 4351–4360. [Google Scholar] [CrossRef] [Scilit]
  10. Zhu, L.; Zhu, Z.; Zhang, C.; Xu, Y.; Kong, X. Multimodal sentiment analysis based on fusion methods: A survey. Inf. Fusion 2023, 95, 306–325. [Google Scholar] [CrossRef] [Scilit]
  11. Chan, J.-L.; Bea, K.; Leow, S.; Phoong, S.; Cheng, W. State of the art: A review of sentiment analysis based on sequential transfer learning. Artif. Intell. Rev. 2023, 56, 749–780. [Google Scholar] [CrossRef] [Scilit]
  12. Mishra, A.; Kanojia, D.; Nagar, S.; Dey, K.; Bhattacharyya, P. Harnessing Cognitive Features for Sarcasm Detection. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), Berlin, Germany, 7–12 August 2016; Erk, K., Smith, N.A., Eds.; Association for Computational Linguistics: Stroudsburg, PA, USA, 2016; pp. 1095–1104. [Google Scholar] [CrossRef] [Scilit]
  13. Ravi, K.; Ravi, V. A novel automatic satire and irony detection using ensembled feature selection and data mining. Knowl.-Based Syst. 2017, 120, 15–33. [Google Scholar] [CrossRef] [Scilit]
  14. Chia, Z.L.; Ptaszynski, M.; Masui, F.; Leliwa, G.; Wroczynski, M. Machine Learning and feature engineering-based study into sarcasm and irony classification with application to cyberbullying detection. Inf. Process. Manag. 2021, 58, 102600. [Google Scholar] [CrossRef] [Scilit]
  15. Kreuz, R.; Caucci, G. Lexical Influences on the Perception of Sarcasm. In Proceedings of the Workshop on Computational Approaches to Figurative Language, Rochester, NY, USA, 26 April 2007; Feldman, A., Lu, X., Eds.; Association for Computational Linguistics: Stroudsburg, PA, USA, 2007; pp. 1–4. [Google Scholar]
  16. Carvalho, P.; Sarmento, L.; Silva, M.J.; de Oliveira, E. Clues for detecting irony in user-generated contents: Oh...!! it’s “so easy” ;-). In Proceedings of the 1st International CIKM Workshop on Topic-Sentiment Analysis for Mass Opinion, Ser. TSA ’09, Hong Kong, China, 6 November 2009; Association for Computing Machinery: New York, NY, USA, 2009; pp. 53–56, ISBN 978-1-60558-805-6. [Google Scholar] [CrossRef] [Scilit]
  17. Riloff, E.; Qadir, A.; Surve, P.; De Silva, L.; Gilbert, N.; Huang, R. Sarcasm as Contrast between a Positive Sentiment and Negative Situation. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, Seattle, WA, USA, 18–21 October 2013; Yarowsky, D., Baldwin, T., Korhonen, A., Livescu, K., Bethard, S., Eds.; Association for Computational Linguistics: Stroudsburg, PA, USA, 2013; pp. 704–714. [Google Scholar]
  18. Savini, E.; Caragea, C. A Multi-Task Learning Approach to Sarcasm Detection (Student Abstract). Proc. AAAI Conf. Artif. Intell. 2020, 34, 13907–13908. [Google Scholar] [CrossRef] [Scilit]
  19. Savini, E.; Caragea, C. Intermediate-Task Transfer Learning with BERT for Sarcasm Detection. Mathematics 2022, 10, 844. [Google Scholar] [CrossRef] [Scilit]
  20. Chen, W.; Lin, F.; Li, G.; Liu, B. A survey of automatic sarcasm detection: Fundamental theories, formulation, datasets, detection methods, and opportunities. Neurocomputing 2024, 578, 127428. [Google Scholar] [CrossRef] [Scilit]
  21. Vitman, O.; Kostiuk, Y.; Sidorov, G.; Gelbukh, A. Sarcasm detection framework using context, emotion and sentiment features. Expert Syst. Appl. 2023, 234, 121068. [Google Scholar] [CrossRef] [Scilit]
  22. Babanejad, N.; Davoudi, H.; An, A.; Papagelis, M. Affective and Contextual Embedding for Sarcasm Detection. In Proceedings of the 28th International Conference on Computational Linguistics, Barcelona, Spain (Online), 8–13 December 2020; Scott, D., Bel, N., Zong, C., Eds.; International Committee on Computational Linguistics: Barcelona, Spain, 2020; pp. 225–243. [Google Scholar] [CrossRef] [Scilit]
  23. Joshi, A.; Tripathi, V.; Patel, K.; Bhattacharyya, P.; Carman, M. Are Word Embedding-based Features Useful for Sarcasm Detection? In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, Austin, TX, USA, 1–5 November 2016; Su, J., Duh, K., Carreras, X., Eds.; Association for Computational Linguistics: Austin, TX, USA, 2016; pp. 1006–1011. [Google Scholar] [CrossRef] [Scilit]
  24. Tang, D.; Wei, F.; Yang, N.; Zhou, M.; Liu, T.; Qin, B. Learning Sentiment-Specific Word Embedding for Twitter Sentiment Classification. In Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), Baltimore, MD, USA, 23–24 June 2014; Toutanova, K., Wu, H., Eds.; Association for Computational Linguistics: Baltimore, MD, USA, 2014; pp. 1555–1565. [Google Scholar] [CrossRef] [Scilit]
  25. Fu, P.; Lin, Z.; Yuan, F.; Wang, W.; Meng, D. Learning Sentiment-Specific Word Embedding via Global Sentiment Representation. Proc. AAAI Conf. Artif. Intell. 2018, 32, 4808–4815. [Google Scholar] [CrossRef] [Scilit]
  26. Kasri, M.; Birjali, M.; Nabil, M.; Beni-Hssane, A.; El-Ansari, A.; El Fissaoui, M. Refining Word Embeddings with Sentiment Information for Sentiment Analysis. J. ICT Stand. 2022, 10, 353–382. [Google Scholar] [CrossRef] [Scilit]
  27. Baccianella, S.; Esuli, A.; Sebastiani, F. SentiWordNet 3.0: An enhanced lexical resource for sentiment analysis and opinion mining. In Proceedings of the Seventh International Conference on Language Resources and Evaluation (LREC’10), Valletta, Malta, 17–23 May 2010; Available online: https://www.researchgate.net/publication/220746537_SentiWordNet_30_An_Enhanced_Lexical_Resource_for_Sentiment_Analysis_and_Opinion_Mining (accessed on 19 September 2024).
  28. Cambria, E.; Li, Y.; Xing, F.Z.; Poria, S.; Kwok, K. SenticNet 6: Ensemble Application of Symbolic and Subsymbolic AI for Sentiment Analysis. In Proceedings of the 29th ACM International Conference on Information & Knowledge Management, Ser. CIKM’20, Virtual, 19–23 October 2020; Association for Computing Machinery: New York, NY, USA, 2020; pp. 105–114, ISBN 978-1-4503-6859-9. [Google Scholar] [CrossRef] [Scilit]
  29. Hutto, C.; Gilbert, E. VADER: A Parsimonious Rule-Based Model for Sentiment Analysis of Social Media Text. Proc. Int. AAAI Conf. Web Soc. Media 2014, 8, 216–225. [Google Scholar] [CrossRef] [Scilit]
  30. Kim, Y. Convolutional neural networks for sentence classification. arXiv 2014, arXiv:1408.5882. [Google Scholar]
  31. Suhartono, D.; Purwandari, K.; Jeremy, N.H.; Philip, S.; Arisaputra, P.; Parmonangan, I.H. Deep neural networks and weighted word embeddings for sentiment analysis of drug product reviews. Procedia Comput. Sci. 2023, 216, 664–671. [Google Scholar] [CrossRef] [Scilit]
  32. Najafabadi, M.K. Sentiment analysis incorporating convolutional neural network into hidden Markov model. Comput. Intell. 2024, 40, e12633. [Google Scholar] [CrossRef] [Scilit]
  33. Strapparava, C.; Valitutti, A. WordNet Affect: An Affective Extension of WordNet. In Proceedings of the Fourth International Conference on Language Resources and Evaluation (LREC’04), Lisbon, Portugal, 24–30 May 2004; Lino, M.T., Xavier, M.F., Ferreira, F., Costa, R., Silva, R., Eds.; European Language Resources Association (ELRA): Lisbon, Portugal, 2004. [Google Scholar]
  34. Mohammad, S.M.; Turney, P.D. Crowdsourcing a Word-Emotion Association Lexicon. arXiv 2013. [Google Scholar] [CrossRef] [Scilit]
  35. Agrawal, A.; An, A. Affective Representations for Sarcasm Detection. In Proceedings of the 41st International ACM SIGIR Conference on Research & Development in Information Retrieval, Ser. SIGIR ’18, Ann Arbor, MI, USA, 8–12 July 2018; Association for Computing Machinery: New York, NY, USA, 2018; pp. 1029–1032, ISBN 978-1-4503-5657-2. [Google Scholar] [CrossRef] [Scilit]
  36. Mohammad, S.M. Word Affect Intensities. arXiv 2022. [Google Scholar] [CrossRef] [Scilit]
  37. Yue, T.; Mao, R.; Wang, H.; Hu, Z.; Cambria, E. KnowleNet: Knowledge fusion network for multimodal sarcasm detection. Inf. Fusion 2023, 100, 101921. [Google Scholar] [CrossRef] [Scilit]
  38. Li, J.; Pan, H.; Lin, Z.; Fu, P.; Wang, W. Sarcasm detection with commonsense knowledge. IEEE/ACM Trans. Audio Speech Lang. Process. 2021, 29, 3192–3201. [Google Scholar] [CrossRef] [Scilit]
  39. Cambria, E.; Liu, Q.; Decherchi, S.; Xing, F.; Kwok, K. SenticNet 7: A Commonsense-based Neurosymbolic AI Framework for Explainable Sentiment Analysis. In Proceedings of the Thirteenth Language Resources and Evaluation Conference, Marseille, France, 20–25 June 2022; Calzolari, N., Béchet, F., Blache, P., Choukri, K., Cieri, C., Declerck, T., Goggi, S., Isahara, H., Maegaard, B., Mariani, J., et al., Eds.; European Language Resources Association: Marseille, France, 2022; pp. 3829–3839. [Google Scholar]
  40. Speer, R.; Chin, J.; Havasi, C. ConceptNet 5.5: An open multilingual graph of general knowledge. In Proceedings of the Thirty-First AAAI Conference on Artificial Intelligence, Ser. AAAI’17, San Francisco, CA, USA, 4–9 February, 2017; AAAI Press: Washington, DC, USA, 2017; pp. 4444–4451. [Google Scholar]
  41. Bosselut, A.; Rashkin, H.; Sap, M.; Malaviya, C.; Celikyilmaz, A.; Choi, Y. COMET: Commonsense transformers for automatic knowledge graph construction. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, Florence, Italy, 28 July–2August 2019. [Google Scholar]
  42. Devlin, J.; Chang, M.-W.; Lee, K.; Toutanova, K. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv 2019, arXiv:1810.04805. [Google Scholar]
  43. Liu, Y. Roberta: A robustly optimized bert pretraining approach. arXiv 2019, arXiv:1907.11692. [Google Scholar]
  44. Krishna, M.M.; Janarthanan, M.; Vankara, J. Detection of Sarcasm Using Bi-Directional RNN Based Deep Learning Model in Sentiment Analysis. J. Adv. Res. Appl. Sci. Eng. Technol. 2023, 31, 352–362. [Google Scholar] [CrossRef] [Scilit]
  45. Wang, J.; Zhang, Y.; Yu, L.-C.; Zhang, X. Contextual sentiment embeddings via bi-directional GRU language model. Knowl.-Based Syst. 2022, 235, 107663. [Google Scholar] [CrossRef] [Scilit]
  46. González, J.Á.; Hurtado, L.-F.; Pla, F. Transformer based contextualization of pre-trained word embeddings for irony detection in Twitter. Inf. Process. Manag. 2020, 57, 102262. [Google Scholar] [CrossRef] [Scilit]
  47. Potamias, R.A.; Siolas, G.; Stafylopatis, A.-G. A transformer-based approach to irony and sarcasm detection. Neural Comput. Appl. 2020, 32, 17309–17320. [Google Scholar] [CrossRef] [Scilit]
  48. Ilić, S.; Marrese-Taylor, E.; Balazs, J.A.; Matsuo, Y. Deep contextualized word representations for detecting sarcasm and irony. arXiv 2018, arXiv:1809.09795. [Google Scholar]
  49. Kunneman, F.; Liebrecht, C.; van Mulken, M.; van den Bosch, A. Signaling sarcasm: From hyperbole to hashtag. Inf. Process. Manag. 2015, 51, 500–509. [Google Scholar] [CrossRef] [Scilit]
  50. Bharti, S.K.; Vachha, B.; Pradhan, R.K.; Babu, K.S.; Jena, S.K. Sarcastic sentiment detection in tweets streamed in real time: A big data approach. Digit. Commun. Netw. Adv. Big Data 2016, 2, 108–121. [Google Scholar] [CrossRef] [Scilit]
  51. Tasnia, R.; Ayman, N.; Sultana, A.; Chy, A.N.; Aono, M. Exploiting stacked embeddings with LSTM for multilingual humor and irony detection. Soc. Netw. Anal. Min. 2023, 13, 43. [Google Scholar] [CrossRef] [Scilit]
  52. Felbo, B.; Mislove, A.; Søgaard, A.; Rahwan, I.; Lehmann, S. Using millions of emoji occurrences to learn any-domain representations for detecting sentiment, emotion and sarcasm. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, Copenhagen, Denmark, 9–11 September 2017; Association for Computational Linguistics: Stroudsburg, PA, USA, 2017. [Google Scholar] [CrossRef] [Scilit]
  53. Poria, S.; Cambria, E.; Hazarika, D.; Vij, P. A deeper look into sarcastic tweets using deep convolutional neural networks. arXiv 2017, arXiv:1610.08815. [Google Scholar]
  54. Mohan, A.; Nair, A.M.; Jayakumar, B.; Muraleedharan, S. Sarcasm Detection Using Bidirectional Encoder Representations from Transformers and Graph Convolutional Networks. Procedia Comput. Sci. Int. Conf. Mach. Learn. Data Eng. 2023, 218, 93–102. [Google Scholar] [CrossRef] [Scilit]
  55. Ortega-Bueno, R.; Rosso, P.; Medina Pagola, J.E. Multi-view informed attention-based model for Irony and Satire detection in Spanish variants. Knowl.-Based Syst. 2022, 235, 107597. [Google Scholar] [CrossRef] [Scilit]
  56. Cer, D.; Yang, Y.; Kong, S.-Y.; Hua, N.; Limtiaco, N.; John, R.S.; Constant, N.; Guajardo-Cespedes, M.; Yuan, S.; Tar, C.; et al. Universal sentence encoder. arXiv 2018, arXiv:1803.11175. [Google Scholar]
  57. Tay, Y.; Tuan, L.A.; Hui, S.C.; Su, J. Reasoning with sarcasm by reading in-between. arXiv 2018, arXiv:1805.02856. [Google Scholar]
  58. Xiong, T.; Zhang, P.; Zhu, H.; Yang, Y. Sarcasm Detection with Self-matching Networks and Low-rank Bilinear Pooling. In Proceedings of the World Wide Web Conference, Ser. WWW’19, San Francisco, CA, USA, 13–17 May 2019; Association for Computing Machinery: New York, NY, USA, 2019; pp. 2115–2124, ISBN 978-1-4503-6674-8. [Google Scholar] [CrossRef] [Scilit]
  59. Agrawal, A.; An, A.; Papagelis, M. Leveraging Transitions of Emotions for Sarcasm Detection. In Proceedings of the 43rd International ACM SIGIR Conference on Research and Development in Information Retrieval, Ser. SIGIR’20, Xi’an, China, 25–30 July 2020; Association for Computing Machinery: New York, NY, USA, 2020; pp. 1505–1508, ISBN 978-1-4503-8016-4. [Google Scholar] [CrossRef] [Scilit]
  60. Zhou, P.; Shi, W.; Tian, J.; Qi, Z.; Li, B.; Hao, H.; Xu, B. Attention-based bidirectional long short-term memory networks for relation classification. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), Berlin, Germany, 7–12 August 2016; Erk, K., Smith, N.A., Eds.; Association for Computational Linguistics: Berlin, Germany, 2016; pp. 207–212. [Google Scholar] [CrossRef] [Scilit]
  61. Pan, H.; Lin, Z.; Fu, P.; Wang, W. Modeling the Incongruity Between Sentence Snippets for Sarcasm Detection. In Proceedings of the ECAI 2020, Santiago de Compostela, Spain, 29 August–8 September 2020; IOS Press: Amsterdam, The Netherlands, 2020; pp. 2132–2139. [Google Scholar] [CrossRef] [Scilit]
  62. Schifanella, R.; Juan, P.; de Tetreault, J.; Cao, L. Detecting sarcasm in multimodal social platforms. In Proceedings of the 24th ACM International Conference on Multimedia, Ser. MM’16, ACM, Amsterdam, The Netherlands, 15–19 October 2016. [Google Scholar] [CrossRef] [Scilit]
  63. Hazarika, D.; Poria, S.; Gorantla, S.; Cambria, E.; Zimmermann, R.; Mihalcea, R. CASCADE: Contextual sarcasm detection in online discussion forums. In Proceedings of the 27th International Conference on Computational Linguistics, Santa Fe, NM, USA, 20–26 August 2018; Bender, E.M., Derczynski, L., Isabelle, P., Eds.; Association for Computational Linguistics: Santa Fe, NM, USA, 2018; pp. 1837–1848. Available online: https://aclanthology.org/C18-1156 (accessed on 19 September 2024).
  64. Castro, S.; Hazarika, D.; Perez-Rosas, V.; Zimmermann, R.; Mihalcea, R.; Poria, S. Towards multimodal sarcasm detection (an Obviously perfect paper). In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, Florence, Italy, 28 July–2 August 2019; Korhonen, A., Traum, D., M’arquez, L., Eds.; Association for Computational Linguistics: Florence, Italy, 2019; pp. 4619–4629. [Google Scholar] [CrossRef] [Scilit]
  65. Wallace, B.C.; Choe, D.K.; Kertz, L.; Charniak, E. Humans require context to infer ironic intent (so computers probably do, too). In Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), Baltimore, MD, USA, 23–24 June 2014; Toutanova, K., Wu, H., Eds.; Association for Computational Linguistics: Baltimore, MD, USA, 2014; pp. 512–516. [Google Scholar] [CrossRef] [Scilit]
  66. Zhang, S.; Zhang, X.; Chan, J.; Rosso, P. Irony detection via sentiment-based transfer learning. Inf. Process. Manag. 2019, 56, 1633–1644. [Google Scholar] [CrossRef] [Scilit]
  67. Khodak, M.; Saunshi, N.; Vodrahalli, K. A Large Self-Annotated Corpus for Sarcasm. arXiv 2018. [Google Scholar] [CrossRef] [Scilit]
  68. Ren, Y.; Wang, Z.; Peng, Q.; Ji, D. A knowledge-augmented neural network model for sarcasm detection. Inf. Process. Manag. 2023, 60, 103521. [Google Scholar] [CrossRef] [Scilit]
  69. Ghorbanali, A.; Sohrabi, M.K.; Yaghmaee, F. Ensemble transfer learning-based multimodal sentiment analysis using weighted convolutional neural networks. Inf. Process. Manag. 2022, 59, 102929. [Google Scholar] [CrossRef] [Scilit]
  70. Majumder, N.; Poria, S.; Peng, H.; Chhaya, N.; Cambria, E.; Gelbukh, A. Sentiment and sarcasm classification with multitask learning. arXiv 2019, arXiv:1901.08014. [Google Scholar] [CrossRef] [Scilit]
  71. Reimers, N.; Gurevych, I. Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks. arXiv 2019. [Google Scholar] [CrossRef] [Scilit]
  72. Cambria, E.; Zhang, X.; Mao, R.; Chen, M.; Kwok, K. Senticnet 8: Fusing Emotion AI and Commonsense AI for Interpretable, Trustworthy, and Explainable Affective Computing. Available online: https://api.semanticscholar.org/CorpusID:269010560 (accessed on 19 September 2024).
  73. Loureiro, D.; Barbieri, F.; Neves, L.; Anke, L.E.; Camacho-Collados, J. Timelms: Diachronic language models from twitter. arXiv 2022, arXiv:2202.03829. [Google Scholar]
  74. Falcon, W.A. Pytorch Lightning; GitHub: San Francisco, CA, USA, 2019; Volume 3. [Google Scholar]
  75. Oraby, S.; Harrison, V.; Reed, L.; Hernandez, E.; Riloff, E.; Walker, M. Creating and Characterizing a Diverse Corpus of Sarcasm in Dialogue. In Proceedings of the 17th Annual Meeting of the Special Interest Group on Discourse and Dialogue, Los Angeles, CA, USA, 13–15 September 2016; Fernandez, R., Minker, W., Carenini, G., Higashinaka, R., Artstein, R., Gainer, A., Eds.; Association for Computational Linguistics: Los Angeles, CA, USA, 2016; pp. 31–41. [Google Scholar] [CrossRef] [Scilit]
  76. Zhang, M.; Zhang, Y.; Fu, G. Tweet sarcasm detection using deep neural network. In Proceedings of the COLING 2016, the 26th International Conference on Computational Linguistics: Technical Papers, Osaka, Japan, 11–16 December 2016; Matsumoto, Y., Prasad, R., Eds.; The COLING 2016 Organizing Committee: Osaka, Japan, 2016; pp. 2449–2460. Available online: https://aclanthology.org/C16-1231 (accessed on 19 September 2024).
  77. Ghosh, A.; Veale, T. Fracking sarcasm using neural network. In Proceedings of the 7th Workshop on Computational Approaches to Subjectivity, Sentiment and Social Media Analysis, San Diego, CA, USA, 16 June 2016; Balahur, A., van der Goot, E., Vossen, P., Montoyo, A., Eds.; Association for Computational Linguistics: San Diego, CA, USA, 2016; pp. 161–169. [Google Scholar] [CrossRef] [Scilit]
  78. Akula, R.; Garibay, I. Interpretable multi-head self-attention architecture for sarcasm detection in social media. Entropy 2021, 23, 394. [Google Scholar] [CrossRef] [Scilit] [PubMed]
  79. Najafabadi, M.K.; Nair, M.B.; Mohamed, A. Tag recommendation model using feature learning via word embedding. In Proceedings of the 2021 IEEE 19th World Symposium on Applied Machine Intelligence and Informatics (SAMI), Herl’any, Slovakia, 21–23 January 2021; IEEE: Piscataway, NJ, USA, 2021; pp. 305–310. [Google Scholar]
  80. Lin, J.; Najafabadi, M.K. Aspect level sentiment analysis with CNN Bi-LSTM and attention mechanism. In Proceedings of the 2023 IEEE/ACIS 8th International Conference on Big Data, Cloud Computing, and Data Science (BCD), Taiyuan, China, 5–7 July 2023; IEEE: Piscataway, NJ, USA, 2023; pp. 282–288. [Google Scholar]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Article Metrics

Citations

Article Access Statistics

Multiple requests from the same IP address are counted as one view.