@Override
  public ObjectInspector initialize(ObjectInspector[] arguments) throws UDFArgumentException {
    if (arguments.length < 1 || arguments.length > 3) {
      throw new UDFArgumentLengthException(
          "The function sentences takes between 1 and 3 arguments.");
    }

    converters = new ObjectInspectorConverters.Converter[arguments.length];
    for (int i = 0; i < arguments.length; i++) {
      converters[i] = ObjectInspectorConverters.getConverter(arguments[i],
          PrimitiveObjectInspectorFactory.writableStringObjectInspector);
    }

    return ObjectInspectorFactory.getStandardListObjectInspector(
             ObjectInspectorFactory.getStandardListObjectInspector(   
              PrimitiveObjectInspectorFactory.writableStringObjectInspector));
  }
GenericUDFSentences: splits a natural language chunk of text into sentences and words.
ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDFSentences.java