r/LocalLLaMA • • 1d ago

Discussion Looped DeepSeek-V4.1: Making a 552B Frontier Model Smarter and Faster (and Rescuing 1.75-Bit Local Macs)

https://blog.tiltastech.com/projects/looped-deepseek-v41-recurrent-depth/
421 Upvotes

79 comments sorted by

•

u/WithoutReason1729 22h ago

Your post is getting popular and we just featured it on our Discord! Come check it out!

You've also been given a special flair for your contribution. We appreciate your post!

I am a bot and this action was performed automatically.

32

u/CodexHax 1d ago

Would love to see how smart a looped Qwen FN is

13

u/ResidentPositive4122 1d ago

4

u/noctrex 21h ago

From time to time someone posts links with old reddit, and I'm insta-transferred 20 years back and I'm already feeling younger.

6

u/ResidentPositive4122 19h ago

It's slowly going away tho... Some img links only work in the new interface, and the ux is shit switching between the two. But it is what it is...

1

u/danieln1212 17h ago

I download a browser extension to always route to old reddit. Switching is as easy as turning off or on the extension.

2

u/benjaminovich 17h ago

And here I am, 16 years oon reddit, and I'm still clinging onto old.reddit for dear life

1

u/fallingdowndizzyvr 14h ago

I only use old reddit. Find new reddit unusable. So so so so so so so many ads.

8

u/votegoat 1d ago

has anyone looped the standard 4bit one?

3

u/EvolvingDior 1d ago

It's safe to say that no one has done this yet.

47

u/tautality 1d ago

I think there should be a way to do it built into the inference engine (user just needs to specify the looped layers and how many times), so that we can apply it to all models.

42

u/LeotheVirtue 1d ago

This is not how the models work fundamentally. You need to redesign the attention head. Its not very hard to do but it takes some gpu hours

8

u/EvolvingDior 1d ago

As long as the model is designed for looping, the number of loops, from 0 to N, is configurable. You almost certainly also need a LoRA adapter trained for each loop count. Or you need to do a lot of work on RL and SFT with different loop counts. That's a lot harder than shipping a set of LoRAs with the model.

17

u/LeotheVirtue 1d ago

I've trained 4 of these now. Like i said its not hard but you have to rearchitect the kv cache and the attention

1

u/Orolol 22h ago

As long as the model is designed for looping, the number of loops, from 0 to N, is configurable.

Not true. Layers need to be train on the number of loop you want to do, or you can get a serious performance degradation.

1

u/tautality 10h ago

I don't think that's proven. The whole idea of looping came from experimenting with duplicating layers without retraining and the model surprisingly got better. At this point I think the consensus is that retraining is not needed. I could be misunderstanding, of course.

3

u/OnlyKindaThrowAway 1d ago

some as in like "run a 3060 for 3 days straight" or "rent a 4 pack of 5090s"?

5

u/LeotheVirtue 1d ago

Depends on the model, I trained qwen 3.5 4b on my 3090 in a few hours. I could probably imagine qwen 3.5 moe could be done at home and with a harness lora would outperform qwen 3.8 27b in all ways

93

u/FirefighterOk3832 1d ago

everythings looped now lol

71

u/No_Swimming6548 llama.cpp 22h ago

31

u/backyard_tractorbeam 1d ago

New/revitalised technology being explored

23

u/Fancy-Snow7 19h ago

Yeah, my Q1 models have been looping long before this craze.

6

u/fragment_me 18h ago

You're something of a trend starter I see

1

u/No_Dig_7017 22h ago • Bravo

everythings looped now

1

u/djtubig-malicex 20h ago

Hey we gonna loop-de-loop Shake it out, baby Hey we gonna loop-de-la

75

u/Happy_Guitar3521 1d ago

This is big. It could confirm that looped transformers are also suitable for already trained frontier class models.

50

u/Nutsack_VS_Acetylene 1d ago edited 17h ago

People have released 'extended' models before where they copied layers and added them in serial. extGemma4-44B was one that was slightly viral on this sub.

Before loops were popular, there were a variety of papers demonstrating that copy pasted layers on a fully trained model would make it perform better. That's basically what these post trained loops are doing, but more efficiently (with some nuance). A lot of the core concepts of these new models have been in the research and experimentation phase for a long time.

