code wiki / _hdl_build / nx_wiki_walk_gate.nx

nx_wiki_walk_gate.nx

buildroot/runtime/_hdl_build/nx_wiki_walk_gate.nx

10204 B206 linesdepth 10pulls 16 transitivereach 0 importersview sourcekind gate/prooftopic wiki
docsdependenciesstructsconstsfunctions

about

nx_wiki_walk_gate.nx -- REFEREE for the walkability metrics (modeled on nx_wiki_exceed_gate). Proves nx_wiki_walk_metrics MEASURES honestly + can SEE every case (no fabricated greens), via 3 hand-built framed-corpus fixtures: HEALTHY (3 pages, all reciprocally cross-linked, start reachable): reciprocity==100, orphans==0, dead-ends==0, reachability==100. SPARSE (3 pages, NO internal links at all): orphans high (>=66%), dead-ends==100%, reachability==33% (start only) -- proves full SENSITIVITY (it does NOT always report healthy). ONE-AXIS (HEALTHY but one page's outbound link removed -> exactly ONE dead-end and the reciprocity drops): dead-ends moves 0 -> >0 while orphans STAY 0 -- proves per-axis SPECIFICITY (greens can't be fabricated; moving one structural fact moves exactly the axes it should, not all-or-none). LIVE (the real live corpus): metrics RUN and assert the spine MEETS S-class structure -- orphans==0 AND dead-ends==0 AND reachability==100. GREEN iff all checks hold. Evidence -> knowledge/status/wiki_walk_gate.log. Sovereign: imports the organ + nx_framed_append + nx_syscalls. license_tier: ORIGINAL

dependencies 3 imports · 0 importers

nx_wiki_walk_metrics.nx nx_framed_append.nx nx_syscalls.nx nx_wiki_walk_gate.nx

imports: nx_wiki_walk_metrics.nxnx_framed_append.nxnx_syscalls.nx

imported by: nobody (leaf or entry point)

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

main sys_now_realtime_sec sys_mmap sys_clock_gettime_real sys_mmap ↻ wg_tmppath wg_cat wg_catn sys_mmap ↻ wg_emit_page wg_slen wg_cat ↻ wg_catn ↻ wg_write_file sys_openat_wr sys_write sys_close wm_measure sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_close ↻ nx_wiki_doc_store_init sys_mmap ↻ wm_ingest sys_mmap ↻ wm_is_page_mark wm_parse_int nx_wiki_doc_store_add sys_mmap ↻ nx_wib_pool_alloc nx_ims_resolve_root nx_wiki_doc_store_count sys_mmap ↻ nx_wiki_doc_store_lookup nx_ims_slug_eq sys_mmap ↻

structs

none

consts

23const WG_LOG: *u8 = "knowledge/status/wiki_walk_gate.log"
24const WG_LIVE_CORPUS: *u8 = "knowledge/status/ims_live_corpus.txt"
25const WG_LINKS: *u8 = "knowledge/registry/wiki_links.tsv"
26const WG_RECCAP: i64 = 512

functions

28func wg_cat(dst: *u8, off: i64, s: *u8) -> i64 { var i: i64 = 0; while s[i] != 0 as u8 { dst[off + i] = s[i]; i = i + 1 } return off + i }
29func wg_catn(dst: *u8, off: i64, v: i64) -> i64
called by 3: wg_tmppathwg_emit_pagemain calls 1: sys_mmap
39func wg_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != 0 as u8 { n = n + 1 } return n }
called by 1: wg_emit_page
42func wg_write_file(path: *u8, content: *u8, clen: i64) -> i64
49func wg_tmppath(out: *u8, stem: *u8, epoch: i64, pid: i64) -> i64
called by 1: main calls 2: wg_catwg_catn
58func wg_emit_page(dst: *u8, off: i64, url: *u8, body: *u8) -> i64
called by 1: main calls 3: wg_slenwg_catwg_catn
70func wg_row(name: *u8, pass: i64) -> i64
83func main() -> i64