Commit Graph

406 Commits

Author SHA1 Message Date
iomgaa a4c429b247 chore: snapshot in-progress question-gen work before preflight fixes 2026-07-16 04:12:21 -04:00
iomgaa 11a5545f57 docs: address Codex design review (coverage matrix, salt/gate pairing, tier termination) 2026-07-16 03:52:50 -04:00
iomgaa d7e965639e docs: add preflight training-fixes design (23 bugs + wiring + split tuning) 2026-07-16 03:44:31 -04:00
iomgaa 57f590b57e test: integration for diagnosis tree_data link + core dep direction 2026-07-15 23:05:27 -04:00
iomgaa 224bb25bb5 fix: load real tree_data for training-loop diagnosis (runner)
算法保真 §4.7#12(训练循环编排):仅将 _run_diagnosis 内 tree_data={} 替换为
按 batch question_ids 涉及 video 加载真实树注入 run_diagnosis,未改动三级嵌套/
慢更新/断点续训/gate 等编排逻辑。覆盖 question_ids=None 全量诊断与
question_ids=[...] batch 两条路径。
2026-07-15 23:02:17 -04:00
iomgaa 8dedd082ff fix: self-contained tree-inject test + fail-loud on missing question (review) 2026-07-15 22:48:37 -04:00
iomgaa 83056688cf fix: load real tree_data for offline diagnosis (video_split_cli) 2026-07-15 22:38:23 -04:00
iomgaa f1b6865861 fix: include question_id in diagnosis tree-coverage fail-loud message 2026-07-15 22:33:23 -04:00
iomgaa c5fff7f8b3 fix: fail loud when diagnosis video tree not covered (algo #7 input) 2026-07-15 22:25:30 -04:00
iomgaa d6c595c4a4 fix: fail-loud on node without time info; anchor test store path 2026-07-15 22:16:39 -04:00
iomgaa 05294412df test: cover missing-id and non-list roots; drop unreachable empty-nodes guard 2026-07-15 22:11:36 -04:00
iomgaa e6adaad8b3 feat: add tree.json flattener for diagnosis ground_truth 2026-07-15 22:05:50 -04:00
iomgaa 748a969e0e docs: implementation plan for diagnosis tree_data fix 2026-07-15 22:01:20 -04:00
iomgaa 63dfee1b9b docs: design for diagnosis tree_data broken-link fix (TRM4 regression) 2026-07-15 21:44:42 -04:00
iomgaa 266a1ab4bc fix: use conda run --no-capture-output for unbuffered real-time logs 2026-07-15 14:02:13 -04:00
iomgaa 94728c5220 chore: set video-split diagnosis concurrency to 12 (overridable) 2026-07-15 13:57:59 -04:00
iomgaa 26ab536fea chore: migrate diagnosis prompts from TRM4 (rename to TRM5 loader filenames) 2026-07-15 13:53:16 -04:00
iomgaa 8fef7ced42 fix: address whole-impl review (INFRA T0 rows, reproducible manifest, evolution_target report, dead config, canonical DRY)
C-1: persist_infra_t0_rows 补 INFRA/空预测错题的 T0 信号行(不进诊断故须单独落库),run_pipeline 加 Phase 0,dry-run 用假数据走通。
C-2: CLI 加 --generated-at,真实运行默认盖真实 UTC now,可显式固定以字节级复现 manifest。
I-1: coverage_report 增 evolution_target_distribution(T2 信号按 tool/skill/system 计数)。
I-2: 删除 PoolConfig 死字段 n_trainval/floor_k/epsilon/report_floor/val_wrong_min(grep 确认无消费者,视频级切分用独立 VideoSplitConfig/SplitBuildConfig/SelectConfig)。
I-3: 抽共享 load_canonical_predictions(db_path, run_id),CLI 与 build_split 共用;消除 canonical 取行 + correct 判定重复。
M-1: build_split docstring 注明 val_wrong_min-agnostic 契约(McNemar 护栏由 CLI 冻结后执行,Task 11 契约)。
2026-07-15 13:39:14 -04:00
iomgaa 02b8145b7f fix: fail loud on diag model fingerprint drift vs .env SEARCH_LLM_MODEL
Codex CHANGES_REQUESTED 复审:
- Critical:diag_fingerprint 用 config.diag.model,但 Phase 1 诊断 LLM 从 .env
  SEARCH_LLM_MODEL 构建,两者不一致会让信号以错误模型指纹落库,破坏可复现/
  resume/隔离。build_diagnosis_deps 新增 expected_model 参数,Phase 1 执行前
  fail loud 校验 config.model == settings.search_llm_model(附两值)。
- Minor:config/video_split.yaml diag.model 注释由 JUDGE_LLM_MODEL 更正为
  SEARCH_LLM_MODEL,与实现对齐。
- 补两个单测:模型不一致 fail loud + 缺凭证 fail loud。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 13:20:51 -04:00
iomgaa 2844732126 refactor: self-contained two-phase video-split CLI entry
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 13:12:21 -04:00
iomgaa 6a21d80313 feat: add video-split config knobs and reproducible script 2026-07-15 12:54:25 -04:00
iomgaa 43d7346526 feat: wire end-to-end results-driven split with defensive asserts 2026-07-15 12:43:25 -04:00
iomgaa b497db97ba fix: guard floor phase against n_trainval budget + assert epsilon on output
Codex Task 8 审查修复:
- Important 1: _satisfy_floors 每步移入前检查预算,floor 需求超 n_trainval 时
  抛 InfeasibleSplitError(fail loud),保证 trainval 永不超额挤占 test;补预算超限测试。
- Important 2: 确定性测试末尾用 _epsilon_ok 断言产出 test 真满足 ε(两维偏差回归护栏),
  并断言 trainval <= n_trainval。
- Minor: fixture docstring 注明结构真实 / signal 二次构造,正式运行由真实诊断替换。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 12:38:33 -04:00
iomgaa c3187167c8 feat: add greedy joint-constrained split selector
两阶段贪心视频级切分:Floor 硬约束优先满足 + 多样性 submodular 覆盖最大化,
两阶段均带 ε 守护保 test 代表性;不可行 fail loud(InfeasibleSplitError),
多样性欠额记 loguru warning 不静默。derive_reportable_types 落地长尾报告门限。
确定性:Random(seed) 预洗牌打破等增益/等槽数平局,同 config 同 videos 同解。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 12:32:24 -04:00
iomgaa 84b0b30213 fix: dedup three-bucket projection + honest C3 error-handling note 2026-07-15 12:29:58 -04:00
iomgaa aa10485b9f fix: make pools.json freeze atomic + add split manifest 2026-07-15 12:28:48 -04:00
iomgaa fd907aab46 fix: extend correctness fail-fast to test-side pool questions (P5) 2026-07-15 12:22:11 -04:00
iomgaa 53989078a0 feat: add offline baseline diagnosis orchestration 2026-07-15 12:22:07 -04:00
iomgaa 3d8bd75372 feat: build all-video records with difficulty and signal overlay 2026-07-15 12:18:56 -04:00
iomgaa 20eea98cdd refactor: add video-atomic pool split (algo #5 gate input preserved) 2026-07-15 12:14:36 -04:00
iomgaa 9d19328cc9 feat: add signal tiering 2026-07-15 12:12:48 -04:00
iomgaa 75a2aac1c0 test: cover unknown error_type ValueError path 2026-07-15 12:10:24 -04:00
iomgaa 0a7ba724a9 feat: add evolution_target derivation and cell 2026-07-15 12:06:56 -04:00
iomgaa 3a8dd5c167 fix: add close/context-manager to diagnosis store; tighten import boundary 2026-07-15 12:06:29 -04:00
iomgaa 6b85fcbe1c feat: add baseline diagnosis signal store 2026-07-15 12:01:30 -04:00
iomgaa 01f2e7c7b9 feat: add steps_json-backed RunLog wrapper 2026-07-15 11:51:55 -04:00
iomgaa cf7f15d8bb feat: add steps_json to trace-row adapter 2026-07-15 11:47:00 -04:00
iomgaa 745b600b5d docs: register baseline_diagnosis and split_manifest schemas with baseline metrics 2026-07-15 11:42:38 -04:00
iomgaa cfa510a7e5 docs: add results-driven video-split implementation plan 2026-07-15 11:38:32 -04:00
iomgaa 312cee7be7 docs: add results-driven video-level split design 2026-07-15 11:17:45 -04:00
iomgaa f8ad8f0143 test: harden baseline_cache guard to per-call unit_id check 2026-07-15 10:13:33 -04:00
iomgaa a536a81b0d chore: apply ruff format to dead-path guard test 2026-07-15 10:07:19 -04:00
iomgaa 13234426b5 chore: guard perquestion revival + mark v2 tables deprecated 2026-07-15 10:06:13 -04:00
iomgaa e9349b55c0 test: add v3 pair-contract full-chain integration regression 2026-07-15 09:57:39 -04:00
iomgaa 58a84dc72b refactor: add CHECK constraints and drop redundant index in v3 tables 2026-07-15 09:47:00 -04:00
iomgaa 3cc8dc9105 refactor: assert warn sink, rename disk-pair sifter, trim WHAT docstrings
Capture loguru warning via project sink pattern and assert the dangling-orphan
warning is emitted; rename _sift_disk_pairs to _keep_complete_disk_pairs; drop
pure-WHAT docstrings on __init__/pending_orphans while keeping WHY notes.
2026-07-15 09:42:27 -04:00
iomgaa 5ecbac620c feat: add v3 question-gen observation tables to run_store 2026-07-15 09:33:40 -04:00
iomgaa 1ecb6ba25c fix: fail-loud on disk-corrupt pairs and preserve buffer on reject
read_accepted now distinguishes size==1 dangling orphans (warn+drop) from
structural corruption / role duplication (raise), and runs explicit binding
checks (video_id/task_type/flip_axis) that survive python -O. add() validates
before evicting the buffered partner so pending_orphans can recover it.
2026-07-15 09:31:42 -04:00
iomgaa bdcc93d7de feat: add pair atomic accepted-bank writer helper
PairPendingBuffer collects pair members by pair_id and emits units;
write_accepted does tmp+os.replace atomic write; read_accepted rebuilds
units and drops disk-dangling orphans. Pure helper; on_accept wiring is
Phase 2 (real write point: adversarial_filter.write_final_bank).
2026-07-15 09:22:41 -04:00
iomgaa 19911e18e0 test(harness): 黄金测试加非空护栏、补类型注解、端到端对照旧逻辑
回应 Codex 审查三项测试质量问题:
- C1: 每个 byte-identical 断言前加非空护栏(sum(len)>0 / len==samples>0),
  防空==空误通过。
- I1: TestBatchingByteIdentical._assert 补齐完整类型注解。
- I2: 端到端 checkpoint 用例增加 _reference_build_batches 对照,断言真实池划分
  →batching 与旧逐题逻辑逐字节一致(不只是 rebuilt==batches 自往返)。
2026-07-15 08:28:12 -04:00