Hostname: page-component-89b8bd64d-7zcd7 Total loading time: 0 Render date: 2026-05-06T20:07:34.827Z Has data issue: false hasContentIssue false

Context-aware and expert data resources for Brazilian Portuguese hate speech detection

Published online by Cambridge University Press:  06 September 2024

Francielle Vargas*
Affiliation:
Institute of Mathematical and Computer Sciences, University of São Paulo, São Carlos, Brazil Computer Science Department, Federal University of Minas Gerais, Belo Horizonte, Brazil
Isabelle Carvalho
Affiliation:
Institute of Mathematical and Computer Sciences, University of São Paulo, São Carlos, Brazil
Thiago A. S. Pardo
Affiliation:
Institute of Mathematical and Computer Sciences, University of São Paulo, São Carlos, Brazil
Fabrício Benevenuto
Affiliation:
Computer Science Department, Federal University of Minas Gerais, Belo Horizonte, Brazil
*
Corresponding author: Francielle Vargas; Email: francielleavargas@usp.br
Rights & Permissions [Opens in a new window]

Abstract

This paper provides data resources for low-resource hate speech detection. Specifically, we introduce two different data resources: (i) the HateBR 2.0 corpus, which is composed of 7,000 comments extracted from Brazilian politicians’ accounts on Instagram and manually annotated a binary class (offensive versus non-offensive) and hate speech targets. It consists of an updated version of the HateBR corpus, in which highly similar and one-word comments were replaced; and (ii) the multilingual offensive lexicon (MOL), which consists of 1,000 explicit and implicit terms and expressions annotated with context information. The lexicon also comprises native-speaker translations and its cultural adaptations in English, Spanish, French, German, and Turkish. Both corpus and lexicon were annotated by three different experts and achieved high inter-annotator agreement. Lastly, we implemented baseline experiments on the proposed data resources. Results demonstrate the reliability of data outperforming baseline dataset results in Portuguese, besides presenting promising results for hate speech detection in different languages.

Information

Type
Article
Creative Commons
Creative Common License - CCCreative Common License - BY
This is an Open Access article, distributed under the terms of the Creative Commons Attribution licence (http://creativecommons.org/licenses/by/4.0/), which permits unrestricted re-use, distribution and reproduction, provided the original article is properly cited.
Copyright
© The Author(s), 2024. Published by Cambridge University Press
Figure 0

Table 1. Portuguese data resources

Figure 1

Table 2. Offensive and non-offensive comments extracted from the HateBR 2.0 corpus

Figure 2

Table 3. Criteria for updating the HateBR corpus

Figure 3

Figure 1. Offensive language classification: Each Instagram comment was classified according to a binary class: offensive or non-offensive. We manually balanced the classes and obtained 3,500 offensive comments labeled as (1) and 3,500 non-offensive comments labeled as (0).

Figure 4

Figure 2. Hate speech classification: We identified nine hate speech targets, and we labeled them as follows: antisemitism was annotated as (1), apologist for dictatorship as (2), fatphobia as (3), homophobia as (4), partyism as (5), racism as (6), religious intolerance as (7), sexism as (8), and xenophobia as (9). It should be pointed out that a couple of comments belong to more than a target. For example, the comment comunista, vagabunda e safada (“shameless, communist and slut”) was classified as partyism and sexism; hence it was labeled as (5,8). Offensive comments without hate speech were annotated as (−1).

Figure 5

Table 4. Cohen’s kappa

Figure 6

Table 5. Fleiss’ kappa

Figure 7

Table 6. Explicit and implicit information

Figure 8

Table 7. Terms annotated with hate speech targets

Figure 9

Table 8. Kappa score obtained for the contextual-aware offensive lexicon annotation

Figure 10

Table 9. Binary class

Figure 11

Table 10. Replaced comments

Figure 12

Table 11. Political orientation

Figure 13

Table 12. Contextual information labels

Figure 14

Table 13. Terms and expressions

Figure 15

Table 14. Baseline experiments on the HateBR 2.0 corpus

Figure 16

Table 15. Baseline experiments using the MOL – multilingual offensive lexicon

Figure 17

Figure 3. ROC curves for the MOL and B + M models. We evaluated these models on the OLID corpus of English tweets (left), the HatEval corpus of Spanish tweets (center), and the HateBR 2.0 of Brazilian Portuguese Instagram comments (right).

Figure 18

Figure 4. Confusion matrix for the MOL model. Specifically, we implemented the MOL on the OLID corpus of English tweets (left), the HatEval corpus of Spanish tweets (center), and the HateBR 2.0 corpus of Brazilian Portuguese Instagram comments (right).

Figure 19

Figure 5. Confusion matrix for the B + M model. Specifically, We implemented the B + M on the OLID corpus of English tweets (left), the HatEval corpus of Spanish tweets (center), and the HateBR 2.0 corpus of Brazilian Portuguese Instagram comments (right).

Figure 20

Table 16. Examples of misclassification cases