科林_Cyril Pilgrim 8eea73f574 feat(nodes): add dedicated reasoning output pin for deepseek models
Motivation: Expose the parsed reasoning_content to downstream ComfyUI nodes so users can route or display the internal thoughts of models like DeepSeek.

Implementation: Appended 'reasoning' to RETURN_TYPES and RETURN_NAMES in openai_compatible.py. Updated _success and _error_result standard return tuple length from 3 to 4.
2026-03-01 23:18:39 +08:00
2025-02-05 16:53:34 +08:00

ComfyUI-LLMs-Toolkit

Language / 语言切换

English 简体中文


GitHub Stars GitHub Forks GitHub Issues License Last Commit

Inject powerful Large Language Models into your ComfyUI workflows!

A professional-grade ComfyUI custom node suite supporting world-leading Large Language Models


Project Overview

ComfyUI-LLMs-Toolkit is a high-performance ComfyUI extension designed for AI creators. Through a lightweight API-driven approach, you can easily integrate world-class Large Language Models like DeepSeek, Qwen, GPT, etc., even with limited computational resources, democratizing AI creation.

Why Choose Us?

  • Zero Hardware Barrier: No high-end GPU required, enjoy cutting-edge AI capabilities with just APIs
  • Global Model Support: Integrated mainstream LLMs worldwide, one-stop solution
  • High-Performance Architecture: Optimized concurrent processing, dramatically improving workflow efficiency
  • Developer Friendly: Environment variable configuration, Docker support, developer-first approach

Core Features

Powerful LLM Ecosystem

Category Supported Models Key Capabilities
Chinese Leaders DeepSeek-V3, Qwen-Max, GLM-4 Chinese understanding, code generation, mathematical reasoning
International Giants GPT-4, Claude-3, Gemini Multimodal processing, creative writing, complex reasoning
Professional Vertical Doubao, Spark, Moonshot Dialogue generation, long text, role-playing

Technical Highlights

  • Lightning Deployment: One-click installation, get started in 5 minutes
  • Concurrency Optimization: Multi-threading processing, supports batch requests
  • Security First: Environment variable configuration, secure API key management
  • Hot Reload: Dynamic configuration updates, no need to restart ComfyUI
  • Smart Caching: Response caching mechanism, reducing API call costs
  • Containerized: Docker support, consistent deployment environment

Quick Start

System Requirements

  • Python: >= 3.8
  • ComfyUI: Latest version
  • Memory: >= 4GB RAM
  • Network: Stable internet connection

Lightning Installation

# Method 1: Git Clone (Recommended)
cd ComfyUI/custom_nodes/
git clone https://github.com/HuangYuChuh/ComfyUI-LLMs-Toolkit.git
cd ComfyUI-LLMs-Toolkit

# Install Dependencies
pip install -r requirements.txt
# Method 2: Docker Deployment
docker pull your-dockerhub/comfyui-llms-toolkit:latest
docker run -d --name comfyui-llms -p 8188:8188 your-dockerhub/comfyui-llms-toolkit

Environment Configuration

1. Create Configuration File

# Copy environment variable template
cp config/env.example .env

2. Configure API Keys

Edit the .env file and select the models you want to use:

# DeepSeek (Recommended for beginners)
DEEPSEEK_API_KEY=sk-your_deepseek_key_here
DEEPSEEK_BASE_URL=https://api.deepseek.com
DEEPSEEK_MODEL_NAME=deepseek-chat

# Qwen (Chinese optimized)
QWEN_API_KEY=your_qwen_key_here
QWEN_BASE_URL=https://dashscope.aliyuncs.com/api/v1
QWEN_MODEL_NAME=qwen-max

# OpenAI GPT (International standard)
OPENAI_API_KEY=sk-your_openai_key_here
OPENAI_BASE_URL=https://api.openai.com/v1
OPENAI_MODEL_NAME=gpt-4o-mini

# More configurations see config/env.example

3. API Key Acquisition Guide

Provider Get Address Free Credits Rating
DeepSeek platform.deepseek.com ¥500 free credits ⭐⭐⭐⭐⭐
Qwen dashscope.aliyun.com 1M tokens/month ⭐⭐⭐⭐
OpenAI platform.openai.com $5 trial credits ⭐⭐⭐⭐⭐
GLM open.bigmodel.cn 5M tokens/month ⭐⭐⭐⭐

First Run

  1. Restart ComfyUI:

    # Restart ComfyUI to load new nodes
    cd /path/to/ComfyUI
    python main.py
    
  2. Find Nodes:

    • Right-click in ComfyUI interface
    • Navigate to Add Node -> LLMs Toolkit
    • Select the node type you need
  3. Start Creating:

    • Drag in LLM nodes
    • Configure model parameters
    • Connect inputs and outputs
    • Enjoy your AI creation journey!

Supported Model Matrix

Chinese AI Champions

Model Provider Core Advantages Price Level Config Prefix
DeepSeek-V3 DeepSeek Mathematical reasoning, Code generation Ultra-low DEEPSEEK_
Qwen-Max Alibaba Multimodal, Chinese optimization Medium QWEN_
GLM-4 Zhipu AI Logical reasoning, Knowledge Q&A Low GLM_
Doubao-Pro ByteDance Dialogue generation, Creative writing Medium DOUBAO_
Spark-Max iFLYTEK Language understanding, Text analysis Low SPARK_
Moonshot-V1 Moonshot AI Long text, Deep understanding Medium MOONSHOT_

International AI Giants

Model Provider Core Advantages Price Level Config Prefix
GPT-4o OpenAI General intelligence, Multimodal High OPENAI_
Claude-3.5 Anthropic Safe dialogue, Long text High CLAUDE_
Gemini-Pro Google Search enhanced, Multilingual Medium GEMINI_

FAQ

Q: How to get API keys?

A: All major vendors provide free trial credits:

  • DeepSeek: Register and get ¥500 credits, suitable for beginners
  • Qwen: Large quota available after Alibaba Cloud account verification
  • OpenAI: New users get $5 free credits, requires international payment method
Q: Does it support local models?

A: Currently mainly supports API calls, local model support is on the development roadmap:

  • v2.0: Planned support for Ollama local models
  • v2.1: Support for GGUF format models
  • v3.0: Support for custom model fine-tuning
Q: What to do when encountering connection errors?

A: Common solutions:

  1. Check network: Ensure access to corresponding API services
  2. Verify keys: Confirm API keys are correct and have balance
  3. Check configuration: Confirm BASE_URL format is correct
  4. View logs: Check ComfyUI console output

Open Source License

This project is licensed under GNU General Public License v2.0.

This means:

  • Free to use: Both personal and commercial use
  • Free to modify: You can modify the source code
  • Free to distribute: You can distribute original or modified versions
  • Open source obligation: Modified versions must be open source

If this project helps you, please give us a Star!

Star History Chart

Contact Us

GitHub Email


Made with love for the ComfyUI community

Making AI creation simpler, making technology more humane

S
Description
No description provided
Readme AGPL-3.0
1.7 MiB
Languages
Python 45.7%
JavaScript 44.6%
CSS 9.7%