ComfyUI Node

CSV Writer (Soze)

Log every generation's seed, prompt, and output to a spreadsheet

By SozeInc·Created 2 years ago·Updated 3 days ago· 10
CSV Writer (Soze)
      csv_filename_path
      value1
      value2
      value3
      value4
      value5
      value6
      value7
      value8
      value9
      value10

      The write-side complement to CSV Reader - appends a row to a CSV file instead of reading one. No image or model output here; this is a pure logging node, useful for keeping a record of exactly what produced what across a big batch run.

      Pair it with CSV Reader and you've got a genuinely useful loop: read a row of source prompts, generate, log the result - seed, prompt, output path - back out to a second CSV as you go. Come back later and you have a real audit trail of a hundred-image batch instead of a folder of numbered PNGs and a fading memory of what settings produced which one.

      How it works

      Every time it runs, it appends one row - up to ten values - to the CSV file at the path you give it. It's a sink: is_output_node is true and it has no outputs of its own, so its entire job is the side effect of writing that line to disk.

      The inputs and outputs that matter

      • csv_filename_path (required) - the file to append to.
      • value1, value2 (required, STRING) - the first two columns of the row. You need at least these two.
      • value3 through value10 (optional, STRING) - up to eight more columns if you need them.
      • No outputs.

      The node doesn't write a header row for you - decide what order you're putting things in (seed, prompt, filename, model, whatever matters to you) and keep track of it yourself, since nothing in the schema labels the columns beyond their generic valueN name.

      How to install it

      Via ComfyUI Manager: search "Quality of Life Nodes for ComfyUI", install, restart. Manually:

      cd ComfyUI/custom_nodes
      git clone https://github.com/SozeInc/ComfyUI_Soze.git
      pip install -r ComfyUI_Soze/requirements.txt
      

      No dependencies beyond the base pack - plain file writing.

      Common issues & troubleshooting

      You want a running log of a big batch - seed, prompt, output filename - for later reference. This is exactly the use case. Wire your seed value, your prompt string, and your Save Image's output path (or Download URL's saved_path, if that's how you're saving) into three of the value slots, and you've got a spreadsheet of your whole run afterward instead of trying to reconstruct it from filenames.

      Rows appear in the wrong column when you open the CSV later. Since there's no header and no per-slot label beyond valueN, this is almost always a discipline problem, not a bug - write down, outside the node, what you decided value1..value10 mean for this particular graph.

      The file doesn't exist yet. Check whether the node creates a new file automatically or expects one to already exist at that path - if you get an error on a brand-new path, create an empty file there first, or point at a path in a directory you know exists.

      The CSV keeps growing across restarts and you didn't want that. Since this is an append, not an overwrite, running the same graph again on a different day adds to the same file rather than replacing it - which is usually what you want for a log, but worth remembering if you were expecting a fresh file each session. Point at a new filename per run if you need a clean slate every time.

      Categoryutils

      Inputs (11)

      NameTypeDefaultDescription
      csv_filename_pathSTRING
      value1STRING
      value2STRING
      value3optSTRING
      value4optSTRING
      value5optSTRING
      value6optSTRING
      value7optSTRING
      value8optSTRING
      value9optSTRING
      value10optSTRING

      Outputs (0)

      No outputs