词嵌入 (英語:Word embedding )是自然语言处理 (NLP)中语言模型 与表征学习 技术的统称。概念上而言,它是指把一个维数为所有词的数量的高维空间嵌入 到一个维数低得多的连续向量空间 中,每个单词或词组被映射为实数 域 上的向量。
词嵌入的方法包括人工神经网络 [ 1] 、对词语同现矩阵 降维 [ 2] [ 3] [ 4] 、機率模型 [ 5] 以及单词所在上下文的显式表示等。[ 6]
在底层输入中,使用词嵌入来表示词组的方法极大提升了NLP中语法分析器 [ 7] 和文本情感分析 等的效果。[ 8]
发展历程
词嵌入技术起源于2000年。约书亚·本希奥 等人在一系列论文中使用了神经機率语言模型(Neural probabilistic language models)使机器“习得词语的分布式表示(learning a distributed representation for words)”,从而达到将词语空间降维的目的。[ 9] 罗维斯(Roweis)与索尔(Saul)在《科学 》上发表了用 局部线性嵌入 (LLE)来学习高维数据结构的低维表示方法[ 10] 。这个领域开始时稳步发展,在2010年后突飞猛进;一定程度上而言,这是因为这段时间里向量的品質与模型的训练速度有极大的突破。
词嵌入领域的分支繁多,有许多学者致力于其研究。2013年,谷歌 一个托马斯·米科洛维(Tomas Mikolov)领导的团队发明了一套工具word2vec 来进行词嵌入,训练向量空间模型的速度比以往的方法都快。[ 11] 许多新兴的词嵌入基于人工神经网络 ,而不是过去的n元语法 模型和非监督式学习 。[ 12]
生物序列中的应用:BioVectors
阿斯加里(Asgari)和莫夫拉德(Mofrad)提出了生物信息学 中生物序列(DNA、RNA和蛋白质等)基于n元语法的词嵌入技术。[ 13] bio-vectors(BioVec)表示生物序列的统称,protein-vectors(ProtVec)表示蛋白质(氨基酸 序列),gene-vectors(GeneVec)表示基因序列。BioVec在蛋白质组学 与基因组学 的深度学习 中有广泛应用。他们提出的结果表明,BioVectors可描述生物化学 与生物物理学 意义下生物序列的基本模式。[ 13]
Thought vectors
将词嵌入扩展到对句子或整个文本的嵌入后得到的结果称为 Thought vectors 。部分研究者期望用Thought vectors来提升机器翻译 的质量。[ 14] [ 15]
软件实现
使用词嵌入技术的训练软件包括托马斯·米科洛维的Word2vec 、斯坦福大学 的GloVe [ 16] 和Deeplearning4j 。主成分分析 (PCA)和t-分布邻域嵌入算法 (t-SNE)也可以用来对词语空间降维,并实现词嵌入的可视化与词义感应 。[ 17]
参见
参考文献
^ Mikolov, Tomas; Sutskever, Ilya; Chen, Kai; Corrado, Greg; Dean, Jeffrey. Distributed Representations of Words and Phrases and their Compositionality. 2013. arXiv:1310.4546 [cs.CL ].
^ Lebret, Rémi; Collobert, Ronan. Word Emdeddings through Hellinger PCA. 2013. arXiv:1312.5542 [cs.CL ].
^ Levy, Omer; Goldberg, Yoav. Neural Word Embedding as Implicit Matrix Factorization (PDF) . NIPS. 2014 [2016-12-28 ] . (原始内容存档 (PDF) 于2016-11-14).
^ Li, Yitan; Xu, Linli. Word Embedding Revisited: A New Representation Learning and Explicit Matrix Factorization Perspective (PDF) . Int'l J. Conf. on Artificial Intelligence (IJCAI). 2015 [2016-12-28 ] . (原始内容 (PDF) 存档于2015-09-06).
^ Globerson, Amir. Euclidean Embedding of Co-occurrence Data (PDF) . Journal of Machine learning research. 2007 [2016-12-28 ] . (原始内容 (PDF) 存档于2016-09-21).
^ Levy, Omer; Goldberg, Yoav. Linguistic Regularities in Sparse and Explicit Word Representations (PDF) . CoNLL: 171–180. 2014 [2016-12-28 ] . (原始内容 (PDF) 存档于2017-09-25).
^ Socher, Richard; Bauer, John; Manning, Christopher; Ng, Andrew. Parsing with compositional vector grammars (PDF) . Proc. ACL Conf. 2013 [2016-12-28 ] . (原始内容 (PDF) 存档于2016-08-11).
^ Socher, Richard; Perelygin, Alex; Wu, Jean; Chuang, Jason; Manning, Chris; Ng, Andrew; Potts, Chris. Recursive Deep Models for Semantic Compositionality Over a Sentiment Treebank (PDF) . EMNLP. 2013 [2016-12-28 ] . (原始内容存档 (PDF) 于2016-12-28).
^ A Neural Probabilistic Language Model : 1. [2016-12-28 ] . doi:10.1007/3-540-33486-6_6 . (原始内容存档 于2017-01-17).
^ Roweis, Sam T.; Saul, Lawrence K. Nonlinear Dimensionality Reduction by Locally Linear Embedding . Science. 2000, 290 (5500): 2323 [2016-12-28 ] . Bibcode:2000Sci...290.2323R . PMID 11125150 . doi:10.1126/science.290.5500.2323 . (原始内容存档 于2016-12-06).
^ word2vec . [2016-12-28 ] . (原始内容 存档于2017-02-11).
^ A Scalable Hierarchical Distributed Language Model . [2016-12-28 ] . (原始内容 存档于2016-08-06).
^ 13.0 13.1 Asgari, Ehsaneddin; Mofrad, Mohammad R.K. Continuous Distributed Representation of Biological Sequences for Deep Proteomics and Genomics . PloS one. 2015, 10 (11): e0141287 [2020-09-19 ] . Bibcode:2015PLoSO..1041287A . doi:10.1371/journal.pone.0141287 . (原始内容存档 于2020-08-15).
^ Kiros, Ryan; Zhu, Yukun; Salakhutdinov, Ruslan; Zemel, Richard S.; Torralba, Antonio; Urtasun, Raquel; Fidler, Sanja. skip-thought vectors. 2015. arXiv:1506.06726 [cs.CL ].
^ thoughtvectors . [2016-12-28 ] . (原始内容 存档于2017-02-11).
^ GloVe . [2016-12-28 ] . (原始内容存档 于2016-12-19).
^ Ghassemi, Mohammad; Mark, Roger; Nemati, Shamim. A Visualization of Evolving Clinical Sentiment Using Vector Representations of Clinical Notes (PDF) . Computing in Cardiology. 2015 [2016-12-28 ] . (原始内容 (PDF) 存档于2016-05-31).