• Keine Ergebnisse gefunden

Interaction Lab, Heriot-Watt University, EH144AS Edinburgh, Untied Kingdom.

eaar1@hw.ac.uk, v.t.rieser@hw.ac.uk

Abstract

Supervised machine learning methods for automatic subjectivity and sentiment analysis (SSA) are problematic when applied to social media, such as Twitter c, since they do not generalise well to unseen topics. A possible remedy of this problem is to apply distant supervision (DS) approaches, which learn from large amounts of automatically annotated data. In this research, we explore DS for SSA on Arabic Twitter feeds using emoticons as noisy labels. We achieve 95.19% accuracy, which is a 48.57% absolute improvement over our previous fully supervised results. While our results show a significant gain in detecting subjectivity, this approach proves to be difficult for sentiment analysis. An error analysis suggests that the most likely cause for this shortcoming is the unclear facing of emoticons due to the right-to-left direction of the Arabic alphabet.

Keywords:Subjectivity and Sentiment Analysis, Twitter, Arabic, Semi-Autonomous Learning on Big Data, Sarcasm, Cultural Bias

1. Introduction

The growth of social media, especially as a source for anal-ysis, has resulted in a two-fold challenge: managing the costs processing all of that data, as well as developing new ways to make sense of it. In addition, of course, in the small world in which we live, one needs to be able to handle mul-tiple languages and idioms equally well. In this work we explore different approaches to subjectivity and sentiment analysis (SSA) of Arabic tweets. SSA aims to determine the attitude of the user with respect to some topic, e.g. ob-jective or subob-jective, or the overall contextual polarity of an utterance, e.g. positive or negative. To the best of our knowledge, there is no publicly available large-scale Arabic Twitter ccorpus annotated for subjectivity and sentiment analysis. Creating a new data set is costly, and, as we will show in the following, learning from small data sets does not cover the wide scope of topics discussed on Twitter.

To the author’s knowledge this is the first empirical study of using distant supervision learning for Arabic social net-works.

2. Background

Arabic can be classified with respect to its morphology, syntax, and lexical combinations into three different cat-egories: classic Arabic (CA), modern standard Arabic (MSA), and dialectal Arabic (DA). Users on social net-works typically use the latter, i.e. dialectic varieties such as Egyptian Arabic and Gulf Arabic (Al-Sabbagh and Girju, 2012). Dealing with DA creates additional challenges for natural language processing (NLP): Being mainly spoken dialects, they lack standardisation, and are written in free-text (Zaidan and Callison-Burch, 2013). This problem is even more pronounced when moving to the micro-blog do-main, such as Twitter (Derczynski et al., 2013). People posting text on social networks tend to use informal writing style, for example by introducing their own abbreviations, as in example (1), or using spelling variations. In addition, tweets may also convey sarcasm, mixed and/or unclear

po-larity content, as in example (2) taken from our corpus (see Section 3.).

(1)

ÈñË

lol (laugh out loud) (2)

Q ªË@ ú æ . Jk.B

@ ÕÎJ ®Ë@ ø P éÊÓA « I®K. ú æ¯ñËX Qå”Ó ék.@ QÓ ú

Ϋ Ñk.Q

Kð h.Q ®JK. ɾË@ , Ñk.Q Ó

Egypt now is more like a foreign film without sub-titles, so everybody watches and puts their own translation.

Machine learning techniques are in general robust to such variety. Previous work on SSA has used manually anno-tated gold-standard data sets to analyse which feature sets and models perform best for this task, e.g. (Wilson et al., 2009; Wiebe et al., 1999). Most of this work is in English, but there have been first attempts to apply similar tech-niques to Arabic, e.g. (Abdul-Mageed et al., 2011; Mourad and Darwish, 2013). While these models work well when tested on limited static data sets, our previous results reveal that these models do not generalise well to new data sets collected at a later point in time due to their limited cover-age (Refaee and Rieser, 2014). In addition, while there is a growing interest within the NLP community to build Ara-bic corpora by harvesting the web, e.g. (Al-Sabbagh and Girju, 2012; Abdul-Mageed and Diab, 2012; Zaidan and Callison-Burch, 2013), these resources have not been pub-licly released yet and only small amounts of these data are (manually) annotated.

We therefore turn to an approach known asdistant super-vision(DS), as first proposed by (Read, 2005), which uses readily available features, such as emoticons, as noisy la-bels. This approach has been shown successful for English SSA, e.g. (Go et al., 2009; Suttles and Ide, 2013), and SSA for under-resourced languages, such as Chinese (Yuan and Purver, 2012).

Table 1: Sentiment label distribution of the gold-standard manually annotated and distant supervision training data sets.

3. Arabic Twitter SSA Corpora

