unimelb-nlp/wikiann
Viewer โข Updated โข 2M โข 19.9k โข 121
How to use Tevfik-istanbullu/camelbert-ner-arabic with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("token-classification", model="Tevfik-istanbullu/camelbert-ner-arabic") # Load model directly
from transformers import AutoTokenizer, AutoModelForTokenClassification
tokenizer = AutoTokenizer.from_pretrained("Tevfik-istanbullu/camelbert-ner-arabic")
model = AutoModelForTokenClassification.from_pretrained("Tevfik-istanbullu/camelbert-ner-arabic")This model is a fine-tuned version of CAMeL-Lab/bert-base-arabic-camelbert-mix on unimelb-nlp/wikiann dataset. It achieves the following results on the evaluation set:
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss | Precision | Recall | F1 | Accuracy |
|---|---|---|---|---|---|---|---|
| 0.1892 | 1.0 | 1250 | 0.2003 | 0.8653 | 0.8677 | 0.8665 | 0.9430 |
| 0.123 | 2.0 | 2500 | 0.1912 | 0.8802 | 0.8826 | 0.8814 | 0.9493 |
| 0.0809 | 3.0 | 3750 | 0.1942 | 0.8928 | 0.8969 | 0.8948 | 0.9539 |
from transformers import pipeline
# Load the NER pipeline
nlp = pipeline("ner", model="Tevfik-istanbullu/camelbert-ner-arabic")
# Example text
text = "ูุนู
ู ู
ุญู
ุฏ ูู ุดุฑูุฉ ุฌูุฌู ูู ุฏุจู"
results = nlp(text)
print(results)
Base model
CAMeL-Lab/bert-base-arabic-camelbert-mix