TEDM-X: Transformer-Embedded Dirichlet Mixture Topic Discovery for Automatic and Interpretable Text Clustering

Conventional topic models rely on sparse word-count statistics and generally require the number of topics to be fixed before training. These assumptions weaken topic discovery when documents are semantically related but share limited surface vocabulary. This paper presents TEDM-X, a transformer-embedded topic discovery framework that combines Sentence-BERT document representations with a variational Bayesian Gaussian mixture model governed by a Dirichlet-process prior. Documents are cleaned, divided into overlapping sentence chunks, embedded with all-MiniLM-L6-v2, and L2-normalized before non-parametric mixture inference. The occupied mixture components define the effective topic set, while class-based TF–IDF produces interpretable topic keywords and labels. TEDM-X is evaluated against LDA, NMF, GSDMM, Top2Vec, and BERTopic on 20 Newsgroups and AG News using coherence, topic diversity, external clustering agreement, and internal cluster-validity measures. Relative to the strongest baseline, BERTopic, TEDM-X improves adjusted Rand index by 7.75% and 7.33%, normalized mutual information by 6.60% and 6.41%, and reduces the Davies–Bouldin index by 17.39% and 18.02% on the two datasets, respectively. The results indicate that combining contextual embeddings with adaptive Bayesian mixture inference yields more coherent, separated, diverse, and label-aligned topics without fixing the final number of active topics in advance.