SemEval-2020 Task 9: Overview of Sentiment Analysis of Code-Mixed Tweets

Parth Patwa, Gustavo Aguilar, Sudipta Kar, Suraj Pandey, Srinivas Pykl, Björn Gambäck, Tanmoy Chakraborty, Thamar Solorio, Amitava Das

TL;DR

This paper provides an overview of SentiMix 2020 (SemEval-2020 Task 9), a competition focused on sentiment analysis for code-mixed social media text. The authors released two novel datasets—Hinglish (Hindi-English) and Spanglish (Spanish-English)—and found that while code-mixing introduces significant linguistic complexity, transformer-based models like BERT and XLM-R are currently the most effective tools for the job.

What Problem Does This Paper Address?

Most Natural Language Processing (NLP) tools are designed for monolingual text, yet a huge portion of global social media users are multilingual and frequently engage in code-mixing (or code-switching). This is the practice of alternating between two or more languages within a single utterance.

Code-mixing presents unique hurdles for sentiment analysis:

  1. Transliteration: Users often write Hindi words using the Latin alphabet (phonetic typing) rather than Devanagari script.
  2. Morphological Mixing: Words from one language are often inflected using the grammar of another (e.g., adding the Spanish third-person suffix -es to the English verb push to get pushes).
  3. Non-standard Writing: Social media is rife with flexible grammar, slang, and informal abbreviations that break traditional NLP pipelines.

The SentiMix task was designed to benchmark how well current systems can identify sentiment (Positive, Negative, or Neutral) in these linguistically fluid environments.

Methods

The organizers established a baseline using Multilingual BERT (M-BERT), fine-tuned separately for each language pair. M-BERT is particularly interesting here because, although trained on monolingual Wikipedia dumps, it has shown a surprising ability to generalize across code-switched scenarios.

Participating teams pushed the state-of-the-art using several advanced techniques:

  • Transformer Variants: Beyond M-BERT, many top teams utilized XLM-R, a transformer-based model trained on 100 languages.
  • Ensemble Architectures: Combining CNNs, LSTMs, and self-attention mechanisms to capture both local features and long-range dependencies.
  • Data Augmentation: Using machine translation to expand the relatively small training sets.
  • Adversarial Training: Intentionally creating "noisy" examples to make the models more robust to the chaotic nature of social media text.

Datasets

The authors introduced two primary corpora, both annotated with word-level language identification and sentence-level sentiment labels.

Table 1: Class-wise statistics of the dataset for train, validation, and test set.
  • Hinglish (Hindi-English): 20,000 tweets. The organizers took special care to ensure a balanced distribution across the three sentiment classes.
  • Spanglish (Spanish-English): ~19,000 tweets. Unlike the Hinglish set, this data was highly imbalanced, with over 56% of the examples being Positive.

For the Spanglish dataset, the authors used a unique annotation interface where contributors used sliders to rate the strength of positive and negative signals independently, which were then converted into a 3-way classification.

Figure 1: A screenshot of the Spanglish annotation interface.

Key Insights and Ideas

  • Word-Level Mixing is Real: The examples in the paper (see Figure 3) debunk the myth that code-mixing only happens at the phrase level. Users frequently mix languages within a single word or tag, requiring models to have a very granular understanding of linguistics.
  • The Power of Pre-training: Even though models like XLM-R aren't explicitly trained on code-mixed data, their massive multilingual pre-training allows them to outperform classical ML methods (like SVMs or Naive Bayes) by a wide margin.
  • Sentiment Skew Matters: In the Spanglish task, models performed significantly better on the Positive class simply because it was over-represented in the training data. This highlights the ongoing need for high-quality, balanced datasets in low-resource language scenarios.
Table 2: Examples of labeled tweets showing the complexity of word-level language marking.

Key Results

The competition saw high engagement, with 89 total submissions.

  • Hinglish: The top team (KK2018) achieved a weighted F1 score of 75.0%, significantly beating the M-BERT baseline of 65.4%.
  • Spanglish: The winning team (LiangZhao) reached an F1 score of 80.6%, compared to the baseline of 65.6%.
Table 3: Top 15 Results for the Hinglish dataset.

As shown in the results table, the gap between the top performers and the baseline was substantial, largely due to the use of adversarial training and sophisticated ensemble methods.

Limitations and Future Work

The authors acknowledge that data scarcity remains the biggest bottleneck. While 20k examples is a start, it is small compared to monolingual English datasets. Furthermore, the inter-annotator agreement for Hinglish was only 55%, reflecting the inherent subjectivity and difficulty of sentiment analysis in code-mixed contexts.

Future work involves expanding the datasets to include more language pairs and moving beyond sentiment analysis to other tasks like Named Entity Recognition (NER), emotion recognition, and machine translation for code-mixed text.

Summary updated

Abstract

In this paper, we present the results of the SemEval-2020 Task 9 on Sentiment Analysis of Code-Mixed Tweets (SentiMix 2020). We also release and describe our Hinglish (Hindi-English) and Spanglish (Spanish-English) corpora annotated with word-level language identification and sentence-level sentiment labels. These corpora are comprised of 20K and 19K examples, respectively. The sentiment labels are - Positive, Negative, and Neutral. SentiMix attracted 89 submissions in total including 61 teams that participated in the Hinglish contest and 28 submitted systems to the Spanglish competition. The best performance achieved was 75.0% F1 score for Hinglish and 80.6% F1 for Spanglish. We observe that BERT-like models and ensemble methods are the most common and successful approaches among the participants.
BibTeX
@inproceedings{patwa2020semeval,
  author = {Parth Patwa and Gustavo Aguilar and Sudipta Kar and Suraj Pandey and Srinivas PYKL and Björn Gambäck and Tanmoy Chakraborty and Thamar Solorio and Amitava Das},
  title = {{SemEval-2020 Task 9: Overview of Sentiment Analysis of Code-Mixed Tweets}},
  booktitle = {SemEval @ COLING},
  year = {2020},
  doi = {10.18653/v1/2020.semeval-1.100},
}
Figure