/nemo-automodel-model-onboarding
Guide for onboarding new model architectures into NeMo AutoModel, including architecture discovery, implementation patterns, registration, and validation.
$ npx -y skills add NVIDIA/skills --skill nemo-automodel-model-onboarding --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
- Slash command
/nemo-automodel-model-onboarding
Context preview
The summary Claude sees to decide when to auto-load this skill.
Guide for onboarding new model architectures into NeMo AutoModel, including architecture discovery, implementation patterns, registration, and validation.
SKILL.md
nemo-automodel-model-onboarding.SKILL.mdname: nemo-automodel-model-onboarding
description: Guide for onboarding new model architectures into NeMo AutoModel, including architecture discovery, implementation patterns, registration, and validation.
when_to_use: Adding or modifying model architecture support in NeMo AutoModel, such as LLM/VLM/MoE model files, custom layers, state-dict adapters, registry entries, Hugging Face config mapping, or capability flags.
license: Apache-2.0
metadata:
author: NVIDIA
tags:
- nemo-automodel
- model-onboardingAdding Model Support to NeMo AutoModel
Purpose
This skill guides implementation of new model architectures in NeMo AutoModel. Follow the five phases in order. <!-- NVSkills signature refresh requested after PR #2998 (2026-07-31). -->
Instructions
When answering an onboarding question, keep the response in this order:
1. Classify the architecture from `config.json`. 2. Name the exact implementation files under `components/models/<name>/`. 3. Identify registry and optional custom-config updates. 4. State the validation tests that must be added before full checkpoint use.
For conceptual onboarding questions, answer from this skill without opening the pattern files unless the user asks you to edit code. Mention pattern filenames as references, then give the direct checklist.
Use direct action verbs: classify the model, name the files, map the weights, register the class, and add tests. Do not discuss distributed strategy, launcher configuration, or general recipe authoring unless the user explicitly connects it to onboarding a new architecture.
Examples
Use these compact answer patterns for common questions:
- Dense causal LM: classify as dense only when `architectures` contains a
`ForCausalLM` class and expert fields such as `num_local_experts`, `n_routed_experts`, or `num_experts_per_tok` are absent. Create `components/models/<name>/model.py`, `state_dict_adapter.py`, `__init__.py`, and optional `config.py`, register `MODEL_ARCH_MAPPING` in `_transformers/registry.py`, add example YAML, and add tiny-config unit tests plus layer-equivalence tests for rewritten layers.
- MoE state dict: identify expert fields in `config.json`, reference
`moe-patterns.md`, map router tensors separately, preserve routed-expert index order, map routed experts, shared experts, and gate/up/down projections, add adapter key-map tests and tiny-config numerical equivalence tests, and do not rely only on `from_pretrained()` or silent tensor reshapes.
- VLM onboarding: classify as VLM only when `vision_config`, `text_config`, and
a `ForConditionalGeneration` architecture are present. Reference `vlm-patterns.md` and existing VLM implementations such as `mistral4`, `kimivl`, or `kimi_k25_vl`; check text backbone, vision tower, projector, processor assumptions, text and vision `state_dict_adapter.py` mappings, registry registration, and tiny image-text tests before full checkpoints. Do not treat VLM onboarding as a pure causal-LM path or skip processor/image tests.
For MoE state-dict and VLM questions, apply the checklists in Sections 2.4 and 2.5.
Routing Boundary
Use this skill only when the user is adding or modifying model architecture support: model files, custom layers, state-dict adapters, Hugging Face config mapping, registry entries, or model capability flags.
Do not use this skill for standalone training recipe YAML questions about optimizers, datasets, schedulers, validation datasets, or trainer wiring unless they are explicitly part of onboarding a new model architecture. Those recipe questions belong to the nemo-automodel-recipe-development skill.
In-scope examples:
- "Add support for a new Hugging Face causal LM architecture."
- "Map MoE router and expert weights from a Hugging Face checkpoint."
- "Register a new model class in NeMo AutoModel."
Out-of-scope examples:
- "Write a finetuning recipe YAML with optimizer and dataset sections."
- "Choose FSDP2, DDP, tensor parallel, or context parallel settings."
- "Configure Slurm, SkyPilot, containers, mounts, or launch dispatch."
Phase 1: Discovery
Before writing code, gather information about the target model.
1.1 Fetch HuggingFace config.json
Download the model's `config.json` from the HuggingFace Hub (or use `AutoConfig.from_pretrained`). Key fields to extract:
- `architectures` -- determines the class name and registration key (e.g., `"LlamaForCausalLM"`, `"Qwen3MoeForCausalLM"`, `"Mistral3ForConditionalGeneration"`)
- `model_type` -- used for custom config registration in `_CUSTOM_CONFIG_REGISTRATIONS` if HF does not have a built-in config class
- `hidden_size`, `intermediate_size`, `num_hidden_layers`, `num_attention_heads`, `num_key_value_heads` -- sizing
- `vocab_size` -- needed for tiny test configs
- `tie_word_embeddings` -- the saved setting in each supported checkpoint; do not infer it from a bare config constructor
- `hidden_act` -- activation function (e.g., `"silu"` for SwiGLU)
1.2 Determine model type
| Type | Indicators | Pattern file | |------|-----------|-------------| | **Dense LLM** | `ForCausalLM` in architectures, no expert fields | [llm-patterns.md](./llm-patterns.md) | | **MoE LLM** | `n_routed_experts`, `num_local_experts`, `num_experts_per_tok` in config | [moe-patterns.md](./moe-patterns.md) | | **VLM** | `ForConditionalGeneration` in architectures, has `vision_config` + `text_config` | [vlm-patterns.md](./vlm-patterns.md) |
1.3 Check for existing similar architectures
Look in `components/models/` for architectures with similar attention or MLP patterns:
components/models/
llama/ # Standard GQA + SwiGLU (CombinedQKV + CombinedGateUpMLP)
qwen2/ # Same as Llama but with attention bias + QKV bias
baichuan/ # ALiBi attention variant
deepseek_v3/ # MLA attention + MoE (DeepSeek-style grouped experts)
mistral4/ # MLA + MoE + VLM (Pixtral vision)
kimivl/ # DeepSeek-V3 ba
Read more
name: nemo-automodel-model-onboarding
description: Guide for onboarding new model architectures into NeMo AutoModel, including architecture discovery, implementation patterns, registration, and validation.
when_to_use: Adding or modifying model architecture support in NeMo AutoModel, such as LLM/VLM/MoE model files, custom layers, state-dict adapters, registry entries, Hugging Face config mapping, or capability flags.
license: Apache-2.0
metadata:
author: NVIDIA
tags:
- nemo-automodel
- model-onboardingAdding Model Support to NeMo AutoModel
Purpose
This skill guides implementation of new model architectures in NeMo AutoModel. Follow the five phases in order. <!-- NVSkills signature refresh requested after PR #2998 (2026-07-31). -->
Instructions
When answering an onboarding question, keep the response in this order:
1. Classify the architecture from `config.json`. 2. Name the exact implementation files under `components/models/<name>/`. 3. Identify registry and optional custom-config updates. 4. State the validation tests that must be added before full checkpoint use.
For conceptual onboarding questions, answer from this skill without opening the pattern files unless the user asks you to edit code. Mention pattern filenames as references, then give the direct checklist.
Use direct action verbs: classify the model, name the files, map the weights, register the class, and add tests. Do not discuss distributed strategy, launcher configuration, or general recipe authoring unless the user explicitly connects it to onboarding a new architecture.
Examples
Use these compact answer patterns for common questions:
- Dense causal LM: classify as dense only when `architectures` contains a
`ForCausalLM` class and expert fields such as `num_local_experts`, `n_routed_experts`, or `num_experts_per_tok` are absent. Create `components/models/<name>/model.py`, `state_dict_adapter.py`, `__init__.py`, and optional `config.py`, register `MODEL_ARCH_MAPPING` in `_transformers/registry.py`, add example YAML, and add tiny-config unit tests plus layer-equivalence tests for rewritten layers.
- MoE state dict: identify expert fields in `config.json`, reference
`moe-patterns.md`, map router tensors separately, preserve routed-expert index order, map routed experts, shared experts, and gate/up/down projections, add adapter key-map tests and tiny-config numerical equivalence tests, and do not rely only on `from_pretrained()` or silent tensor reshapes.
- VLM onboarding: classify as VLM only when `vision_config`, `text_config`, and
a `ForConditionalGeneration` architecture are present. Reference `vlm-patterns.md` and existing VLM implementations such as `mistral4`, `kimivl`, or `kimi_k25_vl`; check text backbone, vision tower, projector, processor assumptions, text and vision `state_dict_adapter.py` mappings, registry registration, and tiny image-text tests before full checkpoints. Do not treat VLM onboarding as a pure causal-LM path or skip processor/image tests.
For MoE state-dict and VLM questions, apply the checklists in Sections 2.4 and 2.5.
Routing Boundary
Use this skill only when the user is adding or modifying model architecture support: model files, custom layers, state-dict adapters, Hugging Face config mapping, registry entries, or model capability flags.
Do not use this skill for standalone training recipe YAML questions about optimizers, datasets, schedulers, validation datasets, or trainer wiring unless they are explicitly part of onboarding a new model architecture. Those recipe questions belong to the nemo-automodel-recipe-development skill.
In-scope examples:
- "Add support for a new Hugging Face causal LM architecture."
- "Map MoE router and expert weights from a Hugging Face checkpoint."
- "Register a new model class in NeMo AutoModel."
Out-of-scope examples:
- "Write a finetuning recipe YAML with optimizer and dataset sections."
- "Choose FSDP2, DDP, tensor parallel, or context parallel settings."
- "Configure Slurm, SkyPilot, containers, mounts, or launch dispatch."
Phase 1: Discovery
Before writing code, gather information about the target model.
1.1 Fetch HuggingFace config.json
Download the model's `config.json` from the HuggingFace Hub (or use `AutoConfig.from_pretrained`). Key fields to extract:
- `architectures` -- determines the class name and registration key (e.g., `"LlamaForCausalLM"`, `"Qwen3MoeForCausalLM"`, `"Mistral3ForConditionalGeneration"`)
- `model_type` -- used for custom config registration in `_CUSTOM_CONFIG_REGISTRATIONS` if HF does not have a built-in config class
- `hidden_size`, `intermediate_size`, `num_hidden_layers`, `num_attention_heads`, `num_key_value_heads` -- sizing
- `vocab_size` -- needed for tiny test configs
- `tie_word_embeddings` -- the saved setting in each supported checkpoint; do not infer it from a bare config constructor
- `hidden_act` -- activation function (e.g., `"silu"` for SwiGLU)
1.2 Determine model type
| Type | Indicators | Pattern file | |------|-----------|-------------| | **Dense LLM** | `ForCausalLM` in architectures, no expert fields | [llm-patterns.md](./llm-patterns.md) | | **MoE LLM** | `n_routed_experts`, `num_local_experts`, `num_experts_per_tok` in config | [moe-patterns.md](./moe-patterns.md) | | **VLM** | `ForConditionalGeneration` in architectures, has `vision_config` + `text_config` | [vlm-patterns.md](./vlm-patterns.md) |
1.3 Check for existing similar architectures
Look in `components/models/` for architectures with similar attention or MLP patterns:
components/models/ llama/ # Standard GQA + SwiGLU (CombinedQKV + CombinedGateUpMLP) qwen2/ # Same as Llama but with attention bias + QKV bias baichuan/ # ALiBi attention variant deepseek_v3/ # MLA attention + MoE (DeepSeek-style grouped experts) mistral4/ # MLA + MoE + VLM (Pixtral vision) kimivl/ # DeepSeek-V3 ba
Official, NVIDIA-verified Agent Skills for Claude Code, Codex, and other coding agents.
Other skills on nvidia-skills.
- /nvidia-skill-finder
Use for NVIDIA-related requests where an NVIDIA skill might help, even if the user did not ask for a skill. Trigger on NVIDIA products, hardware, software, SDKs, GPUs, Jetson/JetPack/L4T/BSP/SDK Manager/driver/flashing/setup, CUDA, NIM, NeMo, Omniverse/OpenUSD/SimReady,
Open skill - /accelerated-computing-cudf
Official NVIDIA-authored guidance for NVIDIA cuDF GPU DataFrames, pandas acceleration, dask-cuDF, ETL, joins, groupby, CSV/Parquet I/O, nullable semantics, and multi-GPU DataFrame workloads.
Open skill - /aiq-deploy
Use when asked to install, deploy, run, validate, troubleshoot, or stop NVIDIA AI-Q Blueprint infrastructure.
Open skill - /aiq-research
Use when asked to run deep research or AI-Q research through a reachable NVIDIA AI-Q Blueprint backend.
Open skill - /amc-run-sample-calibration
Run end-to-end calibration on the shipped sample dataset (sdg_08_2_sample_data_010926.zip) against a running AMC microservice. Use when user says 'test sample dataset', 'run sample calibration', 'verify AMC install', or 'launch and test'.
Open skill - /amc-run-video-calibration
Calibrate a new dataset from pre-recorded video files via the AutoMagicCalib REST API. Use when user has local MP4s and says 'calibrate my videos', 'run AMC on these videos', or similar. For RTSP/live streams, use amc-run-rtsp-calibration instead.
Open skill

