← notes Architectures

SenseNova-U1: one backbone that reads and draws pixels

A native multimodal model with no vision encoder and no VAE. Two weight streams share one attention: one reads clean 32×32 pixel patches, the other turns noisy patches into clean ones.

20 min read 7 interactive

One network, pixels in and pixels out

A unified model understands images and also generates them. Before SenseNova-U1 (arXiv 2605.12500, May 2026), most unified models had two visual front-ends. A vision encoder (CLIP or SigLIP) fed understanding. A VAE fed generation: it compresses the image to a small latent grid, a diffusion model works on that grid, and the VAE decoder turns the grid back into pixels. BAGEL is an example: one shared attention, but a VE on one side and a VAE on the other.

U1 removes both front-ends. It builds on NEO, an encoder-free vision-language model that reads raw pixels. NEO-unify (March 2026) added a generation branch, and U1 is the scaled-up version of that architecture. The same 32×32 pixel patch is the unit of reading and of writing. Understanding sees clean patches. Generation sees noisy patches and must output clean ones. No fixed representation (no CLIP feature, no VAE latent) sits between the pixels and the Transformer.

Most of the reading side comes from NEO without change. The patch embedding is Conv(k=16, s=16) → GELU → 2-D sinusoidal position encoding → Conv(k=2, s=2), so a 512×512 image gives 16×16 = 256 tokens. Text token nn gets the position (t,h,w)=(n,0,0)(t,h,w)=(n,0,0). All patches of one image share one tt and get their row and column as (h,w)(h,w), from 0. Text attention is causal, and the patches of one image see each other in both directions.

U1-8B-MoTU1-A3B-MoT
Layers, hidden size42, 409648, 2048
Q / KV heads32 / 832 / 4
Experts und / gen1 / 1 (dense)128 / 32, top-8
Parameters und / gen8.2B / 8.2B30.0B / 8.2B (about 3B active)

The 8B model starts from NEO-9B and keeps NEO’s pre-buffer (6 new shallow layers in front of the 36 LLM layers). The A3B model has no pre-buffer, and the paper does not state its initialisation; its shape matches Qwen3-30B-A3B.

Two weight streams, one attention

Mixture-of-Transformers gives each token type its own copy of every weight that does not mix tokens: RMSNorms, the Q/K/V projections, QK-norms, WOW_O and the FFN. The tokens of all types still meet in one attention. U1 has two types. Understanding tokens are text and clean image patches. Generation tokens are noisy patches that must be denoised. Unlike a mixture of experts, the routing is not learned: one boolean per token (image_gen_indicators in the code) picks the stream.

animation

One MoT layer, token by token

Press Play, or Step through the five phases. Click a token, or use Follow, to see which weights and which head it uses.

Follow a token
text token (und stream) noise patch N (gen stream) clean patch C (und stream) weights the followed token uses

Only the attention is shared. Each stream in U1-8B is a dense 8.2B network (16.4B stored), but a token passes through one of them, so the compute per token is that of one dense 8B model.

The cost of MoT is memory (two copies of the weights), not compute. The word embedding and LM head belong to understanding only. The generation stream has its own patch embedding (Patch Emb2), its own time and noise-scale embeddings, and the MLP pixel head.

The mask decides who reads whom

In text-to-image and interleaved training, a generated image appears twice in the packed sequence, as in Transfusion. A noisy copy NN goes through the generation stream and gets the loss. A clean copy CC goes through the understanding stream, so that later text can read the image. Both copies have the same position ids. NEO’s mask had two rules; U1 has five:

  1. Text is causal.
  2. A clean image block is bidirectional inside, and causal to everything before it.
  3. A noise block is bidirectional inside, and sees all clean context before it.
  4. Clean tokens never attend to noise tokens.
  5. A noise block does not see the clean copy of the same image (training only).

playground

Break a mask rule and see what fails

Click a row to choose a query token. Press a rule button to break that rule.

Break a rule
text query noise query (gen) clean query (und) allowed only because a rule is broken
K/V cached across steps
K/V recomputed each step
leaky cells

Rule 5 stops the denoiser from copying the answer. Rule 4 keeps every clean K/V independent of the noise, so the prompt is computed once and cached for all denoising steps.

Rule 4 has a large effect at inference. The prompt’s keys and values never depend on the noise, so the model runs the prompt once and keeps the result as a “prompt KV cache”. At each denoising step only the noise block runs again, with full attention to the cache and to itself. Editing uses the same mechanism: the source image is an ordinary clean block in the prefix. The target noise image has its own tt but the same (h,w)(h,w) grid, so a source patch and the target patch at the same location share their row and column.

