VersatileFFN: Achieving Parameter Efficiency in LLMs via Adaptive Wide-and-Deep Reuse

Ying Nie, Kai Han, Hongguang Li, Hang Zhou, Tianyu Guo, Enhua Wu, Xinghao Chen, Yunhe WangarXiv 2025 · DOI

Introduction

The scaling of Large Language Models (LLMs) has traditionally followed a simple heuristic: more parameters lead to better performance. However, this trajectory has encountered a significant "memory wall." The hardware requirements for hosting massive models are increasingly prohibitive, leading researchers to explore compression and parameter-efficient architectures. While techniques like Mixture-of-Experts (MoE) and recursive weight sharing offer solutions, they often face a "representational ceiling" or excessive memory overhead.

VersatileFFN introduces a novel architecture that breaks this cycle by reusing existing parameters in a dual-pathway system. Instead of expanding the model's footprint, it dynamically allocates computational resources based on token difficulty, effectively allowing the model to "think harder" when necessary without increasing its memory requirements.

The VersatileFFN Architecture

The core innovation of VersatileFFN is the Adaptive Wide-and-Deep Reuse strategy. It replaces the standard Feed-Forward Network (FFN) in Transformer blocks with a shared-weight structure that can operate in two distinct modes: a "Width-Versatile" path for rapid, intuitive processing and a "Depth-Versatile" path for intensive, iterative reasoning.

Overview of the VersatileFFN framework, illustrating the routing of simple and complex tokens through specialized pathways.

System 1: Width-Versatile Path (Virtual MoE)

Inspired by "System 1" thinking (fast and intuitive), the Width-Versatile path treats the FFN as a virtual Mixture-of-Experts. Rather than adding new expert weights, it slices the existing weight matrix into non-overlapping segments.

The Width-Versatile path slices the weight matrix into virtual experts, enabling MoE-like behavior without additional parameters.

By routing tokens to a subset of these "virtual experts," the model achieves the representational diversity of MoE models without the associated memory cost. This path is optimized for "simple tokens"—high-frequency words or syntactically straightforward elements that do not require deep deliberation.

System 2: Depth-Versatile Path (Recursive Reasoning)

For "complex tokens" that demand deeper analysis, VersatileFFN employs the Depth-Versatile path. This system reuses the entire FFN weight set recursively. A token passes through the same FFN multiple times (up to a limit $L_{max}$), allowing the model to refine its internal representation iteratively. This approach mimics "System 2" thinking—slow, deliberate, and logical.

Difficulty-Aware Gating

The orchestration between these two pathways is managed by a Difficulty-Aware Gating mechanism. Using a Gumbel-Softmax-based controller, the model predicts the optimal number of processing loops for each token.

  • Easy tokens are biased toward the Width path, minimizing FLOPs.
  • Hard tokens (e.g., ambiguous terms, complex nouns, or reasoning-heavy context) are steered toward the Depth path.

This dynamic allocation ensures that computational budget is spent where it provides the most value, bypassing the "one-size-fits-all" computation of standard Transformers.

Experimental Evaluation

The researchers evaluated VersatileFFN across multiple scales (354M to 1.21B parameters) using the FineWeb-Edu dataset and a variety of NLP benchmarks, including PIQA, HellaSwag, and ARC-Challenge.

Key Performance Metrics

  • Superior Accuracy: At the 1.21B scale, VersatileFFN achieved an average accuracy of 60.47%, outperforming both standard MoE baselines (59.65%) and fixed-loop recursive models (60.05%).
  • Parameter Efficiency: To match the performance of VersatileFFN, a standard MoE model would require approximately 1.97B parameters. VersatileFFN achieves this with 63% less parameter overhead.
  • Computational Savings: At the 350M scale, the model outperformed a standard 6-loop recursive model while utilizing 45% fewer FLOPs, demonstrating that adaptive routing is significantly more efficient than fixed recursion.

Conclusion

VersatileFFN demonstrates that model intelligence is not solely a function of parameter count, but of how flexibly those parameters are utilized. By decoupling representational capacity from physical memory through wide-and-deep reuse, it provides a blueprint for high-performance LLMs that can operate within constrained hardware environments. Future work may extend these principles to the attention mechanism, further pushing the boundaries of parameter-efficient deep learning.

Summary updated

BibTeX
@misc{nie2025versatileffn,
  author = {Ying Nie and Kai Han and Hongguang Li and Hang Zhou and Tianyu Guo and Enhua Wu and Xinghao Chen and Yunhe Wang},
  title = {{VersatileFFN: Achieving Parameter Efficiency in LLMs via Adaptive Wide-and-Deep Reuse}},
  year = {2025},
  eprint = {2512.14531},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2512.14531},
}
Figure