Nodes/ComfyUI-TJ_NODE/MiniMax H3 Save Latent Checkpoint (TJ)
ComfyUI Node

MiniMax H3 Save Latent Checkpoint (TJ)

Parking a clip's latent on disk so the next clip can pick it up

By designloves2·Created 3 months ago·Updated 5 days ago· 13
MiniMax H3 Save Latent Checkpoint (TJ)
  • latent
  • checkpoint_name
checkpoint_nameclip001

ComfyUI has a hard rule that trips up every long-video workflow: it doesn't hold tensors between separate queue submissions. Each prompt you run is a fresh world. So when a MiniMax H3 relay workflow runs each clip as its own queue entry - unloading the model between clips to free VRAM - there's no in-memory way to hand clip N's latent to clip N+1. MiniMax H3 Save Latent Checkpoint (TJ) is the write half of the disk-based workaround: it dumps the finished clip's AV latent to a safetensors file that a later run can load back.

It's about as small a node as this pack makes. Two inputs:

  • latent - the H3 AV latent you just sampled (the undecoded two-stream NestedTensor).
  • checkpoint_name - a name with no extension. The file is saved as <name>.h3lat.safetensors in output/one_minimax_h3/_latent_checkpoints/ (the pack resolves that under your ComfyUI output folder). The matching Load node must use the exact same name.

Output is a single checkpoint_name STRING, mainly so you can thread the name along in the graph if you're being tidy.

Two details in the implementation are worth knowing because they're the difference between "works" and "bizarre cache bug." First, the node forces itself to always run (IS_CHANGED returns NaN): in a One-Take loop the checkpoint name is constant across clips, so if ComfyUI cached on inputs it would decide "same inputs, nothing to do" and never write the new latent to disk. Second, it writes to a temp file and os.replaces it into place - atomic, so a crash mid-write can't corrupt the file the Load node might already have mapped.

You almost never need this node by itself. The One-Take Sampler calls it internally every clip, so if you use that, this is handled. Reach for the standalone pair (Save + Load) only when you're hand-rolling a custom sampler chain and want the checkpoint lifecycle explicit in the graph. For everything else, the Sampler's built-in version saves you the wiring.

Install

Part of the ComfyUI-TJ_NODE pack:

cd ComfyUI/custom_nodes
git clone https://github.com/designloves2/ComfyUI-TJ_NODE

or ComfyUI Manager → "ComfyUI-TJ_NODE", then restart. No extra dependencies. You need the H3 weights/VAEs yourself, and to remember the H3 Community License excludes the US, EU, UK and South Korea from local use.

Troubleshooting

  • Old latent keeps coming back - this is the cache bug the always-run fix exists for; update the pack to a version that includes it.
  • Windows error about a file being mapped when Load tries to overwrite - the Load node clones its tensors precisely so the file isn't left mmap'd; if you hit it, restart ComfyUI and confirm both nodes are from the current version.
  • Name with a path in it fails - checkpoint names are sanitized; no .., / or \. Keep them simple like clip001.
Category ✨ TJ_Node/Video

Inputs (2)

NameTypeDefaultDescription
latentLATENT
checkpoint_nameSTRINGclip001확장자 없이 이름만 — <이름>.h3lat.safetensors 로 저장됩니다.

Outputs (1)

NameTypeDescription
checkpoint_nameSTRING