refactor token length