Update README.md
Browse files
README.md
CHANGED
@@ -19,7 +19,7 @@ should probably proofread and complete it, then remove this comment. -->
|
|
19 |
|
20 |
# bert-ner-turkish-cased
|
21 |
|
22 |
-
This model is a fine-tuned version of [dbmdz/bert-base-turkish-cased](https://huggingface.co/dbmdz/bert-base-turkish-cased) on
|
23 |
It achieves the following results on the evaluation set:
|
24 |
- Loss: 0.0987
|
25 |
- Precision: 0.9112
|
@@ -37,14 +37,43 @@ LABELS = [
|
|
37 |
"B-DATE", "I-DATE", "B-MONEY", "I-MONEY", "B-MISC", "I-MISC"
|
38 |
]
|
39 |
```
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
|
41 |
## Intended uses & limitations
|
42 |
|
43 |
-
|
44 |
|
45 |
-
##
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
46 |
|
47 |
-
More information needed
|
48 |
|
49 |
## Training procedure
|
50 |
|
|
|
19 |
|
20 |
# bert-ner-turkish-cased
|
21 |
|
22 |
+
This model is a fine-tuned version of [dbmdz/bert-base-turkish-cased](https://huggingface.co/dbmdz/bert-base-turkish-cased) on a custom Turkish NER dataset.
|
23 |
It achieves the following results on the evaluation set:
|
24 |
- Loss: 0.0987
|
25 |
- Precision: 0.9112
|
|
|
37 |
"B-DATE", "I-DATE", "B-MONEY", "I-MONEY", "B-MISC", "I-MISC"
|
38 |
]
|
39 |
```
|
40 |
+
- PER: Person
|
41 |
+
- LOC: Location
|
42 |
+
- ORG: Organization
|
43 |
+
- DATE: Date
|
44 |
+
- MONEY: Money
|
45 |
+
- MISC: Miscellaneous Entities
|
46 |
|
47 |
## Intended uses & limitations
|
48 |
|
49 |
+
Extracting entities from Turkish text in NLP pipelines.
|
50 |
|
51 |
+
## How to Use
|
52 |
+
|
53 |
+
```python
|
54 |
+
from transformers import pipeline
|
55 |
+
|
56 |
+
model_name = "yeniguno/bert-ner-turkish-cased"
|
57 |
+
|
58 |
+
ner_pipeline = pipeline("ner", model=model_name, tokenizer=model_name, aggregation_strategy="simple")
|
59 |
+
|
60 |
+
text = """Selim Parlak, 2023-11-15 tarihinde, CUMHURİYET MAH. DUMAN SOKAK 22500 HAVSA/EDİRNE adresinden, Dünya Varlık Yönetim A.Ş. aracılığıyla 850 TRY değerindeki MP.2386.JPA.IP5.WHT.I İPHONE5 ŞARJLI KILIF "AİR" 1700 MAH (BEYAZ) ürününü satın aldı."""
|
61 |
+
|
62 |
+
results = ner_pipeline(text)
|
63 |
+
|
64 |
+
for result in results:
|
65 |
+
print(result)
|
66 |
+
|
67 |
+
"""
|
68 |
+
{'entity_group': 'PER', 'score': 0.9993254, 'word': 'Selim Parlak', 'start': 0, 'end': 12}
|
69 |
+
{'entity_group': 'DATE', 'score': 0.9987677, 'word': '2023 - 11 - 15', 'start': 14, 'end': 24}
|
70 |
+
{'entity_group': 'LOC', 'score': 0.99951524, 'word': 'CUMHURİYET MAH. DUMAN SOKAK 22500 HAVSA / EDİRNE', 'start': 36, 'end': 82}
|
71 |
+
{'entity_group': 'ORG', 'score': 0.8487069, 'word': 'Dünya Varlık Yönetim A. Ş.', 'start': 95, 'end': 120}
|
72 |
+
{'entity_group': 'MONEY', 'score': 0.9970985, 'word': '850 TRY', 'start': 134, 'end': 141}
|
73 |
+
{'entity_group': 'MISC', 'score': 0.97721404, 'word': 'MP. 2386. JPA. IP5. WHT. I İPHONE5 ŞARJLI KILIF " AİR " 1700 MAH ( BEYAZ )', 'start': 154, 'end': 219}
|
74 |
+
"""
|
75 |
+
```
|
76 |
|
|
|
77 |
|
78 |
## Training procedure
|
79 |
|