Nodes/KIE.ai Nodes Next/Claude Sonnet 5.5
ComfyUI Node

Claude Sonnet 5.5

The default worth paying for

By felipederosilva·Created 2 months ago·Updated 5 days ago· 3
Claude Sonnet 5.5
    • text
    • raw_json
    • credits_consumed
    • usage_json
    • credits_left
    ◄prompt►
    ◄system_prompt►
    ◄streamfalse►
    ◄tools_json[]►
    ◄history_json[]►
    ◄max_tokens4096►
    ◄thinkingfalse►
    ◄expert_override_json{}►

    Here's the unglamorous truth about LLM nodes in ComfyUI: you use them for one job at a time, the job is short, and what matters is that the output arrives in the format your next node can eat. Sonnet-tier Claude is the sweet spot for that - noticeably better at following structured instructions than the tiny models people run locally, cheap enough that you don't wince at re-running a graph five times, and fast enough that it doesn't feel like a modal dialog.

    Sonnet 5.5 is the one I'd start with if you're building something that has to work reliably: a shot-list generator, a prompt rewriter with a strict output format, a caption pass on a batch of frames. If it's a one-off throwaway rewrite, use Haiku and save the difference.

    The mechanism, minus the magic

    This is a generated node from the pack's catalog: the model ID (claude-sonnet-5-5) is baked in and it POSTs to KIE's Claude endpoint, /claude/v1/messages. Your history_json array becomes the message list, prompt is appended as the final user turn, and system_prompt is hoisted to the request's system field - properly, as a system instruction, not as a fake message. thinking sets a thinkingFlag. The pack then digs the assistant text out of the response and returns it as a plain string, alongside the raw payload for inspection.

    There are no images on this socket. If your pipeline is "look at frame, write prompt", Claude nodes won't do it - the pack's adapter deliberately keeps them text-only, with multimodal payloads left to history_json or the expert override field. Use an OpenAI-shaped node for vision.

    Inputs that change the output

    • prompt - the instruction. Required, and the preflight check refuses an empty one.
    • system_prompt - where the format contract goes. Ask for bare text and you'll get bare text. Skip it and you'll get "Sure! Here's an enhanced prompt:" glued onto the front of your conditioning.
    • max_tokens - 4096 default, up to 131072. Long structured output (a six-shot storyboard with camera notes) is where people hit the default and get truncated JSON.
    • history_json - [] unless you genuinely need multi-turn. Each extra turn is tokens you're paying for on every run.
    • thinking - off by default, and I'd keep it there for rewriting. Turn it on for actual reasoning jobs (planning a sequence, reconciling contradictory notes). There's no budget dial; it's a boolean flag, and the thinking doesn't come back in the text output.
    • tools_json - function definitions for agentic use. [] for everything else.
    • stream / expert_override_json - leave alone. Streaming hands you one finished string regardless.

    Outputs: text, raw_json, usage_json, credits_consumed, credits_left.

    Install

    cd ComfyUI/custom_nodes
    git clone https://github.com/felipederosilva/ComfyUI-KIE-Nodes-Next
    cd ComfyUI-KIE-Nodes-Next && pip install -r requirements.txt
    # restart ComfyUI
    

    Or search "KIE.ai Nodes Next" in Manager, or comfy node install kie-ai-nodes-next from the registry. Requirements are requests, Pillow, numpy, PyYAML - there is nothing GPU-side to install and no model to download, which is the whole reason this pack exists. Configure the key once in Settings → KIE.ai Nodes Next → Connection; the pack validates it against KIE before overwriting a working key and never puts the full key into workflow JSON.

    Failure modes you'll actually hit

    The node won't run unless its text output feeds something that executes - a text preview, a prompt input, a save node. Because it isn't an output node, an unconnected Sonnet node is silently skipped, and nothing gets billed. Confusing, but harmless.

    Timeouts and provider failures come back as loud errors with the provider's own message; the pack retries transient HTTP statuses (408, 429, 5xx) a few times before giving up. If KIE's balance service is having a bad day, the generation still returns and the node just reports the balance as unavailable.

    The honest downside is the one that applies to every API node: prompts leave your machine, the provider's filter is not removable, and per-call cost scales with how much you iterate. Sonnet 5.5 earns its price on structured work. For "sprinkle adjectives on my prompt", it's a waste of money - the local path does that fine.

    CategoryKIE Next/LLM/Claude/Sonnet

    Inputs (8)

    NameTypeDefaultDescription
    promptSTRINGUser prompt / message.
    system_promptoptSTRING—
    streamoptBOOLEANfalse—
    tools_jsonoptSTRING[]Optional function/tool definitions supported by this model endpoint.
    history_jsonoptSTRING[]Optional prior message/input array as JSON.
    max_tokensoptINT40961–131072—
    thinkingoptBOOLEANfalse—
    expert_override_jsonoptSTRING{}Expert-only request overrides. Normal use does not require this.

    Outputs (5)

    NameTypeDescription
    textSTRING—
    raw_jsonSTRING—
    credits_consumedFLOAT—
    usage_jsonSTRING—
    credits_leftFLOAT—