A ComfyUI custom node for Prompt Enhancer based on Qwen-Image-2.1. Supports both Text-to-Image (T2I) prompt generation and Image-to-Image (I2I) prompt rewriting with dynamic UI that supports 1-9 image connections.
You can install this node via ComfyUI Manager by searching for this repository, or install it manually:
Navigate to your ComfyUI custom_nodes folder and clone this repository:
cd ComfyUI/custom_nodes
git clone https://github.com/kana112233/ComfyUI-kaola-qwen-image2.1-prompt-rewrite.git
cd ComfyUI-kaola-qwen-image2.1-prompt-rewrite
pip install -r requirements.txt
This node relies on standard HuggingFace directory formats, NOT single .safetensors files.
Qwen-Image-2.1-PE-I2I) in your ComfyUI/models/LLM directory.config.json, tokenizer.json, etc.) into this newly created folder.Restart ComfyUI and load the workflow files from the examples folder:
t2i_prompt_enhancer_workflow.json: Pure text prompt expansion.i2i_edit_workflow.json: Image-based prompt editing (dynamically supports 1-9 images).i2t_caption_workflow.json: Reverse engineering image to prompt (extracts detailed prompt from an image).Note: This model uses the newest qwen3_5 architecture. Ensure your transformers package is updated to the latest git branch as specified in requirements.txt (pip install git+https://github.com/huggingface/transformers.git).
推荐使用 ComfyUI Manager 搜索并直接安装。如果你想手动安装:
进入 ComfyUI 的 custom_nodes 目录,克隆此仓库并安装依赖:
cd ComfyUI/custom_nodes
git clone https://github.com/kana112233/ComfyUI-kaola-qwen-image2.1-prompt-rewrite.git
cd ComfyUI-kaola-qwen-image2.1-prompt-rewrite
pip install -r requirements.txt
本项目基于标准的开源大语言模型架构(调用 transformers),因此请勿仅下载单文件,必须下载完整的模型文件夹。
ComfyUI/models/LLM 目录下,新建一个模型文件夹(例如 Qwen-Image-2.1-PE-I2I)。config.json, tokenizer.json 等全部文件)放进该文件夹中。重启 ComfyUI 后,可直接拖入本项目 examples 文件夹下的工作流体验:
t2i_prompt_enhancer_workflow.json:纯文本生成高质量英文提示词。i2i_edit_workflow.json:看图重写提示词(前端自带动态连线功能,最高支持 1-9 张图片同时传入)。注:由于该模型使用了极新的 qwen3_5 架构,必须确保你的 transformers 库是最新版(参考 requirements.txt,环境需执行 pip install git+https://github.com/huggingface/transformers.git)。否则会出现加载架构不认识的报错。
A ComfyUI custom node for Prompt Enhancer based on Qwen-Image-2.1. Supports both Text-to-Image (T2I) prompt generation and Image-to-Image (I2I) prompt rewriting with dynamic UI that supports 1-9 image connections.
You can install this node via ComfyUI Manager by searching for this repository, or install it manually:
Navigate to your ComfyUI custom_nodes folder and clone this repository:
cd ComfyUI/custom_nodes
git clone https://github.com/kana112233/ComfyUI-kaola-qwen-image2.1-prompt-rewrite.git
cd ComfyUI-kaola-qwen-image2.1-prompt-rewrite
pip install -r requirements.txt
This node relies on standard HuggingFace directory formats, NOT single .safetensors files.
Qwen-Image-2.1-PE-I2I) in your ComfyUI/models/LLM directory.config.json, tokenizer.json, etc.) into this newly created folder.Restart ComfyUI and load the workflow files from the examples folder:
t2i_prompt_enhancer_workflow.json: Pure text prompt expansion.i2i_edit_workflow.json: Image-based prompt editing (dynamically supports 1-9 images).i2t_caption_workflow.json: Reverse engineering image to prompt (extracts detailed prompt from an image).Note: This model uses the newest qwen3_5 architecture. Ensure your transformers package is updated to the latest git branch as specified in requirements.txt (pip install git+https://github.com/huggingface/transformers.git).
推荐使用 ComfyUI Manager 搜索并直接安装。如果你想手动安装:
进入 ComfyUI 的 custom_nodes 目录,克隆此仓库并安装依赖:
cd ComfyUI/custom_nodes
git clone https://github.com/kana112233/ComfyUI-kaola-qwen-image2.1-prompt-rewrite.git
cd ComfyUI-kaola-qwen-image2.1-prompt-rewrite
pip install -r requirements.txt
本项目基于标准的开源大语言模型架构(调用 transformers),因此请勿仅下载单文件,必须下载完整的模型文件夹。
ComfyUI/models/LLM 目录下,新建一个模型文件夹(例如 Qwen-Image-2.1-PE-I2I)。config.json, tokenizer.json 等全部文件)放进该文件夹中。重启 ComfyUI 后,可直接拖入本项目 examples 文件夹下的工作流体验:
t2i_prompt_enhancer_workflow.json:纯文本生成高质量英文提示词。i2i_edit_workflow.json:看图重写提示词(前端自带动态连线功能,最高支持 1-9 张图片同时传入)。注:由于该模型使用了极新的 qwen3_5 架构,必须确保你的 transformers 库是最新版(参考 requirements.txt,环境需执行 pip install git+https://github.com/huggingface/transformers.git)。否则会出现加载架构不认识的报错。