Update LongConL.py
Browse files- LongConL.py +6 -6
LongConL.py
CHANGED
|
@@ -33,8 +33,8 @@ _CONFIGS = {
|
|
| 33 |
"Citation": datasets.Value("string"),
|
| 34 |
"Full Case Name": datasets.Value("string"),
|
| 35 |
"Opinion Text": datasets.Value("string"),
|
| 36 |
-
|
| 37 |
-
"Text Label": datasets.Value("string"), # Will be optional for some tasks
|
| 38 |
"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 39 |
},
|
| 40 |
}
|
|
@@ -52,8 +52,8 @@ class LongConLDataset(datasets.GeneratorBasedBuilder):
|
|
| 52 |
"Citation": datasets.Value("string"),
|
| 53 |
"Full Case Name": datasets.Value("string"),
|
| 54 |
"Opinion Text": datasets.Value("string"),
|
| 55 |
-
|
| 56 |
-
"Text Label": datasets.Value("string"), # Will be optional for some tasks
|
| 57 |
"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 58 |
})
|
| 59 |
return datasets.DatasetInfo(
|
|
@@ -102,8 +102,8 @@ class LongConLDataset(datasets.GeneratorBasedBuilder):
|
|
| 102 |
"Citation": row["Citation"],
|
| 103 |
"Full Case Name": row["Full Case Name"],
|
| 104 |
"Opinion Text": row["Opinion Text"],
|
| 105 |
-
|
| 106 |
-
"Text Label": row["Text Label"],
|
| 107 |
"Syllabus": row["Syllabus"]
|
| 108 |
}
|
| 109 |
|
|
|
|
| 33 |
"Citation": datasets.Value("string"),
|
| 34 |
"Full Case Name": datasets.Value("string"),
|
| 35 |
"Opinion Text": datasets.Value("string"),
|
| 36 |
+
"Numerical Label": datasets.Value("string"), # Will be optional for some tasks
|
| 37 |
+
#"Text Label": datasets.Value("string"), # Will be optional for some tasks
|
| 38 |
"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 39 |
},
|
| 40 |
}
|
|
|
|
| 52 |
"Citation": datasets.Value("string"),
|
| 53 |
"Full Case Name": datasets.Value("string"),
|
| 54 |
"Opinion Text": datasets.Value("string"),
|
| 55 |
+
"Numerical Label": datasets.Value("string"), # Will be optional for some tasks
|
| 56 |
+
#"Text Label": datasets.Value("string"), # Will be optional for some tasks
|
| 57 |
"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 58 |
})
|
| 59 |
return datasets.DatasetInfo(
|
|
|
|
| 102 |
"Citation": row["Citation"],
|
| 103 |
"Full Case Name": row["Full Case Name"],
|
| 104 |
"Opinion Text": row["Opinion Text"],
|
| 105 |
+
"Numerical Label": row.get("Numerical Label", None), # Use .get() to handle missing keys
|
| 106 |
+
#"Text Label": row["Text Label"],
|
| 107 |
"Syllabus": row["Syllabus"]
|
| 108 |
}
|
| 109 |
|