Abstract
The widespread adoption of large language models such as ChatGPT and Bard has led to unprecedented demand for these technologies. The burgeoning cost of inference for ever-increasing model sizes coupled with hardware shortages has limited affordable access and poses a pressing need for efficiency approaches geared towards high throughput and performance. Multi-input multi-output (MIMO) algorithms such as data multiplexing, offer a promising solution with a many-fold increase in throughput by performing inference for multiple inputs at the cost of a single input. Yet these approaches are not currently performant enough to be deployed in modern systems. We change that by developing MUX-PLMs, a class of high throughput pre-trained language models (PLMs) trained with data multiplexing, that can be fine-tuned for any downstream task to yield high-throughput high-performance. Our novel multiplexing and demultiplexing modules proficiently entangle and disentangle inputs, and enable high-performance high throughput MUX-PLMs that are competitive with vanilla PLMs while achieving 2x/5x inference speedup with only a 1-4 % drop on a broad suite of tasks.
Introduction
As large language models (LLMs) become ubiquitous, the computational cost of inference has skyrocketed, creating a "perfect storm" of increasing model sizes and global hardware shortages. Traditional efficiency methods like pruning, quantization, and distillation often reach diminishing returns or require specialized hardware to realize actual throughput gains.
Data Multiplexing offers a different paradigm: "squashing" multiple input sequences into a single representation to process them in a single forward pass. While conceptually efficient, previous attempts like DataMUX suffered from devastating 20–30% accuracy drops. MUX-PLMs (specifically MUX-BERT and MUX-ELECTRA) bridge this gap, making data multiplexing viable for modern pre-trained models.
The MUX-PLM Framework
The core of the MUX-PLM approach is a Multi-Input Multi-Output (MIMO) architecture that allows a single model to process up to 10 different sequences simultaneously. This is achieved through three primary components:
- Contextual Multiplexer (MUX): This module uses cross-instance attention to aggregate information across $N$ input sequences before merging them via a Hadamard product with multivariate Gaussian vectors.
- Transformer Backbone: The multiplexed representation passes through a standard Transformer. Because the input is entangled, the model learns to process multiple signals in parallel.
- RSA-Demultiplexer (DeMUX): A key innovation that uses $N$ learned "private key" vectors to disentangle the hidden states back into $N$ independent predictions, avoiding the sequence length overhead of previous prefix-based methods.
Training Pipeline
To overcome the distribution shift caused by multiplexing, the researchers utilized a three-stage training process:
- Stage 1: Token Retrieval: A simple auto-encoding task to prime the model to recognize individual tokens within a multiplexed input.
- Stage 2: Multiplexed Pre-training: Training with standard objectives (like Masked Language Modeling) in a MIMO fashion.
- Stage 3: Fine-tuning: Adapting the pre-trained MUX-model to specific downstream tasks like those in the GLUE benchmark.
RSA-Inspired Demultiplexing
The DeMUX module is critical for performance. By treating multiplexing vectors as "encryption keys" and demultiplexing vectors as "decryption keys," the model ensures that information from one instance does not leak into another, despite sharing the same hidden layers.
Key Results and Insights
Experimental evaluations on the GLUE benchmark and token classification tasks (NER, POS tagging) revealed several key insights:
- Throughput Gains: MUX-PLMs achieved up to a 5x increase in throughput compared to vanilla models.
- Minimal Accuracy Loss: Unlike previous methods, MUX-PLMs stayed within 1–4% of state-of-the-art baselines. For example, MUX-BERT ($N=2$) was only ~3 points behind the baseline on GLUE.
- Pareto Frontier: MUX-PLMs sit on the Pareto frontier of the accuracy-vs-throughput trade-off. A "Small" MUX-BERT with $N=2$ can outperform a "Small" vanilla BERT in throughput while maintaining competitive accuracy.
- Free Ensembling: If $N$ different inputs are not available, feeding the same input $N$ times with different keys provides an "ensemble" boost of ~1-1.5 points without requiring multiple models.
Conclusion and Future Work
MUX-PLMs represent a significant step forward in making high-throughput inference accessible. While the current work focuses on encoder-only models like BERT and ELECTRA, the architecture-agnostic nature of multiplexing suggests it could be combined with other methods like pruning for even greater gains. Future research will focus on scaling these techniques to generative, decoder-only models for high-throughput text generation.
Summary updated