Fal Text-to-Text
A Claude Sonnet 4.5 node in ComfyUI — no local LLM required
- response
- info
Drop a node, pick [Anthropic] Claude Sonnet 4.5, and you've got a frontier LLM inside your ComfyUI graph - no GGUF quantization math, no Ollama server, no VRAM budget. Fal Text-to-Text is the pack's LLM node, and it routes through fal's OpenRouter endpoint, which is why the dropdown reads like a best-of list: Claude, GPT-5, Gemini 2.5 Pro, Llama 3.3, DeepSeek R1, Grok, Qwen, Mistral, plus fal's direct LLMs (Bytedance Seed, Nemotron). The curated list refreshes automatically, so new models surface without a code change.
Before you ditch your local setup: the honest split from the community's own experience is that a local abliterated 8B is still the right call for uncensored, offline, free-per-call prompt rewriting. Where this node wins is genuine frontier-chat quality - a Claude or GPT-5 that actually follows instructions - when you want that inside a workflow and don't care about the API.
Inputs and outputs
- model_id - the flat curated dropdown. Pick one model; no second picker. Entries look like
[Anthropic] Claude Sonnet 4.5and the fal-direct models merge in alongside the OpenRouter ones. - prompt - the actual job. Multiline.
- system_prompt - optional, multiline. Goes in as the system message for chat models,
instructionsfor the responses-style ones. - schema - the hidden superpower. Leave it empty for free-form text. Fill it with a comma-separated field list -
flux_ref_prompt, title, tags- and the response becomes a JSON object keyed by those fields, enforced via OpenRouter's strictresponse_format. One call, structured output. - seed - INT, default -1 (random).
Outputs: response (STRING) and info (STRING, the full JSON result).
How it works
The catalog is synthesized from OpenRouter's live model list, each row dispatching to fal's openrouter/router/openai/v1/chat/completions endpoint with the model ID injected into the payload. The schema widget turns into response_format: json_schema in strict mode. Pair the JSON output with the pack's JSON Extract nodes and one Claude call becomes five named STRING outputs feeding five different parts of your workflow - the classic "LLM writes the video prompts, the title, and the tags in one shot" pattern.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/modbender/ComfyUI-Fal-Gateway
pip install -r requirements.txt
export FAL_KEY=your_fal_key
Restart ComfyUI, find the pack under Fal-Gateway. One key for everything.
Gotchas
- Not every model honors the schema. Older or smaller models (Claude 3 Haiku, Llama 3.1 8B, Mistral Small) may ignore
response_formatand return prose anyway - the node sends a system-prompt hint as a fallback, but you should set adefaulton your JSON Extract node to circuit-break missing fields. - LLM nodes are the category that got weaponized once - ComfyUI_LLMVISION shipped credential-stealing malware and ended in a federal prosecution. This pack is open-source, widely-legible, and Apache 2.0, but the general rule stands: read what a node does before handing it your key.
- Token-priced. The cost badge shows the honest per-token rate rather than a fake total. Long reasoning models (DeepSeek R1) can burn real money on a single "improve this prompt" call.
- No key → "FAL_KEY not set" hard error.
This is the node to reach for when you need an actual frontier model doing real reasoning inside the graph - and to skip when a small local model would do, because the local one is free and offline.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| model_id | COMBO | 3 options: [fal-ai] Bytedance Seed V2 Mini, [nvidia] Nemotron 3 Nano Omni, [openrouter] OpenRouter [Enterprise] | |
| prompt | STRING | — | |
| system_prompt | STRING | — | |
| schema | STRING | — | |
| seed | INT | -1-1–4294967295 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| response | STRING | — |
| info | STRING | — |