The Challenge of Low-Resource Languages in Hate Speech Detection
Roman Urdu—Urdu written using the Latin script—presents significant challenges for standard NLP models due to its lack of standardized orthography, code-switching with English, and limited availability of high-quality annotated datasets. Detecting hate speech in this context is critical for platform safety but often suffers from poor performance when using models trained primarily on English or formal Urdu.
Comparative Performance: PEFT vs. Prompt Engineering
This study evaluates two distinct approaches to adapting Large Language Models (LLMs) for Roman Urdu hate speech classification:
- Parameter-Efficient Fine-Tuning (PEFT): By focusing on techniques like LoRA (Low-Rank Adaptation), the researchers demonstrate that updating a small subset of model parameters can achieve high performance without the prohibitive computational costs of full fine-tuning. PEFT is shown to be particularly effective at capturing the nuances of Roman Urdu's informal syntax and slang, leading to higher F1-scores compared to zero-shot or few-shot prompting.
- Prompt Engineering: The study explores the efficacy of various prompting strategies, including zero-shot, few-shot, and Chain-of-Thought (CoT) prompting. While prompt engineering offers the advantage of not requiring model weight updates, it often struggles with the ambiguity and linguistic variability inherent in Roman Urdu, resulting in lower precision when identifying subtle forms of hate speech.
Strategic Trade-offs for AI Builders
The research highlights a clear trade-off for developers building safety tools for non-English markets. While prompt engineering is faster to implement and requires no training infrastructure, PEFT provides a more robust solution for production-grade classification where accuracy is paramount. The authors suggest that for languages with limited training data, a hybrid approach—using PEFT to ground the model in the specific linguistic patterns of Roman Urdu—yields the most reliable results for content moderation pipelines.