Load Prompt from CSV
A dropdown of ready-made prompts from a CSV file
- Prompt
- negative Prompt
"Load Prompt from CSV" turns a plain CSV file into a dropdown of prompt presets. Pick a name in the combo box, and it hands you a ready-to-go positive prompt on one output and its matching negative prompt on another. If you keep a library of style presets or reusable prompt skeletons, this is the node that stops you from copy-pasting them out of a text file forever.
The design comes from a very specific file: styles.csv, with three columns - name, prompt, negative_prompt. The first column becomes the label in the selection dropdown, the second feeds the Prompt output, the third feeds negative Prompt. The pack ships a sample file full of the old A1111 "sai-*" styles (sai-anime, sai-cinematic, sai-3d-model…) so there's something to play with the moment it's installed. But the author's real use case is worth copying: the positive prompts contain a literal {prompt} placeholder, which they swap for a subject line - so a style preset stays a style, and the subject stays yours.
The one requirement: where the file lives
Here's the gotcha, and it's the whole install step. The file must be styles.csv at the root of your ComfyUI folder - the directory that holds main.py/run.py - not inside the pack, not in a data subfolder. The node checks folder_paths.base_path and reads styles.csv there. Put it anywhere else and the dropdown just shows "file not found".
Beyond that, the format rules are simple: each row needs at least three columns, the first column must be non-empty, and rows starting with >>>>>> are treated as section headers and ignored. The author uses those to group styles in a long file - a heading like >>>>>> Portrait between blocks keeps things organized without polluting the dropdown. Extra columns beyond the third are ignored. Want your own library instead of the shipped styles? Just overwrite the file; as long as the structure holds, it loads. The name says "styles," but it's really a general prompt-pair loader - the README notes you can use it to save and reload any positive/negative prompt pairs.
The inputs and outputs
- csv_file - a dropdown listing CSV files in the ComfyUI root. In the shipped version it's effectively hardcoded to
styles.csv; the author admits the filename is fixed in Python rather than a real file browser. - selection - the dropdown of style names, populated from the first column.
- Outputs: Prompt (STRING, positive) and negative Prompt (STRING) - both wire into your CLIP Text Encode nodes.
Installing it
cd ComfyUI/custom_nodes
git clone https://github.com/Kaleidia/KaleidiaNodes
# restart ComfyUI
Or via ComfyUI Manager, searching "KaleidiaNodes". No Python dependencies, no models.
Where people get burned
Ninety percent of "why is my dropdown empty" reports will be the file location - it really has to be at the ComfyUI root, and it has to be called styles.csv. Second most common: a header row. The sample file starts with name,prompt,negative_prompt as column names, and the loader skips the first row, so if you write your own file, keep that header or you'll wonder why your first style is missing. And a final note: because it's a static Python dropdown, changes to styles.csv need a ComfyUI restart (or at least a node reload) to show up. Minor friction, but the result - a clean dropdown of your best prompts - is worth it.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| csv_file | COMBO | styles.csv | 1 options: <no csv file> |
| selection | COMBO | Empty | 1 options: file not found |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| Prompt | STRING | Positive Prompt. |
| negative Prompt | STRING | Negative Prompt |