Felix commited on
Commit
a1589d6
1 Parent(s): f657749

fix swefaq

Browse files
Files changed (1) hide show
  1. superlim-2.py +10 -2
superlim-2.py CHANGED
@@ -201,9 +201,13 @@ class SuperLim(datasets.GeneratorBasedBuilder):
201
  elif self.config.name == "swefaq":
202
  features = datasets.Features(
203
  {
 
 
 
204
  "question": datasets.Value("string"),
205
- "candidate_answer": datasets.Value("string"),
206
  "correct_answer": datasets.Value("string"),
 
207
  }
208
  )
209
  elif self.config.name == "swepar":
@@ -354,9 +358,13 @@ class SuperLim(datasets.GeneratorBasedBuilder):
354
  }
355
  elif self.config.name == "swefaq":
356
  yield key, {
 
 
 
357
  "question": row["question"],
358
- "candidate_answer": row["candidate_answer"],
359
  "correct_answer": row["correct_answer"],
 
360
  }
361
  elif self.config.name == "swepar":
362
  yield key, {
 
201
  elif self.config.name == "swefaq":
202
  features = datasets.Features(
203
  {
204
+ "category_id": datasets.Value(dtype='int32'),
205
+ "source": datasets.Value("string"),
206
+ "question_id": datasets.Value(dtype='int32'),
207
  "question": datasets.Value("string"),
208
+ "answer_id": datasets.Value(dtype='int32'),
209
  "correct_answer": datasets.Value("string"),
210
+ "link": datasets.Value("string"),
211
  }
212
  )
213
  elif self.config.name == "swepar":
 
358
  }
359
  elif self.config.name == "swefaq":
360
  yield key, {
361
+ "category_id": row['category_id'],
362
+ "source": row['source'],
363
+ "question_id": row['question_id'],
364
  "question": row["question"],
365
+ "answer_id": row['answer_id'],
366
  "correct_answer": row["correct_answer"],
367
+ "link": row['link']
368
  }
369
  elif self.config.name == "swepar":
370
  yield key, {