comp-minds research
Research blog·

Cellular Weight-Space Programming: A Swarm of Cells Reads English Letters, and Nothing Was Trained

AuthorArash Moaddel PhD
The agent that wrote the weightsClaude Fable 5.2 (Anthropic), in Claude Code

A neural cellular automaton had been trained to read handwritten digits. We kept its graph, threw away its weights, and asked an AI agent to write new ones so that the same automaton reads the 26 capital letters. Nothing was trained and no gradient was computed: this is cellular weight-space programming. Of the 339,593 numbers in its tensors, 2,723 are non-zero, and every one of them belongs to a named line of a short program. The program has three parts: work out where you are, tell the whole letter what you see, then vote. The first working version took 69 minutes. It reads 96% of printed letters in the fonts it was designed on and 93% of unseen pen-drawn letters. And it reads any number of letters at once, drawn anywhere and at different sizes, with no change to a single weight: each letter's cells work it out among themselves. Each time it failed, the cause could be traced to specific registers.

A neural network is a program whose instructions are numbers, and in practice nobody writes those numbers. Gradient descent finds them from examples[1,2], and finding out what they compute is a separate research project that begins once training ends[3]. It was not always like this. The first model neurons were wired by hand to compute logic[4], and theory has long shown that suitable weights exist for any computation[5] and any reasonable function[6]. Knowing that weights exist does not tell anyone how to write a useful network for a real task, though.

Writing weights directly has come back. RASP and Tracr compile short programs into transformers, mainly to give interpretability research models whose workings are known in advance[7,8], and looped transformers have been shown to act as programmable computers[9]. Very recently, Elsayed and colleagues had Claude Opus 5.5 set every weight of a single looped transformer block that solves hard 30×30 mazes, Sudoku and a 20-disk Tower of Hanoi[22]. All of those are algorithmic tasks: each one has a known procedure, and the network only has to carry it out exactly.

We asked the same question for perception. Telling an R from a K in a wobbly pen stroke has no exact algorithm. Is it still possible to write the network instead of training it? And can a language-model agent do the writing from a short instruction? Our machine is a neural cellular automaton: a grid of cells that all apply the same small rule again and again[10,11], written as a small convolutional network[12,13]. In the well-known Self-classifying MNIST digits article[14], each ink pixel of a digit[15] is a cell that sees only its eight neighbours, and the cells have to agree on which digit they make up together. That cellular automata can act as recognisers through purely local rules is a classical result[16].

We took that trained digit automaton, kept every node of its graph, and asked Claude Fable 5.2 to write new weights so that it reads capital letters. We call this cellular weight-space programming: an AI agent writes the weights of a neural cellular automaton's rule directly, so that one small rule, repeated in every cell, carries out the whole program. It is the cellular counterpart of weight-space programming[23] and of its looped form[22], and the name is for how the network is made, not for a new algorithm. You can watch the result below. Every frame is the network itself, running from its weight file in your browser.

step 0
–
loading…
Font letters (click again for another of 24 fonts)
Hand-drawn examples
Choose ⌕ Inspect a cell and click a cell to read its 74 numbers while it runs.
Figure 1. The automaton at work. Each ink pixel is a cell. A cell shows the colour of the letter whose score is highest, black while no score is above 0.3. For their first 20 steps the cells stay quiet, then patches of different letters appear and merge into one. Pick a font letter or a hand-drawn example, or draw your own block capital. Draw two letters apart and each is read on its own (section 5). Inspect shows a cell's registers: its position, the 40 feature bits it has received and its 26 letter scores. Show paints one register over the whole letter,. The network runs in plain JavaScript from its 2,723 non-zero weights, with a little noise added at every step, and we checked it against the full tensors in NumPy.

Every cell sees only its 3 × 3 neighbourhood, and no cell can see the whole letter. Yet within a second or so they agree. They agree because the same information has reached all of them, not because any rule forces them to. Before any weight was set, the agent had decided what every number in a cell's state stands for. That is why the state can be read at any moment, which is what Inspect does.

Writing the weights also makes the network's failures readable. When a trained network misreads an input, finding out why can take a study of its own. When this automaton turned a hand-drawn R into a B, the cause was found in minutes, because the program says which registers to look at (section 6).