Native-RoPE inside the original 128 channels

This is the one place where U1 changes NEO’s primitive. NEO’s Native-RoPE gives every token three position indices (t,h,w)(t,h,w). NEO kept the 128 original Q/K channels of each head for tt (base 10610^6), and added 64 channels for hh and 64 for ww (base 10410^4) through extra projections q_proj_hw and k_proj_hw. U1 re-splits the original 128 channels instead: channels 0–63 rotate by tt (base raised to 5×1065\times10^6), 64–95 by hh and 96–127 by ww (base 10410^4). Q, K and V now all have the standard 128-dimensional head.

The consequence is easy to see on one head. For two text tokens, h=w=0h=w=0 on both sides, so half of the channels do not rotate at all: for text the head becomes a partial RoPE head, with 64 positional and 64 position-free channels. For two patches of one image, Δt=0\Delta t=0, so the T channels give a plain content match and only H and W carry the 2-D offset.

playground

Which rotation pairs turn

Choose Query or Key, then click a token. Switch between U1 and NEO. Hover a dial for its frequency.

Click sets
Model
T pairs (sequence index t) H pairs (row h) W pairs (column w) dashed dial = not rotated (plain content match)
Q/K channels per head
K+V numbers / token / layer
extra QK params / layer

Each dial is one rotation pair, turned by ωk·Δ with the real frequencies. In U1, half of the pairs are idle between two text tokens: the head acts as a partial-RoPE head.

The walkthrough gives four reasons why this is acceptable for U1 although NEO avoided it. They are its interpretation; the paper gives only the recipe. U1 starts from a finished NEO model that already understands images, so a short re-adaptation is cheap. Partial RoPE is a known-good design (GPT-NeoX, DeepSeek-V2 MLA), and LLMs already use their slowest RoPE pairs almost as position-free channels. The larger T base keeps a very long wavelength for the slowest of the 32 T pairs. And the system gains are large. The K+V cache drops from 3072 to 2048 numbers per token per layer (−33%), the QK⊤QK^\top cost halves, and unmodified FlashAttention-3 and LightLLM kernels apply. The extra NEO-9B projections cost 21.0M parameters per layer, or 0.88B over 42 layers, and MoT would need them twice: the fusion saves about 1.76B parameters.

The conversion is called attention fusion (Stage 1-i). Everything except attention (WQ,WK,WV,WOW_Q, W_K, W_V, W_O and QK-norms) is frozen, and the model trains until it recovers its pre-fusion accuracy. Then the whole understanding branch continues.

Drawing raw pixels

Flow matching draws a straight line between a noise sample and a clean image, and teaches the network the velocity along that line. U1 uses the convention t=0t=0 is noise and t=1t=1 is clean:

zt=t x+(1−t) σR ϵ,v⋆=dztdt=x−σRϵ=x−zt1−t.z_t = t\,x + (1-t)\,\sigma_R\,\epsilon,\qquad v^\star=\frac{dz_t}{dt}=x-\sigma_R\epsilon=\frac{x-z_t}{1-t}.

Most diffusion transformers predict the noise or the velocity. U1 follows JiT (“Back to Basics”, Li and He): the network outputs the clean image x^θ\hat x_\theta, and the velocity follows from it:

vθ=x^θ−zt1−t,LGen=E ∥vθ−v⋆∥2=E ∥x^θ−x∥2(1−t)2.v_\theta=\frac{\hat x_\theta-z_t}{1-t},\qquad \mathcal L_{\text{Gen}}=\mathbb E\,\|v_\theta-v^\star\|^2=\mathbb E\,\frac{\|\hat x_\theta-x\|^2}{(1-t)^2}.

So the loss is an xx-loss with weight 1/(1−t)21/(1-t)^2. The same pixel error costs 56× more at t=0.9t=0.9 than at t=0.25t=0.25. One output token is a whole 32×32×3 = 3072-number patch. Clean image patches lie close to a low-dimensional manifold and noise does not. JiT shows that when the patch dimension is large compared with the network width, predicting the clean patch works while predicting noise or velocity fails. That is why no VAE is needed: the xx-target is already “easy” because it is a clean image.

Decoding is small. The generation stream ends with an MLP head, Linear(4096,4096)→GELU→Linear(4096,3072)\text{Linear}(4096,4096)\to\text{GELU}\to\text{Linear}(4096,3072), applied to each token, and the patches go back on the grid. Each patch is decoded without its neighbours, so small mismatches at patch borders can show as a 32-pixel grid. The paper meets this in RL and freezes the last three layers and the MLP head there.

