Repository navigation
Conversation
Versioning (mjlab-style, main only for now): - build docs with sphinx-multiversion; branch whitelist defaults to main, tag whitelist empty (SMV_* env vars enable future releases) - Furo sidebar version switcher template + styles - deploy job: fetch-depth 0, root redirect to main/, keep_files so existing root-level pages and future version dirs survive deploys - html_baseurl points at /UniLab-doc/main/ for sitemap correctness P0 reference content (bilingual en/zh_CN): - 5-reference/6-manager_terms: reward/observation/termination term tables (framework-level unilab.envs.mdp + task-layer terms) - 2-user_guide/5-domain_randomization/2-field_reference: per-field DR configuration reference for the 14 event terms - 2-user_guide/2-algorithms/*: per-algo Hydra configuration reference (PPO/APPO/SAC/FlashSAC; efficiency / policy / training-runtime / reward-weight groups)
- extending/5-onboard_new_robot: end-to-end walkthrough from URDF/MJCF to first training run (assets, keyframe checklist, minimal owner YAML, registry, per-step verification) - extending/6-custom_reward: from function definition to the term showing up in training logs (owner YAML injection, info["log"] reward/<term> keys, weight tuning) - training/8-training_diagnostics: NaN guard -> viz chain, info["log"] field reference, common failure modes and triage paths - fix stale references: 1-new_task no longer points at the deleted go2/joystick.py; reward_porting uses the real sensor_reward_terms track_lin_vel and drops the outdated NumPy wording - bilingual (en/zh_CN mirror), zero new sphinx warnings
…706) - add Google-style docstrings across high-traffic public interfaces: envs/mdp observations/actions/curriculums/ray_observation, managers types + manager_base, base torch_env + reset_state, structured_configs dataclasses (interrogate 43.6% -> 50.8%) - interrogate dev dependency with fail-under=40 gate; enforced in CI (ruff-lint job) and available as make check-docstrings; rocm pyproject/lock kept in sync - CONTRIBUTING.md: changelog discipline (Unreleased entries for user-visible PRs, bilingual Added/Changed/Fixed, issue links); AGENTS.md: docstring PR requirement + changelog pointer - changelog.md: add Unreleased section covering this PR
Keep the P2 docstring baseline on public API surface (public functions, classes, dunder/protocol methods — these feed the api_reference autodoc pages). Remove the one-liners added to private helpers (_validate_*, _materialize_*, etc.), which never render in public docs. interrogate still passes: 49.1% (gate 40%).
The P0/P1 pages were only reachable by walking the section tree. Add an "I want to…" card grid to the top of both landing pages (onboard a robot, custom reward, term tables, DR fields, hyperparameters, diagnostics) and surface the two walkthroughs on the developer-guide index, so new users reach the answer pages in one click.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
范围 / Scope
关联 #706,覆盖除已完成项外的全部子目标(P0×3 + P1×2 + P2×2)。按批次增量提交:
f9c63adP0:版本化站点 + 3 组参考页f3113e7P1:两个 walkthrough + 训练诊断页 + 修过时引用8ecd239P2:docstring 基线 + interrogate 门槛 + changelog 纪律站点版本化(参考 mjlab,仅 main)
sphinx-multiversion构建;分支白名单默认^(main)$,tag 白名单默认^$(不构建任何历史版本;未来发版用SMV_TAG_WHITELIST环境变量放行)fetch-depth: 0→sphinx-multiversion→ 根 redirect 到main/en/0-index.html→keep_files: true(存量根目录页面保留,旧外链不死);html_baseurl→/UniLab-doc/main/P0 参考手册(双语)
5-reference/6-manager_terms/:reward/observation/termination term 参考表(框架级unilab.envs.mdp全部 29 个 + 任务层 locomotion/G1/motion tracking)2-user_guide/5-domain_randomization/2-field_reference:14 个 DR event term 字段表 + 最小 owner YAML 示例 + FAQ(backend 适用性按 fail-closed + owner YAML 实证书写)2-user_guide/2-algorithms/{ppo,appo,sac,flash_sac}:每页新增"配置参考"小节(训练效率/策略性能/training 段/reward 权重),默认值逐一核对structured_configs.pyP1 walkthrough + 诊断(双语)
4-developer_guide/3-extending/5-onboard_new_robot:URDF/MJCF → import_robot → keyframe 检查单 → 最小 owner YAML → registry → 起训验证,每步带验证命令4-developer_guide/3-extending/6-custom_reward:函数定义 → owner YAML 注入 →info["log"]的reward/<term>验证 → 权重调整2-user_guide/1-training/8-training_diagnostics:nan_guard →unilab-viz-nan链路、info["log"]字段、常见失败模式排查路径1-new_task.md不再引用已删除的go2/joystick.py;6-reward_porting.md改用真实的sensor_reward_terms.track_lin_vel并去除过时的 NumPy 表述P2 docstring 基线 + 纪律
interrogate入 dev 依赖(pyproject + pyproject.rocm + 双 lock 同步),fail-under = 40;CI ruff-lint job 新增检查步;make check-docstringsCONTRIBUTING.md新增 Changelog Discipline(Unreleased 段、双语 Added/Changed/Fixed、issue 链接);AGENTS.md增加"新公开接口必须有 docstring"PR 要求changelog.md顶部新增## Unreleased,收录本 PR 全部变更与 issue 描述的偏差(issue 快照过时)
base/np_env.py、go2/joystick.py、TensorResetRandomizationPayload等路径/符号已不存在,按当前代码取证reward.<term>.weight(非*_scale)验证 / Validation
uv run pytest tests/scripts/test_check_docs.py -q→ 20 passedmake check(ruff format/check + mypy + pyright)→ 通过(22 条 missing-optional-import 为既有警告)uv run pytest tests/test_library_import_boundary.py -q→ 28 passed(lazy-import 边界完整)uv run interrogate src/unilab→ PASSED(min 40.0%, actual 50.8%)sphinx-build -n与sphinx-multiversion构建均成功,新增页面零 warning(存量 13 条为既有问题);多版本构建仅产出main/目录,版本切换器渲染正常-D intersphinx_timeout=30跳过(仅影响外部交叉引用,CI 不受影响);walkthrough 中需 GPU/backend/显示器的步骤已在文中标注,未实机验证遗留 / Follow-ups
html_baseurl按版本动态化(conf.py/README 已注明)