1.The machine, and the program written into it

The automaton works on a grid of cells. A cell with ink holds a list of numbers, its state. At every step, it reads the states in its 3 × 3 neighbourhood, passes them through a three-layer network (a 3 × 3 convolution, then two 1 × 1 layers, with ReLU in between) and adds the output to its own state. All cells share that network, and there is nothing else: no global memory, no attention, no cell that sees the whole picture.

We kept that graph exactly as published and changed only the sizes of its tensors. The author first allowed the output to grow from 10 digits to 26 letters. When the agent asked, the author allowed the hidden layers to grow too. The agent then built a larger model than the one it had been granted, and said so only afterwards (section 7).

Digit automaton[14]Letter automaton (this work)
How the weights were obtainedgradient descentwritten by a program
Numbers held by each cell2074
Units in each hidden layer80320 (313 and 184 used)
Weights22,499339,593
Non-zero weightsall2,723 (0.8%)
Share of cells updated per step0.51.0

The last row is the difference that matters. Figure 2 puts the two second layers side by side, each drawn from its own weight file. The trained one is dense, and what each of its weights does has to be worked out after training. The written one is almost empty, and every dot in it has a job that was decided before it was set.

Trained by gradient descent
The original digit automaton[14], second layer, 80 × 80. Every weight is non-zero, and what each one does has to be worked out after training.
22,499 weights, all learned. 20 numbers per cell, 10 digits
Written by an agent
The letter automaton, second layer, 320 × 320, with the same graph. Each dot is a non-zero weight, coloured by the part of the program it belongs to.
2,723 non-zero of 339,593 numbers. 74 numbers per cell, 26 letters
Figure 2. Same graph, two ways of filling it. Left: the trained digit automaton's 80 × 80 second-layer matrix, drawn from its weight file (orange positive, blue negative). Right: the same layer of the letter automaton, 320 × 320, also drawn from its weight file. A dot marks a non-zero weight; its colour shows which group of the cell's state that hidden unit writes to. The two networks solve different tasks, so this compares how the weights were obtained and how readable they are, not accuracy.

The agent treated the 74 numbers in a cell's state as registers and wrote a program over them. Figure 3 shows the layout. Hover over a register to see what it holds.

Figure 3. A cell's 74 numbers, by job. Channel 0 is the ink and never changes. Four registers measure the cell's distance to the four edges of the letter. Two count unbroken ink to the left and above. One is a clock. Forty are feature bits that every cell eventually shares, and 26 are letter scores. Every non-zero weight writes into one of these groups (the colours in Figure 2).
PART 1 · REGISTERS U D L R, LR UR, AGE

Where am I?

Each cell measures its distance to the top, bottom, left and right of the letter, counting one cell per step from the edges inward. Two more registers count runs of ink, which mark bars and stems. A clock keeps a young cell quiet.
PART 2 · 40 FEATURE BITS

What is here? Tell everyone.

A cell checks simple facts about itself, such as "I am on an edge facing down, in the left third of the letter". When it passes a feature's tests, it switches that bit on, and the bit spreads along the ink until every cell of the letter carries it.
PART 3 · 26 SCORES

Which letter?

Every cell computes 26 scores as weighted sums of the 40 bits and shows the letter with the highest score. Since all cells end up holding the same bits, they end up with the same answer.

Where am I?

A cell needs to know its position inside the letter before it can check anything useful. Register U holds the distance to the top of the letter. Its rule is the classical way of measuring distances with local operations[17]: take the largest of my neighbours' values, plus one for the neighbour above me. A cell with no ink above it sees zero there and gets the value 1. From there, the count moves down the ink one row per step. Registers D, L and R do the same in the other three directions. After about as many steps as the letter is tall, every cell knows where it sits in the letter's box. Pick distance from the top in Figure 1 to watch the count move down.

The math

The distance from the top is updated as the largest of four candidates:

U ← max( U[above] + 1, U[below] − 1.06, U[left] − 0.03, U[right] − 0.03 )

The sideways and backward candidates let the count travel around corners. Their small losses make out-of-date values fade instead of circulating for ever. The one non-trivial trick in the whole network is this maximum. One ReLU gives the larger of two numbers, max(a, b) = b + ReLU(a − b), and the two hidden layers together give the largest of four. With a constant K = 600 that keeps values positive:

