Skip to main content
QUICK REVIEW

[Paper Review] Experiments on Generalizability of BERTopic on Multi-Domain Short Text

Muriël de Groot, Mohammad Aliannejadi|arXiv (Cornell University)|Dec 16, 2022
Text and Document Classification TechnologiesComputer Science11 citations
TL;DR

This paper evaluates BERTopic's performance on multi-domain short texts from university course evaluations, finding it outperforms LDA in topic coherence and diversity. However, BERTopic's default HDBSCAN clustering discards 74% of documents as outliers, so the authors propose replacing it with k-Means to retain all documents while maintaining strong performance and robustness to short texts.

ABSTRACT

Topic modeling is widely used for analytically evaluating large collections of textual data. One of the most popular topic techniques is Latent Dirichlet Allocation (LDA), which is flexible and adaptive, but not optimal for e.g. short texts from various domains. We explore how the state-of-the-art BERTopic algorithm performs on short multi-domain text and find that it generalizes better than LDA in terms of topic coherence and diversity. We further analyze the performance of the HDBSCAN clustering algorithm utilized by BERTopic and find that it classifies a majority of the documents as outliers. This crucial, yet overseen problem excludes too many documents from further analysis. When we replace HDBSCAN with k-Means, we achieve similar performance, but without outliers.

Motivation & Objective

  • To evaluate BERTopic's generalizability across diverse short-text domains, such as university course evaluations from multiple faculties.
  • To compare BERTopic's performance with the baseline LDA model in terms of topic coherence and diversity on short, multi-domain text.
  • To investigate the impact of HDBSCAN's outlier detection on model utility in real-world applications where all documents must be analyzed.
  • To propose and evaluate k-Means as a replacement for HDBSCAN in BERTopic to eliminate outlier rejection while preserving performance.

Proposed method

  • The study applies BERTopic with HDBSCAN clustering and compares it to LDA and BERTopic with k-Means clustering on a corpus of 62,522 short student responses from five university faculties.
  • Topic coherence is measured using normalized pointwise mutual information (NPMI), and topic diversity is calculated as the proportion of unique words in the top-n words across all topics.
  • The experiments are conducted on both faculty-specific corpora and a combined university-wide corpus to assess scalability and domain generalization.
  • Additional experiments are performed on the 20NG dataset, using short (median 16 words) and long (60–100 words) document samples to evaluate sensitivity to document length.
  • HDBSCAN’s outlier detection is quantified by measuring the percentage of documents labeled as outliers across different corpora.
  • The k-Means variant replaces HDBSCAN in BERTopic’s pipeline to assess whether outlier-free clustering maintains or improves performance.

Experimental results

Research questions

  • RQ1Does BERTopic generalize better than LDA across diverse short-text domains such as university course evaluations?
  • RQ2To what extent does HDBSCAN’s outlier detection compromise BERTopic’s utility in real-world short-text applications?
  • RQ3How does document length affect the performance of LDA, BERTopic with HDBSCAN, and BERTopic with k-Means?
  • RQ4Can k-Means be a viable alternative to HDBSCAN in BERTopic without sacrificing topic coherence and diversity?
  • RQ5How does the choice of clustering algorithm impact the scalability and interpretability of BERTopic in a university-wide topic modeling context?

Key findings

  • BERTopic with HDBSCAN achieves a topic coherence of 0.091 and topic diversity of 0.880 on the university-wide corpus, significantly outperforming LDA’s coherence of 0.031 and diversity of 0.718.
  • HDBSCAN classifies 74% of the course evaluation responses as outliers, severely limiting its practical utility despite strong coherence and diversity scores.
  • The BERTopic k-Means variant maintains high performance with a coherence of 0.032 and diversity of 0.571, and produces no outliers, making it more suitable for inclusive analysis.
  • BERTopic k-Means is more robust to short documents than both LDA and BERTopic with HDBSCAN, as shown by a minimal performance drop of δ = -0.001 in topic diversity between long and short documents.
  • While BERTopic HDBSCAN generalizes better across domains, BERTopic k-Means offers a practical trade-off by preserving all documents and maintaining interpretability.
  • The study identifies a critical gap in evaluation metrics: no standard measure currently accounts for outlier generation, which significantly affects model utility in real-world settings.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.