XDataSave
Your seeds and strings, saved as searchable history instead of vanishing
- xdata_input
- save_status
- save_path
ComfyUI is great at generating, mediocre at remembering. Unless you're disciplined about filenames, every seed you tried is gone the moment you queue the next one. XDataSave is this pack's answer: a node that writes history into a local SQLite database - the XDataSaved folder inside the pack directory - with append-and-rotate behavior that keeps the database from growing forever. If you've ever wanted to answer "what seeds did I run last week, and what were the prompts?" a month later, this is the node that makes that possible.
How it works
The node consumes an xdata_input payload - the pack's composite format that currently supports xdata_seed and xdata_string. Those payloads come from sibling nodes: a seed node wraps your seed into xdata_seed, and XAnyToString wraps any value into xdata_string. You pick a save_type:
- Seed - writes to
seed_data.db. - String - writes to
string_data.db. - Custom - needs a custom filename (from
custom_filename_input, which beats thecustom_filename_textfallback).
Each record is appended, and the DB keeps a rolling window of 500 records max - when you hit the cap, the oldest records rotate out. There are hard limits to respect: a single record (the extra header plus content) must stay under 64KB, and the header can't exceed 120 characters. The node validates before writing, so oversized records fail loudly instead of silently corrupting the DB.
Inputs and outputs that matter
- xdata_input - the payload to save (from a seed or string-producing node).
- save_type - Seed, String, or Custom (default Custom).
- custom_filename_text / custom_filename_input - the filename for Custom mode; the input port takes priority when connected.
- extra_header_text / extra_header_input - an optional annotation on the record; the input port wins.
- enable_save (default true) - the kill switch. Flip it off and the node validates and pretends to save but writes nothing, which is handy for dry runs.
Outputs: save_status (a message about what happened) and save_path (the DB path relative to the project root; empty when saving is disabled).
Installing it
Part of ComfyUI-Xz3r0-Nodes - install the pack once. ComfyUI Manager: search ComfyUI-Xz3r0-Nodes. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/Xz3r0-M/ComfyUI-Xz3r0-Nodes.git
cd ComfyUI-Xz3r0-Nodes
pip install -r requirements.txt
Restart ComfyUI after. The database writes use Python's built-in sqlite3, so there's no extra dependency for this node specifically.
Gotchas
Three things to know. First, the database lives inside the custom node folder (custom_nodes/ComfyUI-Xz3r0-Nodes/XDataSaved), so a clean reinstall of the pack wipes your history - back the folder up if the logs matter to you. Second, the 500-record rotation is a rolling window, not an archive: older records fall off the end, so this is a "recent history" tool, not a data warehouse. Third, the 64KB record cap means don't try to log giant prompt strings or full workflow JSONs as a single record - keep records lean. None of this is hidden, it's all in the tooltips, but each of these has surprised someone.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| xdata_input | xdata_seed,xdata_string | Composite xdata input. Currently supports xdata_seed and xdata_string. | |
| save_type | COMBO | Custom | Save target type. Custom requires a custom filename. Seed writes to seed_data.db. String writes to string_data.db. |
| custom_filename_text | STRING | Fallback custom filename for save_type Custom. Leave empty to force explicit configuration. | |
| extra_header_text | STRING | Fallback extra header text. Single record size must not exceed 64KB. Header length must not exceed 120 characters. | |
| enable_save | BOOLEAN | true | Enable or disable writing records to disk. When disabled, no file is written. |
| custom_filename_inputopt | STRING | Optional custom filename input. Takes priority over custom_filename_text. | |
| extra_header_inputopt | STRING | Optional extra header input. Takes priority over extra_header_text. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| save_status | STRING | Save status message |
| save_path | STRING | Saved path relative to project root. Empty when save is disabled. |