### Question:
VectorNGramFeatureModifierBuilder implements MLFeatureModifierBuilder { @Override public MLFeatureModifier build() { return new VectorNGramFeatureModifier(gramLength, getGrams()); } VectorNGramFeatureModifierBuilder(int gramLength);  VectorNGramFeatureModifierBuilder(MLTrainingConstraints constraints, int gramLength); @Override void addRecordValue(Object value); @Override MLFeatureModifier build();  }### Answer:
@Test public void testBuild() { final VectorNGramFeatureModifierBuilder builder = new VectorNGramFeatureModifierBuilder(3); builder.addRecordValue("s-o s-h-o-r-t i-s i-g-n-o-r-e-d"); assertEquals("", toString(builder)); builder.addRecordValue("Hello world"); assertEquals("ell,hel,llo,orl,rld,wor", toString(builder)); builder.addRecordValue("hello"); builder.addRecordValue("WORLD"); assertEquals("ell,hel,llo,orl,rld,wor", toString(builder)); builder.addRecordValue("Hello-world"); assertEquals("ell,hel,llo,orl,rld,wor", toString(builder)); final MLFeatureModifier modifier = builder.build(); final double[] result = modifier.generateFeatureValues("world"); assertZeroOneFeatureCounts(3, 3, result); }