pub struct BakeArtifacts {
pub keep: Vec<Vec<bool>>,
pub keep_visits: Vec<Vec<bool>>,
pub down: Vec<Vec<f32>>,
pub gate_up: Vec<Option<(Vec<f32>, Vec<f32>)>>,
pub fcd_layers: Vec<usize>,
pub attn: Vec<Option<AttnMasters>>,
pub logits: Vec<Vec<f32>>,
pub final_logits: Vec<Vec<f32>>,
pub checkpoints: Vec<BakeCheckpoint>,
}Expand description
The trained artifacts: everything the defrag writer needs, f32.
Fields§
§keep: Vec<Vec<bool>>Per-PHYSICAL-layer live flags: the union over visits — a weight row is removable from disk only when no visit keeps it.
keep_visits: Vec<Vec<bool>>Per-VIRTUAL-layer live flags (physical × loops, pass-major): the mask the file ships and the runtime applies per visit.
down: Vec<Vec<f32>>Per-layer down_proj [hidden, inter] with dead columns zeroed
(FCD layers: the trained weights; others: the backbone’s).
gate_up: Vec<Option<(Vec<f32>, Vec<f32>)>>Trained gate/up for the FCD layers (None elsewhere).
fcd_layers: Vec<usize>Which layers went through Phase B.
attn: Vec<Option<AttnMasters>>Trained attention/norm masters (full-layer FCD), per layer.
logits: Vec<Vec<f32>>The trained mask logits, per virtual layer — a CONTINUOUS per-neuron importance the hard keep flags throw away. The tube planner ranks and orders neurons by these, not by raw activation mass.
final_logits: Vec<Vec<f32>>Phase-A logits after the last requested optimization step, before restoring the selected hard-validation checkpoint.
checkpoints: Vec<BakeCheckpoint>