feat: running `ng_run` outside of the gym repository
@cmunley1 is already working on this.
Since Jan 29, 2026.
Assessment
This issue has not been assessed yet.
Description
I'd like to use Gym as a dependency in a project and I've therefore installed NeMo-RL (containing Gym) as a submodule of my project. Then in my project I have created a gym folder containing my custom resources servers and responses api agents.
Basically here is what my gym folder looks like
OwkinZero/agentic/gym
├── README.md
├── create_symlinks.sh
├── resources_servers
│ └── llm_judge_reward
│ ├── README.md
│ ├── app.py
│ ├── configs
│ └── requirements.txt
├── responses_api_agents
│ └── idea_generator_agent
│ ├── README.md
│ ├── __init__.py
│ ├── app.py
│ ├── client.py
│ ├── configs
│ ├── data
│ ├── outputs
│ └── requirements.txt
└── scripts
└── submit_training.sh
I tried to run the ng_run command from my working directory (called OwkinZero/agentic). First, in order to have access to the command I installed nemo_gym in editable mode. Then I encountered a first issue: the env variables defined in my env.yaml file (located at the root of OwkinZero/agentic) were not loaded. I had to add the file to the config_paths list.
So here is the commands I run
config_paths="/fsx/xav/code/OwkinZero/agentic/env.yaml,/fsx/xav/code/OwkinZero/agentic/gym/responses_api_agents/idea_generator_agent/configs/idea_generator_agent.yaml,/fsx/xav/code/OwkinZero/agentic/gym/resources_servers/llm_judge_reward/configs/llm_judge_reward.yaml,/fsx/xav/code/OwkinZero/agentic/gym/responses_api_agents/idea_generator_agent/configs/gpt_5_nano.yaml"
ng_run "+config_paths=[${config_paths}]"
And here is the error that I get
Starting Ray cluster...
2026-01-22 16:36:42,971 INFO worker.py:1942 -- Started a local Ray instance. View the dashboard at http://127.0.0.1:8265
Started Ray cluster at 10.1.25.93:56390
Traceback (most recent call last):
File "/fsx/xav/code/OwkinZero/agentic/.venv/bin/ng_run", line 10, in <module>
sys.exit(run())
^^^^^
File "/fsx/xav/code/OwkinZero/agentic/.venv/lib/python3.12/site-packages/nemo_gym/cli.py", line 396, in run
rh.start(global_config_dict_parser_config)
File "/fsx/xav/code/OwkinZero/agentic/.venv/lib/python3.12/site-packages/nemo_gym/cli.py", line 212, in start
command = f"""{_setup_env_command(dir_path, global_config_dict)} \\
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/fsx/xav/code/OwkinZero/agentic/.venv/lib/python3.12/site-packages/nemo_gym/cli.py", line 78, in _setup_env_command
raise RuntimeError(f"Missing pyproject.toml or requirements.txt for uv venv setup in server dir: {dir_path}")
RuntimeError: Missing pyproject.toml or requirements.txt for uv venv setup in server dir: /fsx/xav/code/OwkinZero/agentic/.venv/lib/python3.12/site-packages/responses_api_agents/idea_generator_agent
INFO: Started server process [1900511]
INFO: Waiting for application startup.
INFO: Application startup complete.
INFO: Uvicorn running on http://127.0.0.1:11000 (Press CTRL+C to quit)
Note the /fsx/xav/code/OwkinZero/agentic/.venv/lib/python3.12/site-packages/responses_api_agents/idea_generator_agent actually does not exist.
The only workaround that I found was to create symbolic links from my custom resource servers and resource api agents to the corresponding folder in the Gym repo and to run ng_run from Gym but that's not very convenient.
Is there a way to run ng_run from my project root or am I forced to put new resource servers in the Gym directory?
- Dominant language
- Python
- Stars
- 1.2k
- Forks
- 349
- Avg merge
- 1d 21h
- Merged PRs (30d)
- 318
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from NVIDIA-NeMo/Gym
-
community-request waiting-on-maintainers
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
NVIDIA-NeMo/Gym#3500 ·
-
Difficulty 1/5 1-3 hours Newbie friendliness 74/100
NVIDIA-NeMo/Gym#3328 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
NVIDIA-NeMo/Gym#3312 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
NVIDIA-NeMo/Gym#2994 ·
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
NVIDIA-NeMo/Gym#2937 · 1 comment ·
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
bancolombia/sentinel#23 ·
-
test md OpenCI
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
integration:quickjs org:external priority:backlog topic:code-interpreter topic:middleware type:feature
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
langchain-ai/deepagents#6450 ·
-
bug client
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100