cosmos3-codebase-nav

작성자: nvidia

Cosmos3 패키지 코드베이스를 탐색하여 매개변수, 구성, 기본값, 스크립트 및 문서가 어디에 있는지 찾습니다. 사용자가 "X는 어디에 있나요..."라고 물을 때 사용합니다.

npx skills add https://github.com/nvidia/cosmos-framework --skill cosmos3-codebase-nav

Cosmos3 Codebase Navigation

When to use this skill

  • Use this skill when an agent is navigating the Cosmos3 package
  • Use this skill to answer "where is X", "how do I find the config for Y", or any file-location question
  • Use this skill when the user opens or edits cosmos3 files and needs orientation

Path convention

All paths below are relative to this file's location (.agents/skills/cosmos3-codebase-nav/). The repo is laid out as:

  • cosmos_framework/ — main training package (data, model, trainer, callbacks, checkpoint, utils, …).
  • cosmos_framework/configs/base/experiment/ — vfm (generator) experiment SKUs referenced by [train.train_policy].experiment in the recipe TOMLs.
  • cosmos_framework/configs/base/reasoner/experiment/ — vlm (reasoner) experiment SKUs.
  • cosmos_framework/inference/ — inference subpackage (args, model, inference engine, defaults, Ray serving, common helpers).
  • cosmos_framework/scripts/ — top-level entry-point scripts (train, inference, eval, export_model, convert_model_to_dcp, upsample_prompts, caption_from_video, captions_to_sft_jsonl, action_policy_server, …). Invoked as python -m cosmos_framework.scripts.<name>.
  • examples/toml/sft_config/<recipe>.toml + examples/launch_sft_<recipe>.sh — paired SFT recipes (training entry-point input). The shell sources examples/_sft_launcher_common.sh, which forwards into cosmos_framework.scripts.train --sft-toml=....
  • cosmos_framework/configs/toml_config/ — pydantic schemas (sft_config.py) and helpers that validate the recipe TOML at load time.

Quick Reference

Where parameters and defaults live

What you're looking forFile
Sampling params (num_steps, guidance, shift, fps, etc.)../../../cosmos_framework/inference/args.pySamplingArgs, SamplingOverrides
Per-modality default values../../../cosmos_framework/inference/defaults/<mode>/sample_args.json
Setup params (parallelism, checkpoints, model path)../../../cosmos_framework/inference/args.pyOmniSetupArgs, OmniSetupOverrides
Common args base classes../../../cosmos_framework/inference/common/args.pyArgsBase, OverridesBase
Ray serving parallelism presets../../../cosmos_framework/inference/ray/configs/latency.yaml, ../../../cosmos_framework/inference/ray/configs/throughput.yaml
Feature flags../../../cosmos_framework/utils/flags.py
Prompt upsampler system prompt../../../cosmos_framework/inference/defaults/prompt_upsampler.txt
Video captioner system prompt../../../cosmos_framework/inference/defaults/video_captioner.txt
SFT recipe TOMLs (paired with examples/launch_sft_*.sh)../../../examples/toml/sft_config/<recipe>.toml
SFT pydantic schema (validates the recipe TOML)../../../cosmos_framework/configs/toml_config/sft_config.py
Training experiment SKUs (vfm)../../../cosmos_framework/configs/base/experiment/
Training experiment SKUs (vlm / reasoner)../../../cosmos_framework/configs/base/reasoner/experiment/
Example inputs../../../inputs/omni/t2i.json, ../../../inputs/omni/t2v.json, ../../../inputs/omni/i2v.json, …

Available modality modes for defaults: text2image, text2video, image2video, image2image, video2video, forward_dynamics, inverse_dynamics, wam.

Config defaults resolution chain

When a user runs inference, default parameter values are resolved in this order:

cosmos_framework/inference/defaults/<mode>/sample_args.json     # 1. Per-modality JSON defaults (num_steps, guidance, shift, fps, etc.)
        ↓
_load_modality_defaults() in cosmos_framework/inference/args.py # 2. Loaded and cached at import time
        ↓
SamplingArgs / SamplingOverrides                      # 3. Pydantic models with field-level validation
        ↓
OmniSampleOverrides.build_sample()                    # 4. Merges user overrides → final resolved args
        ↓
_RESOLUTION_SHIFT_DEFAULTS[model_size, resolution]    # 5. Model+resolution shift override (if user didn't set shift)
        ↓
CLI flags (--guidance, --shift, etc.)                 # 6. User overrides from command line

The _RESOLUTION_SHIFT_DEFAULTS table in ../../../cosmos_framework/inference/args.py (on OmniSampleOverrides) overrides the default shift based on model size and resolution, unless the user explicitly specified --shift.

