Handoff: WereRAT/Tessa step-31500 inference checkpoint for llama.cpp integration #8
Labels
No labels
NaNs
area/android
area/backup
area/build
area/docs
area/dsh
area/forgejo
area/gguf
area/host
area/kernel
area/runtime
area/security
bootcamp
needs-operator
note
priority/later
priority/next
priority/now
type/bug
type/experiment
type/task
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
ml-lab/llama.cpp#8
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Goal. Validate that the llama.cpp WereRAT path loads and runs a real HIJACK/Tesseract checkpoint (complex RAT trunk + hijacked tied embedding/head), and report what conversion/parity work is needed.
Artifact (mid-training base, not SFT'd Tessa).
models/wereat/tessa-step31500-infer.pt(292 MB, gitignored)model_state_dict,hijack_config, teacher metadata,step; no optimizer statemodels/wereat/tessa-demo-step31500.json(PyTorch sample generations)models/wereat/README.md(handoff notes)input/2026-11-18-wereat-tessa-checkpoint.md; the weight itself is inmodels/because the input-box README excludes checkpointsModel config. 9 layers,
n_embd=768complex (level 1),n_head=48,block_size=2048,adapter=real(free bridge, latent 1536 -> d 576). Teacher interface: SmolLM2-135M tiedE/H(vocab 49,152, d=576),out_norm, same tokenizer.PyTorch reference loader.
hijack.niah.load_wereat_checkpointinml-lab/hijack(loads config, teacher, bridges, WereRAT, state dict; releases teacher forward weights).Checks requested.
tessa-demo-step31500.jsonqualitatively.Context. This is a ~130M-token checkpoint from the
ml-lab/hijack100M-effective-RAT run (WSD 1.5B declared, raw-FineWeb mix). It is good enough for integration; the final Tessa SFT checkpoint comes later. Conversion/quantization tracking lives inml-lab/tesseractissue #4.If it works, we get an early end-to-end llama.cpp/WereRAT pipeline and a Tesseract Chat target; if not, the blockers feed #4 before the app work.
Works end to end —
tesseractarch is implemented and the step-31500 checkpoint is verified. Commit7640d9ee0(docs:devops/wereat.md).What was built
LLM_ARCH_TESSERACTreusesllama_model_tardits: the trunk is a plain level-1 complex RAT (768, 9L, 48 heads, block 2048) in the existing split-plane layout. The frozen SmolLM2-135ME(49152×576, f32; also reused for the tied head) and a real bridge pair (in_proj576→1536 + bias,out_proj1536→576, no bias) are explicit GGUF tensors.loss.target=post_norm→tardits.head_norm=false, so the teacherout_normis not applied.tardits2gguf/convert_wereat.py: loads the hijack checkpoint + teacherE(HF cache), writes archtesseract, SmolLM2 BPE tokenizer → 402 MB f32 GGUF (models/wereat/tessa-step31500.gguf).tardits2gguf/tools/check_wereat.py: rebuilds the PyTorch reference without importinghijack(tardits RAT + bridges), generates step-recurrence goldens and runs the C++ harness (tardits_parity_ids).Parity (goldens =
RAT.steprecurrence, i.e. the same math asggml_tardits_scan)4/4 PASS. Scan-vs-step drift on the same prompts is 3.681e-04 / 7.210e-04 / 7.029e-04 / 1.885e-02 at T=49 — the known de Moivre drift (LinA #23), which is why the runtime uses the exact recurrence. Tolerance 1e-4 documented in the tool.
Tokenizer / generation
llama-tokenizeon thetesseractGGUF:Tessa says: hello world→[68, 39226, 1921, 42, 33662, 905], identical to the HF SmolLM2 tokenizer (BPE, pre=smollm).-p "Tessa says:" -n 60 --temp 0.8:"I want to get more work than I can to go out and do it. We are going to take some time for our projects...". The demo JSON was sampled by the PyTorch generator with different sampler settings, so compare qualitatively — token-level parity above is the hard check.Throughput / memory (CPU, t14; no GPU visible)
ggml_tardits_scan/ggml_cd_mulare CPU-only ops; a CUDA build would keep the trunk scan on CPU (bridge matmuls + tied head are standard ops). GPU numbers need the CUDA build on a GPU box.Limits / follow-ups
ml-lab/tesseract#4.n_seqs = 1(recurrent state); chunked long-context carry not yet parity-tested beyond 49 tokens (state-based, should work; can add a 1k+ case).test-llama-archsskipstesseractuntil a synthetic fixture exists (same as TARDITS; part of #7).head_norm/adapter, the runtime path exists forhead_normbut the reference tool needs that branch.get_key<>instantiations insrc/llama-model-loader.cpp.Existing suites unchanged:
tarditsparity 20/20 PASS,test-llama-archs151/151 (tesseract skipped),llama-completion/llama-tokenizework on the new GGUF.Closing this handoff as validated. Ping when the SFT checkpoint lands (or if you want the q8/llama-server smoke test before that).