Datasets:
Tasks:
Text Classification
Sub-tasks:
multi-class-classification
Languages:
English
Size:
100K<n<1M
ArXiv:
Tags:
relation extraction
License:
removed todos
Browse files
tacred.py
CHANGED
@@ -37,8 +37,6 @@ _CITATION = """\
|
|
37 |
}
|
38 |
"""
|
39 |
|
40 |
-
# TODO: Add description of the dataset here
|
41 |
-
# You can copy an official description
|
42 |
_DESCRIPTION = """\
|
43 |
TACRED is a large-scale relation extraction dataset with 106,264 examples built over newswire
|
44 |
and web text from the corpus used in the yearly TAC Knowledge Base Population (TAC KBP) challenges.
|
@@ -53,10 +51,8 @@ the original version released in 2017. For more details on this new version, see
|
|
53 |
published at ACL 2020.
|
54 |
"""
|
55 |
|
56 |
-
# TODO: Add a link to an official homepage for the dataset here
|
57 |
_HOMEPAGE = "https://nlp.stanford.edu/projects/tacred/"
|
58 |
|
59 |
-
# TODO: Add the licence for the dataset here if you can find it
|
60 |
_LICENSE = "LDC"
|
61 |
|
62 |
_URL = "https://catalog.ldc.upenn.edu/LDC2018T24"
|
@@ -265,5 +261,7 @@ class Tacred(datasets.GeneratorBasedBuilder):
|
|
265 |
"pos_tags": example["stanford_pos"],
|
266 |
"ner_tags": example["stanford_ner"],
|
267 |
"stanford_deprel": example["stanford_deprel"],
|
268 |
-
"stanford_head": [
|
|
|
|
|
269 |
}
|
|
|
37 |
}
|
38 |
"""
|
39 |
|
|
|
|
|
40 |
_DESCRIPTION = """\
|
41 |
TACRED is a large-scale relation extraction dataset with 106,264 examples built over newswire
|
42 |
and web text from the corpus used in the yearly TAC Knowledge Base Population (TAC KBP) challenges.
|
|
|
51 |
published at ACL 2020.
|
52 |
"""
|
53 |
|
|
|
54 |
_HOMEPAGE = "https://nlp.stanford.edu/projects/tacred/"
|
55 |
|
|
|
56 |
_LICENSE = "LDC"
|
57 |
|
58 |
_URL = "https://catalog.ldc.upenn.edu/LDC2018T24"
|
|
|
261 |
"pos_tags": example["stanford_pos"],
|
262 |
"ner_tags": example["stanford_ner"],
|
263 |
"stanford_deprel": example["stanford_deprel"],
|
264 |
+
"stanford_head": [
|
265 |
+
head - 1 for head in example["stanford_head"]
|
266 |
+
], # make offsets 0-based
|
267 |
}
|