ModeDefault fileKey defaults
text2image../../../cosmos_framework/inference/defaults/text2image/sample_args.jsonnum_frames=1, guidance=6.0, shift=10.0
text2video../../../cosmos_framework/inference/defaults/text2video/sample_args.jsonnum_frames=189, guidance=6.0, shift=10.0
image2video../../../cosmos_framework/inference/defaults/image2video/sample_args.jsonnum_frames=189, guidance=6.0, shift=10.0

Action and video2video modes also have defaults under cosmos_framework/inference/defaults/{image2image,video2video,forward_dynamics,inverse_dynamics,policy}/sample_args.json.

Users can also supply a custom defaults file per-request via the defaults_file field in sample arguments (see ../../../docs/inference.md).

Where to make changes

TaskEdit
Change a built-in default value../../../cosmos_framework/inference/defaults/<mode>/sample_args.json
Add a new CLI parameterSamplingArgs + SamplingOverrides in ../../../cosmos_framework/inference/args.py, then add to each sample_args.json
Change parallelism presets../../../cosmos_framework/inference/ray/configs/latency.yaml or throughput.yaml
Add a new script../../../cosmos_framework/scripts/ — follow inference.py as the pattern

Key entry points

Entry pointHow to run
Batch inferencepython -m cosmos_framework.scripts.inference
Trainingpython -m cosmos_framework.scripts.train --sft-toml=examples/toml/sft_config/<recipe>.toml
Online serving (Ray)python -m cosmos_framework.inference.ray.serve
Submit to Ray serverpython -m cosmos_framework.inference.ray.submit
Gradio UIpython -m cosmos_framework.inference.ray.gradio
Prompt upsamplingpython -m cosmos_framework.scripts.upsample_prompts
Model export (HF)python -m cosmos_framework.scripts.export_model
DCP conversionpython -m cosmos_framework.scripts.convert_model_to_dcp
Diffusers conversionpython -m cosmos_framework.scripts.convert_model_to_diffusers
Video captioningpython -m cosmos_framework.scripts.caption_from_video
Captions → SFT JSONLpython -m cosmos_framework.scripts.captions_to_sft_jsonl
Action policy server (LIBERO HTTP)python -m cosmos_framework.scripts.action_policy_server_libero
Action policy server (RoboLab WS)python -m cosmos_framework.scripts.action_policy_server_robolab

Documentation

DocCovers
../../../AGENTS.mdCommands, rules, key file locations (read this first)
../../../README.mdOverview, quickstart, examples
../../../docs/setup.mdInstallation, environment, checkpoints
../../../docs/code_structure.mdRepo layout and per-subpackage tour of cosmos_framework/
../../../docs/inference.mdSample args, default values, custom defaults
../../../docs/training.mdSFT / post-training workflow
../../../docs/faq.mdFAQ, tips, and troubleshooting

nvidia의 다른 스킬

compileiq-debug
nvidia
무언가 잘못되었을 때 사용: Search()가 멈추거나, 모든 평가가 INVALID_SCORE를 반환하거나, 점수가 개선되지 않거나, 모든 설정이 동일한 숫자를 반환하거나, ptxas 오류 등이 발생할 때
create-github-pr
nvidia
gh CLI를 사용하여 GitHub 풀 리퀘스트를 생성합니다. 사용자가 새 PR을 만들거나, 코드 리뷰를 제출하거나, 풀 리퀘스트를 열고자 할 때 사용합니다. 트리거 키워드 -…
nemoclaw-maintainer-cross-issue-sweep
nvidia
다른 열린 이슈들을 스캔하여 주어진 PR이 함께 수정하거나 실수로 망가뜨릴 수 있는 이슈를 찾습니다. 인접 수정 기회와 모순 위험을 file:line…과 함께 출력합니다.
fhir-basics
nvidia
에이전트에게 FHIR R4 API의 작동 방식, 사용 가능한 리소스, 검색 매개변수를 사용한 쿼리 방법, 모든 응답 형식을 올바르게 파싱하는 방법을 가르칩니다…
compileiq-validate-result
nvidia
검색이 완료된 후, 속도 향상을 청구하거나 ACF를 발송하기 전에 사용합니다. dump_results CSV를 로드하고, 상위 K개 후보(단일 목표)를 추출합니다…
changelog-audit
nvidia
릴리스 전에 Warp CHANGELOG.md를 감사합니다: 누락된 항목 복구, 사용자 영향별 정렬, 항목 언어 다듬기, 줄 바꿈, (릴리스 브랜치 모드) 비교 업데이트…
maintain-dynamic-plugins
nvidia
NeMo Relay 동적 플러그인 로더, 매니페스트, Rust 네이티브 SDK, gRPC 워커 프로토콜, Python 워커 SDK, 문서, 테스트 및 릴리스 워크플로 커버리지를 유지 관리합니다.
dgx-diagnose
nvidia
일반적인 DGX Station GB300 문제 진단 — CUDA 충돌, 잘못된 GPU 타겟팅, vLLM/SGLang 컨테이너 버그, MIG 상태 문제, NVLink/Fabric Manager 오류,…