A robot reaches for a cup, but the cup slips out of its gripper. A policy that only produces actions might continue its placing trajectory. A system that consults a large planner every few seconds might catch the failure, but it also spends resources when the robot is stationary and nothing has changed. Apexio 1.0 asks when the robot actually needs to reconsider its plan.

Hy-Embodied-Apexio-1.0, from Tencent Robotics X, Futian Laboratory, and the Tencent Hy Team, released code and checkpoints on December 3, 2026. Its original technical report, Always-On Perceptual Embodied X-agent for Interactive Operations, combines manipulation policies, consequence prediction, and cognition that runs on demand.

This tutorial progresses from a CPU runtime demonstration to checkpoint inference, post-training, and RoboTwin evaluation. Numerical results are reported by the authors; this article does not claim an independent training run or benchmark reproduction. For simulator terminology, start with our RoboTwin 2.0 bimanual manipulation guide.

1. Choose a concrete first milestone

“Running Apexio” can mean three different things. Separating them makes installation and debugging much easier.

Milestone Requirements What it establishes
Inspect the runtime and Event Trigger Python and the runtime package; no GPU Processes communicate and events move through the stack
Execute a learned policy GPU, compatible PyTorch, checkpoint, DINOv3 access A model accepts observations and returns action chunks
Evaluate closed-loop behavior RoboTwin, assets, and the XPolicyLab adapter The simulated robot succeeds or fails at actual tasks

The CPU demo uses a mock policy and a synthetic robot client. It is useful for learning the architecture, but it does not demonstrate learned grasping. Likewise, an inference call with a correctly shaped output does not establish control quality. Closed-loop evaluation must apply those actions in the simulator and observe what happens across episodes.

Before renting training GPUs, complete the demo and inference milestones. HY-Embodied-0.5 configurations train Cognition-Sys1 alongside PerAction, so training memory requirements are considerably larger than the advertised PerAction parameter count might suggest.

2. The paper's idea: wake the planner for a reason

Apexio separates the system into three tiers. Cognition interprets requests and plans when needed. PerAction continuously observes, acts, and predicts consequences. Execution uses the robot's low-level controller for fast body control and physical feedback.

The cognition tier itself contains two distinct components:

  • Cognition-Sys2 is the slower planner. It considers instructions, decision history, camera observations, and a skill library. It can select a subgoal, continue execution, pause, or return to standby.
  • Cognition-Sys1 grounds the subgoal in the current scene. It encodes the instruction and subgoal-start images into 32 goal tokens, cached outside the control loop.

Suppose Sys2 delegates “put the cup to the right of the sink.” Sys1 identifies the relevant visual context. PerAction then combines the cached goal tokens with fresh observations to move the arms. The planner does not need to reprocess the task at every camera frame while execution matches expectations.

One implementation detail matters: version 1.0 uses a lightweight task- and scene-conditioned state machine as its Router. A learned cognition router is future work. The optional visual gate exposed by the code was also disabled in the reported experiments. Describing the released Router as an already trained end-to-end neural decision module would overstate the implementation.

Apexio architecture combining on-demand Cognition, always-on PerAction, and Execution — source: Tencent-Hunyuan/Hy-Embodied-Apexio-1.0 repository
Apexio architecture combining on-demand Cognition, always-on PerAction, and Execution — source: Tencent-Hunyuan/Hy-Embodied-Apexio-1.0 repository

Three experts inside one MoT backbone

PerAction is a Mixture-of-Transformers with three experts. They share attention machinery while retaining different roles and information access.

Expert Main conditioning Function
Perception Multi-camera RGB and robot state Encode observations and produce reusable KV caches
Action Observations and cached goal tokens Generate action chunks and estimate subgoal progress
Prediction Observations and committed actions Forecast future visual features and state trajectories

A frozen DINOv3 encoder processes visual inputs. The published configuration uses three 192 × 256 views: head, left wrist, and right wrist. Its action horizon is 15 steps, corresponding to one second on a 15 Hz control grid. Flow matching generates the actions by learning a conditional transformation from noise into an action sequence.

Why the Prediction Expert cannot read the goal

Wanting a cup inside the gripper does not make it physically present there. Prediction should estimate what the committed actions will cause, rather than infer a successful outcome from the task description.

