parameters: (self, word)
docstring: Add word to VocabEntry, if it is previously unseen.
          @param word (str): word to add to VocabEntry
          @return index (int): index that the word has been assigned
docstring_summary: Add word to VocabEntry, if it is previously unseen.
docstring_tokens: Add word to VocabEntry if it is previously unseen .
function: def add(self, word):
          """ Add word to VocabEntry, if it is previously unseen.
          @param word (str): word to add to VocabEntry
          @return index (int): index that the word has been assigned
          """
          if word not in self:
              wid = self.word2id[word] = len(self)
              self.id2word[wid] = word
              return wid
          else:
              return self[word]
function_tokens: def add ( self , word ) : if word not in self : wid = self . word2id [ word ] = len ( self ) self . id2word [ wid ] = word return wid else : return self [ word ]