class_docstr: 基于AC自动机实现用户干预的功能
docstr: 装载人工干预词典
docstr_tok: ["\u88c5\u8f7d\u4eba\u5de5\u5e72\u9884\u8bcd\u5178"]
code: def load_customization(self, filename, sep=None):
      """装载人工干预词典"""
      self.ac = Ahocorasick()
      with open(filename, "r", encoding="utf8") as f:
          for line in f:
              if sep == None:
                  words = line.strip().split()
              else:
                  words = line.strip().split(sep)
  
              if len(words) == 0:
                  continue
  
              phrase = ""
              tags = []
              offset = []
              for word in words:
                  if word.rfind("/") < 1:
                      phrase += word
                      tags.append("")
                  else:
                      phrase += word[: word.rfind("/")]
                      tags.append(word[word.rfind("/") + 1 :])
                  offset.append(len(phrase))
  
              if len(phrase) < 2 and tags[0] == "":
                  continue
  
              self.dictitem[phrase] = (tags, offset)
              self.ac.add_word(phrase)
      self.ac.make()
  
imports: from io import open
  from .ahocorasick import Ahocorasick
label_desc: Use image node_id 2 for calling the Customization obj's underlying member method code with example usage: obj.load_customization(filename, sep) without return types