code: 
  '''simple docstring'''
  
  from collections import OrderedDict
  from typing import Mapping
  
  from ...configuration_utils import PretrainedConfig
  from ...onnx import OnnxConfig
  from ...utils import logging
  
  
  _UpperCAmelCase   :      List[Any] 						=  logging.get_logger(__name__)
  
  _UpperCAmelCase   :      List[Any] 						=  {
      """nghuyong/ernie-1.0-base-zh""": """https://huggingface.co/nghuyong/ernie-1.0-base-zh/resolve/main/config.json""",
      """nghuyong/ernie-2.0-base-en""": """https://huggingface.co/nghuyong/ernie-2.0-base-en/resolve/main/config.json""",
      """nghuyong/ernie-2.0-large-en""": """https://huggingface.co/nghuyong/ernie-2.0-large-en/resolve/main/config.json""",
      """nghuyong/ernie-3.0-base-zh""": """https://huggingface.co/nghuyong/ernie-3.0-base-zh/resolve/main/config.json""",
      """nghuyong/ernie-3.0-medium-zh""": """https://huggingface.co/nghuyong/ernie-3.0-medium-zh/resolve/main/config.json""",
      """nghuyong/ernie-3.0-mini-zh""": """https://huggingface.co/nghuyong/ernie-3.0-mini-zh/resolve/main/config.json""",
      """nghuyong/ernie-3.0-micro-zh""": """https://huggingface.co/nghuyong/ernie-3.0-micro-zh/resolve/main/config.json""",
      """nghuyong/ernie-3.0-nano-zh""": """https://huggingface.co/nghuyong/ernie-3.0-nano-zh/resolve/main/config.json""",
      """nghuyong/ernie-gram-zh""": """https://huggingface.co/nghuyong/ernie-gram-zh/resolve/main/config.json""",
      """nghuyong/ernie-health-zh""": """https://huggingface.co/nghuyong/ernie-health-zh/resolve/main/config.json""",
  }
  
  class 			UpperCAmelCase				(					a_ ):
  
  
  
  
  
  		"""simple docstring"""
  
  
  
  
  
  		A__  :   str          =    'ernie'
  		def __init__(    self  ,					_snake_case=30522  ,					_snake_case=768  ,					_snake_case=12  ,					_snake_case=12  ,					_snake_case=3072  ,					_snake_case="gelu"  ,					_snake_case=0.1  ,					_snake_case=0.1  ,					_snake_case=512  ,					_snake_case=2  ,					_snake_case=3  ,					_snake_case=False  ,					_snake_case=0.02  ,					_snake_case=1E-12  ,					_snake_case=0  ,					_snake_case="absolute"  ,					_snake_case=True  ,					_snake_case=None  ,					**_snake_case  ,					)				->    List[Any]:
  				super().__init__(pad_token_id=_snake_case  ,					**_snake_case     )
  
  				_UpperCamelCase       : Dict    =      vocab_size
  				_UpperCamelCase       : int    =      hidden_size
  				_UpperCamelCase       : List[Any]    =      num_hidden_layers
  				_UpperCamelCase       : Tuple    =      num_attention_heads
  				_UpperCamelCase       : List[str]    =      hidden_act
  				_UpperCamelCase       : Optional[int]    =      intermediate_size
  				_UpperCamelCase       : Tuple    =      hidden_dropout_prob
  				_UpperCamelCase       : Optional[int]    =      attention_probs_dropout_prob
  				_UpperCamelCase       : List[str]    =      max_position_embeddings
  				_UpperCamelCase       : Tuple    =      type_vocab_size
  				_UpperCamelCase       : Union[str, Any]    =      task_type_vocab_size
  				_UpperCamelCase       : Union[str, Any]    =      use_task_id
  				_UpperCamelCase       : Any    =      initializer_range
  				_UpperCamelCase       : Optional[int]    =      layer_norm_eps
  				_UpperCamelCase       : str    =      position_embedding_type
  				_UpperCamelCase       : Any    =      use_cache
  				_UpperCamelCase       : str    =      classifier_dropout
  
  
  
  
  
  
  
  class 			UpperCAmelCase				(					a_ ):
  
  
  
  
  
  		"""simple docstring"""
  
  
  
  
  
  		@property
  		def _lowercase  (    self     )				->    Mapping[str, Mapping[int, str]]:
  				if self.task == "multiple-choice":
  						_UpperCamelCase       : str    =      {0: '''batch''', 1: '''choice''', 2: '''sequence'''}
  				else:
  						_UpperCamelCase       : Dict    =      {0: '''batch''', 1: '''sequence'''}
  				return OrderedDict(
  				    [
  				        ('''input_ids''', dynamic_axis),
  				        ('''attention_mask''', dynamic_axis),
  				        ('''token_type_ids''', dynamic_axis),
  				        ('''task_type_ids''', dynamic_axis),
  				    ]     )
  
  
  
  
  
  
style_context: 
  '''simple docstring'''
  
  from typing import TYPE_CHECKING
  
  from ...utils import (
      OptionalDependencyNotAvailable,
      _LazyModule,
      is_flax_available,
      is_tf_available,
      is_torch_available,
  )
  
  
  _UpperCAmelCase   :      int 						=  {
      """configuration_gptsan_japanese""": ["""GPTSAN_JAPANESE_PRETRAINED_CONFIG_ARCHIVE_MAP""", """GPTSanJapaneseConfig"""],
      """tokenization_gptsan_japanese""": ["""GPTSanJapaneseTokenizer"""],
  }
  
  try:
  	if not is_torch_available():
  		raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
  	pass
  else:
  	_UpperCAmelCase   :      int 						=  [
  	    """GPTSAN_JAPANESE_PRETRAINED_MODEL_ARCHIVE_LIST""",
  	    """GPTSanJapaneseForConditionalGeneration""",
  	    """GPTSanJapaneseModel""",
  	    """GPTSanJapanesePreTrainedModel""",
  	]
  	_UpperCAmelCase   :      str 						=  [
  	    """GPTSanJapaneseTokenizer""",
  	]
  
  
  if TYPE_CHECKING:
  	from .configuration_gptsan_japanese import GPTSAN_JAPANESE_PRETRAINED_CONFIG_ARCHIVE_MAP, GPTSanJapaneseConfig
  	from .tokenization_gptsan_japanese import GPTSanJapaneseTokenizer
  
  	try:
  		if not is_torch_available():
  			raise OptionalDependencyNotAvailable()
  	except OptionalDependencyNotAvailable:
  		pass
  	else:
  		from .modeling_gptsan_japanese import (
  		    GPTSAN_JAPANESE_PRETRAINED_MODEL_ARCHIVE_LIST,
  		    GPTSanJapaneseForConditionalGeneration,
  		    GPTSanJapaneseModel,
  		    GPTSanJapanesePreTrainedModel,
  		)
  		from .tokenization_gptsan_japanese import GPTSanJapaneseTokenizer
  
  
  else:
  	import sys
  
  	_UpperCAmelCase   :      List[str] 						=  _LazyModule(__name__, globals()["""__file__"""], _import_structure, module_spec=__spec__)
  
  
  
  
  
  