docs: def extract(self, text: str) -> List[Extraction]:
          """
          Extract from text
  
          Args:
              text (str): input str to be extracted.
  
          Returns:
              List[Extraction]: the list of extraction or the empty list if there are no matches.
          """
  
          doc = self._tokenizer.tokenize_to_spacy_doc(text)
          self._load_matcher()
  
          matches = [x for x in self._matcher(doc) if x[1] != x[2]]
          pos_filtered_matches = []
          neg_filtered_matches = []
          for idx, start, end in matches:
              span_doc = self._tokenizer.tokenize_to_spacy_doc(doc[start:end].text)
              this_spacy_rule = self._matcher.get(idx)
              relations = self._find_relation(span_doc, this_spacy_rule)
              rule_id, _ = self._hash_map[idx]
              this_rule = self._rule_lst[rule_id]
              if self._filter_match(doc[start:end], relations, this_rule.patterns):
                  value = self._form_output(doc[start:end], this_rule.output_format, relations, this_rule.patterns)
                  if this_rule.polarity:
                      pos_filtered_matches.append((start, end, value, rule_id, relations))
                  else:
                      neg_filtered_matches.append((start, end, value, rule_id, relations))
  
          return_lst = []
          if pos_filtered_matches:
              longest_lst_pos = self._get_longest(pos_filtered_matches)
              if neg_filtered_matches:
                  longest_lst_neg = self._get_longest(neg_filtered_matches)
                  return_lst = self._reject_neg(longest_lst_pos, longest_lst_neg)
              else:
                  return_lst = longest_lst_pos
  
          extractions = []
          for (start, end, value, rule_id, relation) in return_lst:
              this_extraction = Extraction(value=value,
                                           extractor_name=self.name,
                                           start_token=start,
                                           end_token=end,
                                           start_char=doc[start].idx,
                                           end_char=doc[end-1].idx+len(doc[end-1]),
                                           rule_id=rule_id.split("rule_id##")[0],
                                           match_mapping=relation)
              extractions.append(this_extraction)
  
          return extractions