# Handoff: Make COLLAB > INDEP at end-to-end EX (target ≥1pp, stretch ≥2pp)
## The problem in one line
Our paper-format ORPO **validator-internal reward-accuracy** strongly favors COLLAB over INDEP
(+10pp on val-sel, +17.7pp on val-cond), but **end-to-end selector EX is identical** (COLLAB 59.97% vs INDEP 60.31% — INDEP is actually 0.34pp ahead). The collab training signal isn't translating to pipeline gains.
**Your goal**: lift the COLLAB pipeline's selector EX so that it **beats INDEP by ≥1pp** (stretch goal: ≥2pp gap) on full BIRD-dev (1524 questions).
This must show in the **pipeline metric the paper cares about** (`compute_bestofn_with_selector.py` trained selector EX), not just the validator-internal `eval_rewards/accuracies`.
---
## 1. Current ground truth (full BIRD-dev, 1524 questions)
| Config | planner@1 (T=0) | pipeline@1 (T=0) | oracle pass@8 | **trained selector EX** |
|---|---|---|---|---|
| PLANNER-only | **51.54%** | 51.54% | 70.80% | — |
| SFT-VF (paper validators, no ORPO) | 51.48% | 52.20% | 71.65% | **59.91%** |
| **ORPO iter1 COLLAB** | 51.08% | 51.81% | 71.19% | **59.97%** |
| **ORPO iter1 INDEP** | 51.74% | 52.59% | 71.95% | **60.31%** |
Validator-internal reward accuracies (test_dpo split, what ORPO optimizes):
| Validator | eval_loss | eval_rewards/accuracies |
|---|---|---|
| **val-sel COLLAB** | 0.174 | **69.7%** |
| val-sel INDEP | 0.210 | 59.7% |
| **val-cond COLLAB** | 0.148 | **89.7%** |
| val-cond INDEP | 0.163 | 72.0% |
**Reading the gap**: COLLAB's chosen/rejected discrimination training succeeded, but at inference the chosen "correct" critiques don't lead to materially different fixer outputs (or different pipeline EX) than INDEP's.
---
## 2. Why collab SHOULD be better than indep (paper Alg. 2 intuition)
| Mode | What "chosen" means | What signal it carries |
|---|---|---|
| **INDEP** | critique whose `Conclude:` matches a HEURISTIC over planner-vs-gold correctness | Local: was the critique text consistent with whether planner was correct? Surface-level. |
| **COLLAB** | critique that, when fed to the fixer, produces a correct final SQL | End-to-end: did this critique HELP the downstream fixer produce correct SQL? |
If the fixer **actually uses critique content**, COLLAB's signal carries downstream-aware information INDEP doesn't have. If the fixer **ignores critique**, COLLAB signal collapses to noise + the fixer's intrinsic correctness, and INDEP wins on cleaner labels.
---
## 3. Diagnosis: why our collab signal is currently weak
Three structural issues identified in this session — partially mitigated, not fixed:
### 3.1 The fixer was trained on a FIXED critique template
[`build_orpo_data.py:245`](https://huggingface.co/datasets/thanhdath/mats-sql-bundle/blob/main/scripts/build_orpo_data.py) (in the snapshot uploaded to `thanhdath/mats-sql-bundle/scripts/`):
```python
val_critique = "\n\n\nCONDITION.\nINCORRECT\n"
```
Every fixer SFT example uses this **identical** critique. The fixer never learned to condition its output on critique content. At collab data-gen time we feed K=4 *diverse* critiques per question, but the fixer's output is largely invariant to the critique — so chosen vs rejected critiques produce near-identical fixer SQLs → ORPO sees a low-information signal.
**Evidence**: collab pair-formation rate is 0.33 pairs/question (650 pairs from 2000 q) vs independent's 1.78 pairs/question (3565 pairs from 2000 q). The fixer judging step is collapsing — most critiques bucket identically.
### 3.2 Data-gen flow ≠ inference flow
At collab data-gen, the fixer runs for EVERY critique regardless of what the critique says. At inference, the fixer is gated by `planner_exec_ok=False`. This mismatch means the collab training distribution doesn't reflect how the validator actually contributes at inference (where it primarily votes "this candidate is good / bad" rather than steering a per-call fixer rewrite).
We added a `collab_v2` mode in `build_orpo_data.py` (`--mode collab_v2`) that simulates inference: critique-says-`Conclude:correct` → keep planner SQL; else → run fixer; chosen/rejected by end-to-end correctness. **It hasn't been used to retrain validators yet** — that's the obvious next experiment.
### 3.3 Small K + small dataset
`build_orpo_data.py` uses K=4 critiques per question in our runs. With paper-format validators that are already fairly calibrated, 4 critiques often land in the same bucket → 0 pairs for that question. Net pair yield is low for COLLAB.
---
## 4. Concrete experiments to flip the gap (ranked by ROI)
### E1. **Train a CRITIQUE-AWARE fixer** ⭐ highest ROI
The biggest single thing keeping COLLAB ≈ INDEP. Rebuild the fixer SFT data so each example has a DIFFERENT critique:
```
For each BIRD-train question with planner_exec_ok=False:
Generate K=4 validator critiques (val-sel + val-cond, paper-format)
For each critique:
Run fixer at T=1.0, get fix_sql
Score correctness
Form (critique, fix) pairs:
chosen = (good_critique, correct_fix)
rejected = (bad_critique, wrong_fix)
Save with critique embedded in the prompt.
```
Then ORPO-train the fixer on this data. Now the fixer LEARNS to use critique content.
When the fixer becomes critique-aware, **collab's "fixer-judged chosen/rejected" signal becomes informative** (different critiques → different fix outputs → different correctness labels), so retraining COLLAB validators on iter2 data will discriminate better than INDEP.
Builder skeleton lives in [`scripts/build_orpo_data.py:build_fixer_data`](models/fixer-1B-orpo-iter1) — currently uses the fixed critique. Replace `val_critique = "