You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a question regarding predefined Topics, whenver I add a list of zeroshot_topic_list, I got different generated topics and not the one I added, is there a way to only do topicmodeling based only on these zeroshot_topic_list ?
Code :
from bertopic import BERTopic
# Initialize and train BERTopic model
topic_model = BERTopic(
embedding_model=embedding_model,
vectorizer_model=vectorizer_model,
umap_model=umap_model,
calculate_probabilities=True,
#hdbscan_model=hdbscan_model,
representation_model=representation_model,
verbose=True,
nr_topics=15,
min_topic_size=25,
zeroshot_topic_list=zeroshot_topic_list,
zeroshot_min_similarity=.85
)
# Fit the topic model and transform the data
topics, probs = topic_model.fit_transform(df['PreprocessedText'].values)
The text was updated successfully, but these errors were encountered:
Hi, Thanks again for your great tool,
I have a question regarding predefined Topics, whenver I add a list of zeroshot_topic_list, I got different generated topics and not the one I added, is there a way to only do topicmodeling based only on these zeroshot_topic_list ?
Code :
The text was updated successfully, but these errors were encountered: