Regualr expression search library with trigram indexed database