SlideShare a Scribd company logo
1 of 22
Download to read offline
ACL2011読み会

                  坪坂 正志
           2011/9/3@サイボウズラボ



2011/9/3       ACL 2011 読み会@サイボウズラボ   1
紹介論文

• Joel Lang : A scalable probablistic classifier for language
  modeling. ACL. 2011
    – 確率的識別器を使った言語モデルに関する論文
    – Kneser-NeyのようなNグラムモデルに比べ、長距離の特徴量
      などを利用できる
    – 同様に識別器を使った先行研究と違い、語彙数30367、1億
      語以上のコーパスに対してもスケールする




 2011/9/3             ACL 2011 読み会@サイボウズラボ                 2
言語モデル

Happy families are all alike; every unhappy
                                            次に来る単語は?




 2011/9/3            ACL 2011 読み会@サイボウズラボ              3
言語モデル

Happy families are all alike; every unhappy
                                            次に来る単語は?

 • 例えばtrigramモデルではP(word | every unhappy)を
   計算する




 2011/9/3            ACL 2011 読み会@サイボウズラボ              4
言語モデル

Happy families are all alike; every unhappy
                                            次に来る単語は?

 • 例えばtrigramモデルではP(word | every unhappy)を
   計算する
 • でも離れた単語に注目すると、より次の単語の予測
   精度が高くなる可能性がある




 2011/9/3            ACL 2011 読み会@サイボウズラボ              5
トリガーモデル

• Nグラムの範囲を超えた長距離の単語の影響を組
  み入れた言語モデル
• 詳しくは




2011/9/3   ACL 2011 読み会@サイボウズラボ   6
どういう特徴量を使うか

• これまでの文脈が ” Yesterday at the press conference
  Mr Thompson said”の場合

                                         通常の3-gram


                                         3-gramの一部をスキップ


                                         3個前までの出現単語


                                         4-8個前までの出現単語



 2011/9/3         ACL 2011 読み会@サイボウズラボ                    7
先行研究

• [Rosenfeld 1996]
      – 最大エントロピー分類器を使った言語モデル
      – パラメータの推定に非常に時間がかかる
• [Bengio+ 2003]
      – ニューラルネットを使った言語モデル
      – これも大きなデータセットに適応するのは困難
• [Mnih and Hinton 2008]
      – 語彙数20000, 1400万語のデータセットに対して適用
• [Van den Bosch 2005]
      – 決定木ベースの手法
      – 一億語以上のデータセットに対して適用可能
      – 確率モデルではないのでperplexityでの比較が困難

2011/9/3             ACL 2011 読み会@サイボウズラボ   8
先行研究 (論文では触れてない)

• 岡野原, 辻井 : 行列分解による多クラス分類とその
  応用. 言語処理学会. 2010
      – 単語数5379万、語彙数116万のデータに対して適用
      – 確率モデルではないが、ソフトマックス関数を使って確率
        値に変換している




2011/9/3        ACL 2011 読み会@サイボウズラボ   9
問題設定

• 与えられた特徴量ベクトル������に対して、クラス分布
  ������(������|������)を推定する
      –    ここで一つのクラスは一つの語彙に相当する
      –    特徴量ベクトル ������ = (������1 , … , ������������ )
      –    特徴量はバイナリを仮定 (������������ ∈ *0,1+)
      –    各特徴量は「直前の単語列が”* Thompson said”である」、
           「4-8単語前までに”conference”が出現」などを意味する
• ここで特徴量ベクトルの次元は非常に大きいが、ア
  クティブな(非ゼロ)なものの数は少ない
      – 例えば先程の例では17個


2011/9/3             ACL 2011 読み会@サイボウズラボ    10
VMM (Variable mixture model)

• 各������������ ごとに������(������|������������ )を定める
• さらに特徴量ごとに予測の強さ������������ ∈ ������を定める
• このとき������(������|������, ������)を次のようにモデル化する




2011/9/3           ACL 2011 読み会@サイボウズラボ   11
最大エントロピーとの比較

• (2)式を変形すると最大エントロピーの式に近い形に
  なる




2011/9/3      ACL 2011 読み会@サイボウズラボ   12
最大エントロピーとの比較




• 最大エントロピーにおいては規格化定数の計算量
  がクラス数(語彙数)に比例する
