Skip to content
Back to skills

Fastgen Add Method

ASecurity

Implement and validate a new NVIDIA FastGen training method or objective (distillation, consistency, adversarial or fine-tuning variants) from a paper or reference code: FastGenModel subclass, method config, gradients, student sampling and tests. Use it whenever an algorithm is not expressible through the existing method configs.

  • 4,297 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added November 9, 2026
ai-agentsgoexpressgitdocumentation

Security analysis

A100/100

Pro scans all 20 files and shows the line behind each finding

Scanned November 9, 2026

npx -y skills add NVIDIA/skills --skill fastgen-add-method --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Fastgen Add Method?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Fastgen Add Method
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/nvidia-fastgen-add-method/badge)](https://www.skillsdirectory.com/skills/nvidia-fastgen-add-method)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: fastgen-add-method
description: >-
  Implement and validate a new NVIDIA FastGen training method or objective (distillation, consistency, adversarial or fine-tuning variants) from a paper or reference code: FastGenModel subclass, method config, gradients, student sampling and tests. Use it whenever an algorithm is not expressible through the existing method configs.
license: Apache-2.0
metadata:
  author: "Julius Berner <jberner@nvidia.com>"
  domain: ml
---

# Add a FastGen method

Apply [fastgen-develop](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-develop/SKILL.md)
and [fastgen-runtime](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-runtime/SKILL.md). Read the
[method index](https://github.com/NVlabs/FastGen/blob/main/fastgen/methods/README.md) and the nearest maintained implementation,
the `FastGenModel` docstrings in [model.py](https://github.com/NVlabs/FastGen/blob/main/fastgen/methods/model.py), then the
[method contract](references/method-contract.md).

1. **Plan.** Resolve the algorithm version and its authoritative paper or code. Write down
   the state and time convention, target construction, detach boundaries, loss weighting
   and reduction, update order, required teacher or auxiliary networks and the inference
   rollout. Separate the method from the reference's architecture, dataset and
   engineering defaults, and record unresolved paper/code discrepancies.
2. **Reuse.** If existing options express the algorithm, hand off to
   [fastgen-configure](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-configure/SKILL.md).
   Otherwise choose the narrowest compatible method extension. Share mechanisms only
   where semantics match; do not inherit losses or networks because they are defaults.
   Move objective math into
   [common_loss.py](https://github.com/NVlabs/FastGen/blob/main/fastgen/methods/common_loss.py) only when another caller shares it.
3. **Implement.** Extend the selected method, creating a `FastGenModel` subclass in the
   matching category only when needed. Follow the contract's model, optimizer, scheduler,
   batch and checkpoint interfaces; for a new method add a typed config under
   `fastgen/configs/methods/` and its export in
   [methods/__init__.py](https://github.com/NVlabs/FastGen/blob/main/fastgen/methods/__init__.py). Keep model and dataset names out
   of the method; experiment configs own them.
4. **Dependencies.** Trace the network operations and batch fields the method needs
   through the actual callers; use
   [fastgen-add-network](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-add-network/SKILL.md) for missing network
   capabilities and [fastgen-dataset](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-dataset/SKILL.md) for supervision.
   Declare the supported prediction types, samplers, modalities and causal modes.
5. **Configs.** Use [fastgen-configure](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-configure/SKILL.md) for a small
   supported experiment and the target recipe, including the method's student grid,
   logging and staged initialisation.
6. **Verify the math.** Compare each objective term's value **and gradients** with the reference on
   fixed tensors, times and noise before any expensive run; cover boundary times,
   disabled terms and detach boundaries. Add and run unit tests following the
   `tests/test_*model.py` pattern and use [fastgen-validate](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-validate/SKILL.md)
   for sampling parity and checkpoints.
7. **Run and document.** Use [fastgen-train](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-train/SKILL.md) for a
   bounded run covering every optimizer phase and the requested distributed mode; check
   that intended modules update, frozen targets stay fixed, validation preserves training
   state and resume restores the new state. Evaluate with
   [fastgen-inference](https://github.com/NVlabs/FastGen/blob/main/skills/fastgen-inference/SKILL.md) at the target NFE, add the
   method to the README tables (they feed the documentation site).

Report method and config paths, the correspondence to the reference math, tests, runs
and supported combinations. For finite but ineffective training inspect gradient paths
and optimizer phases before sweeping hyperparameters, and separate unverified reference
claims from demonstrated results.

Files in this skill

  • BENCHMARK.md9.7 KB
  • SKILL.md4.3 KB
  • evals/config.yml299 B
  • evals/evals.json7.2 KB
  • evals/files/config_dmd2.py.txt7.1 KB
  • evals/files/config_sft.py.txt1.3 KB
  • evals/files/dmd2_change_request.txt883 B
  • evals/files/dmd2_cifar10_config.py.txt1.1 KB
  • evals/files/dmd2_phase.py.txt1.1 KB
  • evals/files/dmd2_recipe_sources.json2.9 KB
  • evals/files/dmd2_sources.json2.4 KB
  • evals/files/dmd2_student_step.py.txt6.6 KB
  • evals/files/flow_matching_loss.py.txt4.8 KB
  • evals/files/gan_reduction.py.txt1.6 KB
  • evals/files/prepare_batch.py.txt2.8 KB
  • evals/files/reward_contract.py.txt1.3 KB
  • evals/files/sft.py.txt15 KB
  • evals/files/sft_existing_tests.py.txt4.3 KB
  • evals/files/sft_multimodal_helpers.py.txt9.4 KB
  • evals/files/sft_sources.json6.6 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.