Skip to content

feat(speechlm2): distill MTP heads with LK loss - #16140

Draft
Slyne wants to merge 5 commits into
NVIDIA-NeMo:mainfrom
Slyne:slyne/feat/mtp-lk-distillation
Draft

feat(speechlm2): distill MTP heads with LK loss#16140
Slyne wants to merge 5 commits into
NVIDIA-NeMo:mainfrom
Slyne:slyne/feat/mtp-lk-distillation

Conversation

@Slyne

@Slyne Slyne commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add opt-in MTP head training to SALMAutomodel, including strict head_only freezing and recurrent/repeated MTP depth support
  • add an LK distillation objective that combines forward KL and total variation against the frozen backbone distribution
  • preserve packed-sequence boundaries and exchange only the required future teacher rows under context parallelism
  • bound vocabulary-projection memory and keep projection/checkpoint collectives rank-symmetric for uneven or empty supervision
  • add per-depth LK metrics, validation agreement metrics, configuration documentation, and focused distributed tests

Configuration

model:
  mtp:
    enabled: true
    training_mode: head_only
    loss_type: lk
    lk_lambda: 0.5
    num_nextn_predict_layers: 2
    use_repeated_layer: true

loss_type: lk requires training_mode: head_only, keeping the backbone deterministic and frozen as the teacher. Cross-entropy MTP remains the backward-compatible default.

Verification

  • all 51 focused SpeechLM2 MTP tests passed, including two-rank Gloo FSDP uneven-row and CP-reference cases
  • Black formatting check and git diff --check passed
  • end-to-end Hero5c CP=1/EP=8 head-only LK training completed five 12,288-token optimizer steps on eight H100s (Slurm 6351147)

A final CP=2/EP=4 CUDA smoke is intentionally retained as a draft-PR gate because it exercises the NCCL/TE context-parallel teacher exchange.

Related

Slyne added 5 commits August 25, 2026 14:54
Signed-off-by: SlyneD <slyned@nvidia.com>
Signed-off-by: SlyneD <slyned@nvidia.com>
Signed-off-by: SlyneD <slyned@nvidia.com>
Signed-off-by: SlyneD <slyned@nvidia.com>
Signed-off-by: SlyneD <slyned@nvidia.com>
@copy-pr-bot

copy-pr-bot Bot commented Aug 25, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant