Weight-space programming
How do you keep a cartoon’s cast on model across a whole episode?
Gitarja is a claymation series about a Javanese princess in 1328. The first episode has 16 scenes, eight characters, a trading ship and four places that come back. An open image model, MiniMax-H3, draws every still. A video model then animates each still.
The image model has no memory. Each shot is drawn from that shot’s text alone, so the princess’s face, skin and diadem change from shot to shot. Animators call a drawing that has drifted from the design “off model”. Our earlier cut had many such shots.
We fixed it with two parts. The first is a canon: one picture of each character, ship and place, which every shot is drawn from. The second is a checker that remembers the canon. It is a frozen Qwen3.5-9B with one small weight edit for each entity. The edits are written by a program, not trained, and they need no labelled frames. A new story needs only its own canon.
Step 1
One canon picture for each character, ship and place
A character’s canon is a full-body sheet on a plain background. We made each one from an approved still: the image model redraws the character alone, and we pick one of three by eye. A place’s canon is an empty plate: the place with nobody in it, in clear light.
Every scene’s text then points at the canon. “Gitarja” becomes “Gitarja, drawn exactly as the woman in Picture 2”, and the sheet goes in as Picture 2. The image model sees only the pictures of what is in that shot. We call it the goldfish.





Step 2
Sheet twins: the same shot twice, once with one thing wrong
A checker has to learn what “off model” looks like for each character. Labelled frames are slow to make and a new story has none. So we let the image model make the examples.
For each entity it draws pairs from the sheet. Both pictures of a pair have the same scene, the same seed and the same words, except one change in the second: a lighter skin, a cartoon face, a long narrow face, the head piece in another colour, other hair, a younger face, a garment in another colour. For a ship the changes are the hull, the sail, the masts, the prow, the painted eyes and the shape. The changes are the same list for every character, so a new story needs nothing written by hand.












Because the two pictures share everything else, their difference inside the checker is the drift alone. The scene, the light and the pose cancel out.
Step 3
One weight edit per entity, solved in closed form
The checker is asked: “Picture 1 is the reference. Is Picture 2 exactly the same woman?” The base model answers from the answer token. It sees the costume well and the face poorly. On Gitarja’s real frames its Yes-minus-No score ranked good frames above off-model ones only 63% of the time.
The drift is visible earlier. At layer 10, the picture’s own tokens separate the twins. The edit adds new neurons in two places and changes no original weight.
- Layer 10, every picture token. Eight neurons read the drift direction and write a flag into directions the model does not use. Their gates shut on text, on ordinary prose and on other characters’ pictures.
- Layer 31, the answer token. 256 neurons, gated to open only on a question about this entity, read what the model’s own attention has carried there and move the answer toward Yes or No.
The direction is a regularised difference of the twins’ mean picture tokens. The gates and readout are least-squares solves on forward passes. The strength of the flag is chosen by cross-validation that holds out one kind of drift at a time, so the edit has to catch a drift it never saw.
Gitarja
Bars start at 0.5, which is chance.
The edit was fitted from twins alone. The real frames were scored once, after the edit was fixed. With Gitarja’s edit on, the checker ranked the ship and Brahma as well as before.
Step 4
The elephant picks the take
A score that ranks frames well is enough to pick between takes. The goldfish draws 4 takes of each shot from the same text and canon. A small vision model finds each entity in each take. The checker, with every entity’s edit on, scores each crop against its sheet. We keep the take whose weakest entity is strongest.
On Gitarja’s real frames, picking at random from 4 gives an on-model frame 80% of the time. The base model’s pick is on model 86% of the time. The edited checker’s pick is on model 96% of the time.




Step 5
Rules the whole episode must keep
A character can be on model and the shot can still be wrong. In our earlier cut, the crowd behind the guard commander was the guard commander, again and again. The image model had copied his sheet onto every face.

So the episode now has written rules. Each rule names where it is checked and the question the checker answers. A new story writes its own list. The code does not change.
| Rule | Where it is checked | The checker’s question |
|---|---|---|
| On model | Every still and every sampled clip frame | The entity's edit: same as its sheet? |
| One face, one person | Every pair of people in a still, and the cast | Same individual, same face and body? |
| Keeps the prop | Every sampled frame of the clips that name it | Is he holding the tablet up? |
“One face, one person” is checked on every pair of people that the small vision model finds. Its pass mark is set on the canon: the same character drawn twice must pass, and two different characters must not. The rules for a still are written in TLA+, apart from the code that measures them. A take is valid only if it keeps all of them.
A clip must keep the rules in every frame. The checker reads every eighth frame. In one early clip, Brahma held his tablet up to the pole star and then let it go. The clip’s own text had told him to lower it. We fixed the text, and a rule now checks for it.

