deniz.in

Markets

Weather

Loading weather

· via Hacker News – Front Page (native)

Gemini-written compiler fills 97% of a language model's stored bytes, training only 103M parameters

A preprint by Youngseong Kim has Gemini 4 Neon design a compiler that turns 31.8B tokens of corpus statistics into 97% of a language model's stored bytes, with gradient descent training just a 103M-parameter network on top.

Gemini-written compiler fills 97% of a language model's stored bytes, training only 103M parameters

An independent researcher has published a preprint in which a frontier LLM writes the program that fills most of a language model's weights, with gradient descent reserved for a small trained network. According to the paper by Youngseong Kim, posted to Preprints in November 2026 via a project page that reached Hacker News's front page, a compiler designed by Gemini 4 Neon turns 31.8 billion tokens of corpus statistics into a 7.96 GiB bank of sparse tables — over 97% of the model's stored bytes — without a single gradient step. Gradient descent then trains only a 103M-parameter network on top of the frozen tables, using 10B tokens on a single GPU.

Writing weights instead of learning them

The approach is an instance of what the paper calls weight-space programming: having a frontier model read and write the weights of a neural network directly rather than learning them through gradient descent. Prior work in this vein, the paper notes, has been limited to small networks or to sparse edits of existing models, and the paper positions this project as the first time WSP has been used to build a language model from scratch.

A key nuance is that the LLM does not write the weights literally; it writes the program that compiles them. That program, designed by Gemini 4 Neon, converts corpus statistics into the frozen tables that hold the overwhelming majority of the model's stored bytes.

Architecturally, the Transformer consults the tables at every position, through an Engram block after its fourth layer and through gated fusion with the output logits. The tables expose 18 channels in six groups: n-grams over the last one to five tokens, skip-grams with gaps, synonym clusters of recent tokens, concept associations, explicit phrase and fact rules, and in-context statistics from the current document. Every channel answers in the same form — a short list of next-token candidates with scores — so the trained network only has to learn how much to trust each channel at each position. The five corpus-derived groups are counted from 31.8B FineWeb-Edu tokens, disjoint from the network's training data.

The numbers

On 2,000 held-out FineWeb-Edu documents, the table model reaches a word-level perplexity of 46.4, 11% lower than the 52.1 of a parameter-matched baseline with the same backbone and the same 10B training tokens but no tables. Under the parameter scaling law of Kaplan et al. (2020), the paper compares that gap to making the network roughly 1.5 times larger. Mean zero-shot accuracy across ten tasks rises by 1.2 points, with the largest gains on tasks that reward common associations between words and events.

In an ablation described on the project page, keeping only the most frequent fraction of table entries — without retraining — improves perplexity with every doubling of the retained fraction and shows no sign of saturating. One caveat worth flagging: the headline comparison is parameter-matched, but the tables add 7.96 GiB of storage, so the model's total stored footprint is far larger than the baseline's.

Editing facts without training

After pretraining, an external edit layer adds new facts with no gradient step. Each fact becomes a plain-data record holding the subject tokens, a key derived from the hidden state where the answer should be produced, and the answer tokens; writing one takes a single forward pass, about 12 ms on a T4 GPU. A record fires only when its subject appears verbatim in the last 64 tokens and the hidden state matches the key with cosine similarity of at least 0.93. The stored answer token is then pushed 1.5 above the current top logit, one token at a time, until the answer ends. Because records are plain data, a person or an LLM can write, inspect or delete them, and a new edit for the same subject and relation replaces the old one.

Over 10,000 sequential WikiBigEdit edits, the edit layer answers 99.9% of the edited questions and 97.4% of their paraphrases, leaves 98.2% of unrelated answers unchanged, and changes perplexity by only 0.003%. Fine-tuning and LoRA, by comparison, recall at most 36.3% of the edits while pushing perplexity above 1,000.

Why it matters

The result challenges the assumption that everything a language model knows must be learned by gradient descent. Here, statistical and factual knowledge lives in inspectable, editable data, while the trained network handles the mechanics of prediction, and a knowledge update becomes a 12-millisecond record write rather than a retraining run. The edit-layer numbers, if they hold up, speak to a persistent pain point in model editing, where fine-tuning and LoRA tend to forget old facts and damage the model. As a demonstration of weight-space programming at language-model scale, it also suggests frontier LLMs can act as compilers of model knowledge, not just generators of text. The work is a single-author preprint that has not yet been peer-reviewed, and it is demonstrated at 103M trained parameters — a long way from frontier scale — but the non-saturating pruning curve is the kind of signal that invites scaling attempts.

  • #language-models
  • #machine-learning
  • #weight-space-programming
  • #knowledge-editing
  • #research

Related posts