code wiki / (root) / nx_zimage_gguf_probe.nx

nx_zimage_gguf_probe.nx

buildroot/runtime/nx_zimage_gguf_probe.nx

2456 B59 linesdepth 8pulls 14 transitivereach 0 importersview sourcekind probetopic zimage
docsdependenciesstructsconstsfunctions

about

nx_zimage_gguf_probe.nx -- read the REAL Z-Image text-encoder GGUF structure, sovereignly. sd-server -> Nishi migration, the real-weight bridge: proves our sovereign GGUF reader (`nx_gguf_parse` + `nx_gguf_find_tensor` + `nx_gguf_tensor_at`, the same path `nx_real_gguf_test` gates on a 491MB Qwen) reads the ACTUAL Z-Image model weights -- `Z-Image_Qwen_3_4b-Q6_K.gguf` -- so real tensors can flow into our gated f32 organs (-> dequant `nx_q6_k_to_f32` -> the DiT/attention path). Bounded PREFIX read: the GGUF header + tensor-info + KV-metadata live at the FRONT of the file; tensor DATA (the multi-GB bulk) is lazy and not needed to enumerate/locate tensors, so we read only a 192MB prefix instead of the 2.5GB file. Pass: file opens, >=1KB read, GGUF v3, tensor_count sane, and token_embd.weight is found with dim_0>0. license_tier: ORIGINAL

dependencies 10 imports · 0 importers

nx_syscalls.nx nx_tier.nx nx_le.nx nx_strconv.nx nx_tensor.nx nx_gguf.nx nx_gguf_load.nx nx_gguf_meta.nx nx_placement.nx nx_gguf_load_lazy.nx nx_zimage_gguf_probe.nx

imports: nx_syscalls.nxnx_tier.nxnx_le.nxnx_strconv.nxnx_tensor.nxnx_gguf.nxnx_gguf_load.nxnx_gguf_meta.nxnx_placement.nxnx_gguf_load_lazy.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main sys_openat_rd sys_mmap sys_read sys_close nx_gguf_parse nx_le_read_u32 nx_le_read_u64 nx_le_read_u32 ↻ _gguf_skip_value nx_le_read_u64 ↻ nx_le_read_u32 ↻ _gguf_skip_value ↻ sys_mmap ↻ nx_gguf_find_tensor nx_gguf_tensor_at nx_gguf_name_equals nx_gguf_tensor_at ↻

structs

none

consts

none

functions

23func main() -> i64