Nodes/ComfyUI CrewAI/📎CrewAI LLM Hugging Face
ComfyUI Node

📎CrewAI LLM Hugging Face

Skip this one — it's broken as shipped

By luandev·Created 2 years ago·Updated 2 years ago· 63
📎CrewAI LLM Hugging Face
    • llm
    â—„modelcrewai-llama3â–º
    â—„base_urlhttp://localhost:11434/v1â–º
    ◄api_key—►

    I'll save you the hour I spent: the 📎CrewAI LLM Hugging Face node does not work in the version of this pack that's currently on GitHub. Every other node in ComfyUI-CrewAI runs, this one crashes the moment you hit queue. If you found this page because the node red-flagged on you, the fix is to not use it - use the 📎CrewAI LLM OpenAI node pointed at your endpoint instead, or 📎CrewAI LLM Ollama for fully local.

    What went wrong

    The bug is right there in the source. The node's inputs (per its info_schema and its own INPUT_TYPES) are:

    • model - required, default crewai-llama3
    • base_url - required, default http://localhost:11434/v1
    • api_key - optional

    But the execution function it declares is:

    def create_task(self, base_url, api_key, task, max_new_tokens):
    

    It expects task and max_new_tokens, which are never supplied by the node's inputs, and it never receives model at all. ComfyUI calls it with the actual inputs, Python raises TypeError, and the node fails. That's not a config problem you can fix from the UI - it's a code/signature mismatch in the release.

    There's also a conceptual smell underneath: despite the "Hugging Face" name, the default base_url is http://localhost:11434/v1 - that's Ollama's OpenAI-compatible endpoint, copied from the OpenAI node. The code does pass a huggingfacehub_api_token, so the intent seems to be pointing at a Hugging Face Inference Endpoint, but with the defaults and the broken signature, it's all over the place.

    What it was supposed to do

    Conceptually: build a crewai.LLM with endpoint_url, huggingfacehub_api_token, task, and max_new_tokens, and hand a CREWAI_LLM object to an Agent node - the same role the other three LLM nodes play. Self-hosted or serverless Hugging Face models, no OpenAI key. A decent idea; it just isn't wired up.

    What to do instead

    • Local, free: 📎CrewAI LLM Ollama (ollama pull llama3.2, set model to ollama/llama3.2:3b, default base_url already points at localhost). Zero friction, works today.
    • Any OpenAI-compatible server: 📎CrewAI LLM OpenAI. Point base_url at your endpoint - Ollama's /v1, LM Studio, vLLM, Together, whatever. The node is named "OpenAI" but it's really an OpenAI-compatible client.
    • Actual OpenAI: 📎CrewAI LLM Chat GPT.

    All three output the same CREWAI_LLM, so swapping is just deleting one node and dragging in another - the wire into your Agent node stays intact.

    Installing the pack

    ComfyUI Manager → search "ComfyUI-CrewAI", or clone it manually:

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

    The only dependency is CrewAI itself. Worth checking the pack's issues page for a fix before you fully write this node off - but as of the shipped release, it's a trap. You lose nothing by going with the OpenAI node on a local endpoint.

    Category📎CrewAI

    Inputs (3)

    NameTypeDefaultDescription
    modelSTRINGcrewai-llama3—
    base_urlSTRINGhttp://localhost:11434/v1—
    api_keyoptSTRING—

    Outputs (1)

    NameTypeDescription
    llmCREWAI_LLM—