Skip to main content

record

Function record 

Source
pub fn record(
    layer: usize,
    k_not_v: bool,
    proj: &[f32],
    n_kv: usize,
    head_dim: usize,
)
Expand description

Record every head’s K (k_not_v = true) or V vector from a projection slice. proj holds n_kv contiguous head vectors of head_dim each ([h0…][h1…]…). No-op (one atomic load) when disabled; stops appending to a layer/stream once its max_per_layer cap is hit.