Datasets:

Modalities:
Text
Formats:
parquet
Languages:
English
ArXiv:
Libraries:
Datasets
pandas
License:
Calc-aqua_rat / README.md
prompteus's picture
Upload README.md with huggingface_hub
4a8f6e5
|
raw
history blame
No virus
5.25 kB
metadata
language:
  - en
license: apache-2.0
size_categories:
  - 10K<n<100K
task_categories:
  - question-answering
pretty_name: AQUA-RAT with Calculator
dataset_info:
  config_name: original-splits
  features:
    - name: id
      dtype: string
    - name: question
      dtype: string
    - name: chain
      dtype: string
    - name: result
      dtype: string
    - name: options
      struct:
        - name: A
          dtype: string
        - name: B
          dtype: string
        - name: C
          dtype: string
        - name: D
          dtype: string
        - name: E
          dtype: string
    - name: question_without_options
      dtype: string
  splits:
    - name: train
      num_bytes: 74265737
      num_examples: 97467
    - name: validation
      num_bytes: 212928
      num_examples: 254
    - name: test
      num_bytes: 206180
      num_examples: 254
  download_size: 42873590
  dataset_size: 74684845
configs:
  - config_name: original-splits
    data_files:
      - split: train
        path: original-splits/train-*
      - split: validation
        path: original-splits/validation-*
      - split: test
        path: original-splits/test-*

Dataset Card for "Calc-aqua_rat"

Summary

This dataset is an instance of aqua_rat dataset extended for the in-context calls of calculator, represented by the exec calls to a sympy library.

Supported Tasks

The dataset is intended for training Chain-of-Thought reasoning models able to use external tools to enhance the factuality of their responses. This dataset presents in-context scenarios where models can out-source the computations in the reasoning chain to a calculator.

Construction Process

The dataset was constructed automatically by evaluating all candidate calls to a sympy library that were extracted from the originally-annotated rationales. The selection of candidates is pivoted by the matching of equals ('=') symbols in the chain, where the left-hand side of the equation is evaluated, and accepted as a correct gadget call, if the result occurs closely on the right-hand side. Therefore, the extraction of calculator calls may inhibit false negatives (where the calculator could have been used but was not), but not any known false positives.

A full description of the extraction process can be found in the corresponding parse script,

If you find an issue in the dataset or in the fresh version of the parsing script, we'd be happy if you report it, or create a PR.

Dataset Structure

The dataset can be loaded by simply choosing a split (train, validation or test) and calling:

import datasets
dataset_val = datasets.load_dataset("MU-NLPC/Calc-aqua_rat", split="validation")
print(dataset_val[0])  # see the output below

Data Instances

The samples of Calc-aqua_rat have this format (newline-reformated for better readability):

{'question': 'Three birds are flying at a fast rate of 900 kilometers per hour. What is their speed in miles per minute? [1km = 0.6 miles]',
 'options': {'A': '32400', 'B': '6000', 'C': '600', 'D': '60000', 'E': '10'},
 'result': 'A',
 'chain':     'To calculate the equivalent of miles in a kilometer\n
               0.6 kilometers \n= 1 mile\n
               900 kilometers \n= (0.6)*900\n= \n<gadget id="calculator">(0.6)*900</gadget>\n<output>540</output>\n540 miles\n
               In 1 hour there are 60 minutes\n
               Speed in miles/minutes\n= 60 * 540\n= \n<gadget id="calculator">60 * 540</gadget>\n<output>32_400</output>\n32400\n
               Correct answer - 32400\n.
               <result>A</result>'
}

The enclosing HTML tags (e.g. <gadget id="calculator">(0.6)*900</gadget>\n<output>540</output>) represent the inputs and outputs to the sympy.parse_expr().evalf() method (in our code here).

Note that the format of the dataset is consistent with MU-NLPC/Calc-gsm8k.

Data Fields

  • question: A natural language definition of the problem to solve.
  • options: 5 possible options (A, B, C, D and E), among which one is correct
  • result: The correct option
  • chain: A natural language step-by-step solution with automatically inserted calculator calls and outputs of the sympy calculator.

Data Splits

The samples in data splits are consistent with the original aqua_rat dataset, containing:

  • train split of 97467 samples,
  • validation split of 254 samples,
  • test split of 254.

Licensing

Apache-2.0, consistently with the original aqua-rat dataset.

Cite

If you use this dataset in research, please cite the original aqua-rat paper and our report as follows:

@article{kadlcik2023calcx,
         title={Calc-X: Enriching Arithmetical Chain-of-Thoughts Datasets by Interaction with Symbolic Systems}, 
         author={Marek Kadlčík and Michal Štefánik},
         year={2023},
         eprint={2305.15017},
         archivePrefix={arXiv},
         primaryClass={cs.LG}
}