code: def lemmatize(self, text, best_guess=True, return_frequencies=False):
  		
  		if isinstance(text, str):
  			tokens = wordpunct_tokenize(text)
  		elif isinstance(text, list):
  			tokens= text
  		else:
  			raise TypeError("lemmatize only works with strings or lists of string tokens.")
  
  		return [self._lemmatize_token(token, best_guess, return_frequencies) for token in tokens]
docs: Lemmatize all tokens in a string or a list.  A string is first tokenized using punkt.
  		Throw a type error if the input is neither a string nor a list.