Datasets:
Publish crosscodeeval_v2 filtered by both models pass@16 results
Browse filesRetain 863 of 6710 v1 tasks solved by Qwen3-30B Instruct or Thinking; archive 5847 newly unsolved tasks alongside 1053 prior exclusions. Preserve all task payloads, reuse pinned v1 images, and expose per-model success counts and selection examples.
Files changed (5)
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384# CrossCodeEval v2
## Dataset stats
- **6,710 v1 tasks → 863 retained; 5,847 newly archived.** All 863 retain their v1 repairs; v2 changes no task instructions, environments, verifiers or reference solutions.- **7,763 original tasks: 863 retained and 6,900 archived**, including 1,053 earlier v1 exclusions.- **Images:** the original 3 image definitions were not consolidated. Retained tasks reuse the 3 [v1 cached images](https://huggingface.co/datasets/FWeindel/validated-tasks/tree/main/crosscodeeval_environment-reliable/cached_images), pinned by immutable revision and checksum in the Parquet. No image copies are needed in v2.
## Dataset characteristics
Cross-file code completion in C#, Java, Python and TypeScript, with related-file context and executable verifiers.
<details><summary>Domains</summary>
Software Engineering; Code Completion; Cross-file Repository Understanding.
</details>
<details><summary>Capabilities</summary>
Read related files, resolve identifiers, follow existing code patterns and complete missing statements.
</details>
**Likely transfer targets:** cross-file code completion and repository understanding.
## Pass@16 filtering
Keep a task if either model solved it at least once. Both models completed 16 attempts on every v1 task. Recorded terminal failures count as unsuccessful attempts; unsolved tasks are not necessarily defective.
| Model | Tasks evaluated | Attempts | Tasks solved at least once || --- | ---: | ---: | ---: || Qwen3-30B Instruct | 6,710 | 107,360 | 641 || Qwen3-30B Thinking | 6,710 | 107,360 | 627 || Either model | 6,710 | 214,720 | **863** |
Successful-attempt distribution **among the 863 retained tasks**. Each model column totals 863; rows with zero tasks for both models are omitted. A task with 0/16 for one model was solved by the other.
| Successful attempts | Instruct tasks | Thinking tasks || --- | ---: | ---: || 0/16 | 222 | 236 || 1/16 | 222 | 193 || 2/16 | 70 | 94 || 3/16 | 57 | 64 || 4/16 | 40 | 51 || 5/16 | 38 | 36 || 6/16 | 33 | 22 || 7/16 | 33 | 24 || 8/16 | 20 | 24 || 9/16 | 22 | 21 || 10/16 | 17 | 16 || 11/16 | 21 | 16 || 12/16 | 18 | 19 || 13/16 | 17 | 12 || 14/16 | 13 | 13 || 15/16 | 7 | 7 || 16/16 | 13 | 15 |
The retained tasks inherit v1's rule-based repairs, build checks, reference reward 1 and no-op reward 0. Teacher runs used the same task contents without the timeout/anti-cheating sentence; v2 preserves that v1 sentence. [V1 repair details](https://huggingface.co/datasets/FWeindel/validated-tasks/blob/main/crosscodeeval_environment-reliable/README.md) · [Teacher results](https://huggingface.co/datasets/FWeindel/validated-tasks/discussions/6).
## Select tasks by successful-attempt count
`tasks.parquet` includes `instruct_successes`, `thinking_successes` and `attempts_per_model` (16). Counts are also available in [selection.json](assets/selection.json). Earlier v1 archives have null teacher counts because they were not evaluated.
```pythonimport pyarrow.parquet as pq
# Exactly 1 successful attempt out of 16 for Instruct:filters = [("instruct_successes", "=", 1)]
# Alternatively, at least 3 successes for either model:# filters = [[("instruct_successes", ">=", 3)],# [("thinking_successes", ">=", 3)]]
subset = pq.read_table("tasks.parquet", filters=filters)pq.write_table(subset, "selected.parquet")```
`patch.py` reproduces the release from the pinned v1 Parquets and recorded counts.
## Runtime
- **Versions:** Apptainer **1.5.4**, Python **3.12.14**, Harbor **0.8.1**.- **Implementation:** [Marin Harbor `7faf878c14b6`](https://github.com/marin-community/harbor/tree/7faf878c14b6d72737579ec936ebf5f74ba3194d) + [our runtime patches](https://github.com/MLI-lab/OT-next-data/tree/main/harbor_patches).123version https://git-lfs.github.com/spec/v1oid sha256:cbfd98d499cb56d9c85c8ab2faf7ec97a30c8ed2699f487350ba4ae27c0b953asize 92382213123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136"""Reproduce CrossCodeEval v2 from pinned v1 Parquets and the recorded pass@16 results.
pip install pyarrow huggingface_hubpython patch.py --out ./rebuiltUse --source-dir PATH to reuse the two original v1 Parquets locally."""import argparseimport copyimport hashlibimport jsonimport ioimport tarfilefrom pathlib import Pathimport pyarrow as paimport pyarrow.parquet as pq
MODELS = {'instruct_successes': 'qwen3-30b-instruct-2507', 'thinking_successes': 'qwen3-30b-thinking'}
def rows(path): table = pq.ParquetFile(path) for i in range(table.num_row_groups): yield from table.read_row_group(i).to_pylist()
def restrict_images(manifest, names): result = copy.deepcopy(manifest) result['tasks'] = {k: v for k, v in manifest['tasks'].items() if k in names} bundles = {e['bundle'] for t in result['tasks'].values() for e in t['environments']} result['bundles'] = {k: v for k, v in manifest['bundles'].items() if k in bundles} result['missing'] = [] return result
def build(source_dir, out, selection_path): selection = json.loads(selection_path.read_text()) out.mkdir(parents=True, exist_ok=True) if any((out / n).exists() for n in ('tasks.parquet', 'archive.parquet')): raise ValueError('Output Parquets already exist; choose an empty output directory') sources = {} for name in ('tasks.parquet', 'archive.parquet'): if source_dir is None: from huggingface_hub import hf_hub_download path = Path(hf_hub_download(selection['repo_id'], selection['source_folder'] + '/' + name, repo_type='dataset', revision=selection['source_revision'], cache_dir=out / '.source-cache')) else: path = source_dir / name with path.open('rb') as handle: digest = hashlib.file_digest(handle, 'sha256').hexdigest() if digest != selection['source_sha256'][name]: raise ValueError('Pinned source hash mismatch: ' + name) sources[name] = path tasks = selection['tasks'] kept = {name for name, task in tasks.items() if task['kept']} assert len(tasks) == 6710 and len(kept) == 863 original_schema = pq.read_schema(sources['tasks.parquet']) image_manifest = json.loads(original_schema.metadata[b'ot.images.v1']) images = restrict_images(image_manifest, kept) assert set(images['tasks']) == kept release = {k: v for k, v in selection.items() if k != 'tasks'} release['selection_file'] = 'assets/selection.json' metadata = {b'ot.release.v2': json.dumps(release).encode(), b'ot.images.v1': json.dumps(images).encode()} schema = original_schema.remove_metadata().append(pa.field('instruct_successes', pa.int64())).append( pa.field('thinking_successes', pa.int64())).append(pa.field('attempts_per_model', pa.int64())).append(pa.field('archive_category', pa.string())) seen, audit = set(), {} with pq.ParquetWriter(out / 'tasks.parquet', schema.with_metadata(metadata), compression='zstd') as retain, \ pq.ParquetWriter(out / 'archive.parquet', schema.with_metadata({b'ot.release.v2': json.dumps(release).encode()}), compression='zstd') as archive: counts = {'retained': 0, 'newly_archived': 0, 'prior_archived': 0} for row in rows(sources['tasks.parquet']): name = row['path'] if name in seen or name not in tasks: raise ValueError('Duplicate or unexpected task: ' + name) seen.add(name) result = tasks[name] assert row['content_sha256'] == result['content_sha256'] for column, model in MODELS.items(): rewards = result['models'][model]['rewards'] assert len(rewards) == 16 and result['models'][model]['complete'] and result['models'][model]['missing'] == 0 row[column] = sum(reward >= 1 for reward in rewards) assert row[column] == result['models'][model]['solved_attempts'] row['attempts_per_model'] = 16 selected = row['instruct_successes'] > 0 or row['thinking_successes'] > 0 assert selected == result['kept'] audit[name] = {'binary_sha256': hashlib.sha256(row['task_binary']).hexdigest(), 'content_sha256': row['content_sha256'], 'kept': selected} if selected: row['stages_passed'] = ','.join(dict.fromkeys(row['stages_passed'].split(',') + ['6'])) retain.write_table(pa.Table.from_pylist([row], schema=schema.with_metadata(metadata))) counts['retained'] += 1 else: row['archive_stage'] = 6 row['archive_reason'] = 'pass16-unsolved: no successful attempt in 16 Instruct and 16 Thinking trials; this is not a confirmed task defect.' row['archive_labels'] = list(row.get('archive_labels') or []) + ['pass16-unsolved'] archive.write_table(pa.Table.from_pylist([row], schema=schema)) counts['newly_archived'] += 1 assert seen == set(tasks) for row in rows(sources['archive.parquet']): assert row['path'] not in seen seen.add(row['path']) # V1's original-source archive predates the validation columns. # Preserve its category and reason while computing its content hash. with tarfile.open(fileobj=io.BytesIO(row['task_binary']), mode='r:*') as archive_tar: files = [(str(Path(m.name)), archive_tar.extractfile(m).read()) for m in archive_tar.getmembers() if m.isfile()] digest = hashlib.sha256() for name, content in sorted(files): encoded = name.encode() digest.update(len(encoded).to_bytes(8, 'big')); digest.update(encoded) digest.update(len(content).to_bytes(8, 'big')); digest.update(content) row['content_sha256'] = digest.hexdigest() row['archive_stage'] = 0 row['stages_passed'] = '' for column in MODELS: row[column] = None row['attempts_per_model'] = None audit[row['path']] = {'binary_sha256': hashlib.sha256(row['task_binary']).hexdigest(), 'content_sha256': row['content_sha256'], 'kept': False} archive.write_table(pa.Table.from_pylist([row], schema=schema)) counts['prior_archived'] += 1 assert counts == {'retained': 863, 'newly_archived': 5847, 'prior_archived': 1053} checked = set() for filename, expected_kept in [('tasks.parquet', True), ('archive.parquet', False)]: for row in rows(out / filename): prior = audit[row['path']] assert row['path'] not in checked and prior['kept'] == expected_kept assert hashlib.sha256(row['task_binary']).hexdigest() == prior['binary_sha256'] assert row['content_sha256'] == prior['content_sha256'] checked.add(row['path']) assert checked == seen print(json.dumps(dict(counts, preserved_task_payloads=len(checked), cached_bundles_reused=len(images['bundles']))))
if __name__ == '__main__': parser = argparse.ArgumentParser(description=__doc__) parser.add_argument('--source-dir', type=Path) parser.add_argument('--out', type=Path, required=True) parser.add_argument('--selection', type=Path, default=Path(__file__).parent / 'assets' / 'selection.json') args = parser.parse_args() build(args.source_dir, args.out, args.selection)123version https://git-lfs.github.com/spec/v1oid sha256:21a25eac1b374c251f67f76e7abbb865435eeba329c7598ba210ba274d31f648size 11270178crosscodeeval_v2/README.mdAdded+84
crosscodeeval_v2/archive.parquetAdded+3
crosscodeeval_v2/assets/selection.jsonAdded
crosscodeeval_v2/patch.pyAdded+136
crosscodeeval_v2/tasks.parquetAdded+3