Efficient out-of-vocabulary term detection by n-gram array indices with distance from a syllable lattice