Instructions to use fse/glove-twitter-100 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- fse
How to use fse/glove-twitter-100 with fse:
pip install "fse<2"
from fse import SIF, IndexedList, Vectors vectors = Vectors.from_pretrained("glove-twitter-100") model = SIF(vectors) sentences = IndexedList([["hello", "world"], ["fast", "sentence", "embeddings"]]) model.train(sentences) vector = model.sv[0] - Notebooks
- Google Colab
- Kaggle
GloVe Twitter (100 dimensions)
Pre-trained GloVe vectors for 1,193,514 words and tokens, trained on 2 billion tweets (27 billion tokens), uncased.
This is a gensim model, packaged for fse (Fast Sentence Embeddings), which turns word vectors into sentence vectors with CBOW averaging, SIF and uSIF.
Usage
This repository uses the fse 1.x API and requires fse<2.
For fse 2.0, choose a finished encoder from the classic model catalog.
See the migration guide before upgrading.
pip install "fse<2"
from fse import SIF, IndexedList, Vectors
vectors = Vectors.from_pretrained("glove-twitter-100")
model = SIF(vectors)
sentences = IndexedList([["hello", "world"], ["fast", "sentence", "embeddings"]])
model.train(sentences)
model.sv[0] # the vector of the first sentence
Vectors.from_pretrained("glove-twitter-100", mmap="r") memory-maps the vectors instead of loading them into RAM.
Files
| File | Content |
|---|---|
glove-twitter-100.model |
gensim KeyedVectors (vocabulary and metadata) |
glove-twitter-100.model.vectors.npy |
1,193,514 ร 100 float32 vectors (477 MB) |
Source and license
The vectors were published by the Stanford NLP Group with GloVe under the Public Domain Dedication and License. This repository redistributes them in the gensim format.
- Pennington, Socher and Manning (2014), GloVe: Global Vectors for Word Representation
About fse
fse is maintained by Dr. Oliver Borchers. Source code, documentation and the STS benchmark of all vector sets in this organization: github.com/oborchers/Fast_Sentence_Embeddings.
- Downloads last month
- 93