layer 1: a = ReLU(c0 − c1) b = ReLU(c1 − s + K) a + b = max(c0, c1) − s + K c = ReLU(c2 − c3) d = ReLU(c3 − s + K) c + d = max(c2, c3) − s + K layer 2: e = ReLU((a+b) − (c+d)) f = ReLU(c + d) e + f = max(c0..c3) − s + K output: Δs = e + f − K = max(c0..c3) − s

The residual update then sets s to the maximum. Each register costs four first-layer units and two second-layer units. Everything else in the network is addition.

What is here? Tell everyone.

A single cell can check simple facts about itself: whether it lies in a given zone of the letter, whether it sits on an edge facing up, down, left or right, and whether it belongs to a long stroke. Oriented edges like these have been the basic vocabulary of vision since the first recordings from visual cortex[18]. A letter, however, is defined by facts about the whole shape, such as "there is a horizontal bar in the middle", and purely local tests cannot decide global properties of a figure[19]. The program bridges the gap with 40 feature bits. Any cell that passes a feature's tests switches that bit on, and the bit then spreads from cell to cell along the ink until every cell of the letter carries it. A bit that nothing supports fades away.

The math

Position tests without division. "Left of a fraction t of the width" means (L−1)/((L−1)+(R−1)) < t, which is the same as (1−t)(L−1) − t(R−1) < 0. That is linear in the registers, so one ReLU unit computes it, and the test does not depend on the letter's size. Twenty such units test x and y against 0.2, 0.35, 0.5, 0.65 and 0.8, four detect an edge from the ink of the three neighbours on one side, and four compare a run length with half or 80% of the letter's width or height. Each unit is zero when its test passes.

A feature bit f is a set of up to five tests. It is updated to

f ← 0.975 · max(f of the four neighbours) + ReLU( 100 − ½(p1 + p2) − 100 · Σ failed tests )

where p1 and p2 are the larger values of the vertical and of the horizontal neighbour pair. The first term spreads the bit along the ink and loses 2.5% per cell. The second term is the source: a cell that passes all the tests pushes the bit up, and the push shrinks as the neighbours fill up, so the value settles near 100. A bit counts as on above 8. That gives a reach of ln(100/8)/0.025 ≈ 100 cells, and a fading time of about 100 steps once the source is gone.

Which letter?

Once all the cells hold the same 40 bits, each cell computes 26 scores, one per letter, as a weighted sum of the bits. This is a naive-Bayes vote, a simple classifier that is known to work well even when its assumptions do not hold[20]. A clock register keeps a cell from announcing features or showing a letter during its first 20 steps, while its position is still unreliable. Section 6 explains why that clock is there.

The math

Each cell computes the "off-ness" of every bit, T = ReLU(1 − f/8), which is 1 when the bit is off and 0 when it is on. The score of letter ℓ is

o_ℓ = ReLU( b_ℓ + Σ_k W_ℓk · T_k ) W_ℓk = (ln(1 − p_ℓk) − ln p_ℓk) / 10 b_ℓ = (45 + Σ_k ln p_ℓk) / 10

Here pℓk is the smoothed share of design images of letter ℓ in which bit k is on, clipped to [0.03, 0.97]. That makes the score a shifted and scaled naive-Bayes log-likelihood. The constants 45 and 10 keep the winning score positive and of order one. In the first version, every score came out negative and the answer was random.

2.Inside one cell, unit by unit

Figure 3 shows the registers. Figure 4 opens up the network that updates them. It is the same weight file, drawn in 3D: the 3 × 3 neighbourhood gathered from the grid, the 320 first-layer units, the 320 second-layer units and the 73 outputs, with every non-zero weight drawn as a wire. Each unit is labelled with the part of the program it belongs to. Click a unit to see what it computes, which neighbours and channels it reads, and its value right now. Step through the phases of one update, or let it run.

The letter automaton's network, in 3DEvery non-zero weight, every unit, labelled by its job.
Runs on WebGL (three.js).
Figure 4. Inside one cell. The letter automaton's network, drawn from its weights: input grid, 3 × 3 gather, two hidden layers, outputs, gate and residual update. Drag to orbit, scroll to zoom and click any node for a plain-language explanation. Use the panel on the left to load letters, draw, and step through the ten phases of one update. Open it full screen ↗.