• 一方VMMでは計算量は有効な特徴量の数に比例
  する
      – クラス数によらない


2011/9/3        ACL 2011 読み会@サイボウズラボ   13
������(������������ |������������ )の推定

• ここに関しては決定的に行う
• absolute discountを使ったsmoothing
• 特徴量������������ がアクティブだったときに������������ である確率




2011/9/3    ACL 2011 読み会@サイボウズラボ   14
������の推定




• 最尤推定を行う
• パラメータの推定アルゴリズムにはSGA (Stochastic
  gradient ascent)を使う
      – なお、パラメータの推定では全データ点を一回舐めるだけ
        で十分であった。
      – 逆に複数回見た場合、過学習の傾向が見られた



2011/9/3       ACL 2011 読み会@サイボウズラボ   15
leave-one-out

• 勾配計算においてデータ点を取ってきたときに
  ������(������������ |������������ )の計算に取ってきたデータ点の寄与をとり
  のぞいて計算する
      – これにより汎化性能が向上する




2011/9/3       ACL 2011 読み会@サイボウズラボ    16
実験

• RCV1データを利用
   – 総語彙数 30367 (week 31において頻度4以下の単語はout-of-
     vocabulary(UNK)に変換)
   – week 50のデータをディベロップメントセット、week 51のデータ
     をテストセットとする
   – 訓練データとしては4種類のサイズのデータを用意
            • D1 (week 1, 3.1M words), D2 (week 1-3, 10M words), D3(week 1-10,
              37M words), D4 (week 1-30, 113M words)




 2011/9/3                       ACL 2011 読み会@サイボウズラボ                         17
利用するモデル

• KN : modified Kneser-Ney
• VM-BA (basic) : N-gram特徴量のみを利用
• VM-SR (short range) : BAに加え、skip N-gramとN個
  前までの単語をBOFにした特徴量を利用
• VM-LR (long range) : SRに加え、長距離の単語をBOF
  にした特徴量を利用




2011/9/3        ACL 2011 読み会@サイボウズラボ       18
実験結果

• 長距離の特徴量を使った
  VM-LRのperplexityが最も小
  さくなっている
• D4においてVM-LRの学習時
  間が30分に対してKNは6分
• D3,D4においてN=5がないの
  はメモリ不足のため




 2011/9/3      ACL 2011 読み会@サイボウズラボ   19
実は結果をプロットしてみると(論文にはない)




• コーパスサイズを増やしていくと、モデルによる
  perplexityの違いは少なくなる(cf [Brants+ 2007])

2011/9/3       ACL 2011 読み会@サイボウズラボ        20
まとめ

• スケーラブルかつ豊富な特徴量を利用できる確率
  的分類器のモデルであるVMMを提案した
      – 加えて実装は単純
• 言語モデルに適応したところ、Nグラムモデルである
  Kneser-Neyよりも高い精度となった
• 今後はメモリの使用量の改善などを行いたい




2011/9/3       ACL 2011 読み会@サイボウズラボ   21
参考文献

• R. Rosenfeld : A maximum entropy approach to adaptive
  statistical language modeling. Computer, speech and
  language. 1996
• Y. Bengio+ : A neural probabilistic language model.
  Journal of Machine Learning Research. 2003
• A. Mnih and G. Hinton : A scalable hierachical distributed
  language model. NIPS. 2008
• A. Van den Bosch : Scalable classification-based word
  prediction and confusible correction. Traitement
  automatique des langues. 2005
• T. Brants+ : Large Language Models in Machine
  Translation. EMNLP. 2007

2011/9/3              ACL 2011 読み会@サイボウズラボ                 22

More Related Content

Similar to A scalable probablistic classifier for language modeling: ACL 2011 読み会

Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)
Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)
Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)Ohsawa Goodfellow
 
EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...
EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...
EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...Yuki Tomo
 
Chainer with natural language processing hands on
Chainer with natural language processing hands onChainer with natural language processing hands on
Chainer with natural language processing hands onOgushi Masaya
 
