
Description
The Match Pattern Node enables a user to find patterns in text and expose them in the Input object. You can define patterns to search for in the input text or in the alternate text that was provided. If a pattern is found, amatchedPatterns group is created in the Input object.
Patterns
Patterns can be any text and can contain references to Slots by using the@ symbol.
Example: @color @product
In I need a green shirt, two Slots are found and assigned to color = green and product = shirt.
Tags
You can tag Slots in a pattern to make it easier to identify them later. Example:from @city>origin to @city>destination.
In I want to go from Dรผsseldorf to Tokyo, the city Slot is found in a matched pattern group with origin and destination tags.
Parameters
Example
Text:I want to fly from bErlin to NEW York with 3 or 4 people on October 1st 2021 if its 30 degrees and I am 22 years old 100%
Pattern: from @city>origin to @city>destination with @NUMBER>ppl1 or @NUMBER>ppl2 people @DATE>date if its @TEMPERATURE>celsius degrees and I am @AGE>userage years old @PERCENTAGE>perc
Result: