Nodes/PromptStudio_Video/Prompt Studio Save H3 Context
ComfyUI Node

Prompt Studio Save H3 Context

The bookmark node that lets MiniMax H3 renders continue later

By tiko13·Created 27 days ago·Updated a day ago· 6
Prompt Studio Save H3 Context
  • latent
  • context_path
project_idproject
generation_idgeneration
context_frames39

Prompt Studio Save H3 Context (PSV_H3SaveContext) does one unglamorous job and does it carefully: after you finish a MiniMax H3 render, it snips off the exact audiovisual latent tail and saves it to disk so a later "continue" render can start from where that clip ended. It's a dead-end output node - you wire the sampler's latent into it and nothing comes out of it that you use for the current render. It exists purely to record state for the next one.

Why a separate save step at all?

Two reasons, both worth internalizing if you've fought video continuation before. First, the parent render must stay untouched - every generation in this pack keeps its own immutable lineage so you can always branch a shorter version or replay it exactly. Second, the tail has to be exact: not a re-encoded approximation, but the actual latent tensors H3 produced, on its native temporal grid. The node trims the compact tail (valid context_frames values are 5, 22, 39, or 56 - the only counts that land cleanly on H3's repeating 1, 4, 4, 4, 4 frame-to-step grid, with audio steps matched at the 40 Hz audio-latent clock), then writes a safetensors file whose metadata records the format, the frame count, and the source audio/video clock so the loader can verify nothing drifted.

The file lands at:

ComfyUI/output/video/PromptStudio_Video/latents/<project_id>/<generation_id>.safetensors

Writes are atomic - it saves to a temp file and renames over the target - so a crash mid-save never corrupts an earlier tail you might still want to use.

Inputs and output

  • latent - the sampled latent from SamplerCustomAdvanced (output 0), straight off the sampler.
  • project_id / generation_id - plain strings that become the folder and file name. They're validated to [A-Za-z0-9_-], so "My Project" with a space will error; use my_project.
  • context_frames - default 39, which is what the continuation path uses.

The single output, context_path, is the relative path string. In the pack's Video Studio flow you won't touch it - the web UI remembers which project/generation it saved and hands that path to the Motion Context node on the next extension automatically.

When you'll see it

The node is added by Video Studio's Continue video flow whenever you extend a render, and it's the only one of the three context nodes added in the lightweight Quick generate path (the full extension path adds the other two as well). If you're building an H3 continuation workflow by hand, the chain is: Save H3 Context on the parent's sampler output → feed its context_path into the Motion Context node's context_latent_path when you render the child. That's the whole trick - save the tail once, keep splicing it forward. Errors are rare and loud: an invalid identifier, a frame count off the grid, or a latent that isn't H3's dual video/audio stream all raise clear value errors rather than silently writing garbage. It's a bookkeeping node, but it's the bookkeeping that makes deterministic continuation possible.

CategoryPrompt Studio/Video

Inputs (4)

NameTypeDefaultDescription
latentLATENT
project_idSTRINGproject
generation_idSTRINGgeneration
context_framesINT395–56

Outputs (1)

NameTypeDescription
context_pathSTRING