code wiki / _hdl_build / nx_nishi_builder.nx
nx_nishi_builder.nx
buildroot/runtime/_hdl_build/nx_nishi_builder.nx
about
nx_nishi_builder.nx -- THE NISHI BUILDER: one universal, self-growing emitter catalog for the WHOLE
ecosystem (websites, games, ads, ... -- "truly our builder"). Every emitter we build in any domain is TAUGHT
here as DATA; the builder reads the catalog to emit, and a GROW loop generates new emitters and registers
them -- so ONE builder keeps growing its emitters across ALL domains (the emitter-of-emitters, universal).
Generalises the ad-domain registry with a DOMAIN axis. Append-only + idempotent (rule 10/13). One row:
domain<TAB>kind<TAB>id<TAB>label<TAB>template
domain in {ad, web, game, ...}; kind is domain-scoped (ad: size/theme/accent/animation; web: section/nav/
button/layout; game: sprite/tilemap/mechanic/entity); template = the emit DATA for that block.
SOVEREIGNTY INVARIANT (the whole builder, by construction): nb_template_safe REJECTS any template carrying a
<script or src= -> NO third-party JS, NO external fetch, in ANY domain. Functions take `path` (hermetic test).
Registry: knowledge/registry/nishi_builder.tsv. (TSV now; seg-store = the doctrine follow-on.) license_tier: ORIGINAL
dependencies 1 imports · 16 importers
diagram shows first 10 each side; +0 more imports, +6 more importers in the complete lists below.
imports: nx_syscalls.nx
imported by: nx_ad_emitter_apply.nxnx_ad_nb_fold_gate.nxnx_brand_packs.nxnx_doc_member.nxnx_fin_member.nxnx_fin_member_gate.nxnx_food_stirfry_gate.nxnx_game_grow.nxnx_game_render.nxnx_game_render_gate.nxnx_game_scaffold.nxnx_game_scaffold_gate.nxnx_nishi_builder_gate.nxnx_nishi_builder_seed.nxnx_web_render.nxnx_web_render_gate.nx
structs
| none |
consts
| 15 | const NB_PATH: *u8 = "knowledge/registry/nishi_builder.tsv" |
| 16 | const NB_MAXTPL: i64 = 4096 |
functions
| 18 | func nb_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 } |
| 19 | func nb_field(line: *u8, linelen: i64, idx: i64, out: *u8) -> i64 |
| 27 | func nb_present(path: *u8, domain: *u8, kind: *u8, id: *u8) -> i64 |
| 45 | func nb_register(path: *u8, domain: *u8, kind: *u8, id: *u8, label: *u8, template: *u8) -> i64 called by 13: mainbp_teach_onem_regm_regfs_teachmain+7 calls 5: nb_presentsys_mmapsys_openat_appendsys_writesys_close |
| 59 | func nb_count(path: *u8, domain: *u8, kind: *u8) -> i64 |
| 78 | func nb_lookup(path: *u8, domain: *u8, kind: *u8, id: *u8, out_template: *u8) -> i64 called by 11: ab_emit_from_nbbp_loadmainfs_emit_componentmainmain+5 calls 4: sys_mmapsys_read_filenb_fieldnb_streq |
| 96 | func nb_template_safe(template: *u8) -> i64 |