class_docstr: Convert source and target examples to doc level segments.
  
  It concatenates segments with a DefaultTokens.SEP
  until it reaches --doc_length tokens
class_docstr_tok: ["Convert","source","and","target","examples","to","doc","level","segments",".","It","concatenates","segments","with","a","DefaultTokens.SEP","until","it","reaches","--","doc_length","tokens"]
docstr: Add an option for the corpus ratio to apply this transform.
docstr_tok: ["Add","an","option","for","the","corpus","ratio","to","apply","this","transform","."]
code: def add_options(cls, parser):
      """Add an option for the corpus ratio to apply this transform."""
  
      group = parser.add_argument_group("Transform/Docify")
      group.add(
          "--doc_length",
          "-doc_length",
          type=int,
          default=200,
          help="Number of tokens per doc.",
      )
      group.add(
          "--max_context",
          "-max_context",
          type=int,
          default=1,
          help="Max context segments.",
      )
  
file_path: OpenNMT-py/onmt/transforms/docify.py
imports: from onmt.constants import DefaultTokens
  from onmt.transforms import register_transform
  from .transform import Transform
  import copy
label_desc: Use image node_id 2 for calling the DocifyTransform obj's underlying member method code with example usage: obj.add_options(cls, parser) without return types