tmax-image-pool / README.md
osieosie's picture
Add README: document the four-directory plain-image layout
0c4e432 verified
|
Raw History Blame Contribute Delete
3.5 kB
---
license: other
tags:
- terminal-agent
- reinforcement-learning
- apptainer
---
# tmax image pool
Every Apptainer/SIF image referenced by the three `swerl-tmax-15k` variants, stored once
and shared between them.
## Read the layout from the repo, not from a prefix
**The plain images are split across four directories, not one.** A consumer that filters
on `images/` silently gets 4,519 fewer files and then reports itself complete — the
tasks that reference the missing blobs fail later, at sandbox start, one by one.
| directory | files |
|---|---:|
| `images/` | 9,971 |
| `images_b00/` | 1,933 |
| `images_b01/` | 2,000 |
| `images_b02/` | 586 |
| **plain, total** | **14,490** |
| `derived/` | 1,713 |
| **total SIFs** | **16,203** |
The batching exists only because HuggingFace enforces a hard limit of 10,000 files per
directory at push time; `images_b00..b02` are continuations of `images/` with no other
meaning. More batches may be added, so **enumerate whatever directories exist** rather
than hard-coding this list.
Resolve paths through `task_to_blob.json` instead of guessing — it already carries the
correct directory for every task.
## `task_to_blob.json`
Keyed by variant, then by task id, valued by the blob path within this repo:
```json
{
"original": {"task_000868_f0470dff": "images_b00/hamishi740__swerl-tmax-v3__17c682d5c609.sif", ...},
"hardened_prefilter": {...},
"solvable": {...}
}
```
| variant | tasks | unresolvable |
|---|---:|---:|
| `original` — [`hamishivi/swerl-tmax-15k`](https://huggingface.co/datasets/hamishivi/swerl-tmax-15k) | 14,601 | 0 |
| `hardened_prefilter` — [`wAI-org/swerl-tmax-15k-hardened-prefilter`](https://huggingface.co/datasets/wAI-org/swerl-tmax-15k-hardened-prefilter) | 13,565 | 0 |
| `solvable` — [`wAI-org/swerl-tmax-15k-solvable-gpt-5-6-terra`](https://huggingface.co/datasets/wAI-org/swerl-tmax-15k-solvable-gpt-5-6-terra) | 7,015 | 0 |
Tasks outnumber blobs because distinct tasks share an image.
## Plain vs derived
`images*/` are the registry images unchanged — a fresh `apptainer pull` of the original
reference is byte-identical to the stored SIF.
`derived/` are single-step derivations used by the hardened variants: an oracle file
removed, and/or the dependency the verifier imports installed, with per-task pinned
versions. A task in a hardened variant may map to either kind, so do not assume a
variant uses only one directory.
## Using it
```python
import json
from huggingface_hub import hf_hub_download, snapshot_download
m = json.load(open(hf_hub_download("wAI-org/tmax-image-pool", "task_to_blob.json",
repo_type="dataset")))
blobs = sorted(set(m["solvable"].values())) # only what this variant needs
snapshot_download("wAI-org/tmax-image-pool", repo_type="dataset",
allow_patterns=blobs, local_dir="sifs/")
```
Then point each row's `env_config.image` at the absolute local `.sif` path;
`prefer_local_sif()` passes an absolute path straight through with no registry lookup.
Fetching only one variant's blobs is much cheaper than the whole pool — `solvable` needs
6,968 of the 16,203.
## Verifying what you fetched
Check `apptainer inspect` on each distinct SIF a variant references. Size and hash
agreement is not sufficient: SIFs have been seen to match both and still not be valid
squashfs. Count coverage per variant against `task_to_blob.json` rather than trusting a
fetcher's own "done".