Aller au contenu
Node packVérifiéExterne
Ouvrir la source

comfyui-watermark-remover

Mainteneur@Slartibart23D · adoptionClasse

Profil du package

Statut
Vérifié
Éditeur
@Slartibart23
Source
GitHub

LIREMOI

ComfyUI – Watermark Sentence Remover

A custom ComfyUI node that batch-processes .txt files from an input folder, removes every sentence containing the word "Watermark", and saves the cleaned files to an output folder – keeping the original filenames.


Features

  • Processes all .txt files in the specified input folder sequentially
  • Removes any sentence that contains the word Watermark (case-insensitive by default)
  • Saves cleaned files to a user-defined output folder with the original filename
  • Creates the output folder automatically if it does not exist
  • Optional Dry Run mode – analyse without writing any files
  • Optional Case Sensitive mode
  • Returns a status message, file count, and removed-sentence count as node outputs
  • Compatible with Python 3.13+

Installation

  1. Clone or download this repository into your ComfyUI custom nodes folder:
cd ComfyUI/custom_nodes/
git clone https://github.com/Slartibart23/comfyui-watermark-remover.git
  1. Restart ComfyUI.

The node will appear in the node menu under text › processing as "Watermark Sentence Remover 🧹".


Node Inputs

InputTypeRequiredDescription
input_folderSTRING✅Full path to the folder containing source .txt files
output_folderSTRING✅Full path to the folder where cleaned files will be saved
dry_runBOOLEAN➖If enabled, no files are written (default: off)
case_sensitiveBOOLEAN➖If enabled, only Watermark (capital W) is matched (default: off)

Node Outputs

OutputTypeDescription
status_messageSTRINGHuman-readable processing summary
files_processedINTNumber of files successfully processed
sentences_removedINTTotal number of sentences removed across all files

How It Works

Sentences are identified by the period . character as a terminator.

Example input:

This is a normal sentence. This image contains a Watermark from Example Corp. Enjoy your day.

Example output:

This is a normal sentence. Enjoy your day.

The sentence "This image contains a Watermark from Example Corp." is detected and removed. The surrounding sentences are left intact.


Running Tests

cd comfyui-watermark-remover
pip install pytest
python -m pytest tests/ -v

Requirements

  • Python 3.13+
  • ComfyUI (any recent version)
  • No additional Python packages required (uses standard library only)

License

MIT License – see LICENSE for details.

Nœuds dans ce pack

Nœud 1
  • WatermarkRemoverNode

Sources

3 sources
GitHubSourceVersion 8a51cc108865ef26035d0d6e2af57347c5843ece
github.com/Slartibart23/comfyui-watermark-remover

Vérifié 11 oct.

Extraits de sources

1 extrait

Source context: Repo Slartibart23/comfyui-watermark-remover