urbija commited on
Commit
1902fb5
1 Parent(s): cc5f84c

updated dataset_info.json and adapted to already BIO2-encoded source data

Browse files
Files changed (2) hide show
  1. dataset_info.json +1 -127
  2. mobie.py +1 -5
dataset_info.json CHANGED
@@ -1,127 +1 @@
1
- {
2
- "description": "MobIE is a German-language dataset which is human-annotated with 20 coarse- and fine-grained entity types and entity linking information for geographically linkable entities. The dataset consists of 3,232 social media texts and traffic reports with 91K tokens, and contains 20.5K annotated entities, 13.1K of which are linked to a knowledge base. A subset of the dataset is human-annotated with seven mobility-related, n-ary relation types, while the remaining documents are annotated using a weakly-supervised labeling approach implemented with the Snorkel framework. The dataset combines annotations for NER, EL and RE, and thus can be used for joint and multi-task learning of these fundamental information extraction tasks.",
3
- "citation": " @inproceedings{hennig-etal-2021-mobie,\n title = \"{M}ob{IE}: A {G}erman Dataset for Named Entity Recognition, Entity Linking and Relation Extraction in the Mobility Domain\",\n author = \"Hennig, Leonhard and\n Truong, Phuc Tran and\n Gabryszak, Aleksandra\",\n booktitle = \"Proceedings of the 17th Conference on Natural Language Processing (KONVENS 2021)\",\n month = \"6--9 \" # sep,\n year = \"2021\",\n address = {D{\"u}sseldorf, Germany},\n publisher = \"KONVENS 2021 Organizers\",\n url = \"https://aclanthology.org/2021.konvens-1.22\",\n pages = \"223--227\",\n}\n",
4
- "homepage": "https://github.com/dfki-nlp/mobie",
5
- "license": "CC-BY 4.0",
6
- "features": {
7
- "id": {
8
- "dtype": "string",
9
- "id": null,
10
- "_type": "Value"
11
- },
12
- "tokens": {
13
- "feature": {
14
- "dtype": "string",
15
- "id": null,
16
- "_type": "Value"
17
- },
18
- "length": -1,
19
- "id": null,
20
- "_type": "Sequence"
21
- },
22
- "ner_tags": {
23
- "feature": {
24
- "num_classes": 41,
25
- "names": [
26
- "O",
27
- "B-date",
28
- "I-date",
29
- "B-disaster-type",
30
- "I-disaster-type",
31
- "B-distance",
32
- "I-distance",
33
- "B-duration",
34
- "I-duration",
35
- "B-event-cause",
36
- "I-event-cause",
37
- "B-location",
38
- "I-location",
39
- "B-location-city",
40
- "I-location-city",
41
- "B-location-route",
42
- "I-location-route",
43
- "B-location-stop",
44
- "I-location-stop",
45
- "B-location-street",
46
- "I-location-street",
47
- "B-money",
48
- "I-money",
49
- "B-number",
50
- "I-number",
51
- "B-organization",
52
- "I-organization",
53
- "B-organization-company",
54
- "I-organization-company",
55
- "B-org-position",
56
- "I-org-position",
57
- "B-percent",
58
- "I-percent",
59
- "B-person",
60
- "I-person",
61
- "B-set",
62
- "I-set",
63
- "B-time",
64
- "I-time",
65
- "B-trigger",
66
- "I-trigger"
67
- ],
68
- "names_file": null,
69
- "id": null,
70
- "_type": "ClassLabel"
71
- },
72
- "length": -1,
73
- "id": null,
74
- "_type": "Sequence"
75
- }
76
- },
77
- "post_processed": null,
78
- "supervised_keys": null,
79
- "task_templates": null,
80
- "builder_name": "mobie",
81
- "config_name": "mobie-v1_20210811",
82
- "version": {
83
- "version_str": "1.0.0",
84
- "description": null,
85
- "major": 1,
86
- "minor": 0,
87
- "patch": 0
88
- },
89
- "splits": {
90
- "train": {
91
- "name": "train",
92
- "num_bytes": 1269814,
93
- "num_examples": 4785,
94
- "dataset_name": "mobie"
95
- },
96
- "test": {
97
- "name": "test",
98
- "num_bytes": 441466,
99
- "num_examples": 1210,
100
- "dataset_name": "mobie"
101
- },
102
- "validation": {
103
- "name": "validation",
104
- "num_bytes": 286139,
105
- "num_examples": 1082,
106
- "dataset_name": "mobie"
107
- }
108
- },
109
- "download_checksums": {
110
- "https://github.com/DFKI-NLP/MobIE/raw/master/v1_20210811/train.jsonl.gz": {
111
- "num_bytes": 5273134,
112
- "checksum": "334cb5d7d66877f2e6344f019de93ad99daaae5b2876c159e28f37da7d29b0b6"
113
- },
114
- "https://github.com/DFKI-NLP/MobIE/raw/master/v1_20210811/dev.jsonl.gz": {
115
- "num_bytes": 1154038,
116
- "checksum": "e671265e1ae291e69057c0fc321efe880c88249a7c292fd69696ff1cbc9356c2"
117
- },
118
- "https://github.com/DFKI-NLP/MobIE/raw/master/v1_20210811/test.jsonl.gz": {
119
- "num_bytes": 1745158,
120
- "checksum": "181150d920da072dd6677b05aac22d81d666ae89ed79dacf5e13d2cd6119a8d7"
121
- }
122
- },
123
- "download_size": 8172330,
124
- "post_processing_size": null,
125
- "dataset_size": 1997419,
126
- "size_in_bytes": 10169749
127
- }
 