The attention mask prevents Prediction from reading Action-branch or Cognition-Sys1 tokens. It receives committed actions through a separate conditioning path. This goal isolation also makes standby prediction meaningful: even without an active subgoal, the robot has observations and a hold action whose consequences it can predict.

The PerAction architecture documentation explains the two-stage inference path. Stage 1 produces actions and preserves the Perception KV cache. After the control layer applies velocity limits, body-part locks, or a hold override, Stage 2 predicts consequences from the final committed chunk. Predicting the unmodified policy proposal would create artificial discrepancies whenever control arbitration changes it.

3. How an event becomes a planning request

An Event Trigger compares predictions with observations only after the predicted horizon matures. A one-second future prediction must be paired with the corresponding later observation, not the current frame. Signals include visual discrepancy, proprioceptive discrepancy, and estimated subgoal progress.

For intuition, imagine a prediction in which both gripper and object rise. One second later, the gripper has risen but the object remains on the table. The mismatch can create an execution-anomaly event, giving Sys2 context to decide whether to retry or change the subgoal. This example illustrates the mechanism; it is not a separate experiment performed for this article.

Appendix A.3 measures visual discrepancy using cosine distances from the highest-error 10% of patches. A localized failure is therefore less easily diluted by a large static background. During standby, an adaptive threshold tracks recent quiet observations. Cold-start baseline collection and cooldowns reduce repeated or premature wake-ups.

These settings depend on normalization, sensor timing, and the authors' deployment environment. Before tuning thresholds on another robot, check timestamp alignment, rollout pairing, and transitions between moving and stationary states. More sensitive triggering cannot repair an observation stream that is consistently late.

4. Install the runtime and run the CPU demo

The commands below are instructions for a separate experimentation machine. Start with a downloaded Apexio repository and open its root directory, containing packages/, scripts/, and tools/. You will need this directory's absolute path later when connecting RoboTwin.

Runtime without a GPU

The runtime requires Python 3.10 or newer. A small virtual environment is enough:

bash
python3 -m venv .venv-runtime
source .venv-runtime/bin/activate
python -m pip install -e packages/apexio
python tools/launch_demo.py

Open http://127.0.0.1:8800. Inspect the camera streams, per-step latency waterfalls, Event Trigger signals, and Hold/E-Stop controls. Watch a subgoal transition and an event to understand how the processes interact. Press Ctrl-C to shut down the stack.

Apexio runtime processes including control, hub, trigger, cognition, and policy — source: Tencent-Hunyuan/Hy-Embodied-Apexio-1.0 repository
Apexio runtime processes including control, hub, trigger, cognition, and policy — source: Tencent-Hunyuan/Hy-Embodied-Apexio-1.0 repository

GPU environment for the learned model

Leave the runtime virtual environment before preparing the full environment. The repository provides a pinned setup for Linux x86_64 with conda; its quickstart specifies CUDA 12.8 or newer:

bash
deactivate
bash scripts/setup_env.sh
conda activate apexio
hf auth login

If a compatible CUDA PyTorch environment already exists, the official quickstart also supports direct editable installation:

bash
pip install -e packages/apexio -e "packages/apexio-peraction[train]"

For the m model, request access to DINOv3 ViT-L/16 using the same Hugging Face account authenticated on the machine. Apexio checkpoints reconstruct their frozen vision encoder from that gated repository. Downloading Apexio successfully does not establish access to every dependency. Resolve gated-repository errors before changing model code.

5. Run inference with the RoboTwin joint-14 checkpoint

Use the post-trained checkpoint tencent/Hy-Embodied-Apexio-1.0-m-hy05-RoboTwin. The foundation m-hy05 checkpoint uses pose100; it is not a direct replacement for the joint-14 task model.

Run this code in the GPU environment. Black images and a zero state are a loading and shape check only. Do not execute the returned actions on hardware.

python
import numpy as np
from apexio_peraction import PerActionInferenceEngine

