LLM Call
The generic LLM caller that works with Ollama out of the box — no key, no account
- text
LLM Call is the engine of this pack's "type a sentence, get a diagram" workflow, but don't let the UML branding fool you - it's a straight-up text-in, text-out LLM caller. It takes a prompt, phones a chat model, and hands you the reply as a string. The pack ships it because the reply is meant to become diagram code, yet nothing here is diagram-specific: the text output will plug into anything that accepts a STRING in your graph.
The best part is the default. Provider is ollama, model is llama3.2, and there's no API key anywhere in sight. You install this, point it at a local Ollama install, and you're calling a real LLM for free. That's the honest reason this node beats wiring up a generic text node: the local path just works.
How it works
Under the hood it's httpx calls to the provider's chat API - nothing exotic. Each provider gets its own endpoint (/api/chat for Ollama, /chat/completions for OpenAI, /v1/messages for Anthropic, generateContent for Gemini). The negative_prompt input isn't a second prompt: it's turned into a system instruction along the lines of "Do NOT do the following: ...". That sounds backwards until you remember why it exists - the pack's other nodes produce diagram code, and models love to wrap it in ``` fences and add a friendly preface. A negative prompt is your leash.
A few genuinely useful details:
- Ollama: no key. Base URL defaults to
http://localhost:11434, override with theollama_base_urlwidget or theOLLAMA_BASE_URLenv var. The model dropdown is loaded live from your Ollama server, so if youollama pulla new model, hit Refresh on the node. - OpenAI / Anthropic / Gemini: paste a key into
api_key, or setOPENAI_API_KEY,ANTHROPIC_API_KEY, orGEMINI_API_KEYin the environment. Miss both and it raises an error that tells you exactly which env var it wants. It's a small thing, but way friendlier than a cryptic 401. - Negative prompt + prompt both go out on the same call, so you're not paying for two round trips.
What you actually set
Only a couple of inputs matter for a beginner: prompt (the thing you ask), provider, and model. api_key and ollama_base_url only matter for cloud providers or non-default Ollama setups. The output is text - connect it to UML Render's code_input and run, or use it for anything else that wants generated text.
Installing it
This is one of five nodes in the antoinebou12/ComfyUI-UML pack (MIT, published to the Comfy Registry). Install the pack, get all five:
comfy node install comfyui-uml
# or, manually:
cd ComfyUI/custom_nodes && git clone https://github.com/antoinebou12/ComfyUI-UML
pip install -r requirements.txt
Restart ComfyUI after installing. Dependencies are light - just httpx and kroki for the diagram side.
Where people get burned
- Ollama isn't running → connection refused. Run
ollama serve(or have the app open) before queuing. - Model not pulled → Ollama returns an error;
ollama pull llama3.2fixes it. - Cloud timeout - the HTTP timeout is 60 seconds. Big prompts on slow models can trip it, but for diagram generation you rarely hit that.
- There's also a hidden test mode: with
COMFY_UI_UML_MOCK_LLM=1set, the node returns a canned Mermaid snippet instead of calling anything. Handy if you want to test a workflow without an LLM running.
One honest caveat: this is a small, newer pack, not a household name like rgthree or Impact Pack. The author posts their own work on r/comfyui and publishes to the Registry, and the repo runs CI tests, but it's not battle-tested by thousands of users yet. Fine for a diagram side-quest in a workflow; don't build your whole pipeline around it.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| promptopt | STRING | — | |
| negative_promptopt | STRING | — | |
| api_keyopt | STRING | — | |
| provideropt | COMBO | ollama | 4 options: ollama, openai, anthropic, gemini |
| modelopt | COMBO | llama3.2 | 18 options: llama3.2, llama3.1, mistral, codellama, qwen2.5-coder, phi3, +12 |
| ollama_base_urlopt | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| text | STRING | — |