ComfyUI_Cutoff  by BlenderNeko

ComfyUI nodes for localized prompt control

Created 3 years ago
395 stars

Top 73.7% on SourcePulse

GitHubView on GitHub
Project Summary

This repository provides a ComfyUI implementation of "Cutoff," a technique for precisely controlling prompt attribute influence in Stable Diffusion. It allows users to isolate specific word meanings within a prompt, preventing unintended attribute bleeding (e.g., ensuring "blue" modifies "hair" and not "shoes"). This is beneficial for users seeking finer-grained control over image generation and prompt interpretation.

How It Works

Cutoff operates by manipulating CLIP embeddings. It identifies tokens within a prompt and generates alternative embeddings where specific tokens are masked. By calculating the difference between the original and masked embeddings, it creates a directional vector that isolates the intended meaning of a token. This directional vector is then used to guide the diffusion process, enhancing control over attribute assignment within the generated image. The implementation uses three ComfyUI nodes: Cutoff BasePrompt, Cutoff Set Region, and Cutoff Regions To Conditioning (with an ADV variant for advanced weighting).

Quick Start & Requirements

  • Install via ComfyUI custom nodes manager or by cloning the repository into the custom_nodes directory.
  • Requires ComfyUI and its dependencies.
  • No specific hardware requirements beyond those for ComfyUI itself.
  • Example workflows and images are provided in the repository.

Highlighted Details

  • Enables precise control over attribute assignment in prompts (e.g., color to specific objects).
  • Offers fine-grained masking and directional embedding manipulation.
  • Includes an advanced node variant for nuanced prompt weighting interpretation.
  • Nodes are available under the conditioning > cutoff category in ComfyUI.

Maintenance & Community

  • Developed by BlenderNeko.
  • No specific community links (Discord/Slack) or roadmap are mentioned in the README.

Licensing & Compatibility

  • The repository does not explicitly state a license.
  • Compatibility with SDXL is noted as functional but potentially less effective in earlier versions (e.g., 0.9).

Limitations & Caveats

The README notes that while functional with SDXL, effectiveness may vary, particularly with older versions. The absence of an explicit license could pose compatibility concerns for commercial or closed-source projects.

Health Check
Last Commit

2 years ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
0 stars in the last 30 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems"), Jeff Hammerbacher Jeff Hammerbacher(Cofounder of Cloudera), and
6 more.

prompt-engine by microsoft

0%
3k
NPM library for LLM prompt engineering
Created 4 years ago
Updated 3 years ago
Starred by Eric Zhu Eric Zhu(Coauthor of AutoGen; Research Scientist at Microsoft Research).

poml by microsoft

0%
5k
Structured prompting for LLMs
Created 2 years ago
Updated 10 months ago
Starred by Clement Delangue Clement Delangue(Cofounder of Hugging Face), Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems"), and
10 more.

promptsource by bigscience-workshop

0%
3k
Toolkit for creating, sharing, and using natural language prompts
Created 5 years ago
Updated 3 years ago
Feedback? Help us improve.