cl-tohoku commited on
Commit
ec241cb
1 Parent(s): 06586b8

Add `datasets.no_passages.aio_02` config

Browse files
Files changed (2) hide show
  1. README.md +32 -1
  2. quiz-datasets.py +9 -2
README.md CHANGED
@@ -189,10 +189,41 @@ dataset_info:
189
  num_examples: 4288198
190
  download_size: 1110830651
191
  dataset_size: 3054493919
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
192
  ---
193
 
194
  # Quiz Datasets for NLP
195
 
196
  Question answering (QA) datasets created from Japanese quiz (trivia) questions.
197
 
198
- Please refer to [cl-tohoku/quiz-datasets](https://github.com/cl-tohoku/quiz-datasets) for details, as well as the licenses of the question data.
 
189
  num_examples: 4288198
190
  download_size: 1110830651
191
  dataset_size: 3054493919
192
+ - config_name: datasets.no_passages.aio_02
193
+ features:
194
+ - name: qid
195
+ dtype: string
196
+ - name: competition
197
+ dtype: string
198
+ - name: timestamp
199
+ dtype: string
200
+ - name: section
201
+ dtype: string
202
+ - name: number
203
+ dtype: string
204
+ - name: original_question
205
+ dtype: string
206
+ - name: original_answer
207
+ dtype: string
208
+ - name: original_additional_info
209
+ dtype: string
210
+ - name: question
211
+ dtype: string
212
+ - name: answers
213
+ sequence: string
214
+ splits:
215
+ - name: train
216
+ num_bytes: 9464003
217
+ num_examples: 22335
218
+ - name: validation
219
+ num_bytes: 409779
220
+ num_examples: 1000
221
+ download_size: 2267163
222
+ dataset_size: 9873782
223
  ---
224
 
225
  # Quiz Datasets for NLP
226
 
227
  Question answering (QA) datasets created from Japanese quiz (trivia) questions.
228
 
229
+ Please refer to [cl-tohoku/quiz-datasets](https://github.com/cl-tohoku/quiz-datasets) for details, as well as the licenses of the question data.
quiz-datasets.py CHANGED
@@ -34,6 +34,10 @@ Attribution-ShareAlike 3.0 Unported ライセンスおよび GFDL ライセン
34
 
35
  _URL_BASE = "https://github.com/cl-tohoku/quiz-datasets/releases/download"
36
  _URLS = {
 
 
 
 
37
  "datasets.jawiki-20220404-c400-small.aio_02": {
38
  "train": f"{_URL_BASE}/v1.0.0/datasets.jawiki-20220404-c400-small.aio_02_train.jsonl.gz",
39
  "dev": f"{_URL_BASE}/v1.0.0/datasets.jawiki-20220404-c400-small.aio_02_dev.jsonl.gz",
@@ -79,6 +83,10 @@ class QuizDatasets(datasets.GeneratorBasedBuilder):
79
  "original_additional_info": datasets.Value("string"),
80
  "question": datasets.Value("string"),
81
  "answers": datasets.Sequence(datasets.Value("string")),
 
 
 
 
82
  "passages": datasets.Sequence(
83
  {
84
  "passage_id": datasets.Value("int32"),
@@ -88,8 +96,7 @@ class QuizDatasets(datasets.GeneratorBasedBuilder):
88
  ),
89
  "positive_passage_indices": datasets.Sequence(datasets.Value("int32")),
90
  "negative_passage_indices": datasets.Sequence(datasets.Value("int32")),
91
- }
92
- )
93
  elif self.config.name.startswith("passages"):
94
  features = datasets.Features(
95
  {
 
34
 
35
  _URL_BASE = "https://github.com/cl-tohoku/quiz-datasets/releases/download"
36
  _URLS = {
37
+ "datasets.no_passages.aio_02": {
38
+ "train": f"{_URL_BASE}/v1.0.0/datasets.no_passages.aio_02_train.jsonl.gz",
39
+ "dev": f"{_URL_BASE}/v1.0.0/datasets.no_passages.aio_02_dev.jsonl.gz",
40
+ },
41
  "datasets.jawiki-20220404-c400-small.aio_02": {
42
  "train": f"{_URL_BASE}/v1.0.0/datasets.jawiki-20220404-c400-small.aio_02_train.jsonl.gz",
43
  "dev": f"{_URL_BASE}/v1.0.0/datasets.jawiki-20220404-c400-small.aio_02_dev.jsonl.gz",
 
83
  "original_additional_info": datasets.Value("string"),
84
  "question": datasets.Value("string"),
85
  "answers": datasets.Sequence(datasets.Value("string")),
86
+ }
87
+ )
88
+ if not self.config.name.startswith("datasets.no_passages"):
89
+ features.update({
90
  "passages": datasets.Sequence(
91
  {
92
  "passage_id": datasets.Value("int32"),
 
96
  ),
97
  "positive_passage_indices": datasets.Sequence(datasets.Value("int32")),
98
  "negative_passage_indices": datasets.Sequence(datasets.Value("int32")),
99
+ })
 
100
  elif self.config.name.startswith("passages"):
101
  features = datasets.Features(
102
  {