class_docstr: OpenNMT Tokenizer transform class.
docstr: Available options relate to Subword.
docstr_tok: ["Available","options","relate","to","Subword","."]
code: def add_options(cls, parser):
      """Available options relate to Subword."""
      super().add_options(parser)
      group = parser.add_argument_group("Transform/Subword/ONMTTOK")
      group.add(
          "-src_subword_type",
          "--src_subword_type",
          type=str,
          default="none",
          choices=["none", "sentencepiece", "bpe"],
          help="Type of subword model for src (or shared) "
          "in pyonmttok.",
      )
      group.add(
          "-tgt_subword_type",
          "--tgt_subword_type",
          type=str,
          default="none",
          choices=["none", "sentencepiece", "bpe"],
          help="Type of subword model for tgt in  pyonmttok.",
      )
      group.add(
          "-src_onmttok_kwargs",
          "--src_onmttok_kwargs",
          type=str,
          default="{'mode': 'none'}",
          help="Other pyonmttok options for src in dict string, "
          "except subword related options listed earlier.",
      )
      group.add(
          "-tgt_onmttok_kwargs",
          "--tgt_onmttok_kwargs",
          type=str,
          default="{'mode': 'none'}",
          help="Other pyonmttok options for tgt in dict string, "
          "except subword related options listed earlier.",
      )
      group.add(
          "--gpt2_pretok",
          "-gpt2_pretok",
          action="store_true",
          default=False,
          help="Preprocess sentence with byte-level mapping",
      )
  
imports: import re
  from onmt.utils.logging import logger
  from onmt.transforms import register_transform
  from .transform import Transform, ObservableStats
  from onmt.constants import DefaultTokens
label_desc: Use image node_id 3 for calling the ONMTTokenizerTransform obj's underlying member method code with example usage: obj.add_options(cls, parser) without return types