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 > Sage Utils > Set Text With Number

ComfyUI Node: Set Text With Number

Class Name

Sage_SetTextWithNum

Category
Sage Utils/text
Author
arcum42 (Account age: 6442days)
Extension
Sage Utils
Latest Updated
2026-05-17
Github Stars
0.03K

How to Install Sage Utils

Install this extension via the ComfyUI Manager by searching for Sage Utils
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Sage Utils 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

Set Text With Number Description

Facilitates dynamic text creation by appending numbers to text with customizable prefix/suffix.

Set Text With Number:

The Sage_SetTextWithNum node is designed to facilitate the creation of text strings that are dynamically constructed by appending a numerical value to a base text. This node is particularly useful when you need to generate text outputs that include numerical data, such as scores, counts, or any other numeric information, seamlessly integrated into a textual context. By allowing you to specify a prefix and suffix, this node provides flexibility in formatting the final output, making it adaptable to various use cases where text and numbers need to be combined. The primary goal of this node is to streamline the process of text generation with embedded numerical values, enhancing the efficiency and effectiveness of your text-based workflows.

Set Text With Number Input Parameters:

str

This parameter represents the main text content that you want to set. It serves as the core of the output string, to which a number will be appended. The input is a string and can be multiline, allowing for complex text structures. There is no minimum or maximum length specified, and it defaults to an empty string if not provided.

prefix

The prefix parameter allows you to add a string at the beginning of the main text. This can be useful for adding context or labels to the text. It is optional and can be multiline. If not specified, it defaults to an empty string.

suffix

Similar to the prefix, the suffix parameter lets you append a string to the end of the main text, just before the number. This can be used to add units or additional context to the number. It is optional and can be multiline, defaulting to an empty string if not provided.

num_type

This parameter determines the type of number to be appended to the text. It offers two options: float and int. Depending on the selection, you can input a floating-point number or an integer. The float option allows for a default value of 0.0 with a step of 0.01, while the int option defaults to 0. This flexibility enables precise control over the numerical data included in the output.

Set Text With Number Output Parameters:

str_out

The str_out parameter is the final output of the node, which is a string that combines the prefix, main text, suffix, and the appended number. This output is crucial as it represents the complete text with the integrated numerical value, ready for use in subsequent processes or displays. The output is a single string that reflects the inputs provided, ensuring that the text and number are seamlessly combined.

Set Text With Number Usage Tips:

  • Use the prefix and suffix parameters to add context to your text, such as units or labels, which can make the output more informative and user-friendly.
  • When dealing with floating-point numbers, consider the precision required for your application and adjust the num_type input accordingly to ensure the output meets your needs.

Set Text With Number Common Errors and Solutions:

Missing str input

  • Explanation: The main text input is missing, resulting in an incomplete output.
  • Solution: Ensure that you provide a valid string for the str parameter to form the base of your output.

Invalid num_type selection

  • Explanation: The num_type input is not correctly specified, leading to errors in number conversion.
  • Solution: Verify that the num_type is set to either float or int and that the corresponding number input is valid.

Number conversion error

  • Explanation: The number provided does not match the expected type (e.g., a non-integer value for int type).
  • Solution: Check the number input to ensure it matches the selected num_type and adjust as necessary.

Set Text With Number Related Nodes

Go back to the extension to check out more related nodes.
Sage Utils
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.