engine = PerActionInferenceEngine.from_pretrained(
    "tencent/Hy-Embodied-Apexio-1.0-m-hy05-RoboTwin",
    device="cuda:0",
)
result = engine.predict(
    images={
        "head": np.zeros((480, 640, 3), dtype=np.uint8),
        "left_wrist": np.zeros((480, 640, 3), dtype=np.uint8),
        "right_wrist": np.zeros((480, 640, 3), dtype=np.uint8),
    },
    state=np.zeros(14, dtype=np.float32),
    instruction="adjust the bottle",
)
print(result.actions.shape)  # Expected: (15, 14), in raw robot units.

Each action row contains six left-arm joints, the left gripper, six right-arm joints, and the right gripper. This embodiment represents grippers as 1 open and 0 closed. Swapping arms or interpreting absolute joint targets as deltas can produce valid tensors with completely incorrect behavior.

To inspect the serving interface:

bash
apexio-peraction serve core \
  --checkpoint-dir tencent/Hy-Embodied-Apexio-1.0-m-hy05-RoboTwin \
  --port 8848

Keep that process running, open another terminal in the same environment, and inspect its handshake:

bash
python tools/inspect_server.py 127.0.0.1:8848

Check the action layout, camera names, and image size. Protocol clients must reset at the appropriate episode or subgoal boundary so that cached goal tokens do not describe an old scene. The official RoboTwin adapter performs per-episode reset; use it before writing a custom client.

6. Prepare LeRobot v3 demonstrations

Skip training if your goal is evaluating the released checkpoint. To learn the training pipeline, start with one task such as adjust_bottle. Success on that task does not represent the full 50-task benchmark.

Obtain the RoboTwin 2.0 release demonstrations through the project's data instructions. The Apexio converter expects a structure like this:

text
ROBOTWIN_HDF5_ROOT/
  adjust_bottle-aloha-agilex_clean_50-50/
    episode_0/
      episode_0.hdf5
      instructions.json
    episode_1/
      episode_1.hdf5
      instructions.json

The input root is the extracted demonstration directory, not RoboTwin's source-code directory. Match --tasks to the actual folder name. Choose an output directory that does not already exist, because the converter refuses to overwrite it.

bash
# Replace this path with the extracted demonstrations directory.
ROBOTWIN_HDF5_ROOT=/absolute/path/to/robotwin_hdf5
APEXIO_DATA="$PWD/data/robotwin-adjust-bottle"

python examples/benchmarks/robotwin/convert_to_lerobot.py \
  "$ROBOTWIN_HDF5_ROOT" "$APEXIO_DATA" \
  --tasks adjust_bottle-aloha-agilex_clean_50-50 --episodes 50

apexio-peraction data stats \
  --embodiment robotwin_joint14 --data-root "$APEXIO_DATA" \
  --stats-out "$PWD/robotwin-stats.safetensors"

The converter reads observations/qpos, joint_actions, and three image streams. It writes parquet data, videos, and metadata for the LeRobot v3 reader. Video keys are observation.images.cam_high, observation.images.cam_left_wrist, and observation.images.cam_right_wrist.

Inspect an episode before training. Check RGB order, viewpoint identity, 14-dimensional state and action vectors, gripper direction, and synchronized timestamps. This example uses 15 Hz recordings. Relabeling a different recording rate as 15 Hz is not resampling: it changes both action timing and when future predictions should mature.

7. Understand training before provisioning GPUs

The report uses two training stages. Cross-embodiment pre-training maps heterogeneous robots into a 100-dimensional semantic layout covering arms, grippers, torso, head, and mobile base. The complete curated corpus contains approximately 30.6 thousand effective hours. However, the flagship RoboTwin row in Table 6 uses the 10 thousand kept robot-hour mixture. The full corpus size should not be attributed to every checkpoint.

Target-embodiment post-training slices the pretrained projections according to meaningful semantic slots. RoboTwin uses 14 output dimensions. This is not equivalent to taking the first 14 entries of the 100-dimensional vector.

The objective combines action flow matching, intent, progress, subgoal supervision, and visual/state consequence prediction. A Query Decoder supplies an intent-related training objective and is skipped by default at inference. Prediction operates in latent feature space, so deploying the model does not require rendering future video frames at every step.

Initialize from the foundation model

From the Apexio root in the training environment:

bash
hf download tencent/Hy-Embodied-Apexio-1.0-m-hy05 \
  --local-dir checkpoints/m-hy05

