Skip to main content
Log in

CAT-BiGRU: Convolution and Attention with Bi-Directional Gated Recurrent Unit for Self-Deprecating Sarcasm Detection

  • Published:
Cognitive Computation Aims and scope Submit manuscript

Abstract

Sarcasm detection has been a well-studied problem for the computational linguistic researchers. However, research related to different categories of sarcasm has still not gained much attention. Self-Deprecating Sarcasm (SDS) is a special category of sarcasm in which users apply sarcasm over themselves, and it is extensively used in social media platforms, mainly as an advertising tool for the brand endorsement, product campaign, and digital marketing with an aim to increase the sales volume. In this paper, we present a deep learning approach for detecting SDS on Twitter. We propose a novel Convolution and Attention with Bi-directional Gated Recurrent Unit (CAT-BiGRU) model, which consists of an input, embedding, convolutional, Bi-directional Gated Recurrent Unit (BiGRU), and two attention layers. The convolutional layer extracts SDS-based syntactic and semantic features from the embedding layer, BiGRU layer retrieves contextual information from the extracted features in both preceding and succeeding directions, and attention layers are used to retrieve SDS-based comprehensive context representation from the input texts. Finally, sigmoid function is employed to classify the input texts as a self-deprecating or non-self-deprecating sarcasm. Experiments are conducted over seven Twitter datasets to evaluate the proposed (CAT-BiGRU) model using standard evaluation metrics. The experimental results are impressive and significantly better than many neural network-based baselines and state-of-the-art methods. In this paper, we have highlighted biologically inspired and psychologically motivated basis of the proposed approach to examine its affective capabilities with respect to SenticNet. The efficacy of the proposed model is evaluated on two SenticNet-based sentic computing resources—Amazon word embedding and AffectiveSpace. Based on the experimental results, we conclude that deep learning-based approaches have potential to detect SDS in social media texts accurately.

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

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13

Similar content being viewed by others

Notes

  1. https://bit.ly/2WsUkUk (last accessed on Dec. 03, 20)

  2. https://bit.ly/34n06rx (last accessed on Dec. 03, 20)

  3. https://bit.ly/3qmxJF9 (last accessed on Dec. 03, 20)

  4. https://github.com/Ashraf-Kamal/Self-Deprecating-Sarcasm-Detection

  5. https://twitter.com/en/tos (last accessed on Dec. 03, 20)

  6. https://twitter.com/en/privacy (last accessed on Dec. 03, 20)

  7. https://developer.twitter.com/en/developer-terms/agreement-and-policy (last accessed on Dec. 03, 20)

  8. https://spacy.io/ (last accessed on Dec. 03, 20)

  9. https://www.ling.upenn.edu/courses/Fall_2003/ling001/penn_treebank_pos.html (last accessed on Dec. 03, 20)

  10. https://keras.io/(last accessed on Dec. 03, 20)

