GenRL: Building Flexible, Decentralized Multi-Agent RL Environments
🌐 Visit Website 🧠 RL Swarm ✖️ X 🤗 Hugging Face 💬 Discord
🔬 Research 📰 Latest News 💼 Work for Gensyn 📊 Dashboard
GenRL is a framework that provides native support for horizontally scalable, multi-agent, multi-stage RL with decentralized coordination and communication.
Customizable Components:
- DataManager: Specifies and manages the particular data your RL environment will use. This could be a text dataset, an image dataset, a chessboard, or something else entirely.
- RewardManager: This is where you implement your custom reward functions, directly shaping the RL objective for your agents.
- Trainer: Performs two functions
- Train: Manages the core learning process itself, this is where policy updates happen. Whether you're working with policy gradient optimization, value function approximation, or other RL paradigms, the algorithmic policy updates take place here.
- Generation: Handles the generation of rollouts and agent interactions within the environment.
Core Components
- GameManager: Seamlessly coordinates the data flow between the core components you define and the other agents in the multi-agent swarm.
- CommunicationManager: Handles the communication between the agents in the swarm. Current backends include
- HiveMind: A decentralized communication protocol that allows agents to communicate with each other.
- Torch Distributed: A distributed training protocol that allows agents to train with each other.
Optional Components
- Coordination: Handles coordination and orchestration between agents in a decentralized swarm. This is implemented using smart contracts on the blockchain and is only required when running in a decentralized swarm.
Framework Defined Progression
We track the progression of the game on a per-round basis. Each round the data manager initializes round data. The round data kicks off the game’s stages, for each stage rollouts are generated, appended to the game state, and communicated to the swarm. After the agent has progressed through the game’s predefined stages, rewards are evaluated and policies are updated. The user has full control over the update, which occurs in the Trainer.train method, and so has the opportunity to update the policy on a per stage or per round basis.
Example Usage
pip install .[examples]
export NUM_PROC_PER_NODE=1
export NUM_NODES=1
export MASTER_ADDR="localhost"
export MASTER_PORT=29500
./scripts/train.sh $NUM_NODES $NUM_PROC_PER_NODE multistage_math msm_dapodata_grpo.yaml
Metadata
Release files for gensyn-genrl 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| gensyn_genrl-0.3.0.tar.gz | 346.2 kB | Without provenance | Details for gensyn_genrl-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gensyn_genrl-0.3.0-py3-none-any.whl | Python 3 | none | any | Details for gensyn_genrl-0.3.0-py3-none-any.whl |
Total release size: 467.9 kB
Release files / gensyn_genrl-0.3.0.tar.gz
| Download URL | gensyn_genrl-0.3.0.tar.gz |
|---|---|
| Size | 346.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6153bca8339c76f2932f881cb2243bae8f83beba70f20eae8d3dc91405ba7650
|
|
BLAKE2b-256 checksum How to use checksums |
245be63d98939c204cf92f30223b60466d129cd39d6e45dc4601f98e744c670a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.3
|
Release files / gensyn_genrl-0.3.0-py3-none-any.whl
| Download URL | gensyn_genrl-0.3.0-py3-none-any.whl |
|---|---|
| Size | 121.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
74b2dfd453d7b60ba966848bc923beffcdb8bb503a824386f4ebfcba34d0e527
|
|
BLAKE2b-256 checksum How to use checksums |
ee004926b2d0d90ed41b10d199ddb6d0001e0a08c3141bd5021ae8faaf7bd78b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.3
|
Security for gensyn-genrl 0.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.