GROQ LLM (Advanced)
What it's really doing (and why it won't run yet)
- context_documents
- response
Let's start with the part the marketing skips: this node, as shipped, almost certainly won't run on your ComfyUI. It's called "GROQ LLM (Advanced)" and it looks like a full-featured text generation widget, but the actual code behind it is a wrapper around a single API call - and even that call never gets reached because the function's signature doesn't match the inputs the UI hands it. I'll explain what it's for first, because the idea is genuinely useful, and then show you exactly where it falls over.
What it's reaching for
GROQ is a cloud inference provider known for stupid-fast responses on open models - their LPU hardware runs Llama and Mixtral far faster than any local setup you own, and there's a free tier. The appeal inside ComfyUI: an LLM in the loop without loading a model into VRAM. You've seen the pattern in the ecosystem - an LLM that expands a terse prompt into a rich one, names your LoRA, or writes image descriptions - feeding an LLM-encoded text model that's now the norm for local generation. This node is that idea: type a prompt, get text back, wire it into your graph.
No model files, no VRAM cost, no GPU hit. The only "model" is an API key from console.groq.com, pasted into the node or set as GROQ_API_KEY.
How it's built
The mechanism is plain: the node constructs a groq client and calls client.chat.completions.create with a system message, your prompt, and the standard sampling knobs - temperature, max_tokens, top_p. That's it. It's a thin, honest wrapper around the Groq SDK, which is why the dependency list is a single package: pip install groq. The models in the dropdown (llama3-70b-8192, llama3-8b-8192, mixtral-8x7b-32768) are hardcoded from an older Groq catalog - worth remembering, because GROQ has since renamed and retired some of those IDs.
The inputs you'd actually touch: api_key, model, prompt, system_message, temperature (0–2, lower is more deterministic), max_tokens, and top_p. The output is a single response string - run it into a text display node to read it, or into a prompt-prep / text-encode stage to feed generation.
Install
ComfyUI Manager is the easy path - search "GROQ" or "ComfyGroq" (the pack's title). Or the manual way:
cd ComfyUI/custom_nodes
git clone https://github.com/downlifted/ComfyUI_GROQ-PromptWizard
pip install groq
Then restart ComfyUI. A heads-up: the pack's README still shows a placeholder clone URL (yourusername/ComfyUI_ComfyGroq.git) - use the real repo above.
The part nobody mentions
Here's the trap. The UI exposes a dozen-plus fields - conversation_history, frequency_penalty, presence_penalty, format_output, enable_function_calling, stop_sequences, context_documents, even a seed. But the node's generate() method only accepts eight parameters, so when ComfyUI calls it with all the inputs it declared, Python throws TypeError: got an unexpected keyword argument before a single token is generated. The "Advanced" label is aspirational: most of those knobs are decoration even in the best case. The seed seeds torch/numpy/random - meaningless for a cloud API.
This is a one-commit, zero-impression pack from an early-stage author. The core idea is sound and the API call is legitimately written; it just isn't finished. If you want LLM-in-the-loop today, call the Groq SDK directly, or use one of the maintained LLM node packs that's been battle-tested by the community. And if you do install this one, check the repo for updates - a fixed function signature would change the story completely.
Inputs (15)
| Name | Type | Default | Description |
|---|---|---|---|
| api_key | STRING | Your GROQ API key. Leave empty to use GROQ_API_KEY environment variable. | |
| model | COMBO | llama3-70b-8192 | LLaMA 3 70B: Meta's 70B parameter model, great for complex tasks |
| prompt | STRING | Your input prompt or question | |
| system_message | STRING | You are a helpful AI assistant with deep knowledge and analytical skills. | System message to guide the model's behavior |
| conversation_history | STRING | Previous conversation history (format: 'user: message assistant: response') | |
| temperature | FLOAT | 0.700–2 | Lower values make output more deterministic, higher more creative |
| max_tokens | INT | 10241–8192 | Maximum number of tokens to generate |
| top_p | FLOAT | 0.900.1–1 | Nucleus sampling: consider only the top tokens with cumulative probability >= top_p |
| frequency_penalty | FLOAT | 0.0-2–2 | Positive values penalize new tokens based on existing frequency |
| presence_penalty | FLOAT | 0.0-2–2 | Positive values penalize new tokens based on whether they appear in the text so far |
| seed | INT | -1-1–4294967295 | Random seed (-1 for random) |
| format_output | COMBO | markdown | Format for the output |
| enable_function_calling | BOOLEAN | false | — |
| context_documentsopt | LIST | — | |
| stop_sequencesopt | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| response | STRING | — |