LiteLLMModelProviderAdv
The model picker that tells you what you'll pay before you spend a cent
- Litellm model
Every LLM pack for ComfyUI ships a model dropdown, and almost every dropdown is a lie within six months - the models get renamed, retired, or repriced, and you're left picking from a menu of ghosts. LiteLLMModelProviderAdv is this pack's attempt to fix that. It's the node you'll reach for first in ComfyUI_LiteLLM, not because it's clever, but because it's the one that stays honest about what you're about to spend.
It's a provider, not a completion node. You feed it nothing but a model choice, and it hands you a LITELLM_MODEL object that every other node in the pack (LiteLLMCompletion, the provider nodes, the agent stuff) understands. Think of it as the power outlet: pick a model, and everything downstream runs on it.
How it actually works
The dropdown you see is built two ways. If you've got an OPENAI_API_KEY in your environment, the node calls OpenAI's model list API live and builds the menu from what your account can actually use - skipping fine-tunes and non-chat models, paginating through the list, and remembering which models want max_completion_tokens instead of max_tokens (that's the o1/o3/gpt-5 "responses"-style quirk that breaks naive clients). No key? It falls back to a hard-coded menu of 39 entries, each one annotated with pricing.
That pricing annotation is the whole personality of this node. The choices look like openai/gpt-4o-mini (Input: $0.15/1M, Cached: $0.075/1M, Output: $0.60/1M tokens). When you hit run, the node strips the parenthetical and hands the bare model id downstream, so the pricing display never leaks into the actual API call.
The one input that matters
name- the model dropdown. That's it. This is the "Adv" in the name: the plainLiteLLMModelProvidernode exists too, but this one fetches live and shows costs. Same output type, more signal.
Output is a single Litellm model (LITELLM_MODEL), which plugs straight into any of the completion nodes, or into LiteLLMCompletionProvider for the agent/RAG pipelines.
Installing and running it
This ships as part of ComfyUI_LiteLLM, so you install the whole pack:
cd ComfyUI/custom_nodes
git clone https://github.com/Hopping-Mad-Games/ComfyUI_LiteLLM
cd ComfyUI_LiteLLM
pip install -r requirements.txt
Restart ComfyUI and you'll find the nodes under ETK/LLM/LiteLLM. Or skip the terminal: ComfyUI Manager, search "ComfyUI_LiteLLM", install. No model files to download for this node - it's pure API. You do need a real key. Set OPENAI_API_KEY (or ANTHROPIC_API_KEY, KLUSTER_API_KEY, whatever provider you pick) as an environment variable before starting ComfyUI; the pack reads env vars and never writes them into config files.
Where people get burned
Two things. First, the hard-coded fallback list still contains ghosts - the "pricing" strings are hard-coded too, and OpenAI reprices models without asking anyone. The live fetch fixes the availability problem when you have a key, but if you run it keyless the menu is only as fresh as the last release. Second, don't treat the prices as gospel for budget planning; they're a rough sanity check, not a bill. If you need a model that isn't on any list, that's what LiteLLMCustomEndpointProvider is for - you can type any model id and base URL by hand. That combo - live menu for the common case, manual override for the edge case - is the honest way to run this pack.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| name | COMBO | openai/gpt-3.5-turbo ($2.00/1M tokens) | 39 options: openai/gpt-3.5-turbo ($2.00/1M tokens), openai/gpt-3.5-turbo-16k (Input: $3.00/1M, Output: $4.00/1M tokens), openai/gpt-4 (Input: $30/1M, Output: $60/1M tokens (8K)), openai/gpt-4-32k (Input: $60/1M, Output: $120/1M tokens (32K)), openai/gpt-4o (Input: $2.50/1M, Cached: $1.25/1M, Output: $10.00/1M tokens), openai/gpt-4o-2024-08-06 (Input: $2.50/1M, Cached: $1.25/1M, Output: $10.00/1M tokens), +33 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| Litellm model | LITELLM_MODEL | — |