code: def model_info(model_dir: Optional[str] = None) -> Tuple[str, bool]:
      
      if model_dir is None:
          try:
              model_dir = resource_filename(PACKAGE, DATADIR.format('model'))
          except DistributionNotFound as error:
              LOGGER.warning("Cannot load model from packages: %s", error)
              model_dir = str(DATA_FALLBACK.joinpath('model').absolute())
          is_default_model = True
      else:
          is_default_model = False
  
      model_path = Path(model_dir)
      model_path.mkdir(exist_ok=True)
      LOGGER.debug("Using model: %s, default: %s", model_path, is_default_model)
  
      return (model_dir, is_default_model)
docs: Retrieve Guesslang model directory name,
      and tells if it is the default model.
  
      :param model_dir: model location, if `None` default model is selected
      :return: selected model directory with an indication
          that the model is the default or not