Two numbers stand out. Of the 320 units in each hidden layer, 313 and 184 are used, and of the 339,593 entries in the tensors only 0.8% are non-zero. A written program spends one register per idea and leaves everything else empty. That makes it larger than a trained network for the same job: 74 numbers per cell against the digit model's 20, although for 26 classes rather than 10. It also makes it far easier to read.

3.What was written, and what was counted

No gradient was computed and no loss function was minimised. The structure of the program, and the form of every weight, was written by construction. Two things were nevertheless taken from images, and the article should not be quoted as "no data used":

The automaton is therefore hand-structured and data-calibrated. That mix may well be the useful one. Structure that a person or a language model can state is written down, and the few numbers nobody can state from first principles are counted. For mazes and Sudoku[22] nothing needs counting, because the algorithm is exact. For letters, the line between written and counted runs right through the readout.

How many images were used, round by round
RoundImages used for choosing features and counting votes
First version (10 Nov)546 font images: 26 letters × 21 design fonts
Start-up repairthe same 40 features; votes recounted on the same 546 images
Re-fit on pen-drawn letters (3 rounds)546 font images + 3,900 generated pen-drawn letters (150 per letter, 17–38 cells tall) = 4,446
Longer reach of a bitno recount; one constant changed
Re-fit on large letters546 font images + 3,900 new pen-drawn letters up to 50 cells tall = 4,446
In total8,346 different images: 546 printed and 7,800 generated. None of the author's drawings was ever counted.

4.How well it reads

We ran the automaton on the 26 letters in 24 fonts. After 300 steps it reads 525 of 546 letters (96.2%) in the 21 design fonts and 62 of 78 (79.5%) in three fonts held out from both the feature search and the counting. Within a letter, 99.6% of cells agree on average. The held-out result is uneven: Optima, a regular printed face, is read with one error in 26, while the two script-like faces, Noteworthy and Bradley Hand, reach 73% and 69%. The most common errors are E read as B (five fonts) and O read as D (four fonts). Each of these pairs differs by one small feature.

Share of letters read correctly, step by step
Accuracy per font after 300 steps
Figure 5. Accuracy on printed letters. Left: the share of letters whose majority of cells gives the right answer, for the 21 design fonts and the three held-out fonts. In the shaded first 20 steps the cells are quiet. After 50 steps, 80% of the design-font letters are already right, and the last ones settle by about step 250. Right: the share of 26 letters read correctly in each font, with held-out fonts in orange. Hover for values.

Letters with long winding strokes, such as G and W, take longest. Position information has to travel along the ink before the right features can be announced, and the announcement has to travel back.

5.Many letters at once, anywhere, at their own sizes

Nothing in the program says how many letters there are, where they are or how big they are. Draw a V, an A, a W and a Q in four corners of one sheet, at four different sizes, and every letter is read by its own cells. No weight was changed for this and nothing was added: Figure 6 runs the network of Figure 1 on a larger grid.

Three things in the program make this work, and none of them was written for it.

step 0
Letters on the sheet
Who reads what. The labels and this list are drawn by the page from the cells' own answers, one piece of ink at a time. The cells are never told where one letter ends and the next begins.
Figure 6. Many letters on one sheet. The same 2,723 non-zero weights as Figure 1, on a 96 × 96 grid. V · A · W · Q loads four pen-drawn letters, 18 to 39 cells tall, in four corners. Shuffle puts up to seven printed letters from the article's fonts at random places, at 1 to 1.5 times their size. Or draw your own capitals anywhere, with a gap between them. Each letter goes through its own 20-step quiet period, settles at its own pace and never exchanges a number with any other. Hover over a letter to read its count.

We checked this in two ways. First, with the noise switched off, we ran 25 sheets twice: once with all their letters together, and once with each letter alone in the same place. After 200 steps, every one of the 74 numbers in every cell was the same in both runs, to the last bit. Reading several letters is therefore not an approximation of reading one: for each letter it is exactly the same computation. Second, with the page's noise on, we read 120 letters on 24 random sheets. On sheets of four pen-drawn V, A, W and Q, 12 to 34 cells tall, 47 of 48 were read correctly. On sheets of six printed letters of all 26 kinds, 69 of 72 were, the same 96% as one at a time (section 4).

