code: def replace(self, word: str) -> Tuple[str, bool]:
      new_word = self.mapping.get(word, None) or self.mapping.get(
          word.lower(), None
      )
      if new_word is not None and word[0].isupper():
          new_word = new_word.capitalize()
      return (new_word, True) if new_word else (word, False)
  
file_path: AugLy/augly/text/augmenters/word_replacement.py
imports: import json
  from typing import Any, Dict, List, Optional, Tuple, Union
  from augly.text.augmenters.utils import detokenize, get_aug_idxes, tokenize
  from augly.utils import pathmgr
  from augly.utils.libsndfile import install_libsndfile
  from nlpaug.augmenter.word import WordAugmenter
  from nlpaug.util import Action, Method
label_desc: Use image node_id 2 for calling the WordReplacement obj's underlying member method code with example usage: obj.replace(word) and returns: unknown