code wiki / _hdl_build / nx_ppmi_probe.nx

nx_ppmi_probe.nx

buildroot/runtime/_hdl_build/nx_ppmi_probe.nx

6250 B156 linesdepth 4pulls 5 transitivereach 0 importersview sourcekind probetopic ppmi
docsdependenciesstructsconstsfunctions

about

nx_ppmi_probe.nx -- HONEST VERDICT on the SHIPPED knowledge/index/semppmi_v1.bin. Loads the persisted 41MB PPMI model (built by nx_semppmi_build) and prints the real probe cosines: cos(won,defeated) vs cos(won,purple), cos(city,stadium) vs cos(city,january). This is the evidence gate for wiring the dense/semantic reranker over the REAL model: both order -> GREEN (count-model carries the signal; dense reranker is wire-ready) not both -> AMBER (count-model weak at this pair; trained thread may be required) Reuses the PROVEN loader/cos format from nx_qabench.nx (ppmi_load/ppmi_cos), sem_isqrt re-defined locally (it lives in the app layer, not the engine). expect_exit: 0 license_tier: ORIGINAL

dependencies 1 imports · 0 importers

nx_qabench_engine.nx nx_ppmi_probe.nx

imports: nx_qabench_engine.nx

imported by: nobody (leaf or entry point)

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

main pb_load sys_read db_w db_n nxi_out nxi_fd sys_mmap ccz_cat_num sys_write sys_munmap pb_wid db_semhash db_bsearch_i64 pb_safecos pb_cos pb_isqrt

structs

none

consts

11const K_MAGIC_4096: i64 = 4096
12const K_MAGIC_536870912: i64 = 536870912
13const K_MAGIC_262144: i64 = 262144

functions

16func pb_isqrt(v: i64) -> i64
called by 1: pb_cos
25func pb_load(g: *i64) -> i64
called by 1: main calls 1: sys_read
78func pb_cos(g: *i64, a: i64, b: i64) -> i64
called by 1: pb_safecos calls 1: pb_isqrt
105func pb_wid(g: *i64, s: *u8) -> i64
called by 1: main calls 2: db_semhashdb_bsearch_i64
113func pb_safecos(g: *i64, a: i64, b: i64) -> i64
called by 1: main calls 1: pb_cos
119func main() -> i64