docs(rollout): write the API reference docstrings

Wave 4 (training & eval) kickoff: brings src/lerobot/rollout/ to 100% public
docstring coverage, following the standard in docs/source/writing_docstrings.mdx.
Picked as the smallest of the five Wave 4 modules (scripts/envs/rewards/rl/rollout)
to validate the workflow before the larger ones.

- Documents the remaining gaps across configs.py (RolloutConfig, the
  RolloutStrategyConfig hierarchy, DAggerKeyboardConfig/DAggerPedalConfig),
  inference/ (InferenceEngineConfig hierarchy, RTCInferenceEngine.__init__,
  SyncInferenceEngine.__init__), ring_buffer.py, robot_wrapper.py, and every
  strategy's __init__ (core/dagger/episodic/highlight/sentry), converting
  RolloutConfig's and the strategy configs' inline `#` field comments into
  type-annotated Args: blocks and RolloutRingBuffer's numpydoc Parameters
  section into Google-style Args:.
- Also documents two dunder methods (RolloutConfig.__get_path_fields__,
  RolloutRingBuffer.__len__) that a naive "skip all underscore-prefixed
  names" gap scan misses but interrogate's ignore-magic=false requires.
- Removes "src/lerobot/rollout/**" = ["D"] from pyproject.toml's ruff ignore
  list — the whole module is now checked, no deferred internals (unlike the
  policies module, rollout has no per-family split to narrow the scope of).
- Adds lerobot.rollout to check_docstrings.py's MODULES_TO_CHECK ratchet.
- Creates docs/source/api/rollout.mdx from scratch (strategies, inference
  backends, RolloutContext and its sub-contexts, ThreadSafeRobot,
  RolloutRingBuffer) and wires it into _toctree.yml under API Reference.
  Verified via a full doc-builder build — no dead cross-references, no
  leftover placeholder text.
- Ratchets interrogate's fail-under from 55 to 55.5 (measured 55.6% with
  this PR).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
CarolinePascal
2026-08-07 15:18:23 +02:00
parent 741005d719
commit cc5759c003
15 changed files with 419 additions and 57 deletions
+2
View File
@@ -215,4 +215,6 @@
title: Environments
- local: api/configs
title: Configuration
- local: api/rollout
title: Rollout
title: "API Reference"