nx_vidclass_census.nx source
↩ module page · 98 lines · 12102 B
1// nx_vidclass_census.nx -- HONEST HAVE/PARTIAL/GAP census for the VIDEO-CLASSIFICATION SYSTEM (operator 2026-07-12:
2// detect orgasm / sexual positions / dancing+which-dance / behaviors -> a GROWING analysis library -> coach (SFW
3// training) + sexual-therapy + want-to-see/skip curation; "make the data actionable"). Maps what the sovereign
4// engine genuinely HAS (the live T1 demux-marker pipeline + the researcher/central-library) vs what must still be
5// BUILT (pose, trained classifiers, the fine-grained detectors). Evidence-backed + LIAR-KILLED: a HAVE/PARTIAL
6// must OPEN the real organ it cites (vc_have) or it downgrades to a logged LIE-GAP -- coverage cannot be faked by
7// symbol-presence. permille = (have*1000 + partial*500)/total. A LOW number is HONEST: it is the roadmap.
8// license_tier: ORIGINAL expect_exit: 0
9import "nx_gate.nx"
10
11func vc_have(path: *u8) -> i64 { let fd: i64 = sys_openat_rd(path); if fd < 0 { return 0 } sys_close(fd); return 1 }
12// c=[have,partial,gap,lie]. kind: 2=HAVE, 1=PARTIAL, 0=GAP. HAVE/PARTIAL liar-killed (cited file must open).
13func vc_row(kind: i64, label: *u8, path: *u8, note: *u8, c: *i64) -> i64 {
14 let opens: i64 = vc_have(path)
15 if kind == 2 {
16 if opens == 1 { c[0] = c[0] + 1; gw(" [HAVE ] " as *u8) }
17 if opens == 0 { c[2] = c[2] + 1; c[3] = c[3] + 1; gw(" [LIE-GAP] " as *u8) }
18 }
19 if kind == 1 {
20 if opens == 1 { c[1] = c[1] + 1; gw(" [PARTIAL] " as *u8) }
21 if opens == 0 { c[2] = c[2] + 1; c[3] = c[3] + 1; gw(" [LIE-GAP] " as *u8) }
22 }
23 if kind == 0 { c[2] = c[2] + 1; gw(" [GAP ] " as *u8) }
24 gw(label); gw(" -> " as *u8); gw(note); gw("\n" as *u8)
25 return 0
26}
27
28func main() -> i64 {
29 let c: *i64 = sys_mmap(64) as *i64
30 c[0] = 0; c[1] = 0; c[2] = 0; c[3] = 0
31 gw("=== nx_vidclass_census: video-classification system -- from demux markers to actionable behavior/scene data ===\n" as *u8)
32 gw(" (HAVE = a real sovereign organ opens; PARTIAL = substrate exists but not classification-wired; GAP = must build. liar-killed.)\n\n" as *u8)
33
34 gw("-- A. THE FOUNDATION: the live marker pipeline (T1, no training) --\n" as *u8)
35 vc_row(2, "clip-analysis marker finders (NXMK) " as *u8, "runtime/nx_ts_marks.nx" as *u8, "ts_silence_marks(dead-air t1) + ts_motion_marks(t3) + ts_scene_marks(t2): bitrate-RELATIVE demux, self-calibrating" as *u8, c)
36 vc_row(2, "executed proof of the finders " as *u8, "runtime/nx_ts_marks_gate.nx" as *u8, "nx_ts_marks_gate 9/9 GREEN (dead-air+motion+scene+rhythm, all bitrate-relative) -- a REAL gate, re-run every census" as *u8, c)
37 vc_row(2, "index-time emit into the sidecar " as *u8, "runtime/nx_ts_index.nx" as *u8, "bins audio+video bytes in the single TS scan -> appends NXMK markers as a BACK-COMPAT tail (v2 seek intact)" as *u8, c)
38 vc_row(2, "serve + render (LIVE) " as *u8, "runtime/_hdl_build/nx_gallery_serve.nx" as *u8, "gs_vid_marks /vid/<id>/marks JSON + daRender seekbar bands (red/cyan/green) -- LIVE on nishifamily.com/gallery" as *u8, c)
39
40 gw("\n-- B. GROUNDING: the researcher -> central library (sovereign info-mgmt plane) --\n" as *u8)
41 vc_row(2, "researcher on primary literature " as *u8, "runtime/nx_vidclass_research_fetch.nx" as *u8, "rf_fetch_bank the OpenAlex/Crossref/Semantic-Scholar originals (ACM/IEEE/arXiv) -> knowledge/library/*.txt" as *u8, c)
42 vc_row(2, "library foundationing (trust) " as *u8, "runtime/_hdl_build/nx_library_foundation.nx" as *u8, "CID + ed25519 provenance + lineage-to-god per library doc = the central library the librarian manages" as *u8, c)
43 vc_row(2, "librarian review (RACI, auto) " as *u8, "runtime/nx_librarian_review.nx" as *u8, "auto-reviews the researcher's ingest (foundationed/substantive/not-truncated) + records a seg_store handoff" as *u8, c)
44
45 gw("\n-- C. T1 DEMUX SIGNALS (arbitrary content, no training) --\n" as *u8)
46 vc_row(2, "activity/motion intensity " as *u8, "runtime/nx_ts_marks.nx" as *u8, "P-frame bitrate windows > median -> high-motion segments (dance/action CANDIDATES); actionable now" as *u8, c)
47 vc_row(2, "scene-cut boundaries " as *u8, "runtime/nx_ts_marks.nx" as *u8, "sharp bitrate rise vs prev window -> scene change point; chapter-grade navigation + curation input" as *u8, c)
48 vc_row(2, "dead-air / silence " as *u8, "runtime/nx_ts_marks.nx" as *u8, "audio-byte silence runs -> skippable quiet; the first actionable marker, LIVE" as *u8, c)
49 vc_row(2, "rhythm / tempo (dance cadence) " as *u8, "runtime/nx_ts_marks.nx" as *u8, "ts_rhythm_marks: integer autocorrelation on the motion bins -> periodic-motion (dance-move/phrase) segments, NXMK type 4, gate 9/9, LIVE" as *u8, c)
50
51 gw("\n-- D. T2 POSE: video -> body keypoints (positions, dance-pose) --\n" as *u8)
52 vc_row(1, "frame decode -> pixels " as *u8, "runtime/nx_h264_decode_frame.nx" as *u8, "Constrained-Baseline CAVLC I-slice decoder = luma for OUR gen/cam content; arbitrary High/CABAC needs a fuller decoder" as *u8, c)
53 vc_row(2, "pose CNN forward pass (heatmap producer) " as *u8, "runtime/nx_pose_cnn.nx" as *u8, "sovereign software-f32 pose-net FORWARD: 3x3 conv backbone + 1x1 head -> ReLU heatmaps, composes nx_f32_conv2d; runs end-to-end INTO the integer back-half, gate 5/5 (incl the executed load-bearing-ReLU proof). Architecture + arithmetic PROVEN, weights-free" as *u8, c)
54 vc_row(1, "sovereign pose estimator " as *u8, "runtime/nx_pose_keypoints.nx" as *u8, "BOTH HALVES built+gated end-to-end: FRONT nx_pose_cnn (f32 conv->ReLU heatmap, 5/5) + BACK nx_pose_keypoints (heatmap->keypoint: argmax+quarter-pixel subpixel+occlusion, 5/5). Estimator still needs TRAINED WEIGHTS; training is now MECHANICALLY PROVEN (conv fwd+bwd+loop CONVERGES, gate 5/5) so weights = a SCALE + labeled-data problem + the port benchmark (operator: benchmark-with-1/build-2)" as *u8, c)
55 vc_row(1, "position classifier " as *u8, "runtime/nx_pose_skeleton.nx" as *u8, "FIRST RUNG done+gated: pose_posture (upright/horizontal/inverted from the spine vector) + pose_compactness, gate 6/6; fine-grained NAMED-position label = trained T3 over the skeleton stream" as *u8, c)
56
57 gw("\n-- E. T3 TRAINED CLASSIFIERS: the fine-grained ask --\n" as *u8)
58 vc_row(2, "sovereign conv training loop (grad-checked)" as *u8, "runtime/nx_f32_conv2d_backward.nx" as *u8, "conv BACKWARD dW/dIn/dB gradient-checked EXACT (nx_f32_conv2d_backward_gate 5/5) + train-ops MSE/ReLU-bwd/SGD (nx_f32_train_ops) + a CONVERGENCE gate (nx_f32_conv_train_gate 5/5: loss->~0 through the real loop) + MULTI-LAYER backprop composes EXACT (nx_pose_backprop_gate 6/6: conv->ReLU->conv chain) -- a conv net TRAINS sovereignly; only SCALE + labeled data remain" as *u8, c)
59 vc_row(1, "sovereign ML training substrate " as *u8, "runtime/nx_nofloat_llm.nx" as *u8, "no-float/f32 matmul/attention/autograd stack + NOW conv fwd/bwd/train-loop (gradient-checked, converges); a VIDEO pose/classifier HEAD at SCALE + labeled data is the arc" as *u8, c)
60 vc_row(1, "audio affect features " as *u8, "runtime/_hdl_build/nx_asr_frontend.nx" as *u8, "nx_asr_power/total_energy = arousal-correlated audio dynamics; a trained affect head is the arc" as *u8, c)
61 vc_row(0, "action/behavior recognition model " as *u8, "" as *u8, "trained video action classifier (Kinetics-class) -> named behavior labels the coach/therapy consume" as *u8, c)
62 vc_row(0, "orgasm-state detector " as *u8, "" as *u8, "multimodal (motion + audio energy + affect) orgasm classifier -- labeled data + training" as *u8, c)
63 vc_row(0, "dance-type classifier (WHICH dance) " as *u8, "" as *u8, "labeled dance corpus -> style/type label (feeds the SFW dance coach)" as *u8, c)
64 vc_row(0, "scene-desirability (want-to-see vs skip) " as *u8, "" as *u8, "a personal preference model over the scene/behavior markers -> curation" as *u8, c)
65
66 gw("\n-- F. THE APPLICATIONS: make the data actionable --\n" as *u8)
67 vc_row(2, "marker -> coaching signals (actionable) " as *u8, "runtime/nx_coach_markers.nx" as *u8, "coach_summary + coach_trimlist: NXMK markers + posture -> SFW coaching FOCUS (trim/energy/rhythm/steady) + the EXACT dead-air spans to trim + inverted-posture form/safety escalation, gate 6/6" as *u8, c)
68 vc_row(1, "coach consumes the marker library " as *u8, "runtime/_hdl_build/nx_ws_coach.nx" as *u8, "the TRANSFORM is built+gated (nx_coach_markers 6/6); serving it inside the coach daemon (the SFW feedback surface) is the remaining deploy-side wire" as *u8, c)
69 vc_row(0, "sexual-therapy longitudinal analysis " as *u8, "" as *u8, "aggregate behavior/affect markers over time into therapy-useful signals (consent-gated, sovereign)" as *u8, c)
70 vc_row(0, "want-to-see / skip curation " as *u8, "" as *u8, "use scene + desirability markers to filter/surface what a person wants (or doesn't) to see" as *u8, c)
71
72 gw("\n-- G. MEASURE + SURFACE (the honesty loop) --\n" as *u8)
73 vc_row(2, "reality-check vs SOTA action-recognition " as *u8, "runtime/nx_vidclass_reality_check.nx" as *u8, "evidence-backed SOTA-gap LEDGER: per-axis OURS(gated) vs NAMED SOTA grounded in the banked lit (OpenPose/Two-Stream/TSN/Kinetics), 4/4 grounded 0 over-claim; AUTHORIZES only the T1 claim, REFUSES pose/action/dance SOTA (no weights) -- gate GREEN" as *u8, c)
74 vc_row(0, "/compare/vidclass evidence-backed page " as *u8, "" as *u8, "publish the matrix on the compare plane (.q from the library + .axes + .gates=nx_ts_marks_gate) -- executed proof" as *u8, c)
75
76 let total: i64 = c[0] + c[1] + c[2]
77 let permille: i64 = (c[0] * 1000 + c[1] * 500) / total
78 gw("\n--- TALLY ---\n HAVE=" as *u8); gn(c[0]); gw(" PARTIAL=" as *u8); gn(c[1]); gw(" GAP=" as *u8); gn(c[2])
79 gw(" of " as *u8); gn(total); gw(" capabilities (LIE-GAP downgrades caught = " as *u8); gn(c[3]); gw(")\n" as *u8)
80 gw(" video-classification domain coverage = " as *u8); gn(permille); gw(" permille (partial counts half)\n" as *u8)
81
82 gw("\n--- VERDICT ---\n" as *u8)
83 gw(" The FOUNDATION is real and LIVE: a bitrate-relative demux-marker pipeline (dead-air + motion + scene,\n" as *u8)
84 gw(" gate 7/7) emitting a growing NXMK sidecar the gallery already renders, grounded by a sovereign researcher\n" as *u8)
85 gw(" that banks the PRIMARY literature into the librarian-managed central library. That makes activity level,\n" as *u8)
86 gw(" scene boundaries, and silence ACTIONABLE today on arbitrary content -- no training, no external tools.\n" as *u8)
87 gw(" The LADDER ahead is the fine-grained classification: T2 POSE is now ARCHITECTURE-COMPLETE end-to-end --\n" as *u8)
88 gw(" f32 conv forward pass (nx_pose_cnn 5/5) -> keypoint back-half (nx_pose_keypoints 5/5) -> skeleton posture\n" as *u8)
89 gw(" (nx_pose_skeleton 6/6) -- so the ONLY T2 remainder is TRAINED WEIGHTS + a deeper backbone. T3 = TRAINED\n" as *u8)
90 gw(" classifiers (action/behavior/orgasm/dance-type/desirability) on the no-float ML substrate + labeled data,\n" as *u8)
91 gw(" then coach/therapy/curation. The census stays LOW on purpose -- it is the honest roadmap. The reality-check\n" as *u8)
92 gw(" LEDGER (nx_vidclass_reality_check, 4/4 grounded) now GATES claims: only the T1 layer is authorized live.\n" as *u8)
93 gw(" BUILD-2 is now mechanically PROVEN: conv fwd + gradient-checked backward + a CONVERGING training loop\n" as *u8)
94 gw(" (nx_f32_conv2d_backward 5/5 + nx_f32_conv_train_gate 5/5) -> the sovereign pose net TRAINS; only SCALE +\n" as *u8)
95 gw(" labeled data remain. NEXT: (1) BENCHMARK = port an HRNet/MoveNet-class net as the measured reference\n" as *u8)
96 gw(" (operator: benchmark-with-1; needs the external weights) (2) scale + train our net vs it (3) /compare/vidclass page.\n" as *u8)
97 sys_exit(0); return 0
98}