The one condition is that letters must not touch. Touching letters are one piece of ink, and their cells read it as one shape. An earlier version of this article said that the automaton handles one letter at a time. That limit was in the page, which took one majority vote over all the ink on the grid, not in the network. Figure 1 now reads each piece of ink separately too.

6.Three faults, and the registers they came from

The most useful part of this project was not the first version but its faults. Each one was found by the author, not by the agent, and each one could be traced to specific lines of the program.

Everything is B for the first two seconds

The first version had no quiet period. During its first few steps a cell does not yet know where it is, so almost every position test passed by accident, all 40 bits switched on, and the letter whose profile has the most bits on, B, won everywhere. Every letter showed as B for about 120 steps and then flipped to the right answer. The agent had seen this, explained it and called it a finding. The author's reply the next morning was blunter: "most things go to become B ! … i think there is a fundamental issue." The agent's first repair kept the cells blank until they agreed. The author rejected that as well, because the point is to watch the cells talk to each other. The final repair is the 20-step clock, which also keeps the evolution visible. Accuracy on printed letters was the same before and after.

Pen strokes are not fonts

Drawing letters by hand exposed the weakest point of the first version. The author drew 13 letters and reported that V and W, O and Q, and P, R and F were often confused. We rebuilt the drawings from the screenshots and replayed them, and six failed. The dynamics were not at fault. The features and votes had been counted on 20-pixel font letters, and the drawings are larger, thinner and more slanted. Each failing drawing disagreed with its own letter's profile on 5 to 13 of the 40 bits.

The repair left the program and the network's size untouched and replaced only the two counted ingredients. The agent wrote a generator that draws each letter as a few strokes with random proportions, slant, size and wobble, rasterised with the same brush as the drawing canvas. It then chose the features and counted the votes again on fonts plus 3,900 generated letters. It also changed the search to reward a wide gap to the runner-up letter instead of the number of correct images. The first re-fit, which still counted correct images, fixed the W's and broke the P.

Accuracy before and after the re-fit
Gap to the nearest rival, the author's 13 drawings
Figure 7. Letters drawn with a pen. Left: accuracy on four test sets with votes counted on fonts only (grey) and with the final weights (teal). Unseen generated pen letters went from 58.7% to 93.3%, and the author's 13 drawings from 7 to 13 correct. Printed letters paid a little. Right: for each drawing, the score of the true letter minus that of its best rival, in log-likelihood units. Below zero means the drawing was misread. With font-only votes, six drawings were at or below zero; with the final weights all 13 are positive, though the two O's and the Q stay close to the line.

Two cautions apply. The 13 drawings are not an independent test, because after the first re-fit two of them still failed and the generator's range of proportions was widened in response. And the generated letters are the agent's idea of handwriting, not handwriting collected from people. Most of the gain came from counting the votes on pen-drawn letters. The number of bits that separate P from F, or V from W, barely changed.

Generated pen-drawn letters, the author's 13 drawings with the letters they settle on, and accuracy on four test sets.
Pen-drawn letters in detail. a, one generated pen-drawn letter per class. b, the author's 13 drawings, rebuilt from screenshots, with the letter their cells settle on before and after. c, accuracy on four test sets.

Very large letters never agree

A last fault appeared when the author drew letters across almost the whole canvas. Each stroke took a different colour, and the cells never agreed. The cause is how far a bit can travel. A bit leaves its source at about 100, loses a fixed share at every cell and counts as on above 8. While fixing the start-up fault, the agent had made bits fade faster, which cut that distance from 100 cells to 63. It did not test a large letter afterwards. An N drawn 48 cells tall has about 160 cells of stroke, so a feature found at one end never reached the other.

In this design, reach and forgetting are one quantity. A bit that can travel n cells also needs about n steps to fade when it is wrong, because the same loss per cell sets both. Try it below.

