nx_reasoning_gate.nx
buildroot/runtime/nx_reasoning_gate.nx
about
nx_reasoning_gate.nx -- MEASURED gate for sovereign TEST-TIME COMPUTE
(self-consistency, Wang 2023) on the REAL model (Qwen2.5-0.5B-Instruct,
v4-lazy forward, ChatML path).
controls pure: extractor (first/last/none), majority, tie, sentinel
liveness greedy is deterministic (Q0 twice -> byte-identical)
MEASURE 8 arithmetic questions x { greedy, self-consistency@5
(T=0.8, top-k=40, prime-spaced seeds) } -> accuracy tally
The verdict reports whichever way the measurement lands (LIFT / TIE /
HURT) -- the gate PASSES (exit 0) when the harness ran mechanically
clean; accuracy is REPORTED, not gamed. license_tier: ORIGINAL
expect_exit: 0
dependencies 22 imports · 0 importers
diagram shows first 10 each side; +12 more imports, +0 more importers in the complete lists below.
imports: nx_syscalls.nxnx_tier.nxnx_le.nxnx_bpe.nxnx_gguf.nxnx_gguf_load.nxnx_gguf_meta.nxnx_f32.nxnx_f32_kv_cache.nxnx_f32_lazy_weight.nxnx_f32_llama_block.nxnx_f32_llama_block_v4.nxnx_f32_llama_stack_v4.nxnx_f32_llama_layer_lazy_load.nxnx_f32_llm.nxnx_f32_llm_v4.nxnx_f32_llm_read_dims.nxnx_f32_bpe_load.nxnx_f32_llm_special_tokens.nxnx_f32_sampler.nxnx_prng.nxnx_reasoning.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 38 | const RG_M: nx_int = 8 // questions |
| 39 | const RG_N: nx_int = 5 // self-consistency samples per question |
functions
| 41 | func rg_w(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 } |
| 42 | func rg_wn(v: i64) -> i64 |
| 55 | func rg_wtext(b: *u8, n: i64) -> i64 |
| 68 | func rg_bytes_eq(a: *u8, b: *u8, n: i64) -> i64 called by 1: main |
| 74 | func rg_atoi(s: *u8) -> i64 called by 1: main |
| 92 | func main(argc: i64, argv: *i64) -> i64 |