Update OpinionBench.py
Browse files- OpinionBench.py +6 -6
OpinionBench.py
CHANGED
|
@@ -38,8 +38,8 @@ _CONFIGS = {
|
|
| 38 |
"Citation": datasets.Value("string"),
|
| 39 |
"Full Case Name": datasets.Value("string"),
|
| 40 |
"Opinion Text": datasets.Value("string"),
|
| 41 |
-
"Numerical Label": datasets.Value("string"), # Will be optional for some tasks
|
| 42 |
-
|
| 43 |
#"DC Numerical Label": datasets.Value("string")
|
| 44 |
#"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 45 |
},
|
|
@@ -58,8 +58,8 @@ class LongConLDataset(datasets.GeneratorBasedBuilder):
|
|
| 58 |
"Citation": datasets.Value("string"),
|
| 59 |
"Full Case Name": datasets.Value("string"),
|
| 60 |
"Opinion Text": datasets.Value("string"),
|
| 61 |
-
"Numerical Label": datasets.Value("string"), # Will be optional for some tasks
|
| 62 |
-
|
| 63 |
#"DC Numerical Label": datasets.Value("string")
|
| 64 |
#"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 65 |
})
|
|
@@ -112,8 +112,8 @@ class LongConLDataset(datasets.GeneratorBasedBuilder):
|
|
| 112 |
"Citation": row["Citation"],
|
| 113 |
"Full Case Name": row["Full Case Name"],
|
| 114 |
"Opinion Text": row["Opinion Text"],
|
| 115 |
-
"Numerical Label": row.get("Numerical Label", None), # Use .get() to handle missing keys
|
| 116 |
-
|
| 117 |
#"DC Numerical Label": row["DC Numerical Label"]
|
| 118 |
#"Syllabus": row["Syllabus"]
|
| 119 |
}
|
|
|
|
| 38 |
"Citation": datasets.Value("string"),
|
| 39 |
"Full Case Name": datasets.Value("string"),
|
| 40 |
"Opinion Text": datasets.Value("string"),
|
| 41 |
+
#"Numerical Label": datasets.Value("string"), # Will be optional for some tasks
|
| 42 |
+
"Text Label": datasets.Value("string"), # Will be optional for some tasks
|
| 43 |
#"DC Numerical Label": datasets.Value("string")
|
| 44 |
#"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 45 |
},
|
|
|
|
| 58 |
"Citation": datasets.Value("string"),
|
| 59 |
"Full Case Name": datasets.Value("string"),
|
| 60 |
"Opinion Text": datasets.Value("string"),
|
| 61 |
+
#"Numerical Label": datasets.Value("string"), # Will be optional for some tasks
|
| 62 |
+
"Text Label": datasets.Value("string"), # Will be optional for some tasks
|
| 63 |
#"DC Numerical Label": datasets.Value("string")
|
| 64 |
#"Syllabus": datasets.Value("string") # Will be optional for some tasks
|
| 65 |
})
|
|
|
|
| 112 |
"Citation": row["Citation"],
|
| 113 |
"Full Case Name": row["Full Case Name"],
|
| 114 |
"Opinion Text": row["Opinion Text"],
|
| 115 |
+
#"Numerical Label": row.get("Numerical Label", None), # Use .get() to handle missing keys
|
| 116 |
+
"Text Label": row["Text Label"],
|
| 117 |
#"DC Numerical Label": row["DC Numerical Label"]
|
| 118 |
#"Syllabus": row["Syllabus"]
|
| 119 |
}
|