
'''simple docstring'''







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


_lowercase					:    List[str]       				=			logging.get_logger(__name__)

_lowercase					:    int       				=			{
    'facebook/opt-125m': 'https://huggingface.co/facebook/opt-125m/blob/main/config.json',
    'facebook/opt-350m': 'https://huggingface.co/facebook/opt-350m/blob/main/config.json',
    'facebook/opt-1.3b': 'https://huggingface.co/facebook/opt-1.3b/blob/main/config.json',
    'facebook/opt-2.7b': 'https://huggingface.co/facebook/opt-2.7b/blob/main/config.json',
    'facebook/opt-6.7b': 'https://huggingface.co/facebook/opt-6.7b/blob/main/config.json',
    'facebook/opt-13b': 'https://huggingface.co/facebook/opt-13b/blob/main/config.json',
}






class 					lowerCAmelCase__  (    lowerCamelCase_	):
					lowerCAmelCase_	  =	"""opt"""
					lowerCAmelCase_	  =	["""past_key_values"""]






					def __init__(  self							,				__SCREAMING_SNAKE_CASE=5_02_72							,				__SCREAMING_SNAKE_CASE=7_68							,				__SCREAMING_SNAKE_CASE=12							,				__SCREAMING_SNAKE_CASE=30_72							,				__SCREAMING_SNAKE_CASE=20_48							,				__SCREAMING_SNAKE_CASE=True							,				__SCREAMING_SNAKE_CASE=False							,				__SCREAMING_SNAKE_CASE=None							,				__SCREAMING_SNAKE_CASE=0.1							,				__SCREAMING_SNAKE_CASE=0.0							,				__SCREAMING_SNAKE_CASE=12							,				__SCREAMING_SNAKE_CASE="relu"							,				__SCREAMING_SNAKE_CASE=0.0							,				__SCREAMING_SNAKE_CASE=0.02							,				__SCREAMING_SNAKE_CASE=True							,				__SCREAMING_SNAKE_CASE=1							,				__SCREAMING_SNAKE_CASE=2							,				__SCREAMING_SNAKE_CASE=2							,				__SCREAMING_SNAKE_CASE=True							,				__SCREAMING_SNAKE_CASE=True							,				**__SCREAMING_SNAKE_CASE							,				):


											"""simple docstring"""





											super().__init__(
											    pad_token_id=snake_case__							,				bos_token_id=snake_case__							,				eos_token_id=snake_case__							,				**snake_case__							,				)
											lowercase_      :	Union[str, Any]						=			vocab_size
											lowercase_      :	List[Any]						=			max_position_embeddings
											lowercase_      :	List[str]						=			num_attention_heads
											lowercase_      :	Dict						=			word_embed_proj_dim if word_embed_proj_dim is not None else hidden_size
											lowercase_      :	Optional[Any]						=			ffn_dim
											lowercase_      :	Optional[int]						=			hidden_size
											lowercase_      :	List[str]						=			num_hidden_layers
											lowercase_      :	Union[str, Any]						=			dropout
											lowercase_      :	List[str]						=			attention_dropout
											lowercase_      :	Union[str, Any]						=			activation_function
											lowercase_      :	Optional[Any]						=			init_std
											lowercase_      :	List[str]						=			layerdrop
											lowercase_      :	Dict						=			use_cache
											lowercase_      :	List[Any]						=			do_layer_norm_before
											# We keep these variables at `True` for backward compatibility.
											lowercase_      :	List[str]						=			enable_bias
											lowercase_      :	Dict						=			layer_norm_elementwise_affine

											# Note that the only purpose of `_remove_final_layer_norm` is to keep backward compatibility
											# with checkpoints that have been fine-tuned before transformers v4.20.1
											# see https://github.com/facebookresearch/metaseq/pull/164
											lowercase_      :	Tuple						=			_remove_final_layer_norm







'''simple docstring'''




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


_lowerCAmelCase	:		List[str]		  =						logging.get_logger(__name__)

_lowerCAmelCase	:		int		  =						{
    'facebook/opt-125m': 'https://huggingface.co/facebook/opt-125m/blob/main/config.json',
    'facebook/opt-350m': 'https://huggingface.co/facebook/opt-350m/blob/main/config.json',
    'facebook/opt-1.3b': 'https://huggingface.co/facebook/opt-1.3b/blob/main/config.json',
    'facebook/opt-2.7b': 'https://huggingface.co/facebook/opt-2.7b/blob/main/config.json',
    'facebook/opt-6.7b': 'https://huggingface.co/facebook/opt-6.7b/blob/main/config.json',
    'facebook/opt-13b': 'https://huggingface.co/facebook/opt-13b/blob/main/config.json',
}



class 			lowerCAmelCase					(					a				):
	_lowerCamelCase :       Dict         =			"""opt"""
	_lowerCamelCase :       Optional[Any]         =			["""past_key_values"""]



	def __init__(       self			,       snake_case__=5_0272			,       snake_case__=768			,       snake_case__=12			,       snake_case__=3072			,       snake_case__=2048			,       snake_case__=True			,       snake_case__=False			,       snake_case__=None			,       snake_case__=0.1			,       snake_case__=0.0			,       snake_case__=12			,       snake_case__="relu"			,       snake_case__=0.0			,       snake_case__=0.0_2			,       snake_case__=True			,       snake_case__=1			,       snake_case__=2			,       snake_case__=2			,       snake_case__=True			,       snake_case__=True			,       **snake_case__			,       ):
		super().__init__(
		    pad_token_id=snake_case__			,       bos_token_id=snake_case__			,       eos_token_id=snake_case__			,       **snake_case__			,       )
		lowerCAmelCase       :     Union[str, Any]   				=			vocab_size
		lowerCAmelCase       :     List[Any]   				=			max_position_embeddings
		lowerCAmelCase       :     List[str]   				=			num_attention_heads
		lowerCAmelCase       :     Dict   				=			word_embed_proj_dim if word_embed_proj_dim is not None else hidden_size
		lowerCAmelCase       :     Optional[Any]   				=			ffn_dim
		lowerCAmelCase       :     Optional[int]   				=			hidden_size
		lowerCAmelCase       :     List[str]   				=			num_hidden_layers
		lowerCAmelCase       :     Union[str, Any]   				=			dropout
		lowerCAmelCase       :     List[str]   				=			attention_dropout
		lowerCAmelCase       :     Union[str, Any]   				=			activation_function
		lowerCAmelCase       :     Optional[Any]   				=			init_std
		lowerCAmelCase       :     List[str]   				=			layerdrop
		lowerCAmelCase       :     Dict   				=			use_cache
		lowerCAmelCase       :     List[Any]   				=			do_layer_norm_before
		# We keep these variables at `True` for backward compatibility.
		lowerCAmelCase       :     List[str]   				=			enable_bias
		lowerCAmelCase       :     Dict   				=			layer_norm_elementwise_affine

		# Note that the only purpose of `_remove_final_layer_norm` is to keep backward compatibility
		# with checkpoints that have been fine-tuned before transformers v4.20.1
		# see https://github.com/facebookresearch/metaseq/pull/164
		lowerCAmelCase       :     Tuple   				=			_remove_final_layer_norm
