From a0ba71c47014ea428e7fc30a716f8e9a582730e2 Mon Sep 17 00:00:00 2001 From: Chad Voegele Date: Tue, 28 Jul 2026 10:19:24 -0500 Subject: [PATCH 1/4] Add ModelOpt agent plugin marketplace Signed-off-by: Chad Voegele --- .agents/README.md | 42 +++++++++---------- .agents/TOOLING.md | 5 +++ .agents/plugins/marketplace.json | 20 +++++++++ .agents/scripts/sync-upstream-skills.sh | 5 ++- .agents/skills | 1 + .claude-plugin/marketplace.json | 21 ++++++++++ .claude/skills/benchmark-model-kernels | 1 + .markdownlint-cli2.yaml | 4 +- .pre-commit-config.yaml | 4 +- AGENTS.md | 10 ++--- README.md | 20 ++++++++- plugins/modelopt/.claude-plugin/plugin.json | 20 +++++++++ plugins/modelopt/.codex-plugin/plugin.json | 37 ++++++++++++++++ .../skills/accessing-mlflow/SKILL.md | 0 .../skills/benchmark-model-kernels/SKILL.md | 0 .../scripts/benchmark_model.py | 0 .../scripts/benchmark_via_builtin.py | 0 .../tests/test_benchmark_model.py | 0 .../tests/test_benchmark_via_builtin.py | 0 plugins/modelopt/skills/common/SKILL.md | 10 +++++ .../modelopt}/skills/common/credentials.md | 0 .../skills/common/environment-setup.md | 0 .../skills/common/remote-execution.md | 0 .../modelopt}/skills/common/remote_exec.sh | 0 .../modelopt}/skills/common/slurm-setup.md | 0 .../skills/common/workspace-management.md | 0 .../modelopt}/skills/compare-results/SKILL.md | 0 .../skills/compare-results/tests/evals.json | 0 .../modelopt}/skills/day0-release/SKILL.md | 0 .../day0-release/scripts/gate_compare.py | 0 .../skills/day0-release/scripts/gate_ptq.py | 0 .../skills/day0-release/scripts/gate_run.py | 0 .../skills/day0-release/tests/evals.json | 0 .../skills/day0-release/tests/test_gates.py | 0 .../modelopt}/skills/debug/SKILL.md | 0 .../modelopt}/skills/deployment/SKILL.md | 0 .../deployment/references/benchmarking.md | 0 .../skills/deployment/references/setup.md | 0 .../skills/deployment/references/sglang.md | 0 .../deployment/references/support-matrix.md | 0 .../skills/deployment/references/trtllm.md | 0 .../references/unsupported-models.md | 0 .../skills/deployment/references/vllm.md | 0 .../skills/deployment/scripts/deploy.sh | 0 .../skills/deployment/tests/evals.json | 0 .../skills/eagle3-new-model/SKILL.md | 0 .../skills/eagle3-review-logs/SKILL.md | 0 .../modelopt}/skills/eagle3-triage/SKILL.md | 0 .../modelopt}/skills/eagle3-validate/SKILL.md | 0 .../modelopt}/skills/evaluation/SKILL.md | 0 .../skills/evaluation/recipes/env.example | 0 .../recipes/examples/example_eval.yaml | 0 .../recipes/examples/example_eval_next.yaml | 0 .../gym_gdpval/example_gym_gdpval.yaml | 0 .../recipes/tasks/aa/gpqa_diamond.md | 0 .../skills/evaluation/recipes/tasks/aa/hle.md | 0 .../evaluation/recipes/tasks/aa/ifbench.md | 0 .../skills/evaluation/recipes/tasks/aa/lcr.md | 0 .../evaluation/recipes/tasks/aa/mmmu_pro.md | 0 .../recipes/tasks/aa/omniscience.md | 0 .../evaluation/recipes/tasks/aa/scicode.md | 0 .../recipes/tasks/aa/tau2_bench_telecom.md | 0 .../evaluation/recipes/tasks/aa_gym/gdpval.md | 0 .../tasks/aa_next/swebench_verified.md | 0 .../tasks/aa_next/terminal_bench_2_1.md | 0 .../evaluation/recipes/tasks/aime_2025.md | 0 .../evaluation/recipes/tasks/livecodebench.md | 0 .../evaluation/recipes/tasks/mmlu_pro.md | 0 .../evaluation/references/gym-gdpval.md | 0 .../references/model-card-research.md | 0 .../evaluation/references/multi-node.md | 0 .../skills/evaluation/references/nel-next.md | 0 .../evaluation/references/parallelism.md | 0 .../references/quantization-benchmarks.md | 0 .../evaluation/references/run-validation.md | 0 .../skills/evaluation/references/slurm.md | 0 .../skills/evaluation/tests/evals.json | 0 .../modelopt}/skills/launching-evals/SKILL.md | 0 .../references/analyze-results.md | 0 .../benchmarks/swebench-general-info.md | 0 .../benchmarks/terminal-bench-general-info.md | 0 .../terminal-bench-trace-analysis.md | 0 .../references/check-progress.md | 0 .../references/debug-failed-runs.md | 0 .../references/run-evaluation.md | 0 .../skills/launching-evals/tests.json | 0 .../modelopt}/skills/monitor/SKILL.md | 0 .../modelopt}/skills/ptq/SKILL.md | 0 .../ptq/references/checkpoint-validation.md | 0 .../skills/ptq/references/launcher-guide.md | 0 .../skills/ptq/references/slurm-setup-ptq.md | 0 .../ptq/references/unsupported-models.md | 0 .../modelopt}/skills/ptq/tests.json | 0 .../modelopt}/skills/qad/SKILL.md | 0 .../skills/quant-recipe-search/SKILL.md | 0 .../references/qwen36_case_study.md | 0 .../references/recipe_iteration.md | 0 .../skills/release-cherry-pick/SKILL.md | 0 pyproject.toml | 2 +- 99 files changed, 166 insertions(+), 36 deletions(-) create mode 100644 .agents/plugins/marketplace.json create mode 120000 .agents/skills create mode 100644 .claude-plugin/marketplace.json create mode 120000 .claude/skills/benchmark-model-kernels create mode 100644 plugins/modelopt/.claude-plugin/plugin.json create mode 100644 plugins/modelopt/.codex-plugin/plugin.json rename {.agents => plugins/modelopt}/skills/accessing-mlflow/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/benchmark-model-kernels/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/benchmark-model-kernels/scripts/benchmark_model.py (100%) rename {.agents => plugins/modelopt}/skills/benchmark-model-kernels/scripts/benchmark_via_builtin.py (100%) rename {.agents => plugins/modelopt}/skills/benchmark-model-kernels/tests/test_benchmark_model.py (100%) rename {.agents => plugins/modelopt}/skills/benchmark-model-kernels/tests/test_benchmark_via_builtin.py (100%) create mode 100644 plugins/modelopt/skills/common/SKILL.md rename {.agents => plugins/modelopt}/skills/common/credentials.md (100%) rename {.agents => plugins/modelopt}/skills/common/environment-setup.md (100%) rename {.agents => plugins/modelopt}/skills/common/remote-execution.md (100%) rename {.agents => plugins/modelopt}/skills/common/remote_exec.sh (100%) rename {.agents => plugins/modelopt}/skills/common/slurm-setup.md (100%) rename {.agents => plugins/modelopt}/skills/common/workspace-management.md (100%) rename {.agents => plugins/modelopt}/skills/compare-results/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/compare-results/tests/evals.json (100%) rename {.agents => plugins/modelopt}/skills/day0-release/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/day0-release/scripts/gate_compare.py (100%) rename {.agents => plugins/modelopt}/skills/day0-release/scripts/gate_ptq.py (100%) rename {.agents => plugins/modelopt}/skills/day0-release/scripts/gate_run.py (100%) rename {.agents => plugins/modelopt}/skills/day0-release/tests/evals.json (100%) rename {.agents => plugins/modelopt}/skills/day0-release/tests/test_gates.py (100%) rename {.agents => plugins/modelopt}/skills/debug/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/references/benchmarking.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/references/setup.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/references/sglang.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/references/support-matrix.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/references/trtllm.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/references/unsupported-models.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/references/vllm.md (100%) rename {.agents => plugins/modelopt}/skills/deployment/scripts/deploy.sh (100%) rename {.agents => plugins/modelopt}/skills/deployment/tests/evals.json (100%) rename {.agents => plugins/modelopt}/skills/eagle3-new-model/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/eagle3-review-logs/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/eagle3-triage/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/eagle3-validate/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/env.example (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/examples/example_eval.yaml (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/examples/example_eval_next.yaml (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/gpqa_diamond.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/hle.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/ifbench.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/lcr.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/mmmu_pro.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/omniscience.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/scicode.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa/tau2_bench_telecom.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa_gym/gdpval.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa_next/swebench_verified.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aa_next/terminal_bench_2_1.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/aime_2025.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/livecodebench.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/recipes/tasks/mmlu_pro.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/gym-gdpval.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/model-card-research.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/multi-node.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/nel-next.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/parallelism.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/quantization-benchmarks.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/run-validation.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/references/slurm.md (100%) rename {.agents => plugins/modelopt}/skills/evaluation/tests/evals.json (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/references/analyze-results.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/references/benchmarks/swebench-general-info.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/references/benchmarks/terminal-bench-general-info.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/references/benchmarks/terminal-bench-trace-analysis.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/references/check-progress.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/references/debug-failed-runs.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/references/run-evaluation.md (100%) rename {.agents => plugins/modelopt}/skills/launching-evals/tests.json (100%) rename {.agents => plugins/modelopt}/skills/monitor/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/ptq/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/ptq/references/checkpoint-validation.md (100%) rename {.agents => plugins/modelopt}/skills/ptq/references/launcher-guide.md (100%) rename {.agents => plugins/modelopt}/skills/ptq/references/slurm-setup-ptq.md (100%) rename {.agents => plugins/modelopt}/skills/ptq/references/unsupported-models.md (100%) rename {.agents => plugins/modelopt}/skills/ptq/tests.json (100%) rename {.agents => plugins/modelopt}/skills/qad/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/quant-recipe-search/SKILL.md (100%) rename {.agents => plugins/modelopt}/skills/quant-recipe-search/references/qwen36_case_study.md (100%) rename {.agents => plugins/modelopt}/skills/quant-recipe-search/references/recipe_iteration.md (100%) rename {.agents => plugins/modelopt}/skills/release-cherry-pick/SKILL.md (100%) diff --git a/.agents/README.md b/.agents/README.md index d24fce1d4a2..3e0f9f7be35 100644 --- a/.agents/README.md +++ b/.agents/README.md @@ -1,24 +1,25 @@ -# `.agents/` — agent-agnostic source of truth +# `.agents/` — agent compatibility and shared config -This directory is the canonical location for assets shared by AI coding agents -working in this repository (Claude Code, Codex, Cursor, …). +This directory exposes the ModelOpt plugin skills to repository-local agents +and holds shared configuration. ## Layout ```text .agents/ -├── skills/ # SKILL.md files (canonical) -│ └── /SKILL.md +├── skills → ../plugins/modelopt/skills +├── plugins/ +│ └── marketplace.json # Codex marketplace ├── scripts/ # shared helper scripts (sync-upstream-skills.sh, …) └── clusters.yaml.example # remote-cluster config template -``` - -## Why this exists -Different agents look for skills/config in vendor-specific directories. Rather -than maintaining N copies that drift out of sync, **`.agents/` is the single -source of truth** — each agent's guidance or install mechanism points here -directly. +plugins/modelopt/ +├── .claude-plugin/ +├── .codex-plugin/ +└── skills/ # canonical SKILL.md files + ├── common/ # shared skill support files + └── /SKILL.md +``` ## How each agent finds these @@ -26,21 +27,18 @@ Each agent points at `.agents/` through whatever mechanism it supports — never a copy: - **Claude Code** only auto-discovers skills under `.claude/skills/`, so - `.claude/` holds relative in-repo symlinks back into `.agents/`: - `.claude/skills → ../.agents/skills`, `.claude/scripts → ../.agents/scripts`, - and `.claude/clusters.yaml.example → ../.agents/clusters.yaml.example`. These - follow the same committed-symlink pattern already used elsewhere in this repo - (e.g. `CLAUDE.md`, `tools/launcher/modules/Model-Optimizer`). -- **Future agents** (Codex, Cursor, …) add their own symlink or config pointing - at `.agents/`. + `.claude/skills/` holds relative symlinks into `.agents/skills/`. +- **Repository agents** use `.agents/skills`, a relative symlink into the + plugin. +- **Claude Code and Codex plugins** load `plugins/modelopt/skills` directly. ## Editing rules -- **Always edit files under `.agents/`**. +- **Always edit skills under `plugins/modelopt/skills/`**. - Vendored-verbatim skills (`launching-evals`, `accessing-mlflow`) are managed by `.agents/scripts/sync-upstream-skills.sh` — do not modify by hand. -- New skills go in `.agents/skills//SKILL.md` following the - conventions of existing skills (e.g. `.agents/skills/monitor/SKILL.md`). +- New skills go in `plugins/modelopt/skills//SKILL.md`. +- Shared support files go in `plugins/modelopt/skills/common/`. ## Project-level cluster config diff --git a/.agents/TOOLING.md b/.agents/TOOLING.md index ecef150f4ec..caadc9d70cf 100644 --- a/.agents/TOOLING.md +++ b/.agents/TOOLING.md @@ -8,6 +8,11 @@ of the always-loaded agent instructions. Update `AGENTS.md` for repository-wide agent instructions. `CLAUDE.md` is symlinked to `AGENTS.md`, so changes there apply to both Codex and Claude Code. +## Installable Skills + +The `modelopt` plugin packages the repository skills for use from any +workspace. Installation commands are in the [README](../README.md#ai-agents). + ## Local Overrides For private local instructions, use the tool-specific override file: diff --git a/.agents/plugins/marketplace.json b/.agents/plugins/marketplace.json new file mode 100644 index 00000000000..ff27684af67 --- /dev/null +++ b/.agents/plugins/marketplace.json @@ -0,0 +1,20 @@ +{ + "name": "modelopt", + "interface": { + "displayName": "NVIDIA Model Optimizer" + }, + "plugins": [ + { + "name": "modelopt", + "source": { + "source": "local", + "path": "./plugins/modelopt" + }, + "policy": { + "installation": "AVAILABLE", + "authentication": "ON_INSTALL" + }, + "category": "Productivity" + } + ] +} diff --git a/.agents/scripts/sync-upstream-skills.sh b/.agents/scripts/sync-upstream-skills.sh index 616643d322c..1828bbff1aa 100755 --- a/.agents/scripts/sync-upstream-skills.sh +++ b/.agents/scripts/sync-upstream-skills.sh @@ -26,13 +26,14 @@ # # Requires: gh, base64, awk. Run from the repo root. # -# The script overwrites .agents/skills// with upstream contents and +# The script overwrites plugins/modelopt/skills// through the +# .agents/skills compatibility symlink and # re-applies our provenance lines into each SKILL.md frontmatter. If you have # local changes to a vendored skill, they will be lost — that is expected, # since vendored-verbatim skills should not be modified locally. # # Note: .claude/skills/ (and other agent-specific skill dirs) are symlinks to -# .agents/skills/ — see .agents/README.md. +# plugins/modelopt/skills/ — see .agents/README.md. set -euo pipefail diff --git a/.agents/skills b/.agents/skills new file mode 120000 index 00000000000..c3f0b779e13 --- /dev/null +++ b/.agents/skills @@ -0,0 +1 @@ +../plugins/modelopt/skills \ No newline at end of file diff --git a/.claude-plugin/marketplace.json b/.claude-plugin/marketplace.json new file mode 100644 index 00000000000..38a471ff876 --- /dev/null +++ b/.claude-plugin/marketplace.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json.schemastore.org/claude-code-marketplace.json", + "name": "modelopt", + "version": "0.1.0", + "description": "Model Optimizer agent plugins.", + "owner": { + "name": "NVIDIA Corporation" + }, + "plugins": [ + { + "name": "modelopt", + "source": "./plugins/modelopt", + "description": "Skills for Model Optimizer development, quantization, deployment, and evaluation.", + "version": "0.1.0", + "author": { + "name": "NVIDIA Corporation" + }, + "category": "development" + } + ] +} diff --git a/.claude/skills/benchmark-model-kernels b/.claude/skills/benchmark-model-kernels new file mode 120000 index 00000000000..1bfd1fefe85 --- /dev/null +++ b/.claude/skills/benchmark-model-kernels @@ -0,0 +1 @@ +../../.agents/skills/benchmark-model-kernels \ No newline at end of file diff --git a/.markdownlint-cli2.yaml b/.markdownlint-cli2.yaml index 86a0387160b..c1d0da5fab3 100644 --- a/.markdownlint-cli2.yaml +++ b/.markdownlint-cli2.yaml @@ -14,5 +14,5 @@ config: # Vendored upstream skills — kept byte-identical to upstream via # .agents/scripts/sync-upstream-skills.sh; do not reformat. ignores: - - ".agents/skills/launching-evals/**" - - ".agents/skills/accessing-mlflow/**" + - "plugins/modelopt/skills/launching-evals/**" + - "plugins/modelopt/skills/accessing-mlflow/**" diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e36b9fc69f7..85b5577494c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -70,10 +70,10 @@ repos: exclude: ^modelopt_recipes/configs/ - id: sync-claude-skills - name: sync .claude/skills/ symlinks from .agents/skills/ + name: sync .claude/skills/ symlinks from plugin skills entry: bash tools/precommit/sync_claude_skills.sh language: system - files: ^\.agents/skills/ + files: ^plugins/modelopt/skills/ pass_filenames: false - id: check-launcher-yaml diff --git a/AGENTS.md b/AGENTS.md index 223aec70a96..c91c257f884 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -7,12 +7,10 @@ These instructions apply to AI-assisted work in this repository. - Start with `README.md` for project overview and install. - Use `modelopt/` for source, `tests/` for focused test coverage, and `examples/` or `docs/` for usage patterns. -- **Agent skills and shared config live under `.agents/`** — the canonical, - agent-agnostic source of truth (`.agents/skills//SKILL.md`, - `.agents/scripts/`, `.agents/clusters.yaml.example`). Claude Code's - `.claude/skills`, `.claude/scripts`, and `.claude/clusters.yaml.example` are - relative symlinks into `.agents/`. Always edit files under `.agents/`, not the - symlink path. See `.agents/README.md` for the convention. +- **Agent skills live under `plugins/modelopt/skills/`**, the installable + plugin's canonical skill tree. `.agents/skills` and `.claude/skills` expose + those skills through relative symlinks. Shared agent config and scripts + remain under `.agents/`. See `.agents/README.md` for the convention. ## Coding guidelines diff --git a/README.md b/README.md index d9b9744b3a5..16b1ae14f8b 100644 --- a/README.md +++ b/README.md @@ -170,7 +170,25 @@ Please read our [Contributing](./CONTRIBUTING.md) guidelines for details on how ## AI Agents -For AI-assisted development setup, see the [agent tooling notes](./.agents/TOOLING.md). +ModelOpt's agent skills can be installed from this repository and used in any +workspace. + +### Claude Code + +```bash +claude plugin marketplace add https://github.com/NVIDIA/Model-Optimizer.git +claude plugin install modelopt@modelopt +``` + +### Codex + +```bash +codex plugin marketplace add https://github.com/NVIDIA/Model-Optimizer.git +``` + +Then open `/plugins`, select the `modelopt` marketplace, and install `modelopt`. +Contributors can also use the skills directly from a checkout. See the +[agent tooling notes](./.agents/TOOLING.md). ### Top Contributors diff --git a/plugins/modelopt/.claude-plugin/plugin.json b/plugins/modelopt/.claude-plugin/plugin.json new file mode 100644 index 00000000000..47393444cfe --- /dev/null +++ b/plugins/modelopt/.claude-plugin/plugin.json @@ -0,0 +1,20 @@ +{ + "$schema": "https://json.schemastore.org/claude-code-plugin-manifest.json", + "name": "modelopt", + "displayName": "ModelOpt", + "version": "0.1.0", + "description": "Skills for Model Optimizer development, quantization, deployment, and evaluation.", + "author": { + "name": "NVIDIA Corporation" + }, + "homepage": "https://github.com/NVIDIA/Model-Optimizer", + "repository": "https://github.com/NVIDIA/Model-Optimizer", + "license": "Apache-2.0", + "keywords": [ + "modelopt", + "quantization", + "evaluation", + "deployment", + "llm" + ] +} diff --git a/plugins/modelopt/.codex-plugin/plugin.json b/plugins/modelopt/.codex-plugin/plugin.json new file mode 100644 index 00000000000..f8faa0b1555 --- /dev/null +++ b/plugins/modelopt/.codex-plugin/plugin.json @@ -0,0 +1,37 @@ +{ + "name": "modelopt", + "version": "0.1.0", + "description": "Skills for Model Optimizer development, quantization, deployment, and evaluation.", + "author": { + "name": "NVIDIA Corporation", + "url": "https://github.com/NVIDIA/Model-Optimizer" + }, + "homepage": "https://github.com/NVIDIA/Model-Optimizer", + "repository": "https://github.com/NVIDIA/Model-Optimizer", + "license": "Apache-2.0", + "keywords": [ + "modelopt", + "quantization", + "evaluation", + "deployment", + "llm" + ], + "skills": "./skills/", + "interface": { + "displayName": "ModelOpt", + "shortDescription": "Optimize, deploy, and evaluate models.", + "longDescription": "Provides Model Optimizer workflows for post-training quantization, deployment, evaluation, result comparison, and release validation.", + "developerName": "NVIDIA", + "category": "Developer Tools", + "capabilities": [ + "Interactive", + "Write" + ], + "defaultPrompt": [ + "Quantize this model with ModelOpt.", + "Deploy and evaluate this checkpoint.", + "Compare the baseline and quantized results." + ], + "brandColor": "#76B900" + } +} diff --git a/.agents/skills/accessing-mlflow/SKILL.md b/plugins/modelopt/skills/accessing-mlflow/SKILL.md similarity index 100% rename from .agents/skills/accessing-mlflow/SKILL.md rename to plugins/modelopt/skills/accessing-mlflow/SKILL.md diff --git a/.agents/skills/benchmark-model-kernels/SKILL.md b/plugins/modelopt/skills/benchmark-model-kernels/SKILL.md similarity index 100% rename from .agents/skills/benchmark-model-kernels/SKILL.md rename to plugins/modelopt/skills/benchmark-model-kernels/SKILL.md diff --git a/.agents/skills/benchmark-model-kernels/scripts/benchmark_model.py b/plugins/modelopt/skills/benchmark-model-kernels/scripts/benchmark_model.py similarity index 100% rename from .agents/skills/benchmark-model-kernels/scripts/benchmark_model.py rename to plugins/modelopt/skills/benchmark-model-kernels/scripts/benchmark_model.py diff --git a/.agents/skills/benchmark-model-kernels/scripts/benchmark_via_builtin.py b/plugins/modelopt/skills/benchmark-model-kernels/scripts/benchmark_via_builtin.py similarity index 100% rename from .agents/skills/benchmark-model-kernels/scripts/benchmark_via_builtin.py rename to plugins/modelopt/skills/benchmark-model-kernels/scripts/benchmark_via_builtin.py diff --git a/.agents/skills/benchmark-model-kernels/tests/test_benchmark_model.py b/plugins/modelopt/skills/benchmark-model-kernels/tests/test_benchmark_model.py similarity index 100% rename from .agents/skills/benchmark-model-kernels/tests/test_benchmark_model.py rename to plugins/modelopt/skills/benchmark-model-kernels/tests/test_benchmark_model.py diff --git a/.agents/skills/benchmark-model-kernels/tests/test_benchmark_via_builtin.py b/plugins/modelopt/skills/benchmark-model-kernels/tests/test_benchmark_via_builtin.py similarity index 100% rename from .agents/skills/benchmark-model-kernels/tests/test_benchmark_via_builtin.py rename to plugins/modelopt/skills/benchmark-model-kernels/tests/test_benchmark_via_builtin.py diff --git a/plugins/modelopt/skills/common/SKILL.md b/plugins/modelopt/skills/common/SKILL.md new file mode 100644 index 00000000000..a75c58f6b93 --- /dev/null +++ b/plugins/modelopt/skills/common/SKILL.md @@ -0,0 +1,10 @@ +--- +name: common +description: Shared ModelOpt support files. Use only when another ModelOpt skill directs you here. +--- + +# Shared ModelOpt Support + +This skill is a placeholder required for Codex plugin validation. + +Read only the file named by the calling ModelOpt skill. diff --git a/.agents/skills/common/credentials.md b/plugins/modelopt/skills/common/credentials.md similarity index 100% rename from .agents/skills/common/credentials.md rename to plugins/modelopt/skills/common/credentials.md diff --git a/.agents/skills/common/environment-setup.md b/plugins/modelopt/skills/common/environment-setup.md similarity index 100% rename from .agents/skills/common/environment-setup.md rename to plugins/modelopt/skills/common/environment-setup.md diff --git a/.agents/skills/common/remote-execution.md b/plugins/modelopt/skills/common/remote-execution.md similarity index 100% rename from .agents/skills/common/remote-execution.md rename to plugins/modelopt/skills/common/remote-execution.md diff --git a/.agents/skills/common/remote_exec.sh b/plugins/modelopt/skills/common/remote_exec.sh similarity index 100% rename from .agents/skills/common/remote_exec.sh rename to plugins/modelopt/skills/common/remote_exec.sh diff --git a/.agents/skills/common/slurm-setup.md b/plugins/modelopt/skills/common/slurm-setup.md similarity index 100% rename from .agents/skills/common/slurm-setup.md rename to plugins/modelopt/skills/common/slurm-setup.md diff --git a/.agents/skills/common/workspace-management.md b/plugins/modelopt/skills/common/workspace-management.md similarity index 100% rename from .agents/skills/common/workspace-management.md rename to plugins/modelopt/skills/common/workspace-management.md diff --git a/.agents/skills/compare-results/SKILL.md b/plugins/modelopt/skills/compare-results/SKILL.md similarity index 100% rename from .agents/skills/compare-results/SKILL.md rename to plugins/modelopt/skills/compare-results/SKILL.md diff --git a/.agents/skills/compare-results/tests/evals.json b/plugins/modelopt/skills/compare-results/tests/evals.json similarity index 100% rename from .agents/skills/compare-results/tests/evals.json rename to plugins/modelopt/skills/compare-results/tests/evals.json diff --git a/.agents/skills/day0-release/SKILL.md b/plugins/modelopt/skills/day0-release/SKILL.md similarity index 100% rename from .agents/skills/day0-release/SKILL.md rename to plugins/modelopt/skills/day0-release/SKILL.md diff --git a/.agents/skills/day0-release/scripts/gate_compare.py b/plugins/modelopt/skills/day0-release/scripts/gate_compare.py similarity index 100% rename from .agents/skills/day0-release/scripts/gate_compare.py rename to plugins/modelopt/skills/day0-release/scripts/gate_compare.py diff --git a/.agents/skills/day0-release/scripts/gate_ptq.py b/plugins/modelopt/skills/day0-release/scripts/gate_ptq.py similarity index 100% rename from .agents/skills/day0-release/scripts/gate_ptq.py rename to plugins/modelopt/skills/day0-release/scripts/gate_ptq.py diff --git a/.agents/skills/day0-release/scripts/gate_run.py b/plugins/modelopt/skills/day0-release/scripts/gate_run.py similarity index 100% rename from .agents/skills/day0-release/scripts/gate_run.py rename to plugins/modelopt/skills/day0-release/scripts/gate_run.py diff --git a/.agents/skills/day0-release/tests/evals.json b/plugins/modelopt/skills/day0-release/tests/evals.json similarity index 100% rename from .agents/skills/day0-release/tests/evals.json rename to plugins/modelopt/skills/day0-release/tests/evals.json diff --git a/.agents/skills/day0-release/tests/test_gates.py b/plugins/modelopt/skills/day0-release/tests/test_gates.py similarity index 100% rename from .agents/skills/day0-release/tests/test_gates.py rename to plugins/modelopt/skills/day0-release/tests/test_gates.py diff --git a/.agents/skills/debug/SKILL.md b/plugins/modelopt/skills/debug/SKILL.md similarity index 100% rename from .agents/skills/debug/SKILL.md rename to plugins/modelopt/skills/debug/SKILL.md diff --git a/.agents/skills/deployment/SKILL.md b/plugins/modelopt/skills/deployment/SKILL.md similarity index 100% rename from .agents/skills/deployment/SKILL.md rename to plugins/modelopt/skills/deployment/SKILL.md diff --git a/.agents/skills/deployment/references/benchmarking.md b/plugins/modelopt/skills/deployment/references/benchmarking.md similarity index 100% rename from .agents/skills/deployment/references/benchmarking.md rename to plugins/modelopt/skills/deployment/references/benchmarking.md diff --git a/.agents/skills/deployment/references/setup.md b/plugins/modelopt/skills/deployment/references/setup.md similarity index 100% rename from .agents/skills/deployment/references/setup.md rename to plugins/modelopt/skills/deployment/references/setup.md diff --git a/.agents/skills/deployment/references/sglang.md b/plugins/modelopt/skills/deployment/references/sglang.md similarity index 100% rename from .agents/skills/deployment/references/sglang.md rename to plugins/modelopt/skills/deployment/references/sglang.md diff --git a/.agents/skills/deployment/references/support-matrix.md b/plugins/modelopt/skills/deployment/references/support-matrix.md similarity index 100% rename from .agents/skills/deployment/references/support-matrix.md rename to plugins/modelopt/skills/deployment/references/support-matrix.md diff --git a/.agents/skills/deployment/references/trtllm.md b/plugins/modelopt/skills/deployment/references/trtllm.md similarity index 100% rename from .agents/skills/deployment/references/trtllm.md rename to plugins/modelopt/skills/deployment/references/trtllm.md diff --git a/.agents/skills/deployment/references/unsupported-models.md b/plugins/modelopt/skills/deployment/references/unsupported-models.md similarity index 100% rename from .agents/skills/deployment/references/unsupported-models.md rename to plugins/modelopt/skills/deployment/references/unsupported-models.md diff --git a/.agents/skills/deployment/references/vllm.md b/plugins/modelopt/skills/deployment/references/vllm.md similarity index 100% rename from .agents/skills/deployment/references/vllm.md rename to plugins/modelopt/skills/deployment/references/vllm.md diff --git a/.agents/skills/deployment/scripts/deploy.sh b/plugins/modelopt/skills/deployment/scripts/deploy.sh similarity index 100% rename from .agents/skills/deployment/scripts/deploy.sh rename to plugins/modelopt/skills/deployment/scripts/deploy.sh diff --git a/.agents/skills/deployment/tests/evals.json b/plugins/modelopt/skills/deployment/tests/evals.json similarity index 100% rename from .agents/skills/deployment/tests/evals.json rename to plugins/modelopt/skills/deployment/tests/evals.json diff --git a/.agents/skills/eagle3-new-model/SKILL.md b/plugins/modelopt/skills/eagle3-new-model/SKILL.md similarity index 100% rename from .agents/skills/eagle3-new-model/SKILL.md rename to plugins/modelopt/skills/eagle3-new-model/SKILL.md diff --git a/.agents/skills/eagle3-review-logs/SKILL.md b/plugins/modelopt/skills/eagle3-review-logs/SKILL.md similarity index 100% rename from .agents/skills/eagle3-review-logs/SKILL.md rename to plugins/modelopt/skills/eagle3-review-logs/SKILL.md diff --git a/.agents/skills/eagle3-triage/SKILL.md b/plugins/modelopt/skills/eagle3-triage/SKILL.md similarity index 100% rename from .agents/skills/eagle3-triage/SKILL.md rename to plugins/modelopt/skills/eagle3-triage/SKILL.md diff --git a/.agents/skills/eagle3-validate/SKILL.md b/plugins/modelopt/skills/eagle3-validate/SKILL.md similarity index 100% rename from .agents/skills/eagle3-validate/SKILL.md rename to plugins/modelopt/skills/eagle3-validate/SKILL.md diff --git a/.agents/skills/evaluation/SKILL.md b/plugins/modelopt/skills/evaluation/SKILL.md similarity index 100% rename from .agents/skills/evaluation/SKILL.md rename to plugins/modelopt/skills/evaluation/SKILL.md diff --git a/.agents/skills/evaluation/recipes/env.example b/plugins/modelopt/skills/evaluation/recipes/env.example similarity index 100% rename from .agents/skills/evaluation/recipes/env.example rename to plugins/modelopt/skills/evaluation/recipes/env.example diff --git a/.agents/skills/evaluation/recipes/examples/example_eval.yaml b/plugins/modelopt/skills/evaluation/recipes/examples/example_eval.yaml similarity index 100% rename from .agents/skills/evaluation/recipes/examples/example_eval.yaml rename to plugins/modelopt/skills/evaluation/recipes/examples/example_eval.yaml diff --git a/.agents/skills/evaluation/recipes/examples/example_eval_next.yaml b/plugins/modelopt/skills/evaluation/recipes/examples/example_eval_next.yaml similarity index 100% rename from .agents/skills/evaluation/recipes/examples/example_eval_next.yaml rename to plugins/modelopt/skills/evaluation/recipes/examples/example_eval_next.yaml diff --git a/.agents/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml b/plugins/modelopt/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml similarity index 100% rename from .agents/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml rename to plugins/modelopt/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml diff --git a/.agents/skills/evaluation/recipes/tasks/aa/gpqa_diamond.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/gpqa_diamond.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/gpqa_diamond.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/gpqa_diamond.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa/hle.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/hle.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/hle.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/hle.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa/ifbench.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/ifbench.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/ifbench.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/ifbench.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa/lcr.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/lcr.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/lcr.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/lcr.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa/mmmu_pro.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/mmmu_pro.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/mmmu_pro.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/mmmu_pro.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa/omniscience.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/omniscience.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/omniscience.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/omniscience.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa/scicode.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/scicode.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/scicode.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/scicode.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa/tau2_bench_telecom.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa/tau2_bench_telecom.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa/tau2_bench_telecom.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa/tau2_bench_telecom.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa_gym/gdpval.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa_gym/gdpval.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa_gym/gdpval.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa_gym/gdpval.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa_next/swebench_verified.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa_next/swebench_verified.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa_next/swebench_verified.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa_next/swebench_verified.md diff --git a/.agents/skills/evaluation/recipes/tasks/aa_next/terminal_bench_2_1.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa_next/terminal_bench_2_1.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aa_next/terminal_bench_2_1.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aa_next/terminal_bench_2_1.md diff --git a/.agents/skills/evaluation/recipes/tasks/aime_2025.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aime_2025.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/aime_2025.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/aime_2025.md diff --git a/.agents/skills/evaluation/recipes/tasks/livecodebench.md b/plugins/modelopt/skills/evaluation/recipes/tasks/livecodebench.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/livecodebench.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/livecodebench.md diff --git a/.agents/skills/evaluation/recipes/tasks/mmlu_pro.md b/plugins/modelopt/skills/evaluation/recipes/tasks/mmlu_pro.md similarity index 100% rename from .agents/skills/evaluation/recipes/tasks/mmlu_pro.md rename to plugins/modelopt/skills/evaluation/recipes/tasks/mmlu_pro.md diff --git a/.agents/skills/evaluation/references/gym-gdpval.md b/plugins/modelopt/skills/evaluation/references/gym-gdpval.md similarity index 100% rename from .agents/skills/evaluation/references/gym-gdpval.md rename to plugins/modelopt/skills/evaluation/references/gym-gdpval.md diff --git a/.agents/skills/evaluation/references/model-card-research.md b/plugins/modelopt/skills/evaluation/references/model-card-research.md similarity index 100% rename from .agents/skills/evaluation/references/model-card-research.md rename to plugins/modelopt/skills/evaluation/references/model-card-research.md diff --git a/.agents/skills/evaluation/references/multi-node.md b/plugins/modelopt/skills/evaluation/references/multi-node.md similarity index 100% rename from .agents/skills/evaluation/references/multi-node.md rename to plugins/modelopt/skills/evaluation/references/multi-node.md diff --git a/.agents/skills/evaluation/references/nel-next.md b/plugins/modelopt/skills/evaluation/references/nel-next.md similarity index 100% rename from .agents/skills/evaluation/references/nel-next.md rename to plugins/modelopt/skills/evaluation/references/nel-next.md diff --git a/.agents/skills/evaluation/references/parallelism.md b/plugins/modelopt/skills/evaluation/references/parallelism.md similarity index 100% rename from .agents/skills/evaluation/references/parallelism.md rename to plugins/modelopt/skills/evaluation/references/parallelism.md diff --git a/.agents/skills/evaluation/references/quantization-benchmarks.md b/plugins/modelopt/skills/evaluation/references/quantization-benchmarks.md similarity index 100% rename from .agents/skills/evaluation/references/quantization-benchmarks.md rename to plugins/modelopt/skills/evaluation/references/quantization-benchmarks.md diff --git a/.agents/skills/evaluation/references/run-validation.md b/plugins/modelopt/skills/evaluation/references/run-validation.md similarity index 100% rename from .agents/skills/evaluation/references/run-validation.md rename to plugins/modelopt/skills/evaluation/references/run-validation.md diff --git a/.agents/skills/evaluation/references/slurm.md b/plugins/modelopt/skills/evaluation/references/slurm.md similarity index 100% rename from .agents/skills/evaluation/references/slurm.md rename to plugins/modelopt/skills/evaluation/references/slurm.md diff --git a/.agents/skills/evaluation/tests/evals.json b/plugins/modelopt/skills/evaluation/tests/evals.json similarity index 100% rename from .agents/skills/evaluation/tests/evals.json rename to plugins/modelopt/skills/evaluation/tests/evals.json diff --git a/.agents/skills/launching-evals/SKILL.md b/plugins/modelopt/skills/launching-evals/SKILL.md similarity index 100% rename from .agents/skills/launching-evals/SKILL.md rename to plugins/modelopt/skills/launching-evals/SKILL.md diff --git a/.agents/skills/launching-evals/references/analyze-results.md b/plugins/modelopt/skills/launching-evals/references/analyze-results.md similarity index 100% rename from .agents/skills/launching-evals/references/analyze-results.md rename to plugins/modelopt/skills/launching-evals/references/analyze-results.md diff --git a/.agents/skills/launching-evals/references/benchmarks/swebench-general-info.md b/plugins/modelopt/skills/launching-evals/references/benchmarks/swebench-general-info.md similarity index 100% rename from .agents/skills/launching-evals/references/benchmarks/swebench-general-info.md rename to plugins/modelopt/skills/launching-evals/references/benchmarks/swebench-general-info.md diff --git a/.agents/skills/launching-evals/references/benchmarks/terminal-bench-general-info.md b/plugins/modelopt/skills/launching-evals/references/benchmarks/terminal-bench-general-info.md similarity index 100% rename from .agents/skills/launching-evals/references/benchmarks/terminal-bench-general-info.md rename to plugins/modelopt/skills/launching-evals/references/benchmarks/terminal-bench-general-info.md diff --git a/.agents/skills/launching-evals/references/benchmarks/terminal-bench-trace-analysis.md b/plugins/modelopt/skills/launching-evals/references/benchmarks/terminal-bench-trace-analysis.md similarity index 100% rename from .agents/skills/launching-evals/references/benchmarks/terminal-bench-trace-analysis.md rename to plugins/modelopt/skills/launching-evals/references/benchmarks/terminal-bench-trace-analysis.md diff --git a/.agents/skills/launching-evals/references/check-progress.md b/plugins/modelopt/skills/launching-evals/references/check-progress.md similarity index 100% rename from .agents/skills/launching-evals/references/check-progress.md rename to plugins/modelopt/skills/launching-evals/references/check-progress.md diff --git a/.agents/skills/launching-evals/references/debug-failed-runs.md b/plugins/modelopt/skills/launching-evals/references/debug-failed-runs.md similarity index 100% rename from .agents/skills/launching-evals/references/debug-failed-runs.md rename to plugins/modelopt/skills/launching-evals/references/debug-failed-runs.md diff --git a/.agents/skills/launching-evals/references/run-evaluation.md b/plugins/modelopt/skills/launching-evals/references/run-evaluation.md similarity index 100% rename from .agents/skills/launching-evals/references/run-evaluation.md rename to plugins/modelopt/skills/launching-evals/references/run-evaluation.md diff --git a/.agents/skills/launching-evals/tests.json b/plugins/modelopt/skills/launching-evals/tests.json similarity index 100% rename from .agents/skills/launching-evals/tests.json rename to plugins/modelopt/skills/launching-evals/tests.json diff --git a/.agents/skills/monitor/SKILL.md b/plugins/modelopt/skills/monitor/SKILL.md similarity index 100% rename from .agents/skills/monitor/SKILL.md rename to plugins/modelopt/skills/monitor/SKILL.md diff --git a/.agents/skills/ptq/SKILL.md b/plugins/modelopt/skills/ptq/SKILL.md similarity index 100% rename from .agents/skills/ptq/SKILL.md rename to plugins/modelopt/skills/ptq/SKILL.md diff --git a/.agents/skills/ptq/references/checkpoint-validation.md b/plugins/modelopt/skills/ptq/references/checkpoint-validation.md similarity index 100% rename from .agents/skills/ptq/references/checkpoint-validation.md rename to plugins/modelopt/skills/ptq/references/checkpoint-validation.md diff --git a/.agents/skills/ptq/references/launcher-guide.md b/plugins/modelopt/skills/ptq/references/launcher-guide.md similarity index 100% rename from .agents/skills/ptq/references/launcher-guide.md rename to plugins/modelopt/skills/ptq/references/launcher-guide.md diff --git a/.agents/skills/ptq/references/slurm-setup-ptq.md b/plugins/modelopt/skills/ptq/references/slurm-setup-ptq.md similarity index 100% rename from .agents/skills/ptq/references/slurm-setup-ptq.md rename to plugins/modelopt/skills/ptq/references/slurm-setup-ptq.md diff --git a/.agents/skills/ptq/references/unsupported-models.md b/plugins/modelopt/skills/ptq/references/unsupported-models.md similarity index 100% rename from .agents/skills/ptq/references/unsupported-models.md rename to plugins/modelopt/skills/ptq/references/unsupported-models.md diff --git a/.agents/skills/ptq/tests.json b/plugins/modelopt/skills/ptq/tests.json similarity index 100% rename from .agents/skills/ptq/tests.json rename to plugins/modelopt/skills/ptq/tests.json diff --git a/.agents/skills/qad/SKILL.md b/plugins/modelopt/skills/qad/SKILL.md similarity index 100% rename from .agents/skills/qad/SKILL.md rename to plugins/modelopt/skills/qad/SKILL.md diff --git a/.agents/skills/quant-recipe-search/SKILL.md b/plugins/modelopt/skills/quant-recipe-search/SKILL.md similarity index 100% rename from .agents/skills/quant-recipe-search/SKILL.md rename to plugins/modelopt/skills/quant-recipe-search/SKILL.md diff --git a/.agents/skills/quant-recipe-search/references/qwen36_case_study.md b/plugins/modelopt/skills/quant-recipe-search/references/qwen36_case_study.md similarity index 100% rename from .agents/skills/quant-recipe-search/references/qwen36_case_study.md rename to plugins/modelopt/skills/quant-recipe-search/references/qwen36_case_study.md diff --git a/.agents/skills/quant-recipe-search/references/recipe_iteration.md b/plugins/modelopt/skills/quant-recipe-search/references/recipe_iteration.md similarity index 100% rename from .agents/skills/quant-recipe-search/references/recipe_iteration.md rename to plugins/modelopt/skills/quant-recipe-search/references/recipe_iteration.md diff --git a/.agents/skills/release-cherry-pick/SKILL.md b/plugins/modelopt/skills/release-cherry-pick/SKILL.md similarity index 100% rename from .agents/skills/release-cherry-pick/SKILL.md rename to plugins/modelopt/skills/release-cherry-pick/SKILL.md diff --git a/pyproject.toml b/pyproject.toml index a2a94a38c58..e090fb62f86 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -218,7 +218,7 @@ extend-ignore = [ "examples/*" = ["D"] "noxfile.py" = ["D", "E501"] "tests/*" = ["B017", "D", "E402", "PT012"] -".agents/skills/*/tests/test_*.py" = ["D", "E402"] # Skill test scripts: docstring (D) + sys.path import-order (E402) exemptions +"plugins/modelopt/skills/*/tests/test_*.py" = ["D", "E402"] # Skill test scripts: docstring (D) + sys.path import-order (E402) exemptions "*/_[a-zA-Z]*" = ["D"] # Private packages (_abc/*.py) or modules (_xyz.py) "*.ipynb" = ["D", "E501"] # Ignore missing docstrings or line length for Jupyter notebooks "modelopt/torch/kernels/*" = ["N803", "N806", "E731"] # triton style From 1b0947f6a4e8a7eaf5efef013c9a085c577879e9 Mon Sep 17 00:00:00 2001 From: Chad Voegele Date: Tue, 11 Aug 2026 18:24:57 +0000 Subject: [PATCH 2/4] Fix installed plugin helper paths Signed-off-by: Chad Voegele --- .../skills/benchmark-model-kernels/SKILL.md | 6 ++--- .../skills/common/environment-setup.md | 6 ++--- .../skills/common/remote-execution.md | 4 +-- plugins/modelopt/skills/common/remote_exec.sh | 2 +- plugins/modelopt/skills/common/slurm-setup.md | 2 +- .../modelopt/skills/compare-results/SKILL.md | 12 ++++----- plugins/modelopt/skills/day0-release/SKILL.md | 20 +++++++------- .../skills/day0-release/tests/test_gates.py | 2 +- plugins/modelopt/skills/deployment/SKILL.md | 27 ++++++++++--------- .../skills/deployment/tests/evals.json | 2 +- plugins/modelopt/skills/evaluation/SKILL.md | 12 ++++----- .../skills/evaluation/recipes/env.example | 4 +-- .../recipes/examples/example_eval_next.yaml | 4 +-- .../gym_gdpval/example_gym_gdpval.yaml | 2 +- .../evaluation/recipes/tasks/aa_gym/gdpval.md | 2 +- .../evaluation/references/gym-gdpval.md | 4 +-- .../skills/evaluation/references/nel-next.md | 18 ++++++------- .../skills/evaluation}/scripts/gdpval-sif.sh | 4 +-- .../skills/evaluation}/scripts/nel-next.sh | 8 +++--- plugins/modelopt/skills/ptq/SKILL.md | 19 +++++++------ .../skills/ptq/references/slurm-setup-ptq.md | 6 ++--- .../ptq/references/unsupported-models.md | 2 +- plugins/modelopt/skills/qad/SKILL.md | 4 +-- .../references/recipe_iteration.md | 4 +-- 24 files changed, 91 insertions(+), 85 deletions(-) rename {.agents => plugins/modelopt/skills/evaluation}/scripts/gdpval-sif.sh (98%) rename {.agents => plugins/modelopt/skills/evaluation}/scripts/nel-next.sh (95%) diff --git a/plugins/modelopt/skills/benchmark-model-kernels/SKILL.md b/plugins/modelopt/skills/benchmark-model-kernels/SKILL.md index 65e9f33520d..a054bbb3089 100644 --- a/plugins/modelopt/skills/benchmark-model-kernels/SKILL.md +++ b/plugins/modelopt/skills/benchmark-model-kernels/SKILL.md @@ -41,7 +41,7 @@ order: GPU needed: ```bash - python .agents/skills/benchmark-model-kernels/scripts/benchmark_model.py \ + python "$SKILL_DIR/scripts/benchmark_model.py" \ --tp --ep --ms ... --print_only ``` @@ -63,7 +63,7 @@ order: ```bash CUDA_VISIBLE_DEVICES= \ - python .agents/skills/benchmark-model-kernels/scripts/benchmark_model.py \ + python "$SKILL_DIR/scripts/benchmark_model.py" \ --tp --ep --ms ... \ --flashinfer_repo --workdir ``` @@ -112,7 +112,7 @@ missing shape: ```bash CUDA_VISIBLE_DEVICES= \ -python .agents/skills/benchmark-model-kernels/scripts/benchmark_via_builtin.py \ +python "$SKILL_DIR/scripts/benchmark_via_builtin.py" \ --flashinfer_repo --ms ... \ --nks ,, --workdir ``` diff --git a/plugins/modelopt/skills/common/environment-setup.md b/plugins/modelopt/skills/common/environment-setup.md index 2afdcff0da4..e6d7a0c6965 100644 --- a/plugins/modelopt/skills/common/environment-setup.md +++ b/plugins/modelopt/skills/common/environment-setup.md @@ -34,13 +34,13 @@ If the cluster config contains multiple clusters and the user did not name the t For remote, connect: ```bash -source .agents/skills/common/remote_exec.sh +source "$SKILL_DIR/remote_exec.sh" remote_load_cluster remote_check_ssh remote_detect_env # sets REMOTE_ENV_TYPE = slurm / docker / bare ``` -If remote but no config, ask user for: hostname, SSH username, SSH key path, remote workdir. Create `~/.config/modelopt/clusters.yaml` (see `skills/common/remote-execution.md` for format). +If remote but no config, ask user for: hostname, SSH username, SSH key path, remote workdir. Create `~/.config/modelopt/clusters.yaml` (see `remote-execution.md` for format). ## Env-3. What compute is available? @@ -79,4 +79,4 @@ Return to the skill's SKILL.md for the execution path based on these results. ## Multi-user / Slack bot -If `MODELOPT_WORKSPACE_ROOT` is set, read `skills/common/workspace-management.md` before proceeding. +If `MODELOPT_WORKSPACE_ROOT` is set, read `workspace-management.md` before proceeding. diff --git a/plugins/modelopt/skills/common/remote-execution.md b/plugins/modelopt/skills/common/remote-execution.md index d81afd42dc1..a0d5d18f706 100644 --- a/plugins/modelopt/skills/common/remote-execution.md +++ b/plugins/modelopt/skills/common/remote-execution.md @@ -46,7 +46,7 @@ See `.agents/clusters.yaml.example` for a fully annotated example with multiple ## 2. Connect and Establish Persistent Session ```bash -source .agents/skills/common/remote_exec.sh +source "$SKILL_DIR/remote_exec.sh" remote_load_cluster # or omit name to use default_cluster remote_check_ssh # validates connectivity + starts persistent session ``` @@ -153,6 +153,6 @@ remote_sync_from /local/output/ ## Reference Files -- **`skills/common/remote_exec.sh`** — Full utility library (session, run, sync, SLURM, Docker helpers) +- **`remote_exec.sh`** — Full utility library (session, run, sync, SLURM, Docker helpers) - **`.agents/clusters.yaml`** — Active cluster configuration (canonical; `.claude/clusters.yaml` also accepted for back-compat) - **`.agents/clusters.yaml.example`** — Annotated example config diff --git a/plugins/modelopt/skills/common/remote_exec.sh b/plugins/modelopt/skills/common/remote_exec.sh index 84e64db978a..08a5af511b9 100644 --- a/plugins/modelopt/skills/common/remote_exec.sh +++ b/plugins/modelopt/skills/common/remote_exec.sh @@ -17,7 +17,7 @@ # remote_exec.sh — Remote execution utility for ModelOpt agent skills # # Usage: -# source .agents/skills/common/remote_exec.sh +# source "$SKILL_DIR/remote_exec.sh" # remote_load_cluster # or: remote_load_cluster (uses default) # remote_check_ssh # remote_detect_env # detect SLURM vs Docker vs bare metal diff --git a/plugins/modelopt/skills/common/slurm-setup.md b/plugins/modelopt/skills/common/slurm-setup.md index 901a1ab9b2a..276f99f00ef 100644 --- a/plugins/modelopt/skills/common/slurm-setup.md +++ b/plugins/modelopt/skills/common/slurm-setup.md @@ -53,7 +53,7 @@ srun \ ### Container registry credentials (pyxis) -If `srun --container-image` uses an image from a private registry (e.g., `nvcr.io/nvidia/...`), pyxis/enroot needs registry credentials on the cluster in `~/.config/enroot/.credentials`. See `skills/common/credentials.md` for the NGC / Docker / HF token setup. Without this, `srun` fails with `401 Unauthorized` when the compute node pulls. +If `srun --container-image` uses an image from a private registry (e.g., `nvcr.io/nvidia/...`), pyxis/enroot needs registry credentials on the cluster in `~/.config/enroot/.credentials`. See `credentials.md` for the NGC / Docker / HF token setup. Without this, `srun` fails with `401 Unauthorized` when the compute node pulls. Submit and capture the job ID: diff --git a/plugins/modelopt/skills/compare-results/SKILL.md b/plugins/modelopt/skills/compare-results/SKILL.md index d6fee539e78..8960e6305cd 100644 --- a/plugins/modelopt/skills/compare-results/SKILL.md +++ b/plugins/modelopt/skills/compare-results/SKILL.md @@ -29,10 +29,9 @@ change is being measured, typically a further quantized version of the baseline. before comparing scores. If not, validate logs, server health, judge/code-execution status, sample accounting, and reasoning parsing before computing deltas. -5. For each task, use the canonical score field from the matching - `.agents/skills/evaluation/recipes/tasks/.md` Score Extraction - section. -6. Read and perform `.agents/skills/evaluation/references/run-validation.md` +5. For each task, use the canonical score field from the matching evaluation + skill task recipe, `recipes/tasks/.md`, under **Score Extraction**. +6. Use the evaluation skill's `references/run-validation.md` to perform the **External Baseline Sanity Check**. Record each source URL, protocol difference, and task status before applying the candidate-delta gate. A failed baseline blocks a success verdict; correct and rerun it first. If no @@ -80,8 +79,9 @@ If any item differs, either rerun with matched settings or label the result as not an apples-to-apples quantization comparison. These checks compare the baseline and candidate to each other. The external -baseline check in `evaluation/references/run-validation.md` separately tests -whether the baseline's absolute score is credible; both guards must be reported. +baseline check in the evaluation skill's `references/run-validation.md` +separately tests whether the baseline's absolute score is credible; both guards +must be reported. ## Report Format diff --git a/plugins/modelopt/skills/day0-release/SKILL.md b/plugins/modelopt/skills/day0-release/SKILL.md index 0fc3c67cef4..d12419460eb 100644 --- a/plugins/modelopt/skills/day0-release/SKILL.md +++ b/plugins/modelopt/skills/day0-release/SKILL.md @@ -27,8 +27,10 @@ Resolve these before starting (ask the user for anything missing): - **Model** — HF handle or checkpoint path. - **Recipe / qformat** — e.g. `nvfp4`, `fp8`, or a recipe path. One candidate for v1. -- **Cluster / launcher** — from `clusters.yaml` (see `skills/common/environment-setup.md`). -- **Eval set** — defaults to the AA suite (`evaluation/recipes/tasks/aa/`). +- **Cluster / launcher** — from `clusters.yaml` (see the common skill's + `environment-setup.md`). +- **Eval set** — defaults to the evaluation skill's AA suite + (`recipes/tasks/aa/`). - **Threshold** — max accuracy drop; default `0.01` (1%). ## The chain @@ -60,8 +62,8 @@ progress: ### Step 1 — Setup gate -Confirm credentials (`skills/common/credentials.md`) and cluster reachability -(`skills/common/remote-execution.md`). If either fails, stop with +Use the common skill's `credentials.md` and `remote-execution.md` to confirm +credentials and cluster reachability. If either fails, stop with `SYSTEMIC` — do not start PTQ. ### Step 2 — PTQ @@ -70,9 +72,9 @@ Invoke the **ptq** skill to produce the quantized checkpoint. Then gate: ```bash # The ptq skill's post-PTQ validation produces a validation-summary JSON (size -# ratio + layer-precision counts + metadata diffs; see -# ptq/references/checkpoint-validation.md). v1 gates on that summary: -python .agents/skills/day0-release/scripts/gate_ptq.py --summary +# ratio + layer-precision counts + metadata diffs; see the ptq skill's +# references/checkpoint-validation.md). v1 gates on that summary: +python "$SKILL_DIR/scripts/gate_ptq.py" --summary # add `--recipe ` to override the recipe recorded in the summary ``` @@ -100,7 +102,7 @@ the working command back into NEL's `deployment.command` and resume the eval. If the checkpoint genuinely can't serve, `POINT_INFEASIBLE`. Gate: ```bash -python .agents/skills/day0-release/scripts/gate_run.py --run +python "$SKILL_DIR/scripts/gate_run.py" --run ``` A `pass: false` here means the run is incomplete or invalid (judge/parse error, @@ -118,7 +120,7 @@ baseline. After recording the external status, produce per-task deltas and run: ```bash -python .agents/skills/day0-release/scripts/gate_compare.py \ +python "$SKILL_DIR/scripts/gate_compare.py" \ --baseline --candidate \ --threshold 0.01 ``` diff --git a/plugins/modelopt/skills/day0-release/tests/test_gates.py b/plugins/modelopt/skills/day0-release/tests/test_gates.py index 53236d5c889..cccc21874ac 100644 --- a/plugins/modelopt/skills/day0-release/tests/test_gates.py +++ b/plugins/modelopt/skills/day0-release/tests/test_gates.py @@ -18,7 +18,7 @@ These are deterministic — no GPU, cluster, or network. They test the pure decision functions that the gates rest on. Run with: - python -m pytest .agents/skills/day0-release/tests/test_gates.py + python -m pytest "$SKILL_DIR/tests/test_gates.py" """ import sys diff --git a/plugins/modelopt/skills/deployment/SKILL.md b/plugins/modelopt/skills/deployment/SKILL.md index bc189f05421..f4105307c1a 100644 --- a/plugins/modelopt/skills/deployment/SKILL.md +++ b/plugins/modelopt/skills/deployment/SKILL.md @@ -10,26 +10,26 @@ Serve a model checkpoint as an OpenAI-compatible inference endpoint. Supports vL ## Quick Start -Prefer `scripts/deploy.sh` for standard local deployments — it handles quant detection, health checks, and server lifecycle. Use the raw framework commands in Step 4 when you need flags the script doesn't support, or for remote deployment. +Prefer `$SKILL_DIR/scripts/deploy.sh` for standard local deployments — it handles quant detection, health checks, and server lifecycle. Use the raw framework commands in Step 4 when you need flags the script doesn't support, or for remote deployment. ```bash # Start vLLM server with a ModelOpt checkpoint -scripts/deploy.sh start --model ./qwen3-0.6b-fp8 +"$SKILL_DIR/scripts/deploy.sh" start --model ./qwen3-0.6b-fp8 # Start with SGLang and tensor parallelism -scripts/deploy.sh start --model ./llama-70b-nvfp4 --framework sglang --tp 4 +"$SKILL_DIR/scripts/deploy.sh" start --model ./llama-70b-nvfp4 --framework sglang --tp 4 # Start from HuggingFace hub -scripts/deploy.sh start --model nvidia/Llama-3.1-8B-Instruct-FP8 +"$SKILL_DIR/scripts/deploy.sh" start --model nvidia/Llama-3.1-8B-Instruct-FP8 # Test the API -scripts/deploy.sh test +"$SKILL_DIR/scripts/deploy.sh" test # Check status -scripts/deploy.sh status +"$SKILL_DIR/scripts/deploy.sh" status # Stop -scripts/deploy.sh stop +"$SKILL_DIR/scripts/deploy.sh" stop ``` The script handles: GPU detection, quantization flag auto-detection (FP8 vs FP4), server lifecycle (start/stop/restart/status), health check polling, and API testing. @@ -38,7 +38,7 @@ The script handles: GPU detection, quantization flag auto-detection (FP8 vs FP4) ### 0. Check workspace (multi-user / Slack bot) -If `MODELOPT_WORKSPACE_ROOT` is set, read `skills/common/workspace-management.md`. Before creating a new workspace, check the current session for existing model workspaces — especially if deploying a checkpoint from a prior PTQ run: +If `MODELOPT_WORKSPACE_ROOT` is set, use the common skill's `workspace-management.md`. Before creating a new workspace, check the current session for existing model workspaces — especially if deploying a checkpoint from a prior PTQ run: ```bash ls "$MODELOPT_WORKSPACE_ROOT//" 2>/dev/null @@ -79,7 +79,7 @@ Check the support matrix in `references/support-matrix.md` to confirm the model ### 3. Check the environment -Read `skills/common/environment-setup.md` for GPU detection, local vs remote, and SLURM/Docker/bare metal detection. After completing it you should know: GPU model/count, local or remote, and execution environment. +Use the common skill's `environment-setup.md` for GPU detection, local vs remote, and SLURM/Docker/bare metal detection. After completing it you should know: GPU model/count, local or remote, and execution environment. Then check the **deployment framework** is installed: @@ -211,12 +211,13 @@ token shapes, and how to read `profile_export_aiperf.json`. If a cluster config exists (`~/.config/modelopt/clusters.yaml`, `.agents/clusters.yaml`, or `.claude/clusters.yaml`), or the user mentions running on a remote machine: -0. **Check container registry auth** — before submitting any SLURM job with a container image, verify credentials exist on the cluster per `skills/common/slurm-setup.md` section 6. If credentials are missing for the image's registry, ask the user to fix auth or switch to an image on an authenticated registry (e.g., NGC). **Do not submit until auth is confirmed.** +0. **Check container registry auth** — before submitting any SLURM job with a container image, verify credentials exist on the cluster per the common skill's `slurm-setup.md` section 6. If credentials are missing for the image's registry, ask the user to fix auth or switch to an image on an authenticated registry (e.g., NGC). **Do not submit until auth is confirmed.** -1. **Source remote utilities:** +1. **Source remote utilities:** Load the common skill, then resolve + `remote_exec.sh` from that skill's root. ```bash - source .agents/skills/common/remote_exec.sh + source "/remote_exec.sh" remote_load_cluster remote_check_ssh remote_detect_env @@ -232,7 +233,7 @@ If a cluster config exists (`~/.config/modelopt/clusters.yaml`, `.agents/cluster 3. **Deploy based on remote environment:** - - **SLURM** — see `skills/common/slurm-setup.md` for job script templates (container setup, account/partition discovery). The server command inside the container is the same as Step 4 (e.g., `python -m vllm.entrypoints.openai.api_server --model --quantization modelopt`). After submitting, register the job and set up monitoring per the **monitor skill**. Get the node hostname from `squeue -j $JOBID -o %N`. + - **SLURM** — see the common skill's `slurm-setup.md` for job script templates (container setup, account/partition discovery). The server command inside the container is the same as Step 4 (e.g., `python -m vllm.entrypoints.openai.api_server --model --quantization modelopt`). After submitting, register the job and set up monitoring per the **monitor skill**. Get the node hostname from `squeue -j $JOBID -o %N`. - **Bare metal / Docker** — use `remote_run` to start the server directly: diff --git a/plugins/modelopt/skills/deployment/tests/evals.json b/plugins/modelopt/skills/deployment/tests/evals.json index a94bef08e3a..f9c4c037246 100644 --- a/plugins/modelopt/skills/deployment/tests/evals.json +++ b/plugins/modelopt/skills/deployment/tests/evals.json @@ -27,7 +27,7 @@ "files": [], "expected_behavior": [ "Checks for cluster config at ~/.config/modelopt/clusters.yaml, .agents/clusters.yaml, or .claude/clusters.yaml", - "Sources .agents/skills/common/remote_exec.sh", + "Sources remote_exec.sh from the loaded common skill root", "Calls remote_load_cluster, remote_check_ssh, remote_detect_env", "Checks if checkpoint is already on remote (e.g., from prior PTQ run) before syncing; only syncs if local", "For SLURM: writes a job script with srun --container-image and --container-mounts on srun line (not #SBATCH)", diff --git a/plugins/modelopt/skills/evaluation/SKILL.md b/plugins/modelopt/skills/evaluation/SKILL.md index 7c04835ade5..c0716a71d4d 100644 --- a/plugins/modelopt/skills/evaluation/SKILL.md +++ b/plugins/modelopt/skills/evaluation/SKILL.md @@ -12,7 +12,7 @@ Guide the user through creating NEL YAML configs, running evaluations, and monit ### Workspace integration -If `MODELOPT_WORKSPACE_ROOT` is set, read `skills/common/workspace-management.md` and reuse existing workspaces (this skill is usually the final stage of PTQ → Deploy → Eval; carry any deployment-time patches into `deployment.command`). +If `MODELOPT_WORKSPACE_ROOT` is set, use the common skill's `workspace-management.md` and reuse existing workspaces (this skill is usually the final stage of PTQ → Deploy → Eval; carry any deployment-time patches into `deployment.command`). ### Workflow @@ -41,7 +41,7 @@ overrides, and `services`/`benchmarks`/`cluster`/`output` schema. If the user as for one, do **not** add it to a 0.2.6 `evaluation.tasks` list — instead: 1. Read **`references/nel-next.md`** (shared: venv, schema, AWS creds, architecture, timeout strategy, MLflow, run flow) + the per-benchmark recipe `recipes/tasks/aa_next/{terminal_bench_2_1,swebench_verified}.md`; start from `recipes/examples/example_eval_next.yaml`. -2. Isolated nel-next venv: `.agents/scripts/nel-next.sh --setup-only` (keeps 0.2.6 `nel` untouched). +2. Isolated nel-next venv: `"$SKILL_DIR/scripts/nel-next.sh" --setup-only` (keeps 0.2.6 `nel` untouched). 3. Run **`modelopttools:eval-config`** (Step 3b) to write the AWS-sandbox creds + harbor infra rows (`${NEL_NEXT_EVAL_IMAGE}`, `${HARBOR_*_ECR_REPOSITORY}`) into `.env`; always include the `output.export_config.mlflow` block. 4. Dry-run → canary → full (`nel-next.sh eval run`), then **push to MLflow** — SLURM doesn't auto-export, so run `nel-next.sh mlflow-push -r -c ` after (config-driven; see `references/nel-next.md`). @@ -63,7 +63,7 @@ GDPVal: self-contained file. 3. Prerequisite — the Apptainer SIF. **If your site provides one, use it** (NVIDIA-internal: `modelopttools:eval-config` Step 3c); otherwise set - `GDPVAL_SIF_DIR` in `.env` and build with `.agents/scripts/gdpval-sif.sh` + `GDPVAL_SIF_DIR` in `.env` and build with `"$SKILL_DIR/scripts/gdpval-sif.sh"` (build-if-absent, no cross-cluster copy). Either way the mounted dir must contain the file `GDPVAL_CONTAINER_PATH` names (template: `python-3.13.gdpval.sif`) — a name mismatch passes NEL's `test -d` check and the agent then silently runs @@ -81,7 +81,7 @@ GDPVal: Run `nel --version`; if missing, instruct `pip install nemo-evaluator-launcher`. If user has an existing config, skip to Step 8 (optionally review for `???` and quantization flags first). -**Set up `.env` now (not Step 8).** The working `.env` lives at the **workspace root** — the directory you run `nel` from — matching `modelopttools:eval-config`'s convention; do **not** create it under the skill dir. (NEL does not discover `.env` by path: it reads secrets from the shell env via the `host:` prefix after you `source`, so the location is purely *which file you source* before `nel run`. Keeping the single `.env` at the workspace root avoids a stale duplicate under the symlinked, shared `.agents/` skill tree.) For judge-scored / user-sim tasks (HLE, AA-LCR, Tau2), seed it from the template if absent — the template ships under the skill dir, the working `.env` does not: `[ -f .env ] || cp .agents/skills/evaluation/recipes/env.example .env`. Then try `modelopttools:eval-config` (if available) to fill the judge `model_id`/`url` rows (user adds the secret key). Needed before Step 5, which substitutes those values into task `` placeholders. +**Set up `.env` now (not Step 8).** The working `.env` lives at the **workspace root** — the directory you run `nel` from — matching `modelopttools:eval-config`'s convention; do **not** create it under the skill dir. (NEL does not discover `.env` by path: it reads secrets from the shell env via the `host:` prefix after you `source`, so the location is purely *which file you source* before `nel run`. Keeping the single `.env` at the workspace root avoids a stale duplicate under the symlinked, shared `.agents/` skill tree.) For judge-scored / user-sim tasks (HLE, AA-LCR, Tau2), seed it from the template if absent — the template ships under the skill dir, the working `.env` does not: `[ -f .env ] || cp "$SKILL_DIR/recipes/env.example" .env`. Then try `modelopttools:eval-config` (if available) to fill the judge `model_id`/`url` rows (user adds the secret key). Needed before Step 5, which substitutes those values into task `` placeholders. **Secret safety — never open `.env` with Read/Write/Edit.** The harness mirrors later edits of any agent-opened file into the transcript, so touching `.env` leaks the keys the user adds afterward. Use shell only (`cp` to create, `source` to load — neither echoes); edit `env.example`, never `.env`; leave value entry to the user / `modelopttools:eval-config`. @@ -378,7 +378,7 @@ Public images → submit without preflight. Private/restricted → check credent ssh "grep -E '^\s*machine\s+' ~/.config/enroot/.credentials 2>/dev/null" ``` -Add credentials per `skills/common/slurm-setup.md` §6 if missing. If you can't add, switch to a compatible public image (e.g. `nvcr.io/nvidia/vllm:-py3` — check catalog.ngc.nvidia.com). **Do not retry more than once** after an auth failure. +Add credentials per the common skill's `slurm-setup.md` §6 if missing. If you can't add, switch to a compatible public image (e.g. `nvcr.io/nvidia/vllm:-py3` — check catalog.ngc.nvidia.com). **Do not retry more than once** after an auth failure. --- @@ -390,7 +390,7 @@ Run directly when the user asked to launch; otherwise ask before submitting. ```bash # .env lives at the workspace root (where you run nel); the template ships under the skill dir -[ -f .env ] || cp .agents/skills/evaluation/recipes/env.example .env # create only if Step 1 didn't +[ -f .env ] || cp "$SKILL_DIR/recipes/env.example" .env # create only if Step 1 didn't set -a && source .env && set +a # If pre_cmd/post_cmd in config (review pre_cmd first — runs arbitrary commands): diff --git a/plugins/modelopt/skills/evaluation/recipes/env.example b/plugins/modelopt/skills/evaluation/recipes/env.example index 09bd7888155..de0bfdee9ab 100644 --- a/plugins/modelopt/skills/evaluation/recipes/env.example +++ b/plugins/modelopt/skills/evaluation/recipes/env.example @@ -2,7 +2,7 @@ # # Copy this file to your workspace root (the dir you run `nel` from) — NOT into # the skill dir — and fill in the keys you need: -# cp .agents/skills/evaluation/recipes/env.example .env +# cp "$SKILL_DIR/recipes/env.example" .env # # Edit .env with your keys # set -a && source .env && set +a # @@ -45,7 +45,7 @@ NEMO_EVALUATOR_TRUST_PRE_CMD=1 # TAVILY_API_KEY= # GDPVal (nemo_gym) — persistent Apptainer SIF cache dir on the TARGET cluster's -# shared FS (a path, not a secret). .agents/scripts/gdpval-sif.sh builds the SIF +# shared FS (a path, not a secret). $SKILL_DIR/scripts/gdpval-sif.sh builds the SIF # here if absent and reuses it otherwise; the config bind-mounts this dir at # /gdpval/sif. Convention: a per-user .cache dir. # GDPVAL_SIF_DIR=//.cache/gdpval/sif diff --git a/plugins/modelopt/skills/evaluation/recipes/examples/example_eval_next.yaml b/plugins/modelopt/skills/evaluation/recipes/examples/example_eval_next.yaml index 3e44a47e594..9463c653062 100644 --- a/plugins/modelopt/skills/evaluation/recipes/examples/example_eval_next.yaml +++ b/plugins/modelopt/skills/evaluation/recipes/examples/example_eval_next.yaml @@ -3,9 +3,9 @@ # Benchmark shown = Terminal-Bench 2.1; swap the `benchmarks:` block per the recipe. # # Run via the isolated nel-next venv: -# .agents/scripts/nel-next.sh --setup-only +# "$SKILL_DIR/scripts/nel-next.sh" --setup-only # set -a && source .env && set +a # HF_TOKEN, AWS_*, NEL_NEXT_EVAL_IMAGE, HARBOR_*_ECR_REPOSITORY (from modelopttools:eval-config) -# .agents/scripts/nel-next.sh eval run recipes/examples/example_eval_next.yaml --dry-run +# "$SKILL_DIR/scripts/nel-next.sh" eval run "$SKILL_DIR/recipes/examples/example_eval_next.yaml" --dry-run # ... --submit -O benchmarks.0.max_problems=2 -O benchmarks.0.repeats=1 -O benchmarks.0.max_concurrent=2 # canary # ... --submit # full # Internal harbor infra (eval_image + ECR) comes from .env via ${VAR}; all blocks diff --git a/plugins/modelopt/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml b/plugins/modelopt/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml index 76cd40dad10..cdc513dc8cd 100644 --- a/plugins/modelopt/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml +++ b/plugins/modelopt/skills/evaluation/recipes/examples/gym_gdpval/example_gym_gdpval.yaml @@ -23,7 +23,7 @@ # Before running: `.env` needs HF_TOKEN, INFERENCE_API_KEY, TAVILY_API_KEY, # INFERENCE_JUDGE_URL, GDPVAL_SIF_DIR, NEMO_EVALUATOR_TRUST_PRE_CMD=1; and the # SIF must exist (prefer a site-provided one, else -# `srun -p cpu -t 01:00:00 --pty .agents/scripts/gdpval-sif.sh`). +# `srun -p cpu -t 01:00:00 --pty "$SKILL_DIR/scripts/gdpval-sif.sh"`). # # nel run --config example_gym_gdpval.yaml --env-file .env # diff --git a/plugins/modelopt/skills/evaluation/recipes/tasks/aa_gym/gdpval.md b/plugins/modelopt/skills/evaluation/recipes/tasks/aa_gym/gdpval.md index 00b2ff73b96..13a83562f82 100644 --- a/plugins/modelopt/skills/evaluation/recipes/tasks/aa_gym/gdpval.md +++ b/plugins/modelopt/skills/evaluation/recipes/tasks/aa_gym/gdpval.md @@ -20,7 +20,7 @@ Steps 1–9 apply — but with the branch differences below. - **Standalone** — one gym eval per config. Never add GDPVal to a multi-task `evaluation.tasks` list, and never add other tasks to a GDPVal config. - **Apptainer SIF sandbox** — prefer a site-provided SIF; otherwise - `.agents/scripts/gdpval-sif.sh` builds one into `$GDPVAL_SIF_DIR` (build-if-absent, + `$SKILL_DIR/scripts/gdpval-sif.sh` builds one into `$GDPVAL_SIF_DIR` (build-if-absent, never copied between clusters). Missing/misnamed → **silent** unsandboxed exec. - **Thinking mode is mandatory** — non-thinking loses ~86% of pairwise judgements. Serve with the model's `--reasoning-parser` and force it on via the adapter's diff --git a/plugins/modelopt/skills/evaluation/references/gym-gdpval.md b/plugins/modelopt/skills/evaluation/references/gym-gdpval.md index 999d6bd6ee0..61aaf0746f7 100644 --- a/plugins/modelopt/skills/evaluation/references/gym-gdpval.md +++ b/plugins/modelopt/skills/evaluation/references/gym-gdpval.md @@ -34,7 +34,7 @@ Step 3c has the path.) Otherwise build it on the target cluster — never copy a between clusters: ```bash -srun -p cpu -t 01:00:00 --pty .agents/scripts/gdpval-sif.sh # uses $GDPVAL_SIF_DIR +srun -p cpu -t 01:00:00 --pty "$SKILL_DIR/scripts/gdpval-sif.sh" # uses $GDPVAL_SIF_DIR ``` `gdpval-sif.sh` is idempotent (flock-guarded, atomic): it builds from `gdpval.def` at @@ -160,7 +160,7 @@ mount source, and `raise ValueError` listing the missing ones **before** any validation, and the run then silently degrades. Guard with the verify-only mode: ```bash - .agents/scripts/gdpval-sif.sh --check # uses $GDPVAL_SIF_DIR; exit 1 + lists what IS there + "$SKILL_DIR/scripts/gdpval-sif.sh" --check # uses $GDPVAL_SIF_DIR; exit 1 + lists what IS there ``` Keep `GDPVAL_SIF_NAME` / the helper's default in sync with the config's diff --git a/plugins/modelopt/skills/evaluation/references/nel-next.md b/plugins/modelopt/skills/evaluation/references/nel-next.md index 1c08b5d9a8e..19e8e9c74af 100644 --- a/plugins/modelopt/skills/evaluation/references/nel-next.md +++ b/plugins/modelopt/skills/evaluation/references/nel-next.md @@ -12,7 +12,7 @@ Start configs from `recipes/examples/example_eval_next.yaml`. | | default (SKILL Steps 1–9) | nel-next | |---|---|---| | package | `nemo-evaluator-launcher` 0.2.6 | `nemo-evaluator[harbor]` 0.4.x | -| env | the skill's normal env | **separate venv** (`.agents/scripts/nel-next.sh`) | +| env | the skill's normal env | **separate venv** (`$SKILL_DIR/scripts/nel-next.sh`) | | CLI | `nel run --config X.yaml` | `nel eval run X.yaml [--submit]` | | overrides | `-o ++a.b.c=v` | `-O a.b.c=v` | | canary limiter | `++…limit_samples=N` | `-O benchmarks.0.max_problems=N` (NOT `--max-problems`, which is `--bench`-only) | @@ -23,8 +23,8 @@ Start configs from `recipes/examples/example_eval_next.yaml`. Installing 0.4.x into the 0.2.6 env clobbers `nel`, so it lives in its own venv: ```bash -.agents/scripts/nel-next.sh --setup-only # one-time, ~1-2 min (needs `uv`) -.agents/scripts/nel-next.sh eval run --dry-run | --submit | … +"$SKILL_DIR/scripts/nel-next.sh" --setup-only # one-time, ~1-2 min (needs `uv`) +"$SKILL_DIR/scripts/nel-next.sh" eval run --dry-run | --submit | … ``` Default install is a git build from `github.com/NVIDIA-NeMo/Evaluator` via `NEL_NEXT_ORIGIN` @@ -197,12 +197,12 @@ with its own `run_id`, copying the shared `services:` block. ## Run (dry-run → canary → full) → push to MLflow ```bash -set -a && source .env && set +a; NEL=.agents/scripts/nel-next.sh -$NEL eval run .yaml --dry-run # validate/render (no SSH) -$NEL eval run .yaml --submit -O benchmarks.0.max_problems=2 -O benchmarks.0.repeats=1 -O benchmarks.0.max_concurrent=2 # canary -$NEL eval run .yaml --submit # full -$NEL eval {status|logs -f|report -f markdown|merge} -r # lifecycle -$NEL mlflow-push -r -c .yaml # post-run: push merged bundle(s) to MLflow +set -a && source .env && set +a; NEL="$SKILL_DIR/scripts/nel-next.sh" +"$NEL" eval run .yaml --dry-run # validate/render (no SSH) +"$NEL" eval run .yaml --submit -O benchmarks.0.max_problems=2 -O benchmarks.0.repeats=1 -O benchmarks.0.max_concurrent=2 # canary +"$NEL" eval run .yaml --submit # full +"$NEL" eval {status|logs -f|report -f markdown|merge} -r # lifecycle +"$NEL" mlflow-push -r -c .yaml # post-run: push merged bundle(s) to MLflow ``` `eval run` on a slurm cluster scp's the sbatch + redacted `.secrets.env` and diff --git a/.agents/scripts/gdpval-sif.sh b/plugins/modelopt/skills/evaluation/scripts/gdpval-sif.sh similarity index 98% rename from .agents/scripts/gdpval-sif.sh rename to plugins/modelopt/skills/evaluation/scripts/gdpval-sif.sh index 585dc0fdbc0..c76ce451a2e 100755 --- a/.agents/scripts/gdpval-sif.sh +++ b/plugins/modelopt/skills/evaluation/scripts/gdpval-sif.sh @@ -22,7 +22,7 @@ # run reuses the built SIF instantly. # # Usage: -# .agents/scripts/gdpval-sif.sh [] [--commit ] [--force|--check] +# "$SKILL_DIR/scripts/gdpval-sif.sh" [] [--commit ] [--force|--check] # Persistent path on the target cluster's shared FS. # DEFAULTS to $GDPVAL_SIF_DIR (from .env) when omitted. A # directory -> /$GDPVAL_SIF_NAME (default python-3.13.gdpval.sif, @@ -45,7 +45,7 @@ # build support, plus network egress to GitHub/base image. Run on a node that has # it — a login node, or (preferred for the ~30-min build) the CPU partition: # srun -p cpu -t 01:00:00 --pty \ -# .agents/scripts/gdpval-sif.sh /lustre/<...>/gdpval/sif +# "$SKILL_DIR/scripts/gdpval-sif.sh" /lustre/<...>/gdpval/sif # # Env overrides: GDPVAL_GYM_COMMIT, GDPVAL_SIF_NAME, APPTAINER_BIN. set -euo pipefail diff --git a/.agents/scripts/nel-next.sh b/plugins/modelopt/skills/evaluation/scripts/nel-next.sh similarity index 95% rename from .agents/scripts/nel-next.sh rename to plugins/modelopt/skills/evaluation/scripts/nel-next.sh index 4db8fa6b545..ec0fa856843 100755 --- a/.agents/scripts/nel-next.sh +++ b/plugins/modelopt/skills/evaluation/scripts/nel-next.sh @@ -24,10 +24,10 @@ # `uvx` environment (uv resolves + caches + reuses it) and forwards to its `nel`. # # Usage (source .env FIRST so the config's ${VAR}s resolve; this never reads secrets): -# .agents/scripts/nel-next.sh --setup-only|--which|--version -# .agents/scripts/nel-next.sh eval run [--dry-run|--submit] [-O k=v ...] -# .agents/scripts/nel-next.sh eval {status|logs|report|merge|resume|stop} -r -# .agents/scripts/nel-next.sh mlflow-push -r -c [-- -o k=v ...] +# "$SKILL_DIR/scripts/nel-next.sh" --setup-only|--which|--version +# "$SKILL_DIR/scripts/nel-next.sh" eval run [--dry-run|--submit] [-O k=v ...] +# "$SKILL_DIR/scripts/nel-next.sh" eval {status|logs|report|merge|resume|stop} -r +# "$SKILL_DIR/scripts/nel-next.sh" mlflow-push -r -c [-- -o k=v ...] # Post-run: SLURM doesn't auto-export. Pulls the merged bundle(s) + pushes to MLflow # using the config's export_config.mlflow (resolves ${MLFLOW_TRACKING_URI}, forces # emit_traces=false to avoid the per-sample hang). Run after `source .env`. diff --git a/plugins/modelopt/skills/ptq/SKILL.md b/plugins/modelopt/skills/ptq/SKILL.md index f1bdf518b6e..afa5f6ca9f8 100644 --- a/plugins/modelopt/skills/ptq/SKILL.md +++ b/plugins/modelopt/skills/ptq/SKILL.md @@ -18,7 +18,8 @@ optimization. Use this skill for each selected recipe's PTQ run. ## Step 1 — Environment -Read `skills/common/environment-setup.md` and `skills/common/workspace-management.md`. After completing them you should know: +Use the common skill's `environment-setup.md` and `workspace-management.md`. +After completing them you should know: - ModelOpt source is available - Local or remote (+ cluster config if remote) @@ -128,7 +129,8 @@ python examples/hf_ptq/hf_ptq.py \ Run `--help` for all options. -For remote: use `remote_run` from `remote_exec.sh` (see `skills/common/remote-execution.md`). +For remote, use `remote_run` from the common skill's `remote_exec.sh`; see its +`remote-execution.md`. ### 4B — Launcher: supported model on SLURM or local Docker @@ -148,7 +150,8 @@ The launcher blocks and tails logs until the job completes. If the launcher fail Follow `references/unsupported-models.md`. It walks through investigating the model, patching ModelOpt if needed, and running `hf_ptq.py`. Run manually (like 4A) for easier monitoring and debugging. -For SLURM, see `skills/common/slurm-setup.md` and `references/slurm-setup-ptq.md`. +For SLURM, see the common skill's `slurm-setup.md` and this skill's +`references/slurm-setup-ptq.md`. ### Monitoring @@ -190,20 +193,20 @@ Report the gate result before moving on. Follow the canonical report format and - **Model-specific dependencies**: Models with `trust_remote_code` may import packages not in the container (e.g., `mamba-ssm` for hybrid Mamba models). See Step 2.5. Use `EXTRA_PIP_DEPS` env var with the launcher, or install manually before running `hf_ptq.py` - **Transformers version**: New models may need a newer version of transformers than what's installed. Check `config.json` for `transformers_version`. In containers, beware of `PIP_CONSTRAINT` blocking upgrades — see `references/slurm-setup-ptq.md` for workarounds - **Gated datasets**: Some calibration datasets require HF authentication. Set `HF_TOKEN` in the job environment. Use `--dataset cnn_dailymail` only as the constrained-environment fallback described in Step 4, not as the preferred calibration set -- **NFS root_squash + Docker**: See `skills/common/slurm-setup.md` section 5 +- **NFS root_squash + Docker**: See the common skill's `slurm-setup.md` section 5 ## References | Reference | When to read | | --- | --- | -| `skills/common/environment-setup.md` | Step 1: always | -| `skills/common/workspace-management.md` | Step 1: always | +| common skill: `environment-setup.md` | Step 1: always | +| common skill: `workspace-management.md` | Step 1: always | | `references/launcher-guide.md` | Step 4B only (launcher path) | | `tools/launcher/CLAUDE.md` | Step 4B only, if you need more launcher detail | | `references/unsupported-models.md` | Step 4C only (unlisted model) | | `references/checkpoint-validation.md` | Step 5: mandatory post-PTQ gate before deployment/evaluation | -| `skills/common/remote-execution.md` | Step 4A/4C only, if target is remote | -| `skills/common/slurm-setup.md` | Step 4A/4C only, if using SLURM manually (not launcher) | +| common skill: `remote-execution.md` | Step 4A/4C only, if target is remote | +| common skill: `slurm-setup.md` | Step 4A/4C only, if using SLURM manually (not launcher) | | `references/slurm-setup-ptq.md` | Step 4A/4C only, PTQ-specific SLURM (container, GPU sizing, FSDP2) | | `examples/hf_ptq/README.md` | Step 3: support matrix, CLI flags, accuracy | | `modelopt/torch/quantization/config.py` | Step 3: format definitions | diff --git a/plugins/modelopt/skills/ptq/references/slurm-setup-ptq.md b/plugins/modelopt/skills/ptq/references/slurm-setup-ptq.md index c642c4aacf2..1b125aaa090 100644 --- a/plugins/modelopt/skills/ptq/references/slurm-setup-ptq.md +++ b/plugins/modelopt/skills/ptq/references/slurm-setup-ptq.md @@ -1,7 +1,7 @@ # SLURM Setup for PTQ PTQ-specific SLURM details. For generic SLURM patterns (account discovery, job template, -monitoring), see `skills/common/slurm-setup.md`. +monitoring), see the common skill's `slurm-setup.md`. --- @@ -73,7 +73,7 @@ FSDP2* section of `examples/hf_ptq/README.md`. Sizing guidance specific to this path: when the per-rank decoder shard approaches GPU capacity (200B+ at low rank count), either add more nodes (more ranks → smaller shard per rank) or add `--cpu_offload`. Layer detection is automatic; no YAML config needed. -Use the multi-node template from `skills/common/slurm-setup.md` section 4 as the job script wrapper. +Use the multi-node template from the common skill's `slurm-setup.md` section 4 as the job script wrapper. --- @@ -82,6 +82,6 @@ Use the multi-node template from `skills/common/slurm-setup.md` section 4 as the Before the full calibration run, submit a smoke test with `--calib_size 4` and `--time=00:30:00`. This catches script errors cheaply before using GPU quota on a real run. -See `skills/common/slurm-setup.md` section 2 for the smoke test partition pattern. +See the common skill's `slurm-setup.md` section 2 for the smoke test partition pattern. Only submit the full calibration job after the smoke test exits cleanly. diff --git a/plugins/modelopt/skills/ptq/references/unsupported-models.md b/plugins/modelopt/skills/ptq/references/unsupported-models.md index 361669f70c2..2d536af6aa3 100644 --- a/plugins/modelopt/skills/ptq/references/unsupported-models.md +++ b/plugins/modelopt/skills/ptq/references/unsupported-models.md @@ -6,7 +6,7 @@ Follow the investigation steps below to determine if `hf_ptq.py` works or if pat ## Step A — Download the model and locate the source -**Download first.** Follow `skills/common/workspace-management.md` to set up local and remote workspaces, sync ModelOpt source, and download the model on the target machine. This avoids downloading twice and gives access to README, custom modeling code, and tokenizer config. +**Download first.** Follow the common skill's `workspace-management.md` to set up local and remote workspaces, sync ModelOpt source, and download the model on the target machine. This avoids downloading twice and gives access to README, custom modeling code, and tokenizer config. After download, inspect the model files on the target machine (use `remote_run` if remote): diff --git a/plugins/modelopt/skills/qad/SKILL.md b/plugins/modelopt/skills/qad/SKILL.md index d016fdf65d0..37e20ee7e5c 100644 --- a/plugins/modelopt/skills/qad/SKILL.md +++ b/plugins/modelopt/skills/qad/SKILL.md @@ -20,8 +20,8 @@ Before constructing commands, read: - `examples/megatron_bridge/README.md`, especially PTQ, data preparation, QAD, export, and Slurm usage - `examples/megatron_bridge/{quantize.py,distill.py}` via `--help` -- `skills/common/{environment-setup,workspace-management,slurm-setup}.md`; also - `skills/common/remote-execution.md` for remote Slurm +- the common skill's `environment-setup.md`, `workspace-management.md`, and + `slurm-setup.md`; also its `remote-execution.md` for remote Slurm Treat the example README and `--help` output as authoritative for mutable flags, commands, containers, and checkpoint formats. This skill supports Slurm only. diff --git a/plugins/modelopt/skills/quant-recipe-search/references/recipe_iteration.md b/plugins/modelopt/skills/quant-recipe-search/references/recipe_iteration.md index 0f95d84c98a..ecdf573b295 100644 --- a/plugins/modelopt/skills/quant-recipe-search/references/recipe_iteration.md +++ b/plugins/modelopt/skills/quant-recipe-search/references/recipe_iteration.md @@ -218,8 +218,8 @@ Do not reimplement workflows that existing skills own: | Fetch MLflow artifacts | `accessing-mlflow` | | Compute baseline-vs-candidate deltas | `compare-results` | -Before launching PTQ in a ModelOpt repo, read the current PTQ skill from -`.agents/skills/ptq/SKILL.md`; recipe paths and validation gates can change. +Before launching PTQ in a ModelOpt repo, use the `ptq` skill; its current recipe +paths and validation gates are authoritative. ## ModelOpt Starting Points From a9d9089a75b9067bf98d66e6ee3b0d13d1aa507c Mon Sep 17 00:00:00 2001 From: Chad Voegele Date: Tue, 11 Aug 2026 20:30:13 +0000 Subject: [PATCH 3/4] Bundle ModelOpt MCP with agent plugin Signed-off-by: Chad Voegele --- plugins/modelopt/.claude-plugin/plugin.json | 12 +++++++++++- plugins/modelopt/.codex-plugin/plugin.json | 1 + plugins/modelopt/.mcp.json | 10 ++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 plugins/modelopt/.mcp.json diff --git a/plugins/modelopt/.claude-plugin/plugin.json b/plugins/modelopt/.claude-plugin/plugin.json index 47393444cfe..693728b9767 100644 --- a/plugins/modelopt/.claude-plugin/plugin.json +++ b/plugins/modelopt/.claude-plugin/plugin.json @@ -16,5 +16,15 @@ "evaluation", "deployment", "llm" - ] + ], + "mcpServers": { + "modelopt": { + "command": "uvx", + "args": [ + "--from", + "git+https://github.com/NVIDIA/Model-Optimizer.git#subdirectory=tools/mcp", + "modelopt-mcp" + ] + } + } } diff --git a/plugins/modelopt/.codex-plugin/plugin.json b/plugins/modelopt/.codex-plugin/plugin.json index f8faa0b1555..95f5e30479f 100644 --- a/plugins/modelopt/.codex-plugin/plugin.json +++ b/plugins/modelopt/.codex-plugin/plugin.json @@ -17,6 +17,7 @@ "llm" ], "skills": "./skills/", + "mcpServers": "./.mcp.json", "interface": { "displayName": "ModelOpt", "shortDescription": "Optimize, deploy, and evaluate models.", diff --git a/plugins/modelopt/.mcp.json b/plugins/modelopt/.mcp.json new file mode 100644 index 00000000000..6c0b9cb636e --- /dev/null +++ b/plugins/modelopt/.mcp.json @@ -0,0 +1,10 @@ +{ + "modelopt": { + "command": "uvx", + "args": [ + "--from", + "git+https://github.com/NVIDIA/Model-Optimizer.git#subdirectory=tools/mcp", + "modelopt-mcp" + ] + } +} From ab24e67cb3b8449ff2c355b530717c5405322fd4 Mon Sep 17 00:00:00 2001 From: Chad Voegele Date: Tue, 11 Aug 2026 20:59:05 +0000 Subject: [PATCH 4/4] Run skill CI from canonical plugin path Signed-off-by: Chad Voegele --- .github/workflows/unit_tests.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/unit_tests.yml b/.github/workflows/unit_tests.yml index ae5fabc0061..4fbbd9a9ebe 100644 --- a/.github/workflows/unit_tests.yml +++ b/.github/workflows/unit_tests.yml @@ -15,6 +15,7 @@ on: - "tools/mcp/**" - "tools/resource_monitor.py" - ".agents/skills/**" + - "plugins/modelopt/skills/**" schedule: - cron: "0 0 * * *" # Nightly workflow_dispatch: @@ -55,6 +56,7 @@ jobs: tools/mcp/** tools/resource_monitor.py .agents/skills/** + plugins/modelopt/skills/** linux: runs-on: ubuntu-latest timeout-minutes: 15 @@ -190,7 +192,7 @@ jobs: # Override addopts to drop the repo's coverage/instafail plugins (not installed here). run: | pip install pytest - python -m pytest .agents/skills/ -o addopts="" -p no:cacheprovider -v + python -m pytest plugins/modelopt/skills/ -o addopts="" -p no:cacheprovider -v unit-pr-required-check: # Run even if some jobs are skipped if: ${{ github.event_name == 'pull_request' && always() }}