code wiki / (root) / nx_teacher_consult.nx

nx_teacher_consult.nx

buildroot/runtime/nx_teacher_consult.nx

4124 B89 linesdepth 10pulls 11 transitivereach 1 importersview sourcekind tooltopic teacher
docsdependenciesstructsconstsfunctions

about

nx_teacher_consult.nx -- makes the unified capability store ACTIONABLE (Teacher arc, rung R4): the team (or operator) ASKS "what do we know about <topic>?" and gets every matching insight. Until now the store was write + recall-by-id only; consult turns 113 stored lessons into on-demand wisdom the team consults WHILE working (e.g. before a build: consult "compile"; before a publish: consult "publish"). Match = the insight's rule CONTAINS the query (case-insensitive substring). Reads the shared native store via ncfg -- coordinates THROUGH the store (SL-004), imports nx_teacher_merge for the store machinery only. No network/hardware writes (Rule 26). license_tier: ORIGINAL

dependencies 2 imports · 1 importers

nx_teacher_merge.nx nx_syscalls.nx nx_teacher_consult.nx nx_teacher_consult_gate.nx

imports: nx_teacher_merge.nxnx_syscalls.nx

imported by: nx_teacher_consult_gate.nx

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

main tc_puts sys_write ncfg_open ss_open_cached ssc_init sys_mmap ssc_sig_of ss_cat sys_fstatat ssc_streq ss_open ss_open2 sys_mmap ↻ ss_manifest_dyn ss_manifest_file_dyn ss_cat ↻ ss_loadfile sys_map_file ss_readall ss_load_aux2 sys_mmap ↻ ss_cat ↻ ss_loadfile ↻ ss_r32 sys_munmap ssl_total_keys ss_r32 ↻ ssl_pow2 ssl_build ss_r32 ↻ ssl_hash_entry ssl_key_eq ss_r32 ↻ ssl_lookup ssl_hash_entry ↻ ssl_key_eq ↻ ss_manifest_free sys_munmap ↻ sys_munmap ↻

structs

none

consts

none

functions

12func tc_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != 0 as u8 { n = n + 1 } sys_write(1, s, n); return 0 }
called by 3: tc_consulttc_askmain calls 1: sys_write
13func tc_putn(v: i64) -> i64
called by 2: tc_askmain calls 2: sys_writesys_mmap
22func tc_lc(c: i64) -> i64 { if c >= 65 { if c <= 90 { return c + 32 } } return c }
called by 1: tc_contains_ci
24func tc_contains_ci(hay: *u8, needle: *u8) -> i64
called by 1: tc_consult calls 1: tc_lc
38func tc_consult(store: *u8, query: *u8) -> i64
68func tc_ask(store: *u8, query: *u8) -> i64
called by 1: main calls 3: tc_putstc_consulttc_putn
75func main() -> i64