List Models | Ollama Nodes
See every model Ollama has installed, right in your workflow
- model_list
- model_list_as_string
ListModels does one tiny thing: it asks your local Ollama server what models are installed and returns the names. No model loading, no generation, no downloads. It's the "ollama list but inside the graph" node, and it exists for a boring but real reason - hardcoding model names in a workflow is a recipe for a broken workflow.
Why you'd reach for it
If you download someone's workflow and it points at a model you don't have, you get an error and a scavenger hunt. ListModels makes the workflow tell you what's available instead. Wire it to a ShowText node and you can see your installed models at a glance. Wire model_list_as_string into a text input somewhere and you can even surface available models inside a prompt - say, asking GenerateOllama to pick which of your models to use.
It's also a genuinely handy sanity check. Did your ollama pull actually complete? Drag in a ListModels node and run it. The output is ground truth from the server, not what you think you installed.
The realistic caveat: on its own it saves you maybe ten seconds. Its real value is in workflows you share or templates you reuse, where a dynamic model list beats a hardcoded string.
How it works
The node calls ollama.list() on the server at 127.0.0.1:11434 and extracts each model's name field - the model:tag strings like llava:latest or phi3:latest. It always re-executes, so it picks up new pulls without you restarting anything.
One input, delimiter, defaults to , - it controls how the model names are joined into the string output.
Two outputs:
model_list- a proper LIST of model names. This is the one to wire into anything that expects a list.model_list_as_string- the same names joined by your delimiter as a single STRING, for text inputs and display.
Installing it
ComfyUI Manager → search "comfyui-ollama-nodes" → Install → restart, or:
cd ComfyUI/custom_nodes
git clone https://github.com/slyt/comfyui-ollama-nodes
cd comfyui-ollama-nodes
pip install -r requirements.txt
Like every node in this pack, it assumes Ollama is running at 127.0.0.1:11434. No Ollama server, no output - just an error in the console.
Small gotchas
- The delimiter's newline escape is half-baked. Type
\\nexpecting line breaks and the code just prints it to the console; you'll get literal\nin your string. For readable output, prefer wiringmodel_listto a display node rather than fighting the delimiter. - The output only lists what's installed locally, not what's available on the Ollama library. If you want more models, that's the job of the pack's PullModel node.
- Since the node hits the network (localhost, but still a server round-trip), it adds a beat to any workflow it's in. That's fine - it's a query node, not something you chain a hundred times.
Thin node, but not useless. It's the kind of plumbing that makes a shared workflow actually run on someone else's machine, and it pairs naturally with PullModel for "check if I have it, pull it if I don't" patterns.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| delimiter | STRING | , | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| model_list | LIST | — |
| model_list_as_string | STRING | — |