how it works physics ...
packages: the gait pattern generator is @hackbuild/gait, the neural gait @hackbuild/motion-net, the saliency and sound helpers @hackbuild/senses, the model call scheduler @hackbuild/drives, the side camera @hackbuild/cameras, the tune registry @hackbuild/tunables, all mit. physics is rapier.
body: two motion sources share the rig, a central pattern generator (walk, pace, trot, canter, gallop picked by froude number, raibert foot placement, two bone ik) and the neural gait (paws pinned by predicted contacts, retargeted as paw targets). switches between them are inertialized so nothing snaps. springs drive posture, gaze, ears and a tail with eight wag modes.
brain: each act scores by how much it would reduce the dog's needs (keramati and gutkin 2011). the choice is sampled from a softmax with a commitment bonus; urgent acts start after a short heavy tailed latency while the head turns first. sleep pressure and a two peak body clock run onset, nrem, rem and wake. learning is rescorla wagner with pearce kaye hall associability, a faster fading inhibition and eligibility traces.
senses: itti koch saliency on the dog eye frame with top down drive bias and inhibition of return, looming startle from time to contact, per dog sound direction error, a scent plume sampled in sniff bouts and tracked upwind.
human: moheeb with retargeted quaternius clips (cc0), a gaze model, velocity springs, planted feet and a phased throw. his day runs on needs and an hourly routine; the top three options are drawn at random, weighted.
cortex: gemma 4 e2b or lfm2-vl 450m on webgpu sets goals on events, from a memory stream ranked by recency, importance and relevance (park 2023). reflexes and timing stay in code.
licences: app code mit. three.js mit, rapier apache 2.0, fonts apache 2.0 and ofl 1.1, animation clips cc0. fetched only when you ask: the neural gait model and mocap cc by-nc 4.0, yolov8n agpl 3.0, pocket tts engine apache 2.0 with cc by-nc 4.0 models, the cortex and mediapipe models under their own licences. LICENCES.md in the repository has the full list.