Nodes/ComfyUI-WordEmbeddings/WordEmbeddings: Loader
ComfyUI Node

WordEmbeddings: Loader

Where every word-embedding workflow starts (and why the first run takes forever)

By jtrue·Created about a year ago·Updated about a year ago· 1
WordEmbeddings: Loader
    • we_model
    model_nameglove-wiki-gigaword-50

    This is the node that makes the rest of jtrue/ComfyUI-WordEmbeddings do anything. One dropdown, one output, zero configuration - pick a model and it hands you a we_model handle that every other node in the pack (Neighbors, Equation, the Axis family, Centrality) expects on its left side. If you came here from a tutorial that says "start with a Loader," this is the Loader.

    What you're loading is not a checkpoint or a LoRA. It's a static word embedding: GloVe or word2vec vectors that map words to positions in a mathematical space where "king − man + woman ≈ queen" actually computes. This is 2013-era NLP tech, and the pack leans into it deliberately. Nothing here talks to an API, nothing needs a key, and nothing touches your diffusion model - the numbers these nodes produce describe word meaning as GloVe learned it, which is a different space from what your CLIP or LLM text encoder sees. The KB makes this exact distinction when it warns that a textual-inversion embedding is locked to whichever encoder it was trained against; the same logic applies here, in reverse. You get an honest, transparent lens on semantics, not a shortcut into the sampler.

    How it works

    The dropdown is populated live from gensim.downloader - the code asks gensim for its model registry and fills the list with whatever's available, with glove-wiki-gigaword-50 forced to the top as the default. On the first run it downloads the selected model into your local gensim-data cache; every run after that loads straight from disk. That's the whole mechanism, and it's also the whole source of your pain.

    The inputs that matter

    There's exactly one required input: model_name, an enum with 13 choices. The ones you'll actually see:

    • glove-wiki-gigaword-50 (default) - tiny, fast, 50 dimensions. Perfect for learning the nodes; the default for a reason.
    • glove-wiki-gigaword-100/200/300 - more dimensions, better neighbors, slower first download.
    • glove-twitter-25/50/100/200 - same GloVe method, trained on tweets. Good for slang.
    • word2vec-google-news-300 - the classic, huge (about 1.6 GB), and the one people are usually thinking of when they say "word2vec."
    • fasttext-wiki-news-subwords-300, fasttext-crawl-300d-2M - fastText handles out-of-vocabulary words via subwords, which is genuinely nice when your token isn't in GloVe's vocab.
    • conceptnet-numberbatch-17-06-300, word2vec-ruscorpora-300 - niche; the latter is Russian.

    The output is we_model (WE_MODEL), which you wire straight into any analysis node.

    Installation

    Same story as the whole pack. Easiest path is ComfyUI Manager - search "ComfyUI-WordEmbeddings" and hit install. Or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/jtrue/ComfyUI-WordEmbeddings
    pip install gensim numpy
    

    Then restart ComfyUI. The heavy lifting here is gensim (requirements.txt pins gensim>=4.3.3 and numpy>=1.20), which is a chunky but normal install. The real dependency cost isn't the package - it's the model download, which happens on first use, not at install.

    Where people get burned

    The first-run download. Pick word2vec-google-news-300 on a fresh setup and your workflow hangs for a while downloading ~1.6 GB before the node returns anything. That's not a crash, and there's no progress bar - the log just sits there. Start with the 50-dim default, get the pipeline working, then scale up.

    Second gotcha: if you're offline, every model is unavailable, because gensim fetches them on demand. That's exactly what the Local Loader node in this pack is for - point it at a .kv or word2vec file you already have.

    Also keep expectations honest: this is a tiny pack with essentially no community footprint. If a workflow from a stranger references these nodes, you're probably running into a personal experiment - but the nodes are dependency-light and work as advertised.

    CategoryWordEmbeddings

    Inputs (1)

    NameTypeDefaultDescription
    model_nameCOMBOglove-wiki-gigaword-5013 options: glove-wiki-gigaword-50, fasttext-wiki-news-subwords-300, conceptnet-numberbatch-17-06-300, word2vec-ruscorpora-300, word2vec-google-news-300, glove-wiki-gigaword-100, +7

    Outputs (1)

    NameTypeDescription
    we_modelWE_MODEL