Skip to content

feat(assemble): replay sources survive the verdict gate - dataset v2 - #142

Merged
log0u7 merged 2 commits into
mainfrom
feat/mr6-v2-replay
Nov 4, 2026
Merged

log0u7 merged 2 commits into
mainfrom
feat/mr6-v2-replay

Conversation

@log0u7

@log0u7 log0u7 commented Nov 4, 2026

Copy link
Copy Markdown
Owner

Summary

Dataset v1 shipped with ZERO replay records: the failed-trajectory gate silently ejected the whole teacher corpus (ctf-big, ctf-distill, ctf-first*) and the anti-forgetting mix never reached the training file. This adds --replay-source to scripts/assemble_sft_mr6.py (skips the verdict gate + per-id cap; every other gate still applies), and wires datasets/sft-mr6-v2/train.jsonl into scripts/run_final_bench.sh TRAIN_IDS so the clean derivation drops uaf_heap-002 from eval automatically (sacrifice ledger rides the dataset).

Also: 2 eval-leaked teacher records (ctf-lictor-uaf_heap-001 in ctf-first.jsonl/batch1) are dropped by the contamination gate - replay is not exempt.

Tests (mandatory)

TDD red-green: test_replay_source_records_kept_without_verdicts (red first: the gate dropped all 5 replay records), test_replay_sources_skip_the_per_target_cap, test_replay_source_eval_contamination_still_refused (red first: the gate let the eval leak through). All green after the fix: pytest tests/unit/test_assemble_sft_mr6.py 11 passed. Files: tests/unit/test_assemble_sft_mr6.py.

Linked Issue

No issue. Scope: MR6 dataset v2 (levier 1 replay) - the consolidation retrain needs the replay mix; without it the retrain re-creates catastrophic forgetting.

Quality Checklist

  • I wrote the failing test first (red), then made it pass (green)
  • I ran the lint check (ruff clean)
  • I ran the test suite (11 passed in test_assemble_sft_mr6.py)
  • I ran the build (make lint + mypy clean)
  • I updated CHANGELOG.md under [Unreleased]
  • This change is focused and avoids unrelated behavior changes
  • I updated docs when user-facing workflow changed (datasets/eval/README.md)

The v1 MR6 dataset shipped with ZERO replay records: the failed-
trajectory gate (MR5 lesson, aimed at rollout records) silently
ejected the whole teacher corpus (ctf-big, ctf-distill, ctf-first*),
and the anti-forgetting mix the consolidation cycle needs never made
it into the training file. The retrain then re-created exactly the
forgetting failure the replay exists to prevent.

- assemble_sft_mr6.py: --replay-source (repeatable). Replay records
  skip the failed-trajectory gate AND the per-id cap (teacher-
  namespace IDs), every other gate still applies: contamination
  (2 eval-leaked ctf-lictor-uaf_heap-001 teacher records dropped,
  exit nonzero), class-fact, excluded targets, empty share.
- run_final_bench.sh: the v2 file joins TRAIN_IDS - the derivation
  drops uaf_heap-002 from the eval automatically (the sacrifice
  ledger rides the dataset), eval set after v2 = 10 challenges.
- datasets/eval/README.md: the v2 section documents the contract.

TDD: test_replay_source_records_kept_without_verdicts (red: the gate
dropped all 5), test_replay_sources_skip_the_per_target_cap,
test_replay_source_eval_contamination_still_refused (red: the gate
let the eval leak through). All green after the fix.
@log0u7
log0u7 merged commit 252a559 into main Nov 4, 2026
8 checks passed
@log0u7
log0u7 deleted the feat/mr6-v2-replay branch November 4, 2026 13:55
@log0u7 log0u7 mentioned this pull request Nov 4, 2026
7 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant