Path | pimlico.modules.input.embeddings.fasttext |
Executable | yes |
Reads in embeddings from the FastText format, storing them in the format used internally in Pimlico for embeddings.
Can be used, for example, to read the pre-trained embeddings offered by Facebook AI.
Currently only reads the text format (.vec
), not the binary format (.bin
).
pimlico.modules.input.embeddings.fasttext_gensim
:An alternative reader that uses Gensim's FastText format reading code and permits reading from the binary format, which contains more information.
No inputs
Name | Type(s) |
---|---|
embeddings | ~pimlico.datatypes.embeddings.Embeddings |
Name | Description | Type |
---|---|---|
path | (required) Path to the FastText embedding file | string |
limit | Limit to the first N words. Since the files are typically ordered from most to least frequent, this limits to the N most common words | int |