ComfyUI Node
π¦ Bulk Prompt Ollama Improver
Improve each prompt with a local Ollama model (official ollama library), optionally trimming any chat wrapper the model adds. Use the π Reconnect button to load the model list.
π¦ Bulk Prompt Ollama Improver
- result
- context
- meta
βinstructionYou are an expert prompt engineer for image generation. Rewrite the following prompt to be more vivid and detailed. Output ONLY the improved prompt, with no preamble or explanation.βΊ
βurlhttp://127.0.0.1:11434βΊ
βmodelβΎβΊ
βkeep_alive_minutes5βΊ
βtimeout120βΊ
βenabledtrueβΊ
βtrim_outputtrueβΊ
βpositiveββΊ
βcontextββΊ
CategoryBulkPrompt
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| instruction | STRING | You are an expert prompt engineer for image generation. Rewrite the following prompt to be more vivid and detailed. Output ONLY the improved prompt, with no preamble or explanation. | System prompt β tell the model what to do with the prompt. |
| url | STRING | http://127.0.0.1:11434 | Ollama server URL. Change this for a custom host/port (e.g. http://192.168.1.50:11434), then click π Reconnect. |
| model | COMBO | Pick a model (auto-loaded from the Ollama server at the default URL). After changing url or pulling new models, click π Reconnect to refresh the list. | |
| keep_alive_minutes | INT | 5-1β1440 | Minutes Ollama keeps the model loaded after inference (-1 = keep forever, 0 = unload immediately). |
| timeout | INT | 1205β3600 | Max seconds to wait for the response. Large models (e.g. 14B) need more β the first run also loads the model into VRAM. Use 300+ if you hit timeouts. |
| enabled | BOOLEAN | true | If off, the prompt passes through unchanged (no Ollama call). |
| trim_output | BOOLEAN | true | Keep only the prompt: strip any chat wrapper the model adds (preambles, '---'/code-fence/'Prompt:' headers, trailing offers). Turn off to use the raw reply. |
| positive | STRING | β | |
| contextopt | STRING | Optional Ollama context (comma-separated ints) for multi-turn continuity. |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| result | STRING | β |
| context | STRING | β |
| meta | STRING | β |