Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
f489351
infra: nvkind GPU cluster with KAI scheduler, KubeRay, and examples
terrykong Mar 31, 2026
d0412de
feat: NemoGym disaggregated mode with standalone Gym server
terrykong Mar 31, 2026
1214eb9
infra: K8s ConfigMap endpoint registry for disaggregated service disc…
terrykong Mar 31, 2026
a3eba37
infra: peer-watcher sidecar for bidirectional failure cascading
terrykong Mar 31, 2026
bc36404
infra: Kyverno queue enforcement, Prometheus+Grafana monitoring, fair…
terrykong Mar 31, 2026
0da7e5f
infra: upgrade KAI to v0.14.0, k8s CLI, fixed Grafana dashboard
terrykong Apr 1, 2026
5de2917
infra: consolidate examples, inline peer-watcher, clean up
terrykong Apr 15, 2026
2820f36
infra: remove k8s CLI, rename queues to high-prio/low-prio
terrykong Apr 18, 2026
882faae
infra: remove Kyverno
terrykong Apr 18, 2026
9f3a3ff
infra: remove KAI Grafana dashboard
terrykong Apr 18, 2026
edc3cd2
infra: remove Prometheus+Grafana stack
terrykong Apr 18, 2026
919c2c9
infra: move standalone gym server from Gym submodule to nemo-rl
terrykong Apr 18, 2026
7691665
infra: add monolithic RayJob and disagg JobSet examples
terrykong Apr 18, 2026
d4f6eb5
infra: add gym-head + gym-workers to JobSet example
terrykong Apr 18, 2026
9503d72
infra: fix JobSet example — use init containers instead of dependsOn
terrykong Apr 18, 2026
7e9edb2
infra: use uv run --extra nemo_gym for gym-head in JobSet
terrykong Apr 18, 2026
69fffa9
infra: fix gym-head startup in JobSet example
terrykong Apr 18, 2026
7613a66
infra: fix driver working-dir upload in JobSet example
terrykong Apr 18, 2026
b546641
infra: fix driver in JobSet — unique submission_id, disable wandb, pi…
terrykong Apr 18, 2026
14c831b
infra: rewrite SETUP.md with architecture docs, disclaimers, and guides
terrykong Apr 18, 2026
7df3167
infra: fix GRPO config for 2-GPU kind cluster
terrykong Apr 18, 2026
13da860
infra: add NRL_FORCE_REBUILD_VENVS=true to all pod specs
terrykong Apr 19, 2026
d5b8461
infra: mount hostPath at /opt/nemo-rl for code consistency
terrykong Apr 19, 2026
8339eac
address PR #2238 review feedback
terrykong Apr 19, 2026
7fd1dc8
infra: revert Gym submodule bump
terrykong Apr 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions examples/nemo_gym/run_grpo_nemo_gym.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,36 @@ def main() -> None:
base_urls=policy_generation.dp_openai_server_base_urls,
initial_global_config_dict=config["env"]["nemo_gym"],
)
# Support disaggregated Gym: connect to a remote Gym service instead of spawning local subprocesses.
# Two modes: (1) static URL via env.remote_gym_url, or (2) K8s endpoint registry via env.disagg_job_id.
remote_gym_url = config["env"].get("remote_gym_url")
disagg_job_id = config["env"].get("disagg_job_id")
if disagg_job_id:
import json

from nemo_rl.distributed.k8s_endpoint_registry import K8sEndpointRegistry

registry = K8sEndpointRegistry(job_id=disagg_job_id)
registry.create(owner_raycluster_name=os.environ.get("RAY_CLUSTER_NAME"))

# Publish vLLM URLs so the Gym cluster can discover them.
vllm_urls = [u for u in policy_generation.dp_openai_server_base_urls if u]
registry.set("vllm_base_urls", json.dumps(vllm_urls))

# Wait for the Gym cluster to register its head server address.
print("Waiting for Gym head server to register in endpoint registry...")
try:
remote_gym_url = registry.get("gym_head_server")
except TimeoutError as e:
raise TimeoutError(
f"Timed out waiting for the Gym cluster to register its head server. "
f"Ensure the Gym RayCluster is running and the standalone_gym_server "
f"has started with --job-id={disagg_job_id}. Original error: {e}"
) from e
print(f"Discovered remote Gym service at: {remote_gym_url}")
if remote_gym_url:
nemo_gym_config["remote_gym_url"] = remote_gym_url
print(f"Using remote Gym service at: {remote_gym_url}")
nemo_gym = create_env(env_name="nemo_gym", env_config=nemo_gym_config)
# Blocking wait for NeMo-Gym to spin up
ray.get(nemo_gym.health_check.remote())
Expand Down
Loading
Loading