1
+ {"description": "MobIE is a German-language dataset which is human-annotated with 20 coarse- and fine-grained entity types and entity linking information for geographically linkable entities. The dataset consists of 3,232 social media texts and traffic reports with 91K tokens, and contains 20.5K annotated entities, 13.1K of which are linked to a knowledge base. A subset of the dataset is human-annotated with seven mobility-related, n-ary relation types, while the remaining documents are annotated using a weakly-supervised labeling approach implemented with the Snorkel framework. The dataset combines annotations for NER, EL and RE, and thus can be used for joint and multi-task learning of these fundamental information extraction tasks.", "citation": " @inproceedings{hennig-etal-2021-mobie,\n title = \"{M}ob{IE}: A {G}erman Dataset for Named Entity Recognition, Entity Linking and Relation Extraction in the Mobility Domain\",\n author = \"Hennig, Leonhard and\n Truong, Phuc Tran and\n Gabryszak, Aleksandra\",\n booktitle = \"Proceedings of the 17th Conference on Natural Language Processing (KONVENS 2021)\",\n month = \"6--9 \" # sep,\n year = \"2021\",\n address = {D{\"u}sseldorf, Germany},\n publisher = \"KONVENS 2021 Organizers\",\n url = \"https://aclanthology.org/2021.konvens-1.22\",\n pages = \"223--227\",\n}\n", "homepage": "https://github.com/dfki-nlp/mobie", "license": "CC-BY 4.0", "features": {"id": {"dtype": "string", "id": null, "_type": "Value"}, "tokens": {"feature": {"dtype": "string", "id": null, "_type": "Value"}, "length": -1, "id": null, "_type": "Sequence"}, "ner_tags": {"feature": {"num_classes": 41, "names": ["O", "B-date", "I-date", "B-disaster-type", "I-disaster-type", "B-distance", "I-distance", "B-duration", "I-duration", "B-event-cause", "I-event-cause", "B-location", "I-location", "B-location-city", "I-location-city", "B-location-route", "I-location-route", "B-location-stop", "I-location-stop", "B-location-street", "I-location-street", "B-money", "I-money", "B-number", "I-number", "B-organization", "I-organization", "B-organization-company", "I-organization-company", "B-org-position", "I-org-position", "B-percent", "I-percent", "B-person", "I-person", "B-set", "I-set", "B-time", "I-time", "B-trigger", "I-trigger"], "names_file": null, "id": null, "_type": "ClassLabel"}, "length": -1, "id": null, "_type": "Sequence"}}, "post_processed": null, "supervised_keys": null, "task_templates": null, "builder_name": "mobie", "config_name": "mobie-v1_20210811", "version": {"version_str": "1.0.0", "description": null, "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 1269814, "num_examples": 4785, "dataset_name": "mobie"}, "test": {"name": "test", "num_bytes": 441466, "num_examples": 1210, "dataset_name": "mobie"}, "validation": {"name": "validation", "num_bytes": 286139, "num_examples": 1082, "dataset_name": "mobie"}}, "download_checksums": {"https://github.com/DFKI-NLP/MobIE/raw/master/v1_20210811/train.jsonl.gz": {"num_bytes": 5285543, "checksum": "b1a5a2da0e3291543b188b82433e2f607b3400700576b5c46fb1756673395eea"}, "https://github.com/DFKI-NLP/MobIE/raw/master/v1_20210811/dev.jsonl.gz": {"num_bytes": 1156347, "checksum": "e14413e32c29817179cc90d2b026a8e839e5c982ad8567cd81143d70b00c03f5"}, "https://github.com/DFKI-NLP/MobIE/raw/master/v1_20210811/test.jsonl.gz": {"num_bytes": 1748322, "checksum": "f3dfb888cb6b76382e975518622e6ed5dd065c00f61659521f50c89eaff4976a"}}, "download_size": 8190212, "post_processing_size": null, "dataset_size": 1997419, "size_in_bytes": 10187631}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
mobie.py CHANGED
@@ -201,11 +201,7 @@ class Mobie(datasets.GeneratorBasedBuilder):
201
  sid = s["id"]
202
  for x in s["tokens"]["array"]:
203
  toks.append(text[x["span"]["start"] : x["span"]["end"]])
204
- # convert to BIO
205
- if x["ner"]["string"] != 'O':
206
- lbls.append("B-" + x["ner"]["string"] if x["span"]["start"] in entity_starts else "I-" + x["ner"]["string"])
207
- else:
208
- lbls.append(x["ner"]["string"])
209
 
210
  yield sid, {
211
  "id": sid,
 
201
  sid = s["id"]
202
  for x in s["tokens"]["array"]:
203
  toks.append(text[x["span"]["start"] : x["span"]["end"]])
204
+ lbls.append(x["ner"]["string"])
 
 
 
 
205
 
206
  yield sid, {
207
  "id": sid,