new library for segmenter and test wrapper