LinRongCai commited on
Commit
ad4f8db
·
verified ·
1 Parent(s): 72ba979

card: shorter

Browse files
Files changed (1) hide show
  1. README.md +34 -77
README.md CHANGED
@@ -40,32 +40,51 @@ configs:
40
  <a href="https://huggingface.co/datasets/zlab-princeton/XStack/tree/main/traces">📊 Agent traces</a>
41
  </p>
42
 
43
- ## Overview
44
-
45
  <p align="center">
46
  <img src="pipeline.png" alt="The agent gets the PyTorch source, a TPU machine and the prompt and hands in a JAX repository; a fresh machine grades it against the source's published result, two judges read the transcript, and a failed blind turn gets one frozen phase-2 turn." width="100%">
47
  </p>
48
 
49
- XStack asks a coding agent to migrate a whole machine-learning repository from PyTorch to JAX and make it work at the source's own scale. Each of the 20 tasks is a real repository at a pinned commit. The agent gets the source tree, a bare TPU machine and one prompt that is the same for every task; it is never told the metric, the bar or the dataset. A fresh machine then runs the migration at full scale, the headline number is compared with the source's published result, two judges read the transcript, and the exported weights must load into the source model. A failed blind turn gets one more turn with the code frozen and the recipe stated.
50
 
51
  <p align="center">
52
  <img src="teaser.png" alt="Pass rate per agent over the 20 repositories. Claude Opus 5 passes 75%, GPT-5.6-sol 45%, every other agent at most 40%." width="90%">
53
  </p>
54
 
