code wiki / _hdl_build / nx_skill_coach_speech.nx

nx_skill_coach_speech.nx

buildroot/runtime/_hdl_build/nx_skill_coach_speech.nx

4380 B57 linesdepth 3pulls 3 transitivereach 0 importersview sourcekind tooltopic skill
docsdependenciesstructsconstsfunctions

about

nx_skill_coach_speech.nx -- SKILL-COACH audio-PROSODY adapter (the operator's "convincing capability in how i speak" + the hypnotist's voice + public speaking/acting). SENSOR-coach: from prosodic features (pace, pitch- variety, pause-control, fillers) -> grade each dimension -> diagnose -> DRILL. Perception composes the gated audio stack (nx_pitch over time = pitch-variety + energy/silence = pauses; fillers via ASR = a later rung); here features are passed in (like R1 passed known F0s). Thresholds inline at R1 (-> R2 rubric-store, rule#11). NO floats. Self-gate: 3 speaker profiles (confident / nervous / hesitant) -> correct issue diagnosis. license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_itoa_lib.nx nx_skill_coach_speech.nx

imports: nx_syscalls.nxnx_itoa_lib.nx

imported by: nobody (leaf or entry point)

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

main sp_puts sys_write sp_attempt sp_puts ↻ sp_putn nxi_out nxi_fd sys_mmap ccz_cat_num sys_write ↻ sys_munmap speech_coach sp_puts ↻ sp_putn ↻

structs

none

consts

10const PACE_LO: i64 = 110 // words/min: < = too slow
11const PACE_HI: i64 = 170 // > = too fast
12const PITCH_VAR_MIN: i64 = 200 // cents range of speaking pitch: < = monotone
13const PAUSE_LO: i64 = 8 // % time in pauses: < = rushed
14const PAUSE_HI: i64 = 30 // > = hesitant
15const FILLER_HI: i64 = 4 // fillers per 100 words: > = too many

functions

17func sp_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 }
22func sp_putn(v: i64) -> i64 { nxi_out(v); return 0 }
called by 2: sp_attemptmain calls 1: nxi_out
24func speech_coach(wpm: i64, pitch_range: i64, pause_pct: i64, fillers_per100: i64) -> i64
called by 1: sp_attempt calls 1: sp_puts
39func sp_attempt(label: *u8, wpm: i64, pr: i64, pp: i64, f: i64) -> i64
called by 1: main calls 3: sp_putssp_putnspeech_coach
44func main() -> i64