code wiki / _hdl_build / nx_team_harmony.nx
nx_team_harmony.nx
buildroot/runtime/_hdl_build/nx_team_harmony.nx
about
nx_team_harmony.nx -- THE ORCHESTRA: the Nishi team judges ITSELF and its COUNTERPARTS on the
ability to orchestrate and make "music" through total harmony (operator 2026-06-22). NOT Claude
grading -- the ecosystem measures itself from REAL signals, liar-killed:
SELF-judgment(role) = PRESENT (organ on disk) + OWNS (accountable for >=1 RACI activity)
COUNTERPART-judgment(role) = BOUND (named in the RACI contract) + PLAYING (live rows in the
sovereign roles- store) -- "the team's contract includes me AND I am
actually playing for them."
HARMONY(role) = SELF + PEER (0..4); IN-HARMONY iff == 4 (exists, owns, bound, AND playing).
MUSIC = TOTAL harmony scored by the WEAKEST section, not the average -- a few stars cannot fake
a full orchestra. MUSIC only when every section is in.
Grounds the roster + ownership in the VALIDATED RACI contract (knowledge/registry/nishi_raci.tsv,
the SSOT nx_raci enforces) + live activity in the sovereign seg-store via nx_role_store rs_count.
Sovereign. license_tier: ORIGINAL
dependencies 3 imports · 0 importers
imports: nx_role_store.nxnx_syscalls.nxnx_raci_sov.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 TH_MAGIC_2026: i64 = 2026 |
| 20 | const TH_MAXROWS: i64 = 512 |
| 21 | const TH_STR: i64 = 40 |
| 22 | const TH_CAP: i64 = 262144 |
| 23 | const TH_LOG: *u8 = "knowledge/status/team_harmony.log" |
functions
| 25 | func th_w(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 } |
| 26 | func th_n(v: i64) -> i64 |
| 34 | func th_pad(s: *u8, width: i64) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); var p: i64 = width - n; while p > 0 { th_w(" " as *u8); p = p - 1 } return 0 } |
| 35 | func th_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 } |
| 36 | func th_has(s: *u8, ch: i64) -> i64 { var i: i64 = 0; while s[i] != (0 as u8) { if (s[i] as i64) == ch { return 1 } i = i + 1 } return 0 } |
| 37 | func th_cpy(dst: *u8, src: *u8, max: i64) -> i64 { var i: i64 = 0; while src[i] != (0 as u8) { if i < max - 1 { dst[i] = src[i] } i = i + 1 } dst[i] = 0 as u8; return 0 } called by 1: th_load |
| 38 | func th_cat(dst: *u8, off: i64, s: *u8) -> i64 { var o: i64 = off; var i: i64 = 0; while s[i] != (0 as u8) { dst[o] = s[i]; o = o + 1; i = i + 1 } return o } |
| 40 | func th_read(path: *u8, buf: *u8, cap: i64) -> i64 |
| 46 | func th_field(line: *u8, len: i64, idx: i64, out: *u8, outcap: i64) -> i64 |
| 56 | func th_load(roleS: *u8, letS: *u8) -> i64 |
| 84 | func th_bound(roleS: *u8, nrows: i64, role: *u8) -> i64 |
| 89 | func th_owns(roleS: *u8, letS: *u8, nrows: i64, role: *u8) -> i64 |
| 97 | func th_present(organ: *u8) -> i64 |
| 106 | func th_playing(channel: *u8) -> i64 { if rs_count(channel) > 0 { return 1 } return 0 } |
| 109 | func th_ext(role: *u8, want_A: i64) -> i64 |
| 130 | func th_delivering(channel: *u8) -> i64 |
| 148 | func th_exceeding(channel: *u8) -> i64 |
| 163 | func th_judge(role: *u8, organ: *u8, channel: *u8, roleS: *u8, letS: *u8, nrows: i64, t: *i64) -> i64 |
| 188 | func main(argc: i64, argv: *i64) -> i64 |