code: def count_words(self, doc):
      # count number of words in *original doc before detokenization*
      return len(re.split(r"\s+", doc))
  
file_path: lm-evaluation-harness/lm_eval/tasks/wikitext.py
imports: import re
  from lm_eval.base import PerplexityTask
label_desc: Use image node_id 10 for calling the WikiText obj's underlying member method code with example usage: obj.count_words(doc) and returns: len