Elamur Research⌕
☰
home / papers / 2011 / Sentiment Analysis of Twitter Data

Sentiment Analysis of Twitter Data

Summary

The paper addresses polarity classification of tweets in two settings: positive vs. negative, and a 3-way task that adds neutral. The authors use 11,875 tweets labelled by hand. A commercial provider collected them from the live Twitter stream without keyword filtering, so the sample is less biased than data gathered with search queries or emoticon-based distant labels. Preprocessing relies on two new resources, an emoticon polarity dictionary and an acronym expansion list. Three model types are compared:

  • a unigram baseline;
  • a feature-based model with about 100 "Senti-features" that combine prior word polarity with POS tags;
  • an SVM tree kernel over a custom tree representation of each tweet.

The 100 features match unigrams, which need over 10,000 features. The tree kernel and the model combinations beat the baseline by roughly 4% absolute. Feature analysis shows that polarity-by-POS features matter most, while Twitter-specific cues add little. The authors conclude that standard NLP tools and lexicons transfer to tweets reasonably well.

Key points

  • Data: 11,875 annotated tweets. After removing "junk" tweets, often caused by poor Google Translate output, 8,753 remain. Stratified sampling then gives a balanced set of 5,127 tweets, 1,709 per class.

  • Resources:

    • an emoticon dictionary of 170 Wikipedia-listed emoticons with five labels, from Extremely-positive to Extremely-negative plus Neutral;
    • an acronym dictionary of 5,184 entries, e.g. lol → laughing out loud.
  • Preprocessing: emoticons are replaced by their polarity, and URLs and @-targets are replaced by tags. Negations are normalised to NOT, and character runs are shortened to three letters.

  • 3-way results (5-fold CV, chance 33.33%):

    ModelAccuracy
    Unigram56.58%
    Senti-features56.31%
    Unigram + Senti-features60.50%
    Tree kernel60.60%
    Tree kernel + Senti-features≈60.83% (best)
  • Feature ranking: the strongest unigrams include clearly polar words, emoticon tags and the URL tag. Unexpectedly, "for" also ranks high, through patterns like "for you".

Interesting ideas

  • I1. Polarity crossed with POS: pairing a word's lexicon polarity with its part of speech gives a small, interpretable feature set that rivals large n-gram models. This could suit low-resource languages, where a sentiment lexicon plus a POS tagger are easier to obtain than lots of labelled data.
  • I2. Tree kernels instead of feature engineering: encoding each tweet as a tree and letting an SVM kernel compare structures removes most manual feature design. It still performs about as well as the best hand-built features, which makes it a quick strong baseline for new genres.
  • I3. Normalising noise into meaningful tags: mapping emoticons, URLs, mentions and negations to placeholder tokens, while keeping three-letter elongations, preserves emphasis and still shrinks the vocabulary. The step is cheap and reusable for any social-media corpus.
  • I4. Incremental ablation plus learning curves: adding feature groups one at a time shows which families actually help. Plotting accuracy against training-set size showed the gains over unigrams grow when data is scarce. Both checks are worth copying when justifying compact feature sets.
  • I5. Sampling from the stream rather than by query: a random sample of the stream avoids topic and emoticon biases in evaluation data. That is useful whenever a benchmark must reflect real-world language use.

Our summary of the paper, in our own words — not its text. The work belongs to its authors; read it at the links above.

Fields: Natural language processing

Topics: Part-of-speech tagging

Cited by

119 papers of our library cite it (of the 140884 whose bibliographies we read); 3 of them have a page here, 116 not yet.

Cite

The paper itself, not this page. BibTeX from the library's record of the work.

@inproceedings{agarwal2011sentiment,
  title = {{Sentiment Analysis of Twitter Data}},
  author = {Agarwal, Apoorv and Xie, Boyi and Vovsha, Ilia and Rambow, Owen and Passonneau, Rebecca},
  booktitle = {Proceedings of the Workshop on Language in Social Media (LSM 2011)},
  year = {2011},
  url = {https://aclanthology.org/W11-0705/}
}

References

16 references, 6 of them with a card of ours. ↗ leads to the work, «find» searches for one we have no id for yet.

  1. Apoorv Agarwal, Fadi Biadsy, and Kathleen Mckeown. 2009. Contextual phrase-level polarity analysis using lexical affect scoring and syntactic n-grams. Proceedings of the 12th Conference of the European Chapter of the ACL (EACL 2009), pages 24–32, March. find
  2. Luciano Barbosa and Junlan Feng. 2010. Robust sentiment detection on twitter from biased and noisy data. Proceedings of the 23rd International Conference on Computational Linguistics: Posters, pages 36–44. find our card
  3. Adam Bermingham and Alan Smeaton. 2010. Classifying sentiment in microblogs: is brevity an advantage is brevity an advantage? ACM, pages 1833–1836. find
  4. C. Fellbaum. 1998. Wordnet, an electronic lexical database. MIT Press. find
  5. Michael Gamon. 2004. Sentiment classification on customer feedback data: noisy data, large feature vectors, and the role of linguistic analysis. Proceedings of the 20th international conference on Computational Linguistics. find
  6. Alec Go, Richa Bhayani, and Lei Huang. 2009. Twitter sentiment classification using distant supervision. Technical report, Stanford. find
  7. David Haussler. 1999. Convolution kernels on discrete structures. Technical report, University of California at Santa Cruz. find
  8. M Hu and B Liu. 2004. Mining and summarizing customer reviews. KDD. find
  9. S M Kim and E Hovy. 2004. Determining the sentiment of opinions. Coling. find our card
  10. Dan Klein and Christopher D. Manning. 2003. Accurate unlexicalized parsing. Proceedings of the 41st Meeting of the Association for Computational Linguistics, pages 423–430. find our card
  11. Alessandro Moschitti. 2006. Efficient convolution kernels for dependency and constituent syntactic trees. In Proceedings of the 17th European Conference on Machine Learning. find
  12. Alexander Pak and Patrick Paroubek. 2010. Twitter as a corpus for sentiment analysis and opinion mining. Proceedings of LREC. find our card
  13. B. Pang and L. Lee. 2004. A sentimental education: Sentiment analysis using subjectivity analysis using subjectivity summarization based on minimum cuts. ACL. find
  14. P. Turney. 2002. Thumbs up or thumbs down? semantic orientation applied to unsupervised classification of reviews. ACL. find our card
  15. C M Whissel. 1989. The dictionary of Affect in Language. Emotion: theory research and experience, Acad press London. find
  16. T. Wilson, J. Wiebe, and P. Hoffman. 2005. Recognizing contextual polarity in phrase level sentiment analysis. ACL. find our card

↑ back to top

This page in Markdown → https://md.research.elamur.ai/free/en/papers/agarwal-2011-sentiment-analysis-twitter-data/