References

  1. Bouazizi M, Ohtsuki T. Opinion mining in twitter how to make use of sarcasm to enhance sentiment analysis. In: Proceedings of the IEEE/ACM International Conference on Advances in Social Networks Analysis and Mining (ASONAM), Paris, France, August 25–28, 2015; pp. 1594–1597.

  2. Abulaish M, Kamal A, Zaki MJ. A survey of figurative language and its computational detection in online social networks. ACM Transactions on the Web. 2020;14(1):1–52.

    Article  Google Scholar 

  3. Bouazizi M, Ohtsuki T. A pattern-based approach for sarcasm detection on twitter. IEEE Access. 2016;4(1):5477–88.

    Article  Google Scholar 

  4. Ghosh A, Li G, Veale T, Rosso P, Shutova E, Barnden J, Reyes A. Semeval-2015 task 11: sentiment analysis of figurative language in twitter. In: Proceedings of the 9th International Workshop on Semantic Evaluation (SemEval), Denver, Colorado, June 4–5, 2015; pp. 470–478.

  5. Stieger S, Formann AK, Burger C. Humor styles and their relationship to explicit and implicit self-esteem. Personality and Individual Differences. 2011;50(5):747–50.

    Article  Google Scholar 

  6. Kamal A, Abulaish M. Self-deprecating humor detection: a machine learning approach. In: Proceedings of the 16th International Conference of the Pacific Association for Computational Linguistics (PACLING), Hanoi, Vietnam, October 11–13, 2019; pp. 1–13.

  7. Kamal A, Abulaish M. An LSTM-based deep learning approach for detecting self-deprecating sarcasm in textual data. In: Proceedings of the 16th International Conference on Natural Language Processing (ICON), Hyderabad, India, December 18–21, 2019; pp. 1–10.

  8. Joshi A, Bhattacharyya P, Carman MJ. Automatic sarcasm detection: a survey. ACM Computing Surveys. 2017;50(5):1–22.

    Article  Google Scholar 

  9. Zhang M, Zhang Y, Fu G. Tweet sarcasm detection using deep neural network. In: Proceedings of the 26th International Conference on Computational Linguistics (COLING), Osaka, Japan, December 11–17, 2016; pp. 2449–2460.

  10. González-Ibáñez R, Muresan S, Wacholder N. Identifying sarcasm in Twitter: a closer look. In: Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics (ACL), Portland, Oregon, June 19–24, 2011; pp. 581–586.

  11. Lukin S, Walker M. Really? well. apparently bootstrapping improves the performance of sarcasm and nastiness classifiers for online dialogue. In: Proceedings of the Workshop on Language in Social Media (LASM), Atlanta, Georgia, June 13, 2013; pp. 30–40.

  12. Rajadesingan A, Zafarani R, Liu H. Sarcasm detection on twitter: a behavioral modeling approach. In: Proceedings of the 8th Association for Computing Machinery International Conference on Web Search and Data Mining (WSDM), Shanghai, China, February 2–6, 2015; pp. 97–106.

  13. Tsur O, Davidov D, Rappoport A. ICWSM–a great catchy name: semi-supervised recognition of sarcastic sentences in online product reviews. In: Proceedings of the 4th International Association for the Advancement of Artificial Intelligence Conference on Weblogs and Social Media (ICWSM), Washington, DC, USA, May 23–26, 2010; pp. 162–169.

  14. Davidov D, Tsur O, Rappoport A. Semi-supervised recognition of sarcastic sentences in twitter and amazon. In: Proceedings of the 14th Conference on Computational Natural Language Learning (CoNLL), Uppsala, Sweden, July 15–16, 2010; pp. 107–116.

  15. Abulaish M, Kamal A. Self-deprecating sarcasm detection: an amalgamation of rule-based and machine learning approach. In: Proceedings of the IEEE/WIC/ACM International Conference on Web Intelligence (WI), Santiago, Chile, December 3–6, 2018; pp. 574–579.

  16. Schifanella R, de Juan P, Tetreault J, Cao L. Detecting sarcasm in multimodal social platforms. In: Proceedings of the ACM on Multimedia Conference (ACM MM), Amsterdam, Netherlands, October 15–19, 2016; pp. 1136–1145.

  17. Amir S, Wallace BC, Lyu H, Silva PC. Modelling context with user embeddings for sarcasm detection in social media. In: Proceedings of the 20th Special Interest Group on Natural Language Learning Conference (SIGNLL) on Computational Natural Language Learning (CoNLL), Berlin, Germany, August 7–12, 2016; pp. 167–177.

  18. Poria S, Cambria E, Hazarika D, Vij P. A deeper look into sarcastic tweets using deep convolutional neural networks. In: Proceedings of the 26th International Conference on Computational Linguistics: Technical Papers (COLING), Osaka, Japan, December 11-16, 2016; pp. 1601–1612.

  19. Avvaru A, Vobilisetty S, Mamidi, R. Detecting sarcasm in conversation context using transformer-based models. In: Proceedings of the 2nd Workshop on Figurative Language Processing (ACL), July 9, 2020; pp. 98–103.

  20. Dubey A, Joshi A, Bhattacharyya P. Deep models for converting sarcastic utterances into their non sarcastic interpretation. In: Proceedings of the ACM India Joint International Conference on Data Science and Management of Data (CoDS-COMAD), Koklata, India, January 3–5, 2019; pp. 289–292.

  21. Dubey A, Kumar L, Somani A, Joshi A, Bhattacharyya P. ”When numbers matter!”: detecting sarcasm in numerical portions of text. In: Proceedings of the 10th Workshop on Computational Approaches to Subjectivity, Sentiment and Social Media Analysis (WASSA), June 6, 2019; pp. 72–80.

  22. 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 (EMNLP), Seattle, Washington, USA, October 18-21, 2013; pp. 704–714.

  23. Khattri A, Joshi A, Bhattacharyya P, Carman MJ. Your sentiment precedes you: Using an author’s historical tweets to predict sarcasm. In: Proceedings of the 6th Workshop on Computational Approaches to Subjectivity, Sentiment and Social Media Analysis (WASSA), Lisboa, Portugal, September 17, 2015; pp. 25–30.

  24. Bharti SK, Babu KS, Jena SK. Parsing-based sarcasm sentiment recognition in twitter data. In: Proceedings of the IEEE/ACM International Conference on Advances in Social Networks Analysis and Mining (ASONAM), Paris, France, August 25–28, 2015; pp. 1373–1380.

  25. Liebrecht CC, Kunneman FA, Van Den Bosch AP. The perfect solution for detecting sarcasm in tweets #not. In: Proceedings of the 4th Workshop on Computational Approaches to Subjectivity, Sentiment and Social Media Analysis (WASSA), Atlanta, Georgia, June 13–14, 2013; pp. 29–37.

  26. Littlestone N. Learning quickly when irrelevant attributes abound: A new linear-threshold algorithm. Machine Learning. 1988;2(4):285–318.

    Google Scholar 

  27. Mishra A, Kanojia D, Bhattacharyya P. Predicting readers’ sarcasm understandability by modeling gaze behavior. In: Proceedings of the 13th Association for the Advancement of Artificial Intelligence Conference on Artificial Intelligence (AAAI), Phoenix, Arizona, USA, February 12–17, 2016; pp. 3747–3753.

  28. Zhao Z, Resnick P, Mei Q. Enquiring minds: Early detection of rumors in social media from enquiry posts. In: Proceedings of the 24th International Conference on World Wide Web (WWW), Florence, Italy, May 18–22, 2015; pp. 1395–1405.

  29. Liu G, Guo J. Bidirectional LSTM with attention mechanism and convolutional layer for text classification. Neurocomputing. 2019;337:325–38.

    Article  Google Scholar 

  30. Ptácek T, Habernal I, Hong J. Sarcasm detection on czech and english twitter. In: Proceedings of the 25th International Conference on Computational Linguistics (COLING), Dublin, Ireland, August 23–29, 2014; pp. 213–223.

  31. Ling J, Klinger R. An empirical quantitative analysis of the differences between sarcasm and irony. In: Sack H, Rizzo G, Steinmetz N, Mladenic D, Auer S, Lange C. (eds). The Semantic Web. ESWC 2016. LNCS, Springer; 9989: pp. 203–216.

  32. Bamman D, Smith NA. Contextualized sarcasm detection on twitter. In: Proceedings of the 9th International Association for the Advancement of Artificial Intelligence Conference on Web and Social Media (ICWSM), Oxford, UK, May 26–29, 2015; pp. 574–577.

  33. Ghosh A, Veale T. Fracking sarcasm using neural network. In: Proceedings of the 15th North American Chapter of the Association for Computational Linguistics: Human Language Technologies (NAACL-HLT), San Diego, California, USA, June 12–17, 2016; pp. 161–169.

  34. Kim Y. Convolutional neural networks for sentence classification. In: Proceedings of the Conference on Empirical Methods in Natural Language Processing (EMNLP), Doha, Qatar, October 25–29, 2014; pp. 1746–1751.

  35. Hochreiter S, Schmidhuber J. Long short-term memory. Neural Computation. 1997;9(8):1735–80.

    Article  Google Scholar 

  36. Justo R, Alcaide JM, Torres MI, Walker M. Detection of sarcasm and nastiness: new resources for spanish language. Cognitive Computation. 2018;10(6):1135–51.

    Article  Google Scholar 

  37. Elovici Y, Fire M, Herzberg A, Shulman H. Ethical considerations when employing fake identities in online social networks for research. Science and Engineering Ethics. 2014;20(4):1027–43.

    Article  Google Scholar 

  38. Zinck A. Self-Referential Emotion. Emotions Hold the Self Together. 2011;105–33.

  39. Effron M. If only this was a detective novel Self-Referentiality as Metafictionality (Doctoral dissertation, Newcastle University), 2010.

  40. Boot AB, Sang ET, Dijkstra K, Zwaan RA. How character limit affects language usage in tweets. Palgrave Communications. 2019;5(1):1–13.

    Article  Google Scholar 

  41. Kreuz R, Caucci G. Lexical influences on the perception of sarcasm. In: Proceedings of the Workshop on Computational Approaches to Figurative Language, Rochester (ACL), NY, USA, April 26, 2007; pp. 1–4.

  42. Bengio Y, Ducharme R, Vincent P, Jauvin C. A neural probabilistic language model. Journal of Machine Learning Research. 2003;3(2):1137–55.

    MATH  Google Scholar 

  43. Carvalho J, Plastino A. On the evaluation and combination of state-of-the-art features in Twitter sentiment analysis. Artificial Intelligence Review. 2020; pp. 1–50.

  44. Cambria E. Affective computing and sentiment analysis. IEEE Intelligent Systems. 2016;31(2):102–7.

    Article  Google Scholar 

  45. Hussain A, Cambria E. Semi-supervised learning for big social data analysis. Neurocomputing. 2018;275:1662–733.

    Article  Google Scholar 

  46. Majumder N, Poria S, Peng H, Chhaya N, Cambria E, Gelbukh A. Sentiment and sarcasm classification with multitask learning. IEEE Intelligent Systems. 2019;34(3):38–433.

    Article  Google Scholar 

  47. Mehta Y, Majumder N, Gelbukh A, Cambria E. Recent trends in deep learning based personality detection. Artificial Intelligence Review. 2020;53(4):2313–39.

    Article  Google Scholar 

  48. Young T, Hazarika D, Poria S, Cambria E. Recent trends in deep learning based natural language processing. IEEE Computational Intelligence Magazine. 2018;13(3):55–75.

    Article  Google Scholar 

  49. Cambria E, Grassi M, Hussain A, Havasi C. Sentic computing for social media marketing. Multimedia Tools and Applications. 2012;59(2):557–77.

    Article  Google Scholar 

  50. Cambria E, Fu J, Bisio F, Poria S. Affectivespace 2: enabling affective intuition for concept-level sentiment analysis. In: Proceedings of the Association for the Advancement of Artificial Intelligence (AAAI), Austin, Texas, USA, January 25–30, 2015; pp. 508–514.

  51. 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 (COLING), Santa Fe, New-Mexico, USA, August 20–26, 2018; pp. 1837–1848.

  52. Cambria E, Li Y, Xing FZ, Poria S, Kwok K. Senticnet: SenticNet 6: ensemble application of symbolic and subsymbolic AI for sentiment analysis. In: Proceedings of the 29th ACM International Conference on Information & Knowledge Management (CIKM), October 19–23, 2020; pp. 105–114.

  53. Poria S, Cambria E, Gelbukh A. Aspect extraction for opinion mining with a deep convolutional neural network. Knowledge-Based Systems. 2016;108:42–9.

    Article  Google Scholar 

  54. Cambria E, Livingstone A, Hussain A. The hourglass of emotions. In: Cognitive behavioural systems 2012; pp. 144–157. Springer, Berlin, Heidelberg.

  55. Susanto Y, Livingstone AG, Ng BC, Cambria E. The hourglass model revisited. IEEE Intelligent Systems. 2020;35(5):96–102.

    Article  Google Scholar 

  56. Wang Z, Ho SB, Cambria E. A review of emotion sensing: categorization models and algorithms. Multimedia Tools and Applications. 2020: pp. 1–30

  57. Camacho D, Panizo-LLedot A, Bello-Orgaz G, Gonzalez-Pardo A, Cambria E. The four dimensions of social network analysis: an overview of research methods, applications, and software tools. Information Fusion. 2020;63:88–120.

    Article  Google Scholar 

  58. Cavallari S, Cambria E, Cai H, Chang KC, Zheng VW. Embedding both finite and infinite communities on graphs. IEEE computational intelligence magazine. 2019;14(3):39–50.

    Article  Google Scholar 

  59. Ma Y, Nguyen KL, Xing FZ, Cambria E. A survey on empathetic dialogue systems. Information Fusion. 2020;64:50–70.

    Article  Google Scholar 

Download references

Acknowledgements

This study was supported by Visvesvaraya PhD Scheme, MeitY, Govt. of India. ’MEITY-PHD-555’.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Muhammad Abulaish.

Ethics declarations

Conflict of Interest

The authors declare that they have no conflict of interest.

Ethical Approval

This article does not contain any studies with human participants or animals performed by any of the authors.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Kamal, A., Abulaish, M. CAT-BiGRU: Convolution and Attention with Bi-Directional Gated Recurrent Unit for Self-Deprecating Sarcasm Detection. Cogn Comput 14, 91–109 (2022). https://doi.org/10.1007/s12559-021-09821-0

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s12559-021-09821-0

Keywords

Navigation