comfyui-prompt-format

comfyui-prompt-format
★ 35

提示词格式化去重下划线替换ComfyUI扩展
为ComfyUI在文本框添加Format按钮,自动整理提示词:去除多余空格/逗号、修复括号、可去重并替换下划线,保留换行。
💡 在发送给模型前一键清理和格式化提示词。
🍴 5 Forks💻 JavaScript🔄 2025-11-19
📦
网盘下载
复制链接后前往夸克网盘下载
https://pan.quark.cn/s/e00a65475347
📄 README

# ComfyUI Prompt Format

This is an Extension for ComfyUI, which helps formatting texts.

Features

This adds a button, Format, to the menu which when clicked will:

  • [x] Remove extra spaces and commas
  • [x] Fix misplaced brackets and commas
  • [x] Enable Remove Duplicates to remove identical tags found in the prompts
  • Note: Only works for tag-based prompt, not sentence-based prompt
  • e.g. 1girl, solo, smile, 1girl will become 1girl, solo, smile
  • e.g. a girl smiling, a girl standing will not be changed
  • [x] Enable Remove Underscores to replace _ with space
  • [x] Respect line breaks
  • Remove Duplicates only checks within the same line
  • [x] Append a comma every line break
  • [x] Pressing Alt + Shift + F can also manually trigger formatting