class_docstr: Record for converting generated string to information record <type, span>
      
class_docstr_tok: ["Record","for","converting","generated","string","to","information","record","<","type",",","span",">"]
docstr: Find Entity's offset using first matched in the sentence.
  :param instance:
  :return:
docstr_tok: ["Find","Entity","'s","offset","using","first","matched","in","the","sentence",".",":","param","instance",":",":","return",":"]
code: def record_to_offset_first_role(self, instance, token_list):
      """
      Find Entity's offset using first matched in the sentence.
      :param instance:
      :return:
      """
      entity_list = list()
  
      entity_matched_set = set()
      for pred_record in instance:
          record_type, record_text = (
              pred_record["type"],
              pred_record["text"],
          )
          if record_text == "":
              logger.warning(f"Empty Extraction {pred_record}")
              continue
          matched_list = match_sublist(
              token_list, self.span_to_token(record_text)
          )
          for matched in matched_list:
              if (record_type, matched) not in entity_matched_set:
                  entity_list += [
                      (
                          record_type,
                          tuple(range(matched[0], matched[1] + 1)),
                      )
                  ]
                  entity_matched_set.add((record_type, matched))
                  break
  
      return entity_list
  
imports: from asyncio.log import logger
  import sys
  from typing import Tuple
  import numpy
  import logging
label_desc: Use image node_id 4 for calling the EntityRecord obj's underlying member method code with example usage: obj.record_to_offset_first_role(instance, token_list) and returns: entity_list