Nodes/arkennemasis Nodes/arkennemasis Job Record (durable state)
ComfyUI Node

arkennemasis Job Record (durable state)

The write that makes a run resumable

By Hishamahmer·Created 2 months ago·Updated 8 days ago· 9
arkennemasis Job Record (durable state)
    • job_json
    • status
    • summary
    cell_json{}
    jobs_dirvariation/jobs
    verdict_json{}
    master_path
    recipe_json
    prompt_hash
    qc_diagnosis
    qc_passedtrue

    ArkJobRecord is the memory of the arkennemasis Variation pipeline. It takes a finished cell - the verdict, the measurements, the master's path - and writes it to durable storage as a per-cell JSON record. That write is what makes the whole resume system work: without it, a run that dies at cell 19 of 24 has no way to know cells 1–18 are done, and the restart pays for everything again.

    Think of it as the ledger the pipeline keeps. Job Skip reads that ledger before spending on a cell; Job Record is the node that writes it. One writes, one reads, and between them a 24-image batch can be interrupted and resumed without re-billing a single finished cell.

    What it records

    Required inputs: cell_json (the cell, whose key identifies the record), jobs_dir (where the per-cell JSONs live - same durable folder Job Skip reads, default variation/jobs), and verdict_json from Verify Candidate - the measurements and the pass/soft/hard result. The verdict is the payload: it gets stored on the attempt, so a flagged cell says why it was flagged rather than only that it was.

    The optional inputs fill in the rest of the record:

    • master_path - where the accepted image was written. This is what lets Job Skip read the master back off disk instead of regenerating.
    • recipe_json - supplies the recipe hash, so a later recipe change correctly invalidates cells made under the old one.
    • prompt_hash - the prompt's hash for this attempt.
    • qc_diagnosis and qc_passed - the critic's explanation and verdict. The diagnosis is recorded on the attempt, which is the difference between "cell 7 failed" and "cell 7 failed because the background bled into the region."

    Outputs: job_json (the full updated record), status, and summary - useful for feeding a run report or a log node.

    Two details worth knowing

    It's an output node that always re-runs. IS_CHANGED returns NaN, so the record is rewritten every time it executes - appropriate, because a durable record should reflect the latest state, not sit in ComfyUI's cache.

    The records live outside the graph. One JSON per cell in jobs_dir, which is on disk and meant to survive runs. This is the "durable" in the node's own name - and it's why the tooltip on Job Skip warns never to point this at a per-run folder. A per-run folder is temporary by construction; durable storage is not.

    Where it sits

    The chain is: generate → verify (Verify Candidate) → Job Record → deliver (Deliver). The natural wiring is Verify Candidate's verdict_json into this node's verdict_json, and Deliver's master_path into master_path - so the record captures both the measurements and where the accepted file went. Then the next time Job Skip sees this cell's key, the master is waiting on disk and the generation branch is skipped entirely.

    Installing

    It's part of the comfyui-arkennemasis pack:

    cd ComfyUI/custom_nodes
    git clone https://github.com/Hishamahmer/comfyui-arkennemasis
    pip install replicate httpx
    

    restart, and it appears under arkennemasis/Variation. No models, no API keys. The beginner trap is treating this as optional bookkeeping and skipping it on a short run - then realising a week later that nothing on disk remembers what you already paid for. Wire it in from the start; it costs nothing to run and it's the only thing standing between you and a fully re-billed second pass.

    Categoryarkennemasis/Variation

    Inputs (8)

    NameTypeDefaultDescription
    cell_jsonSTRING{}
    jobs_dirSTRINGvariation/jobs
    verdict_jsonSTRING{}From Verify Candidate — the measurements and the pass/soft/hard result.
    master_pathoptSTRINGWhere the accepted image was written.
    recipe_jsonoptSTRING
    prompt_hashoptSTRING
    qc_diagnosisoptSTRINGThe critic's explanation. Recorded on the attempt, so a flagged cell says WHY it was flagged rather than only that it was.
    qc_passedoptBOOLEANtrue

    Outputs (3)

    NameTypeDescription
    job_jsonSTRING
    statusSTRING
    summarySTRING