Nodes/OmiXdev Custom Nodes/๐Ÿ‘พ Ollama Local Chat ๐Ÿฆ™
ComfyUI Node

๐Ÿ‘พ Ollama Local Chat ๐Ÿฆ™

Private, free, no API key โ€” the local chat node worth reaching for

By omixmaxdimoยทCreated 11 months agoยทUpdated 6 months agoยท 0
๐Ÿ‘พ Ollama Local Chat ๐Ÿฆ™
    • last_reply
    • chat_history
    โ—„user_messageHello!โ–บ
    โ—„modelQwen3:4bโ–บ
    โ—„resetfalseโ–บ
    โ—„send_historytrueโ–บ

    OmixChatOllama ("๐Ÿ‘พ Ollama Local Chat ๐Ÿฆ™") is the sibling that wants nothing from you: no API key, no account, no cloud. If Ollama is running on your machine, this node talks to it over localhost and brings the reply back into your graph. For the "let an LLM write or rewrite my prompt" trick, this is the privacy-friendly version - nothing you type ever leaves your computer, and nothing gets saved in your workflow JSON.

    How it works

    It's a thin wrapper over the official ollama Python package (pinned to ollama>=0.3.0 in the pack's requirements). Your message goes to the local Ollama server on port 11434, the model you name does the thinking, and the reply comes back as a string.

    Unlike the OpenAI node in this pack, send_history here actually does something. When it's on, the node rebuilds your ๐Ÿ‘ค/๐Ÿค– log into proper user/assistant messages and sends the whole conversation to the model. This is the pack's node that genuinely holds a multi-turn chat.

    One more difference worth knowing: model is a plain text box, not a locked dropdown. Type any model you've pulled into Ollama - Qwen3:4b (the default), llama3.1, deepseek-r1, whatever you've got.

    The inputs and outputs

    • user_message - your prompt or instruction, multiline.
    • model - a free string, default Qwen3:4b.
    • reset - boolean; set it true for one run to wipe the in-session history.
    • send_history - boolean, default on; actually honored here.

    Outputs are the same pair as the other chat nodes: last_reply (STRING) and chat_history (STRING, the newline-joined log with ๐Ÿ‘ค/๐Ÿค– prefixes). Wire last_reply into a Show Text node, or into a text encoder if you're generating from what the model wrote.

    Installing

    Two separate pieces. First, Ollama itself:

    # install from https://ollama.com, then
    ollama pull qwen3:4b
    

    Then the pack, via Manager (search OmiXdev Custom Nodes) or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/omixmaxdimo/OmiXDev.git
    cd OmiXDev
    pip install -r requirements.txt
    

    Restart ComfyUI and you're done. The 4B default runs fine on CPU while your GPU is busy doing diffusion - that's the point.

    Troubleshooting

    The most common failure isn't subtle: Ollama isn't running. You'll see it as an error string on last_reply, because the node catches exceptions and returns them as text - connection refused means start Ollama. Also make sure the model is actually pulled; a typo'd name gives you a model-not-found error. And remember the shared-history quirk: chat_history is class-level state, so every OmixChatOllama instance in the session shares one log, and it resets whenever you restart ComfyUI. If replies don't match the message you just sent, that's the reason.

    It's the simplest of the three chat nodes, and honestly the one I'd reach for first - free, private, and it works. The only price is that a 4B local model won't write as well as GPT-4.1. For prompt drafting, that's usually enough.

    Category๐Ÿ‘พ OmiXDev/Chat

    Inputs (4)

    NameTypeDefaultDescription
    user_messageSTRINGHello!โ€”
    modelSTRINGQwen3:4bโ€”
    resetoptBOOLEANfalseโ€”
    send_historyoptBOOLEANtrueโ€”

    Outputs (2)

    NameTypeDescription
    last_replySTRINGโ€”
    chat_historySTRINGโ€”