atlas

Research map / Large language models / Language, safety and interpretability

Learn To be Efficient: Build Structured Sparsity in Large Language Models

NeurIPS 2024 · Large language models › Language, safety and interpretability · approach: Pruning and circuits in LLMs · 1 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Proposes Learn-To-be-Efficient (LTE), a two-stage training method that MoEfies FFN layers with sigmoid threshold routing plus an efficiency loss and separability loss, yielding more structured activation sparsity in both ReLU and non-ReLU LLMs.

Problem

LLM inference is costly in FFN layers; existing MoEfication methods exploit only naturally occurring activation sparsity, which is low in soft-activation models like LLaMA, and top-k softmax routing hurts accuracy when converting FFNs to MoE.

Approach

Group FFN neurons into experts via balanced K-means on weights, route with independent sigmoid scores and a fixed threshold, and train the router and model jointly with an efficiency loss (penalizing router output magnitude) and a threshold-separability loss, followed by a discrete-routing adaptation stage.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Use LTE instead of baseline sparse methodsLLaMA-7B · XSumGFLOPs per token: 12.06 -> 5.38Helped
Use LTE instead of baseline sparse methodsLLaMA-7B · E2EGFLOPs per token: 12.06 -> 4.65Helped
Use LTE instead of baseline sparse methodsLLaMA-7B · WikiText-103GFLOPs per token: 12.06 -> 6.59Helped
Use LTE instead of Wanda at similar overall sparsityLLaMA-7B · WikiText103perplexity: 6.87 -> 5.95Helped
Replace parameter K-means grouping with random neuron grouping (ablation)LTE · WikiText-103 (GPT2-Medium)performanceHurt
Replace parameter K-means grouping with co-activation graph split (ablation)LTE · WikiText-103 (GPT2-Medium)performanceNo clear effect
Increase efficiency-loss coefficient η (ablation)LTE · Evaluated models and taskssparsityHelped
Add separability loss (λ from 0 to 0.5) (ablation)LTE · WikiText-103 (GPT2-Medium)perplexityHelped
Increase separability-loss coefficient λ beyond 0.5 (ablation)LTE · WikiText-103 (GPT2-Medium)perplexityNo clear effect
Replace LTE-trained routers with random routers (ablation)LTE · WikiText-103 (GPT2-Medium)performance at different sparsity levelsHurt
Replace GeLU with ReLU (ablation)RoBERTa · MRPCaccuracy: around 10% accuracy dropHurt
Use threshold-based adaptive LTE expert selection rather than fixed expert countsLLaMA2-7B with custom Triton kernel · End-to-end generationlatency: 25\%Helped

Surprising findings

Limitations

Experimental setup

Datasets: GLUE WikiText-103 XSum E2E Tulu

Benchmarks: GLUE E2E XSum WikiText-103 MMLU

Metrics: accuracy Matthews correlation Pearson correlation ROUGE-L perplexity GFLOPs per token wall-clock latency

Baselines: MoEfication Deja Vu R-LLaMA+MoE Wanda σ-MoE

Builds on: MoEfication Deja Vu noisy top-k softmax gating Wanda

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy