Generates an Aho-Corasick automata for matching multiple patterns in a stream