ngram integration