[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...
[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...
[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...Hayahide Yamagishi
 
Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...
Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...
Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...Naoaki Okazaki
 
Approximate Scalable Bounded Space Sketch for Large Data NLP
Approximate Scalable Bounded Space Sketch for Large Data NLPApproximate Scalable Bounded Space Sketch for Large Data NLP
Approximate Scalable Bounded Space Sketch for Large Data NLPKoji Matsuda
 
Mplusの使い方 初級編
Mplusの使い方 初級編Mplusの使い方 初級編
Mplusの使い方 初級編Hiroshi Shimizu
 
MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)
MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)
MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)Webpla LLC.
 
一般化線形混合モデル入門の入門
一般化線形混合モデル入門の入門一般化線形混合モデル入門の入門
一般化線形混合モデル入門の入門Yu Tamura
 
Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...
Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...
Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...Shin Kanouchi
 
ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...
ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...
ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...Yusuke Oda
 
Probabilistic fasttext for multi sense word embeddings
 Probabilistic fasttext for multi sense word embeddings Probabilistic fasttext for multi sense word embeddings
Probabilistic fasttext for multi sense word embeddingsMakoto Takenaka
 
TensorFlow math ja 05 word2vec
TensorFlow math ja 05 word2vecTensorFlow math ja 05 word2vec
TensorFlow math ja 05 word2vecShin Asakawa
 
論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus
論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus
論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus広樹 本間
 
言語資源と付き合う
言語資源と付き合う言語資源と付き合う
言語資源と付き合うYuya Unno
 
Reusing weights in subword aware neural language models
Reusing weights in subword aware neural language modelsReusing weights in subword aware neural language models
Reusing weights in subword aware neural language models広樹 本間
 
Character word lstm language models
Character word lstm language modelsCharacter word lstm language models
Character word lstm language models浩気 西山
 
Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介
Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介
Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介Kosuke Futamata
 

Similar to A scalable probablistic classifier for language modeling: ACL 2011 読み会 (20)

Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)
Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)
Natural Language Processing (Almost) from Scratch(第 6 回 Deep Learning 勉強会資料; 榊)
 
EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...
EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...
EMNLP 2015 読み会 @ 小町研 "Morphological Analysis for Unsegmented Languages using ...
 
Chainer with natural language processing hands on
Chainer with natural language processing hands onChainer with natural language processing hands on
Chainer with natural language processing hands on
 
[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...
[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...
[ACL2018読み会資料] Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use C...
 
Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...
Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...
Pennington, Socher, and Manning. (2014) GloVe: Global vectors for word repres...
 
Approximate Scalable Bounded Space Sketch for Large Data NLP
Approximate Scalable Bounded Space Sketch for Large Data NLPApproximate Scalable Bounded Space Sketch for Large Data NLP
Approximate Scalable Bounded Space Sketch for Large Data NLP
 
Mplusの使い方 初級編
Mplusの使い方 初級編Mplusの使い方 初級編
Mplusの使い方 初級編
 
Extract and edit
Extract and editExtract and edit
Extract and edit
 
MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)
MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)
MAごころを、君に - #7 ChatGPT勉強会(2023-03-28)
 
一般化線形混合モデル入門の入門
一般化線形混合モデル入門の入門一般化線形混合モデル入門の入門
一般化線形混合モデル入門の入門
 
Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...
Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...
Bilingual Correspondence Recursive Autoencoders for Statistical Machine Trans...
 
ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...
ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...
ACL Reading @NAIST: Fast and Robust Neural Network Joint Model for Statistica...
 
Probabilistic fasttext for multi sense word embeddings
 Probabilistic fasttext for multi sense word embeddings Probabilistic fasttext for multi sense word embeddings
Probabilistic fasttext for multi sense word embeddings
 
TensorFlow math ja 05 word2vec
TensorFlow math ja 05 word2vecTensorFlow math ja 05 word2vec
TensorFlow math ja 05 word2vec
 
論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus
論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus
論文紹介 JParaCrawl: A Large Scale Web-Based English-Japanese Parallel Corpus
 
言語資源と付き合う
言語資源と付き合う言語資源と付き合う
言語資源と付き合う
 
Reusing weights in subword aware neural language models
Reusing weights in subword aware neural language modelsReusing weights in subword aware neural language models
Reusing weights in subword aware neural language models
 
Character word lstm language models
Character word lstm language modelsCharacter word lstm language models
Character word lstm language models
 
Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介
Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介
Neural G2Pの最新動向 SIGMORPHON及び関連緩急の紹介
 
