new predictive text engine using a ternary DAGs (ternary search tree)