TL;DR
Converting bulky, pretrained Vision-Language Models (VLMs) into faster Mixture-of-Experts (MoE) architectures usually involves blind guesswork—applying rules of thumb that work on one model only to watch them catastrophically break another. LEGO replaces that guesswork with simple architectural "sizing rules," revealing a hidden geometric sweet spot that keeps models sharp while shrinking their compute footprint. Give LEGO a memory and compute budget, and it automatically snaps together and stabilizes the best sparse VLM from existing dense parts.
What Problem Does This Paper Address?
Vision-Language Models (VLMs) pair a visual encoder (like a Vision Transformer, or ViT) with a Large Language Model (LLM). Scaling them up makes them smarter, but deploying a monolithic giant on an edge device or tight server budget is painful.
Mixture-of-Experts (MoE) offers an elegant escape hatch: replace the LLM’s dense Feed-Forward Networks (FFNs) with a pool of smaller "expert" sub-networks, and route each token to only a few of them. You get high parameter capacity (memory) with low per-token compute. Because training MoEs from scratch is notoriously expensive and unstable, researchers often convert pretrained dense models into MoEs ("Dense-to-MoE") followed by a lightweight recovery fine-tuning phase.
Here is the catch: nobody had clear rules for what MoE structure to build. Engineers typically rely on raw sparsity heuristics—like "activate 4 out of 16 experts (1/4)." Yet the authors noticed a puzzling anomaly: applying a 1/4 activation ratio to an 8B VLM caused a mild 4.8% performance dip, whereas the exact same recipe on a larger 14B model triggered a steep 10.2% nosedive. Why would a bigger model be more fragile at the exact same sparsity?
Methods
To solve this, the authors introduce LEGO (ruLes-guided Experts Generation and Orchestration), a framework built on three pillars:
- Budget-Aware Hybrid Search: Given a target budget of total parameters ($P_{\text{total}}$, dictating VRAM) and active parameters per token ($P_{\text{active}}$, dictating compute), LEGO searches across candidate base models and three standard FFN conversion operators: Split (slicing a dense FFN into $N_S$ thinner shards), Upcycle (duplicating shards to create $N_E$ total experts), and Hybrid (splitting then duplicating for precise budget control). Instead of testing everything, an algorithm filters and ranks candidates using empirical sizing rules (keeping the ratio of activated FFN width to hidden dimension, $D_I/D_H$, ideally within $[1.5, 8]$).
- Moment-Matching Scaling Factor: Splitting and duplicating weights introduces a sneaky mathematical bug at initialization: aggregating a sparse subset of shards shifts the output scale and variance compared to the original dense layer, spiking early training loss. LEGO derives a closed-form scalar $C$ (a geometric mean of mean-shift and variance corrections, accounting for repeated shard hits) applied right after expert aggregation to restore smooth optimization.
- Two-Stage Multimodal Recovery: Because surgery on the LLM’s FFNs temporarily scrambles its gradients, training the whole VLM at once sends noisy signals back into the delicate pretrained vision tower. LEGO freezes the ViT in Stage 1 to let the LLM and projector heal first, then unfreezes everything for joint fine-tuning in Stage 2.
Datasets
No new benchmarks are introduced. For evaluation, the authors test across nine public multimodal benchmarks spanning three categories: VQA/OCR, Document/Chart understanding, and Multi-image/Comprehensive tasks (reporting arithmetic means across three runs; individual benchmark names and exact training data mixtures are deferred to the paper's appendices).
Key Insights and Ideas
- Raw sparsity is an illusion; $D_I/D_H$ is the true compass: Different LLM backbones have wildly different native FFN-to-attention width ratios ($D_{\text{dense}}/D_H$). That 14B model crashed at 1/4 sparsity because its native FFN was relatively narrow, pushing its activated FFN-to-hidden ratio ($D_I/D_H$) down to $0.67$. Across model families, $D_I/D_H < 1$ creates a severe information bottleneck, $[1.5, 8]$ is the sweet spot, and going higher yields diminishing returns—proving that more active parameters do not automatically mean better recovery.
- Sparsity still has boundaries: Even when $D_I/D_H$ sits comfortably in the green zone, extreme sparsity is fragile. Activating between $1/8$ and $1/2$ of the expert pool strikes the safest balance during fast recovery.
- Protect the eyes while the brain heals: Synchronously updating the ViT while converted MoE layers are still chaotic triggers cascading multimodal errors. Delaying ViT unfreezing visibly lowers and stabilizes early training loss.
Key Results
- Superior Budgeted Construction: Under a 17B total / 5B active LLM budget, naive Split-only conversion of InternVL3-14B collapses to an average score of 58.2 (-29.5% vs. dense) due to an extreme width bottleneck ($D_I/D_H = 0.17$), while Upcycling a 2B model hits diminishing returns at 76.9. LEGO selects an 8B base with a Hybrid
8s24E4Aconfiguration ($D_I/D_H = 2.64$), scoring 80.7—within 2.2% of the dense 14B ceiling. - Surpassing Smaller Dense Baselines: At an 8B/3B budget, LEGO’s hybrid Qwen2-VL-2B (
2s16E4A) reaches 75.9, outperforming its equivalently trained dense 2B parent (73.1) by +3.8% and beating external pruning/shared-expert conversion baselines like ToMoE and CMoE on InternVL3. - Real-World Speedups: On an NVIDIA A100 (batch size 1), converting InternVL3-8B via LEGO (
16s16E8A) cuts mean query latency from 0.801s to 0.702s and boosts generation throughput by 20.3% (from 80.02 to 96.29 tokens/s) at virtually identical peak VRAM (~17.8 GiB), trading ~3.1 points of accuracy for snappy execution.
Limitations and Future Work
The authors candidly note that their sizing rules ($D_I/D_H \in [1.5, 8]$) are empirical guidelines for fast Dense-to-MoE recovery, not universal physical laws for training MoEs from scratch. Furthermore, because LEGO jointly picks both the source backbone and the MoE structure to meet a budget, cross-source table comparisons reflect practical end-to-end engineering rather than isolated, single-backbone causal effects. Finally, hardware speedups were measured at batch size 1 on an A100 where all expert weights stay resident in memory; different serving batch sizes or offloading setups will shift the efficiency picture.
Summary updated