File size: 1,464 Bytes
cf7f853 aa3f536 d22fbf3 aa3f536 88bf3df | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | This is copied from the `codeparrot/apps` which is not in Parquet format (meaning that if you are using Datasets>=4.0.0 you will fail to download it because it requires remote code).
You can find the origin dataset here: https://huggingface.co/datasets/codeparrot/apps
You can find the conversion code here: https://gist.github.com/4gatepylon/024853a9d279812e1f14be93242b3ef8#file-gistfile1-py-L1
NOTE that some of the solutions/input-output are empty. You can check as the code ^ does by looking for `len(element["solution"].strip()) == 0` and/or `len(element["input_output"].strip()) == 0`. Otherwise, these objects are JSON-decodeable strings which look, respectively like:
```
solutions: list[str] # each string is a python function/code you can run that would solve the problem
```
and
```
input_outputs: dict[str, list[list[str] | str | Any]]
# keys: "inputs" and "outputs" have same length
# usually the list items are lists of strings or are single strings
# (I haven't checked exhaustively)
```
Auto-generated docs below:
```
features:
- name: problem_id
dtype: int64
- name: question
dtype: string
- name: solutions
dtype: string
- name: input_output
dtype: string
- name: difficulty
dtype: string
- name: url
dtype: string
- name: starter_code
dtype: string
splits:
- name: test
num_bytes: 1226206337
num_examples: 5000
- name: train
num_bytes: 103144035
num_examples: 5000
download_size: 788823098
dataset_size: 1329350372
``` |