Skip to contents

Create an empty clusterer for skipping clustering step of bertopic pipeline

Usage

bt_empty_clusterer()

Value

an empty clustering model (Python class)

Details

This refers to the BaseCluster() function in the Python BERTopic library and can be used to skip over the clustering step that occurs as part of fitting the bertopic model to the text data. Predicting topics is achieved via clustering and if using this function to skip over the clustering step, pre-determined topics will need to be passed to the bertopic model via the y parameter in the bt_fit_model() function. This can be convenient in cases where you already know the topics to which your documents belong. Creating a bertopic model in this way allows you to utilise the other functionality of a bertopic model for scenarios where you do not need to employ the topic discovery capabilities of the bertopic workflow.

Examples

empty_clusterer <- bt_empty_clusterer()

clusterer <- bt_empty_clusterer()