LDA(Latent Dirichlet Allocation)とは
• Bleiらによる
– David M. Blei, Andrew Y. Ng, and Michael I. Jordan. Latent dirichlet
allocation. The Journal of Machine Learning Research, 3: 993-1022,
March 2003.
• コーパスを対象とした生成確率モデルの一つ
• 文書が潜在トピック上の確率混合分布として
表される
• 各トピックは単語上の分布として特徴づけら
れる
6
記法
Word
A vocabulary indexed:
{1, . . . , V }
V -vector w vth word in the vocabulary
wv = 1
w u = 0, v 6= u
Document
w = (w1 , w2 , . . . , wN ) N words
Corpus
D = {w1 , w2 , . . . , wM } M documents
8
9.
LDA [Blei et.al.2003]
トピック数:
k
パラメータ:
↵,
トピック分布:
✓
ドキュメント数:
M 2 k ⇥ V matrix
文書 d の単語数:
N
N 個のトピック:
z
N 個の単語:
w
↵ ✓ z w N
M
↵ 2 k-vector zn ⇠ Multinomial(✓)
✓ ⇠ Dir(↵) N ⇠ Poisson(⇠)
✓ 2 k-vector on (k 1)-simplex 9
10.
LDAモデルの推論
トピック分布 ✓ 、N個のトピック z 、N 個の単語 w の同時分布は、
N
Y
p(✓, z, w|↵, ) = p(✓|↵) p(zn |✓)p(wn |zn , )
n=1
↵ ✓ z w N
M
✓ と z で周辺化すると、文書wの確率が得られ、
Z N X
!
Y
p(w|↵, ) = p(✓|↵) p(zn |✓)p(wn |zn , ) d✓
n=1 zn
さらに、積を取ると、コーパス全体 D の確率が得られる
M Z Nd
!
Y Y X
p(D|↵, ) = p(✓ d |↵) p(zdn |✓ d )p(wdn |zdn , ) d✓ d
d=1 n=1 zdn
10
Purity and Inverse-Purity
• itemが一つのクラスターに属す場合の、クラスタリング評価指標
• Web people search task Iで使用された
• Zhao, Y., & Karypis, G. (2001). Criterion functions for document clustering: Experiments and analysis. MN. Retrieved from https://
wwws.cs.umn.edu/tech_reports_upload/tr2001/01-040.pdf
• Artiles, J., Gonzalo, J., & Sekine, S. (2007). The semeval-2007 weps evaluation: Establishing a benchmark for the web people search
task. Proceedings of the 4th International Workshop on Semantic Evaluations (SemEval-2007) (pp. 64–69). Retrieved from http://
acl.ldc.upenn.edu/W/W07/W07-2012.pdf
X |Ci |
Purity = max Precision(Ci , Lj ) Precision measure
i
n j
|Ci Lj |
Precision(Ci , Lj ) =
|Ci |
X |Li |
Inverse Purity = max Precision(Li , Cj ) Recall measure
i
n j
C : the set of clusters to be evaluated
L : the set of categories (manually annotated)
n : the number of clustered elements
14