NVIDIA-NeMo / NVIDIA-NeMo/Gym

Add inline comments to auto-generated YAML configs for better developer UX

Open
#191 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

core-infra usability
Dominant language
Python
Stars
1.2k
Forks
349
Avg merge
1d 21h
Merged PRs (30d)
318

Description

Issue Type

Enhancement / UX Improvement

Description

Problem
Server YAML configuration files generated by ng_init_resources_server are difficult to understand without consulting external documentation. New users struggle to understand the structure, required fields, and available options, creating unnecessary friction in the onboarding experience.

Motivation:
While building tutorials for #119, I realized that YAML configs are unusable without consulting documentation. This creates a poor developer experience, especially for new users trying to get started quickly.

Current Experience:

# Current generated config (no guidance)
simple_weather_simple_agent:
  responses_api_agents:
    simple_agent:
      entrypoint: app.py
      resources_server:
        type: resources_servers
        name: simple_weather
      model_server:
        type: responses_api_models
        name: policy_model

Proposed Improvement

Add inline comments to generated YAML configs to explain:

  • What each field does
  • Required vs optional fields
  • Common values and examples
  • References to related documentation

Example of Improved Config:

# Server ID - unique name used in requests and references
simple_weather_simple_agent:
  # Server type - must be one of: responses_api_models, resources_servers, responses_api_agents
  # These match the 3 top-level folders in NeMo-Gym
  responses_api_agents:
    # Implementation type - must match a folder name inside responses_api_agents/
    simple_agent:
      # Entrypoint - Python file to run (relative to implementation folder)
      entrypoint: app.py
      
      # Resources configuration
      resources_server:
        type: resources_servers               # What type of server to reference
        name: simple_weather                  # Which specific server instance
      
      # Model configuration (uses policy_* variables from env.yaml)
      model_server:
        type: responses_api_models
        name: policy_model                    # References the model server
Benefits:
  • Self-documenting: Users understand configs without external docs
  • Faster onboarding: Reduce time to first successful agent run
  • Fewer errors: Clear guidance prevents common configuration mistakes
  • Better discoverability: Users learn about available options inline
  • Consistency: All generated configs follow the same documentation pattern

Proposed Acceptance Criteria:

  • Update ng_init_resources_server command to add comments
  • Add comments to all template YAML files in resources/
  • Consider adding validation hints (e.g., "# Valid values: localhost, 0.0.0.0")
  • Document the comment conventions for contributors
  • Update tutorials (#119) to reference inline YAML comments as primary documentation

Related:
Tutorial 03 - Interacting with Agents in NeMo Gym (where users first encounter configs)
Tutorial 09 - Configuration Management (which explains these concepts)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the ng_init_resources_server command and the YAML templates under resources/. Review Tutorial 03, Tutorial 09, and the related issue #119 to align the inline comments and conventions. Done means generated configs and all relevant templates include accurate guidance, contributor conventions are documented, and the tutorials reference the comments.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.