Live data from Hacker News

Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

dnhkng.github.io

61–70 of 137 posts

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#61
The astounding thing about Goliath wasn’t that is was a huge leap in performance, it was that the damn thing functioned at all. To this day, I still don’t understand why this didn’t raise more eyebrows.

This wasn't something I really dug into in great detail but I remember my surprise back then at how all those merged models and those "expanded" models like Goliath still generated coherent output. IMO those were more community models made by small creators for entertainment rather than work, and only really of interest to the local LLM groups on Reddit, 4chan, and Discord. People might briefly discuss it on the board and say "that's cool" but papers aren't being written and it's less likely for academics or corpo researchers to notice it.

That being said I wonder if it's possible to combine the layers of completely different models like say a Llama and a Qwen and still get it to work.

Even with math probes, I hit unexpected problems. LLMs fail arithmetic in weird ways. They don’t get the answer wrong so much as get it almost right but forget to write the last digit, as if it got bored mid-number. Or they transpose two digits in the middle. Or they output the correct number with a trailing character that breaks the parser.

Would using grammar parsing help here by forcing the LLM to only output the expected tokens (i.e. numbers)? Or maybe on the scoring side you could look at the actual probabilities per token to see how far the correct digit is.

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#64
Man, that was such an enjoyable read. I loved your story on the wild server hunt, back when it was posted on r/localllama. I think one thing that is missing from the whole AI "discussion" is this train of thought of how we go from abstract mathetmatical formulation to intuitive understanding of the underlying functionality, and you showcased it beautifully in this article. Similarly to 3blue1brown who also did an amazing series on transformers. Kudos!

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#65

I've gotta say, this writeup gives me an itchy feeling. It really does feel like poking around a synthetic brain at this point. You could make the argument it's closer to the blocks of a CPU compared with a brain, and it's no different to copy-pasting some IP block for eg, HW JPEG decoding. But I feel like the difference here is we're 'discovering' these blocks / organs. They weren't designed, they were evolved.

At some point I will clean up and share the dynamic layer modification code for oobabooga Text-Generation-WebuUI.

You can enter the setting, and apply new re-layering architectures. Its very weird chatting with these brain-damaged models.

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#66
post #27
post #5

I think you may have cracked latent space reasoning. I've had a hunch that something like this would work, but couldn't figure out how the training would back propagate. But you've shown that you just need to duplicate existing layers. Have you tried a simple inline loop over the duplicated layers? Would be interesting to see performance. Also, would be interesting to compare with a MOE model. See if these layers are…

Yes, I've tried duplicating indvidual layers, but its not useful. I think this hasn't been tried before because it's totally unintuitive that feeding the output from later layers into previous ones would actually do anything. And in fact, it usually is detrimental. I guess it takes really bored hobbyists with too much compute to check this stuff. I have done some interesting work on applying multiple layer duplicatio…

Clarification. Duplicating multiple groups of layers in a "reasoning" loop

Normal:

  L1 -> L2 -> L3 -> L4 -> out
Unrolled (current framing):

  L1 -> [L2->L3] -> [L2->L3] -> L4 -> out
Looped (proposed):

       -- [L2->L3] x N --> L4 -> out
"reasoning loop"

Note: ascii rendering HN is not trivial

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#67
post #24

Earlier quoted context omitted.

Have a look at the boundaries in the heatmaps. They are of course open to interpretation, but it suggest to me that the models develop 'organs' for processing different types of data, and without duplicating the 'whole organ' you don't get the benefits. This is quite different to what you usually see, which is via layer ablation experiments. Thoughts?

Maybe you are observing artifacts of Qwen's training procedure. Perhaps they initialized further layers with the weights of previous ones as part of the training curriculum. But it's fun to imagine something more exotic.

There are similar patterns in the models from all the big labs. I think the transform layer stack starts out 'undifferentiated', analogous to stem cells. Pre-training pushes the model to develop structure and this technique helps discover the hidden structure.

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#68
post #18
post #6

This layer duplication strikes me as a bit of "poor man's" version of looped language models: https://ouro-llm.github.io/ Pretty cool though. LLM brain surgery.

Agrees, but one thing to note: I really think from the experiments that 'organs' (not sure what to term this), develop during massive pretraining. This also means maybe looping the entire models is actually not efficient. Maybe a better way is [linear input section -> loop 1 -> linear section -> loop 2 -> linear section -> ... -> loop n -> linear output]? This would give 'organs' space to develop.

it also reminds me a bit of this diffusion paper [1] which proposes having an encoding layer and a decoding layer but repeats the middle layers until a fixed point is reached. but really there is a whole field of "deep equilibrium models" that is similar. it wouldn't be surprising if large models develop similar circuits naturally when faced with enough data.

finding them on the other hand is not easy! as you've shown, i guess brute force is one way.. it would be nice to find a short cut but unfortunately as your diagrams show, the landscape isn't exactly smooth.

I would also hypothesize that different circuits likely exist for different "problems" and that these are messy and overlapping so the repeated layers that improve math for example may not line up with the repeated layers that improve poetry or whatever, meaning the basic layer repetition is too "simple" to be very general. that said you've obviously shown that there is some amount of generalizing at work, which is definitely interesting.

[1] https://arxiv.org/abs/2401.08741

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#69
post #63

[flagged]

Yes! I tried that pretty early on, the its basically never good. Its described in the the section: https://dnhkng.github.io/posts/rys/#the-beginning-of-llm-neu...

If you found two disjoint sections that seemed positive on their own, did you try looping both separately in the same model? Wondering how localized the structures are.

Re: Show HN: How I topped the HuggingFace open LLM leaderboard on two gaming GPUs

#70
post #12

Did you ever try multiple copies?

I did, but the combinatorics are mad. I have also tried training a meta-model that predicts the outputs of the combinations. I will make another post if the topic is popular; its pretty geeky though, even more than my usual blog posts...

My first idea would be to generate one of those heatmaps using RYS as the base model. And see if it gets meaningfully better. And then again!
Post reply on HN