Share a bit keeps per cell ρ = 0.975
100cells a bit reaches
100steps to forget a wrong bit
96%agreement on letters 46–50 cells tall
150median steps to settle, ordinary pen letters
Figure 8. One constant, two behaviours. A bit starts at 100 at the left end of a 160-cell stroke (the length of a large N) and keeps a share ρ at each cell. It counts as on while it is above 8 (dashed line). A longer reach lets the whole stroke agree, but a wrong bit takes just as long to fade. The last two boxes were measured by running the network at the four values that were compared (0.961, 0.975, 0.981, 0.986). Between those values the boxes show the nearest measured one, marked *. Our choice, and the network in Figure 1, is ρ = 0.975, which was also the first version's value.

Agreement did not make large letters right. With the longer reach, a large A with a rounded top was read as R by every cell, because the design set stopped at 38 cells of height and only had sharp-topped A's. The generator was extended to 50 cells and to round and flat tops, the features and votes were counted again, and all seven large drawings were then read correctly. You can load them in Figure 1. The price: printed E is now read as B in five of the 24 fonts. Giving fonts more weight in the counting removed that error but lowered unseen pen letters to 92.3%. Asked to choose, the author replied "no favor the hand drawn", and every number in this article is for that choice.

An N drawn 48 cells tall at two reaches, agreement against reach, settling time against reach, and seven large drawings.
Very large letters in detail. a, b, an N drawn 48 cells tall with a reach of 63 and of 100 cells. c, d, agreement on large letters and settling time on ordinary ones, for four reaches. e, the author's seven large drawings under three versions of the automaton.

7.How the agent did

Claude Fable 5.2 worked as a coding agent in Claude Code, with a shell, a file editor and a browser. It took 69 minutes from the first instruction to a working demonstration, including two pauses while it waited for the author's answers. The first instruction, verbatim:

"read the model.json file in webdemo , then directly chnag ethe weights (weight spac programming) , to make it capable of detecting capital letters instead of mnist , make a new wbdemo folder for letters do it directly by writitng the wightts of the nn"

It decoded the stored graph correctly, proposed the program, wrote all the code, and tested the result both in its own simulator and in the browser. It also made mistakes, and those deserve as much attention as the network's. Figure 9 scores every step.

worked first timeasked first (good judgement)needed tuning or fixed quicklyfailed, fixed late, found by the authorrule broken or claim overstated
Figure 9. The agent's scorecard, step by step. Hover over a square to read what happened and how it was caught. Squares 15 to 19 are things the agent said to the author, which matter as much as what it built.

The weaknesses fall into a pattern. The agent exceeded an agreed limit without asking: it was granted about 36 numbers per cell and 256 hidden units, built 73 and 320 (the clock later made it 74), and disclosed the overrun only in its final report. It overstated a claim: it described "every weight written by hand" until the author asked "are u cheating ?", and then separated what was written from what was counted. Its own tests used fonts and four simple drawings, so the start-up fault, the weakness on pen-drawn letters and the short reach were all left for the author to find. Two of its statements turned out to be wrong only when every number was recomputed from one script.

The strengths are just as real. It found a working design without help. It noticed by itself that the original size left room for only about ten feature bits, and asked rather than guessed. It reported held-out fonts separately without being asked. When it could not run a test, it said so. And it reproduced every fault the author reported, from a screenshot, before changing a weight. What made the difference was short, sceptical questions from a person, that person's own drawings, and recomputing everything before writing it down.

From one project to five agent skills

We distilled what went right and wrong into five agent skills, so that the next agent starts from the lessons instead of repeating the mistakes. They apply to any architecture, not just cellular automata.

SkillWhat it gives the agent
weight-space-programmingThe entry point. It maps network parts to program parts (a hidden unit is an instruction, a layer is a step, state channels are registers, recurrence is a clock). It also gives a workflow with gates where the agent must stop and ask, the hard rules below, and an honesty block to end every report with.
wsp-model-ioOpening any weight file (safetensors, PyTorch, ONNX, TF.js, npz), reading the forward pass, a budget table, resizing and exporting back.
wsp-circuitsThe instruction set: exact ReLU pieces such as max, min, step, logic, gates and arg-max, how to compose them, and attention heads used as lookups.
wsp-calibrateCounting instead of training: realistic design data, selection by margin rather than by count, and disclosure of everything fitted.
wsp-verifyThe test ladder: each piece alone, the whole network at runtime settings, margins, precision, extremes, behaviour over time, and the real runtime.