APEXIO_PRETRAIN_DIR="$PWD/checkpoints/m-hy05"
APEXIO_MODEL_CONFIG=Hy-Embodied-Apexio-1.0-m-hy05

apexio-peraction checkpoint init \
  "$APEXIO_PRETRAIN_DIR/model.safetensors" "$PWD/robotwin-init.safetensors" \
  --embodiment robotwin_joint14

The model name matches the YAML configuration in the released checkpoint's model/ directory. Preserve its processor, tokenizer, and configuration alongside the weights. Copying a single weights file to another machine can omit information needed to reconstruct the model.

Debug before the long run

The package README describes an m-hy05 example using eight 64 GB GPUs, per-GPU batch size 8, and HSDP ZeRO-2. Treat this as the project's reference configuration, not a universal memory guarantee. A smaller batch alone may not solve an out-of-memory error because Sys1 weights and optimizer state remain substantial.

bash
torchrun --nproc_per_node 8 -m apexio_peraction.cli train \
  --config-dir "$APEXIO_PRETRAIN_DIR" model="$APEXIO_MODEL_CONFIG" \
  embodiment=robotwin_joint14 data=robotwin \
  data.data_root="$APEXIO_DATA" \
  data.normalization_stats_path="$PWD/robotwin-stats.safetensors" \
  training.init_weights_path="$PWD/robotwin-init.safetensors" \
  'training.init_weights_new_prefixes=[readout.]' \
  training.distributed=hsdp_zero2 training.batch_size=8 \
  training.num_epochs=50 training.max_steps=null \
  training.debug=true

This first invocation is a debug run. Check finite losses, data-loading throughput, checkpoint output, and the served checkpoint's handshake. Once the pipeline and budget are understood, repeat without training.debug=true for the long run. The single-task dataset above is a learning exercise; multitask benchmarking requires the full task set.

The public recipe differs from the paper's exact training budget. The repository describes 50 epochs without a step cap. The report gives 20,000 RoboTwin post-training steps, peak learning rate 1.4e-4, and global batch 792 for the HY family. The command above inherits package learning-rate defaults and does not reproduce that budget. Reproduction requires checking Appendix A.2, effective global batch, and actual run configurations rather than changing epochs alone.

8. Connect RoboTwin and evaluate closed-loop

The official benchmark instructions use RoboTwin with its XPolicyLab submodule. Keep simulator and policy dependencies in separate conda environments. Install an actual ffmpeg executable on PATH; a similarly named Python package is insufficient.

Set up the simulator in a separate working directory:

bash
git clone --recurse-submodules https://github.com/RoboTwin-Platform/RoboTwin.git
cd RoboTwin
conda create -n RoboTwin python=3.10 -y
conda activate RoboTwin
bash scripts/_install.sh
bash scripts/_download_assets.sh
conda install -c conda-forge ffmpeg

The Apexio instructions describe approximately 15 GB of compressed assets. Allow additional space for extraction and episode videos. From the RoboTwin root, replace the Apexio path below with your actual source directory:

bash
APEXIO_ROOT=/absolute/path/to/Hy-Embodied-Apexio-1.0
cp -r "$APEXIO_ROOT/examples/benchmarks/robotwin/xpolicylab/ApexioPerAction" \
  XPolicyLab/policy/

conda create -n apexio_policy python=3.10 -y
conda activate apexio_policy
pip install torch torchvision --index-url https://download.pytorch.org/whl/cu128
APEXIO_ROOT="$APEXIO_ROOT" bash XPolicyLab/policy/ApexioPerAction/install.sh

hf auth login
hf download tencent/Hy-Embodied-Apexio-1.0-m-hy05-RoboTwin \
  --local-dir checkpoints/apexio-robotwin

Choose a PyTorch build compatible with the installed driver; cu128 follows the adapter example. Stop the manually launched inference server before evaluation so it does not unnecessarily occupy GPU memory. For the first run, restrict env_cfg/eval/all_tasks.yml to one task and one GPU, and use two test episodes:

bash
conda activate RoboTwin
APEXIO_RUN_DIR="$PWD/checkpoints/apexio-robotwin"

