Generalized Pattern Matching Micro-Engine