55
- Over 20 repositories and 7 agents, Claude Opus 5 passes 75% of the tasks, GPT-5.6-sol 45%, and every other agent at most 40%. Every run is in this dataset, under [`traces/`](https://huggingface.co/datasets/zlab-princeton/XStack/tree/main/traces).
 
 
56
 
57
- ## Quickstart
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
58
 
59
  ```python
60
  from datasets import load_dataset
 
61
 
62
- tasks = load_dataset("zlab-princeton/XStack", split="test")
63
- task = tasks[0]
64
- print(task["source_repo"], task["source_commit"]) # https://github.com/karpathy/minGPT 37baab7...
65
- print(task["prompt"][:200]) # the phase-1 prompt the agent receives
 
 
 
66
  ```
67
 
68
- Give the agent `prompt`, the repository at `source_commit` and a TPU machine it sets up itself. Keep `criteria` and `phase2` out of its workspace; `phase2` is sent only after a failed blind turn. The [harness](https://github.com/zlab-princeton/XStack) does all of this and grades the result.
69
 
70
  ## Tasks
71
 
@@ -92,77 +111,15 @@ Give the agent `prompt`, the repository at `source_commit` and a TPU machine it
92
  | `patchtst` | time-series forecasting | [PatchTST @ 204c21e](https://github.com/yuqinie98/PatchTST/tree/204c21efe0b39603ad6e2ca640ef5896646ab1a9) |
93
  | `tabr` | tabular learning | [TabR @ 17baa90](https://github.com/yandex-research/tabular-dl-tabr/tree/17baa9082506f8e7a0f8d11bb1e08212926a1507) |
94
 
95
- ## Fields
96
 
97
  | Field | Meaning |
98
  |---|---|
99
  | `task_id`, `name`, `domain` | The task, its display name and what the repository does |
100
- | `source_repo`, `source_commit`, `source_at_commit`, `source_license` | The repository, the pinned commit, a link to the tree at that commit and its license |
101
- | `source_drop`, `source_tree_sha256` | Paths removed from the vendored tree, and a hash of the file list to verify a fetch |
102
- | `prompt`, `contract_lines` | The phase-1 prompt, verbatim, and its task-specific lines (empty for 16 tasks) |
103
- | `phase2` | The phase-2 message, verbatim: the recipe, never the bar |
104
- | `pipeline`, `graded_quantity`, `bar`, `bar_cmp`, `bar_value`, `bar_value_2`, `bar_kind` | What is graded and the bar (`at least` or `at most` a value, or a band), and where the bar comes from |
105
- | `dataset`, `seed`, `grade_cmd`, `expected_grade_wall_h` | What the grading machine runs and how long it takes |
106
- | `criteria` | The hidden grading criteria: metric pattern, dataset pattern, bar and its provenance, grade command, phase-2 recipe |
107
-
108
- ## Migrations
109
-
110
- `migrations/<task_id>.tar.gz` holds the seven agents' hand-ins for one task: the workspace at the end of each cell's last turn, code and text files only, one folder per model, and a `manifest.json` with each cell's verdict and its folder under `traces/`. Vendored source, data, checkpoints, exported weights and binaries are not included.
111
-
112
- ```python
113
- from huggingface_hub import hf_hub_download
114
- import tarfile
115
-
116
- path = hf_hub_download("zlab-princeton/XStack", "migrations/nanogpt.tar.gz", repo_type="dataset")
117
- tarfile.open(path).extractall("nanogpt_migrations") # nanogpt_migrations/claude-opus-5/run_train.py, ...
118
- ```
119
-
120
- ## Agent traces
121
-
122
- `traces/` holds every run behind the paper: 140 cells, 7 agents on 20 tasks, one cell per agent and task. A cell holds the prompt the agent saw, its full transcript, its closing message per turn, the migration it handed in, the grade log and metrics of each turn, the judges' answers and the verdict. A cell passes when the migration reaches the source's published result on a fresh TPU machine, both judges accept it and the exported weights load into the source model. A failed blind turn gets one phase-2 turn with the code frozen and the recipe stated; passing in either turn counts.
123
-
124
- | Model | Harness | Passes | Pass rate |
125
- |---|---|---:|---:|
126
- | `claude-opus-5` | Claude Code | 15/20 | 75% |
127
- | `gpt-5.6-sol` | Codex | 9/20 | 45% |
128
- | `deepseek-v4.1-flash` | Claude Code | 8/20 | 40% |
129
- | `glm-5.3-flash` | Claude Code | 5/20 | 25% |
130
- | `muse-spark-1.3` | Claude Code | 4/20 | 20% |
131
- | `gpt-5.6-terra` | Codex | 2/20 | 10% |
132
- | `gpt-5.6-luna` | Codex | 1/20 | 5% |
133
-
134
- `traces/cells.csv` (also `cells.parquet`, the `traces` config, split `cells`) has one row per cell: the model, harness and task, the machine, the verdict of each turn, the weight-load check and its tensor counts, the failure class, wall hours, token counts and cost, and the link to the cell's folder.
135
-
136
- ```python
137
- from huggingface_hub import hf_hub_download, snapshot_download
138
- import pandas as pd
139
-
140
- repo = "zlab-princeton/XStack"
141
- cells = pd.read_csv(hf_hub_download(repo, "traces/cells.csv", repo_type="dataset"))
142
-
143
- cell = cells.query("model == 'claude-opus-5' and repo == 'nanogpt'").iloc[0]
144
- path = snapshot_download(repo, repo_type="dataset", allow_patterns=f"traces/cells/{cell.cell_id}/*")
145
- ```
146
-
147
- The traces are about 2 GB in 2,800 files; `snapshot_download(repo, repo_type="dataset", allow_patterns="traces/*")` fetches all of them.
148
-
149
- ```text
150
- traces/cells/<run>/<model>_<effort>/<task>_e2e/
151
- meta.json The cell's record: machine, timing, verdicts
152
- prompt.txt The phase-1 prompt the agent saw
153
- phase2.txt The phase-2 message, when a phase 2 ran
154
- turns.jsonl One line per turn: status and verdict
155
- trajectory.jsonl The agent's transcript, both turns in order
156
- final_message_turnN.txt The agent's closing message of turn N
157
- tokens_cum_turnN.json Token usage up to turn N
158
- entry_diff_turn2.patch The phase-2 diff of run_train.py
159
- migration_final.tar.gz The migration the agent handed in: code and text files only
160
- grade/ The metrics file and the last 400 log lines of each graded turn
161
- readers/ The failure judge's answers (failure_analysis.*)
162
- judges/<trial>/answer.txt The judge runs: correctness judge (strict22_sol_r1..3), cheat judge (cheat22_sol_r1..3); `_t2_` trials for a judged phase-2 turn
163
- ```
164
-
165
- The transcript is the Codex CLI rollout for the Codex agents and the Claude Code stream-json trace for the others. Credential values, token-shaped strings, IP addresses and our cluster's names and paths are replaced by placeholders such as `<REDACTED-TOKEN>` and `<scratch>`; nothing else was edited.
166
 
167
  ## License
168
 
 
40
  <a href="https://huggingface.co/datasets/zlab-princeton/XStack/tree/main/traces">📊 Agent traces</a>
41
  </p>
42
 
 
 
43
  <p align="center">
44
  <img src="pipeline.png" alt="The agent gets the PyTorch source, a TPU machine and the prompt and hands in a JAX repository; a fresh machine grades it against the source's published result, two judges read the transcript, and a failed blind turn gets one frozen phase-2 turn." width="100%">
45
  </p>
46
 
47
+ XStack asks a coding agent to migrate a whole machine-learning repository from PyTorch to JAX and make it work at the source's own scale. Each of the 20 tasks is a real repository at a pinned commit. The agent gets the source, a bare TPU machine and one prompt, and is never told the metric, the bar or the dataset. A fresh machine runs the migration at full scale and compares its headline number with the source's published result, two judges read the transcript, and the exported weights must load into the source model. A failed blind turn gets one more turn with the code frozen and the recipe stated.
48
 
49
  <p align="center">
50
  <img src="teaser.png" alt="Pass rate per agent over the 20 repositories. Claude Opus 5 passes 75%, GPT-5.6-sol 45%, every other agent at most 40%." width="90%">
51
  </p>
52
 
53
+ Seven agents on the 20 tasks: Claude Opus 5 passes 75%, GPT-5.6-sol 45%, every other agent at most 40%. Every run is in this dataset.
54
+
55
+ ## What is here
56
 
57
+ ```text
58
+ data/test.parquet the 20 tasks: source, pinned commit, prompt, phase-2 message, hidden criteria
59
+ migrations/<task>.tar.gz the seven agents' hand-ins for one task, one folder per model, with a manifest
60
+ traces/cells.parquet one row per run: model, task, verdicts, weight-load check, failure class, tokens, cost
61
+ traces/cells/<run>/<model>_<effort>/<task>_e2e/
62
+ prompt.txt, phase2.txt what the agent was told
63
+ trajectory.jsonl the full transcript, both turns
64
+ migration_final.tar.gz the hand-in: code and text files only
65
+ grade/ the metrics file and the log tail of each graded turn
66
+ judges/, readers/ the correctness and cheat judges' answers (three runs each), the failure judge's answer
67
+ meta.json, turns.jsonl the cell's record and the verdict of each turn
68
+ ```
69
+
70
+ `data/test.parquet` is the default config (split `test`); `traces/cells.parquet` is the `traces` config (split `cells`); both also exist as `test.jsonl` and `cells.csv`. The traces are about 2 GB in 2,800 files. Transcripts are the Codex CLI rollout for the Codex agents and the Claude Code stream-json trace for the others. Credential values, token-shaped strings, IP addresses and our cluster's names and paths are replaced by placeholders such as `<REDACTED-TOKEN>` and `<scratch>`; nothing else was edited.
71
+
72
+ ## Load
73
 
74
  ```python
75
  from datasets import load_dataset
76
+ from huggingface_hub import hf_hub_download, snapshot_download
77
 
78
+ repo = "zlab-princeton/XStack"
79
+ tasks = load_dataset(repo, split="test") # 20 tasks
80
+ cells = load_dataset(repo, "traces", split="cells") # 140 runs
81
+
82
+ cell = next(c for c in cells if c["model"] == "claude-opus-5" and c["repo"] == "nanogpt")
83
+ snapshot_download(repo, repo_type="dataset", allow_patterns=f"traces/cells/{cell['cell_id']}/*") # one run
84
+ hf_hub_download(repo, "migrations/nanogpt.tar.gz", repo_type="dataset") # one task's seven hand-ins
85
  ```
86
 
87
+ To run an agent on a task, give it `prompt`, the repository at `source_commit` and a TPU machine it sets up itself. Keep `criteria` and `phase2` out of its reach; `phase2` is sent only after a failed blind turn. The [harness](https://github.com/zlab-princeton/XStack) does this and grades the result.
88
 
89
  ## Tasks
90
 
 
111
  | `patchtst` | time-series forecasting | [PatchTST @ 204c21e](https://github.com/yuqinie98/PatchTST/tree/204c21efe0b39603ad6e2ca640ef5896646ab1a9) |
112
  | `tabr` | tabular learning | [TabR @ 17baa90](https://github.com/yandex-research/tabular-dl-tabr/tree/17baa9082506f8e7a0f8d11bb1e08212926a1507) |
113
 
114
+ ## Fields of a task
115
 
116
  | Field | Meaning |
117
  |---|---|
118
  | `task_id`, `name`, `domain` | The task, its display name and what the repository does |
119
+ | `source_repo`, `source_commit`, `source_at_commit`, `source_license`, `source_drop`, `source_tree_sha256` | The repository, the pinned commit and a link to it, its license, the paths not vendored, and a hash of the file list |
120
+ | `prompt`, `contract_lines`, `phase2` | The phase-1 prompt and its task-specific lines, and the phase-2 message, all verbatim |
121
+ | `pipeline`, `graded_quantity`, `bar`, `bar_cmp`, `bar_value`, `bar_value_2`, `bar_kind` | What is graded, the bar (`at least` or `at most` a value, or a band) and where it comes from |
122
+ | `dataset`, `seed`, `grade_cmd`, `expected_grade_wall_h`, `criteria` | What the grading machine runs, how long it takes, and the hidden criteria in full |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
123
 
124
  ## License
125