class_docstr: Dictionary for Masked Language Modelling tasks. This extends Dictionary by
  adding the mask symbol.
code: def __init__(
      self,
      pad="<pad>",
      eos="</s>",
      unk="<unk>",
      mask="<mask>",
      max_special_tokens: int = vocab_constants.MAX_SPECIAL_TOKENS,
  ):
      self.symbols: List[str] = []
      self.count: List[int] = []
      self.indices: Dict[str, int] = {}
      self.lexicon_indices: Set[int] = set()
  
      self.pad_word = pad
      self.pad_index = self.add_symbol(pad)
      assert self.pad_index == vocab_constants.PAD_ID
  
      # Adds a junk symbol for vocab_constants' GO_ID
      self.add_symbol("<reserved>")
  
      self.eos_word = eos
      self.eos_index = self.add_symbol(eos)
      assert self.eos_index == vocab_constants.EOS_ID
  
      self.unk_word = unk
      self.unk_index = self.add_symbol(unk)
      assert self.unk_index == vocab_constants.UNK_ID
  
      self.mask_word = mask
      self.mask_index = self.add_symbol(mask)
      assert self.mask_index == vocab_constants.MASK_ID
  
      # Adds junk symbols to pad up to the number of special tokens.
      num_reserved = max_special_tokens - len(self.symbols)
      for i in range(num_reserved):
          self.add_symbol(f"<reserved_{i}>")
  
      self.nspecial = len(self.symbols)
      assert self.nspecial == max_special_tokens
  
imports: from typing import Dict, List, Set
  from pytorch_translate import vocab_constants
  from pytorch_translate.data.dictionary import Dictionary
label_desc: Use image node_id 1 to create a new MaskedLMDictionary object from inherited base classes: Dictionary with example: obj = MaskedLMDictionary(pad, eos, unk, mask, max_special_tokens)