<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Arabic Tweeps Traits Prediction AT2P</article-title>
      </title-group>
      <contrib-group>
        <aff id="aff0">
          <label>0</label>
          <institution>Higher Institute for Applied Sciences and Technology</institution>
          ,
          <addr-line>Damascus</addr-line>
          ,
          <country country="SY">Syria</country>
        </aff>
      </contrib-group>
      <fpage>0000</fpage>
      <lpage>0002</lpage>
      <abstract>
        <p>Author profiling is the process of extracting author traits, which constitute the profile of an author, by analyzing his/her writings. Detecting these traits is useful and important process in the domain of social media analysis. In this notebook, we present our approach for author profiling task that is one of the tasks required in “Author Profiling and Deception Detection in Arabic (APDA)” workshop 2019. The focus of this task is to identify the age, gender, and language variety of Arabic Twitter users (tweeps). For this purpose, several feature vectors and classifiers were evaluated to find out the best prediction models for the three traits. SMO classifier with the feature vector that consisted of UniGram and Stem was the best model for each three traits: gender, age and variety1.</p>
      </abstract>
      <kwd-group>
        <kwd>Author Profiling</kwd>
        <kwd>Variety Prediction</kwd>
        <kwd>Age Prediction</kwd>
        <kwd>Gender Prediction</kwd>
        <kwd>Arabic Social Media Processing</kwd>
        <kwd>Machine Learning</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>
        Author profiling on social media is a method of analyzing the author writings on
social media in order to uncover different traits of the author (e.g. gender, variety and
age) based on stylistic or content-based features. This method aims at taking
advantage of a huge volume of data generated by a huge number of authors, in order to
classify them into predefined classes based on their traits [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ].
      </p>
      <p>Author profiling has gained much importance due to its various applications in
business, social studies and security areas. From a marketing viewpoint, extracting
latent traits of the authors is used for targeting advertisement campaigns, companies
also may be interested in knowing, on the basis of the analysis of online product
reviews, the demographics of people that like or dislike their products. From social
studies viewpoint, having knowledge about the authors that have specific behavior
toward new trends is very important issue, these may be used for classifying social
accounts for future trends.</p>
      <p>
        With the birth and rise of social media [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ], internet users in the Arab world were
quick to embrace the new technology, and utilize all what social media has to offer to
connect, communicate, and share information with others using Arabic language.
      </p>
      <p>
        Arabic language used in social media has two forms: the first, is the Modern
