π Pytorch Distributed native training library for LLMs/VLMs with OOTB Hugging Face support
927
stars
1,987
commits
Python
primary language
Sep 11, 2026
updated
π Documentation β’ π₯ Ready-to-Use Recipes β’ π‘ Examples β’ Model Coverage β’ Performance β’ π€ Contributing
Qwen/Qwen3.8-2.4T-A95B checkpoints. Check out the HellaSwag EP32/PP8 recipe and model coverage page.zai-org/GLM-5.2 with IndexShare DSA, optional TileLang sparse kernels, and long-context CP recipes. Check out our 32K long-context recipe and model coverage page.google/diffusiongemma-26B-A4B-it model. Check out our recipe and guide.google/gemma-4-12B model. Check out our recipe.inclusionAI/Ling-mini-2.0, inclusionAI/Ling-flash-2.0, and inclusionAI/Ling-1T), thanks to @Hayden727. Check out our recipes.baidu/ERNIE-4.5-0.3B-PT, baidu/ERNIE-4.5-21B-A3B-PT, and XiaomiMiMo/MiMo-V2-Flash. Check out our ERNIE dense recipe, ERNIE MoE recipe, and MiMo recipe.nvidia/Nemotron-3-Nano-Omni-30B-A3B-Reasoning-BF16, NVIDIA's 30B-A3B omnimodal MoE (text Β· image Β· audio) with NemotronH hybrid Mamba+Attention backbone. Check out our SFT recipe, LoRA recipe, and guide.tencent/Hy3-preview, thanks to @Khazic. Check out our recipe.deepseek-ai/DeepSeek-V4-Flash, thanks to @Khazic. Check out our recipe and guide.Qwen/Qwen3.6-27B. Check out our recipe.Qwen/Qwen-Image, thanks to @harshareddy832. Check out our recipe.Qwen/Qwen3.6-35B-A3B. Check out our recipe.lmms-lab/LLaVA-OneVision-1.5-4B-Instruct, thanks to @vgauraha62. Check out our recipe.MiniMaxAI/MiniMax-M2.7. Check out our recipe.zai-org/GLM-5.1. GLM-5.1 is Zhipu AI's latest open-source MoE model featuring MLA + DeepSeek Sparse Attention. Check out our recipe and discussion.nvidia/NVIDIA-Nemotron-3-Super-120B-A12B-BF16. Check out our recipe.zai-org/GLM-5. Check out our recipe.Qwen/Qwen3.5-397B-A17B (recipe) and Qwen/Qwen3.5-35B-A3B (recipe)MiniMaxAI/MiniMax-M2.5. Checkout our recipeMiniMaxAI/MiniMax-M2. Checkout our recipeQwen/Qwen3-VL-235B-A22B-Instruct. Checkout our recipemoonshotai/Kimi-VL-A3B-Instruct. Check out our recipe.nvidia/Nemotron-Flash-1B. Check out our recipe.nvidia/NVIDIA-Nemotron-Parse-v1.1 (recipe, tutorial and try on Brev).mistralai/Devstral-Small-2-24B-Instruct-2512. Check out our recipe.Nemo AutoModel is a Pytorch DTensorβnative SPMD open-source training library under NVIDIA NeMo Framework, designed to streamline and scale training and finetuning for LLMs, VLMs, diffusion models, and retrieval models. Designed for flexibility, reproducibility, and scale, NeMo AutoModel enables both small-scale experiments and massive multi-GPU, multi-node deployments for fast experimentation in research and production environments.
What you can expect:
DeviceMesh + placements (Shard, Replicate).TL;DR: SPMD turns βhow to parallelizeβ into a runtime layout choice, not a code fork.
β Available now (v0.5.0 / 26.06 container) | π Planned for 26.08
High-throughput scalable training
SOTA algorithms
Model Coverage and π€ Ecosystem compatibility
Agentic Development and UX
skills/ for common dev tasks (recipe runs, model onboarding, CI).Planned for 26.08
.build() refactor across data and remaining components.We recommend using uv for reproducible Python environments.
# Setup environment before running any recipes
uv venv
# Choose ONE:
uv sync --frozen # LLM recipes (default)
# uv sync --frozen --extra vlm --extra vlm-media # VLM recipes (Qwen/Mistral/Omni need vlm-media for video/vision; fixes: ImportError: qwen_vl_utils is not installed)
# uv sync --frozen --extra cuda # Optional CUDA deps (e.g., Transformer Engine, Mamba SSM)
# uv sync --frozen --extra cuda_source # Optional bitsandbytes dependency
# uv sync --frozen --extra all # Most optional deps (includes `vlm` and `cuda`; NOTE: excludes media β add --extra media for video/image decode)
# uv sync --frozen --all-extras # Everything (includes `fa`, `moe`, `media`, etc.)
# One-off runs (examples):
# uv run --extra vlm <command>
# uv run --extra cuda <command>
uv run python -c "import nemo_automodel; print('NeMo AutoModel ready')"
All recipes are launched via the automodel CLI (or its short alias am). Each YAML config specifies the recipe class and all training parameters:
# LLM example: multi-GPU fine-tuning with FSDP2
automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag.yaml --nproc-per-node 8
# VLM example: single-GPU fine-tuning (Gemma-3-VL) with LoRA
automodel examples/vlm_finetune/gemma3/gemma3_vl_4b_cord_v2_peft.yaml
# Both commands also work with uv run:
uv run automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag.yaml --nproc-per-node 8
[!TIP] NeMo-Run submission: The
cliextra adds NeMo Run to the base package:uv pip install "nemo-automodel[cli]". It is additive; the base package still installs its core training dependencies, including PyTorch.
We provide an example SFT experiment using the FineWeb dataset with a nano-GPT model, ideal for quick experimentation on a single node.
automodel examples/llm_pretrain/nanogpt_pretrain.yaml --nproc-per-node 8
We provide an example SFT experiment using the SQuAD dataset.
The default SFT configuration is set to run on a single GPU. To start the experiment:
automodel examples/llm_finetune/llama3_2/llama3_2_1b_squad.yaml
This fine-tunes the Llama3.2-1B model on the SQuAD dataset using a single GPU.
To use multiple GPUs on a single node, add the --nproc-per-node argument:
automodel examples/llm_finetune/llama3_2/llama3_2_1b_squad.yaml --nproc-per-node 8
To launch on a SLURM cluster, copy the reference sbatch script and adapt it to your cluster:
cp slurm.sub my_cluster.sub
# Edit my_cluster.sub β change CONFIG, #SBATCH directives, container, mounts, etc.
sbatch my_cluster.sub
All cluster-specific settings (nodes, GPUs, partition, container, mounts) live in your sbatch script.
NeMo-Run (nemo_run:) sections are also supported -- see our
cluster guide for details.
We provide a PEFT example using the HellaSwag dataset.
# Memory-efficient SFT with LoRA
automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag_peft.yaml
# Override any YAML parameter via the command line:
automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag_peft.yaml \
--step_scheduler.local_batch_size 16
[!NOTE] Launching a multi-node PEFT example uses the same
sbatch slurm.subworkflow as the SFT case above.
We provide a VLM SFT example using Qwen2.5-VL for end-to-end fine-tuning on image-text data.
# Qwen2.5-VL on 8 GPUs
automodel examples/vlm_finetune/qwen2_5/qwen2_5_vl_3b_rdr.yaml --nproc-per-node 8
We provide a VLM PEFT (LoRA) example for memory-efficient adaptation with Gemma3 VLM.
# Gemma-3-VL PEFT on 8 GPUs
automodel examples/vlm_finetune/gemma3/gemma3_vl_4b_medpix_peft.yaml --nproc-per-node 8
NeMo AutoModel provides native support for a wide range of models available on the Hugging Face Hub, enabling efficient fine-tuning for various domains. Below is a small sample of ready-to-use families (train as-is or swap any compatible π€ causal LM), you can specify nearly any LLM/VLM model available on π€ hub:
[!NOTE] Check out more LLM and VLM examples. Any causal LM on Hugging Face Hub can be used with the base recipe template, just overwrite
--model.pretrained_model_name_or_path <model-id>in the CLI or in the YAML config.
NeMo AutoModel achieves great training performance on NVIDIA GPUs. Below are highlights from our benchmark results:
| Model | #GPUs | Seq Length | Model TFLOPs/sec/GPU | Tokens/sec/GPU | Kernel Optimizations |
|---|---|---|---|---|---|
| DeepSeek V3 671B | 256 | 4096 | 250 | 1,002 | TE + DeepEP |
| GPT-OSS 20B | 8 | 4096 | 279 | 13,058 | TE + DeepEP + FlexAttn |
| Qwen3 MoE 30B | 8 | 4096 | 212 | 11,842 | TE + DeepEP |
For complete benchmark results including configuration details, see the Performance Summary.
NeMo-Automodel/
βββ cli/ # `automodel` / `am` CLI entry-point
β βββ app.py
βββ docker/ # Container build files
βββ docs/ # Documentation and guides
βββ examples/
β βββ convergence/ # Convergence test configs
β βββ diffusion/ # Diffusion pretrain/finetune configs
β βββ dllm_sft/ # Discrete diffusion LM SFT configs
β βββ dllm_generate/ # Discrete diffusion LM generation
β βββ llm_benchmark/ # LLM benchmarking configs
β βββ llm_finetune/ # LLM finetune YAML configs
β βββ llm_kd/ # LLM knowledge-distillation configs
β βββ llm_pretrain/ # LLM pretrain configs
β βββ llm_seq_cls/ # LLM sequence classification configs
β βββ retrieval/ # Bi-encoder / cross-encoder configs
β βββ vlm_benchmark/ # VLM benchmarking configs
β βββ vlm_finetune/ # VLM finetune configs
β βββ vlm_generate/ # VLM generation configs
βββ nemo_automodel/
β βββ _diffusers/ # HF Diffusers integration (NeMoAutoDiffusionPipeline)
β βββ _transformers/ # HF Transformers integration
β βββ components/ # Core library
β β βββ _peft/ # PEFT implementations (LoRA, QLoRA)
β β βββ attention/ # Attention implementations
β β βββ checkpoint/ # Distributed checkpointing
β β βββ config/
β β βββ datasets/ # LLM, VLM, diffusion, retrieval datasets
β β βββ distributed/ # FSDP2, Megatron FSDP, pipelining, CP, etc.
β β βββ launcher/ # Launcher backends (SLURM, NeMo-Run, SkyPilot)
β β βββ loggers/ # Loggers
β β βββ loss/ # Optimized loss functions
β β βββ models/ # User-defined model examples
β β βββ moe/ # Optimized kernels for MoE models
β β βββ optim/ # Optimizer/LR scheduler components (incl. Dion)
β β βββ quantization/ # FP8, QAT, QLoRA
β β βββ training/ # Train utils
β β βββ utils/ # Misc utils
β βββ recipes/
β β βββ llm/ # Main LLM train loop
β β βββ vlm/ # Main VLM train loop
β β βββ diffusion/ # Diffusion training loop
β β βββ dllm/ # Discrete diffusion LM training loop
β β βββ retrieval/ # Retrieval / biencoder training loop
β βββ shared/
βββ tools/ # Developer tooling
βββ tests/ # Comprehensive test suite
If you use NeMo AutoModel in your research, please cite it using the following BibTeX entry:
@misc{nemo-automodel,
title = {NeMo AutoModel: DTensor-native SPMD library for scalable and efficient training},
howpublished = {\url{https://github.com/NVIDIA-NeMo/Automodel}},
year = {2025--2026},
note = {GitHub repository},
}
We welcome contributions! Please see our Contributing Guide for details.
NVIDIA NeMo AutoModel is licensed under the Apache License 2.0.
Python
98.3%
Shell
1.1%
π Pytorch Distributed native training library for LLMs/VLMs with OOTB Hugging Face support
927
stars
1,987
commits
Python
primary language
Sep 11, 2026
updated
π Documentation β’ π₯ Ready-to-Use Recipes β’ π‘ Examples β’ Model Coverage β’ Performance β’ π€ Contributing
Qwen/Qwen3.8-2.4T-A95B checkpoints. Check out the HellaSwag EP32/PP8 recipe and model coverage page.zai-org/GLM-5.2 with IndexShare DSA, optional TileLang sparse kernels, and long-context CP recipes. Check out our 32K long-context recipe and model coverage page.google/diffusiongemma-26B-A4B-it model. Check out our recipe and guide.google/gemma-4-12B model. Check out our recipe.inclusionAI/Ling-mini-2.0, inclusionAI/Ling-flash-2.0, and inclusionAI/Ling-1T), thanks to @Hayden727. Check out our recipes.baidu/ERNIE-4.5-0.3B-PT, baidu/ERNIE-4.5-21B-A3B-PT, and XiaomiMiMo/MiMo-V2-Flash. Check out our ERNIE dense recipe, ERNIE MoE recipe, and MiMo recipe.nvidia/Nemotron-3-Nano-Omni-30B-A3B-Reasoning-BF16, NVIDIA's 30B-A3B omnimodal MoE (text Β· image Β· audio) with NemotronH hybrid Mamba+Attention backbone. Check out our SFT recipe, LoRA recipe, and guide.tencent/Hy3-preview, thanks to @Khazic. Check out our recipe.deepseek-ai/DeepSeek-V4-Flash, thanks to @Khazic. Check out our recipe and guide.Qwen/Qwen3.6-27B. Check out our recipe.Qwen/Qwen-Image, thanks to @harshareddy832. Check out our recipe.Qwen/Qwen3.6-35B-A3B. Check out our recipe.lmms-lab/LLaVA-OneVision-1.5-4B-Instruct, thanks to @vgauraha62. Check out our recipe.MiniMaxAI/MiniMax-M2.7. Check out our recipe.zai-org/GLM-5.1. GLM-5.1 is Zhipu AI's latest open-source MoE model featuring MLA + DeepSeek Sparse Attention. Check out our recipe and discussion.nvidia/NVIDIA-Nemotron-3-Super-120B-A12B-BF16. Check out our recipe.zai-org/GLM-5. Check out our recipe.Qwen/Qwen3.5-397B-A17B (recipe) and Qwen/Qwen3.5-35B-A3B (recipe)MiniMaxAI/MiniMax-M2.5. Checkout our recipeMiniMaxAI/MiniMax-M2. Checkout our recipeQwen/Qwen3-VL-235B-A22B-Instruct. Checkout our recipemoonshotai/Kimi-VL-A3B-Instruct. Check out our recipe.nvidia/Nemotron-Flash-1B. Check out our recipe.nvidia/NVIDIA-Nemotron-Parse-v1.1 (recipe, tutorial and try on Brev).mistralai/Devstral-Small-2-24B-Instruct-2512. Check out our recipe.Nemo AutoModel is a Pytorch DTensorβnative SPMD open-source training library under NVIDIA NeMo Framework, designed to streamline and scale training and finetuning for LLMs, VLMs, diffusion models, and retrieval models. Designed for flexibility, reproducibility, and scale, NeMo AutoModel enables both small-scale experiments and massive multi-GPU, multi-node deployments for fast experimentation in research and production environments.
What you can expect:
DeviceMesh + placements (Shard, Replicate).TL;DR: SPMD turns βhow to parallelizeβ into a runtime layout choice, not a code fork.
β Available now (v0.5.0 / 26.06 container) | π Planned for 26.08
High-throughput scalable training
SOTA algorithms
Model Coverage and π€ Ecosystem compatibility
Agentic Development and UX
skills/ for common dev tasks (recipe runs, model onboarding, CI).Planned for 26.08
.build() refactor across data and remaining components.We recommend using uv for reproducible Python environments.
# Setup environment before running any recipes
uv venv
# Choose ONE:
uv sync --frozen # LLM recipes (default)
# uv sync --frozen --extra vlm --extra vlm-media # VLM recipes (Qwen/Mistral/Omni need vlm-media for video/vision; fixes: ImportError: qwen_vl_utils is not installed)
# uv sync --frozen --extra cuda # Optional CUDA deps (e.g., Transformer Engine, Mamba SSM)
# uv sync --frozen --extra cuda_source # Optional bitsandbytes dependency
# uv sync --frozen --extra all # Most optional deps (includes `vlm` and `cuda`; NOTE: excludes media β add --extra media for video/image decode)
# uv sync --frozen --all-extras # Everything (includes `fa`, `moe`, `media`, etc.)
# One-off runs (examples):
# uv run --extra vlm <command>
# uv run --extra cuda <command>
uv run python -c "import nemo_automodel; print('NeMo AutoModel ready')"
All recipes are launched via the automodel CLI (or its short alias am). Each YAML config specifies the recipe class and all training parameters:
# LLM example: multi-GPU fine-tuning with FSDP2
automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag.yaml --nproc-per-node 8
# VLM example: single-GPU fine-tuning (Gemma-3-VL) with LoRA
automodel examples/vlm_finetune/gemma3/gemma3_vl_4b_cord_v2_peft.yaml
# Both commands also work with uv run:
uv run automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag.yaml --nproc-per-node 8
[!TIP] NeMo-Run submission: The
cliextra adds NeMo Run to the base package:uv pip install "nemo-automodel[cli]". It is additive; the base package still installs its core training dependencies, including PyTorch.
We provide an example SFT experiment using the FineWeb dataset with a nano-GPT model, ideal for quick experimentation on a single node.
automodel examples/llm_pretrain/nanogpt_pretrain.yaml --nproc-per-node 8
We provide an example SFT experiment using the SQuAD dataset.
The default SFT configuration is set to run on a single GPU. To start the experiment:
automodel examples/llm_finetune/llama3_2/llama3_2_1b_squad.yaml
This fine-tunes the Llama3.2-1B model on the SQuAD dataset using a single GPU.
To use multiple GPUs on a single node, add the --nproc-per-node argument:
automodel examples/llm_finetune/llama3_2/llama3_2_1b_squad.yaml --nproc-per-node 8
To launch on a SLURM cluster, copy the reference sbatch script and adapt it to your cluster:
cp slurm.sub my_cluster.sub
# Edit my_cluster.sub β change CONFIG, #SBATCH directives, container, mounts, etc.
sbatch my_cluster.sub
All cluster-specific settings (nodes, GPUs, partition, container, mounts) live in your sbatch script.
NeMo-Run (nemo_run:) sections are also supported -- see our
cluster guide for details.
We provide a PEFT example using the HellaSwag dataset.
# Memory-efficient SFT with LoRA
automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag_peft.yaml
# Override any YAML parameter via the command line:
automodel examples/llm_finetune/llama3_2/llama3_2_1b_hellaswag_peft.yaml \
--step_scheduler.local_batch_size 16
[!NOTE] Launching a multi-node PEFT example uses the same
sbatch slurm.subworkflow as the SFT case above.
We provide a VLM SFT example using Qwen2.5-VL for end-to-end fine-tuning on image-text data.
# Qwen2.5-VL on 8 GPUs
automodel examples/vlm_finetune/qwen2_5/qwen2_5_vl_3b_rdr.yaml --nproc-per-node 8
We provide a VLM PEFT (LoRA) example for memory-efficient adaptation with Gemma3 VLM.
# Gemma-3-VL PEFT on 8 GPUs
automodel examples/vlm_finetune/gemma3/gemma3_vl_4b_medpix_peft.yaml --nproc-per-node 8
NeMo AutoModel provides native support for a wide range of models available on the Hugging Face Hub, enabling efficient fine-tuning for various domains. Below is a small sample of ready-to-use families (train as-is or swap any compatible π€ causal LM), you can specify nearly any LLM/VLM model available on π€ hub:
[!NOTE] Check out more LLM and VLM examples. Any causal LM on Hugging Face Hub can be used with the base recipe template, just overwrite
--model.pretrained_model_name_or_path <model-id>in the CLI or in the YAML config.
NeMo AutoModel achieves great training performance on NVIDIA GPUs. Below are highlights from our benchmark results:
| Model | #GPUs | Seq Length | Model TFLOPs/sec/GPU | Tokens/sec/GPU | Kernel Optimizations |
|---|---|---|---|---|---|
| DeepSeek V3 671B | 256 | 4096 | 250 | 1,002 | TE + DeepEP |
| GPT-OSS 20B | 8 | 4096 | 279 | 13,058 | TE + DeepEP + FlexAttn |
| Qwen3 MoE 30B | 8 | 4096 | 212 | 11,842 | TE + DeepEP |
For complete benchmark results including configuration details, see the Performance Summary.
NeMo-Automodel/
βββ cli/ # `automodel` / `am` CLI entry-point
β βββ app.py
βββ docker/ # Container build files
βββ docs/ # Documentation and guides
βββ examples/
β βββ convergence/ # Convergence test configs
β βββ diffusion/ # Diffusion pretrain/finetune configs
β βββ dllm_sft/ # Discrete diffusion LM SFT configs
β βββ dllm_generate/ # Discrete diffusion LM generation
β βββ llm_benchmark/ # LLM benchmarking configs
β βββ llm_finetune/ # LLM finetune YAML configs
β βββ llm_kd/ # LLM knowledge-distillation configs
β βββ llm_pretrain/ # LLM pretrain configs
β βββ llm_seq_cls/ # LLM sequence classification configs
β βββ retrieval/ # Bi-encoder / cross-encoder configs
β βββ vlm_benchmark/ # VLM benchmarking configs
β βββ vlm_finetune/ # VLM finetune configs
β βββ vlm_generate/ # VLM generation configs
βββ nemo_automodel/
β βββ _diffusers/ # HF Diffusers integration (NeMoAutoDiffusionPipeline)
β βββ _transformers/ # HF Transformers integration
β βββ components/ # Core library
β β βββ _peft/ # PEFT implementations (LoRA, QLoRA)
β β βββ attention/ # Attention implementations
β β βββ checkpoint/ # Distributed checkpointing
β β βββ config/
β β βββ datasets/ # LLM, VLM, diffusion, retrieval datasets
β β βββ distributed/ # FSDP2, Megatron FSDP, pipelining, CP, etc.
β β βββ launcher/ # Launcher backends (SLURM, NeMo-Run, SkyPilot)
β β βββ loggers/ # Loggers
β β βββ loss/ # Optimized loss functions
β β βββ models/ # User-defined model examples
β β βββ moe/ # Optimized kernels for MoE models
β β βββ optim/ # Optimizer/LR scheduler components (incl. Dion)
β β βββ quantization/ # FP8, QAT, QLoRA
β β βββ training/ # Train utils
β β βββ utils/ # Misc utils
β βββ recipes/
β β βββ llm/ # Main LLM train loop
β β βββ vlm/ # Main VLM train loop
β β βββ diffusion/ # Diffusion training loop
β β βββ dllm/ # Discrete diffusion LM training loop
β β βββ retrieval/ # Retrieval / biencoder training loop
β βββ shared/
βββ tools/ # Developer tooling
βββ tests/ # Comprehensive test suite
If you use NeMo AutoModel in your research, please cite it using the following BibTeX entry:
@misc{nemo-automodel,
title = {NeMo AutoModel: DTensor-native SPMD library for scalable and efficient training},
howpublished = {\url{https://github.com/NVIDIA-NeMo/Automodel}},
year = {2025--2026},
note = {GitHub repository},
}
We welcome contributions! Please see our Contributing Guide for details.
NVIDIA NeMo AutoModel is licensed under the Apache License 2.0.
(top 30 of 123)
Python
98.3%
Shell
1.1%