bash scripts/eval_policy.sh multitask \
  --config env_cfg/eval/all_tasks.yml --policy-name ApexioPerAction \
  --checkpoint-file "$APEXIO_RUN_DIR" \
  --env-cfg-type aloha_agilex --action-type joint \
  --policy-conda-env apexio_policy --eval-env-conda-env RoboTwin \
  --test-num 2 --task-config demo_clean

For the full benchmark, restore all 50 tasks and use 25 episodes per task. Run demo_clean and demo_randomized separately. For a custom-trained checkpoint, point APEXIO_RUN_DIR to its run directory containing configuration, normalization statistics, processor, and weights.

The public adapter defaults to denoise_steps: 10, replan_steps: 15, compilation disabled, and fp32 weights under bf16 autocast. Keep eval_batch: false. The protocol executes the entire 15-step chunk before replanning; changing that to a single executed step changes the experiment.

A status: success entry in summary.json means the evaluation job finished. Actual task performance appears in log lines such as Final success rate: k/n. Watch rollout videos too: a process can exit cleanly while its robot remains still, grasps the wrong object, or misses every placement.

9. Interpret the results without mixing experiments

Table 6 comparing C2C and C2R task success on RoboTwin 2.0 — source: Tencent-Hunyuan/Hy-Embodied-Apexio-1.0 repository
Table 6 comparing C2C and C2R task success on RoboTwin 2.0 — source: Tencent-Hunyuan/Hy-Embodied-Apexio-1.0 repository

Table 6 uses clean-only training. C2C means training and testing on clean scenes; C2R means training on clean scenes and testing on domain-randomized scenes.

Method C2C C2R Average
π0.5 70.7% 46.0% 58.4%
GR00T N1.7 43.6% 20.7% 32.2%
OpenWAM-α 89.4% 48.7% 69.0%
UniWAM 75.1% 67.6% 71.4%
Apexio m, without Sys2 87.4% 57.8% 72.6%
Apexio m, generative Sys2 87.4% 71.3% 79.4%

The 79.4% result adds gemini-nano-banana-2.1 as a generative Sys2. Once at episode start, it edits observations to remove distractors. This is different from continuously replanning every action. Clean views contain no distractors, so C2C stays unchanged. Loading the checkpoint and running the default adapter does not automatically add that image-editing stage; that run is closer to the no-Sys2 policy setting. Baselines were also collected from leaderboards and other reports rather than all being rerun on one shared machine.

The nano, s, and m tiers have 0.47B, 1.46B, and 3.26B PerAction parameters, excluding cached Sys1. With an RTX 5090 D v2, batch 1, bf16, compilation, and four action-denoising steps, action-forward medians are 7.8, 17.5, and 28.1 ms. Adding consequence prediction gives model-loop medians of 9.7, 20.6, and 34.9 ms. These are not complete camera-to-actuator latencies and do not use the adapter's ten-step evaluation configuration.

The reported approximately 74% reduction in Sys2 input tokens per minute belongs to a separate physical-robot experiment, Tea-room-Dynamic, compared with five-second polling. Apexio achieved 95% success across 20 four-round trials, versus 80% for Harness VLA. Its extended 30-minute test succeeded in 3/3 runs, a small sample of three. These measurements do not establish a 74% reduction in total GPU spending or electricity for RoboTwin.

10. Troubleshoot from the interfaces outward

If loading fails, check DINOv3 access and frozen-encoder paths first. If the adapter waits indefinitely, inspect server startup logs, ports, and hostname resolution. The adapter uses 127.0.0.1 to avoid problematic localhost mappings on some hosts.

If motion is wrong, verify joint-14 ordering, camera identity, RGB order, gripper direction, and absolute joint targets before changing the instruction. If motion looks plausible but grasps fail, inspect object distributions, camera latency, and recorded rollouts. Decreasing training loss does not establish closed-loop competence.

If the trigger repeatedly wakes the planner, examine prediction-observation timing, committed actions after arbitration, reset behavior, and motion–rest transitions. If performance falls below 79.4%, first establish whether generative image editing was present, then compare task sets, seeds, and protocol settings.

A useful progression is observable at every step: the console runs, the model serves the expected layout, one simulated task behaves correctly, and only then does evaluation or training expand. Each milestone helps locate a failure in the simulator, data, policy, or planning interface before several components change together.