Given a set of string patterns, find which ones match a particular string
Rather than build 5 NFAs (one for each pattern), I suggest you build a single NFA or DFA that represents the parallel composition of all five patterns.  Then you can run the string through this automaton and check what state it ends at.  That state will tell you which of the 5 patterns it matches.

For best performance, build a NFA for each pattern, take the parallel composition using the product construction, and then convert to a DFA.  This should be quite fast.