This node allows you to find and replace words in a given text.

Node Inputs

  1. Text to manipulate: The text you want to perform find and replace on
    • Type: Text
  2. Find Word: The text to find
    • Type: Text
  3. Replace With: The text to replace the found text with
    • Type: Text

Node Outputs

  1. Processed Text: The final text with found words replaced
    • Type: Text
    • Example usage: {{find_and_replace_0.processed_text}}

Example

The below example is a pipeline that takes in a text and finds and replaces the word “John Smith” with “Tom Wilson”.

  1. Text Node: Contains the text “my name is John Smith” (the text that we will do find and replace on)
  2. Find and Replace Node: Finds and replaces the word “John Smith” with “Tom Wilson”
    • Text to manipulate: {{text_0.text}}
    • Find Word: John Smith
    • Replace With: Tom Wilson
  3. Output: display the new text
    • Output: {{find_and_replace_0.processed_text}}