GloVe 25-Dimensional Word Vectors Trained on Tweets

Represent words as vectors

Released in 2014 by the computer science department at Stanford University, this 25-dimensional representation is trained using an original method called Global Vectors (GloVe). It encodes 1,193,515 tokens as unique vectors, with all tokens outside the vocabulary encoded as the zero-vector. Token case is ignored.

Number of layers: 1 | Parameter count: 29,837,875 | Trained size: 132 MB |

Training Set Information

Examples

Resource retrieval

Get the pre-trained net:

In[1]:=
NetModel["GloVe 25-Dimensional Word Vectors Trained on Tweets"]
Out[1]=

Basic usage

Use the net to obtain a list of word vectors:

In[2]:=
vectors = NetModel["GloVe 25-Dimensional Word Vectors Trained on Tweets"][
  "hello world"]
Out[2]=

Obtain the dimensions of the vectors:

In[3]:=
Dimensions[vectors]
Out[3]=

Use the embedding layer inside a NetChain:

In[4]:=
chain = NetChain[{NetModel[
    "GloVe 25-Dimensional Word Vectors Trained on Tweets"], LongShortTermMemoryLayer[10]}]
Out[4]=

Requirements

Wolfram Language 11.2 (September 2017) or above

Resource History

Reference