[performance] ngram index: method for computing string offsets by unicode code points turned out to be a major bottleneck. Replacing the code to avoid String.offsetByCodePoints improves indexing performance by at least factor 2.