code wiki / (root) / nx_elder_seed.nx

nx_elder_seed.nx source

↩ module page · 85 lines · 7442 B

1// nx_elder_seed.nx -- seed Elder AI's REAL character into the sovereign visual store (nx_visual_arc), with a 2// rich wardrobe + scene set so the odometer has real breadth to draw from. Grounds the system in the operator's 3// ACTUAL character (Elara, the curvy-brunette identity from the character_appearance DNA) instead of a demo 4// placeholder. Identity anchor = the full_appearance_prompt (constant = same person). Wardrobe = the operator's 5// real outfit vocabulary (from the legacy outfit set), scenes = our domestic/intimate settings. All DATA 6// (rule 11/25): uncensored, the record IS the look. Seeds into the PRODUCTION VID_PREFIX and self-verifies the 7// variety (distinct looks, identity constant). Run via nx_sov_build_run. license_tier: ORIGINAL expect_exit: 0 8import "nx_visual_arc.nx" 9const ELARA_MAGIC_8192: i64 = 8192 10 11// Elara's identity ANCHOR (constant across every render -- the SAME PERSON). CANONICAL, verified via 12// nx_char_verify against the platform data-vault (operator: "Elara is a blonde, doublecheck" -- my first pass 13// wrongly used a curvy-brunette tier variant; the platform's own regression notes flag "canonical Elara is 14// platinum blonde; a brunette is wrong"). Real DNA: 18, Nata Lee face, slim petite frame + large natural 32F 15// bust, tall, warm-golden platinum-blonde, light blonde brows, freckles, warm peachy glow, base realism anchor. 16const ELARA_ANCHOR: *u8 = "Elara, eighteen years old, the face of model Nata Lee, a slim petite frame with a large natural 32F bust, narrow slim hips, long lean arms and exquisitely shaped long legs, delicate shoulders, graceful slender hands, tall and elegant; long warm golden platinum-blonde hair with sun-bleached highlights, naturally arched light blonde eyebrows never shaped, small pointed chin, faint freckles scattered across her nose, clear skin with a warm peachy glow, dewy and luminous; candid photograph of a real person, catch light in her eyes, warm skin tones, shallow depth of field, visible pores, natural skin texture" as *u8 17 18// Wardrobe -- adult, uncensored per doctrine (she is an 18yo girlfriend archetype -- legal; the platform's own 19// established character). '|'-separated items. 20const ELARA_WARDROBE: *u8 = "wearing an oversized band tee that hangs off one shoulder, bare legs|natural and unclothed, at ease in her own skin|wearing a sheer gossamer nightgown that hides nothing|wearing tiny cotton sleep shorts and a cropped cami|wearing a fitted long black wool coat with a faux-fur collar and knee-high boots|wearing an oversized flannel unbuttoned over a bralette|wearing a school-plaid skirt and a knotted white shirt|wearing a strappy metallic bikini|wearing tight yoga pants and a sports crop|wearing a silk robe loosely tied at the waist|wearing thigh-high socks and an oversized hoodie, nothing else|wearing a bodycon mini dress|wearing lace lingerie, delicate straps|wearing his shirt and nothing else" as *u8 21 22// OUR scenes -- Elara's real world (cozy bedroom with string lights + plushies; her home). 23const ELARA_SCENES: *u8 = "in her cozy bedroom with string lights and plushies and band posters|in a sunlit bedroom, morning light through sheer curtains|at the desk in the home office, laptop glow|in a warm kitchen at morning|in a steamy shower, water running over her skin|in a candle-lit bath|curled on the bed under soft lamplight, evening|by a rain-streaked window" as *u8 24 25// activities / poses -- confident, playful, devoted (her real personality) 26const ELARA_ACTS: *u8 = "curled up with a plushie, glancing up at you|stretching lazily in the warm light|laughing over her shoulder, playful|leaning in close with a teasing smile|lying back on the bed, gazing up|glancing up through her lashes|blowing you a kiss|biting her lip with a knowing look" as *u8 27 28func sw(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 } 29func sn(v: i64) -> i64 { let bb: *u8=sys_mmap(28); var m: i64=v; if m<0{sys_write(1,"-" as *u8,1);m=0-m} let t: *u8=sys_mmap(28); var k: i64=0; if m==0{t[0]=48 as u8;k=1} while m>0{t[k]=(48+(m%10)) as u8;m=m/10;k=k+1} var i: i64=0; while i<k{bb[i]=t[k-1-i];i=i+1} sys_write(1,bb,k); return 0 } 30 31func main() -> i64 { 32 sw("=== nx_elder_seed: seed the REAL Elara character into the sovereign visual store ===\n" as *u8) 33 vid_put("elara" as *u8, ELARA_ANCHOR, ELARA_WARDROBE, ELARA_SCENES, ELARA_ACTS) 34 varc_reset("elara" as *u8) 35 36 // counts 37 let p: *i64 = sys_mmap(16) as *i64 38 let l: *i64 = sys_mmap(16) as *i64 39 let idx: *i64 = sys_mmap(32) as *i64 40 // derive nO/nS/nA by reading the record via one indices call at step 0, then counting items 41 vid_get_pfx(VID_PREFIX, "elara" as *u8, p, l) 42 let rec: *u8 = p[0] as *u8; let rl: i64 = l[0] 43 let f: *i64 = sys_mmap(16) as *i64 44 var nO: i64=0; var nS: i64=0; var nA: i64=0 45 if tr_field(rec,0,rl,VF_WARDROBE,f)==1 { nO=vitem_count(rec,f[0],f[1]) } 46 if tr_field(rec,0,rl,VF_SCENES,f)==1 { nS=vitem_count(rec,f[0],f[1]) } 47 if tr_field(rec,0,rl,VF_ACTS,f)==1 { nA=vitem_count(rec,f[0],f[1]) } 48 sw("SEEDED elara: " as *u8); sn(nO); sw(" outfits x " as *u8); sn(nS); sw(" scenes x " as *u8); sn(nA); sw(" poses = " as *u8); sn(nO*nS*nA); sw(" distinct looks\n" as *u8) 49 50 var pass: i64 = 0 51 var tot: i64 = 0 52 53 // sample a few looks to SEE the variety + identity constancy 54 let a: *u8 = sys_mmap(ELARA_MAGIC_8192) 55 sw("\n-- sample looks (identity CONSTANT, everything else SHIFTS) --\n" as *u8) 56 var st: i64 = 0 57 while st < 4 { varc_prompt_at("elara" as *u8, st, a, ELARA_MAGIC_8192); sw(" step " as *u8); sn(st); sw(": " as *u8); sw(a); sw("\n" as *u8); st = st + 1 } 58 59 // T1: identity anchor present at step 0 AND a far step 60 tot=tot+1 61 let l0: i64 = varc_prompt_at("elara" as *u8, 0, a, ELARA_MAGIC_8192) 62 var idc: i64 = 0 63 if ex_has(a, l0, "platinum-blonde" as *u8)==1 { let lf: i64 = varc_prompt_at("elara" as *u8, 200, a, ELARA_MAGIC_8192); if ex_has(a, lf, "platinum-blonde" as *u8)==1 { if ex_has(a, lf, "Nata Lee" as *u8)==1 { idc=1 } } } 64 if idc==1 { pass=pass+1; sw("PASS T1 identity constant across the arc (same platinum-blonde Elara, Nata Lee face)\n" as *u8) } else { sw("FAIL T1\n" as *u8) } 65 66 // T2: rich variety -- first nO steps give nO DISTINCT outfits 67 tot=tot+1 68 let seen: *i64 = sys_mmap(8*64) as *i64; var ns: i64=0 69 st = 0 70 while st < nO { varc_indices_pfx(VID_PREFIX, "elara" as *u8, st, idx); let o: i64=idx[0]; var d: i64=0; var j: i64=0; while j<ns { if seen[j]==o {d=1} j=j+1 } if d==0 { seen[ns]=o; ns=ns+1 } st=st+1 } 71 if ns==nO { pass=pass+1; sw("PASS T2 rich variety: " as *u8); sn(nO); sw(" distinct outfits over " as *u8); sn(nO); sw(" steps (clothes change every render)\n" as *u8) } else { sw("FAIL T2 distinct=" as *u8); sn(ns); sw("\n" as *u8) } 72 73 sw("nx_elder_seed pass=" as *u8); sn(pass); sw("/" as *u8); sn(tot) 74 if pass==tot { sw(" verdict=GREEN (the REAL Elara now has a rich wardrobe + our scenes; same person, new look every render)\n" as *u8); sys_exit(0); return 0 } 75 sw(" verdict=RED\n" as *u8); sys_exit(1); return 1 76} 77 78func ex_has(hay: *u8, hlen: i64, needle: *u8) -> i64 { 79 var nl: i64=0; while needle[nl]!=(0 as u8){nl=nl+1} 80 if nl==0 { return 1 } 81 if hlen<nl { return 0 } 82 var i: i64=0 83 while i<=hlen-nl { var m: i64=1; var c: i64=0; while c<nl { if hay[i+c]!=needle[c]{m=0;c=nl} else {c=c+1} } if m==1 {return 1} i=i+1 } 84 return 0 85}