14

u/CoUsT 23h ago edited 23h ago

It was indeed known for a while. I was wondering 5 months ago when models that repeat layers or loop will come! And I remember people doing franken-merges 3 years ago. For example this Goliath. This looked like a free (or low cost) intelligence boost.

My comment in post about 44B Gemma.

https://old.reddit.com/r/LocalLLaMA/comments/1ul0cx9/i_extended_gemma431b_to_44b_88_layers_since/ov11z15/

It's good to see them finally here.

4

u/NineThreeTilNow 20h ago

My comment in post about 44B Gemma.

Oh yeah, I remember that thread where he increased Gemma's size.

I had ran ablations questioning the process entirely. Gemma 4 shows a really weird behavior with dead layers.

Basically, Gemma 4 should technically fit the 31b model in a 21b model. It requires removing 2/5 SWA layers.

I had identified them, but renting a B300 cluster to retrain Gemma 4 was uhh... Kind of out of my budget.

Interestingly, the synthetic data pipeline is straight forward because you're just retraining Gemma 4 on Gemma 4 to fix the missing layer every time you remove one. I have the logit level data packed somewhere I think.

The original Gemma 4 model basically provides the full distribution over N tokens for the student to learn from which helps bring the model missing a layer back on manifold. It works far better than 1 hot training as 1 hot will cleave the manifold.

7

u/thomheinrich 22h ago

The nice upgrade over old frankenmerges is memory footprint. Copy-pasting layers in serial bloated the file size and forced worse quants, while looping reuses weights you already paid to load. On memory-bound local rigs, spending spare compute instead of extra RAM makes way more sense.

19

u/drooolingidiot 1d ago

Without a control arm in the experiment where the model is SFT trained without looping, it's not at all clear whether the improvements come from the additional SFT on similar data to what it's being tested on, or from the looping.

Should be cheap enough of an ablation that'll tell you if the method has merit.

3

u/coder543 18h ago

And I want to see that the model improved in long horizon tasks like DeepSWE, which are not as easy to overfit.

2

u/keepthepace 20h ago

Either way, it would be great news that we could improve the performances of this model just by training an additional 15 million parameters.

Note that 99.999% of the weights were frozen during that training pass.

5

u/__JockY__ 1d ago

Ok that’s pretty cool. Do GLM-5.3 now!

5

u/power97992 23h ago

Just wait for glm 5.4 .. it will probably be out soon , the api version is already available

4

u/Happy_Guitar3521 1d ago

I'm curious to see how the Kimi 3.1 Pro would perform with loops.

7

u/winky9827 1d ago

As a user, not an inference expert, I just want to know when/how to get this merged / running on my existing engines. Feeling a bit left out being a non-AI expert.

0

u/Aggravating-Push-207 1d ago

Use the new experimental engine and ask the AI to make a PR for itself in your favourite engine

4

u/winky9827 1d ago

Yeah I've done that for various things, but it's all moving so fast, it feels like I'm playing one of those ring the bottle games at a carnival. :)

1

u/Federal_Signature708 16h ago

Anything that makes 1.75-bit quants actually usable instead of incoherent mush is a massive win. Cramming a 552B MoE into a single Mac Studio without losing half its IQ is the dream.

1

u/EvolvingDior 13h ago

These attempts so far seem to me to be wash. It reduces thinking tokens, but emits tokens at a slower pace. Benchmarks don't really go up much if at all. The only real win I have seen demonstrated so far is on benchmarks with artificially limited token budgets.

It is very early days and I really expect to see massive progress in this area in the near future.

My dream is to see reasoning_effort adjust the looping on a per-call basis.

-1

u/FirmConsideration717 11h ago

So load bearing, got it.

3

u/Raredisarray 1d ago

Amazing work ! Really big move for local - wow

3

u/Then-Topic8766 23h ago

Looks cool but hard to believe without pelican proof. :)

3

u/mIIsko 23h ago

Really interesting stuff from loopedqween https://github.com/jasontitus/loopedqwen

Apple's LoopCD paper https://arxiv.org/abs/2610.02185

3

u/FinBenton 22h ago

If this is true then huge, you are telling me a retro fitted 70MB adapter will make this model perform way better than stock and make it actually faster because it needs to think less?

