File size: 3,183 Bytes
f5a5b7d 11f66f5 f5a5b7d 11f66f5 f5a5b7d 11f66f5 f5a5b7d 11f66f5 f5a5b7d 11f66f5 |
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 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 |
---
dataset_info:
- config_name: default
features:
- name: path
dtype: string
- name: task_binary
dtype: binary
splits:
- name: train
num_bytes: 44246842
num_examples: 9644
download_size: 44246842
dataset_size: 44246842
---
# CodeContests
A dataset of **9,644** code contest tasks with sandbox environments and tests, formatted for [Harbor](https://github.com/open-thoughts/OpenThoughts-Agent) / [SkyRL](https://github.com/NovaSky-AI/SkyRL) agentic RL training.
## Dataset Description
- **Source:** [DCAgent/code-contests-sandboxes-with-tests](https://huggingface.co/datasets/DCAgent/code-contests-sandboxes-with-tests)
- **Original dataset:** [deepmind/code_contests](https://huggingface.co/datasets/deepmind/code_contests)
This dataset repackages the [CodeContests](https://github.com/google-deepmind/code_contests) competitive programming benchmark into the Harbor task format. Each row contains a task directory packed as a tar archive with instructions, environment (Dockerfile), and test verifiers suitable for agentic RL training with sandboxed execution.
## Schema
| Column | Type | Description |
|--------|------|-------------|
| `path` | string | Task identifier (e.g. "code_contests-0000") |
| `task_binary` | binary | Gzip-compressed tar archive of the task directory |
## Interacting with the Data
To explore the tasks locally, you can extract them into a readable format using the following commands (make sure `pyarrow` is installed):
```bash
curl -L -o extract_parquet_tasks.py \
"https://huggingface.co/datasets/open-thoughts/CodeContests/raw/main/extract_parquet_tasks.py"
curl -L -o tasks.parquet \
"https://huggingface.co/datasets/open-thoughts/CodeContests/resolve/main/tasks.parquet"
python extract_parquet_tasks.py tasks.parquet ./extracted_tasks
```
## Usage with SkyRL + Harbor
```bash
python examples/harbor/prepare_harbor_dataset.py --dataset open-thoughts/CodeContests
```
This will download and extract the tasks to `~/data/harbor/CodeContests/`.
## Citation
If you use this dataset, please cite the original CodeContests paper:
```bibtex
@article{li2022competition,
title={Competition-Level Code Generation with AlphaCode},
author={Li, Yujia and Choi, David and Chung, Junyoung and Kushman, Nate and Schrittwieser, Julian and Leblond, R{\'e}mi and Eccles, Tom and Keeling, James and Gimeno, Felix and Dal Lago, Agustin and Hubert, Thomas and Choy, Peter and de Masson d'Autume, Cyprien and Babuschkin, Igor and Chen, Xinyun and Huang, Po-Sen and Welbl, Johannes and Gowal, Sven and Cherepanov, Alexey and Molloy, James and Mankowitz, Daniel J. and Sutherland Robson, Esme and Kohli, Pushmeet and de Freitas, Nando and Kavukcuoglu, Koray and Vinyals, Oriol},
journal={Science},
volume={378},
number={6624},
pages={1092--1097},
year={2022},
publisher={American Association for the Advancement of Science},
doi={10.1126/science.abq1158}
}
```
And the OpenThoughts-Agent project:
```bibtex
@misc{openthoughts-agent,
author = {Team, OpenThoughts-Agent},
month = Dec,
title = {{OpenThoughts-Agent}},
howpublished = {https://www.openthoughts.ai/blog/agent},
year = {2025}
}
```
|