1 / 58

Linguistic Regularities in Sparse and Explicit Word Representations

Linguistic Regularities in Sparse and Explicit Word Representations. Omer Levy Yoav Goldberg Bar- Ilan University Israel. Papers in ACL 2014*. * Sampling error: +/- 100%. Neural Embeddings. Dense vectors Each dimension is a latent feature Common software package: word2vec

wilson
Download Presentation

Linguistic Regularities in Sparse and Explicit Word Representations

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Linguistic Regularities in Sparse and Explicit Word Representations Omer Levy Yoav Goldberg Bar-Ilan University Israel

  2. Papers in ACL 2014* * Sampling error: +/- 100%

  3. Neural Embeddings • Dense vectors • Each dimension is a latent feature • Common software package: word2vec • “Magic” king man woman queen (analogies)

  4. Representing words as vectors is not new!

  5. Explicit Representations (Distributional) • Sparse vectors • Each dimension is an explicit context • Common association metric: PMI, PPMI • Does the same “magic” work for explicit representations too? • Baroni et al. (2014) showed that embeddings outperform explicit, but…

  6. Questions • Are analogies unique to neural embeddings? Compare neural embeddings with explicit representations • Why does vector arithmetic reveal analogies? Unravel the mystery behind neural embeddings and their “magic”

  7. Background

  8. Mikolov et al. (2013a,b,c) • Neural embeddings have interesting geometries

  9. Mikolov et al. (2013a,b,c) • Neural embeddings have interesting geometries • These patterns capture “relational similarities” • Can be used to solve analogies: man is to woman as king is to queen

  10. Mikolov et al. (2013a,b,c) • Neural embeddings have interesting geometries • These patterns capture “relational similarities” • Can be used to solve analogies: is to as is to • Can be recovered by “simple” vector arithmetic:

  11. Mikolov et al. (2013a,b,c) • Neural embeddings have interesting geometries • These patterns capture “relational similarities” • Can be used to solve analogies: is to as is to • With simple vector arithmetic:

  12. Mikolov et al. (2013a,b,c)

  13. Mikolov et al. (2013a,b,c)

  14. Mikolov et al. (2013a,b,c) king man woman queen

  15. Mikolov et al. (2013a,b,c) Tokyo Japan France Paris

  16. Mikolov et al. (2013a,b,c) best good strong strongest

  17. Mikolov et al. (2013a,b,c) best good strong strongest vectors in

  18. Are analogies unique to neural embeddings?

  19. Are analogies unique to neural embeddings? • Experiment: compare embeddings to explicit representations

  20. Are analogies unique to neural embeddings? • Experiment: compare embeddings to explicit representations

  21. Are analogies unique to neural embeddings? • Experiment: compare embeddings to explicit representations • Learn different representations from the samecorpus:

  22. Are analogies unique to neural embeddings? • Experiment: compare embeddings to explicit representations • Learn different representations from the samecorpus: • Evaluate with the samerecovery method:

  23. Analogy Datasets • 4 words per analogy: is to as is to • Given 3 words: is to as is to • Guess the best suiting from the entire vocabulary • Excluding the question words • MSR:8000 syntactic analogies • Google:19,000 syntactic and semantic analogies

  24. Embedding vs Explicit (Round 1)

  25. Embedding vs Explicit (Round 1) Many analogies recovered by explicit, but many more by embedding.

  26. Why does vector arithmetic reveal analogies?

  27. Why does vector arithmetic reveal analogies? • We wish to find the closest to • This is done with cosine similarity: Problem: one similarity might dominate the rest.

  28. Why does vector arithmetic reveal analogies? • We wish to find the closest to

  29. Why does vector arithmetic reveal analogies? • We wish to find the closest to • This is done with cosine similarity:

  30. Why does vector arithmetic reveal analogies? • We wish to find the closest to • This is done with cosine similarity:

  31. Why does vector arithmetic reveal analogies? • We wish to find the closest to • This is done with cosine similarity: vector arithmetic similarity arithmetic

  32. Why does vector arithmetic reveal analogies? • We wish to find the closest to • This is done with cosine similarity: vector arithmetic similarity arithmetic

  33. Why does vector arithmetic reveal analogies? • We wish to find the closest to • This is done with cosine similarity: vector arithmetic similarityarithmetic

  34. Why does vector arithmetic reveal analogies? • We wish to find the closest to • This is done with cosine similarity: vector arithmetic similarityarithmetic royal? female?

  35. What does each similarity term mean? • Observe the joint features with explicit representations!

  36. Can we do better?

  37. Let’s look at some mistakes…

  38. Let’s look at some mistakes… England London Baghdad ?

  39. Let’s look at some mistakes… England London Baghdad Iraq

  40. Let’s look at some mistakes… England London Baghdad Mosul?

  41. The Additive Objective

  42. The Additive Objective

  43. The Additive Objective

  44. The Additive Objective

  45. The Additive Objective

  46. The Additive Objective • Problem: one similarity might dominate the rest • Much more prevalent in explicit representation • Might explain why explicit underperformed

  47. How can we do better?

  48. How can we do better? • Instead of adding similarities, multiply them!

  49. How can we do better? • Instead of adding similarities, multiply them!

More Related