fixed up trigram support