NInfer - System Prompt
Pick a behaviour like you pick a checkpoint
- other_options
- Options
The system prompt is the instruction that applies to everything the model does in a conversation, and in this pack it does double duty: there's a text box you can type into, and a dropdown that loads a markdown file off your disk and appends it. That second half is the interesting one.
The author's framing is the right one - a skill file lets a workflow pick a behaviour the same way it picks a checkpoint. Instead of pasting your house prompt-enhancer instructions into a node every time, you keep prompt_enhancer.md in a folder, select it from the dropdown, and every workflow that uses it stays in sync.
How the two halves merge
Plain text first, then the file, joined by a blank line. If the text box is empty you get just the skill; if the skill is (none) you get just your text. Nothing is stripped out and no template is applied - whatever is in the file becomes system prompt verbatim.
Downstream, the Chat node takes that merged string and inserts it as the first message of the request with role: system. If a history payload is already in play and its first message is a system or developer message, that one gets replaced rather than duplicated - so editing this node genuinely changes the instructions for a multi-turn chain instead of stacking a second system prompt on top, which is the failure you'd get hand-rolling this.
Inputs and outputs
- System Prompt - multiline text. Instructions that apply to the whole conversation.
- Skill File - a dropdown of markdown and text files found in the skills directory, plus a
(none)sentinel. - Options (optional, input) - the merged settings handed down from an earlier option node.
- Options (output) - the same settings dictionary with
system_promptset. Wire this into the next option node, or straight into the Chat node'soptionsinput if this is the only option you're using.
Skills on disk
A skill is just a .md or .txt file. Write it as instructions to the model, keep it short, and say what you don't want - the README's own example explicitly forbids the words "beautiful" and "masterpiece", which is a good habit given how much slop these models will happily generate unprompted.
The skills directory resolves like this, first hit wins:
NINFER_SKILLS_DIR<ComfyUI>/input/skills<ComfyUI>/../Input/skills
# can't find the folder? make the portable default and it starts working immediately
mkdir -p ComfyUI/input/skills
echo "# Skill: cinematic still" > ComfyUI/input/skills/cinematic-still.md
Group them in sub-folders once you have more than a handful, one per model or task:
<skills>/
qwen-image-2.1/prompt_enhancer.md
minimax-h3/camera-motion.md
cinematic-still.md
The dropdown shows the path relative to the skills root, so two folders can each hold a prompt_enhancer.md without colliding. Up to three path components are offered (a/b/c.md works, a/b/c/d.md is ignored), hidden folders are skipped, and only .md/.txt files are listed. Note the deliberate quirk in the tooltip: skill paths are not derived from ComfyUI's --input-directory setting, because folder_paths.get_input_directory() reports the built-in <ComfyUI>/input even when the server loads images from somewhere else - deriving from it alone silently read an empty folder, which was a real bug in this pack's history.
Where people get burned
Restart after editing. ComfyUI caches node definitions, so a new or renamed skill file doesn't show up in the dropdown until you restart. Same story for the Chat node's schema.
A skill is not a magic personality. The system prompt is upstream of everything; if your skill asks the model to return bare JSON and the model returns a chatty preamble, that preamble lands in your prompt-as-text wherever you wire Response. The community's standard defense applies - narrow the job and ask for one format, or constrain it with response_format via the Extra Body node.
Both fields on purpose. Typing a system prompt and selecting a file means getting both, text first. If output looks doubled, that's why.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| system_prompt | STRING | Instructions applied to the whole conversation | |
| skill | COMBO | (none) | Markdown appended to the system prompt. Files come from /tmp/ComfyUI/input/skills. |
| other_optionsopt | NINFER_OPTIONS | Options from the previous settings node |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| Options | NINFER_OPTIONS | Merged settings |