i REL at S em E val-2023 Task 10: Multi-level Training for Explainable Detection of Online Sexism (2023)

Abstract: This paper describes our approach for SemEval-2023 Task 10: Explainable Detection of Online Sexism (EDOS). The task deals with identification and categorization of sexist content into fine-grained categories for explainability in sexism classification. The explainable categorization is proposed through a set of three hierarchical tasks that constitute a taxonomy of sexist content, each task being more granular than the former for categorization of the content. Our team (iREL) participated in all three hierarchical subtasks. Considering the inter-connected task structure, we study multilevel training to study the transfer learning from coarser to finer tasks. Our experiments based on pretrained transformer architectures also make use of additional strategies such as domain-adaptive pretraining to adapt our models to the nature of the content dealt with, and use of the focal loss objective for handling class imbalances. Our best-performing systems on the three tasks achieve macro-F1 scores of 85.93, 69.96 and 54.62 on their respective validation sets.

## introduction the proliferation of online sexism targeted towards women not only makes online spaces inhospitable but also perpetuates existing social inequities. this has lead to the use of online systems for the identification of such content through automated technologies based on nlp methods. however, a blatant categorization into general, high-level categories as is often performed by such technologies leads to lack of explainability and trust in these systems. the nature of sexist content being varied based on the motivation of the writer, a discrete identification of categories as different as threats and prejudiced expressions is beneficial for differential treatment. a granular study also helps in identifying the weaknesses of the model in identifying certain specific categories of sexist content. in our work, we work on the dataset for explainable detection of online sexism (introduced as a part of the semeval-2023 task 10) @xcite based on english language posts from the social media platforms reddit 1 and gab 2 . the dataset, discussed in a greater detail in section 3, introduces three inter-connected subtasks (labeled a, b, c) for the problem, each dealing with classification of sexist comments in a more fine-grained sense. task a consists of a simple binary classification of posts into sexist and non-sexist categories. for posts which are detected as sexist, task b deals with their categorization into 4 distinct categories of sexism. finally, in task c looks at a more granular classification of the sexist posts into 11 classes, or "fine-grained vectors of sexism". we worked on all the three subtasks, and report our experimental findings on the same. to benefit from the inter-connected, hierarchical nature of the three subtasks forming a taxonomy of sexist content labeling, we primarily study the technique of multi-level training in this paper. this technique, explained in section 4.4, serves to transfer learn on a task at the lower level from the learnings on a higher level task. we experiment with five different pretrained transformer @xcite architectures for our approaches. besides cross-entropy based vanilla finetuning (section 4.1), we employ domain-adaptive pretraining (refer to section 4.3) @xcite as a precursor to multi-level training for adaptation of the models to the nature of the data in this domain. considering the class imbalances in tasks b and c, we also make use of the focal loss @xcite objective, elaborated in section 4.2. we specify the experimental settings for these methods in section task c as the best performing approaches for the tasks. the best results (on the basis of macro-f1) were obtained on the pretrained roberta-large @xcite model, the results for which we show on the validation split of the provided data. we open source our code for replicability of our methods foot_2 . these prior works lack the study from a taxonomical perspective for categories on online sexist 3 data in addition to the primary labeled dataset for the task, the organizers also provided two additional unlabeled datasets, each containing 2m comments from reddit and gab. the primary dataset consists of 14k / 2k / 4k labeled instances each in the train / dev / test splits. of the 14k instances in the train split, ∼3.4k comments are labeled under the "sexist" category for task a, hence limiting the amount of usable data for tasks b and c to this subset, which are further categorized into 4 and 11 classes respectively. although the classes for task a do not have a significant imbalance (3:1 distribution for "non-sexist" versus "sexist"), the classes for tasks b and c have a significant imbalances. we make use of the labeled dataset as well as the unlabeled reddit and gab datasets for our experiments. no other additional data was made use of. as a part of data exploration, we measured the average lengths of the comments in each dataset on the basis of white space-separated tokens. average length of comments in the given labeled dataset is 23.42 tokens, slightly above that for gab (16.17 tokens) and reddit (17.89 tokens) unlabeled datasets. we also noticed that the length distributions of the comments from all the three data sources to conform when plotted on a graph. this observation was useful in merging the datasets for applying domain-adaptive pretraining, discussed in section 4.3. ## methodology in this section, we describe the core components of our modeling we experimented with to tackle the three subtasks. we start with basic finetuning in section 4.1, explain the focal loss objective in section 4.2, domain-adaptive pretraining in section 4.3, and multi-level training in section 4.4. ## results the experimental results for our approaches for task a, b and c can be seen in in task a, we observed that all the models, except db, performed better after the domain-adaptive pretraining step. among all the experiments, rl with pretraining gave the best f1 score of 85.93. in task b, we explored the usage of focal loss in basic finetuning, which showed improved performance in the best performing model, rl. however, we observed that the improvement from focal loss to not be consistent when compared to cross entropy. pretraining followed by fine-tuning with focal loss showed improvement only for bbu. multilevel training with pretraining gave the best model, which again was rl with a macro-f1 score of 69.96. interestingly, bbu showed the highest performance improvement with continued pretraining and multilevel training where the score increased by 5.42 points from the second-best performing setup. in task c, we observed that the performance improvement from focal loss was more pronounced due to the high class imbalance of 11 categories. in basic finetuning, changing the objective from cross entropy to focal loss improved the performance of each model by at least 3 points in the macro-f1 score. the best performing model in basic finetuning was rl, which showed an improvement of more than 4.27 points in macro-f1. the model that saw the highest improvement was dbv3 with a difference of 6.25 points in macro-f1. we also noted that continued pretraining gave improved performance for all models except rl. multi-level training with task a -> task b -> finetuning with focal loss gave the best performance for bbu and rb. however, overall the best performing model remained rl in the basic finetuning with focal loss setup, giving a macro-f1 score of 54.62. ## conclusion in our work, we present a study of our approaches to tackle the problem of explainable detection of online sexism as a set of 3 inter-connected, hierar