modify the interface of tokenize