code wiki / (root) / nx_writehub_loop.nx

nx_writehub_loop.nx

buildroot/runtime/nx_writehub_loop.nx

4284 B73 linesdepth 3pulls 5 transitivereach 0 importersview sourcekind orphan librarytopic writehub
docsdependenciesstructsconstsfunctions

about

nx_writehub_loop.nx -- WRITING HUB rung R2: the autonomous IMMUNE-SCORED keep/discard decider -- the "grows on its own / autonomously improving" core. Uses the shared scorer lib nx_writehub_score (whl_eval: nx_writecraft readability + nx_writestyle adverb/passive/weak/hard-sentence -> ONE composite quality permil), then DECIDES: KEEP (>= WHL_KEEP) or REVISE -- naming the single WORST dimension as a directive the seat (nx_writehub_seat) can act on next round. Fully sovereign (no seat needed to run). Self-proves with two fixtures (a weak draft MUST revise, a clean draft MUST keep = the discriminator gate) and also scores a live draft at knowledge/staging/writehub_draft.txt if present. license_tier: ORIGINAL module: nishi-core.writehub.loop

dependencies 1 imports · 0 importers

nx_writehub_score.nx nx_writehub_loop.nx

imports: nx_writehub_score.nx

imported by: nobody (leaf or entry point)

structs

none

consts

9const K_MAGIC_2097152: i64 = 2097152

functions

11func wp(fd: i64, s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); if fd>0 { sys_write(fd,s,n) } return 0 }
12func wn(fd: i64, v: i64) -> i64
20func whl_strlen(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} return n }
22func whl_report(label: *u8, rep: *i64, fd: i64) -> i64
34func main() -> i64