d1-3B
d1-3B is a Liquid AI decision model built on the LFM2-VL vision-language
architecture. Like other decision models, it returns a probability for
every allowed option of each typed question. NeMo AutoModel provides experimental post-training for D1-3B and the
related D1 Omni model through the d1_posttrain.py example. The example keeps the backbone frozen and trains only the
readout: additive answer-token rows for D1-3B, or the released marker head for D1 Omni. It adapts the readout on
text-only records. The vision modules of both models, and the D1 Omni audio modules, remain frozen.
Post-Train D1-3B
From the repository root, generate fictional training, validation, and test records. The generator rejects an
existing output directory, so skip this step if you already generated data/soc_triage for another decision model:
Run each stage on a CUDA GPU. Start with the baseline, which evaluates the released checkpoint and compares its
probabilities with the publisher implementation. The supervised fine-tuning (SFT) and reinforcement learning (RL)
stages do not repeat that comparison. Each stage writes metrics_validation.json and metrics_test.json to its
output directory.
To run D1 Omni, replace --model d1-3b with --model d1-omni, and use separate output directories, such as
runs/d1-omni/base. The example loads D1-3B in BF16 and D1 Omni in FP32, and it pins the model and tokenizer
revisions. The RL stage requires --input-dir set to the output directory of the SFT stage. It loads only the readout
weights (head.pt) from that directory and starts with a new optimizer.
Model Reference
Model Architecture
NeMo AutoModel uses its D1 implementation, which matches released D1 numerics such as FP32 rotary embeddings, only for
checkpoints whose configuration maps AutoModel to the publisher’s modeling_d1.D1Model class. Other LFM2-VL
checkpoints use the Hugging Face implementation.
The d1_posttrain.py example downloads pinned publisher code for both models and loads it with
trust_remote_code=True. D1 Omni also needs that code to build its vision and audio modules. To run offline, download
the checkpoints and the publisher code to your Hugging Face cache first.
The D1 examples do not demonstrate distributed adaptation, and their results do not measure downstream task quality. Downloaded publisher code and checkpoints keep their own license terms.