Recently, gensim, a Python package for topic modeling, released a new version of its package which includes the implementation of author-topic models.
The most famous topic model is undoubtedly latent Dirichlet allocation (LDA), as proposed by David Blei and his colleagues. Such a topic model is a generative model, described by the following directed graphical models:
In the graph, and are hyperparameters. is the topic distribution of a document, is the topic for each word in each document, is the word distributions for each topic, and is the generated word for a place in a document.
There are models similar to LDA, such as correlated topic models (CTM), where is generated by not only but also a covariance matrix .
There exists an author model, which is a simpler topic model. The difference is that the words in the document are generated from the author for each document, as in the following graphical model. is the author of a given word in the document.
Combining these two, it gives the author-topic model as a hybrid, as shown below:
The new release of Python package, gensim, supported the author-topic model, as demonstrated in this Jupyter Notebook.
- I am also aware that there is another topic model called structural topic model (STM), developed for the field of social science. However, there is no Python package supporting this, but an R package, called stm, is available for it. You can refer to their homepage too.
- I may consider including author-topic model and STM in the next release of the Python package shorttext.