5.1 KiB
ComfyUI Image Promptor
Image-only ComfyUI node that sends one or more IMAGE inputs to a vision-language model and returns a detailed still-image generation prompt as STRING.
This package is separate from Comfyui-Minimax-H3-Promptor, so the existing MiniMax H3 video nodes are unchanged.
Node
Search for Detailed Image Promptor under image/Prompting.
Inputs:
image: one image or an image batch.provider:ollama,openai_compatible,gemini, orclaude.model,api_base,api_key: provider settings.temperature,max_tokens: generation controls.additional_instruction: optional image-only focus, such as emphasizing clothing or hand placement.
Output:
prompt: a single English prompt containing the scene, people, poses, actions, relationships, clothing, objects, environment, composition, camera, lighting, color, text, and visual finish when visible.
The node does not expose or analyze video and does not add temporal instructions to the result.
Local Ollama
Install a vision model in Ollama, for example:
ollama pull qwen2.5vl:7b
Use the defaults shown in the node: http://127.0.0.1:11434 and SetneufPT/Gemma4-12B-IT-QAT_Q4_64K_16GB-GPU:latest.
API providers
For OpenAI-compatible, Gemini, or Claude, enter the API base, model, and key in the node or create config.json beside nodes.py using config.example.json as a template. The node UI values override config values.
Restart ComfyUI after installing or changing the node package. Existing video nodes from the source repository are not modified.
Установка на русском языке
-
Откройте каталог
custom_nodesвашей установки ComfyUI. -
Клонируйте репозиторий:
cd ComfyUI/custom_nodes git clone http://192.168.1.171:3000/dimon/ComfyUI-Image-Promptor.git -
Установите зависимости в то же Python-окружение, из которого запускается ComfyUI:
cd ComfyUI-Image-Promptor python -m pip install -r requirements.txtВ Windows ComfyUI Desktop при необходимости используйте
C:\path\to\ComfyUI\.venv\Scripts\python.exeвместо системногоpython. -
Полностью перезапустите ComfyUI.
-
Добавьте Detailed Image Promptor из категории
image/Prompting.
Зависимости
requests>=2.28.0— HTTP-запросы к выбранному провайдеру.Pillow>=9.0.0— конвертация тензоров ComfyUI в JPEG.torch— нужен для тензораIMAGE, но обычно уже установлен вместе с ComfyUI. Отдельно устанавливать PyTorch не нужно, если этого не требует ваша установка.
Ollama
По умолчанию нода использует http://127.0.0.1:11434 и vision-модель SetneufPT/Gemma4-12B-IT-QAT_Q4_64K_16GB-GPU:latest. Ollama должен быть запущен, а модель должна поддерживать изображения. Модель и URL можно изменить прямо в ноде. Для другого vision-моделя, например qwen2.5vl:7b, укажите его имя в поле model.
Для провайдеров openai_compatible, gemini и claude укажите URL API, модель и ключ в ноде. config.example.json можно скопировать в config.json; реальные ключи нельзя добавлять в git.
Installation in English
-
Open the
custom_nodesdirectory of your ComfyUI installation. -
Clone the repository:
cd ComfyUI/custom_nodes git clone http://192.168.1.171:3000/dimon/ComfyUI-Image-Promptor.git -
Install dependencies into the same Python environment used by ComfyUI:
cd ComfyUI-Image-Promptor python -m pip install -r requirements.txtOn Windows ComfyUI Desktop, use
C:\path\to\ComfyUI\.venv\Scripts\python.exeinstead of the systempythonwhen needed. -
Restart ComfyUI completely.
-
Add Detailed Image Promptor from
image/Prompting.
Dependencies
requests>=2.28.0for provider HTTP requests.Pillow>=9.0.0for converting ComfyUI tensors to JPEG.torchis needed for theIMAGEtensor and is normally supplied by ComfyUI. Do not install a separate PyTorch build unless your ComfyUI setup requires it.
Ollama
The default endpoint is http://127.0.0.1:11434 and the default vision model is SetneufPT/Gemma4-12B-IT-QAT_Q4_64K_16GB-GPU:latest. Ollama must be running and the selected model must support image input. You can change the model and endpoint directly in the node. For another vision model, such as qwen2.5vl:7b, enter its name in model.
For openai_compatible, gemini, or claude, enter the provider URL, model, and API key in the node. You may copy config.example.json to config.json for file-based defaults. Never commit real API keys.
Лицензия / License
MIT. See LICENSE.