





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


__A       : Dict						    = logging.get_logger(__name__)

__A       : 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(	__snake_case  ):
					'''simple docstring'''


					__magic_name__        = 'opt'
					__magic_name__        = ['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.02							,    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_							,    )
									_A    =       vocab_size
									_A    =       max_position_embeddings
									_A    =       num_attention_heads
									_A    =       word_embed_proj_dim if word_embed_proj_dim is not None else hidden_size
									_A    =       ffn_dim
									_A    =       hidden_size
									_A    =       num_hidden_layers
									_A    =       dropout
									_A    =       attention_dropout
									_A    =       activation_function
									_A    =       init_std
									_A    =       layerdrop
									_A    =       use_cache
									_A    =       do_layer_norm_before
									# We keep these variables at `True` for backward compatibility.
									_A    =       enable_bias
									_A    =       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
									_A    =       _remove_final_layer_norm












from ..utils import DummyObject, requires_backends


__A       : str						    = None





def 							__lowerCAmelCase(					*_SCREAMING_SNAKE_CASE       ,    **_SCREAMING_SNAKE_CASE							)       ->   Tuple:




    """simple docstring"""




    requires_backends(_SCREAMING_SNAKE_CASE       ,    ['sentencepiece', 'tokenizers']							)