Guidance with two conditions. A request can have a text condition and an image condition (the source image in editing). Following InstructPix2Pix, U1 guides the two separately:

s~=γ(s(cimg,ctxt)−s(cimg))+γimg(s(cimg)−s(∅))+s(∅).\tilde s=\gamma\big(s(c_{\text{img}},c_{\text{txt}})-s(c_{\text{img}})\big)+\gamma_{\text{img}}\big(s(c_{\text{img}})-s(\varnothing)\big)+s(\varnothing).

Training drops the text in 10% of samples and both conditions in another 10%. The best setting is γ=4\gamma=4, γimg=1\gamma_{\text{img}}=1. With γimg=1\gamma_{\text{img}}=1 the unconditional term cancels, s~=4 s(cimg,ctxt)−3 s(cimg)\tilde s=4\,s(c_{\text{img}},c_{\text{txt}})-3\,s(c_{\text{img}}), so a step needs two forward passes, not three. For text-to-image, cimgc_{\text{img}} is empty and this is ordinary CFG with scale 4.

playground

A toy pixel sampler

Press Play to run the steps. Change the prompt, the number of Euler steps, the guidance γ and the time shift. Try 1 step, and γ = 0.

Prompt
Time shift
t′ at shown step
network evaluations
final RMSE to nearest image
Toy: 8×8 grey images, and the “network” is the exact posterior mean over four training images, not a learned model. The update is the real one: x̂ → v = (x̂ − z)/max(1 − t, 0.02) → CFG → Euler. One step gives a blurry average; γ = 0 ignores the prompt. Dashed lines mark four 4×4 “patches”.

Bigger images need more noise

U1 generates images from 256² to 2048². With unit noise, the same tt is much easier at high resolution. Neighbouring pixels are correlated, so averaging them removes independent noise but keeps the signal, and the global layout of a large image is still visible at a noise level that hides a small image. U1 scales the noise with the number of generation tokens N=HW/322N=HW/32^2:

σR=σ0N/N0,σ0=1,  N0=64.\sigma_R=\sigma_0\sqrt{N/N_0},\qquad \sigma_0=1,\; N_0=64.

This gives σR=1\sigma_R=1 at 256², 2 at 512², 4 at 1024² and 8 at 2048². The factor is N\sqrt N because NN grows with the pixel count and the averaging gain is its square root (the walkthrough’s interpretation; the paper only says “approximately constant per-token noise energy”). The denoiser must know σR\sigma_R, so σˉ=σR/8\bar\sigma=\sigma_R/8 goes through its own sinusoidal embedder and is added to the timestep embedding: st=τt+NSEmb(σˉ)s_t=\tau_t+\text{NSEmb}(\bar\sigma). Training samples tt from a logit-normal (μ=−0.8\mu=-0.8, s=0.8s=0.8), and inference uses a timestep shift of 3.0.

calculator

Resolution → tokens → noise scale

Set the image size. Drag on the chart to pick a time t.

tokens N (rows × cols)
σ_R = √(N/64)
σ̄ = σ_R / 8 (to NSEmb)
pixel values out per pass
256² reference (σ = 1) this resolution with σ_R 512², 1024², 2048² (thin)
effective t′ at the marker
layout SNR, σ = 1
layout SNR, σ = σ_R

Layout SNR: a flat region of value 0.4, seen as a 256² thumbnail (average over blocks of pixels). Same formula as the worked example in the walkthrough.

A larger image is pushed towards the noise end: at t = 0.5 a 1024² image behaves like t′ = 0.2 under unit noise. With σR the layout SNR is the same at every resolution.

One request, end to end

The walkthrough follows one text-to-image request through U1-8B with the settings of the released inference script: 50 Euler steps, shift 3.0, CFG 4.0. The prompt is “A red pill on a white table” and the size is 512×384 (the script’s default is 2048²; the small size keeps the numbers readable).

animation

One text-to-image request

Press Play, or use Back and Next. The packet on the diagram carries the tensor shape of each step.

Only the lower loop repeats. The prefix runs once through the understanding stream; each of the 50 steps runs the generation stream twice (conditional and unconditional), so the request costs 100 network evaluations.

Six training stages

