You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs: source: union, clean config errors, and new discovery/validate CLI commands (#1754)
Documents the config/CLI features merged for epic #1205 that were not
yet reflected in the docs. Requested follow-up: a single doc PR covering
the recently merged config/CLI work.
## What's documented
| Area | Change | Merged in |
|---|---|---|
| `reference/cli-commands.mdx` | New `gym list environments`, `gym list
agents`, and `gym env validate` sections (+ Quick-Reference entries) |
#1635, #1671, #1599 |
| `troubleshooting/configuration.mdx` | Three `config_paths` startup
errors (Config Path Not Found, Malformed `config_paths`, No Server
Instances) + a `gym env validate` pre-flight tip; corrected the stale
`ServerRefNotFound` message | #1609, #1599 |
| `data/index.mdx` | Unified dataset `source:` block + dedicated
"Dataset `source`" subsection + legacy-deprecation note | #1637 |
| `data/download-huggingface.mdx` | Auto-download example migrated to
`source: { type: huggingface }` | #1637 |
| `reference/faq.mdx` | Dataset example and field bullets rewritten
around `source:` | #1637 |
| `environment-tutorials/single-step-environment.mdx` | Scaffold comment
updated to reference `source:` | #1637 |
---------
Signed-off-by: Wojciech Prazuch <wprazuch@nvidia.com>
Copy file name to clipboardExpand all lines: fern/versions/latest/pages/data/download-huggingface.mdx
+4-3Lines changed: 4 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -229,14 +229,15 @@ gym dataset download \
229
229
230
230
<Accordiontitle="Automatic Downloads During Data Preparation">
231
231
232
-
NeMo Gym can automatically download missing datasets during data preparation. Configure `huggingface_identifier` in your resources server config:
232
+
NeMo Gym can automatically download missing datasets during data preparation. Declare a `source:` block (`type: huggingface`) in your resources server config:
If `jsonl_fpath` doesn't exist locally, NeMo Gym downloads from `huggingface_identifier`before processing.
257
+
If `jsonl_fpath` doesn't exist locally, NeMo Gym downloads from the dataset's `source:` (here, the Hugging Face `repo_id`) before processing. The legacy `huggingface_identifier:` block still works but is deprecated in favor of `source:`.
The legacy `huggingface_identifier:` / `gitlab_identifier:` blocks still work (a deprecation warning is emitted), so existing configs keep running — but new configs should use `source:`.
142
+
143
+
</Note>
144
+
119
145
### Valid Licenses
120
146
121
147
`Apache 2.0`· `MIT` · `GNU General Public License v3.0` · `Creative Commons Attribution 4.0 International` · `Creative Commons Attribution-ShareAlike 4.0 International` · `TBD` · `NVIDIA Internal Use Only, Do Not Distribute`
# The scaffold also generates train/validation dataset entries
297
-
#with gitlab_identifier blocks. Those are omitted here since
298
-
# we only have example data at this stage.
297
+
#(which can declare a `source:` block — the unified dataset source).
298
+
#Those are omitted here since we only have example data at this stage.
299
299
```
300
300
301
301
The `domain` field categorizes your resource server and is **required**. Common values: `math`, `coding`, `agent`, `knowledge`, `instruction_following`, `long_context`, `safety`, `games`, `e2e`, `other`.
Copy file name to clipboardExpand all lines: fern/versions/latest/pages/reference/cli-commands.mdx
+53-4Lines changed: 53 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,9 +19,11 @@ gym --help # list all command groups
19
19
gym --version [--json] # print version and system info
20
20
ng ... # 'ng' is an alias for 'gym'
21
21
22
-
# Discover benchmarks
23
-
gym list benchmarks [--json] # list available benchmarks
24
-
gym search <query> [--json] # filter the benchmark list by name
22
+
# Discover
23
+
gym list benchmarks [--json] # list available benchmarks
24
+
gym list environments [--json] # list available environments by name
25
+
gym list agents [--json] # list agent harnesses and how each composes
26
+
gym search <query> [--json] # filter the benchmark list by name
25
27
26
28
# Datasets
27
29
gym dataset upload # upload a prepared dataset to HF (default) or GitLab
@@ -34,9 +36,10 @@ gym dataset collate # validate and collate a dataset
34
36
# Environments
35
37
gym env init # scaffold a new resources server
36
38
gym env resolve # resolve and print the final merged config
39
+
gym env validate # validate a config (no Ray, no servers) — fast pre-flight check
37
40
gym env packages # list packages in a server's virtual environment
38
41
gym env test# test resources server(s); all of them if none is given
39
-
gym env start # start the servers
42
+
gym env start # start the servers
40
43
gym env status # show running servers
41
44
42
45
# Evaluation
@@ -143,6 +146,32 @@ gym list benchmarks
143
146
gym list benchmarks --json | jq '.[].name'
144
147
```
145
148
149
+
### `gym list environments`
150
+
151
+
List the environments available under `environments/`, by short name (with their domain and description). The names map to `environments/<name>/config.yaml` and can be passed to `--environment` on commands like `gym env start` / `gym eval run`.
152
+
153
+
| Option | Description |
154
+
| --- | --- |
155
+
|`--json`| Output the environment list as JSON. |
156
+
157
+
```bash
158
+
gym list environments
159
+
gym list environments --json | jq '.[].name'
160
+
```
161
+
162
+
### `gym list agents`
163
+
164
+
List the agent harnesses under `responses_api_agents/`, with each one's composition pattern — **composable** (Pattern A: references a separate resources server, so it can be wired into a matching environment) vs **self-contained** (Pattern B: ships its own framework/environment) — plus its config variants.
165
+
166
+
| Option | Description |
167
+
| --- | --- |
168
+
|`--json`| Output the agent list as JSON (includes the `self_contained` flag). |
169
+
170
+
```bash
171
+
gym list agents
172
+
gym list agents --json | jq '.[] | {name, self_contained}'
173
+
```
174
+
146
175
### `gym search`
147
176
148
177
List benchmarks whose name, agent, resources server, dataset, or domain matches a query.
@@ -323,6 +352,26 @@ gym env resolve \
323
352
++responses_create_params.temperature=0.6
324
353
```
325
354
355
+
### `gym env validate`
356
+
357
+
Validate a config without starting Ray or any server subprocess — a fast pre-flight check that catches config mistakes (missing/malformed `config_paths`, unknown server cross-references, unset mandatory `???` values, schema errors) in well under a second instead of after a Ray bootstrap. Exits `0` when valid, or `1` with a clean message (no traceback) when not. A model config is **not** required — model interpolations resolve against a dummy model; pass one (or `--model-type`) if you want it validated too.
358
+
359
+
| Option | Description |
360
+
| --- | --- |
361
+
|`--config PATH`| Config file to load. Repeatable. |
362
+
|`--environment NAME` / `--benchmark NAME`| Validate a named environment / benchmark config. |
363
+
|`--resources-server NAME`| Validate a named resources server config. |
364
+
|`--model-type NAME`| Also load a named model config (otherwise a dummy `policy_model` is used). |
365
+
|`--model` / `--model-url` / `--model-api-key`| Override model name, base URL, and API key. |
| `type` | Yes | `example`, `train`, or `validation` |
101
101
| `jsonl_fpath` | Yes | Path to data file |
102
102
| `license` | For train/validation | License identifier (see values below) |
103
+
| `source` | No | Where to fetch the data from when it's missing locally. A `source:` block with `type: gitlab` (`dataset_name`, `version`, `artifact_fpath`) or `type: huggingface` (`repo_id`, optional `artifact_fpath`). Replaces the deprecated `gitlab_identifier:` / `huggingface_identifier:` blocks. |
103
104
| `num_repeats` | No | Repeat dataset n times (default: `1`) |
@@ -200,21 +193,22 @@ A dataset object consists of:
200
193
- Type: train, validation, or example. Train and validation are as used in NeMo RL or other train frameworks. More information about the example type is in the next section.
201
194
- Jsonl fpath: the local file path to your jsonl file for this dataset.
202
195
- Num repeats: optionally repeat each row when preparing or collating data. Defaults to 1 if unspecified.
203
-
- GitLab identifier: The remote path to the dataset as held in the GitLab dataset registry. This field is required for train and validation datasets. Not required for example datasets since those are required to be committed to Git.
204
-
- Hugging Face identifier: The remote path to the dataset on Hugging Face. Contains `repo_id` (required) and optionally `artifact_fpath` for raw file repos. If `artifact_fpath` is omitted, the datasets library will infer the `split` from the dataset `type`.
196
+
- Source: the unified `source:` block declaring where the dataset is fetched from when it's missing locally. `type` selects the backend:
197
+
- `gitlab` — the GitLab dataset registry: `dataset_name`, `version`, `artifact_fpath`.
198
+
- `huggingface` — the Hugging Face Hub: `repo_id`(required) and optionally `artifact_fpath` for raw-file repos (if omitted, the split is inferred from the dataset `type`).
199
+
200
+
Required for train and validation datasets; not for example datasets (those are committed to Git). The legacy `gitlab_identifier:` / `huggingface_identifier:` fields still work (with a deprecation warning) and may be set together as a gitlab-primary / huggingface-fallback pair, but `source:` is preferred for new configs.
205
201
- License: The license of that dataset. Required for train and validation datasets; not required for example datasets.
206
202
- Start idx, end idx: used for slicing your dataset.
0 commit comments