data-gen-ebd/docs/artifacts.md
amos b773033658 Record model requests and payloads as prefix deltas in the native trace
Each model_request/model_payload repeated the full context, so the trace
grew with the square of the request count: batch 6 Qwen runs hit 64 MiB
at ~75 requests and 14 attempts (13 graded PASS) were discarded.
Requests now record only items after the common prefix with the previous
one (schema embedded-rollout.pi/2), and pi_run.expand rebuilds full
payloads before the unchanged broker/feedback checks. Needs a new image
(trace6) and recalibration before use.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-18 10:50:56 +08:00

14 lines
2.0 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 轨迹归档合同
本步骤把已完成并复核的单次 Pi rollout 封存为一个 `.tar.gz` 文件,便于保存到 Salty 唯一目录。今后每份归档还包含 [五字段任务 JSONL](data-format.md),不执行模型训练,不新增数据库或上传服务。
入口:`python3 -m rollout.archive CONTROLLER --task TASK --output ARCHIVE.tar.gz`。只接收清理已确认、Agent 正常结束且原生证据 VERIFIED 的 PASS/FAIL 尝试;真实任务失败也可成为完整轨迹,中断与基础设施故障不能混入。
归档前重新核对任务/镜像/校准回执、冻结候选摘要、host stdout 与 native trace、broker 请求摘要和工具反馈。pi/2 轨迹的 model request/payload 是前缀增量,原样封存;核对时先重建每次全量 payload 再比对 broker 摘要,读取方须用 `rollout.pi_run.expand` 同法重建。只显式包含公开题面/template 初态、全部 `candidate_files` 的最终候选、控制与评分回执、监督事件、原生轨迹和 broker 记录;不递归打包工作区、grader、gold、凭据或项目目录。
新增 `dataset.jsonl` 为固定任务行,来自作者冻结并核对 task/verifier 摘要的 `dataset.json`;无该快照的任务记 `call_type=verifier`,见 [数据合同](data-format.md),manifest 的 `dataset_call_type` 与之一致。它包含判分目标,仅提供给可信数据处理端;采样 Agent 不挂载该快照、JSONL 或历史归档盘。已有封存文件不改写,新导出统一携带该文件并纳入 manifest。
`manifest.json` 列出每个文件的字节数和 SHA-256,并记录任务/镜像身份、评分与轨迹质量。输出以独占创建方式写入,不覆盖已有文件;失败时删除本次未完成输出。上传使用已登录的 Salty CLI,成功后下载到临时文件并复核归档摘要,再删除该临时文件。
这是受控 Pi adapter 的证据归档,不能证明任意恶意 Agent 的全部行为。费用未知时保持未知;`NOT_TRAIN_READY` 仅沿用回执字段,本项目不实施模型训练。