Skip to content
Back to the collection

GLU Variants Improve Transformer

Noam Shazeer

2020 · arXiv

Read the paper
HN score
1
Mentions
5
Readers
5
Months
4
What’s in a score?

From the abstract

Gated Linear Units (arXiv:1612.08083) consist of the component-wise product of two linear projections, one of which is first passed through a sigmoid function. Variations on GLU are possible, using different nonlinear (or even linear) functions in place of sigmoid. We test these variants in the feed-forward sublayers of the Transformer (arXiv:1706.03762) sequence-to-sequence model, and find that some of them yield quality improvements over the typically-used ReLU or GELU activations.

Metadata: arXiv. Abstracts retain their original authors’ rights.

In the conversation

Original HN comments, with labels from simple text rules. A label describes the whole comment and may miss context or irony. Read the discussion to make up your own mind. About the labels

5 selected excerpts · 5 total mentions

conditionnumber
Recommendation · rule
It's not just you! Here's a lovely quote from an influential paper, "We offer no explanation as to why these architectures seem to work; we attribute their success, as all else, to divine benevolence." I think people went through a similar phase with steam engines. Lot's of practical engineering and heuristics to explain what works, before the emergence of a solid theoretical foundation (thermodynamics) to explain why. https://arxiv.org/pdf/2002.05202
HarHarVeryFunny
Neutral mention · rule
> The science behind these models are being worked on IN PUBLIC. The research is not secret. The implementations will all catch up. Only to a limited extent - the US companies stopped sharing research a long time ago, other than Anthropic's interpretability research (which also seems to have dried up?). Interestingly most of the sharing is now coming from the Chinese side, largely DeepSeek. Ziphu/Z.ai (GLM) is also partner in the Slime RL training framework. I wouldn't call much, if any, of this "science" - it's all empiricalism. Throw spaghetti at the wall and see what sticks. There's a famous quote from Noam Shazeer: "We offer no explanation as to why these…
Read the full comment
architectures seem to work; we attribute their success, as all else, to divine benevolence" https://arxiv.org/abs/2002.05202v1 Jakob Uszkoreit has also talked about the empiricalism that it took to make what would become the Transformer, and any complex neural network architecture work.
lossolo
Neutral mention · rule
> The field of ML research is moving so fast that people don’t even take time anymore to explain the design decisions behind their architectures Often, they don't fully understand why certain methods work, they simply experiment and observe the outcomes. This sentiment is echoed by one of the authors of the Transformer paper in another publication[1], where he states: "We offer no explanation as to why these architectures seem to work; we attribute their success, as with all else, to divine benevolence." [1] https://arxiv.org/pdf/2002.05202.pdf
GistNoesis
Neutral mention · rule
There is a bug : While in SwiGLU beta is a learnable parameter, in the reference paper the feed forward network set beta as a constant FFnSwiGLU = Swish1... https://arxiv.org/pdf/2002.05202.pdf (Eq 6.) In official llama implementation : the constant beta has been removed https://github.com/facebookresearch/llama/blob/main/llama/mo... In the blog log we observe various lines " feedforward.1.beta', 0.0 " which mean that during the training the beta has degenerated into 0 whereas it should be constant 1.

Keep following the thread.

More in Language models

More from the same topics.