Last updated: 2026-11-03

U
Undergraduate level
EPH
Ephemeral / Tooling โ€” Knowledge that evolves in months to a year โ€” check for updates

Weight-Space Programming: Reading and Writing Neural Network Weights Without Gradient Descent

A neural network's weights are usually treated as a destination, not a text: something gradient descent arrives at, not something anyone reads or writes directly. A report published on 2 November 2026 by four MIT CSAIL researchers โ€” Rikiya Takehi, Jayden Teoh, Alex Zhang, and Omar Khattab โ€” argues that frontier language models are starting to treat weights the second way. They call the pattern weight-space programming: a model reads a target network's numbers directly and can identify what the network does, diagnose why it fails, or write new weights by hand, sometimes without running the network at all [1]. It is a striking claim, and this page treats it the way any single, one-day-old, non-peer-reviewed report deserves: explained in full, checked against what it actually shows, and weighed against what it doesn't.

Where the Idea Comes From Applied / MethodologicalKnowledge with a 5โ€“10 year half-life โ€” stable practice

Treating weights as something other than a training target is not new; what would be new is a general-purpose model doing it by reasoning in natural language rather than by a mechanism built and trained for the purpose. Two existing lines of work mark the territory either side of that claim.

The first is fast weight programming. Schlag, Irie, and Schmidhuber showed that linear transformers are mathematically equivalent to an older idea from Schmidhuber's own earlier work: a "slow" network that writes the weights of a second, "fast" network at every step of a sequence, with attention recast as that fast-weight update rule [2]. One network writing another's weights, in other words, is already how a class of transformers operates internally โ€” it just happens inside the architecture, not as a chosen, inspectable action, and it was engineered and trained to do it, not reasoned through.

The second is Tracr, a tool that compiles a human-written symbolic program directly into transformer weights, built specifically to give interpretability researchers networks whose internals are known by construction rather than inferred after training [3]. Tracr shows that transformer weights can be a genuine compilation target: a program goes in, a trained-looking network comes out, and no training happens at all. What Tracr does deterministically, with a fixed compiler and a restricted programming language, is the nearest existing precedent for a model writing weights to a specification rather than learning them.

Weight-space programming, as the new report frames it, sits between these two: not a trained sub-mechanism like fast weight programming, and not a fixed compiler like Tracr, but a general LLM applying the same reasoning it would apply to source code to a network's raw numbers instead. The report's own framing leans on Karpathy's distinction between "Software 1.0," code a person writes by hand, and "Software 2.0," a network's weights, arrived at by training rather than writing [4]. Weight-space programming is, in that frame, an attempt to write Software 2.0 artefacts the way Software 1.0 ones have always been written: directly, by something that understands what it's producing.the weights are the program

What the Report Actually Tested Ephemeral / ToolingKnowledge that evolves in months to a year โ€” check for updates

The report describes eight experiments. The first three ask whether a model can read a network's weights and say something true about it, without running the network as a black box.weights are not a readable spec

  • Given only the weights of four identically-architected PPO-trained policies [5], one each for grid versions of Breakout, Pong, Pac-Man, and Freeway, the model named the correct game in all four cases.
  • Given the weights of three small DDPM diffusion models [6], each trained to generate a different shape, the model identified which shape each one produces. The report notes the model drew outlines rather than filled shapes, which it reads as evidence the model was inferring the target from weight geometry rather than quietly running a forward pass and copying the result โ€” a specific, checkable detail rather than a general assertion.
  • Given the middle layers only of three tiny (7.2M-parameter) character-level transformers, with the input and output layers removed, the model identified each one's training language (Python, romanised Japanese, or English) and located its induction heads โ€” the copying mechanism Elhage et al. identified as a building block of in-context learning [7] โ€” without running the network.

The next three experiments move from reading to writing. A PPO policy for a car-on-a-ramp task in the Kinetix physics environment [8] had converged to a local minimum; the model diagnosed the failure and edited 3.5% of its weights by hand, after which the car succeeded in all 1,024 test episodes. For three MinAtar games [9] โ€” Breakout, Seaquest, and Asterix โ€” the model wrote entire policy networks as text, with no training and no environment rollouts at all; its Breakout network scored 517.4, against 15.8 for a PPO baseline at 100M training steps and 25.3 at 500M. For 9ร—9 Go, a 1.5M-parameter network written the same way won over half its games against two smaller PPO-trained opponents with zero forward passes used during writing, and beat a PPO network trained on 20 million games once 50 forward passes were allowed.

The last two experiments test whether weight-space reading supports something closer to auditing and improvement. Given two fine-tuned copies of Gemma 3 270M, one sycophantic and one not, the model could not tell them apart from weights alone โ€” a real limit the report states plainly rather than glosses over. It could tell them apart, in all three tested pairs, once allowed to write its own test prompts and inspect attention patterns on them: a specific attention head attended to the user's suggested answer only in the sycophantic model. In the final experiment, the model traced repetitive looping behaviour in a small Qwen model to a single direction active in two MLP layers and removed it, editing 0.016% of the network's weights. On that model, MATH-500 accuracy rose from 7.9% to 48.1%, GSM8K from 13.8% to 67.1%, and IFEval from 21.0% to 62.3%. Run against Gemma 3 270M, which rarely loops in the first place, the same approach produced no meaningful change on MATH-500 โ€” which the report reads as evidence that this kind of editing removes an obstacle a model already has the capacity to work around, rather than adding a capability it lacks.

