<!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>UFPelRules to irony detection in Spanish variants</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Diulia Justin Deon</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Larissa Astrogildo de Freitas</string-name>
          <email>larissa@inf.ufpel.edu.br</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>UFPel</institution>
          ,
          <addr-line>Gomes Carneiro 1, Porto, 96010-610, Rio Grande do Sul, Pelotas</addr-line>
          ,
          <country country="BR">Brazil</country>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2019</year>
      </pub-date>
      <fpage>310</fpage>
      <lpage>314</lpage>
      <abstract>
        <p>Figurative language is one of the most di cult challenge to Natural Language Processing. In this study, we propose a strategy to irony detection in Spanish based in linguistic patterns. After studying the state of the art, we implement seven linguistic patterns in 9000 texts written in three di erent linguistic variants. Copyright c 2019 for this paper by its authors. Use permitted under Creative Commons License Attribution 4.0 International (CC BY 4.0). IberLEF 2019, 24 September 2019, Bilbao, Spain.</p>
      </abstract>
      <kwd-group>
        <kwd>Irony detection</kwd>
        <kwd>Spanish variants</kwd>
        <kwd>Patterns</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>Introduction</title>
      <p>
        Usually, irony is known as a way of communicating the opposite of the literal
meaning [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. Commonly known as, irony is a gure of speech that seeks to express
a word or text with distinct meaning from the original.
      </p>
      <p>The detection of ironic declarations represent a major challenge to Natural
Language Processing. In this study, we analyzed and implemented some linguistic
patterns that may be associated with ironic declarations in Spanish language
varieties.</p>
      <p>
        Irony can be seen as a complex communication mechanism that is governed
by pragmatic principles. Observing the uses of the term, it is observed that irony
is often mistaken for sarcasm, satire or parody. In this study, we based the task
of irony detection in a general concept for this phenomenon, since there are no
consensuses on a rigid de nition of irony. [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ] and [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] de ne irony as an apparent
violation of pragmatic principles in an utterance. [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ], on the other side, de ne
irony as a contradictory property in a given context or event. [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ] states that the
presence of irony conveys a pragmatic meaning when alluding to expectations
(failures or not).
      </p>
      <p>
        The elaboration of patterns involving possible evidence of ironic declarations
considers the following elements: syntactic rules, static expressions, lists of
laughter expressions, speci c scores, and symbolic language. The implementation of
the proposed patterns is based on the work of [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ], and [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ].
      </p>
      <p>Six linguistic patterns classi ed into three groups were implemented: (C1)
lists; (C2) exact expressions; and (C3) symbols (Table 1). Finally, we applied
these patterns in 9000 texts and analysed the results.
2</p>
    </sec>
    <sec id="sec-2">
      <title>Related Works</title>
      <p>The detection of irony has been increasingly worked and explored by the scienti c
community.</p>
      <p>
        The use of linguistic patterns to detect irony has already been used by other
researchers, such as [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] and [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ].
      </p>
      <p>
        [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] proposed 13 linguistic patterns to detect irony in a corpus of tweets in
Brazilian Portuguese about End of the World.
      </p>
      <p>
        [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ] proposed an investigation from a corpus of comments. In this study, the
authors concluded that the most productive patterns for the detection of irony
are related to the use of punctuation marks, emoticons and quotes.
3
      </p>
    </sec>
    <sec id="sec-3">
      <title>Linguistic Patterns</title>
      <p>
        List of patterns were built in the three varieties of the Spanish language that
are present in the corpus: Mexican, Spanish and Cuban [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ], [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]. In this study six
linguistic patterns were implemented for all varieties. They are:
      </p>
      <p>P1- List of Laughter Expression: Social network's users, like twitters,
usually use expressions like \jajaja" and \hehehe" to express that they are
kidding or to reverse the utterance's meaning. For example, \Jajajajajajajajaja
tendencioso, a mi primero que me explique la falta de capacidad de sus
candidatos y luego hablamos de con icto de intereses.".</p>
      <p>P2 - \No te creas", \No es cierto", \Es broma": In Brazilian
Portuguese, people use the expression \So que na~o" to add a negative meaning to
all that said before. In Spanish, we found three equivalent expressions: \No te
creas", \Es broma" and \No es cierto". For example,\Pues no te creas que es
tan jovencita.".</p>
      <p>P3 - ...&lt;EXPR&gt;! : Expressions accompanied by an exclamation point after
an ellipsis are considered ironies, because the punctuation (...) indicates that the
phrase is over. However, when such a pattern is used, it would be interpreted
as an attempt by the author to add something, nish his sentence, which is
supposed to be an irony. For example, \Ojala Carmen Calvo saliendo a decir
`Pero no os habeis dado cuenta? Todo este tiempo... el relator... eras tu!' y se va
volando agarrada a un paraguas.".</p>
      <p>P4 - Uppercase: To give greater intonation and prominence to the texts,
users choose to use words with uppercase formatting in text points, or all of it,
indicating that his speech would change, producing the feeling that this is an
irony. For example: \LA TV DIGITAL ESTA SIENDO MUY EFICIENTE.".</p>
      <p>P5 - * j * j !* j ?* j ** j ** j !*?* j ?*!* : People end up not using more
nal scores in sentences, and in the case of Twitter, they use even less because
the network counts and only allows tweets with a certain number of characters.
Analyzing this, it is noted that the score is no longer used in the application in
question. Thus, when it is present in some phrase in a large number followed,
called repetition, it brings indicators that the phrase contains irony. For example:
\entonces la tv cubana PAGA los derechos? !VIVA EL pqt!!!!!!!!!!!!!!!!!!!!!!".</p>
      <p>P6 - Quotations Marks: Quotes are used to give prominence, show that
it would be something similar or derived from, causing the reader a sense of
insecurity referring to what is being read, and thus indicating, that it may be
an irony, a phrase using gured sense. For example: \Entendi `perfectamente' ,
ms claro no pudieron ser. Que cosa es servicio de mensajeria ??".
4</p>
    </sec>
    <sec id="sec-4">
      <title>Training set</title>
      <p>In this work, we used the training set, available in IroSvA. This database contains
7200 texts with the following annotation: identi cation code (ID), topic (text
subject), classi cation of ironic or non-ironic.</p>
      <p>UFPelRules classi ed 964 Cuba texts, 864 Mexico texts and 749 Spain texts
as ironic (Table 2a, 2b and 2c) on the training set.</p>
      <p>There were 2400 texts for each spanish variation, of these 800 were ironic.
UFPelRules was able to identify 964 text with irony in the Cuban variety (Table
2a), 1463 in the Mexican variety (Table 2b) and 743 in the Spanish variety
(Table 2c). Comparing the results of UFPelRules and the training set, the tool
identi ed and marked more texts as ironic in Table 2a and 2b, and less in Table
2c, in relation to those prede ned by the training set.</p>
      <p>These results demonstrate that the tool can detect patterns, with half of the
marked texts being identi ed as originally ironic. It was also observed that the
P4 pattern was the one that most identi ed irony, achieving expressive numbers
in the three variations, standing out among the six linguistic patterns. This
proves that in most cases, Spanish speakers use this language feature to express
irony.
After the analysis with the training set, we applied the patterns in test set.
This database contains: code identi er (ID) and the message to be analyzed.
This time, the texts were not annotated for ironic or non-ironic. The results are
shown in the Table 3.</p>
      <p>The P4 repeated the result of the training set, and identi ed irony with a
great prominence in relation to the others, being able to identify a large group
of texts in the three variations. Second with the best result was the P6 and the
third was the P5.</p>
      <p>Although P3 does not present a signi cant result, we still believe that
given the intuition of language users that it would be possible to nd better
results in other.</p>
      <p>
        Table 3 presents the nal average obtained in the analyzes of the test set, as
well as the average of other resources used by the authors of Irony Corpus [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ],[
        <xref ref-type="bibr" rid="ref2">2</xref>
        ].
      </p>
    </sec>
    <sec id="sec-5">
      <title>Final remarks</title>
      <p>During this work, it was noted that irony is expressed in complex ways, and
in similar ways even with di erent languages. Although intelligent methods are
used for this analysis, irony is shown as a major challenge.</p>
      <p>Interpreting, understanding and detecting social networks requires
multianalysis on linguistic concepts and understanding of how people use virtual
communication. It is concluded that the linguistic patterns established by the
study o er satisfactory results, in addition to allowing the detection in more
than one language, demonstrating a high similarity between the structures of
di erent languages.</p>
      <p>Based on observing language behavior in other corpora, it is possible that
new patterns can be added to the UFPelRules, as well as some existing ones can
be excluded if they provide irrelevant results.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1. Antonio Reyes, Paolo Rosso,
          <string-name>
            <surname>D.B.</surname>
          </string-name>
          :
          <article-title>From humor recognition to irony detection: The gurative language of social media</article-title>
          .
          <source>Data Knowledge Engineering</source>
          <volume>74</volume>
          ,
          <issue>1</issue>
          {
          <fpage>12</fpage>
          (Apr
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2. Francisco Rangel, Paolo Rosso,
          <string-name>
            <surname>M.F.S.:</surname>
          </string-name>
          <article-title>A low dimensionality representation for language variety identi cation</article-title>
          .
          <source>In: 17th International Conference on Intelligent Text Processing and Computational Linguistics</source>
          ,
          <source>CICLing'16</source>
          . Springer-Verlag,
          <source>LNCS(9624)</source>
          , pp.
          <fpage>156</fpage>
          -
          <lpage>169</lpage>
          (
          <year>2018</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <surname>Larissa A. de Freitas</surname>
          </string-name>
          ,
          <article-title>Aline A</article-title>
          .
          <string-name>
            <surname>Vanin</surname>
            ,
            <given-names>D.N.H.M.N.B.R.V.</given-names>
          </string-name>
          :
          <article-title>Pathways for irony detection in tweets</article-title>
          .
          <source>In: Proceedings of the 29th Annual ACM Symposium on Applied Computing</source>
          . pp.
          <volume>628</volume>
          {
          <fpage>633</fpage>
          . SAC '14,
          <string-name>
            <surname>ACM</surname>
          </string-name>
          , New York, NY, USA (
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <surname>Grice</surname>
            ,
            <given-names>H.P.</given-names>
          </string-name>
          :
          <article-title>Logic and conversation</article-title>
          . Academic Press (
          <year>1975</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <surname>Ortega-Bueno</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Rangel</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          , Hernandez Far as,
          <string-name>
            <given-names>D.I.</given-names>
            ,
            <surname>Rosso</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            ,
            <surname>Montes-</surname>
          </string-name>
          y-Gomez,
          <string-name>
            <surname>M.</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Medina</given-names>
            <surname>Pagola</surname>
          </string-name>
          ,
          <string-name>
            <surname>J.E.</surname>
          </string-name>
          :
          <article-title>Overview of the Task on Irony Detection in Spanish Variants</article-title>
          .
          <source>In: Proceedings of the Iberian Languages Evaluation Forum (IberLEF</source>
          <year>2019</year>
          ),
          <article-title>co-located with 34th Conference of the Spanish Society for Natural Language Processing (SEPLN</article-title>
          <year>2019</year>
          ).
          <article-title>CEUR-WS.org (</article-title>
          <year>2019</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <given-names>Paula</given-names>
            <surname>Carvalho</surname>
          </string-name>
          , Lu s Sarmento,
          <string-name>
            <surname>M.J.S.E.d.O.</surname>
          </string-name>
          :
          <article-title>Clues for detecting irony in usergenerated contents: Oh.</article-title>
          ..!
          <article-title>! it's "so easy" ;-)</article-title>
          .
          <source>In: Proceedings of the 1st International CIKM Workshop on Topic-sentiment Analysis for Mass Opinion</source>
          . pp.
          <volume>53</volume>
          {
          <fpage>56</fpage>
          . TSA '09,
          <string-name>
            <surname>ACM</surname>
          </string-name>
          , New York, NY, USA (
          <year>2009</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <given-names>R. J.</given-names>
            <surname>Kreuz</surname>
          </string-name>
          ,
          <string-name>
            <surname>S.G.</surname>
          </string-name>
          :
          <article-title>How to be sarcastic: The choice reminder theory of verbal irony</article-title>
          .
          <source>Journal of Experimental Psychology: General</source>
          <volume>118</volume>
          ,
          <issue>374</issue>
          {
          <fpage>386</fpage>
          (
          <year>1989</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <string-name>
            <surname>Searle</surname>
            ,
            <given-names>J.R.</given-names>
          </string-name>
          :
          <source>Speech Acts: An Essay in the Philosophy of Language</source>
          . Cambridge University Press (
          <year>1969</year>
          )
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>