Nodes/playbook-comfyui/Load from Playbook
ComfyUI Node

Load from Playbook

Turn a board into an IMAGE batch your graph can chew on

By playbook-labs·Created 10 days ago·Updated a day ago· 0
Load from Playbook
    • images
    • masks
    • asset_tokens
    mode
    limit4
    query
    board
    include_subboardstrue
    tags
    statuses
    match_sizetrue
    originalstrue
    refresh0
    api_key
    workspace

    LoadImage reads one file from ComfyUI/input/. This reads a board - a whole set of assets in Playbook, filtered by tag and approval status - and hands back a normal IMAGE batch plus an alpha mask batch. That's the trick: a shared asset library the graph can just consume.

    The review loop is where it pays off. The usual version of that is generate a pile, have a client or art director mark the good ones, then spend twenty minutes downloading files and re-uploading them into input/. Here you point one node at the board, filter to statuses: Approved, and the signed-off batch is in the graph - restyle it, upscale it, inpaint with the masks it gives you, or feed a curated slice into a training set (captioning is lora-training.md's problem; this is the other half). It's the natural partner to Save to Playbook: generate, upload, review, reload, refine. Like the API-wrapper nodes in external-api-nodes.md it's an HTTP client, except what it talks to is a file board, not an inference service.

    The three modes

    board pulls one board, sub-boards included unless you turn include_subboards off. It needs the board token from the Pick board button; leave it blank and the node stops you with "Pick a board, or switch mode to search."

    search is a keyword search across the workspace using query. semantic search runs the same query through Playbook's ai_search endpoint - the one to use when you remember the picture but not the words on it.

    limit (default 4, max 64) caps the batch; every asset costs a download, so it isn't a free knob.

    What you actually set

    • mode and limit - required. Start with board.
    • board, tags, statuses - the filters, tags and statuses comma-separated. Filtering on Approved is the entire point of pairing this with the save node.
    • match_size - on by default, and it does more than it says. A batch is one stacked tensor, so everything is resized to the first image's dimensions with Lanczos - mixed aspect ratios get squashed to match, not letterboxed. Turn it off and you get a clear error naming the offending asset and both resolutions instead.
    • originals - also on. Playbook's normal display_url is imgproxy output, a WebP transcode, so feeding it back into a graph silently re-encodes every asset you thought you were reusing. The stored file costs one extra API request per asset; turn it off when approximate is fine.
    • refresh - an integer that does nothing except change. ComfyUI caches node outputs and a board is a live remote source, so without this you'd get the same four images forever. Bump it to re-fetch; the default of 0 is deliberate, since invalidating every run would re-run everything downstream on every queue.

    Outputs are images, masks (the inverted alpha, same convention as LoadImage, and zeroes when the file has no alpha), and asset_tokens - comma-separated, in batch order. Wire the image and mask pair into an inpaint or detailer setup exactly like a LoadImage pair.

    Install

    Same pack, same one-time setup. ComfyUI Manager, search Playbook (registry package playbook-creative), or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/playbook-labs/playbook-comfyui
    

    The only Python dependency is requests; no models to download. Restart ComfyUI and press Connect Playbook on either node - the key is shared and lives at user/playbook/credentials.json, mode 0600, never as a widget value, because widget values ride along in workflow.json and in the PNG text chunks of every render you share (image-io-metadata.md). Headless installs use PLAYBOOK_API_KEY and PLAYBOOK_WORKSPACE; on a --multi-user server that's the only option.

    Where people get burned

    "Playbook returned no images for that board or query." That's the only failure you get when filters match nothing, and it doesn't say which filter did it. Wrong board token, sub-boards excluded when the assets live in one, a status name that doesn't match - same message every time. Peel the filters off one at a time until something appears.

    Stale results that look like a bug. You approve an asset, re-run, and get yesterday's list. Nothing is wrong; the node is cached. Bump refresh. In reverse, if you want a stable batch for a run you're going to repeat, leave refresh alone.

    Files it quietly skips. Non-images get dropped, along with SVG and Photoshop files - Playbook treats those as images, Pillow can't decode them. Skips go to the console rather than raising, so an oddly short batch usually has an explanation in the terminal.

    Masks that come back black. No alpha in the file, no mask. Correct, and identical to LoadImage's behavior.

    Endpoint exposure. The node's HTTP routes are as open as any custom node's on a shared server (comfyui-ecosystem.md) - the key is never readable back through them, but don't point a public tunnel at ComfyUI and act surprised.

    CategoryPlaybook

    Inputs (12)

    NameTypeDefaultDescription
    modeCOMBO3 options: board, search, semantic search
    limitINT41–64
    queryoptSTRING
    boardoptSTRINGBoard token. Use 'Pick board' to fill it.
    include_subboardsoptBOOLEANtrue
    tagsoptSTRINGComma separated.
    statusesoptSTRINGComma separated, e.g. Approved.
    match_sizeoptBOOLEANtrueResize everything to the first image so it batches.
    originalsoptBOOLEANtrueLoad the stored file rather than Playbook's WebP render. Costs one extra API request per asset; turn it off to save quota when exact pixels do not matter.
    refreshoptINT00–4294967295Bump to re-fetch. The board is a live source, but invalidating every run would re-run the whole graph.
    api_keyoptSTRING
    workspaceoptSTRINGWorkspace slug. Required alongside api_key.

    Outputs (3)

    NameTypeDescription
    imagesIMAGE
    masksMASK
    asset_tokensSTRING