
from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_tf_available,
    is_tokenizers_available,
    is_torch_available,
)


_lowercase     							=						{
    """configuration_funnel""": ["""FUNNEL_PRETRAINED_CONFIG_ARCHIVE_MAP""", """FunnelConfig"""],
    """convert_funnel_original_tf_checkpoint_to_pytorch""": [],
    """tokenization_funnel""": ["""FunnelTokenizer"""],
}

try:
				if not is_tokenizers_available():
								raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
				pass
else:
				_lowercase     							=						["""FunnelTokenizerFast"""]

try:
				if not is_torch_available():
								raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
				pass
else:
				_lowercase     							=						[
				    """FUNNEL_PRETRAINED_MODEL_ARCHIVE_LIST""",
				    """FunnelBaseModel""",
				    """FunnelForMaskedLM""",
				    """FunnelForMultipleChoice""",
				    """FunnelForPreTraining""",
				    """FunnelForQuestionAnswering""",
				    """FunnelForSequenceClassification""",
				    """FunnelForTokenClassification""",
				    """FunnelModel""",
				    """FunnelPreTrainedModel""",
				    """load_tf_weights_in_funnel""",
				]

try:
				if not is_tf_available():
								raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
				pass
else:
				_lowercase     							=						[
				    """TF_FUNNEL_PRETRAINED_MODEL_ARCHIVE_LIST""",
				    """TFFunnelBaseModel""",
				    """TFFunnelForMaskedLM""",
				    """TFFunnelForMultipleChoice""",
				    """TFFunnelForPreTraining""",
				    """TFFunnelForQuestionAnswering""",
				    """TFFunnelForSequenceClassification""",
				    """TFFunnelForTokenClassification""",
				    """TFFunnelModel""",
				    """TFFunnelPreTrainedModel""",
				]


if TYPE_CHECKING:
				from .configuration_funnel import FUNNEL_PRETRAINED_CONFIG_ARCHIVE_MAP, FunnelConfig
				from .tokenization_funnel import FunnelTokenizer

				try:
								if not is_tokenizers_available():
												raise OptionalDependencyNotAvailable()
				except OptionalDependencyNotAvailable:
								pass
				else:
								from .tokenization_funnel_fast import FunnelTokenizerFast

				try:
								if not is_torch_available():
												raise OptionalDependencyNotAvailable()
				except OptionalDependencyNotAvailable:
								pass
				else:
								from .modeling_funnel import (
								    FUNNEL_PRETRAINED_MODEL_ARCHIVE_LIST,
								    FunnelBaseModel,
								    FunnelForMaskedLM,
								    FunnelForMultipleChoice,
								    FunnelForPreTraining,
								    FunnelForQuestionAnswering,
								    FunnelForSequenceClassification,
								    FunnelForTokenClassification,
								    FunnelModel,
								    FunnelPreTrainedModel,
								    load_tf_weights_in_funnel,
								)

				try:
								if not is_tf_available():
												raise OptionalDependencyNotAvailable()
				except OptionalDependencyNotAvailable:
								pass
				else:
								from .modeling_tf_funnel import (
								    TF_FUNNEL_PRETRAINED_MODEL_ARCHIVE_LIST,
								    TFFunnelBaseModel,
								    TFFunnelForMaskedLM,
								    TFFunnelForMultipleChoice,
								    TFFunnelForPreTraining,
								    TFFunnelForQuestionAnswering,
								    TFFunnelForSequenceClassification,
								    TFFunnelForTokenClassification,
								    TFFunnelModel,
								    TFFunnelPreTrainedModel,
								)

else:
				import sys

				_lowercase     							=						_LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)








from ... import PretrainedConfig


_lowercase     							=						{
    '''sijunhe/nezha-cn-base''': '''https://huggingface.co/sijunhe/nezha-cn-base/resolve/main/config.json''',
}
class 				__A					( A_      ):
			UpperCamelCase					:Optional[Any]     =			NEZHA_PRETRAINED_CONFIG_ARCHIVE_MAP
			UpperCamelCase					:int     =			'''nezha'''





			def __init__(self							,    __magic_name__=21128							,    __magic_name__=768							,    __magic_name__=12							,    __magic_name__=12							,    __magic_name__=3072							,    __magic_name__="gelu"							,    __magic_name__=0.1							,    __magic_name__=0.1							,    __magic_name__=512							,    __magic_name__=64							,    __magic_name__=2							,    __magic_name__=0.02							,    __magic_name__=1E-12							,    __magic_name__=0.1							,    __magic_name__=0							,    __magic_name__=2							,    __magic_name__=3							,    __magic_name__=True							,    **__magic_name__							,    ):
						super().__init__(pad_token_id=__magic_name__							,    bos_token_id=__magic_name__							,    eos_token_id=__magic_name__							,    **__magic_name__				)

						lowerCamelCase__ :      List[str]								=		vocab_size
						lowerCamelCase__ :      int								=		hidden_size
						lowerCamelCase__ :      int								=		num_hidden_layers
						lowerCamelCase__ :      Optional[int]								=		num_attention_heads
						lowerCamelCase__ :      Dict								=		hidden_act
						lowerCamelCase__ :      str								=		intermediate_size
						lowerCamelCase__ :      Optional[Any]								=		hidden_dropout_prob
						lowerCamelCase__ :      Dict								=		attention_probs_dropout_prob
						lowerCamelCase__ :      str								=		max_position_embeddings
						lowerCamelCase__ :      Optional[Any]								=		max_relative_position
						lowerCamelCase__ :      Optional[int]								=		type_vocab_size
						lowerCamelCase__ :      Optional[Any]								=		initializer_range
						lowerCamelCase__ :      Any								=		layer_norm_eps
						lowerCamelCase__ :      Union[str, Any]								=		classifier_dropout
						lowerCamelCase__ :      Union[str, Any]								=		use_cache



