Coldog2333 commited on
Commit
3adf26a
1 Parent(s): 6542569
Files changed (1) hide show
  1. super_dialseg.py +6 -6
super_dialseg.py CHANGED
@@ -100,10 +100,10 @@ class SuperDialseg(datasets.GeneratorBasedBuilder):
100
  for id_, row in enumerate(data):
101
  yield id_, {
102
  "dial_id": row["dial_id"],
103
- "utterance": [utterance for utterance in row["turns"]["utterance"]],
104
- "segmentation_label": [segmentation_label for segmentation_label in row["turns"]["segmentation_label"]],
105
- "da": [da for da in row["turns"]["da"]],
106
- "role": [role for role in row["turns"]["role"]],
107
- "turn_id": [turn_id for turn_id in row["turns"]["turn_id"]],
108
- "topic_id": [topic_id for topic_id in row["turns"]["topic_id"]]
109
  }
 
100
  for id_, row in enumerate(data):
101
  yield id_, {
102
  "dial_id": row["dial_id"],
103
+ "utterance": [turn["utterance"] for turn in row["turns"]],
104
+ "segmentation_label": [turn["segmentation_label"] for turn in row["turns"]],
105
+ "da": [turn["da"] for turn in row["turns"]],
106
+ "role": [turn["role"] for turn in row["turns"]],
107
+ "turn_id": [turn["turn_id"] for turn in row["turns"]],
108
+ "topic_id": [turn["topic_id"] for turn in row["turns"]]
109
  }