← All entries
Paper2025#542

Dr.LLM: Dynamic Layer Routing in LLMs

Summary

Attaches a tiny MLP router to each frozen block; routers are supervised on 4k length-aware MCTS paths (skip/execute/repeat) from ARC and DART-Math, then run search-free at inference. On six LLaMA-3.2/Qwen-2.5 models, in-domain accuracy rises in all cases (up to +3.4%p / +4.0%p on DART) with ~3–11 fewer layers per query; OOD drop 0.85%p average. Beats LayerSkip/ShortGPT/MindSkip/FlexiDepth by up to +7.7%p avg on GSM8k/MMLU/HellaSwag/HumanEval. Code https://github.com/parameterlab/dr-llm.

Venue
arXiv / Parameter Lab / MBZUAI / NAVER AI Lab
Purpose
Retrofit frozen LLMs with per-layer skip/execute/repeat routers trained from offline MCTS paths
Scale
4k MCTS paths (961k offline forwards); routers 11M/16.8M params (0.14–0.56% of 3B/8B); six backbones 3B–8B; 1k-token gen 15.3% wall-time cut; router overhead <1%
Time period
2025-10-14 (arXiv 2510.12773 v1); last revised 2026-05-18 (v2). Published at ICLR 2026. HF paper publishedAt 2025-10-14.
Added
Oct 1, 2026
Research status
done

From the source

Published
Oct 14, 2025
Last revised
May 18, 2026
arXiv categories
cs.CL, cs.AI, cs.LG
Author comment
Published at ICLR 2026
Citations
11 (2 influential)
References
34

Fetched Oct 3, 2026 from arXiv, Semantic Scholar. These numbers change; the curated fields above do not come from here.

Abstract (from arXiv)

Large Language Models (LLMs) process every token through all layers of a transformer stack, causing wasted computation on simple queries and insufficient flexibility for harder ones that need deeper reasoning. Adaptive-depth methods can improve efficiency, but prior approaches rely on costly inference-time search, architectural changes, or large-scale retraining, and in practice often degrade accuracy despite efficiency gains. We introduce Dr. LLM, Dynamic routing of Layers for LLMs, a retrofittable framework that equips pretrained models with lightweight per-layer routers deciding to skip, execute, or repeat a block. Routers are trained with explicit supervision: using Monte Carlo Tree Search (MCTS), we derive high-quality layer configurations that preserve or improve accuracy under a compute budget. Our design, windowed pooling for stable routing, focal loss with class balancing, and bottleneck MLP routers, ensures robustness under class imbalance and long sequences. On ARC (logic) and DART (math), Dr. LLM improves accuracy by up to +3.4%p while saving 5 layers per example on average. Routers generalize to out-of-domain tasks (MMLU, GSM8k, AIME, TruthfulQA, SQuADv2, GPQA, PIQA, AGIEval) with only 0.85% accuracy drop while retaining efficiency, and outperform prior routing methods by up to +7.7%p. Overall, Dr. LLM shows that explicitly supervised routers retrofit frozen LLMs for budget-aware, accuracy-driven inference without altering base weights. Code is available at https://github.com/parameterlab/dr-llm.

Tags

dr-llmlayer-routingmctsadaptive-depthskip-repeaticlrmbzuainaver

Topics

adaptive depth, layer routing, efficient inference

Research notes

  • Primary: arxiv abs (cs.CL; also cs.AI, cs.LG). License not stated on abs/HTML at check. Parameter Lab / MBZUAI / NAVER AI Lab / University of Tübingen / Tübingen AI Center. Heakl corresponding. Code https://github.com/parameterlab/dr-llm (57 stars at check). HF paper page 32 upvotes; githubRepo linked; no linked models/datasets. Discord posted abs (Substack UTM). MCTS supervision is derived from public ARC/DART-Math, not a hosted corpus, so no datasets_local row. License field left blank per catalog convention.

Cites, within this collection 2

Similar entries