Nodes/ComfyUI-AuK_Doc/AuK OpenAI Settings_Doc
ComfyUI Node

AuK OpenAI Settings_Doc

The node that doesn't call anything (and why that's fine)

By DocWorkBox·Created 23 days ago·Updated 23 days ago· 4
AuK OpenAI Settings_Doc
    • llm_config
    ◄base_urlhttps://api.openai.com/v1►
    ◄api_key►
    ◄model►
    ◄temperature0.00►
    ◄top_p1.00►
    ◄max_tokens4096►
    ◄timeout_sec120►

    Here's the thing that confuses people about this node: it never talks to anything. No request leaves your machine when you run it, because there's nothing to run - it's a config holder that packages a base URL, a key and a few sampling knobs into an AUK_LLM_CONFIG_Doc value for the AuK Generate node to pick up. The actual call happens there, inside the Prompt Enhancer. If you wired it up and saw zero network activity, that's the design working.

    What it's for

    The Prompt Enhancer inside AuK Generate / Edit_Doc is a multi-step LLM job. It classifies your free-form request into an AuK task type, rewrites it into the official template wording, and estimates a target duration when you leave generation_seconds at 0. That means real chat completions calls.

    You've got three ways to supply the model, and this node is the explicit one:

    1. Environment variables on the server (LLM_API_KEY, LLM_BASE_URL, LLM_MODEL_NAME) - what the Gradio demo path uses, and the fallback when Generate's llm_config socket is empty.
    2. This node, for any OpenAI-compatible Chat Completions endpoint you can reach over HTTP.
    3. AuK Llama.cpp Adapter_Doc, for a local GGUF file with no server at all.

    If you're running against LM Studio, vLLM, llama.cpp's server or a reseller, path 2 is the one you want, because it keeps credentials in the graph instead of in a shell profile.

    The fields, and the two that matter

    base_url and model are the only ones that will stop you. The URL should be the API root - https://api.openai.com/v1 by default - and the node strips a trailing slash and silently removes a trailing /chat/completions if you pasted the full endpoint. It then validates that what's left is http or https, has a host, and carries no query string, fragment or embedded credentials. Malformed URLs fail at queue time with a readable message instead of a 404 twenty seconds into an enhancement.

    model has no default and is required non-empty: "the model ID provided by your service." Whatever your endpoint calls it - gpt-4o-mini, Qwen3-8B, qwen3-vl-32b-instruct - the node can't guess, and won't.

    api_key is where the design gets nice: leave it blank for a local server with no auth. Blank becomes the literal placeholder not-required, so the OpenAI client is happy and your keyless Ollama/LM Studio endpoint doesn't 401. Never paste a key in and share the workflow, though - the field is a widget, so it's saved inside the JSON. The pack's README says to clear it before sharing; do that, and price in that a shared workflow is a shared key otherwise (external-api-nodes.md makes the same point about API nodes generally).

    The rest are advanced and mostly fine at defaults:

    • temperature (0 by default) - leave it. The job is "follow a format and stop," not "be creative." A hotter setting here means a rewritten instruction that drifts off the template (llm-in-comfyui.md § 1 is the long version of why small and obedient beats clever for this).
    • top_p 1.0, max_tokens 4096, timeout_sec 120. The timeout is per call, and the enhancer makes more than one per run, so a slow free endpoint needs this raised rather than retried.
    • max_tokens at 4096 is generous for a prompt rewrite; the ceiling exists because thinking-mode models will happily eat it.

    Output is a single llm_config socket. Wire it to Generate's llm_config input, and make sure Enable Prompt Enhancer is on - the settings node is ignored completely when it isn't.

    Install

    Same pack, same steps as everything else here:

    cd ComfyUI/custom_nodes
    git clone https://github.com/DocWorkBox/ComfyUI-AuK_Doc
    cd ComfyUI-AuK_Doc
    python -m pip install -r requirements.txt
    

    Restart ComfyUI. Or install ComfyUI-AuK_Doc from ComfyUI Manager. It needs openai>=1.0.0, which the requirements list carries. This node has no model files of its own - the AuK and Qwen weights are what the pack actually downloads, and the LLM is whatever's behind your base_url.

    Troubleshooting

    • "Fill in the model ID supplied by your LLM service." The most common failure, and it's literally a blank text field. Other OpenAI-compatible tools default to a model name; this one makes you type yours.
    • 404 on the enhancer - you probably pointed base_url at a bare host. Most servers need the /v1 (or equivalent) segment; this node removes a /chat/completions suffix but won't invent a prefix.
    • Timeouts on a local model - 120 s is fine for a hosted API and can be tight for a 14B on a busy card, especially since the classifier call and the rewrite call are separate. Raise timeout_sec before blaming the pack.
    • Nothing happens at all - check the Prompt Enhancer info output on the Generate node. It prints the detected task, the final target duration and the ASR transcript, so a misclassified request is visible instead of mysterious.
    • It works in your graph and breaks in a shared one - you cleared the key and left the URL pointing at a local port. Swap to the llama.cpp adapter, or accept that the recipient needs their own credential.
    CategoryAuK_Doc

    Inputs (7)

    NameTypeDefaultDescription
    base_urlSTRINGhttps://api.openai.com/v1API base URL, usually ending in /v1. A trailing /chat/completions is removed automatically.
    api_keySTRINGAPI key. Leave blank for a local server without authentication.
    modelSTRINGModel ID provided by your service.
    temperatureFLOAT0.000–2—
    top_pFLOAT1.000.01–1—
    max_tokensINT40961–131072—
    timeout_secINT1201–3600—

    Outputs (1)

    NameTypeDescription
    llm_configAUK_LLM_CONFIG_Doc—