File size: 2,199 Bytes
c63d916
 
afc6ffb
 
 
 
 
 
 
 
 
bc21651
 
afc6ffb
b1fa94b
afc6ffb
 
 
 
 
 
 
bc21651
afc6ffb
 
bc21651
afc6ffb
 
bc21651
c63d916
afc6ffb
 
 
cde5638
afc6ffb
 
 
b1fa94b
cde5638
 
afc6ffb
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
b1fa94b
afc6ffb
 
cde5638
afc6ffb
 
 
 
 
 
 
 
 
 
 
53d86b7
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
---
license: gpl-3.0
language:
- es
library_name: spacy
pipeline_tag: token-classification
tags:
- spacy
- token-classification
widget:
- text: "Fue antes de llegar a Sigüeiro, en el Camino de Santiago."
- text: "Si te metes en el Franco desde la Alameda, vas hacia la Catedral."
- text: "Y allí precisamente es Santiago el patrón del pueblo."
model-index:
- name: bne-spacy-corgale-ner-es
  results:
  - task:
      name: NER
      type: token-classification
    metrics:
    - name: NER Precision
      type: precision
      value: 0.9721311475
    - name: NER Recall
      type: recall
      value: 0.9732708089
    - name: NER F Score
      type: f_score
      value: 0.9727006444
---

# Introduction

spaCy NER model for Spanish trained with interviews in the domain of tourism related to the Way of Saint Jacques. It recognizes four types of entities: location (LOC), organizations (ORG), person (PER) and miscellaneous (MISC). It was fine-tuned using `PlanTL-GOB-ES/roberta-base-bne`.

| Feature | Description |
| --- | --- |
| **Name** | `bne-spacy-corgale-ner-es` |
| **Version** | `0.0.2` |
| **spaCy** | `>=3.5.2,<3.6.0` |
| **Default Pipeline** | `transformer`, `ner` |
| **Components** | `transformer`, `ner` |

### Label Scheme

<details>

<summary>View label scheme (4 labels for 1 components)</summary>

| Component | Labels |
| --- | --- |
| **`ner`** | `LOC`, `MISC`, `ORG`, `PER` |

</details>

## Usage

You can use this model with the spaCy *pipeline* for NER.

```python
import spacy
from spacy.pipeline import merge_entities


nlp = spacy.load("bne-spacy-corgale-ner-es")
nlp.add_pipe('sentencizer')

example = "Fue antes de llegar a Sigüeiro, en el Camino de Santiago. Si te metes en el Franco desde la Alameda, vas hacia la Catedral. Y allí precisamente es Santiago el patrón del pueblo."
ner_pipe = nlp(example)

print(ner_pipe.ents)
for token in merge_entities(ner_pipe):
    print(token.text, token.ent_type_)
```

## Dataset

ToDo

## Model performance

entity|precision|recall|f1
-|-|-|-
LOC|0.985|0.987|0.986
MISC|0.862|0.865|0.863
ORG|0.938|0.779|0.851
PER|0.921|0.941|0.931
micro avg|0.971|0.972|0.971
macro avg|0.926|0.893|0.908
weighted avg|0.971|0.972|0.971