def forward(
      self,
      batch: Dict[str, Array],
      deterministic: bool,
  ) -> Tuple[Array, Dict[str, Array], Dict[str, Array]]:
    """The forward pass of the encoder.

    Models that use an encoder should call this method to encode a passage.

    Args:
      batch: input to the encoder.
      deterministic: whether to apply dropout.

    Returns:
      A tuple of:
        [bsz, seq_len, model_dim] passage encoding.
        Dictionary of auxiliary values.
        Dictionary of logging values.
    """
    raise NotImplementedError
The forward pass of the encoder.

    Models that use an encoder should call this method to encode a passage.

    Args:
      batch: input to the encoder.
      deterministic: whether to apply dropout.

    Returns:
      A tuple of:
        [bsz, seq_len, model_dim] passage encoding.
        Dictionary of auxiliary values.
        Dictionary of logging values.
    
language/mentionmemory/encoders/base_encoder.py