Outlier-Efficient Hopfield Layers for Large Transformer-Based Models
Jerry Yao-Chieh Hu, Pei-Hsuan Chang, Haozheng Luo, Hong-Yu Chen, Weijian Li, Wei-Po Wang, Han Liu
Abstract
We introduce an Outlier-Efficient Modern Hopfield Model (termed ) and use it to address the outlier inefficiency problem of training gigantic transformer-based models. Our main contribution is a novel associative memory model facilitating outlier-efficient associative memory retrievals. Interestingly, this memory model manifests a model-based interpretation of an outlier-efficient attention mechanism (): it is an approximation of the memory retrieval process of . Methodologically, this allows us to introduce novel outlier-efficient Hopfield layers as powerful alternatives to traditional attention mechanisms, with superior post-quantization performance. Theoretically, the Outlier-Efficient Modern Hopfield Model retains and improves the desirable properties of standard modern Hopfield models, including fixed point convergence and exponential storage capacity. Empirically, we demonstrate the efficacy of the proposed model across large-scale transformer-based and Hopfield-based models (including BERT, OPT, ViT, and STanHop-Net), benchmarking against state-of-the-art methods like and . Notably, achieves an average reduction of 22+% in average kurtosis and 26+% in the maximum infinity norm of model outputs across four models. Code is available at GitHub; models are on Hugging Face Hub; future updates are on arXiv.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
22 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- The Fine-Grained Complexity of Gradient Computation for Training Large Language Models cites Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models
- Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models cites The Fine-Grained Complexity of Gradient Computation for Training Large Language Models
- The Fine-Grained Complexity of Gradient Computation for Training Large Language Models cites Language Models are Few-Shot Learners
- The Fine-Grained Complexity of Gradient Computation for Training Large Language Models cites On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs)
- On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs) cites The Fine-Grained Complexity of Gradient Computation for Training Large Language Models
- The Fine-Grained Complexity of Gradient Computation for Training Large Language Models cites On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis
- On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis cites The Fine-Grained Complexity of Gradient Computation for Training Large Language Models
- An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale cites Language Models are Few-Shot Learners
- The Closeness of In-Context Learning and Weight Shifting for Softmax Regression cites The Fine-Grained Complexity of Gradient Computation for Training Large Language Models
- The Closeness of In-Context Learning and Weight Shifting for Softmax Regression cites Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models
- The Closeness of In-Context Learning and Weight Shifting for Softmax Regression cites Language Models are Few-Shot Learners
- The Closeness of In-Context Learning and Weight Shifting for Softmax Regression cites On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs)
- The Closeness of In-Context Learning and Weight Shifting for Softmax Regression cites On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis
- Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models cites Informer: Beyond Efficient Transformer for Long Sequence Time-Series Forecasting
- Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
- Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models cites Hopfield Networks is All You Need
- Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models cites On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis
- On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis cites Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models
- On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs) cites Hopfield Networks is All You Need
- On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs) cites Uniform Memory Retrieval with Larger Capacity for Modern Hopfield Models
- On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs) cites Language Models are Few-Shot Learners
- On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs) cites On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis
- On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis cites Hopfield Networks is All You Need
- On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity Analysis cites Language Models are Few-Shot Learners
Cited by top-tier papers22
- The Closeness of In-Context Learning and Weight Shifting for Softmax RegressionShuai Li, Zhao Song, Yu Xia, Tong Yu et al.NeurIPS 2024 · 53 citations
- On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs)Jerry Yao-Chieh Hu, Weimin Wu, Zhuoru Li, Sophia Pi et al.NeurIPS 2024 · 49 citations
- On Computational Limits of Modern Hopfield Models: A Fine-Grained Complexity AnalysisJerry Yao-Chieh Hu, Thomas Lin, Zhao Song, Han LiuICML 2024 · 47 citations
- Uniform Memory Retrieval with Larger Capacity for Modern Hopfield ModelsDennis Wu, Jerry Yao-Chieh Hu, Teng-Yun Hsiao, Han LiuICML 2024 · 44 citations
- The Fine-Grained Complexity of Gradient Computation for Training Large Language ModelsJosh Alman, Zhao SongNeurIPS 2024 · 33 citations
Builds on33
- Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
- An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
- Informer: Beyond Efficient Transformer for Long Sequence Time-Series ForecastingHaoyi Zhou, Shanghang Zhang, Jieqi Peng, Shuai Zhang et al.AAAI 2021 · 7,289 citations
- Hopfield Networks is All You NeedHubert Ramsauer, Bernhard Schäfl, Johannes Lehner, Philipp Seidl et al.ICLR 2021 · 620 citations
- Outlier Suppression: Pushing the Limit of Low-bit Transformer Language ModelsXiuying Wei, Yunchen Zhang, Xiangguo Zhang, Ruihao Gong et al.NeurIPS 2022 · 238 citations
Related papers
- Quantizable Transformers: Removing Outliers by Helping Attention Heads Do NothingYelysei Bondarenko, Markus Nagel, Tijmen BlankevoortNeurIPS 2023 · 196 citations
- On the Role of Hidden States of Modern Hopfield Network in TransformerTsubasa Masumura, Masato TakiNeurIPS 2025 · 2 citations
- Nonparametric Modern Hopfield ModelsJerry Yao-Chieh Hu, Bo-Yu Chen, Dennis Wu, Feng Ruan et al.ICML 2025
- Fast and Low-Cost Genomic Foundation Models via Outlier RemovalHaozheng Luo, Chenghao Qiu, Maojiang Su, Zhihan Zhou et al.ICML 2025
- On Sparse Modern Hopfield ModelJerry Yao-Chieh Hu, Donglin Yang, Dennis Wu, Chenwei Xu et al.NeurIPS 2023 · 52 citations