Standard Arabic (MSA), which is widely used in formal situations like formal
speeches, government and official contents; the second, is known as Dialectal Arabic
(DA) which is the informal private language, predominantly found as spoken
vernaculars with no written standards. Dialects differ in morphologies, grammatical
cases, vocabularies and verb conjugations [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. These differences call for dialect-specific
processing and modeling when building Arabic automatic analysis systems [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ].
      </p>
      <p>
        Concerning gender of tweeps, Twitter does not collect users’ self-reported gender
as do other social media sites (e.g., Facebook and Google+) [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ]. Topics and style of
writing vary depending on the author gender (males and females). Males could be
interested in sports, politics and economy, whereas females could be interested in
fashion and celebrity news. In Arabic language, words suffixes and prefixes differ
between males and females, for example: “نيكراشت” “t$Arkyn” word for second person
female vs. “كراشت ” “t$Ark” word for second person male. Moreover, females tend
more to use emojis, whereas males may tend to write textual tweets. These differences
could be used as indicators when developing a gender prediction model for Arab
tweeps.
      </p>
      <p>According to age of the tweeps, the writing style and type vary between young and
old tweeps. Old tweeps may write long and formal tweets more than young ones.
Young tweeps may write more about sport, studying issues and fashion, whereas old
tweeps may tweet politic and social topics. These assumptions could be used as
indicators to distinguish between various age groups.</p>
      <p>
        In this paper, we summarize our participation in “Author Profiling and Deception
Detection in Arabic (APDA)” workshop 2019 [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ], in the “author profiling in Arabic
tweets” task. We represent our methodology for developing the prediction models for
the traits under study in the workshop: age, gender and variety (dialect) of the Arabic
authors.
      </p>
      <p>In the rest of this paper, we present in section 2 our methodology that includes: the
characteristics of training and testing data, the features used for the developed models,
and a step-by-step approach to build the prediction model. In section 3, a brief
discussion of the results is addressed. At the end, a short summary and insights for the
future are presented.
2</p>
    </sec>
    <sec id="sec-2">
      <title>Methodology</title>
      <p>In this section, we describe the dataset used in this work, and the features tested for
the prediction models. The proposed models are explained in detail hereafter,
including: data pre-processing, features extraction, features filtering and the algorithms with
their evaluation criteria.</p>
      <sec id="sec-2-1">
        <title>Dataset</title>
        <p>APDA workshop provided the participants in author profiling task with training and
testing data from Twitter. Training data consists of 225000 tweets written in Arabic
language by 2250 authors equally (100 tweets per each author). Authors were tagged
with three traits: variety, age and gender. Variety trait was categorized into fifteen
classes: Algeria, Egypt, Iraq, Kuwait, Lebanon-Syria, Libya, Morocco, Oman,
Palestine-Jordan, Qatar, Saudi Arabia, Sudan, Tunisia, UAE and Yemen. Age trait was
categorized into three age groups: under 25, Between 25 and 34, and Above 35.
Gender trait was categorized into two classes: male and female. Authors were divided
according to these three traits equally into: 150 authors per each variety, 750 authors
per each age group and 1125 authors per each gender.</p>
        <p>Testing data was also provided by APDA workshop. It consists of 72000 Arabic
tweets, divided into 720 authors equally. Testing data was not tagged corpus, it was
blinded. The evaluation process and the accuracy calculation using testing data were
achieved by the workshop organizers.
2.2</p>
      </sec>
      <sec id="sec-2-2">
        <title>Studied Features</title>
        <p>In our attempt to reach to the best prediction models for age, variety and gender traits,
we tried a number of features for each model; some features contributed in improving
the accuracy, while others did not. We categorized these features into:
 Content-based features:
o Uni-gram, bi-gram and tri-gram of words.
o Stems of words.
o Lemmas of words.
o Words Part Of Speech tags (POS), i.e. NOUN_MS_PRON and</p>
        <p>V_PRON.</p>
        <p>o Character n-gram, where n ranges from 2 to 7.
 Style-based features:
o Links to websites (“http”).
o Hashtags to active public trends (“#”).
o Mentions to other authors (“@”).
o Lengthened words, i.e. the intentional repetition of a character in a word
to emphasize and to exaggerate in describing something like laughing
“ههههههههه”, magnification “واااااااااااااااااو”, indignation “ااااااااالا ”, etc.
o Average tweets length, i.e. the average number of words in an author
tweets.
o Tweets punctuation marks, i.e. the summation of punctuation marks
used in an author tweets.</p>
      </sec>
      <sec id="sec-2-3">
        <title>Our Model</title>
        <p>In our attempt to find out the best prediction models, we prepared the dataset and
extracted the features. These features have been filtered to reduce the size of feature
vectors. Depending on reduced feature vectors, we implemented several experiments
that differed from each other in feature vector and the algorithm used for training. The
resulting models were compared using specific evaluation criteria to select the best
one.</p>
        <p>
          Data Pre-processing. Before starting feature extraction stage, we concatenated all the
100 tweets for each author into one long text. This long text was tokenized using
Farasa tokenizer [
          <xref ref-type="bibr" rid="ref7">7</xref>
          ]. All extracted tokens have been grouped and weighted with their
frequency in the dataset (all the tokens from all authors).
        </p>
        <p>Features Extraction. After the tokenization stage, lemmas and stems were extracted
from the calculated tokens using Farasa toolbox. Tokens were used also to extract
character 2-7 grams.</p>
        <p>In all content-based features, the calculated value for each feature was the
frequency of use in the dataset. This step produced a huge size of feature vector that should
be reduced.</p>
        <p>Style-based features were also calculated and extracted for each author. We
considered a word is lengthened if it included a character repeated three times at least.</p>
        <p>In case of all style-based features -except the average tweets length-, the values
that are considered in each feature vector were the frequency of use. In case of
average tweets length, the considered value in each author feature vector was the average
number of words in a tweet.</p>
        <p>
          Features Filtering. The number of elements of each content-based feature vector was
very huge, which made the training process very hard and time-consuming. We
applied the following steps to reduce the feature vector size:
 Eliminating features with a value less than two (we have two classes at
least). The probability that these items contribute in the classification is low.
 Discarding all elements with Information Gain (IG) equals to zero.
Model Training. In our experiments, we trained different models using Weka
toolbox [
          <xref ref-type="bibr" rid="ref8">8</xref>
          ]. The features mentioned previously have been used separately or jointly to
create various feature vectors to be evaluated in several experiments.
        </p>
        <p>
          According to the classifiers, we used Sequential Minimal Optimization (SMO)
classifier for each trait. Depending on previous experiments, SMO already gave us
good results relatively [
          <xref ref-type="bibr" rid="ref9">9</xref>
          ].
        </p>
        <p>Evaluation of Models. For the models evaluation, we used training data to find out
the best models by calculating the accuracy over 10-folds cross-validation (AccTrain).</p>
        <p>Concerning the testing data, it was blinded (hidden tags), so the testing accuracy
(AccTest) for the models are calculated and declared later by APDA organizers.
3</p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>Experiments and Results</title>
      <p>In this section, we represent the best six experiments according to AccTrain for each
trait. The used features in these experiments are abbreviated here as: UniGram for
word uni-gram, Stem for stems, CNGram for character n-gram and Ratios for the six
style-based features that previously mentioned. In the following three charts, we
ranked the prediction experiments per each trait descending from left to right
according to AccTrain values.
3.1</p>
      <sec id="sec-3-1">
        <title>Gender</title>
      </sec>
      <sec id="sec-3-2">
        <title>Variety</title>
        <p>Generally, UniGram as content-based features gave good results in predicting the
three traits comparing with Stems and character n-gram. From the results above, the
problem of detecting age of author is consider hard problem relatively, the best
AccTrain for age prediction is (83.24%) comparing to (98%) for gender prediction and
(92.17%) for variety prediction. This fact ensures that authors of various ages (young
and old) may use the same behavior on social media, making the predicting task
harder.</p>
        <p>Also, variety prediction considering fifteen classes is harder than gender prediction
which considers just two classes; this is axiomatic fact in prediction problems. So, we
notice that the highest AccTrain for gender prediction (98%) is more than (92.17%)
for variety prediction.
3.5</p>
      </sec>
      <sec id="sec-3-3">
        <title>APDA Runs</title>
        <p>APDA organizers allow the participants to submit three runs to be compared to other
participants. We select the best three experiments per each trait according to AccTrain
to constitute the three runs: Run1, Run2 and Run3. In Table 1, we represent the three
runs with the AccTrain and AccTest for each run.
Gender</p>
        <p>Age
Dialect</p>
        <p>AccTrain
AccTest
AccTrain
AccTest
AccTrain</p>
        <p>AccTest
Joint AccTest</p>
        <p>Run1</p>
        <p>According to AccTest which calculated by APDA organizers for each trait, Run1
was the best one in case of gender and age traits, Run2 was the best in case of variety.
The feature vector that consists of UniGram and Stem is the best one according to
AccTest for all traits. We can notice that AccTest for age is considered low relatively
in comparing with gender and variety (53.75% in best case), this ensures the fact that
age prediction is harder than gender and variety prediction as we already discussed.</p>
        <p>In the last line of Table 1, joint AccTest means the accuracy that is calculated when
the three developed models correctly predict the three traits for each author. Best joint
AccTest is calculated in Run1 (36.39%), this means the three traits of (36.39%) of
testing data are correctly predicted by the three models.
4</p>
      </sec>
    </sec>
    <sec id="sec-4">
      <title>Conclusion</title>
      <p>In this notebook, we summarized our participation in APDA workshop in task of
“author profiling in Arabic tweets”. For this purpose, we tried several features and
classifiers to find out the best prediction models. Depending on testing data, SMO
classifier with the feature vector that consisted of UniGram and Stem was the best
model for each three traits: gender, age and variety.</p>
      <p>Our accomplished ranks were 12th, 21st and 20th for gender, age and variety
respectively in comparison with 28 participants. Our rank was 16th in case of joint
prediction.</p>
      <p>It will be worth investigating more features that could improve the prediction
accuracy, especially in case of age prediction, such as: type of written topics, special
words and emojis, type of shared links, etc. Using deep learning algorithms may be
useful for Arabic author profiling problem in case of availability a huge dataset
written by Arabic authors.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1. Mart Busger op Vollenbroek, Talvany Carlotto, Tim Kreutz, Maria Medvedeva, Chris Pool, Johannes Bjerva, Hessel Haagsma, and Malvina Nissim.
          <article-title>GronUP: Groningen User Profiling</article-title>
          .
          <source>Notebook for PAN at CLEF 2016</source>
          . University of Groningen, Groningen, The
          <string-name>
            <surname>Netherlands</surname>
          </string-name>
          (
          <year>2016</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2. TNS.
          <source>Arab Social Media Report. First Report</source>
          (
          <year>2015</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <given-names>Mohammed</given-names>
            <surname>Abdulmalik</surname>
          </string-name>
          <article-title>Ali</article-title>
          .
          <article-title>Artificial intelligence and natural language processing: the Arabic corpora in online translation software</article-title>
          .
          <source>International Journal of Advanced and Applied Sciences</source>
          (
          <year>2016</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <given-names>Fei</given-names>
            <surname>Huang</surname>
          </string-name>
          .
          <article-title>Improved Arabic Dialect Classification with Social Media Data</article-title>
          .
          <source>Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing</source>
          (
          <year>2015</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <given-names>Thomas</given-names>
            <surname>Oshiobughie</surname>
          </string-name>
          <article-title>Ugheoke. Detecting the Gender of a Tweet Sender. A Project Report Submitted to the Department of Computer Science In Partial Fulfilment of the Requirements For the Degree of Master of Science In Computer Science</article-title>
          , University of Regina, (
          <year>2014</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <surname>Rangel</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Rosso</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Charfi</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Zaghouani</surname>
            ,
            <given-names>W.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Ghanem</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Snchez-Junquera</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          :
          <article-title>Overview of the track on author profiling and deception detection in arabic</article-title>
          . In: Mehta P.,
          <string-name>
            <surname>Rosso</surname>
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Majumder</surname>
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Mitra</surname>
            <given-names>M</given-names>
          </string-name>
          . (Eds.)
          <article-title>Working Notes of the Forum for Information Retrieval Evaluation (FIRE 2019)</article-title>
          . CEUR Workshop Proceedings. In: CEUR-WS.org, Kolkata, India, December
          <volume>12</volume>
          -
          <fpage>15</fpage>
          (
          <year>2019</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <given-names>Ahmed</given-names>
            <surname>Abdelali</surname>
          </string-name>
          , Kareem Darwish, Nadir Durrani, and
          <string-name>
            <given-names>Hamdy</given-names>
            <surname>Mubarak</surname>
          </string-name>
          .
          <article-title>Farasa: A Fast and Furious Segmenter for Arabic</article-title>
          . Qatar Computing Research Institute, Hamad Bin Khalifa University, Doha, Qatar.
          <source>Proceedings of NAACL-HLT 2016 (Demonstrations)</source>
          , pages
          <fpage>11</fpage>
          -
          <lpage>16</lpage>
          , San Diego, California, June 12-17,
          <year>2016</year>
          .
          <article-title>Association for Computational Linguistics (</article-title>
          <year>2016</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <article-title>Weka official website: www.cs.waikato.ac</article-title>
          .nz/ml/weka
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <given-names>Khaled</given-names>
            <surname>Alrifai</surname>
          </string-name>
          , Ghaida Rebdawi, and
          <string-name>
            <given-names>Nada</given-names>
            <surname>Ghneim</surname>
          </string-name>
          . Arabic Tweeps Gender and
          <string-name>
            <given-names>Dialect</given-names>
            <surname>Prediction</surname>
          </string-name>
          .
          <article-title>Notebook for PAN at CLEF (</article-title>
          <year>2017</year>
          ).
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>