Fill-Mask
Transformers
PyTorch
Safetensors
Arabic
bert
masked-language-modeling
arabic
social-media
pilot
Instructions to use thejosango/nuha-ajp-mlm with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use thejosango/nuha-ajp-mlm with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="thejosango/nuha-ajp-mlm")# Load model directly from transformers import AutoTokenizer, AutoModelForMaskedLM tokenizer = AutoTokenizer.from_pretrained("thejosango/nuha-ajp-mlm") model = AutoModelForMaskedLM.from_pretrained("thejosango/nuha-ajp-mlm", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Adding `safetensors` variant of this model
#1
by SFconvertbot - opened
- README.md +7 -7
- model.safetensors +1 -1
README.md
CHANGED
|
@@ -10,14 +10,14 @@ tags:
|
|
| 10 |
- fill-mask
|
| 11 |
- pilot
|
| 12 |
datasets:
|
| 13 |
-
- thejosango/nuha-
|
| 14 |
---
|
| 15 |
|
| 16 |
-
# nuha-
|
| 17 |
|
| 18 |
## Model Summary
|
| 19 |
|
| 20 |
-
`nuha-
|
| 21 |
|
| 22 |
Starting from a fresh vocabulary trained on the NUHA corpus rather than fine-tuning an existing Arabic BERT, the model is adapted to the vocabulary and linguistic patterns of colloquial Jordanian Arabic social media text.
|
| 23 |
|
|
@@ -25,12 +25,12 @@ Starting from a fresh vocabulary trained on the NUHA corpus rather than fine-tun
|
|
| 25 |
|
| 26 |
### Direct Use
|
| 27 |
|
| 28 |
-
`nuha-
|
| 29 |
|
| 30 |
```python
|
| 31 |
from transformers import pipeline
|
| 32 |
|
| 33 |
-
fill_mask = pipeline("fill-mask", model="thejosango/nuha-
|
| 34 |
results = fill_mask("هذه المرأة [MASK] جداً")
|
| 35 |
for r in results:
|
| 36 |
print(r["token_str"], r["score"])
|
|
@@ -38,7 +38,7 @@ for r in results:
|
|
| 38 |
|
| 39 |
### Downstream Use
|
| 40 |
|
| 41 |
-
The primary intended downstream use is fine-tuning for hate speech and gender-based violence detection using the NUHA dataset, as demonstrated by [`nuha-
|
| 42 |
|
| 43 |
### Out-of-Scope Use
|
| 44 |
|
|
@@ -55,7 +55,7 @@ This model was pre-trained on a relatively small, domain-specific corpus of Jord
|
|
| 55 |
|
| 56 |
### Training Data
|
| 57 |
|
| 58 |
-
Pre-trained on the text portion of the [`thejosango/nuha-
|
| 59 |
|
| 60 |
### Training Procedure
|
| 61 |
|
|
|
|
| 10 |
- fill-mask
|
| 11 |
- pilot
|
| 12 |
datasets:
|
| 13 |
+
- thejosango/nuha-dataset
|
| 14 |
---
|
| 15 |
|
| 16 |
+
# nuha-jo-mlm
|
| 17 |
|
| 18 |
## Model Summary
|
| 19 |
|
| 20 |
+
`nuha-jo-mlm` is an Arabic BERT model pre-trained from scratch on Jordanian social media text using masked language modelling (MLM). It serves as the domain-adapted base for the NUHA classifier family — [`nuha-jo-binary`](https://huggingface.co/thejosango/nuha-jo-binary) and [`nuha-jo-trinary-full`](https://huggingface.co/thejosango/nuha-jo-trinary-full) — and was developed as part of a **pilot proof-of-concept** for the NUHA project by the [Jordan Open Source Association (JOSA)](https://josa.ngo).
|
| 21 |
|
| 22 |
Starting from a fresh vocabulary trained on the NUHA corpus rather than fine-tuning an existing Arabic BERT, the model is adapted to the vocabulary and linguistic patterns of colloquial Jordanian Arabic social media text.
|
| 23 |
|
|
|
|
| 25 |
|
| 26 |
### Direct Use
|
| 27 |
|
| 28 |
+
`nuha-jo-mlm` can be used for masked token prediction on Arabic social media text, or as a base model for fine-tuning downstream Arabic NLP tasks — particularly those involving informal Jordanian or Levantine Arabic.
|
| 29 |
|
| 30 |
```python
|
| 31 |
from transformers import pipeline
|
| 32 |
|
| 33 |
+
fill_mask = pipeline("fill-mask", model="thejosango/nuha-jo-mlm")
|
| 34 |
results = fill_mask("هذه المرأة [MASK] جداً")
|
| 35 |
for r in results:
|
| 36 |
print(r["token_str"], r["score"])
|
|
|
|
| 38 |
|
| 39 |
### Downstream Use
|
| 40 |
|
| 41 |
+
The primary intended downstream use is fine-tuning for hate speech and gender-based violence detection using the NUHA dataset, as demonstrated by [`nuha-jo-binary`](https://huggingface.co/thejosango/nuha-jo-binary) and [`nuha-jo-trinary-full`](https://huggingface.co/thejosango/nuha-jo-trinary-full).
|
| 42 |
|
| 43 |
### Out-of-Scope Use
|
| 44 |
|
|
|
|
| 55 |
|
| 56 |
### Training Data
|
| 57 |
|
| 58 |
+
Pre-trained on the text portion of the [`thejosango/nuha-dataset`](https://huggingface.co/datasets/thejosango/nuha-dataset) — a corpus of Arabic social media comments collected from Jordanian platforms. The `binary` dataset split was used for pre-training (text only, labels ignored).
|
| 59 |
|
| 60 |
### Training Procedure
|
| 61 |
|
model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 398065292
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9506d281ad68aba4d88eb618b02f26e05b4785a464f95308deddb9170f2466e1
|
| 3 |
size 398065292
|