Skip to content
Back to skills

Checkpointing And Conversion

ASecurity

"Work with Megatron distributed checkpoints, safe loading,

  • 247 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added September 8, 2026
tools

Works with

  • cli

Security analysis

A100/100

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

Scanned September 8, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill checkpointing-and-conversion --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Checkpointing And Conversion?

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

Security grade badge for Checkpointing And Conversion
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-checkpointing-and-conversion/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-checkpointing-and-conversion)

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: checkpointing-and-conversion
description: "Work with Megatron distributed checkpoints, safe loading,
  resharding, and GPT-Hybrid conversion."
metadata:
  disco-role: operating
disable-model-invocation: true
license: NOASSERTION
---

# checkpointing-and-conversion

Use this sub-skill when the task involves Megatron checkpoint formats, save/load/resume behavior, optimizer state compatibility, distributed checkpoint resharding, PyTorch safe loading, or GPTModel ↔ HybridModel conversion.

## Read first

- For checkpoint formats, optimizer state behavior, async saves, and safe loading, read [references/checkpoint-reference.md](references/checkpoint-reference.md).
- For GPT-to-Hybrid, Hybrid-to-GPT, and Hugging Face/Megatron conversion decision paths, read [references/conversion-workflows.md](references/conversion-workflows.md).
- For failed loads, unsafe globals, unsupported hybrid patterns, missing tracker files, or memory issues, read [references/troubleshooting.md](references/troubleshooting.md).
- Use [scripts/render_gpt_hybrid_conversion_command.py](scripts/render_gpt_hybrid_conversion_command.py) to validate and render a conversion command template without touching checkpoint files.

## Route by task

| Task | Action |
|---|---|
| Resume training from a checkpoint | Confirm `--load`, `--save`, `--ckpt-format`, optimizer load flags, and parallelism compatibility. |
| Change TP/PP/EP/FSDP layout | Prefer distributed checkpoint formats and, for optimizer resharding, fully-reshardable optimizer state. |
| PyTorch 2.6 unsafe global error | Keep safe loading; allow-list only the required class or use the repo's safe globals guidance. |
| GPTModel to HybridModel migration | Choose load-time translation or offline converter; validate `--hybrid-layer-pattern`. |
| HF ↔ Megatron conversion | Treat Megatron Bridge/HF conversion as an external workflow with mounts, tokens, and model-specific scripts. |

## Checkpoint workflow

1. Pull checkpoint metadata first: format, root directory shape, tracker file, model args, parallel sizes, optimizer state format, and target run command.
2. Decide whether the user needs weights-only load, full resume, finetune semantics, or format conversion.
3. If changing parallelism, confirm the checkpoint format and optimizer state format support that change.
4. If migrating GPT to Hybrid, validate the layer pattern before running any conversion.
5. After any conversion or resume, run a bounded smoke before launching full training.

## Boundaries

- Training launch details belong to [../training-cli-and-data/SKILL.md](../training-cli-and-data/SKILL.md).
- Model architecture and parallelism reasoning belongs to [../core-models-and-parallelism/SKILL.md](../core-models-and-parallelism/SKILL.md).
- Inference-time checkpoint use belongs to [../inference-and-serving/SKILL.md](../inference-and-serving/SKILL.md).

Files in this skill

  • SKILL.md2.8 KB
  • references/checkpoint-reference.md3 KB
  • references/conversion-workflows.md3.1 KB
  • references/troubleshooting.md2.7 KB
  • scripts/render_gpt_hybrid_conversion_command.py2.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.

Comments

Loading comments…

Newsletter

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