File size: 1,924 Bytes
ad93196
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48ce668
 
9b4a8f3
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48ce668
d154a2b
ad93196
 
 
 
 
 
 
 
 
 
 
 
 
 
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
---
language:
- en
library_name: flair
pipeline_tag: token-classification
---
# English NER model for extraction of named entities from scientific acknowledgement texts using Flair Embeddings

<!-- Provide a quick summary of what the model is/does. -->

F1-Score: 0.79 

Predicts 6 tags:

|label|description|precision|recall|f1-score|support|
|:----|:----|:----|:----|:----|:----|
|GRNB|grant number|0,93|0,98|0,96|160|
|IND|person|0,98|0,98|0,98|295|
|FUND|funding organization|0,70|0,83|0,76|157|
|UNI|university|0,77|0,74|0,75|99|
|MISC|miscellaneous|0,65|0,65|0,65|82|
|COR|corporation|0,75|0,50|0,60|12|

Based on [Flair embeddings](https://aclanthology.org/C18-1139/)

# Usage

Requires: [Flair](https://github.com/flairNLP/flair/) (pip install flair)

```python
#import libraries
from flair.data import Sentence
from flair.models import SequenceTagger

# load the trained model
model = SequenceTagger.load("kalawinka/flair-ner-acknowledgments")

# create example sentence
sentence = Sentence("This work was supported by State Key Lab of Ocean Engineering Shanghai Jiao Tong University and financially supported by China National Scientific and Technology Major Project (Grant No. 2016ZX05028-006-009)")

# predict the tags
model.predict(sentence)
#print output as spans
for entity in sentence.get_spans('ner'):
    print(entity)
```

This produces the following output:

```

```

[See our Google colab notebook](https://colab.research.google.com/drive/1Wz4ae5c65VDWanY3Vo-fj__bFjn-loL4?usp=sharing#scrollTo=2ZRSrcjuFMHO)

# Citation

if you use this model, please consider citing this work:

```
@misc{smirnova2023embedding,
      title={Embedding Models for Supervised Automatic Extraction and Classification of Named Entities in Scientific Acknowledgements}, 
      author={Nina Smirnova and Philipp Mayr},
      year={2023},
      eprint={2307.13377},
      archivePrefix={arXiv},
      primaryClass={cs.DL}
}
```