Abstract
Traditional topic models often treat documents as unordered collections of words or topics, failing to capture the inherent global structure found in many domains. This paper introduces a hierarchical Bayesian model that represents document structure as a latent permutation of topics. By employing the Generalized Mallows Model (GMM), the framework encodes high-level discourse constraints such as topic contiguity and consistent global ordering. Experimental results across five diverse datasets show that this approach significantly outperforms existing Markovian models in tasks including document alignment, segmentation, and information ordering.
Introduction
Most conventional topic models, such as Latent Dirichlet Allocation (LDA), operate under the "bag of words" assumption, which ignores the sequential nature of text. While extensions using Markov chains can capture local transitions between topics, they often struggle with global structural constraints. In many structured domains—such as Wikipedia entries or technical reviews—documents follow predictable templates. For example, a city's history is typically discussed before its transportation infrastructure. Furthermore, topics in these domains are usually contiguous; once a section on "History" concludes, the author rarely returns to it. Existing models often fail to enforce this "non-recurring" property, leading to "topic flickering." This paper addresses these limitations by modeling document structure through latent permutations.
The Latent Permutation Model
The core innovation of this work is the explicit representation of content structure as a permutation of topics. This is achieved through a hierarchical Bayesian framework governed by the Generalized Mallows Model (GMM).
Model Architecture
The model assumes a "standard" or centroid ordering for a given domain and uses dispersion parameters to control how individual documents deviate from that standard. By treating the topic sequence as a permutation, the model inherently satisfies two critical discourse properties:
- Contiguity: Each topic is expressed within a single, continuous block of text.
- Precedence: Topics follow a globally consistent progression across the corpus.
As shown in the graphical representation (Figure 1), the model integrates global structure parameters ($\theta, \rho$) with document-specific latent variables ($\mathbf{t}, \pi, z$) to generate the observed words ($w$). The use of permutations also solves the "topic identifiability" problem common in LDA; here, topics are naturally indexed by their typical position in the document sequence.
Inference via Collapsed Gibbs Sampling
To handle the discrete and vast space of possible permutations, the authors utilize collapsed Gibbs sampling. The permutations are represented using inversion counts—the number of times a topic appears "out of order" relative to the identity permutation. This transformation simplifies the complex discrete optimization into a series of independent calculations, making the inference process computationally tractable.
Experimental Evaluation
The model was evaluated on five datasets representing different levels of structural rigidity:
- CitiesEn/CitiesEn500/CitiesFr: Wikipedia articles on cities in English and French.
- Elements: Technical Wikipedia articles on chemical elements.
- Phones: Formulaic expert cell phone reviews from PhoneArena.com.
The performance was measured across three primary tasks: alignment (identifying shared topics across documents), segmentation (detecting topical boundaries), and information ordering (reconstructing the original order of a shuffled document).
Results and Discussion
The permutation-based model consistently outperformed the Hidden Topic Markov Model (HTMM) and other state-of-the-art baselines. In the alignment task, the model achieved an average 28% improvement in F-score over HTMM. For segmentation, it reached a $P_k$ error measure of 0.231, significantly better than the 0.321 achieved by BayesSeg. Most notably, in information ordering, the model's Kendall’s $\tau$ of 0.602 more than doubled the performance of HMM-based baselines (0.267).
The model's success stems from its ability to act as a natural regularizer. Because a permutation uses each element exactly once, it prevents the topic repetition loops that plague Markovian models. Furthermore, the model adapts to the domain; it learns high dispersion parameters for rigid domains like phone reviews while allowing more flexibility for varied Wikipedia articles.
Conclusion and Future Work
While the latent permutation approach provides a powerful mechanism for modeling global structure, it currently assumes that topics never recur. This assumption holds for encyclopedic text but may not apply to more fluid domains like dialogue. Future research could explore mixtures of GMMs to handle corpora with multiple distinct editorial styles and integrate local syntactic coherence models to improve sentence-level flow. Nevertheless, this work demonstrates that moving beyond the "bag of topics" to structured permutations is a significant step forward for content modeling.
Summary updated