BERTopic: Neural topic modeling with a class-based TF-IDF procedure
About
Topic models can be useful tools to discover latent topics in collections of documents. Recent studies have shown the feasibility of approach topic modeling as a clustering task. We present BERTopic, a topic model that extends this process by extracting coherent topic representation through the development of a class-based variation of TF-IDF. More specifically, BERTopic generates document embedding with pre-trained transformer-based language models, clusters these embeddings, and finally, generates topic representations with the class-based TF-IDF procedure. BERTopic generates coherent topics and remains competitive across a variety of benchmarks involving classical models and those that follow the more recent clustering approach of topic modeling.
Related benchmarks
| Task | Dataset | Result | Rank | |
|---|---|---|---|---|
| Text Classification | 20News | Accuracy59.1 | 127 | |
| Text Classification | AGNews | Accuracy66.6 | 119 | |
| Topic Modeling | 20NG | NPMI0.0887 | 33 | |
| Topic Modeling | NCTBText | CV0.82 | 29 | |
| Topic Modeling | Jamuna News | CV0.71 | 29 | |
| Topic Modeling | BanFakeNews | CV0.67 | 25 | |
| Topic Modeling | M10 | NPMI0.131 | 23 | |
| Topic Modeling | DBLP | NPMI0.0039 | 23 | |
| Topic Modeling | Yelp | -- | 18 | |
| Topic Modeling | BBC | NPMI0.085 | 17 |