Engineering / advanced
Adapt models with supervised instructions
Design instruction data, masking, adapters, validation, and releases while measuring retention of capabilities and the effect of example formatting.
Your route through engineering
Follow the path or begin with a question. Every lesson is open.
Your place, at your pace. Progress is optional and saved only in this browser when available.
Read / explore / reason
Inside this module
Module 01 advanced
Adapt models with supervised instructions
Design instruction data, masking, adapters, validation, and releases while measuring retention of capabilities and the effect of example formatting.
- 01
Conversation schemas become exact token sequences
Preserve roles, turn boundaries, and tokenizer/template identity before treating an example as training data.
25 min - 02
Mask the intended assistant prediction targets
Separate attention visibility from target supervision and normalize loss over the explicitly selected tokens.
26 min - 03
Truncate conversations without breaking their targets
Preserve meaningful context and recompute aligned masks when a multi-turn example exceeds its token budget.
25 min - 04
Deduplicate before trusting a split
Keep related conversations, templates, and source records together so evaluation tests generalization rather than repeated content.
25 min - 05
LoRA rank is a parameter budget, not a quality guarantee
Count a declared low-rank update while separating trainable weights from the full training-memory footprint.
26 min - 06
Merge updates, not arbitrary factor sums
Check BA orientation, scaling, rank growth, and quantization before treating merged adapters as equivalent execution.
27 min - 07
Example sampling is not token weighting
Specify task proportions together with target lengths and loss normalization before calling a mixture balanced.
25 min - 08
Measure what adaptation leaves behind
Compare target gains and retained capabilities with paired, group-aware uncertainty rather than assuming frozen base weights prevent forgetting.
26 min - 09
Control optimizer steps and effective exposure
Relate microbatches, accumulation, target tokens, and schedules without treating one default learning rate as universal.
26 min - 10
Release the whole adapter dependency tuple
Bind adapter weights to their base, tokenizer, targets, and serving configuration, and verify a real rollback path.
27 min