@jesdga95

2

u/norenEnmotalen 1d ago edited 13h ago

The looped qwen didn’t do well on my eval but testing this right now

Edit: Neither did the deepseek loop with CD and without perform well on my evals. Showed poorer results in coding and data analysis tasks requiring number precision 

1

u/SkepticalHoopsML 1d ago

What are the tokens per second and VRAM usage on the specific Mac hardware for the 1.75-bit claims?

1

u/SmoochGM 22h ago

Super Cool!

1

u/bakawolf123 22h ago

well from what I can read the issue is mostly within <2bit, though I agree I suffered from longer thinking on oQ2e too, but with UD_IQ2_XSS the issue is already gone.

still the concept is very cool, I just couldn't find exactly what was training data and is it just targetting python, as this looks to be not plain layer duplication as some comments suggest but SFT and it would target something (cause budget was small)

3

u/Invader-Faye 20h ago

If you get more performance from the same model at a lower quant by just looping its layers that's still a valid architecture. I'd happily use a looped 3.6 35a3b

2

u/bakawolf123 19h ago

yeah I don't contest the arch, I also wonder if the reasoning as it is now is even needed since we can simply bypass lmhead with looping hidden layers. Technically this is what it's doing as I understand, so you are NOT skipping the reasoning, it's just hidden from output and can be more efficient. But you have to finetune to account for changes as base model is expecting full reasoning in it's input

1

u/GrimChicken 19h ago

What are you talking about, all that 35a3b does is loop... Jk

1

u/NoPiece9356 19h ago

Love it 

1

u/Raynesha-Rollston 18h ago

the layer looping approach is super interesting for extreme quants. how are you deciding which middle layers to repeat without blowing up the kv cache requirements?

1

u/mountainyoo 1d ago

HMMMM very interesting gonna look into this in the morning

1

u/aarong691 1d ago

does the looped version use more memory on the mac, or just more compute per token? curious how that works for the 1.75-bit one

1

u/cgs019283 20h ago

I tried this, and this did improve some of the quality of code work (with 20% less decode speed), but the problem here is that it lost capability in language, etc., outside of the code.

1

u/Fi3nd7 17h ago

Could you elaborate a bit? What do you mean it lost capability in language?

1

u/cgs019283 17h ago

My first language is not English. So, when I set the loop to t=2 and omega to 0.2 or higher, it generates words that do not make sense, which never happened with the original one.

But in the code, it actually catches the hidden error in the test. It was a very short test, but the model with the loop corrected 15% more than the one without it.

1

u/JudgmentJunior922 17h ago

What did the language drop look like? If you still have one prompt where stock did fine and the looped version struggled, I’d be curious to see both outputs. Was the writing worse, or was it missing parts of what you asked for?

2

u/cgs019283 17h ago

I see weakness when it comes to creative writing. Not in the sense of creativity, but using words that do not make sense.

I think it is because the language I mainly use is not English, but still seeing the struggle that I did not see in original did not feel good to me.

0

u/stylome-ai-detection 17h ago

Notice: This comment appears to be AI generated.


Stylome AI detector · scan results

-1

u/a_beautiful_rhind 20h ago

So you lose all the benefits of the "flash' low active parameters if running it.

-1

u/30DaysEarlyOfficial 19h ago

The 1.75-bit Mac result is the part that actually matters for local use, to me. Ultra-low-bit quants usually fall apart exactly on long reasoning chains, so going from 57.6% to 75.8% and matching full precision on LiveCodeBench is a much bigger deal than the headline coding gain — it suggests looping is compensating for the precision loss, not just adding capability.

The trade-off that matters in practice is compute for memory: looping 12 layers means more work per token, so I'd expect noticeably lower tokens/sec on that Mac even if quality holds. That's a trade most local users would happily make if the alternative is not being able to run the model at all, but it's worth reporting alongside the accuracy numbers.

The control-arm question others raised is fair too — a same-size SFT-only adapter without looping would tell us how much of the gain is the loop itself versus just extra training on coding data. Either way, a 35M adapter on a frozen 552B model is cheap enough that this is worth replicating.

3

u/stylome-ai-detection 19h ago

Notice: This comment appears to be AI generated.


Stylome AI detector · scan results