\improved token fuction.