code wiki / _hdl_build / nx_researcher_spec_test.nx

nx_researcher_spec_test.nx

buildroot/runtime/_hdl_build/nx_researcher_spec_test.nx

3922 B53 linesdepth 3pulls 3 transitivereach 0 importersview sourcekind gate/prooftopic researcher
docsdependenciesstructsconstsfunctions

about

nx_researcher_spec_test.nx -- the Researcher takes the NEED "match a query beyond exact terms" (semantic retrieval) and emits a buildable SPEC decomposed to Layer-8. It produces TWO candidate specs and chooses honestly: SPEC A co-occurrence vectors + integer cosine -> primitives {COUNT, IMUL, IADD, ISQRT}, all available at L8 -> COMPLETE + ACTIONABLE -> hand to the Builder, build bits-up. SPEC B learned embeddings -> needs EMBED_TRAIN, NOT available -> flag as an LLM-gap, do not fake. So the team finds its own next build AND knows where it must stop and flag Claude. Exit 0 on 6/6. license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_researcher_spec.nx nx_syscalls.nx nx_researcher_spec_test.nx

imports: nx_researcher_spec.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 rt_puts sys_write sys_mmap rs_spec_complete rs_spec_actionable rs_first_missing rs_prim_available rs_first_missing ↻ rt_num sys_mmap ↻ sys_write ↻ rs_missing_is_llm_gap sys_exit

structs

none

consts

none

functions

13func rt_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 1: main calls 1: sys_write
14func rt_num(v: i64) -> i64 { let bb: *u8 = sys_mmap(28); var m: i64=v; if m<0 {m=0-m; sys_write(1,"-" as *u8,1)}; let t: *u8 = sys_mmap(28); var k: i64=0; if m==0 {t[0]=48;k=1}; while m>0 {t[k]=48+(m%10); m=m/10; k=k+1}; var i: i64=0; while i<k {bb[i]=t[k-1-i]; i=i+1}; sys_write(1, bb, k); return 0 }
called by 1: main calls 2: sys_mmapsys_write
16func main() -> i64