APIs#

This section provides a detailed walkthrough of the most essential API interfaces in RLinf, aiming to help users deeply understand our API design and usage. These key APIs are exposed to users to simplify the complex data flows of RL, allowing them to focus on higher-level abstractions without needing to worry about the underlying implementations.

This API documentation proceeds bottom-up, starting with the foundational APIs of RLinf, including:

  • Worker Interface — A unified interface for workers and worker groups.

  • Placement Interface — An introduction to RLinf’s GPU placement strategies.

  • Cluster Interface — Support for distributed training via clusters.

  • Channel Interface — Low-level communication primitives, including a producer–consumer queue abstraction.

After that, we introduce the upper-layer APIs used to implement different stages of RL: