Datasets:
Tasks:
Text2Text Generation
Modalities:
Text
Size:
1K - 10K
ArXiv:
Tags:
math-word-problems
License:
update script and readme
Browse files
README.md
CHANGED
@@ -1,8 +1,9 @@
|
|
1 |
---
|
2 |
annotations_creators:
|
3 |
-
-
|
4 |
language_creators:
|
5 |
-
-
|
|
|
6 |
language:
|
7 |
- en
|
8 |
- es
|
@@ -21,7 +22,7 @@ multilinguality:
|
|
21 |
size_categories:
|
22 |
- 1K<n<10K
|
23 |
source_datasets:
|
24 |
-
-
|
25 |
task_categories:
|
26 |
- text2text-generation
|
27 |
task_ids: []
|
|
|
1 |
---
|
2 |
annotations_creators:
|
3 |
+
- found
|
4 |
language_creators:
|
5 |
+
- found
|
6 |
+
- expert-generated
|
7 |
language:
|
8 |
- en
|
9 |
- es
|
|
|
22 |
size_categories:
|
23 |
- 1K<n<10K
|
24 |
source_datasets:
|
25 |
+
- extended|gsm8k
|
26 |
task_categories:
|
27 |
- text2text-generation
|
28 |
task_ids: []
|
mgsm.py
CHANGED
@@ -13,9 +13,14 @@
|
|
13 |
# limitations under the License.
|
14 |
"""Multilingual Grade School Math Benchmark (MGSM)"""
|
15 |
|
16 |
-
import datasets
|
17 |
import csv
|
18 |
-
from
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
|
20 |
_CITATION = """\
|
21 |
@article{cobbe2021gsm8k,
|
@@ -112,9 +117,9 @@ class MGSM(datasets.GeneratorBasedBuilder):
|
|
112 |
def _generate_examples(self, filepath):
|
113 |
if filepath.endswith(".py"):
|
114 |
name = self.config.name
|
115 |
-
examples =
|
116 |
-
number_answers =
|
117 |
-
equation_solutions =
|
118 |
for key, data in examples.items():
|
119 |
yield key, {
|
120 |
"question": data["q"],
|
@@ -128,8 +133,6 @@ class MGSM(datasets.GeneratorBasedBuilder):
|
|
128 |
csv_file,
|
129 |
quotechar='"',
|
130 |
delimiter="\t",
|
131 |
-
quoting=csv.QUOTE_ALL,
|
132 |
-
skipinitialspace=True,
|
133 |
)
|
134 |
for key, row in enumerate(csv_reader):
|
135 |
yield key, {
|
|
|
13 |
# limitations under the License.
|
14 |
"""Multilingual Grade School Math Benchmark (MGSM)"""
|
15 |
|
|
|
16 |
import csv
|
17 |
+
from .exemplars import (
|
18 |
+
EXEMPLAR_NUMBER_ANSWERS,
|
19 |
+
EXEMPLAR_EQUATION_SOLUTIONS,
|
20 |
+
MGSM_EXEMPLARS,
|
21 |
+
)
|
22 |
+
import datasets
|
23 |
+
|
24 |
|
25 |
_CITATION = """\
|
26 |
@article{cobbe2021gsm8k,
|
|
|
117 |
def _generate_examples(self, filepath):
|
118 |
if filepath.endswith(".py"):
|
119 |
name = self.config.name
|
120 |
+
examples = MGSM_EXEMPLARS[name]
|
121 |
+
number_answers = EXEMPLAR_NUMBER_ANSWERS
|
122 |
+
equation_solutions = EXEMPLAR_EQUATION_SOLUTIONS
|
123 |
for key, data in examples.items():
|
124 |
yield key, {
|
125 |
"question": data["q"],
|
|
|
133 |
csv_file,
|
134 |
quotechar='"',
|
135 |
delimiter="\t",
|
|
|
|
|
136 |
)
|
137 |
for key, row in enumerate(csv_reader):
|
138 |
yield key, {
|