Note well. Every network in these experiments is small: a handful to a few hundred million parameters. None of this has been shown, by this report or anyone else yet, to work on a frontier-scale model, and the report does not claim it has.

What This Doesn't Yet Show Ephemeral / ToolingKnowledge that evolves in months to a year โ€” check for updates

Three things are worth holding onto past the headline, and connecting them to the report's own experiments is this page's own reading, not a claim the report makes in these terms.

First, the sycophancy experiment is the clearest evidence that "reading weights natively" is doing less work on its own than the framing suggests. The model failed at the task from raw weights alone and only succeeded once it could write its own probe inputs and inspect attention on them โ€” an interactive, tool-using loop, closer to a researcher running a targeted test than to a single act of reading. The experiments that worked purely from static weights (identifying a game, a shape, a training language) were classification tasks with a small set of plausible answers; the harder, more open-ended judgement โ€” is this specific model dishonest? โ€” needed an experiment designed and run against the network, not an inspection of its numbers.

Second, the most impressive single result โ€” editing 0.016% of a Qwen model's weights to roughly sextuple its MATH-500 score โ€” is a targeted, single-direction ablation of the kind mechanistic interpretability research already does: find a direction associated with a behaviour, remove it, measure the effect. That lineage, including the induction-head identification in experiment three, is genuinely well-precedented [7]. It's an impressive demonstration that a general-purpose model can find and perform that kind of edit itself, without a human interpretability researcher doing the probing โ€” but it is a more modest, better-grounded claim than "writing a network from scratch," and the two shouldn't be read as equally strong evidence for the same underlying idea.

Third, this is one report, four authors, one day old as this page is being written, with no independent replication yet. That isn't a reason to dismiss it โ€” the diagnostic detail (outlines rather than filled shapes; the explicit null result on Gemma; the admitted failure of pure weight-reading on sycophancy) reads like a group reporting what it actually found rather than overselling a headline. It is a reason to treat the central claim as reported, not settled, until someone other than the authors has tried to break it.preprint: no peer review yet

Don't do this! Don't cite "LLMs can write neural networks from scratch" as an established capability on the strength of this report alone โ€” cite the specific experiment, the specific scale, and the fact that it hasn't yet been independently replicated.

Why It Is Worth Tracking Anyway

Even bounded to small networks and a single unreplicated source, the underlying claim describes a genuinely different kind of activity from either of the two things it sits between. Adam and Muon adjust weights by calculated gradient, with no model of what the weights mean. A human interpretability researcher, or a tool like a sparse autoencoder, inspects a trained network's internals but doesn't autonomously rewrite them. What this report describes โ€” a general-purpose model reading a network's structure, forming a hypothesis about what's wrong, and editing the weights accordingly, in natural language reasoning rather than gradient computation โ€” would be a third category if it holds up and scales, with consequences for both auditing (checking what a model has learned without running it on a battery of test cases) and for how networks might eventually be improved at all. Whether it holds up at a scale that matters, and whether anyone outside the original four authors can reproduce it, are exactly the questions worth watching for over the next year โ€” the kind of claim the companion page on explaining language models would file as interesting but not yet load-bearing.

References

  1. R. Takehi, J. Teoh, A. Zhang, O. Khattab, "Sparks of Weight-Space Programming: LLMs can natively read & write neural network weights," 2 November 2026. https://rikiyat.github.io/blog/weight-space-programming/
  2. I. Schlag, K. Irie, J. Schmidhuber, "Linear Transformers Are Secretly Fast Weight Programmers," 2021. https://arxiv.org/abs/2102.11174
  3. D. Lindner, J. Kramรกr, S. Farquhar, M. Rahtz, T. McGrath, V. Mikulik, "Tracr: Compiled Transformers as a Laboratory for Interpretability," 2023. https://arxiv.org/abs/2301.05062
  4. A. Karpathy, "Software 2.0," Medium, November 2017. https://karpathy.medium.com/software-2-0-a64152b37c35
  5. J. Schulman, F. Wolski, P. Dhariwal, A. Radford, O. Klimov, "Proximal Policy Optimization Algorithms," 2017. https://arxiv.org/abs/1707.06347
  6. J. Ho, A. Jain, P. Abbeel, "Denoising Diffusion Probabilistic Models," NeurIPS 2020. https://arxiv.org/abs/2006.11239
  7. N. Elhage et al., "A Mathematical Framework for Transformer Circuits," Transformer Circuits Thread, 2021. https://transformer-circuits.pub/2021/framework/
  8. M. Matthews, M. Beukman, C. Lu, J. Foerster, "Kinetix: Investigating the Training of General Agents through Open-Ended Physics-Based Control Tasks," ICLR 2025. https://arxiv.org/abs/2410.23208
  9. K. Young, T. Tian, "MinAtar: An Atari-Inspired Testbed for Thorough and Reproducible Reinforcement Learning Experiments," 2019. https://arxiv.org/abs/1903.03176

Graduate Attributes

Modelled on this page

  • Critical Thinker: The central claim is treated as reported rather than settled until independent replication occurs.
  • Reflective: The distinction between fast weight programming and weight-space programming is drawn to clarify the scope of the new method.

University of Reading Graduate Attributes framework.