2016word embbed
2016word embbed2016word embbed
2016word embbed
 

More from 正志 坪坂

KDD 2016勉強会 Deep crossing
KDD 2016勉強会 Deep crossingKDD 2016勉強会 Deep crossing
KDD 2016勉強会 Deep crossing正志 坪坂
 
Deeplearning輪読会
Deeplearning輪読会Deeplearning輪読会
Deeplearning輪読会正志 坪坂
 
WSDM 2016勉強会 Geographic Segmentation via latent factor model
WSDM 2016勉強会 Geographic Segmentation via latent factor modelWSDM 2016勉強会 Geographic Segmentation via latent factor model
WSDM 2016勉強会 Geographic Segmentation via latent factor model正志 坪坂
 
Deeplearning勉強会20160220
Deeplearning勉強会20160220Deeplearning勉強会20160220
Deeplearning勉強会20160220正志 坪坂
 
OnlineMatching勉強会第一回
OnlineMatching勉強会第一回OnlineMatching勉強会第一回
OnlineMatching勉強会第一回正志 坪坂
 
Tokyowebmining ctr-predict
Tokyowebmining ctr-predictTokyowebmining ctr-predict
Tokyowebmining ctr-predict正志 坪坂
 
Riak Search 2.0を使ったデータ集計
Riak Search 2.0を使ったデータ集計Riak Search 2.0を使ったデータ集計
Riak Search 2.0を使ったデータ集計正志 坪坂
 
Contexual bandit @TokyoWebMining
Contexual bandit @TokyoWebMiningContexual bandit @TokyoWebMining
Contexual bandit @TokyoWebMining正志 坪坂
 
Introduction to contexual bandit
Introduction to contexual banditIntroduction to contexual bandit
Introduction to contexual bandit正志 坪坂
 
確率モデルを使ったグラフクラスタリング
確率モデルを使ったグラフクラスタリング確率モデルを使ったグラフクラスタリング
確率モデルを使ったグラフクラスタリング正志 坪坂
 
Big Data Bootstrap (ICML読み会)
Big Data Bootstrap (ICML読み会)Big Data Bootstrap (ICML読み会)
Big Data Bootstrap (ICML読み会)正志 坪坂
 

More from 正志 坪坂 (20)

Recsys2018 unbiased
Recsys2018 unbiasedRecsys2018 unbiased
Recsys2018 unbiased
 
WSDM2018Study
WSDM2018StudyWSDM2018Study
WSDM2018Study
 
Recsys2016勉強会
Recsys2016勉強会Recsys2016勉強会
Recsys2016勉強会
 
KDD 2016勉強会 Deep crossing
KDD 2016勉強会 Deep crossingKDD 2016勉強会 Deep crossing
KDD 2016勉強会 Deep crossing
 
Deeplearning輪読会
Deeplearning輪読会Deeplearning輪読会
Deeplearning輪読会
 
WSDM 2016勉強会 Geographic Segmentation via latent factor model
WSDM 2016勉強会 Geographic Segmentation via latent factor modelWSDM 2016勉強会 Geographic Segmentation via latent factor model
WSDM 2016勉強会 Geographic Segmentation via latent factor model
 
Deeplearning勉強会20160220
Deeplearning勉強会20160220Deeplearning勉強会20160220
Deeplearning勉強会20160220
 
OnlineMatching勉強会第一回
OnlineMatching勉強会第一回OnlineMatching勉強会第一回
OnlineMatching勉強会第一回
 
Recsys2015
Recsys2015Recsys2015
Recsys2015
 
KDD 2015読み会
KDD 2015読み会KDD 2015読み会
KDD 2015読み会
 
Recsys2014 recruit
Recsys2014 recruitRecsys2014 recruit
Recsys2014 recruit
 
EMNLP2014_reading
EMNLP2014_readingEMNLP2014_reading
EMNLP2014_reading
 
Tokyowebmining ctr-predict
Tokyowebmining ctr-predictTokyowebmining ctr-predict
Tokyowebmining ctr-predict
 
KDD2014_study
KDD2014_study KDD2014_study
KDD2014_study
 
Riak Search 2.0を使ったデータ集計
Riak Search 2.0を使ったデータ集計Riak Search 2.0を使ったデータ集計
Riak Search 2.0を使ったデータ集計
 
