nx_absa_bench_gate.nx
buildroot/runtime/nx_absa_bench_gate.nx
about
nx_absa_bench_gate.nx -- GATE for the SemEval-2014 SB1 scorer in nx_absa_lib (intelmine IM17), driven
IN-PROCESS on a planted gold set under /tmp/nx_absa_bench_gate. The load-bearing proof is the F1 arithmetic
(ab_prf) checked at exact permil values including the ZERO-PREDICTION control the rung's done-rule names; the
gold parser is proven to dedupe distinct terms and to survive CRLF; the normaliser is proven case- and
whitespace-insensitive; a multi-word gold term is proven UNMATCHABLE by a unigram (the honest weakness); and
the full ab_eval pipeline is proven non-vacuous on the planted gold. Every fixture asserts its own condition
before any outcome is judged. No network. license_tier: ORIGINAL No hw writes (Rule 26).
dependencies 5 imports · 0 importers
imports: nx_syscalls.nxnx_gatekit_lib.nxnx_reviewmine_lib.nxnx_absa_lib.nxnx_gate_verdict.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
| 14 | const G_ROOT: *u8 = "/tmp/nx_absa_bench_gate" |
| 15 | const G_GOLD: *u8 = "/tmp/nx_absa_bench_gate/gold.seg" |
| 16 | const G_GOLDCRLF: *u8 = "/tmp/nx_absa_bench_gate/goldcrlf.seg" |
| 17 | const G_I64: i64 = 8 |
| 18 | const G_LINES: i64 = 12 // four three-line records |
| 19 | const G_NG: i64 = 3 // distinct terms: food, service, hard disk (food appears twice) |
| 20 | const G_LF: i64 = 10 |
| 21 | const G_CR: i64 = 13 |
| 22 | const G_CRLF_CAP: i64 = 512 |
| 24 | const G_LEXDIR: *u8 = "/tmp/nx_absa_bench_gate/lex/" |
| 25 | const G_NOLEXDIR: *u8 = "/tmp/nx_absa_bench_gate/nolex/" |
| 26 | const G_LEX_DEFECT: *u8 = "/tmp/nx_absa_bench_gate/lex/lexicon_defect.conf" |
| 27 | const G_LEX_NOTMEET: *u8 = "/tmp/nx_absa_bench_gate/lex/lexicon_notmeet.conf" |
| 28 | const G_LEX_EXCEED: *u8 = "/tmp/nx_absa_bench_gate/lex/lexicon_exceed.conf" |
| 29 | const G_ABSENT_GOLD: *u8 = "/tmp/nx_absa_bench_gate/absent.seg" |
| 30 | const G_RECORDS: i64 = 4 |
| 31 | const G_LEX_TERMS: i64 = 5 // slow, noisy (defect) + refund (not met) + great, fast (exceed) |
| 34 | const G_GOLD_NG: *u8 = "/tmp/nx_absa_bench_gate/gold_ng.seg" |
| 35 | const G_ROWS_NG: *u8 = "The $T$ was great .\nfood\n1\nThe $T$ is slow .\nservice\n-1\nThe $T$ is noisy .\nhard disk\n0\nGreat $T$ here .\nfood\n1\nThe $T$ is loud .\nhard disk\n-1\n" |
| 36 | const G_NG_LINES: i64 = 15 |
| 37 | const G_NG_RECORDS: i64 = 5 |
| 38 | const G_NG_MINSUP: i64 = 2 // pins support at the bigram's frequency |
| 39 | const G_NG_MINSUP_ABOVE: i64 = 3 // one above it: the control that must find no frequent bigram |
| 40 | const G_NG_CANDS: i64 = 3 // hard disk, food, great |
| 41 | const G_NG_PRUNED: i64 = 2 // hard, disk |
| 42 | const G_TRAIN: *u8 = "/tmp/nx_absa_bench_gate/train.seg" |
| 43 | const G_TEST: *u8 = "/tmp/nx_absa_bench_gate/test.seg" |
| 44 | const G_TRAIN_ROWS: *u8 = "The $T$ was slow .\nfood\n1\nThe $T$ is rude .\nservice\n-1\nThe $T$ is noisy .\nhard disk\n0\nThe $T$ is nice .\nkeyboard\n1\n" |
| 45 | const G_TEST_ROWS: *u8 = "The $T$ was great .\nfood\n1\nThe $T$ is noisy .\nhard disk\n0\nThe $T$ broke .\nmouse\n-1\nI like the keyboard and $T$ .\nfood\n1\n" |
| 46 | const G_D_DICT: i64 = 4 |
| 47 | const G_D_RECORDS: i64 = 4 |
| 48 | const G_D_NG: i64 = 3 |
| 49 | const G_D_PRED: i64 = 3 |
| 50 | const G_D_INTER: i64 = 2 |
| 52 | const G_ROWS: *u8 = "The $T$ was great .\nfood\n1\nThe $T$ is slow .\nservice\n-1\nThe $T$ is noisy .\nhard disk\n0\nGreat $T$ here .\nfood\n1\n" |
functions
| 54 | func g_lines(path: *u8) -> i64 |
| 65 | func g_crlf(src: *u8, out: *u8) -> i64 called by 1: main |
| 77 | func main() -> i64 |