code: def to_dict(self) -> Dict[str, Any]:
      return {
          "config": {
              "token_pad": self.token_pad,
              "token_unk": self.token_unk,
              "token_bos": self.token_bos,
              "token_eos": self.token_eos,
              "vocab2idx": self.vocab2idx,
              "segment": self.segment,
          },
          "__class_name__": self.__class__.__name__,
          "__module__": self.__class__.__module__,
      }
  
file_path: Kashgari/kashgari/processors/abc_processor.py
imports: from abc import ABC
  from typing import Dict, List, Optional, Any, Tuple
  import numpy
  from kashgari.generators import CorpusGenerator
  from kashgari.types import TextSamplesVar
label_desc: Use image node_id 1 for calling the ABCProcessor obj's underlying member method code with example usage: obj.to_dict() and returns: dict