





from ...configuration_utils import PretrainedConfig
from ...utils import logging


_SCREAMING_SNAKE_CASE      	=		logging.get_logger(__name__)

_SCREAMING_SNAKE_CASE      	=		{
    """s-JoL/Open-Llama-V1""": """https://huggingface.co/s-JoL/Open-Llama-V1/blob/main/config.json""",
}
class SCREAMING_SNAKE_CASE_						(					snake_case_					):
						__magic_name__:			int       =       "open-llama"






						def __init__(      self      :      Union[str, Any]		,   _A      :      Any=100000		,   _A      :      Tuple=4096		,   _A      :      Dict=11008		,   _A      :      str=32		,   _A      :      Union[str, Any]=32		,   _A      :      Dict="silu"		,   _A      :      List[str]=2048		,   _A      :      Optional[int]=0.0_2		,   _A      :      Dict=1E-6		,   _A      :      Optional[Any]=True		,   _A      :      Optional[int]=0		,   _A      :      List[Any]=1		,   _A      :      Optional[int]=2		,   _A      :      Tuple=False		,   _A      :      Optional[int]=True		,   _A      :      str=0.1		,   _A      :      Optional[Any]=0.1		,   _A      :      Dict=True		,   _A      :      Any=True		,   _A      :      Tuple=None		,   **_A      :      int		,   )							->    List[Any]:







							"""simple docstring"""


							snake_case_		:			Any											=	vocab_size
							snake_case_		:			Optional[int]											=	max_position_embeddings
							snake_case_		:			int											=	hidden_size
							snake_case_		:			Optional[int]											=	intermediate_size
							snake_case_		:			int											=	num_hidden_layers
							snake_case_		:			Optional[int]											=	num_attention_heads
							snake_case_		:			List[Any]											=	hidden_act
							snake_case_		:			List[Any]											=	initializer_range
							snake_case_		:			Union[str, Any]											=	rms_norm_eps
							snake_case_		:			Optional[Any]											=	use_cache
							snake_case_		:			Tuple											=	kwargs.pop(
							    'use_memorry_efficient_attention'		,   _A	)
							snake_case_		:			Tuple											=	hidden_dropout_prob
							snake_case_		:			List[Any]											=	attention_dropout_prob
							snake_case_		:			int											=	use_stable_embedding
							snake_case_		:			int											=	shared_input_output_embedding
							snake_case_		:			int											=	rope_scaling
							self._rope_scaling_validation()

							super().__init__(
							    pad_token_id=_A		,   bos_token_id=_A		,   eos_token_id=_A		,   tie_word_embeddings=_A		,   **_A		,   )






						def UpperCAmelCase_				(      self      :      int	)							->    int:







							"""simple docstring"""


							if self.rope_scaling is None:
								return

							if not isinstance(self.rope_scaling		,   _A	) or len(self.rope_scaling	) != 2:
								raise ValueError(
								    '`rope_scaling` must be a dictionary with with two fields, `name` and `factor`, '
								    F"""got {self.rope_scaling}"""	)
							snake_case_		:			List[Any]											=	self.rope_scaling.get('type'		,   _A	)
							snake_case_		:			int											=	self.rope_scaling.get('factor'		,   _A	)
							if rope_scaling_type is None or rope_scaling_type not in ["linear", "dynamic"]:
								raise ValueError(
								    F"""`rope_scaling`'s name field must be one of ['linear', 'dynamic'], got {rope_scaling_type}"""	)
							if rope_scaling_factor is None or not isinstance(_A		,   _A	) or rope_scaling_factor <= 1.0:
								raise ValueError(F"""`rope_scaling`'s factor field must be an float > 1, got {rope_scaling_factor}"""	)








from ...configuration_utils import PretrainedConfig
from ...utils import logging


_SCREAMING_SNAKE_CASE      	=		logging.get_logger(__name__)

_SCREAMING_SNAKE_CASE      	=		{
    """SCUT-DLVCLab/lilt-roberta-en-base""": (
        """https://huggingface.co/SCUT-DLVCLab/lilt-roberta-en-base/resolve/main/config.json"""
    ),
}
class SCREAMING_SNAKE_CASE_						(					snake_case_					):
						__magic_name__:			str       =       "lilt"






						def __init__(      self      :      Any		,   _A      :      Dict=30522		,   _A      :      List[Any]=768		,   _A      :      str=12		,   _A      :      int=12		,   _A      :      Optional[int]=3072		,   _A      :      Optional[Any]="gelu"		,   _A      :      Dict=0.1		,   _A      :      Tuple=0.1		,   _A      :      str=512		,   _A      :      Union[str, Any]=2		,   _A      :      Union[str, Any]=0.0_2		,   _A      :      Optional[Any]=1E-12		,   _A      :      Optional[int]=0		,   _A      :      Dict="absolute"		,   _A      :      Any=None		,   _A      :      Optional[Any]=4		,   _A      :      Any=1024		,   **_A      :      Union[str, Any]		,   )							->    List[str]:







							"""simple docstring"""


							super().__init__(pad_token_id=_A		,   **_A	)

							snake_case_		:			List[str]											=	vocab_size
							snake_case_		:			Dict											=	hidden_size
							snake_case_		:			Union[str, Any]											=	num_hidden_layers
							snake_case_		:			List[str]											=	num_attention_heads
							snake_case_		:			Tuple											=	hidden_act
							snake_case_		:			Tuple											=	intermediate_size
							snake_case_		:			int											=	hidden_dropout_prob
							snake_case_		:			Tuple											=	attention_probs_dropout_prob
							snake_case_		:			Dict											=	max_position_embeddings
							snake_case_		:			Any											=	type_vocab_size
							snake_case_		:			Union[str, Any]											=	initializer_range
							snake_case_		:			Optional[int]											=	layer_norm_eps
							snake_case_		:			List[str]											=	position_embedding_type
							snake_case_		:			Optional[int]											=	classifier_dropout
							snake_case_		:			Dict											=	channel_shrink_ratio
							snake_case_		:			Tuple											=	max_ad_position_embeddings

