textOutput
Stop screenshotting your prompts β save them as files
- text
textOutput is the text-world equivalent of a Save Image node: it takes a string, shows it to you, and - if you ask - writes it to disk as a real file. It's the node you reach for when you're generating prompt variations or positive/negative pairs and you want them preserved as .txt, .md, or .csv files instead of living only in a workflow JSON.
The workflow where this earns its keep: you've got a textConcat or a pipeLoader's prompt string, and you want an audit trail of exactly what got sent to the sampler - including the resolved wildcards, which the static text boxes don't show you. Point this at the end of your text chain, flip it to Save, and every run leaves a timestamped file you can diff later.
How it works
It's an output node with two modes via text_output:
Preview- renders the text in the node's UI area. No file.Save- writes the text through the pack's shared save machinery, with all the filename goodies.
When saving, you get output_path (defaults to ComfyUI's output folder), save_prefix (supports the %date:yyyy-MM-dd-hh-mm-ss% syntax and %widget%-style value injection), number_padding for the counter, and file_type - txt, md, rtf, log, ini, or csv. The overwrite_existing toggle controls whether a repeated run rolls to a new number or replaces the file.
The text output passes the string through untouched, so you can tee it into another node (say, a text concat that builds a filename from it) while still saving.
Inputs and outputs
text_output-PrevieworSave. The one you'll actually flip.text- the STRING to display/save. Usually wired from a concat or prompt node.text- the same STRING as a passthrough output.
Installing it
It's part of the tinyterraNodes pack:
cd ComfyUI/custom_nodes
git clone https://github.com/TinyTerra/ComfyUI_tinyterraNodes.git
or ComfyUI Manager β tinyterraNodes. No dependencies, no models.
Gotchas
The classic complaint is the other direction: people expect this to load text from a file and it only saves. If you want to read a file into a string, that's a different node (the pack doesn't ship a file-reader; WAS Node Suite or a core load node handles that). Also, csv output is a single cell, not a nicely formatted table - it's for when downstream tooling wants a plain value, not for spreadsheets. And remember the %date% prefix parsing is done at save time, so two runs in the same second with overwrite_existing off will collide into a (1)-style suffix rather than a separate timestamp. Minor, but it's caught me before.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| text_output | COMBO | Preview | 2 options: Preview, Save |
| text | STRING | β | |
| output_path | STRING | /tmp/ComfyUI/output | β |
| save_prefix | STRING | ComfyUI | β |
| number_padding | COMBO | 5 | 9 options: None, 2, 3, 4, 5, 6, +3 |
| file_type | COMBO | txt | 6 options: txt, md, rtf, log, ini, csv |
| overwrite_existing | BOOLEAN | false | β |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| text | STRING | β |