Nodes/PromptModels Studio/Google AI - Workflow Analyzer
ComfyUI Node

Google AI - Workflow Analyzer

Paste someone's JSON, get a plain-English breakdown

By cdanielp·Created 9 months ago·Updated 2 months ago· 28
Google AI - Workflow Analyzer
    • analysis_report
    workflow_json
    api_key
    modelgemini-3.1-pro-preview

    You download a workflow from the internet, load it in ComfyUI, and it's a wall of nodes you've never seen. Or a friend sends you a .json and asks "why is this broken?" This diagnostic node exists for exactly that moment: hand it the workflow JSON and it gets Gemini to explain what the graph is doing - what each node is, what's being loaded, how the pieces connect.

    The mechanism is a neat two-step. First it parses the JSON you give it - and this is the clever bit, it handles both formats ComfyUI workflows come in: the raw API format (a dict of node IDs with class_type fields) and the UI format (nodes[] with type fields), plus it accepts either pasted JSON or a filesystem path to a .json file. It collects every unique node type into a list, then sends that list to Gemini with a prompt asking for analysis. What comes back is the analysis_report string.

    The inputs that matter

    • workflow_json - the only required input. Paste the raw workflow JSON, or a path like C:\downloads\myworkflow.json.
    • model - defaults to gemini-3.1-pro-preview. If you just want a fast read, the flash models in the combo are cheaper and plenty good at this task.
    • api_key - leave empty; resolved from .env as GEMINI_API_KEY.

    Output: one analysis_report STRING. It's a text node, so wire it to a text display widget and read it there.

    Where this is (and isn't) useful

    Honestly? It's a debugging and learning aid, not a build tool. It's genuinely handy when a workflow won't load because a node type is missing - the report tells you what's referenced, so you know what pack to install. It's also a decent first pass at understanding someone's complex graph before you start deleting nodes. What it won't do is fix the workflow or check your wiring; it's reading a node list, not executing anything. If you feed it a malformed JSON it just returns an error string rather than crashing, which is the right behavior for a diagnostic node.

    Installing it

    ComfyUI Manager → search "COMFYUI_PROMPTMODELS" → install → restart, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/cdanielp/COMFYUI_PROMPTMODELS
    

    Add GEMINI_API_KEY=AI... to the pack's .env and restart. ComfyUI >= 0.26.0 required; dependencies are requests and Pillow.

    Gotchas

    Key hygiene is the recurring theme of this pack: .env, not the node field, or the key ends up in your workflow JSON and PNG metadata. And remember the output quality is only as good as the model - with the default Pro model and the full node list of a big workflow, the response can get long and rambly. Ask it targeted questions by trimming the JSON first if you want a focused answer. Also, this one's a paid Gemini call per run - free tier gives you a little, but repeated debugging sessions will burn credits.

    CategoryGoogle AI/Diagnostic

    Inputs (3)

    NameTypeDefaultDescription
    workflow_jsonSTRINGJSON del workflow o ruta al archivo .json.
    api_keyoptSTRING
    modeloptCOMBOgemini-3.1-pro-preview4 options: gemini-3.1-pro-preview, gemini-3-flash-preview, gemini-2.5-flash, gemini-2.5-pro

    Outputs (1)

    NameTypeDescription
    analysis_reportSTRING