10. 2.3.2 文のベクトル表現
• 文 ������ → ベクトル ������ (������)
– 文書のベクトル表現とまったく同様
• 例題)下記2文をbag-of-words, bag-of-bigramsで表せ
– ������1 : “The pen is mightier than the sword.”
– ������2 : “The sword is mightier than the pen.”
– bag-of-words
������������������������������������ (������1 , ������2 ) = 1
11. 例題をbag-of-bigramsで
– ������1 : “The pen is mightier than the sword.”
– ������2 : “The sword is mightier than the pen.”
– bag-of-bigrams
������������������������������������ (������1 , ������2 ) = 5/6
bigramsになって順序が考慮されているのでsimが低くなる
12. 2.4.1 文書に対する前処理
• ストップワード
– the, is, have, take などの無視すべき単語
• 品詞タグ付け
– fly[動詞] と fly[名詞] を区別できる
– (語義の曖昧性解消)