Abstract
Sentiment lexicons—dictionaries mapping words to emotional weights—are foundational to sentiment analysis. Traditional automatic construction methods rely on "counting" co-occurrences between words and sentiment labels using statistical measures like Pointwise Mutual Information (PMI). This paper argues that a "predictive" approach is superior. We introduce nnLexicon, a minimalist neural network that learns word-level sentiment scores by optimizing for tweet-level classification. Evaluated on millions of tweets in English and Arabic, nnLexicon consistently outperforms state-of-the-art statistical lexicons, demonstrating that direct optimization for prediction yields more nuanced and accurate sentiment representations.
Introduction
The construction of high-quality sentiment lexicons is a significant bottleneck in natural language processing. While manual curation provides high precision, it is slow and fails to scale with the evolving vocabulary of social media. Distant supervision—using emoticons or hashtags as proxy labels—has enabled the automatic creation of large-scale lexicons. However, these methods typically use "counting" approaches like PMI to associate words with sentiments.
The authors propose a shift from counting to predicting. By training a model to solve the sentiment classification task, the model is forced to learn word weights that minimize prediction error, effectively "correcting" for the noise inherent in distant supervision.
The nnLexicon Architecture
The proposed model, nnLexicon, is designed for extreme efficiency and simplicity. Each word $w$ in the vocabulary is represented by two learnable parameters: a negativity score ($n$) and a positivity score ($p$).
To represent a tweet, the model sums the $(n, p)$ vectors of all constituent words. This sum is then passed through a softmax layer to predict the probability of the tweet being positive or negative. Training is performed using backpropagation with the AdaDelta optimizer to minimize cross-entropy loss against emoticon-based labels. This architecture allows the model to learn weights based on how words contribute to the overall sentiment in context, a form of simple compositionality.
Experimental Setup
The model was trained on massive datasets collected via the Twitter API:
- English: 9 million tweets labeled by emoticons.
- Arabic: 800,000 tweets labeled by emoticons.
Evaluation was conducted on standard benchmarks: the SemEval 2013 Twitter dataset for English and the Arabic Sentiment Tweets Dataset (ASTD) for Arabic.
Results and Discussion
The predictive approach demonstrated clear superiority over traditional statistical methods. In the English SemEval 2013 benchmark, nnLexicon outperformed the previous state-of-the-art NRC method in both unsupervised and supervised settings.
As shown in the results, nnLexicon achieved an F-score of 75.3 in an unsupervised setting (compared to NRC's 73.8) and reached 81.3% accuracy in a supervised setting. Similar gains were observed in Arabic, where the model consistently beat the NRC baseline on both balanced and unbalanced test sets.
Qualitative analysis revealed that PMI-based methods often mislabel words due to simple co-occurrence noise (e.g., labeling "suitable" as negative). In contrast, the predictive model correctly identified these polarities by learning to balance word weights during the optimization process. Furthermore, the model is highly efficient, training on 9 million tweets in approximately 35 minutes on a standard desktop CPU.
Conclusion
This research highlights that for sentiment lexicon construction, predicting is better than counting. The nnLexicon model provides a language-agnostic, efficient, and highly effective way to learn sentiment weights from noisy social media data. Future work may involve expanding the model to handle more complex emotional dimensions beyond binary sentiment and exploring more sophisticated composition functions for longer texts.
Summary updated