Manuscript Offprint

arXiv:2610.07606

VALSE: Vertical Adaptive Layer Skipping for Efficient Inference in Large Language Models

Jia-Dong Zhang

Abstract

This paper establishes a theoretical framework for vertical adaptive layer skipping, proving three foundational results: (i) an Expected FLOPs formula (theorem 2) giving a closed-form expression for the computational cost of arbitrary per-sample skip schedules as a function of layer-wise skip probabilities; (ii) function-space superset (theorem 10) and strict inclusion (theorem 11) theorems showing that skip-layer models are strictly contained in—yet meaningfully approximate—the full-layer function space, with an explicit separating example; and (iii) a structural duality between VALSE and Mixture-of-Experts architectures (theorem 6), positioning vertical depth-wise sparsity as the orthogonal counterpart to horizontal width-wise sparsity. Building on this theory, we propose VALSE (Vertical Adaptive Layer Skipping for Efficiency), a per-sample, non-contiguous layer skipping method: a lightweight difficulty estimator scores each input from the first few layers, and per-layer gates selectively skip redundant layers—including arbitrary middle layers while retaining deeper ones—so that only the necessary depth is activated for each input, whose feasibility is preliminarily assessed at prototype scale.

1 Introduction

Modern large language models (e.g., GPT-4 [OpenAI et al., 2023], LLaMA [Touvron et al., 2023], DeepSeek-MoE [Dai et al., 2024]) stack dozens to hundreds of Transformer blocks. Regardless of input difficulty—from simple sentiment classification to complex multi-step problems—every sample must traverse all layers, incurring identical computation.

In the horizontal (width) dimension, Mixture-of-Experts (MoE) achieves sparse activation by selecting K of E experts per token per layer. However, in the vertical (depth) dimension, the number of layers remains fixed for all inputs: MoE makes each layer “cheaper” but does not reduce the number of layers. Depth thus constitutes an underexploited orthogonal direction for conditional computation.

The core idea is natural: if simple inputs do not require the full representational power of all layers, can we vertically skip certain layers based on input difficulty, activating only the necessary depth? MoE achieves width-wise sparsity; vertical layer skipping achieves depth-wise sparsity—the two form orthogonal dimensions.

Limitations of existing methods. Prior work on adaptive depth falls into several categories, each with structural limitations: early exit [Xin et al., 2020, Liu et al., 2020, Schuster et al., 2022] is truncation-based and cannot skip a middle layer while retaining a deeper one; adaptive computation time [Graves, 2016, Dehghani et al., 2019] adds shared-weight recurrence rather than skipping fixed layers; structured dropout [Fan et al., 2020, Elhoushi et al., 2024a] selects subnetworks statically or per token, not per-sample by difficulty; and token-level routing (MoD [Raposo et al., 2024]) operates at token granularity and lacks an explicit difficulty signal. Crucially, no existing method achieves

40th Conference on Neural Information Processing Systems (NeurIPS 2026).

per-sample, non-contiguous layer skipping (skipping arbitrary middle layers while retaining deeper ones) in conjunction with a unified theoretical duality to horizontal MoE. A detailed comparison is provided in section 2 and section 3.

Contributions. We propose VALSE (Vertical Adaptive Layer Skipping for Efficiency), with three contributions:

  1. Theoretical framework. We formalize vertical sparse conditional computation through three fully proven results: the Expected FLOPs theorem (theorem 2), which gives a closed-form expression for the computational cost of arbitrary per-sample skip schedules; the function-space superset (theorem 10) and strict containment (theorem 11) theorems, establishing that skip-layer models are strictly contained in the full-layer function space with an explicit separating example; and the MoE–VALSE structural duality (theorem 6) together with a unified two-dimensional sparsity representation (theorems 7 and 9), positioning VALSE as the depth-wise counterpart to horizontal MoE (section 8).

  2. Method design. A lightweight, interpretable difficulty estimator scores each sample from the first KestK_{est} layers, feeding three routing variants (hard, soft, global) that produce per-sample, non-contiguous layer retention sets—extending conditional computation from the width to the depth dimension. The method is supported by four auxiliary losses (layer-utilization balancing, efficiency, output consistency via KL distillation, and Z-loss) and a three-stage curriculum learning schedule (sections 5 to 7).

  3. Proof-of-concept validation. A prototype-scale (12-layer) evaluation on SST-2 provides initial feasibility evidence for the layer-skipping mechanism. We explicitly frame these results as preliminary and emphasize that the core empirical hypothesis—difficulty-driven differentiated routing—is not yet validated at the current scale; full-scale evaluation on larger, pre-trained models is necessary to confirm the approach (section 9).

References (24)