Wujiai 通用批量提交 (异步 CSV/Excel)
The spreadsheet batch node for any Wujiai model
- images
- report
The whole "batch automation" promise of the ComfyUI-nkxx README lands here: point this node at a CSV or Excel file, tell it which column holds the prompts, and it submits every row as an async image job to whatever Wujiai model you name - Gemini, Nano Banana, Grok, GPT, Seedream. Then you collect results with UniversalAsyncQueryWujiai. It's the spreadsheet-driven version of UniversalAsyncSubmitWujiai, and for anyone generating product shots, character sheets, or a thousand variations, it's the node that turns a boring table into a running production line.
Inputs:
- model_name - any Wujiai image model, default
gemini-3.1-flash-image-preview. - file_path - the CSV/XLS/XLSX. Absolute path; pandas reads it (CSV as UTF-8, Excel via openpyxl).
- column_name - which column has the prompts (default
prompt). Missing column → clean error, not a silent partial run. - prompt_prefix - text prepended to every row (style tags, character names, whatever).
- aspect_ratio, image_size - the usual knobs (9 ratios; 默认/1K/2K/3K/4K).
- sequential_mode - disabled / auto (组图模式).
- max_images - 1–15 reference images shared across the batch.
- n - 1–10 images per row.
- executions_per_prompt - 1–10; how many times each row gets submitted. Want 3 variations of every one of your 40 prompts? Set this to 3.
- images (optional) - a shared reference image batch, uploaded once and reused.
- api_key - optional, pack-wide fallback.
Output: report - a status string with the task ID, how many subtasks went out, failures, and the credit balance. (Note: it's an output node - end of a branch, nothing to wire downstream except a text display.)
Mechanically: reads the file, drops NaN rows, applies prefix and executions-per-prompt, then spawns one background job per prompt with the same concurrency machinery as the single async submit. Every subtask goes into the pack's local task database (data/), so the query node picks them up and the whole run survives a restart mid-batch.
Install is pack-wide:
cd ComfyUI/custom_nodes
git clone https://github.com/jieg9341-lab/ComfyUI-nkxx
Restart; the auto-installer handles pandas (required for Excel!), openpyxl, requests, yt-dlp, opencv-python, aiohttp. Register at wujiai.org for a key.
Grounded gotchas:
- Math before you queue. Rows × executions_per_prompt = real API calls at real cost. A 200-row sheet with executions_per_prompt=5 is a thousand paid generations - the node will happily spend them all.
- It's async on the generation side, but the submit still has to read and parse the whole file, which for a giant Excel can take a moment. Don't confuse that brief stall with blocking generation.
- Errors per-row don't abort the batch; the report's failure count is where they surface. Check it before re-running, or you'll double-pay for the rows that actually succeeded.
- The reference images are shared across all rows - there's no per-row image mapping in this node. For per-row images you want the folder-processing node (
UniversalBatchDirWujiai) instead.
Inputs (12)
| Name | Type | Default | Description |
|---|---|---|---|
| model_name | STRING | gemini-3.1-flash-image-preview | — |
| file_path | STRING | — | |
| column_name | STRING | prompt | — |
| prompt_prefix | STRING | — | |
| aspect_ratio | COMBO | 1:1 | 9 options: 1:1, 16:9, 9:16, 3:4, 4:3, 2:3, +3 |
| image_size | COMBO | 默认 | 5 options: 默认, 1K, 2K, 3K, 4K |
| sequential_mode | COMBO | disabled | 组图模式 |
| max_images | INT | 151–15 | — |
| n | INT | 11–10 | — |
| executions_per_prompt | INT | 11–10 | — |
| imagesopt | IMAGE | — | |
| api_keyopt | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| report | STRING | — |