Datasets:
GEM
/

Tasks:
Other
Modalities:
Text
Languages:
English
ArXiv:
Libraries:
Datasets
License:
Sebastian Gehrmann commited on
Commit
16898bb
1 Parent(s): 55b2057

formatting

Browse files
Files changed (2) hide show
  1. dataset_infos.json +2 -2
  2. squad_v2.py +7 -3
dataset_infos.json CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:fced5f50843d6237b139c3e0cf295073864b9286980a94ea5ad1d06ec9a093e9
3
- size 2532
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2b57dedd58342e6e56bdb4f3b140ea5fd7098c3e441866d216d5eea44b10752a
3
+ size 2660
squad_v2.py CHANGED
@@ -28,7 +28,7 @@ _DESCRIPTION = """\
28
  """
29
 
30
  _URLS = {
31
- "gem_data_split":
32
  {
33
  "train": "./gem_data_split/train.json",
34
  "test": "./gem_data_split/test.json",
@@ -60,7 +60,7 @@ class SquadV2(datasets.GeneratorBasedBuilder):
60
  SquadV2Config(name="gem_data_split", version=VERSION_1, description="SQuAD2.0 - GEM version 1"),
61
  ]
62
 
63
- DEFAULT_CONFIG_NAME = "gem_data_split"
64
 
65
  def _info(self):
66
  # TODO(squad_v2): Specifies the datasets.DatasetInfo object
@@ -75,6 +75,8 @@ class SquadV2(datasets.GeneratorBasedBuilder):
75
  "title": datasets.Value("string"),
76
  "context": datasets.Value("string"),
77
  "question": datasets.Value("string"),
 
 
78
  "answers": datasets.features.Sequence(
79
  {
80
  "text": datasets.Value("string"),
@@ -135,12 +137,14 @@ class SquadV2(datasets.GeneratorBasedBuilder):
135
  # Features currently used are "context", "question", and "answers".
136
  # Others are extracted here for the ease of future expansions.
137
  yield id_, {
138
- "id": row["id"],
139
  "gem_id": row["gem_id"],
140
  "title": row["title"],
141
  "context": row["context"],
142
  "question": row["question"],
143
  "answers": row["answers"],
 
 
144
  }
145
 
146
 
 
28
  """
29
 
30
  _URLS = {
31
+ "gem_data_split":
32
  {
33
  "train": "./gem_data_split/train.json",
34
  "test": "./gem_data_split/test.json",
 
60
  SquadV2Config(name="gem_data_split", version=VERSION_1, description="SQuAD2.0 - GEM version 1"),
61
  ]
62
 
63
+ DEFAULT_CONFIG_NAME = "gem_data_split"
64
 
65
  def _info(self):
66
  # TODO(squad_v2): Specifies the datasets.DatasetInfo object
 
75
  "title": datasets.Value("string"),
76
  "context": datasets.Value("string"),
77
  "question": datasets.Value("string"),
78
+ "target": datasets.Value("string"),
79
+ "references": [datasets.Value("string")],
80
  "answers": datasets.features.Sequence(
81
  {
82
  "text": datasets.Value("string"),
 
137
  # Features currently used are "context", "question", and "answers".
138
  # Others are extracted here for the ease of future expansions.
139
  yield id_, {
140
+ "id": row["id"],
141
  "gem_id": row["gem_id"],
142
  "title": row["title"],
143
  "context": row["context"],
144
  "question": row["question"],
145
  "answers": row["answers"],
146
+ "target": row["question"],
147
+ "references": [row["question"]],
148
  }
149
 
150