Save 4 hours! We auto-setup your workflow! Free!

Drop your workflow.json — we handle every dependency, custom node, and model. Just open the link and run.

Auto-Setup Workflow Json (Free) Now!
ComfyUI > Nodes > Nucleus-Image-comfyui-beta > Nucleus-Image Text Encode (Dual)

ComfyUI Node: Nucleus-Image Text Encode (Dual)

Class Name

NucleusImageTextEncodeDual

Category
Nucleus-Image
Author
a180265 (Account age: 1788days)
Extension
Nucleus-Image-comfyui-beta
Latest Updated
2026-04-22
Github Stars
0.0K

How to Install Nucleus-Image-comfyui-beta

Install this extension via the ComfyUI Manager by searching for Nucleus-Image-comfyui-beta
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Nucleus-Image-comfyui-beta in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Nucleus-Image Text Encode (Dual) Description

Encodes positive and negative Nucleus-Image prompts into separate conditioning with one model load.

Nucleus-Image Text Encode (Dual):

NucleusImageTextEncodeDual converts two text prompts into conditioning for a Nucleus-Image workflow: one for the desired image and one for what you want to avoid. It processes both prompts during a single text-encoder model load, rather than loading the model separately for each prompt. The implementation describes this as avoiding a second load of an approximately 8.2 GB model and roughly halving encoding time; your actual time savings will depend on your system. The node encodes the prompts separately, preserving their distinct roles for later steps in the workflow.

Nucleus-Image Text Encode (Dual) Input Parameters:

text_encoder

A required NUCLEUS_TE input that provides the text-encoder resource. The node uses its model path to load the encoder that turns your prompts into conditioning. Connect a compatible Nucleus text-encoder output here; ordinary text or a different model type will not serve the same purpose. No default, minimum, maximum, or selectable options are specified.

positive_text

A required, multiline STRING field for the text you want encoded as positive conditioning. Write the description you want the image workflow to follow here; changing this text changes the positive conditioning produced by the node. The default is an empty string. No minimum or maximum text length is specified in the interface, although the implementation processes text with a maximum tokenized length of 1,024 and enables truncation, so content beyond that limit may not be represented.

negative_text

A required, multiline STRING field for the text you want encoded as negative conditioning. Use it to describe qualities you want the subsequent image workflow to avoid; changing it changes the negative conditioning produced by this node. The default is an empty string. No minimum or maximum text length is specified in the interface, but the same 1,024-token processing limit and truncation apply.

Nucleus-Image Text Encode (Dual) Output Parameters:

positive

A NUCLEUS_CONDITIONING value created from positive_text. It contains prompt_embeds, the encoded representation of the prompt, and prompt_mask, which identifies relevant positions when a mask is needed. If every position is attended, the node sets the mask to None. Connect this output to a downstream input expecting positive Nucleus conditioning; it is not a readable text prompt or a finished image.

negative

A NUCLEUS_CONDITIONING value created from negative_text. It has the same prompt_embeds and prompt_mask structure as the positive output, but represents the separately encoded negative prompt. Connect it to a downstream input expecting negative Nucleus conditioning. The meaning and effect of that conditioning depend on the downstream image-generation workflow.

Nucleus-Image Text Encode (Dual) Usage Tips:

  • Connect a compatible NUCLEUS_TE resource before running the node; the implementation requires a model path from that resource.
  • Put what you want to see in positive_text and what you want to avoid in negative_text, then connect the two outputs to their corresponding downstream inputs.
  • Keep the most important prompt details early and concise. Tokenization is capped at 1,024 tokens with truncation enabled, so later content in a very long prompt may be discarded.
  • Use this dual node when your workflow needs both positive and negative conditioning: it loads the text-encoder model once for both encodings. The model still needs sufficient memory to load and run.

Nucleus-Image Text Encode (Dual) Common Errors and Solutions:

Missing required input: text_encoder

  • Explanation: The node cannot load a text encoder without its required NUCLEUS_TE connection. The exact wording of a missing-input message depends on the host application.
  • Solution: Connect a compatible Nucleus text-encoder resource to text_encoder and run the workflow again.

KeyError: 'model_path'

  • Explanation: The supplied text_encoder value does not contain the model_path entry that this implementation reads. This can indicate an incompatible or incomplete upstream resource.
  • Solution: Check the upstream node and reconnect an output that supplies a valid NUCLEUS_TE resource with its model path.

FileNotFoundError or OSError while loading the text encoder or processor

  • Explanation: The implementation loads model weights, a text-encoder configuration, and processor files. A missing or inaccessible required file can stop encoding. The precise error message depends on which file failed to load.
  • Solution: Check that the Nucleus-Image installation and its required model, configuration, and processor files are present in their expected locations and readable by the application.

ModuleNotFoundError: No module named 'transformers'

  • Explanation: The implementation imports components from transformers when the node runs; this error means that package is unavailable in the application's Python environment.
  • Solution: Install the dependencies required by your Nucleus-Image installation into the same Python environment used by the application, then restart it.

CUDA out of memory

  • Explanation: Loading and running the text encoder on the selected device can exceed available GPU memory. Loading it once for both prompts reduces repeated loading, but does not remove its memory requirement.
  • Solution: Free GPU memory used by other tasks, close other model-heavy applications or workflows, and retry on hardware with enough available memory.

Model-loading or device compatibility error

  • Explanation: The node constructs the encoder in bfloat16 and loads its weights onto the selected device. An incompatible device, weights, or software environment can cause a failure during model loading or inference; the exact message depends on the underlying library.
  • Solution: Confirm that the selected device and installed software support the required model operations, and that the model weights match your Nucleus-Image installation.

Nucleus-Image Text Encode (Dual) Related Nodes

Go back to the extension to check out more related nodes.
Nucleus-Image-comfyui-beta
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.

Nucleus-Image Text Encode (Dual)