Razv LLM Chat
Your ComfyUI graph, talking to Claude and Gemini in the cloud
- image
- response
The name says "LLM," but there's no model on your disk and nothing downloads. Razv LLM Chat is a REST client dressed up as a ComfyUI node: it takes your prompt and optionally an image, calls the Anthropic or Google API, and hands the text reply back to your workflow as a plain string. One node, two clouds, zero local inference. If you've been hunting for a way to make your graph actually think about what it just rendered - caption an image, critique a batch, rewrite your prompt before the next sampler pass - this is a small, readable way to bolt a frontier LLM onto it.
Set your expectations early: despite the "Chat" in the name, this is a one-shot call, not a conversation.
How it works
The entire pack is one file, and it's about as transparent as an API node gets. It builds the request payload, base64-encodes your image as a PNG, POSTs it to https://api.anthropic.com/v1/messages or Google's generativelanguage.googleapis.com, and pulls the text out of the response. No SDK, no auth library - plain requests with x-api-key and x-goog-api-key headers. Which cloud you hit is decided entirely by the model you pick in the dropdown.
The model list is hardcoded in the source (the README is dated November 2025): Sonnet 4.5, Opus 4.1, and Haiku 4.5 on the Anthropic side; Gemini 3 Pro Preview, 2.5 Pro, 2.5 Flash, and 2.5 Flash Lite on Google's. A model that launches later can't be typed in - you'd be editing source or waiting on an update.
The inputs that actually matter
The required set is api_key, model, prompt, max_tokens, temperature, seed, and timeout, with system_prompt and image optional. A beginner sets three of these and leaves the rest alone:
- api_key - paste an Anthropic or Google key directly, or leave it blank and let the node read
ANTHROPIC_API_KEY/CLAUDE_API_KEY(Claude) orGEMINI_API_KEY/GOOGLE_API_KEY(Gemini) from the environment. Blank field plus env var is the cleaner route for shared workflows. - model - the dropdown, defaulting to
claude-sonnet-4-5, the best speed/cost/intelligence balance. Opus if you need serious reasoning, Haiku if you're on a budget. - prompt - the multiline text you want processed.
image (optional) is where the "vision" in the README lives - wire any IMAGE output into it. Note the source silently takes only the first frame of a batch, so don't count on it iterating over an image set. seed is the quiet trap: it only does anything on Gemini models. Claude's API doesn't accept seeds - the tooltip says exactly that - so changing it on a Claude model changes nothing. max_tokens defaults to 4096 and can go to 200,000; temperature runs 0–2; timeout defaults to 500s and tops out at 3600 for long jobs.
The single output is a STRING named response. To actually see it, wire it into a text-display node (core Show Text or any text-view node) - otherwise you've made an expensive invisible computation.
Installing it
Via ComfyUI Manager, search razv-llm and install. Or the manual route:
cd ComfyUI/custom_nodes
git clone https://github.com/razvanmatei-sf/razv-llm.git
cd razv-llm
pip install -r requirements.txt
Then restart ComfyUI. Dependencies are light - requests, pydantic, Pillow, numpy<2.0.0, torch (already present with ComfyUI). No model files to fetch; the "model" lives on Anthropic's and Google's servers. The real cost is your API bill: Sonnet 4.5 runs about $3/$15 per million tokens, Opus $15/$75, Haiku $1/$5, with Gemini 2.5 Flash as the budget pick.
Gotchas worth knowing
- It's one-shot. No conversation history is carried between calls, so a "chat" is a single prompt→response round trip. For a back-and-forth you'd feed the previous
responseback into the prompt yourself. - Your image and prompt leave your machine. For a community whose whole identity is local generation, that's the thing to sit with before wiring a workflow to a hosted API.
- Model IDs rot. This node ships a frozen list; when Anthropic deprecates an alias or Google retires a preview, the dropdown goes stale until the author ships an update.
- Errors are the provider's messages. "API request failed with status 401" means the key is wrong; a Gemini 404 usually means the model isn't enabled for your key yet -
gemini-3-pro-previewis a preview, after all. Big images or long outputs can hit the default timeout, which is exactly what the timeout input exists for.
If you're new to LLM nodes in ComfyUI, this one is worth trusting partly because it's so small - in a corner of the ecosystem where an LLM/vision node once shipped malware (the ComfyUI_LLMVISION incident), a ~400-line file that only makes REST calls is about as auditable as it gets. It's the same "cloud API" family as a dozen other nodes, just with both clouds in one dropdown and no SDK cruft.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| api_key | STRING | — | |
| model | COMBO | claude-sonnet-4-5 | 10 options: claude-sonnet-4-5-20250929, claude-sonnet-4-5, claude-opus-4-1-20250805, claude-opus-4-1, claude-haiku-4-5-20251001, claude-haiku-4-5, +4 |
| prompt | STRING | — | |
| max_tokens | INT | 40961–200000 | — |
| temperature | FLOAT | 0.700–2 | — |
| seed | INT | 1-1–18446744073709550000 | Random seed for reproducible results. -1 for random seed. Note: Only works with Gemini models, Claude doesn't support seeds. |
| timeout | INT | 50010–3600 | Request timeout in seconds. Increase for large text processing (default: 500s) |
| system_promptopt | STRING | — | |
| imageopt | IMAGE | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| response | STRING | — |