code wiki / (root) / nx_bright_prep_gate.nx

nx_bright_prep_gate.nx

buildroot/runtime/nx_bright_prep_gate.nx

11000 B200 linesdepth 4pulls 5 transitivereach 0 importersview sourcekind gate/prooftopic bright
docsdependenciesstructsconstsfunctions

about

nx_bright_prep_gate.nx -- GATE for nx_bright_prep (BRIGHT reshaped into the BEIR layout), driven IN-PROCESS through bp_run on the pinned pony fixtures (search.refs brightds26) into a /tmp tree: the receipt must reproduce the card (112 queries, 2219 qrels, 112 excluded pairs, 7894 corpus rows, 0 orphans, 2317793 corpus bytes), the files must carry the shapes nx_beir_eval reads (queries.tsv row 0 is id 0 TAB the known query prefix; qrels/test.tsv opens with the BEIR header then a score-1 row for the known first gold id; excluded.tsv row 0 is 0 TAB N/A), the licence must sit beside the bytes and name cc-by-4.0, and two runs must be byte-identical. Neg-controls: a missing examples file refuses at examples-open; the documents file offered as the examples file refuses at examples-columns (it has no query, gold_ids or excluded_ids); a missing documents file refuses at documents-open. SKIPs when the fixtures are absent, never acquits. Expected byte strings are BUILT at run time from named pieces and byte constants (a tab or newline spelled as an escape inside a literal is a lexer contract this gate does not depend on). license_tier: ORIGINAL No hw writes (Rule 26).

dependencies 3 imports · 0 importers

nx_syscalls.nx nx_gate_verdict.nx nx_bright_prep.nx nx_bright_prep_gate.nx

imports: nx_syscalls.nxnx_gate_verdict.nxnx_bright_prep.nx

imported by: nobody (leaf or entry point)

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

main gv_head gv_puts sys_write gv_ctr sys_mmap nxa_die sys_write ↻ sys_exit nxa_lock_take nxa_lock_addr sys_write ↻ nxa_lock_give nxa_lock_addr ↻ nxa_report_overrun sys_write ↻ nxa_dump_printable sys_write ↻ nxa_dump_sizes sys_write ↻ sys_mkdir sys_mmap ↻ g_cat g_slen g_catb g_pick sys_openat_rd sys_close gv_need gv_puts ↻ gv_check_eq gv_check gv_puts ↻ gv_puts ↻ gv_num sys_mmap ↻ sys_write ↻ sys_munmap bp_run sys_mmap ↻

structs

none

consts

16const G_ROOT: *u8 = "/tmp/nx_bright_prep_gate"
17const G_OUT_A: *u8 = "/tmp/nx_bright_prep_gate/bright/pony"
18const G_OUT_B: *u8 = "/tmp/nx_bright_prep_gate/bright2/pony"
19const G_QUERIES_A: *u8 = "/tmp/nx_bright_prep_gate/bright/pony/queries.tsv"
20const G_QRELS_A: *u8 = "/tmp/nx_bright_prep_gate/bright/pony/qrels/test.tsv"
21const G_EXCL_A: *u8 = "/tmp/nx_bright_prep_gate/bright/pony/excluded.tsv"
22const G_CORPUS_A: *u8 = "/tmp/nx_bright_prep_gate/bright/pony/corpus.tsv"
23const G_LICENSE_A: *u8 = "/tmp/nx_bright_prep_gate/bright/LICENSE"
24const G_QUERIES_B: *u8 = "/tmp/nx_bright_prep_gate/bright2/pony/queries.tsv"
25const G_QRELS_B: *u8 = "/tmp/nx_bright_prep_gate/bright2/pony/qrels/test.tsv"
26const G_CORPUS_B: *u8 = "/tmp/nx_bright_prep_gate/bright2/pony/corpus.tsv"
27const G_EX_A: *u8 = "knowledge/fetched/cmp_search_bright_examples_pony.parquet"
28const G_EX_B: *u8 = "../knowledge/fetched/cmp_search_bright_examples_pony.parquet"
29const G_DOC_A: *u8 = "knowledge/fetched/cmp_search_bright_documents_pony.parquet"
30const G_DOC_B: *u8 = "../knowledge/fetched/cmp_search_bright_documents_pony.parquet"
31const G_ABSENT: *u8 = "/tmp/nx_bright_prep_gate/no_such_file.parquet"
32const G_MODE_DIR: i64 = 0x1ed
33const G_I64: i64 = 8
34const G_EXPECT_CAP: i64 = 256
36const G_QUERIES: i64 = 112
37const G_QRELS: i64 = 2219
38const G_EXCL: i64 = 112
39const G_CORPUS: i64 = 7894
40const G_CORPUS_BYTES: i64 = 2317793
42const G_ZERO: *u8 = "0"
43const G_ONE: *u8 = "1"
44const G_NA: *u8 = "N/A"
45const G_Q0_TEXT: *u8 = "I will use the programming language pony"
46const G_H1: *u8 = "query-id"
47const G_H2: *u8 = "corpus-id"
48const G_H3: *u8 = "score"
49const G_GOLD0: *u8 = "Pony/4_control-structures_13.txt"
50const G_CORPUS0_ID: *u8 = "Pony/src-builtin-runtime_options-_1.txt"
51const G_LIC_MARK: *u8 = "cc-by-4.0"

functions

53func g_slen(s: *u8) -> i64
58func g_cat(dst: *u8, off: i64, s: *u8) -> i64
called by 1: main calls 1: g_slen
65func g_catb(dst: *u8, off: i64, b: i64) -> i64
called by 1: main
70func g_read(path: *u8, lenp: *i64) -> *u8
called by 2: g_files_equalmain calls 1: sys_read_file
74func g_starts(buf: *u8, n: i64, s: *u8) -> i64
called by 1: main calls 1: g_slen
81func g_contains(buf: *u8, n: i64, s: *u8) -> i64
called by 1: main calls 1: g_slen
93func g_files_equal(a: *u8, b: *u8) -> i64
called by 1: main calls 2: sys_mmapg_read
106func g_pick(a: *u8, b: *u8) -> *u8
called by 1: main calls 2: sys_openat_rdsys_close
114func main() -> i64