NEO had three understanding-only stages. U1 starts from a trained NEO and adds six. The loss is L=λ1LUnd+λ2LGen\mathcal L=\lambda_1\mathcal L_{\text{Und}}+\lambda_2\mathcal L_{\text{Gen}}: next-token cross-entropy plus the pixel vv-loss. All stages use AdamW with β=(0.9,0.95)\beta=(0.9,0.95), no weight decay and gradient clipping at 1.0.

diagram

What trains when

Click a stage column, or use Prev and Next.

understanding data text-to-image editing interleaved trains trains in phase (ii) frozen not listed as frozen

Understanding is made final first, then frozen while the generation side learns from scratch, and only then do both train together. Stage widths are training tokens; the column split is the data mix (approximate, because samples differ in length).

The walkthrough’s reading of the order: the understanding branch is the context “teacher” for generation, so it must be final first. A randomly behaving generation branch would send noisy gradients into it, so it stays frozen in Stage 2. In the unified stages λ1=0.1\lambda_1=0.1. A plausible reason (not stated in the paper) is that text cross-entropy is about 1–2 nats while the pixel loss is a mean over 3072 values per token and much smaller.

Stage 5 runs Flow-GRPO with three rewards. The OCR reward is a multiset IoU between the text that PaddleOCR reads and the target text, so a misspelt or duplicated word costs points. The style reward is a VLM judge score from 1 to 4, mapped to [0, 1]. The aesthetic reward is HPSv3, which alone “tends to favour darker backgrounds”, so the two reward groups alternate every epoch. RL starts with easy resolutions and opens the harder aspect ratios and areas over the first 200 epochs. Stage 6 distils with DMD2: a student, a frozen teacher at CFG 4 and a “fake” flow model. The result is 8 network evaluations instead of 100 (12.5×12.5\times fewer), with no second CFG pass at inference.

Serving. The two streams have different runtime profiles. Understanding is prefill plus autoregressive decoding and is memory-bound. Generation is 8 to 50 full passes over thousands of image tokens and is compute-bound. So LightLLM serves understanding and LightX2V serves generation, and the two exchange the prompt KV caches through pinned shared memory. A hybrid attention kernel extends the key range of a query tile only when the tile contains image rows, so text-only tiles keep the causal fast path.

Results, and what is missing

ModelGenEvalDPGCVTG-2KWISE (CoT)
U1-8B0.9187.780.9400.78
U1-A3B0.9188.140.8810.81
BAGEL-7B0.8285.070.3560.70
Qwen-Image-20B0.8788.320.8290.63 (no CoT)
GPT-Image-10.8485.150.8570.80 (no CoT)

Generation. U1 has the best open text rendering (CVTG-2K word accuracy 0.940), above the closed Seedream 4.5 (0.899) and GPT-Image-1. The source links this to near-lossless 32×32 patches plus the OCR reward. On DPG the closed Seedream 4.5 (88.63) and the open Qwen-Image (88.32) are best. WISE rises from 0.69 to 0.78 for U1-8B when the model first writes its reasoning and then draws.

Understanding. U1-8B (thinking mode) beats Qwen3-VL-8B on most reasoning benchmarks and all spatial ones (MindCube 62.01 vs 43.17, ViewSpatial 56.19 vs 47.25), and is close to Qwen3.5-9B. It is weaker on dense text images: OCRBench 82.10 and InfoVQA 82.46 against 89.20 and 90.76 for Qwen3.5-9B. A plausible cost of 32×32 patches with no high-resolution encoder.

Editing is the weakest area: ImgEdit 3.90 against 4.51 for Qwen-Image-Edit-2511. The paper blames editing data that is mostly open-source, and the lack of editing RL. Reasoning-heavy editing (RISE, 26.9 for 8B, 30.0 for A3B) and interleaved generation (OpenING 9.07 / 9.16) are strong among open models.

Ablations (mostly on NEO-unify-2B, not U1):

  • Reconstruction. NEO-unify-2B reaches PSNR 31.56 at 32× downsampling, equal to the FLUX.1-dev VAE at 8× (512²), with lower SSIM (0.85 against 0.93). The protocol for a model without an autoencoder is not explained, so treat this as indicative.
  • Conflict. Before and after unified mid-training, all four scores go up a little: multimodal understanding 72.1 → 73.2, text 77.7 → 77.8, DPG 84.7 → 86.5, GEdit 69.1 → 69.9. The claim is “minimal intrinsic conflict”, not strong synergy.
  • Data scaling. DPG saturates early, while WISE and RISE jump after about 1.4T tokens. If the axis counts from Stage 2, that is where unified training with understanding data starts. This is the best evidence in the paper that understanding helps generation.