We start by collecting corpora at different times over one year to account for the cyclic effects of topic change in so-cial media (Eisenstein, 2013): (1) A gold-standard data-set which we use for evaluation (spring 2013); (2) A data-set for DS using emoticon-based queries (autumn 2013). Table 1 shows the distributions of labels in our data-sets.

We use the Twitter Search API for corpus collection, which allows harvesting a stream of real-time tweets by querying their content. The tweets were collected at different times and days to reduce bias in the distribution of the number of tweets from individual users. In addition, we collected the used-ID of each retrieved tweet. The distribution of tweets per user IDs is 1.12. By setting the language variable toar, all retrieved tweets were restricted to Arabic. The extracted data is cleaned in a pre-processing step, e.g. normalise dig-its, non-Arabic characters, user-names and links.

3.1. Gold-Standard Dataset

We harvested two data sets at two different time steps, which we label manually. We first harvest a data set of 3,309 multi-dialectal Arabic tweets randomly retrieved over the period from February to March 2013. We use this set as a training set for our fully supervised approach (Re-faee and Rieser, 2014). We also manually labelled a subset of 963 tweets of the “emoticon-based” corpus (see Section 3.2.), which we use as an independent held-out test set.

Two native speakers of Arabic were recruited to manually annotate the collected data for subjectivity, i.e. subjec-tive/polar versus objective tweets, and sentiment, where we define sentiment as a positive or negative emotion, opin-ion, or attitude, following (Wilson et al., 2009). Our gold-standard annotations reached a weightedκ= 0.76, which indicates reliable annotations (Carletta, 1996).

We annotate the corpus with a rich set of linguistically mo-tivated features using freely available processing tools for Arabic, such as MADA (Nizar Habash and Roth, 2009), see Table 2. For more details please see (Refaee and Rieser, 2014).

3.2. Emoticon-Based Queries

In order to investigate DS approaches to SSA, we also col-lect a much larger data set of Arabic tweets, where we use emoticons as noisy labels following, e.g. (Read, 2005;

Go et al., 2009; Pak and Paroubek, 2010; Suttles and Ide, 2013). We query Twitter API for tweets with varia-tions of positive and negative emoticons to obtain pairs of micro-blog texts (statuses) and using emoticons as author-generated emotion labels. In following (Purver and Bat-tersby, 2012; Yuan and Purver, 2012; Zhang et al., 2011;

Suttles and Ide, 2013), we also utilise some sentiment-bearing hash-tags to query emotional tweets.

Examples of hash-tags we queried are:

hQ ¯

happinessand

à Qk

sadness. Note that emoticons and hashtags are merely used to collect and build the training set and were replaced by the standard (positive/ negative) labels. In order to col-lect neutral instances, we query a set of official news ac-counts, following (Pak and Paroubek, 2010). Examples of the accounts queried are: BBC-Arabic, Al-Jazeera Arabic, SkyNews Arabia, Reuters Arabic, France24-Arabic, and DW Arabic. Using this method, we collected 55,076 neu-tral instances in total. We then automatically extract the same set of linguistically motivated features as for the gold-standard corpus, see Table 2. After removing re-tweets, duplicates and mixed tweets, the corpus is composed of 120,747 data instances.

Note that this work is the first to investigate distant su-pervision approaches for Arabic, and as such, no previous automatically labelled data sets are available. The gold-standard data set will shortly be available from the ELRA repository.1 We also hope to release the automatically la-belled data to the community in the near future, where we investigate standardised RDF data schema for linked open SSA data, such as MARL (Westerski, 2011).

4. Classification Experiments Using Distant Supervision

In previous work, we experiment with a fully supervised approach on a hand-labelled data set (Refaee and Rieser, 2014). However, our results reveal that these models do not transfer well to new data sets collected at a later point in time due to their limited coverage. An error analysis con-firms that this drop in performance is due to topic-shifts in the Twitter stream. We therefore turn to DS approaches.

In this section we empirically evaluate emoticon-based ap-proach to DS.

4.1. Experimental Setup

For classification, we experiment with two alternative prob-lem formulations: Related work has treated SSA as a

two-1http://catalog.elra.info/

Type Feature-sets

Morphological diacritic, aspect, gender, mood, person, part of speech (POS), state, voice, has morphological analysis.

Syntactic n-grams of words and POS, lemmas, including bag of words (BOW), bag of lemmas.

Semantic has positive lexicon, has negative lexicon, has neutral lexicon, has negator, has positive emoticon, has negative emoticon.

polar vs. neutral 0.69 53.0 0.43 46.62 0.94 94.89 0.95 95.19 0.94 94.28

positive vs. negative 0.67 50.89 0.41 49.65 0.50 50.29 0.51 51.25 0.49 50.0 positive vs. negative vs.

