Abstract
Language modeling has traditionally been divided between interpretable but limited statistical $n$-gram models and powerful but "black-box" recurrent neural networks. This paper introduces the Tensor Space Language Model (TSLM), which bridges this gap by representing language in high-dimensional tensor spaces. By employing tensor network decomposition, TSLM captures complex multi-way word dependencies while maintaining computational efficiency. We demonstrate that TSLM is a theoretical generalization of $n$-gram models and empirically outperforms standard RNNs and LSTMs on benchmark datasets.
Introduction
Predicting the next word in a sequence is a cornerstone of natural language processing. Historically, statistical $n$-gram models provided simplicity but suffered from the "curse of dimensionality" as the order $n$ increased. Modern Recurrent Neural Networks (RNNs) and LSTMs overcome these dependency limits but often obscure the underlying mathematical relationships through non-linear activations and additive hidden states.
The Tensor Space Language Model (TSLM) addresses this by using high-order tensors to model interactions between multiple words simultaneously. To avoid exponential parameter growth, the authors utilize tensor networks and recursive decomposition, creating a model that is both mathematically rigorous and computationally tractable.
Methods
The core of TSLM is the representation of a sentence as a high-order tensor formed by the tensor product of word vectors. To make this practical, the authors employ Tensor Networks (TN) and Recursive Tensor Decomposition. Instead of a single dense tensor, the model is represented as a network of smaller, interconnected tensors.
As shown in Figure 2, the recursive calculation derived from tensor contraction leads to a hidden state update rule. Interestingly, this derivation results in an element-wise multiplication (Hadamard product) between the previous hidden state and the current input, rather than the standard additive update found in traditional RNNs. This provides a theoretical tensor-based justification for multiplicative hidden states, which are known to be highly expressive for capturing semantic interactions.
Key Results
The model was evaluated on the Penn Tree Bank (PTB) and WikiText-2 (WT2) benchmarks using Perplexity (PPL). TSLM consistently outperformed standard RNN and LSTM baselines.
As detailed in Figure 6, TSLM achieved a PPL of 108.1 on PTB, significantly lower than the standard RNN (124.1) and LSTM (110.3) with comparable hidden sizes. When combined with the Mixture of Softmaxes (MoS) technique, TSLM+MoS reached state-of-the-art levels, achieving 83.6 on PTB and 81.0 on WikiText-2. By using tensor decomposition, the authors reduced parameter complexity from $O(m^n)$ to $O(m \times r)$, making high-order modeling practical.
Discussion and Insights
A key insight of this work is that TSLM is a theoretical generalization of the $n$-gram model; using one-hot basis vectors allows the tensor inner product to replicate frequency-based $n$-gram logic exactly. Furthermore, empirical testing revealed a "saturation point" for model performance regarding the order $n$ and rank $r$, suggesting that semantic information within a corpus eventually fills the available tensor space.
While TSLM shows strong results on medium-scale datasets, future work involves scaling the model to massive modern corpora and exploring alternative tensor network topologies (e.g., PEPS or MERA) to further refine language structure modeling.
Summary updated