Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

topic_model.get_topic() #894

Closed
As2066 opened this issue Dec 20, 2022 · 1 comment
Closed

topic_model.get_topic() #894

As2066 opened this issue Dec 20, 2022 · 1 comment

Comments

@As2066
Copy link

As2066 commented Dec 20, 2022

Hi.. I used this line to display 20 words for topic number 0,
topic_model.get_topic(0)[:20]
but only 10 words appeared for me.
Is there a way to display more words?

@MaartenGr
Copy link
Owner

That is because the default BERTopic model creates the top 10 words. If you want the top 20 words, then you will have to set BERTopic(top_n_words=20).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants