I am writing an analysis plugin for elasticsearch, which maps a sentence to a prefix array. e.g. "EVA EGG京" will be mapped to term array [E, EV, EVA, E, EG, EGG, 京].