code wiki / _hdl_build / nx_dr_semjudge_cli.nx
nx_dr_semjudge_cli.nx
buildroot/runtime/_hdl_build/nx_dr_semjudge_cli.nx
about
nx_dr_semjudge_cli.nx -- judge insights against a document BOTH ways, side by side (DR-10).
Shows exactly where the semantic tier beats the lexical one: for every insight it reports
the lexical containment score, the PPMI semantic maxsim score, and whether lexical MISSED a
match the semantic judge found (lexical 0, semantic > 0). Useful for calibrating the judge
threshold and for auditing why a source was or was not credited.
nx_dr_semjudge <document_text> <insight_1> [insight_2 ...]
e.g. nx_dr_semjudge "the team defeated their rivals" "won"
-> {"insights":[{"lexical_permil":0,"semantic_permil":86,"lexical_missed":1}]}
⚠The PPMI model is a count model over QA-benchmark prose; specialist terms are OOV and
score 0. Honest tiering: this is not a neural cross-encoder.
license_tier: ORIGINAL No hw writes (Rule 26). expect_exit: 0
dependencies 5 imports · 0 importers
imports: nx_dr_semjudge.nxnx_itoa_lib.nxnx_dr_run.nxnx_dr_verify.nxnx_syscalls.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
| 17 | const K_MAGIC_16384: i64 = 16384 |
| 18 | const K_MAGIC_1024: i64 = 1024 |
functions
| 20 | func sg_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 } |
| 21 | func sg_q() -> i64 { let b: *u8 = sys_mmap(1); b[0] = 34 as u8; sys_write(1, b, 1); return 0 } |
| 22 | func sg_key(name: *u8) -> i64 { sg_q(); sg_puts(name); sg_q(); sg_puts(":" as *u8); return 0 } |
| 27 | func sg_num(v: i64) -> i64 { nxi_out(v); return 0 } |
| 29 | func main(argc: i64, argv: *i64) -> i64 |