JSON Load π¦βπ₯
Pull your saved graph data back out of a .json
- data
ComfyUI workflows are JSON themselves, but that doesn't mean it's convenient to move data between runs. The pack's JSON Save node writes dictionaries, lists, and tuples to disk as .json files; this node reads them back. Together they're the pack's little persistence layer - a way to stash a batch of prompts, a set of detected points, or any other Python object your graph produced and pull it out on a later run.
How it works
The node lists every .json file inside ComfyUI's output/jsons directory and presents them in the jsonfile dropdown. Pick one and you get data on the output - an * (any) port, so it can carry a dict, a list, a tuple, or whatever else got serialized.
Then there's filename_noExt, the sneaky override: type a filename (no extension - .json gets appended automatically) and it ignores the dropdown entirely and loads that file instead. That's your escape hatch when the file you want was just written and hasn't refreshed into the dropdown, or when you're scripting runs where the filename changes per batch.
The output is * typed, so what you do with it depends on what you saved. A list flows into iteration or batching; a dict usually needs another node to pull keys out of it - this node just hands you the object.
Where this actually matters
The canonical pattern in this pack:
- Run a batch, collect results (say, a list of image paths or detected circle centers), hit JSON Save.
- Next session, JSON Load brings the exact same structure back, and you iterate over it or feed it downstream.
No re-running the detection. No copy-pasting values between ComfyUI tabs by hand.
Gotchas
- Files live in
ComfyUI/output/jsons, not your input folder. People look in the wrong place once, guaranteed. - If that folder is empty, the dropdown shows a single "None" entry and executing raises a
FileNotFoundError- the node can't load a file that was never saved. - "If specified, npyfile will be ignored" in the tooltip is a copy-paste from the pack's nparray loader; here the override input is
filename_noExtitself. Same idea, just a stale tooltip.
Install
In ComfyUI Manager, search ComfyUI-ArchiGraph, or:
cd ComfyUI/custom_nodes
git clone https://github.com/vincentfs/ComfyUI-ArchiGraph
Restart ComfyUI and run the pack's install script once so the dependencies land. No downloads beyond that - this node is pure Python's json module.
Verdict
It's a small utility, but it's the read-side of the only data persistence the pack gives you. Pair it with JSON Save and the any-typed outputs stop being a mystery - they become the same thing you saved yesterday.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| jsonfile | COMBO | 1 options: None | |
| filename_noExt | STRING | Filename without extension (extension .json will be added automatically). If specified, npyfile will be ignored. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| data | * | β |