What are Subtasks?
While a task describes the overall goal (e.g., “Pick up the apple and place it in the basket”), subtasks break execution into atomic steps:- “Approach the apple”
- “Grasp the apple”
- “Lift the apple”
- “Move to basket”
- “Release the apple”
Dataset Structure
Subtask information is stored inmeta/subtasks.parquet:
Subtasks File Format
meta/subtasks.parquet maps indices to descriptions:
Frame-Level Annotations
Each frame includes asubtask_index field:
Annotating Datasets
Use the Hugging Face Space to annotate datasets: https://huggingface.co/spaces/lerobot/annotateSteps:
- Load your dataset
- Define subtask labels
- Annotate frame ranges for each episode
- Push annotated dataset to Hub
Loading Datasets with Subtasks
Accessing Subtask Information
Using with DataLoader
Training with Subtasks
Hierarchical Policy
Predict both actions and current subtask:Stage-Aware Reward Modeling (SARM)
Build reward models that understand task progression:Subtask Analysis
Distribution Analysis
Episode-Level Analysis
Progress Visualization
Monitor robot execution by tracking subtask progression:Subtask-Conditioned Policies
Use ground truth or predicted subtasks as input:Example Datasets
Datasets with subtask annotations:API Reference
Dataset Properties
Sample Keys
Related Resources
- SARM Paper - Stage-Aware Reward Modeling
- LeRobot Annotate Space - Annotation tool
- Dataset Overview - Dataset format documentation