docstr: Fills the array containing information about the entity mention annotations.
  
  Args:
      annot_array: array to be filled
      key: reddit id, on which the post title/comment thread is matched with its corresponding annotation
      post_flag: flag indicating whether the annotations are collected for the post titles or comment threads
docstr_tok: ["Fills","the","array","containing","information","about","the","entity","mention","annotations",".","Args",":","annot_array",":","array","to","be","filled","key",":","reddit","id",",","on","which","the","post","title\/comment","thread","is","matched","with","its","corresponding","annotation","post_flag",":","flag","indicating","whether","the","annotations","are","collected","for","the","post","titles","or","comment","threads"]
code: def _fill_annot_array(
      self, annot_array: list, key: str, post_flag: bool
  ) -> list:
      """Fills the array containing information about the entity mention annotations.
  
      Args:
          annot_array: array to be filled
          key: reddit id, on which the post title/comment thread is matched with its corresponding annotation
          post_flag: flag indicating whether the annotations are collected for the post titles or comment threads
      """
      while True:
          # Check if further annotations belong to the current post title or comment thread as well
          try:
              next_annot = (
                  next(self.post_annotations)
                  if post_flag
                  else next(self.comment_annotations)
              )
              if next_annot[0] == key:
                  annot_array.append(
                      (
                          int(next_annot[4]),
                          int(next_annot[5]),
                          next_annot[3],
                      )
                  )
              else:
                  self.curr_annot = next_annot
                  break
          # Stop when the end of an annotation file is reached
          except StopIteration:
              break
      return annot_array
  
imports: import csv
  import logging
  import os
  from pathlib import Path
  from typing import Dict, List, Optional, Union
  import requests
  import flair
  from flair.data import Corpus, MultiCorpus, Sentence
  from flair.datasets.sequence_labeling import ColumnCorpus, MultiFileColumnCorpus
  from flair.file_utils import cached_path, unpack_file
  from flair.splitter import SegtokSentenceSplitter, SentenceSplitter
label_desc: Use image node_id 3 for calling the NEL_ENGLISH_REDDIT obj's underlying member method code with example usage: obj._fill_annot_array(annot_array, key, post_flag) and returns: annot_array