Text Match Pixaroma
Text Match Pixaroma - checks whether a text contains one of your words, and lets a workflow act on the answer. Wire any text into text (an AI answer, a prompt, a file name) and type the words to look for, one per line or separated by commas. It gives a yes / no (match), the number of the word that matched (index, 1 for the first word, 0 for none) and the word itself. Wire a picture or anything else into value and two gates appear: if_match lets it through only when the text matches, if_no_match only when it does not. Nothing after a closed gate runs, and there is no error. With a vision model asked 'Is the face sharp? Answer yes or no' in front, a whole folder is filtered in one Run: only the matching pictures reach the save node. With nothing wired into value, the gates pass the text itself. Matching is plain text, never a code pattern. Whole words is on by default, so 'cat' does not match 'category'; upper and lower case are the same unless you turn that off.
- value
- match
- index
- word
- if_match
- if_no_match
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| text | STRING | The text to check, for example an AI Prompt answer, a prompt or a file name. | |
| words | STRING | yes | The words or phrases to look for: one per line, or separated by commas. The first one is number 1 for the index output. |
| mode | COMBO | contains any word | contains any word = at least one of them is in the text. contains all words = every one of them is. is exactly one of them = the whole text is one of the words (spaces, full stops and quotes around it are ignored, so 'Yes.' counts as yes). starts with one of them = the text begins with one of the words. |
| ignore_case | BOOLEAN | true | On: Yes, YES and yes are the same. |
| whole_words | BOOLEAN | true | On: a word only counts on its own, so 'cat' does not match 'category'. Off: it may be part of a longer word. |
| valueopt | * | Optional. Anything to let through only on a match (if_match) or only without one (if_no_match): a picture, a prompt, a latent. Not wired: the gates pass the text. |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| match | BOOLEAN | True when the text matches your words, False when it does not. |
| index | INT | The number of the word that matched (1 for the first word in the list), 0 when none did. |
| word | STRING | The word that matched, or nothing. |
| if_match | * | The value (or the text) when it matches. Without a match nothing after it runs. |
| if_no_match | * | The value (or the text) when it does NOT match. With a match nothing after it runs. |