neutral

0.63 46.99 0.28 28.24 0.70 69.67 0.69 68.43 0.67 67.18

Table 3: 2-level and single-level SSA classification using distant supervision (DS).

stage binary classification process, where the first level dis-tinguishes subjective and objective statements, and the sec-ond level then further distinguishes subjectivity into pos-itive and negative sentiment, e.g. (Wiebe et al., 1999;

Abdul-Mageed et al., 2011; Abdul-Mageed et al., 2012).

Alternatively, the classification can be carried out at as single-level classification (positive, negative, neutral), e.g.

(Farra et al., 2010). We experiment with both options. For the first stage of the binary approach, we collapse the posi-tive and negaposi-tive labels into a “polar” label.

We experiment with a number of machine learning methods and we report the results of the best performing scheme, namely Support Vector Machines (SVMs), where we use the implementation provided by the WEKA data mining package version 3.7.9 (Witten and Frank, 2005). We report the results on two metrics: F-score and accuracy. We use paired t-tests to establish significant differences (p < .05).

Different to the previous experiments on the gold-standard data (Refaee and Rieser, 2014), we only experiment with a subset of features, which we previously identified as best performing: Bag-of-Words (BOW) + morphological + se-manticfeatures. Note that, for the DS approach, we exclude the emoticon-based features from thesemanticfeature set.

We compare our results against a majority baseline and against a fully supervised approach, i.e. SVMs trained on a manually labelled gold-standard data set using the same feature set. We evaluate the approaches on a separate held-out test set, as described in Section 3.1.

4.2. Emoticon-Based Distant Supervision

In this section, we evaluate the potentials of exploiting training data that is automatically labelled using (noisy) emoticons, see Section 3.2. The results are summarised in Table 3.

Polar vs. Neutral: The results show a significant im-provement over the majority baseline, as well as over the classifier trained on the gold-standard data set: We achieve a 95.19% accuracy on the held-out set with BOW and morphological features, which is a 48.57% absolute improvement over our previous fully supervised results.

These results indicate that the classifier is able to recog-nise and distinguish the language used to express

neu-tral/objective utterances from those used to convey personal opinion/attitude. Feature selection, while showing some improvement when adding morphological features, does not have a significant effect on performance.

Positive vs. negative: For sentiment classification, the performance of emoticon-based approach degrades notably to 0.50 F-score (for BOW only), which is significantly bet-ter that the fully supervised baseline, but still significantly worse than a simple majority baseline. One possible expla-nation for this is that the classifier is faced with the natu-rally harder discrimination task between positive and nega-tive instances. The confusion matrix shows that it’s mostly negative instances are misclassified as positive. In Section 4.2.1. we will investigate possible reasons in a detailed error analysis. Again, adding features has no significant effect on performance.

Positive vs. Negative vs. Neutral: When performing three-way SSA on a single level, the SVM outperforms the majority baseline and achieves 0.70 F-score. Again, BOW achieves the highest results. The confusion matrix reveals that detecting the negative class is most problem-atic, with the lowest recorded precision at 0.55, while the neutral class achieved significantly better precision at 0.96.

In this case, adding the semantic features significantly de-creases the performance. We hypothesise that this might be the features based on the subjectivity lexicon, which so far only covers MSA. We will address this short-coming in future work.

Feature Selection: In general, our feature selection ex-periments show no significant impact on performance.

However, adding morphological features show a positive trend for improving both, subjectivity and sentiment anal-ysis. This confirms previous results by Abdul-Mageed et al. (2012) for SSA on Arabic tweets using fully super-vised learning. Go et al. (2009), in contrast, reports that adding morphological features hurts performance when us-ing emoticon-based DS for SSA on English Twitter feeds.

We therefore hypothesise that morphological features are especially useful for Arabic, being morphologically rich language.

Emoticon

Table 4: Results of labelling sarcasm, mixed emotions and unclear sentiment for misclassified instances.

4.2.1. Error Analysis for Emoticon-Based DS

The above results seem to indicate that DS works well for subjectivity analysis (distinguishing neutral vs. polar in-stances), but proves to be difficult for sentiment analysis (distinguishing positive vs. negative instances). Especially, detecting negative instances seems to be problematic. We conduct an error analysis in order to further investigate the underlying cause. In particular, we investigate the use of sarcasm and the direction of facing of emoticons in right-to-left alphabets.

Use of sarcasm and irony: Using emoticons as labels is naturally noisy, since we cannot know for sure the intended meaning the author wishes to express. This is especially problematic when emoticons are used in a sarcastic way, i.e. their intended meaning is the opposite of the expressed emotion. An example from our data set is:

): ú