nx_cap_census.nx
buildroot/runtime/nx_cap_census.nx
about
nx_cap_census.nx -- THE NISHI CAPABILITY DRIVER (unified, measurement-first). ONE engine measures how SOTA
any TARGET is, replacing the scattered per-lane census organs. Data-driven: a target T is defined by
knowledge/registry/T_capabilities.conf (cols: feature<TAB>surface<TAB>status<TAB>file<TAB>marker<TAB>note);
the set of targets is knowledge/registry/capability_targets.conf. SURFACES ARE DYNAMIC -- discovered from
the rows, so each target brings its own taxonomy (torrent: acquire..ops; protocol: core..advanced; the next
target: whatever it declares). LIAR-KILL: a HAVE/PARTIAL opens the repo-relative `file` and requires the
`marker` substring present (marker "-"=existence-only); a missing file OR absent marker flips the claim to
UNGROUNDED (counted as GAP + flagged) -- so a capability can never be asserted without the code on disk.
nx_cap_census -> ECOSYSTEM SCOREBOARD: one SOTA line per target + the overall number
nx_cap_census all -> same
nx_cap_census <target> -> full per-surface census + gap roadmap (the build order to 1000) for one target
Durable ecosystem log -> knowledge/status/capability_ecosystem_census.log. license_tier: ORIGINAL
dependencies 4 imports · 0 importers
imports: nx_str.nxnx_itoa_lib.nxnx_syscalls.nxnx_flatstore_flip.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 CAP_MAGIC_4096: i64 = 4096 |
| 18 | const CAP_MAGIC_65536: i64 = 65536 |
| 19 | const CAP_MAGIC_65000: i64 = 65000 |
| 20 | const CAP_MAGIC_131072: i64 = 131072 |
| 21 | const CAP_MAGIC_131000: i64 = 131000 |
| 22 | const CAP_MAGIC_200000: i64 = 200000 |
| 23 | const CAP_MAGIC_524288: i64 = 524288 |
| 24 | const CAP_MAGIC_20000: i64 = 20000 |
| 25 | const CAP_MAGIC_16384: i64 = 16384 |
| 26 | const CAP_MAGIC_16000: i64 = 16000 |
| 28 | const CAP_MANIFEST: *u8 = "knowledge/registry/capability_targets.conf" |
| 29 | const CAP_ROWKEY: *u8 = "cap:row:" |
| 30 | const CAP_ECOLOG: *u8 = "knowledge/status/capability_ecosystem_census.log" |
functions
| 32 | func cp(s: *u8) -> i64 { sys_write(1, s, nx_str_len(s)); return 0 } called by 5: cap_print_sourcescap_census_onecap_verify_onecap_judge_onemain calls 2: sys_writenx_str_len |
| 37 | func cnum(v: i64) -> i64 { nxi_out(v); return 0 } |
| 38 | func cwf(fd: i64, s: *u8) -> i64 { if fd>=0 { sys_write(fd, s, nx_str_len(s)) } return 0 } |
| 43 | func cwn(fd: i64, v: i64) -> i64 { nxi_fd(fd, v); return 0 } |
| 45 | func cap_streq(a: *u8, b: *u8) -> i64 { var i: i64=0; while a[i]!=(0 as u8) { if a[i]!=b[i] { return 0 } i=i+1 } if b[i]!=(0 as u8) { return 0 } return 1 } |
| 46 | func cap_app(dst: *u8, off: i64, s: *u8) -> i64 { var i: i64=0; while s[i]!=(0 as u8) { dst[off+i]=s[i]; i=i+1 } return off+i } |
| 47 | func cap_field(buf: *u8, ls: i64, le: i64, n: i64, out: *u8) -> i64 |
| 56 | func cap_contains(hay: *u8, hn: i64, needle: *u8) -> i64 called by 1: cap_grounded |
| 69 | func cap_grounded(file: *u8, marker: *u8, fbuf: *u8, fcap: i64) -> i64 |
| 79 | func cap_surf_reg(labs: *i64, nlab: *i64, s: *u8) -> i64 |
| 88 | func cap_pct(h: i64, p: i64, g: i64) -> i64 { let t: i64=h+p+g; if t<=0 { return 0 } return (h*2+p)*1000/(t*2) } called by 1: cap_census_one |
| 90 | func cap_find_after(buf: *u8, n: i64, needle: *u8) -> i64 called by 1: cap_prev_score |
| 102 | func cap_int_at(buf: *u8, n: i64, pos: i64) -> i64 called by 1: cap_prev_score |
| 110 | func cap_prev_score(buf: *u8, n: i64, target: *u8) -> i64 |
| 116 | func cap_conf_path(target: *u8, out: *u8) -> i64 |
| 119 | func cap_srcs_path(target: *u8, out: *u8) -> i64 |
| 123 | func cap_store_path(target: *u8, out: *u8) -> i64 |
| 130 | func cap_self_locate(argv: *i64) -> i64 |
| 152 | func cap_count_sources(target: *u8) -> i64 |
| 168 | func cap_print_sources(target: *u8) -> i64 |
| 191 | func cap_census_one(target: *u8, detail: i64, fbuf: *u8, out4: *i64) -> i64 |
| 255 | func cap_probe_grounded(probe: *u8) -> i64 |
| 268 | func cap_gate_run(probe: *u8) -> i64 |
| 293 | func cap_num_app(dst: *u8, off: i64, v: i64) -> i64 |
| 303 | func cap_verify_one(target: *u8, detail: i64, out3: *i64) -> i64 |
| 347 | func cap_judge_one(target: *u8, detail: i64, out2: *i64) -> i64 |
| 382 | func main(argc: i64, argv: *i64) -> i64 |