pub struct DflashCfg {Show 15 fields
pub hidden: usize,
pub n_head: usize,
pub n_kv: usize,
pub head_dim: usize,
pub n_ff: usize,
pub n_layer: usize,
pub eps: f32,
pub rope_theta: f32,
pub block_size: usize,
pub mask_token_id: u32,
pub target_layer_ids: Vec<usize>,
pub sliding_window: usize,
pub layer_sliding: Vec<bool>,
pub strategy_dspark: bool,
pub is_causal: Option<bool>,
}Fields§
§n_head: usize§n_kv: usize§head_dim: usize§n_ff: usize§n_layer: usize§eps: f32§rope_theta: f32§block_size: usize§mask_token_id: u32§target_layer_ids: Vec<usize>§sliding_window: usize§layer_sliding: Vec<bool>true = sliding_attention for that layer (4x true + 1x false on the 31B draft).
strategy_dspark: boolCheckpoint training-strategy census (dspark_strategy_census over the raw
config.json): true = a SpecForge DSPARK-strategy export (shifted labels, ALL rows
supervised — the q38 arm-a family). Keys the HARVEST DEFAULT strategy-keyed,
never env-keyed (owner-ratified 2026-08-20 after B1 confirmed H1 ×5;
DSPARK-POSTMORTEM-20260820.md B0 default-flip plan).
is_causal: Option<bool>Explicit top-level is_causal from config.json (z-lab reference: an explicit
value OVERRIDES the per-layer-type default). The DFlash2 q38 checkpoint carries
"is_causal": false — every sliding layer is NON-causal with a symmetric
+/-2048 window (model.py _attention_mask). None = key absent (historical
exports; the windowless-assert arm keeps handling those byte-identically).