MBPP for code RL, deduplicated against MBPP+ (320 train / 378 MBPP+ / 276 heldout)
Browse files- README.md +91 -0
- data/heldout_mbpp_test.parquet +3 -0
- data/test.parquet +3 -0
- data/train.parquet +3 -0
README.md
ADDED
|
@@ -0,0 +1,91 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: cc-by-4.0
|
| 3 |
+
task_categories:
|
| 4 |
+
- text-generation
|
| 5 |
+
language:
|
| 6 |
+
- en
|
| 7 |
+
tags:
|
| 8 |
+
- code
|
| 9 |
+
- rlvr
|
| 10 |
+
- reinforcement-learning
|
| 11 |
+
- mbpp
|
| 12 |
+
- verl
|
| 13 |
+
size_categories:
|
| 14 |
+
- n<1K
|
| 15 |
+
configs:
|
| 16 |
+
- config_name: default
|
| 17 |
+
data_files:
|
| 18 |
+
- split: train
|
| 19 |
+
path: data/train.parquet
|
| 20 |
+
- split: test
|
| 21 |
+
path: data/test.parquet
|
| 22 |
+
- split: heldout_mbpp_test
|
| 23 |
+
path: data/heldout_mbpp_test.parquet
|
| 24 |
+
---
|
| 25 |
+
|
| 26 |
+
# MBPP for code RL (deduplicated against MBPP+)
|
| 27 |
+
|
| 28 |
+
MBPP prepared for RLVR training in [verl](https://github.com/volcengine/verl),
|
| 29 |
+
with **two independent hold-outs** so both MBPP+ and MBPP's own canonical test
|
| 30 |
+
split stay reportable after training on this data.
|
| 31 |
+
|
| 32 |
+
| split | rows | contents |
|
| 33 |
+
|---|---|---|
|
| 34 |
+
| `train` | 320 | MBPP canonical train + validation + prompt, minus everything in MBPP+ |
|
| 35 |
+
| `test` | 378 | exactly the problems in [`evalplus/mbppplus`](https://huggingface.co/datasets/evalplus/mbppplus) |
|
| 36 |
+
| `heldout_mbpp_test` | 276 | MBPP's canonical test split (task_id 11-510) that is *not* in MBPP+ |
|
| 37 |
+
|
| 38 |
+
## Why 320 and not 974
|
| 39 |
+
|
| 40 |
+
MBPP `full` is 974 problems across four canonical splits (prompt 10, test 500,
|
| 41 |
+
validation 90, train 374). Two things are removed from the training pool:
|
| 42 |
+
|
| 43 |
+
1. **Everything in MBPP+** (378 problems). MBPP+ is derived from MBPP-sanitized
|
| 44 |
+
and consumes 378 of that config's 427 problems.
|
| 45 |
+
2. **MBPP's canonical test split.** Deduplicating against MBPP+ alone would
|
| 46 |
+
leave 596 training problems, but 276 of those are canonical MBPP test — fine
|
| 47 |
+
if MBPP+ is your only benchmark, fatal if you ever want standard MBPP numbers.
|
| 48 |
+
|
| 49 |
+
Deduplicating MBPP-**sanitized** against MBPP+ leaves only **49** problems,
|
| 50 |
+
which is why the sanitized config alone is not viable for training. Each problem
|
| 51 |
+
here uses its *sanitized* text and corrected tests where one exists (427 of 974
|
| 52 |
+
do) while keeping the other 547 — sanitized quality at usable size.
|
| 53 |
+
|
| 54 |
+
Leakage is asserted at build time: no train `task_id` appears in MBPP+, and no
|
| 55 |
+
train row comes from a withheld split.
|
| 56 |
+
|
| 57 |
+
## Format
|
| 58 |
+
|
| 59 |
+
verl RLHF layout: `data_source`, `prompt`, `ability`, `reward_model`, `extra_info`.
|
| 60 |
+
|
| 61 |
+
`reward_model.ground_truth` is a **JSON string**:
|
| 62 |
+
|
| 63 |
+
```json
|
| 64 |
+
{"assert_case": ["assert floor_Min(10,20,30) == 15", "..."]}
|
| 65 |
+
```
|
| 66 |
+
|
| 67 |
+
The verifier dispatches on the *keys* of that dict, so one reward path handles
|
| 68 |
+
MBPP asserts and competitive-programming stdin/stdout with no dataset-specific
|
| 69 |
+
routing. Setup imports (`test_setup_code` / `test_imports`) are folded into each
|
| 70 |
+
assert string, because every test runs as a standalone script:
|
| 71 |
+
`solution + "\n" + assert_case[i]`.
|
| 72 |
+
|
| 73 |
+
The prompt is a two-turn chat whose system message matches the math/kk runs of
|
| 74 |
+
the same study, so prompt format is not a confound across tasks:
|
| 75 |
+
|
| 76 |
+
```
|
| 77 |
+
system: Please reason step by step and put your final solution in a single ```python code block.
|
| 78 |
+
user: <task> + half the tests as an interface hint + fenced-block instruction
|
| 79 |
+
```
|
| 80 |
+
|
| 81 |
+
Half the tests (`floor(N/2)`) are shown so the model can infer the function name
|
| 82 |
+
and signature; **all** tests are used for reward.
|
| 83 |
+
|
| 84 |
+
## Validation
|
| 85 |
+
|
| 86 |
+
All 974 MBPP reference solutions score 1.0 through the verifier.
|
| 87 |
+
|
| 88 |
+
## Sources
|
| 89 |
+
|
| 90 |
+
- [`google-research-datasets/mbpp`](https://huggingface.co/datasets/google-research-datasets/mbpp) (configs `full` and `sanitized`)
|
| 91 |
+
- [`evalplus/mbppplus`](https://huggingface.co/datasets/evalplus/mbppplus)
|
data/heldout_mbpp_test.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8749b790e12913372c5a3bdbc9701a4c12bd431ab9f6ed5b5fbe844e75e39406
|
| 3 |
+
size 62264
|
data/test.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:7e5b78d660746c69674a345cececc812459e6f381ce9de3683702d30c61a3e6e
|
| 3 |
+
size 82958
|
data/train.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a227e2853c9ee12e0367e875dd436b3b7491663b060e034a3015cbd9d957df6d
|
| 3 |
+
size 73303
|