engineersakibcse47's picture
update README.md
9d73213 verified
|
raw
history blame
No virus
1.75 kB
---
language: bn
datasets:
- wikiann
examples:
widget:
- text: "রিয়াল মাদ্রিদ ফুটবল ক্লাব"
example_title: "Sentence_1"
- text: "উত্তরবঙ্গ কৃষি বিশ্ববিদ্যালয়"
example_title: "Sentence_2"
- text: "বাংলাদেশ জাতীয় ক্রিকেট দল"
example_title: "Sentence_3"
- text: "বাংলাদেশ টেলিকমিউনিকেশন্স কোম্পানী লিমিটেড"
example_title: "Sentence_4"
- text: "রোমিও অ্যান্ড জুলিয়েট"
example_title: "Sentence_5"
---
<h1>Named Entity Recognition on Bangla Language</h1>
Fine Tuning BERT for NER on Bengali Language Tagging using HuggingFace
## Correspondence Label ID and Label Name
| Label ID | Label Name|
| -------- | ----- |
|0 | O |
| 1 | B-PER |
| 2 | I-PER |
| 3 | B-ORG|
| 4 | I-ORG |
| 5 | B-LOC |
| 6 | I-LOC |
<h1>Evaluation and Validation</h1>
| Name | Precision | Recall | F1 | Accuracy |
| ---- | -------- | ----- | ---- | ---- |
| Train/Val set | 0.963899 | 0.964770 | 0.964334 | 0.981252 |
| Test set | 0.952855 | 0.965105 | 0.958941 | 0.981349 |
Transformers AutoModelForTokenClassification
```py
from transformers import AutoTokenizer, AutoModelForTokenClassification
from transformers import pipeline
tokenizer = AutoTokenizer.from_pretrained("engineersakibcse47/NER_on_Bangla_Language")
model_ner = AutoModelForTokenClassification.from_pretrained("engineersakibcse47/NER_on_Bangla_Language")
pipe = pipeline("ner", model=model_ner, tokenizer=tokenizer)
sample = "বসনিয়া ও হার্জেগোভিনা"
result = pipe(sample)
result
```