Every hard rule in them is a failure that actually happened in this project. Never exceed the agreed size without asking first. Only numbers from running the network are results. Test with the inputs the user will really produce. Behaviour over time is part of the spec. Constants couple, as with reach and forgetting. Trade-offs belong to the user, as with fonts against pen strokes.

8.Algorithms and perception

Read alongside the looped transformers of Elsayed et al.[22], this work suggests where writing weights is easy and where it is hard. Both projects use the same lever: a small block that repeats, so that one written step can run for as long as the input needs. In their maze solver, a wave of distances spreads one cell per loop. In this automaton, positions and feature bits spread one cell per step. In both cases the meaning of every number is fixed before any weight is set, so the network can be read at any moment.

The difference is the task. A maze has an exact procedure, so a written transformer can be correct by construction and stay correct at sizes it was never checked on. A letter has no exact procedure. Here the written structure carries the reasoning (where am I, what is here, tell everyone), but the last step, deciding which combination of 40 facts is an R, had to be counted from examples. That is where every accuracy problem in this project lived. The coverage of the counted data set how well it read pen strokes, and the dynamics of the written rule set how big a letter it could handle. Writing the weights did not remove the need for data. It confined that need to 1,066 numbers whose meaning is known.

The same method, cellular weight-space programming, sits on both sides of that line in our other work. On the algorithmic side, it gives a maze solver that finds every shortest path with 115 non-zero numbers and is exact by construction[24]. On the side of programs that run for as long as you use them, it gives a playable first person shooter, game rules and 3D picture alike, in 3,207[25]. This article is the case in between, where the structure is written and only the last step is counted from data.

Conclusion

Weights can be an authored, readable medium for perception, not only for algorithms.A trained digit automaton became a letter reader without any training, by writing a short program into its weights. Every non-zero weight belongs to a named step.
Written structure, counted readout.The form of the computation was written, and 40 choices and 1,066 numbers were counted from images. For a task with no exact algorithm, that line is where the data has to go.
One letter or many, the same program.Nothing in the weights assumes one letter. Letters drawn anywhere on a sheet, at different sizes, are read at once, each by its own cells, and each goes through exactly the computation it would go through alone.
Faults become debuggable.Start-up B's, pen-stroke confusions and large letters that never agree were each traced to specific registers and constants within minutes, and each fix was a change to an identifiable line.
An agent can do the writing, if a person keeps asking.Claude Fable 5.2 designed, wrote and tested the network in 69 minutes. It also exceeded its brief and overstated a claim. Short sceptical questions and the author's own drawings caught what its own tests did not.

Limits

The printed test set is 624 rendered images, of which only 78 come from unseen fonts. The pen-drawn test set is made by the same generator as the pen-drawn design set, so it measures variation within the agent's model of handwriting, not real handwriting from many people. The only real drawings are 20 letters by one person, and they influenced the generator. About one unseen generated letter in fifteen is still misread. Letters must not touch: touching letters are one piece of ink and are read as one shape. And no network was trained on the letter task, so nothing here measures how written weights compare with learned ones in accuracy, robustness or speed.

What's next

With 40 bits the letters are separated by narrow gaps. An offline estimate says 72 bits would read about 97% of unseen pen-drawn letters, at the price of a network about 1.6 times wider. The agent reported that option and, this time, did not build it without asking. Beyond that, we want handwriting from many people, touching letters and joined-up words, and a fair comparison with the same graph trained by gradient descent, including training that starts from the written weights.

Citation

If you use this work, please cite it as follows.

@misc{moaddel2026letters,
  title  = {{Cellular Weight-Space Programming: A Swarm of Cells Reads English Letters, and Nothing Was Trained}},
  author = {Moaddel, Arash},
  year   = {2026},
  month  = nov,
  note   = {Article, ibiLAB, Copenhagen}
}

