Files
SkillFactory/docs/contact_cycle_rootxy_v2_launch.md
chenlin 9fe9d27865 feat: checkpoint contact-cycle evaluation and RootXY PPO progress
Consolidate next-stage docs, archive superseded narratives, and preserve frozen document inputs. Retain invalid P2 pairs, partial RootXY training, failed attempts and nonselectable checkpoints as explicit limitations.

Include supervised evaluation/training, desktop GPU admission, bounded evidence and atomic-publication monitor repairs with CPU regressions. Ignore local dotenv configuration.

Validation: 1403 passed, 6 skipped for contact-cycle and related contracts/CLI tests. Full-suite legacy ABI and registration tests require Python 3.12/Torch 2.10/pxr; no runtime checks relaxed. No new physical run or accepted skill.
2026-10-15 14:18:17 +08:00

58 lines
5.8 KiB
Markdown
Raw Permalink 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.
# RootXY-v2:受监督启动与终态合同
入口`scripts/train_cycle_sim_rootxy_v2.py`;stdlib监督器`scripts/rootxy_launch_v2.py`。已有真实配置准备和部分PPO运行,但**最新native修复尚未端到端资格验证**;历史绑定/授权不能用于当前源码。[当前进度](current_status.md)不是新运行许可。
## 准备与授权顺序
1. CPU `--check-only`只读验证,`--plan`输出preregistration JSON;不推理、不构造环境、不签发许可。
2. 父级审核manifest、来源/冻结包、短路径新输出根、GPU身份、存储策略及明确预算;生成独立prepare grant。
3. PREP总600s,480s工作+120s清理:安装零物理调用钩子,构造真实128env配置而非环境,有限固定Isaac/PhysX预导入,精确规范化,生成绑定提案。无reset/inference/optimizer。
4. 只有监督器独立等待正常退出、清理并重哈希之后的`preparation.json`有效;worker provisional不能直接授权RUN。
5. 父级另作P2证据/试训可行性决定并签发RUN grant。P2失配不改称通过;仅可明确批准名义单周期pilot,保留功能baseline硬门槛。
6. RUN限额按[配方](contact_cycle_rootxy_v2_plan.md);一次、无恢复/重试。任何源码/配置/绑定变更须新PREP,不复用旧claim或grant。
模板仅说明参数,**不是可直接执行的新许可**。监督器使用绝对入口和`/usr/bin/python3.12`,不能直接启动Kit worker或替换为通用`supervise_sim.py`:
```sh
/usr/bin/python3.12 /ABS/PROJECT/scripts/train_cycle_sim_rootxy_v2.py --prepare \
--output /NEW/ROOT --manifest /PARENT/preregistration.json \
--trusted-manifest-sha256 EXACT_SHA256 \
--storage-policy /PARENT/prepare-policy.json --trusted-storage-policy-sha256 EXACT_SHA256 \
--authorization /PARENT/prepare-grant.json --trusted-authorization-sha256 EXACT_SHA256
/usr/bin/python3.12 /ABS/PROJECT/scripts/train_cycle_sim_rootxy_v2.py --run \
--output /SAME/PREPARED/ROOT --manifest /PARENT/preregistration.json \
--trusted-manifest-sha256 EXACT_SHA256 \
--storage-policy /PARENT/run-policy.json --trusted-storage-policy-sha256 EXACT_SHA256 \
--authorization /PARENT/run-grant.json --trusted-authorization-sha256 EXACT_SHA256 \
--p2-decision /PARENT/pilot-feasibility-decision.json
```
## 精确身份与时钟
- profile=`rootxy-v2-7200s-1GiB-73460calls`,grant=`skillfactory.rootxy-parent-grant.v2`。精确字段校验以`admission`/grant校验代码为准;包括root、mode、manifest/policy/launch identity、boot、expiry、parent_review、GPU,以及RUN必须有的preparation/binding/P2 decision哈希。PREP后三项为null。
- 入场grant有效窗口≤3600s,同boot;这是入场期限,**不是**运行总时长。新策略`skillfactory.rootxy-native-policy.v2`寿命7200..10800s,须覆盖运行及规定120s额外策略余量和grant入场期限。
- 外部trusted SHA256针对精确文件字节,不是重新序列化JSON;`launch_identity`按适配器canonical JSON规则取hash。不得自读自批、猜测digest或让worker自行批准。
- `skillfactory.rootxy-p2-decision.v2`包含task/root/manifest/preparation/binding、approved、parent_review和非空`p2_evidence`路径→哈希。对失败证据的可行性批准不是P2物理通过。
- 保持短canonical输出路径,避免长TMPDIR/NVRTC问题;不使用symlink冒充根或复用旧输出。
## GPU桌面共享
用户已批准保留桌面,而不是GPU独占或硬件分区。每次新grant必须重新记录实际身份,不照抄旧PID:
- admission无计算客户端,graphics恰好匹配有限父级基线(排序唯一、最多64个);NVML库路径/哈希和GPU0 UUID固定,CUDA可见性由监督器强制。
- desktop身份包含PID、birth、UID、argv哈希、exe文件路径/元数据/哈希;运行中查birth/文件身份,入场/终态也重哈希。
- root Xorg的实际`/proc/PID/exe`不可读时,仅UID0、精确`/usr/lib/xorg/Xorg` argv0与comm Xorg允许显式公共元数据范围;**actual-executable-unverified**,不声称真实exe已验证。
- 新图形、外来计算、desktop取得计算身份、身份变化均停止。批准desktop可退出,不属于清理归属,不得终止它或其他外来进程。最终只允许剩余批准desktop,无任务/外来GPU工作。
## 运行绑定、安全与终态
- 唯一spawner/subreaper通过认证继承FD交接;进程清理使用birth identity/pidfd,独立wait,失败也保持有界清理。禁止手动直接运行worker、fake模块或放宽导入白名单。
- 配置只在构造前按精确类/计数规范化:Evaluation=1环境、RootXY=128环境。有限依赖预导入不代替真实同对象绑定。
- 检查构造前、实际环境构造后且动作前、训练源码检查点、env.close后/app.close前。Kit快速关闭前持久化证据;退出后监督器只重哈希静态文件,不能宣称仍验证原cfg对象。
- 真实SimulationContext.step前后记录attempted/completed及初始化/rollout分类;500Hz scene-update安全检查包括reset,缺失/重复覆盖在下一物理步或工作边界拒绝。构造期尚无task audit的调用另计。
- 1GiB含PREP/快照/native/tmp/stdout和声明的外部正增长;保留1MiB stdout和16MiB发布/清理余量。路径、mount、free floor≥2GiB、interval≤1s、覆盖缺口必须精确声明。不是native硬quota。
- 仅完整正常退出、归属/GPU清理、最终身份/账本/物理安全、两baseline+四开发功能、XY资格都通过后,监督器最后提交candidate lock。缺少worker最终报告、仅静态文件PASS、只有checkpoint均不够。
扫描实现、XZ完整性与评估初态规则见[评估和监控](contact_cycle_native_monitor_v3.md)。CPU用例见`test_contact_cycle_sim_rootxy_launch_v2.py`、`test_contact_cycle_sim_rootxy_v2.py`及native/evaluation runner测试;独立复审缺口必须如实披露。