---
title: "AAA at MAHED Text-based Hate and Hope Speech"
description: "The paper describes a system for the MAHED shared task at ArabicNLP 2025, where Arabic social media… 0.712 precision. 4 references."
authors: ["Ahmed Khalil Elzainy", "Mohamed Amin", "Ahmed Samir", "Hazem Abdelsalam"]
year: 2025
venue: "Proceedings of The Third Arabic Natural Language Processing Conference: Shared Tasks"
source: "https://aclanthology.org/2025.arabicnlp-sharedtasks.83/"
doi: "10.18653/v1/2025.arabicnlp-sharedtasks.83"
licence: "CC BY 4.0 (ACL Anthology)"
licence_url: "https://creativecommons.org/licenses/by/4.0/"
summary_licence: "Elamur Cosmic License"
canonical: "https://research.elamur.ai/free/en/papers/elzainy-2025-aaa-mahed-text-based-hate/"
---
[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/elzainy-2025-aaa-mahed-text-based-hate/)

[home](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2025](https://md.research.elamur.ai/free/en/papers/2025/page/16/) / AAA at MAHED Text-based Hate and Hope Speech Classification: A Systematic Encoder Evaluation for Arabic Hope and Hate Speech Classification

# AAA at MAHED Text-based Hate and Hope Speech Classification: A Systematic Encoder Evaluation for Arabic Hope and Hate Speech Classification

**Authors:** Ahmed Khalil Elzainy, [Mohamed Amin](https://md.research.elamur.ai/free/en/authors/mohamed-amin/), Ahmed Samir and Hazem Abdelsalam · **Year:** 2025 · **Venue:** [Proceedings of The Third Arabic Natural Language Processing Conference: Shared Tasks](https://md.research.elamur.ai/free/en/venues/arabicnlp/) ([ArabicNLP 2025](https://md.research.elamur.ai/free/en/venues/arabicnlp/2025/)) · **Publisher:** [Association for Computational Linguistics](https://md.research.elamur.ai/free/en/publishers/association-for-computational-linguistics/) · **Licence:** [CC BY 4.0 (ACL Anthology)](https://creativecommons.org/licenses/by/4.0/)

**Links:** [Publisher's page](https://aclanthology.org/2025.arabicnlp-sharedtasks.83/) · [PDF](https://aclanthology.org/2025.arabicnlp-sharedtasks.83.pdf) · [DOI 10.18653/v1/2025.arabicnlp-sharedtasks.83](https://doi.org/10.18653/v1/2025.arabicnlp-sharedtasks.83) · [OpenAlex](https://openalex.org/W4416037639)

**Citations:** 0 citations (OpenAlex, 2026-10-14)

## Summary
The paper describes a system for the MAHED shared task at ArabicNLP 2025, where Arabic social media posts are sorted into three classes: hope, hate, or not_applicable. Arabic is hard for this task because of its rich root-and-pattern morphology, diglossia between MSA and regional dialects, and the frequent use of sarcasm and veiled hostility online. The authors did not build an ensemble. They fine-tuned six transformer encoders one at a time, each with a linear classification head and class-weighted cross-entropy, so they could find the strongest single model for resource-constrained deployment. Three of the encoders are Arabic-specific (MARBERT, AraBERT-Twitter, ALCLAM) and three are multilingual (XLM-RoBERTa, LaBSE, BGE-m3). MARBERT, which was pretrained on dialect-rich social media text, came out on top with a test macro-F1 of 0.707 and similar accuracy, precision and recall. An error analysis showed that most remaining mistakes involve implicit hate, dialectal vulgarity and statements that need outside context. The study is a useful baseline for choosing an encoder for Arabic affective classification.

## Key points
- The data consists of Arabic social media posts from the MAHED organisers, split into 6890 training, 1476 validation and 1477 test examples. The labels are hope, hate and not_applicable, and neutral posts make up most of the set.
- Test macro-F1 for each model:
  - MARBERT: 0.707 (accuracy 0.712, precision 0.705, recall 0.710)
  - XLM-RoBERTa: 0.645
  - AraBERT-Twitter: 0.630
  - LaBSE: 0.627
  - BGE-m3: 0.588
  - ALCLAM Base v2: 0.404
- ALCLAM's weak score surprised the authors. One passage of the paper still groups it with the best models, which conflicts with the results table.
- MARBERT was trained with a learning rate of 1×10⁻⁶, batch size 64, 3 epochs with early stopping, warmup ratio 0.1, weight decay 0.01 and a maximum of 170 tokens. Class weighting in the loss was used to handle the imbalance.
- The authors group the main errors into three types:
  - implicit accusation read as hate, for example a post suggesting Messi uses stimulants;
  - dialectal swearing in posts that are otherwise neutral;
  - political remarks that need context to interpret.

## Interesting ideas
- Encoders pretrained on the same register as the target data (dialectal social media text) beat larger, broadly multilingual models, so a domain match can matter more than model scale or language coverage.
- Running every candidate as a single model under one identical protocol, with no ensembling, makes the comparison clean and directly tied to what will be deployed.
- The final model is chosen because its precision, recall and accuracy are close to one another, not because it peaks on a single number.
- The error analysis sorts failures into named categories (implicit meaning, dialect or vulgarity, missing context), which tells you where to work next.
- Class weighting in the loss addresses a dataset dominated by one class without changing the data itself.

## For Mova

How these ideas could serve Mova, our small open language model — its files, stages and tests:

- **I1** (tree): When choosing a backbone for gparse, compare candidates on the actual genre Mova reads, such as fables, school texts and word problems, instead of assuming the largest general model wins.
- **I2** (learn): Evaluate each witness parser or teacher tier separately under a fixed setup before combining them into silver data, so the contribution of each one is known.
- **I3** (learn): Report balanced per-class metrics, for example per dependency relation or per frame role, and prefer components with consistent behaviour, since a skewed one can quietly corrupt later stages.
- **I4** (frames): Tag implicature, irony and speech-act errors in prag with similar labels so that self-induced repair rules can be aimed at specific failure types.
- **I5** (tokens): Weight rare tags or morphological features during tagger training so that the frequent classes do not crowd them out.

*Our summary of the paper, in our own words — not its text. The work belongs to its authors; read it at the links above.*

## Institutions

- [Alexandria University](https://md.research.elamur.ai/free/en/universities/alexandria-university/) — University, Alexandria, Egypt · 42 works · 287 citations

📚 Shelves (4): [🖥️ Computer Science](https://md.research.elamur.ai/free/en/shelves/computer-science/) · 18,614 works · [🤖 Artificial Intelligence](https://md.research.elamur.ai/free/en/shelves/computer-science/artificial-intelligence/) · 17,965 works · [🎭 Arts and Humanities](https://md.research.elamur.ai/free/en/shelves/arts-and-humanities/) · 17,450 works · [🗣️ Language and Linguistics](https://md.research.elamur.ai/free/en/shelves/arts-and-humanities/language-and-linguistics/) · 17,296 works

🧭 Topics (3): [😊 Sentiment & emotion](https://md.research.elamur.ai/free/en/topics/sentiment-emotion/) · 1,035 works · [Semitic languages](https://md.research.elamur.ai/free/en/topics/semitic-languages/) · 3,066 works · [🛡️ Bias, fairness & safety](https://md.research.elamur.ai/free/en/topics/bias-fairness-safety/) · 587 works

## Cite

Cite as: Ahmed Khalil Elzainy, Mohamed Amin, Ahmed Samir and Hazem Abdelsalam. 2025. AAA at MAHED Text-based Hate and Hope Speech Classification: A Systematic Encoder Evaluation for Arabic Hope and Hate Speech Classification. Proceedings of The Third Arabic Natural Language Processing Conference: Shared Tasks.

The paper itself, not this page. BibTeX from the library's record of the work.

```bibtex
@inproceedings{elzainy2025aaa,
  title = {{AAA at MAHED Text-based Hate and Hope Speech Classification: A Systematic Encoder Evaluation for Arabic Hope and Hate Speech Classification}},
  author = {Ahmed Khalil Elzainy, Mohamed Amin, Ahmed Samir and Hazem Abdelsalam},
  booktitle = {Proceedings of The Third Arabic Natural Language Processing Conference: Shared Tasks},
  year = {2025},
  doi = {10.18653/v1/2025.arabicnlp-sharedtasks.83},
  url = {https://doi.org/10.18653/v1/2025.arabicnlp-sharedtasks.83}
}
```

- [← previous A-SEA3L-QA: A Fully Automated Self-Evolving, Adversarial Workflow for Arabic Long-Context Question-Answer Generation](https://md.research.elamur.ai/free/en/papers/wang-2025-sea3l-qa-fully-automated-self/)
- [next → Accusation, Anger, and Defense: Rhetorical Questions in Genesis, Exodus, Numbers, and Judges](https://md.research.elamur.ai/free/en/papers/nabulsi-2025-accusation-anger-defense-rhetorical-questions/)
- [↑ back to papers of 2025](https://md.research.elamur.ai/free/en/papers/2025/page/16/)

## References

4 references, 4 of them with a card of ours. ↗ leads to the work.

1. Muhammad Abdul-Mageed, AbdelRahim Elmadany, and El Moatez Billah Nagoudi. 2021. [ARBERT & MARBERT: Deep bidirectional transformers for Arabic](https://md.research.elamur.ai/free/en/papers/abdul-mageed-2021-arbert-marbert-deep-bidirectional-transformers/). In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 7088–7105, Online. Association for Computational Linguistics. [↗](https://doi.org/10.18653/v1/2021.acl-long.551)
2. Wissam Antoun, Fady Baly, and Hazem Hajj. [Arabert: Transformer-based model for arabic language understanding](https://md.research.elamur.ai/free/en/papers/antoun-2020-arabert-transformer-based-model-arabic/). In LREC 2020 Workshop Language Resources and Evaluation Conference 11–16 May 2020, page 9.
3. Jianlv Chen, Shitao Xiao, Peitian Zhang, Kun Luo, Defu Lian, and Zheng Liu. 2024. [Bge m3-embedding: Multi-lingual, multi-functionality, multi-granularity text embeddings through self-knowledge distillation](https://md.research.elamur.ai/free/en/papers/chen-2024-m3-embedding-multi-linguality/). Preprint, arXiv:2402.03216. [↗](https://arxiv.org/abs/2402.03216)
4. Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettlemoyer, and Veselin Stoyanov. 2019. [Unsupervised cross-lingual representation learning at scale](https://md.research.elamur.ai/free/en/papers/conneau-2020-unsupervised-cross-lingual-representation-learning/). CoRR, abs/1911.02116. [↗](https://arxiv.org/abs/1911.02116)

*Updated 2 November 2026*
