distributed-llm-pretraining-torchtitan

Configure distributed LLM pretraining workflows in TorchTitan.

1|Updated Apr 10, 2026
One-click install
npx skills add https://github.com/zerwiz/wayofpi --skill distributed-llm-pretraining-torchtitan-zerwiz
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: distributed-llm-pretraining-torchtitan
Source: https://github.com/zerwiz/wayofpi/tree/main/.hermes/hermes-agent/optional-skills/mlops/torchtitan
Command: npx skills add https://github.com/zerwiz/wayofpi --skill distributed-llm-pretraining-torchtitan-zerwiz

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill removes the friction of setting up and operating large-scale TorchTitan pretraining runs by centralizing parallelism, optimization, and checkpoint workflows.

Core Features & Use Cases

  • Distributed training orchestration for FSDP2, tensor parallelism, pipeline parallelism, and context parallelism.
  • Float8 and torch compile guidance for H100 and newer accelerators.
  • Fault-tolerant checkpointing, HuggingFace conversion, and custom model integration for research or production training.
  • Use it to launch Llama-class pretraining jobs, resume from sharded checkpoints, or adapt TorchTitan to a new model family.

Quick Start

Ask the skill to configure a TorchTitan training run for your model, GPU topology, and checkpointing needs.

Frequently Asked Questions about distributed-llm-pretraining-torchtitan

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure distributed LLM pretraining across multiple GPUs with PyTorch?

Distributed LLM pretraining across multiple GPUs requires configuring 4D parallelism, including FSDP2 and tensor parallelism. This setup orchestrates training runs for models like Llama and DeepSeek across 8 to 512+ GPUs natively within PyTorch.

Can I use Float8 and torch.compile to optimize large-scale Llama pretraining?

Float8 and torch.compile optimize large-scale Llama pretraining by accelerating computation on H100 and newer accelerators. This configuration is fully supported for TorchTitan workflows to maximize hardware efficiency during distributed training.

How do I resume distributed training from sharded checkpoints in PyTorch?

Resume distributed training from sharded checkpoints in PyTorch using fault-tolerant checkpointing mechanisms. This ensures training continuity and allows recovery without manually managing distributed state across nodes.

Does TorchTitan support HuggingFace interoperability for custom model pretraining?

TorchTitan supports HuggingFace interoperability for custom model pretraining through checkpoint conversion. This allows seamless integration and registration of new model families for repeatable large-scale training workflows.

What is the best way to set up multi-node pretraining for Qwen models?

The best way to set up multi-node pretraining for Qwen models is using native 4D parallelism. This approach configures pipeline and context parallelism to scale training efficiently across 512+ GPUs.

Do I need to implement 4D parallelism for single-node LLM pretraining?

4D parallelism is required for single-node LLM pretraining to efficiently distribute workloads. Implementing FSDP2 and tensor parallelism ensures optimal memory utilization and compute distribution across local accelerators.