References

  1. Rumelhart, D. E., Hinton, G. E. & Williams, R. J. Learning representations by back-propagating errors. Nature 323, 533–536 (1986). doi:10.1038/323533a0
  2. LeCun, Y., Bengio, Y. & Hinton, G. Deep learning. Nature 521, 436–444 (2015). doi:10.1038/nature14539
  3. Olah, C. et al. Zoom in: an introduction to circuits. Distill 5, e00024.001 (2020). doi:10.23915/distill.00024.001
  4. McCulloch, W. S. & Pitts, W. A logical calculus of the ideas immanent in nervous activity. Bull. Math. Biophys. 5, 115–133 (1943). doi:10.1007/BF02478259
  5. Siegelmann, H. T. & Sontag, E. D. On the computational power of neural nets. J. Comput. Syst. Sci. 50, 132–150 (1995). doi:10.1006/jcss.1995.1013
  6. Hornik, K., Stinchcombe, M. & White, H. Multilayer feedforward networks are universal approximators. Neural Netw. 2, 359–366 (1989). doi:10.1016/0893-6080(89)90020-8
  7. Weiss, G., Goldberg, Y. & Yahav, E. Thinking like transformers. Preprint at arXiv:2106.06981 (2021).
  8. Lindner, D. et al. Tracr: compiled transformers as a laboratory for interpretability. Preprint at arXiv:2301.05062 (2023).
  9. Giannou, A. et al. Looped transformers as programmable computers. Preprint at arXiv:2301.13196 (2023).
  10. Wolfram, S. Statistical mechanics of cellular automata. Rev. Mod. Phys. 55, 601–644 (1983). doi:10.1103/RevModPhys.55.601
  11. Gardner, M. Mathematical games. Sci. Am. 223(4), 120–123 (1970). doi:10.1038/scientificamerican1070-120
  12. Gilpin, W. Cellular automata as convolutional neural networks. Phys. Rev. E 100, 032402 (2019). doi:10.1103/PhysRevE.100.032402
  13. Mordvintsev, A., Randazzo, E., Niklasson, E. & Levin, M. Growing neural cellular automata. Distill 5, e23 (2020). doi:10.23915/distill.00023
  14. Randazzo, E., Mordvintsev, A., Niklasson, E., Levin, M. & Greydanus, S. Self-classifying MNIST digits. Distill 5, e00027.002 (2020). doi:10.23915/distill.00027.002
  15. LeCun, Y., Bottou, L., Bengio, Y. & Haffner, P. Gradient-based learning applied to document recognition. Proc. IEEE 86, 2278–2324 (1998). doi:10.1109/5.726791
  16. Smith, A. R. Real-time language recognition by one-dimensional cellular automata. J. Comput. Syst. Sci. 6, 233–253 (1972). doi:10.1016/S0022-0000(72)80004-7
  17. Rosenfeld, A. & Pfaltz, J. L. Sequential operations in digital picture processing. J. ACM 13, 471–494 (1966). doi:10.1145/321356.321357
  18. Hubel, D. H. & Wiesel, T. N. Receptive fields, binocular interaction and functional architecture in the cat's visual cortex. J. Physiol. 160, 106–154 (1962). doi:10.1113/jphysiol.1962.sp006837
  19. Minsky, M. & Papert, S. A. Perceptrons: An Introduction to Computational Geometry (MIT Press, 2017; first published 1969). doi:10.7551/mitpress/11301.001.0001
  20. Domingos, P. & Pazzani, M. On the optimality of the simple Bayesian classifier under zero-one loss. Mach. Learn. 29, 103–130 (1997). doi:10.1023/A:1007413511361
  21. Smilkov, D. et al. TensorFlow.js: machine learning for the web and beyond. Preprint at arXiv:1901.05350 (2019).
  22. Elsayed, A., Heakl, A., Shaker, A., Khan, F., Khan, S. & Claude Opus 5.5. Looped weight-space programming: LLM-written transformers for long algorithmic reasoning. Blog post, MBZUAI, 23 November 2026. mbzuai-oryx.github.io/LoopedWSP
  23. Takehi, R., Teoh, J., Zhang, A. & Khattab, O. Sparks of weight-space programming: LLMs can natively read & write neural network weights. Blog post, MIT CSAIL, 2 November 2026. rikiyat.github.io/blog/weight-space-programming
  24. Moaddel, A. Cellular weight-space programming: 115 numbers find every shortest path in any maze. Article, ibiLAB, Copenhagen, 24 November 2026.
  25. Moaddel, A. Cellular weight-space programming: 3,207 numbers run a 3D first person shooter. Article, ibiLAB, Copenhagen, 24 November 2026.