A failing clip is drawn again with new seeds, at most three times. If no attempt keeps every rule, the best one is kept and the shot is flagged for a person. The pipeline is written in TLA+ too. It states that a clip is never made from a still that broke a rule, and that no shot is drawn again forever. We checked both on a small model of the loop.
Distinct(s, t) ==
\A p, q \in People[s][t] :
p # q => Same[s][t][p][q] < SameBar
Valid(s, t) == OnModel(s, t) /\ Distinct(s, t)ClipOnlyFromValidStill ==
\A s \in Shots : phase[s] \in
{"clipcheck", "done", "flagged"} => stillOK[s]
CanonOnlyIfBothPassed ==
\A s \in canon : stillOK[s] /\ clipOK[s]
EveryShotEnds == \A s \in Shots :
<>(phase[s] \in {"done", "flagged", "escalated"})The test
Do viewers stay longer?
A checker’s score is our own measure. The real test is whether people watch. We wrote the test down before posting anything.
- Two cuts of the same episode: the new one, and the cut made before this method. They share the script, the voices, the music and the timing. Only the pictures differ.
- Each cut becomes the same six Shorts. That makes six pairs, posted one a day. The cut posted first alternates.
- We read “stayed to watch” for each Short once, seven days after it went up.
- The method wins only if the new cut wins all six pairs. Five of six is a lead, not proof.
We will post the result here, whichever way it goes.
For a new story
What a new story needs
- One approved still per character, ship and recurring place. The image model turns each into a sheet or a plate.
- Scene texts that name the entities. The program points each name at its canon picture.
- About 80 twins per entity, drawn by the same image model in about 25 minutes on one GPU.
- One weight edit per entity, about 12 minutes each on one GPU. No labelled frames.
- Four takes per shot, and the edited checker keeps one.
- A list of rules: who must look like their sheet, who must look unlike each other, and which props stay in hand.
Limits
What it does not do yet
The edit ranks frames well, but its Yes/No cut lands in the wrong place on real frames. That is why we use it to pick between takes and not to accept or reject a single take. The twins show only the drifts on our list. A drift outside the list, such as a wrong number of fingers, is not covered.
Two earlier attempts failed, and we report them. Matching a frame’s picture tokens against the sheet directly was at chance on characters it was not fitted on. Off-model pictures drawn from words alone, with no sheet, were easy to tell apart for reasons that had nothing to do with drift.
The episode
The final cut
Every still in the final cut was picked by the edited checker. The video model then animated each one.
- Image model: MiniMax-H3 (Q4 GGUF), six steps. Video: Wan 2.2 image-to-video. Checker: Qwen/Qwen3.5-9B in bf16. Crops: Qwen3-VL-4B grounding.
- Twins: 8 scenes × (2 faithful + 8 drifts) per entity for the first four entities, 4 scenes for the others; each pair also read under a matched random crop and exposure.
- Edit: layer 10, 8 neurons on picture tokens; layer 31, 256 gated neurons at the answer. Direction by shrinkage LDA on paired differences. Flag strength by leave-one-drift-out cross-validation.
- Rules: on-model bar at each entity’s 10th percentile over the episode’s takes; same-person bar by Youden’s J on canon pairs; prop bar by Youden’s J on prop twins. Clips: every 8th frame, at most three re-draws.
More head-to-head evals
| Measure | Physical Agent | Qwen3.5-4B |
|---|---|---|
| LIBERO frames answered with a tool call | 400 / 400 | 18 / 400 |
| Target movement per cm of object movement (median) | 0.02 cm | — |
| Measure | Particle-1 | DeepSeek V4.1 Flash | GLM-5.3-Flash |
|---|---|---|---|
| Rows right, blind | 91.2% | 89.4% | 90.8% |
| Median seconds per run | 375 | 315 | 144 |
| Measure | GLM-5.3 | DeepSeek V4.1 Flash |
|---|---|---|
| Right, of 75 | 75 | 71 |
| Seconds a question, median | 3.9 | 1.8 |
| Measure | First run | Best since |
|---|---|---|
| Landscape, seconds | 937 | 233 |
| Memo, seconds | 759 | 602 |
| Measure | Qwen3 235B | GLM-5.2 | Gemini 3.8 Flash | Claude Opus 5 |
|---|---|---|---|---|
| Seconds to the plan, median | 27 | 48 | 57 | 94 |
| Plans written, of three runs | 2 | 3 | 3 | 3 |
| Measure | SubQ | jev | Decider | Nimble |
|---|---|---|---|---|
| Found, mean of five columns at section length | 64% | 65% | 66% | 68% |
| Mechanism of action, found at section length | 57% | 51% | 61% | 54% |
| Measure | ask | Apollo | treg |
|---|---|---|---|
| Usable leads | 13 of 40 | 7 of 40 | 6 of 28 |
| Cost per usable lead | $0.037 | $0.27 | $0.23 |
| Measure | ask with jev | ask with Decider |
|---|---|---|
| Questions right, of 92 | 89 | 89 |
| Wrong answers | 1 | 2 |
| Measure | jev | ask |
|---|---|---|
| Our 370 clinical decisions, right | 94.6% | 93.0% |
| PubMedQA, right (best EdgeEvals scored: 62.2%) | 77.0% | 74.4% |
| Measure | ask | Claude Opus 5.5 |
|---|---|---|
| Questions right, of 95 | 59 | 63 |
| Small companies right, of 20 | 13 | 9 |
| Measure | realestate-us | Best of four assistants |
|---|---|---|
| Floor-plan rents right, of 26 | 26 | 23 |
| Amenities claimed the listing doesn't state | 12 | 129 |
| Measure | ask | jev |
|---|---|---|
| Right, of the questions answered | 98% | 79% |
| Wrong answers, of 92 | 2 | 19 |
| Measure | Trained localiser | Best of four frontier models |
|---|---|---|
| Mean overlap with the defect (IoU, 0 to 1) | 0.421 | 0.109 |