Contexual bandit @TokyoWebMining
Contexual bandit @TokyoWebMiningContexual bandit @TokyoWebMining
Contexual bandit @TokyoWebMining
 
Introduction to contexual bandit
Introduction to contexual banditIntroduction to contexual bandit
Introduction to contexual bandit
 
確率モデルを使ったグラフクラスタリング
確率モデルを使ったグラフクラスタリング確率モデルを使ったグラフクラスタリング
確率モデルを使ったグラフクラスタリング
 
Big Data Bootstrap (ICML読み会)
Big Data Bootstrap (ICML読み会)Big Data Bootstrap (ICML読み会)
Big Data Bootstrap (ICML読み会)
 
Tokyowebmining2012
Tokyowebmining2012Tokyowebmining2012
Tokyowebmining2012
 

A scalable probablistic classifier for language modeling: ACL 2011 読み会

  • 1. ACL2011読み会 坪坂 正志 2011/9/3@サイボウズラボ 2011/9/3 ACL 2011 読み会@サイボウズラボ 1
  • 2. 紹介論文 • Joel Lang : A scalable probablistic classifier for language modeling. ACL. 2011 – 確率的識別器を使った言語モデルに関する論文 – Kneser-NeyのようなNグラムモデルに比べ、長距離の特徴量 などを利用できる – 同様に識別器を使った先行研究と違い、語彙数30367、1億 語以上のコーパスに対してもスケールする 2011/9/3 ACL 2011 読み会@サイボウズラボ 2
  • 3. 言語モデル Happy families are all alike; every unhappy 次に来る単語は? 2011/9/3 ACL 2011 読み会@サイボウズラボ 3
  • 4. 言語モデル Happy families are all alike; every unhappy 次に来る単語は? • 例えばtrigramモデルではP(word | every unhappy)を 計算する 2011/9/3 ACL 2011 読み会@サイボウズラボ 4
  • 5. 言語モデル Happy families are all alike; every unhappy 次に来る単語は? • 例えばtrigramモデルではP(word | every unhappy)を 計算する • でも離れた単語に注目すると、より次の単語の予測 精度が高くなる可能性がある 2011/9/3 ACL 2011 読み会@サイボウズラボ 5
  • 6. トリガーモデル • Nグラムの範囲を超えた長距離の単語の影響を組 み入れた言語モデル • 詳しくは 2011/9/3 ACL 2011 読み会@サイボウズラボ 6
  • 7. どういう特徴量を使うか • これまでの文脈が ” Yesterday at the press conference Mr Thompson said”の場合 通常の3-gram 3-gramの一部をスキップ 3個前までの出現単語 4-8個前までの出現単語 2011/9/3 ACL 2011 読み会@サイボウズラボ 7
  • 8. 先行研究 • [Rosenfeld 1996] – 最大エントロピー分類器を使った言語モデル – パラメータの推定に非常に時間がかかる • [Bengio+ 2003] – ニューラルネットを使った言語モデル – これも大きなデータセットに適応するのは困難 • [Mnih and Hinton 2008] – 語彙数20000, 1400万語のデータセットに対して適用 • [Van den Bosch 2005] – 決定木ベースの手法 – 一億語以上のデータセットに対して適用可能 – 確率モデルではないのでperplexityでの比較が困難 2011/9/3 ACL 2011 読み会@サイボウズラボ 8
  • 9. 先行研究 (論文では触れてない) • 岡野原, 辻井 : 行列分解による多クラス分類とその 応用. 言語処理学会. 2010 – 単語数5379万、語彙数116万のデータに対して適用 – 確率モデルではないが、ソフトマックス関数を使って確率 値に変換している 2011/9/3 ACL 2011 読み会@サイボウズラボ 9
  • 10. 問題設定 • 与えられた特徴量ベクトル������に対して、クラス分布 ������(������|������)を推定する – ここで一つのクラスは一つの語彙に相当する – 特徴量ベクトル ������ = (������1 , … , ������������ ) – 特徴量はバイナリを仮定 (������������ ∈ *0,1+) – 各特徴量は「直前の単語列が”* Thompson said”である」、 「4-8単語前までに”conference”が出現」などを意味する • ここで特徴量ベクトルの次元は非常に大きいが、ア クティブな(非ゼロ)なものの数は少ない – 例えば先程の例では17個 2011/9/3 ACL 2011 読み会@サイボウズラボ 10
  • 11. VMM (Variable mixture model) • 各������������ ごとに������(������|������������ )を定める • さらに特徴量ごとに予測の強さ������������ ∈ ������を定める • このとき������(������|������, ������)を次のようにモデル化する 2011/9/3 ACL 2011 読み会@サイボウズラボ 11
  • 13. 最大エントロピーとの比較 • 最大エントロピーにおいては規格化定数の計算量 がクラス数(語彙数)に比例する • 一方VMMでは計算量は有効な特徴量の数に比例 する – クラス数によらない 2011/9/3 ACL 2011 読み会@サイボウズラボ 13
  • 14. ������(������������ |������������ )の推定 • ここに関しては決定的に行う • absolute discountを使ったsmoothing • 特徴量������������ がアクティブだったときに������������ である確率 2011/9/3 ACL 2011 読み会@サイボウズラボ 14
  • 15. ������の推定 • 最尤推定を行う • パラメータの推定アルゴリズムにはSGA (Stochastic gradient ascent)を使う – なお、パラメータの推定では全データ点を一回舐めるだけ で十分であった。 – 逆に複数回見た場合、過学習の傾向が見られた 2011/9/3 ACL 2011 読み会@サイボウズラボ 15
  • 16. leave-one-out • 勾配計算においてデータ点を取ってきたときに ������(������������ |������������ )の計算に取ってきたデータ点の寄与をとり のぞいて計算する – これにより汎化性能が向上する 2011/9/3 ACL 2011 読み会@サイボウズラボ 16
  • 17. 実験 • RCV1データを利用 – 総語彙数 30367 (week 31において頻度4以下の単語はout-of- vocabulary(UNK)に変換) – week 50のデータをディベロップメントセット、week 51のデータ をテストセットとする – 訓練データとしては4種類のサイズのデータを用意 • D1 (week 1, 3.1M words), D2 (week 1-3, 10M words), D3(week 1-10, 37M words), D4 (week 1-30, 113M words) 2011/9/3 ACL 2011 読み会@サイボウズラボ 17
  • 18. 利用するモデル • KN : modified Kneser-Ney • VM-BA (basic) : N-gram特徴量のみを利用 • VM-SR (short range) : BAに加え、skip N-gramとN個 前までの単語をBOFにした特徴量を利用 • VM-LR (long range) : SRに加え、長距離の単語をBOF にした特徴量を利用 2011/9/3 ACL 2011 読み会@サイボウズラボ 18
  • 19. 実験結果 • 長距離の特徴量を使った VM-LRのperplexityが最も小 さくなっている • D4においてVM-LRの学習時 間が30分に対してKNは6分 • D3,D4においてN=5がないの はメモリ不足のため 2011/9/3 ACL 2011 読み会@サイボウズラボ 19
  • 20. 実は結果をプロットしてみると(論文にはない) • コーパスサイズを増やしていくと、モデルによる perplexityの違いは少なくなる(cf [Brants+ 2007]) 2011/9/3 ACL 2011 読み会@サイボウズラボ 20
  • 21. まとめ • スケーラブルかつ豊富な特徴量を利用できる確率 的分類器のモデルであるVMMを提案した – 加えて実装は単純 • 言語モデルに適応したところ、Nグラムモデルである Kneser-Neyよりも高い精度となった • 今後はメモリの使用量の改善などを行いたい 2011/9/3 ACL 2011 読み会@サイボウズラボ 21
  • 22. 参考文献 • R. Rosenfeld : A maximum entropy approach to adaptive statistical language modeling. Computer, speech and language. 1996 • Y. Bengio+ : A neural probabilistic language model. Journal of Machine Learning Research. 2003 • A. Mnih and G. Hinton : A scalable hierachical distributed language model. NIPS. 2008 • A. Van den Bosch : Scalable classification-based word prediction and confusible correction. Traitement automatique des langues. 2005 • T. Brants+ : Large Language Models in Machine Translation. EMNLP. 2007 2011/9/3 ACL 2011 読み会@サイボウズラボ 22