docstr: Add command-line arguments specifically for this agent.
docstr_tok: ["Add","command-line","arguments","specifically","for","this","agent","."]
code: def add_cmdline_args(
      cls, parser: ParlaiParser, partial_opt: Optional[Opt] = None
  ) -> ParlaiParser:
      """
      Add command-line arguments specifically for this agent.
      """
      agent = parser.add_argument_group("HRED Arguments")
      agent.add_argument(
          "-hs",
          "--hiddensize",
          type=int,
          default=128,
          help="size of the hidden layers",
      )
      agent.add_argument(
          "-esz",
          "--embeddingsize",
          type=int,
          default=128,
          help="size of the token embeddings",
      )
      agent.add_argument(
          "-nl",
          "--numlayers",
          type=int,
          default=2,
          help="number of hidden layers",
      )
      agent.add_argument(
          "-dr",
          "--dropout",
          type=float,
          default=0.1,
          help="dropout rate",
      )
      agent.add_argument(
          "-lt",
          "--lookuptable",
          default="unique",
          choices=["unique", "enc_dec", "dec_out", "all"],
          help="The encoder, decoder, and output modules can "
          "share weights, or not. "
          "Unique has independent embeddings for each. "
          "Enc_dec shares the embedding for the encoder "
          "and decoder. "
          "Dec_out shares decoder embedding and output "
          "weights. "
          "All shares all three weights.",
      )
      agent.add_argument(
          "-idr",
          "--input-dropout",
          type=float,
          default=0.0,
          help="Probability of replacing tokens with UNK in training.",
      )
  
      super().add_cmdline_args(parser, partial_opt=partial_opt)
      return agent
  
file_path: ParlAI/parlai/agents/hred/hred.py
imports: from typing import Optional
  from parlai.core.params import ParlaiParser
  from parlai.core.opt import Opt
  import torch
  from parlai.agents.seq2seq.modules import opt_to_kwargs
  from parlai.core.torch_generator_agent import TorchGeneratorAgent
  from .modules import HredModel
label_desc: Use image node_id 1 for calling the HredAgent obj's underlying member method code with example usage: obj.add_cmdline_args(cls, parser, partial_opt) and returns: agent