Views
No views yet
nuha-ajp-trinary-onnx is a lightweight, ONNX-optimised Arabic text classifier that categorises Jordanian social media comments into three classes based on the NUHA methodology for online gender-based violence (OGBV). It fine-tunes nuha-ajp-mlm — a domain-adapted Arabic BERT — with a reduced 4-layer architecture for efficient CPU inference, and is exported to ONNX. It shares the same classification task and labels as nuha-ajp-trinary but is optimised for production deployment. This is the model powering the NUHA analysis platform.| Label | Meaning |
|---|---|
Not Online Violence | Comments that are not hate speech |
Offensive Language | Hate speech characterised by irony or sarcasm |
Gender Based Violence | Direct hate speech targeting gender — the primary focus of NUHA |
nuha-ajp-trinary.1from optimum.onnxruntime import ORTModelForSequenceClassification
2from transformers import AutoTokenizer, pipeline
3
4model = ORTModelForSequenceClassification.from_pretrained("thejosango/nuha-ajp-trinary-onnx")
5tokenizer = AutoTokenizer.from_pretrained("thejosango/nuha-ajp-trinary-onnx")
6classifier = pipeline("text-classification", model=model, tokenizer=tokenizer)
7
8result = classifier("اخرسي يا غبية")
9print(result)
10# [{'label': 'Gender Based Violence', 'score': ...}]1comments = ["يعطيكم العافية", "أنتِ ساحرة", "اخرسي يا غبية"]
2results = classifier(comments)
3for comment, result in zip(comments, results):
4 print(f"{result['label']} ({result['score']:.2f}): {comment}")nuha-ajp-trinary directly.[رابط] token[مستخدم] token[بريد] tokenthejosango/nuha-ajp-dataset (methodology configuration):| Metric | Value |
|---|---|
| F1 (macro) | 0.5363 |
| Precision | 0.6660 |
| Recall | 0.5188 |
nuha-ajp-trinary for full training details and evaluation discussion.