Natural Prompt Editor Node
Tell a local LLM what's wrong with your prompt — no cloud, no key
- positive_prompt
- negative_prompt
- diff
- model_status
Natural Prompt Editor does call an API - but it's the API listening on 127.0.0.1, your own machine, and it needs no key and no cloud account. You wire up your current positive and negative prompt, type a plain-English instruction like "make the lighting golden hour, keep the score tags," and the node hands it to a small local LLM that rewrites the prompts for you. It's the "describe the change in words instead of hand-editing a tag soup" workflow, and if you already run a local chat model it's a surprisingly nice quality-of-life node.
The timing is right for it, too. Prompting genuinely differs by model family now - Pony wants its score_9, score_8_up tags, Illustrious wants masterpiece, very aesthetic, Flux and the 2026 LLM-encoded models want sentences, and pasting the wrong style's boilerplate quietly hurts you. This node bakes that knowledge into its system prompt so you don't have to keep it in your head.
How it works
The node is a thin wrapper over any OpenAI-compatible chat endpoint, with Ollama fallback. It builds a system prompt that tells the model to return strict JSON - {"positive": ..., "negative": ..., "diff": ...} - and includes style-specific rules: preserve Pony score/source tags, preserve Illustrious aesthetic tags, keep Flux output as concise natural language, and so on.
Then it sends your instruction plus base_positive / base_negative as the user message. The reply is parsed (it even strips code fences, since local models love wrapping JSON in them), and the three outputs come back. If anything fails, it degrades gracefully: it returns your base prompts untouched and puts the error in diff instead of crashing the graph.
prompt_style defaults to auto, which is the clever bit. The node reads your base positive and guesses the family - Pony score tags → pony, masterpiece/aesthetic → illustrious, sentence-like structure → flux, otherwise sdxl. It gets the obvious cases right, and you can always force a style if it guesses wrong.
The inputs that matter
There are ten inputs, but a beginner really touches three:
- instruction - what you want changed, in words. The whole point of the node.
- base_positive / base_negative - your current prompts, pasted in.
- prompt_style - leave it on
autountil it misdetects.
The rest are mostly server plumbing. api_base defaults to http://127.0.0.1:1234/v1, which is LM Studio's default port, and model / expected_model default to Qwen2.5-3B-Instruct. temperature (0.2 default) and timeout_sec (60) do what they say.
The four outputs are positive_prompt, negative_prompt, diff, and model_status. Wire the first two into your CLIP Text Encode nodes; diff is a plain-English summary of what changed (and where errors land); model_status tells you whether the model check passed.
Installing it
Install via ComfyUI Manager (search "Natural Prompt Editor"), or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/Lumi4s/natural_prompt_editor
Then restart ComfyUI. The pack itself has essentially no dependencies - it uses requests, which ComfyUI already brings - and downloads no model files. That's the part people miss: the heavy lifting is on you. You need LM Studio (default) or Ollama running locally with a small instruct model loaded, e.g. Qwen2.5-3B-Instruct. It's a tiny cookiecutter-scaffolded project - the tests and docs still reference an example node that doesn't ship - so expect rough edges, not polish.
When it bites
Two failure modes are coded right into it. First, if your server isn't reachable, list_available_models() comes back empty and with strict_model_check on (default) the node raises instead of proceeding - check LM Studio is running and the port matches. Second, the wrong-model guard: if the server's loaded model doesn't match expected_model, you get a WRONG MODEL exception. Fix it by typing the actual loaded name into expected_model, or flip strict_model_check off.
Also: the diff output is the honest place to look before trusting the edit. Small 3B models occasionally drop a tag or "helpfully" normalize your prompt into a style you didn't want. Check what it says it changed - the node at least tells you.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| instruction | STRING | — | |
| base_positive | STRING | — | |
| base_negative | STRING | — | |
| api_base | STRING | http://127.0.0.1:1234/v1 | — |
| model | STRING | Qwen2.5-3B-Instruct | — |
| expected_model | STRING | Qwen2.5-3B-Instruct | — |
| strict_model_check | BOOLEAN | true | — |
| timeout_sec | INT | 601–600 | — |
| temperature | FLOAT | 0.200–2 | — |
| prompt_style | COMBO | auto | 6 options: auto, sdxl, pony, illustrious, flux, generic |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| positive_prompt | STRING | — |
| negative_prompt | STRING | — |
| diff | STRING | — |
| model_status | STRING | — |