

"""simple docstring"""





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


__UpperCamelCase  :      Any							      =		logging.get_logger(__name__)

__UpperCamelCase  :      Optional[int]							      =		{
    '''abeja/gpt-neox-japanese-2.7b''': '''https://huggingface.co/abeja/gpt-neox-japanese-2.7b/resolve/main/config.json''',
}







class 				SCREAMING_SNAKE_CASE					(		a_       ):






					"""simple docstring"""



					lowercase__				 =       "gpt_neox_japanese"







					def __init__(       self			:				Union[str, Any]   ,lowercase_			:				Tuple=3_2_0_0_0   ,lowercase_			:				Union[str, Any]=2_5_6_0   ,lowercase_			:				Optional[int]=3_2   ,lowercase_			:				Any=3_2   ,lowercase_			:				Any=4   ,lowercase_			:				List[Any]="gelu"   ,lowercase_			:				Optional[int]=1.00   ,lowercase_			:				Union[str, Any]=1_0_0_0_0   ,lowercase_			:				List[Any]=2_0_4_8   ,lowercase_			:				int=0.02   ,lowercase_			:				Optional[Any]=1E-5   ,lowercase_			:				Any=True   ,lowercase_			:				List[str]=3_1_9_9_6   ,lowercase_			:				Optional[int]=3_1_9_9_9   ,lowercase_			:				List[str]=0.1   ,lowercase_			:				int=0.0   ,**lowercase_			:				str   ,):
						super().__init__(bos_token_id=lowercase_   ,eos_token_id=lowercase_   ,**lowercase_		)
						lowerCAmelCase__	:						List[str]  				=	vocab_size
						lowerCAmelCase__	:						str  				=	max_position_embeddings
						lowerCAmelCase__	:						int  				=	hidden_size
						lowerCAmelCase__	:						Optional[int]  				=	num_hidden_layers
						lowerCAmelCase__	:						int  				=	num_attention_heads
						lowerCAmelCase__	:						int  				=	intermediate_multiple_size
						lowerCAmelCase__	:						List[str]  				=	hidden_act
						lowerCAmelCase__	:						Optional[Any]  				=	rotary_pct
						lowerCAmelCase__	:						List[Any]  				=	rotary_emb_base
						lowerCAmelCase__	:						Any  				=	initializer_range
						lowerCAmelCase__	:						Union[str, Any]  				=	layer_norm_eps
						lowerCAmelCase__	:						List[Any]  				=	use_cache
						lowerCAmelCase__	:						Optional[int]  				=	attention_dropout
						lowerCAmelCase__	:						Dict  				=	hidden_dropout







"""simple docstring"""





from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_tf_available, is_torch_available


__UpperCamelCase  :      Optional[Any]							      =		{
    '''configuration_rag''': ['''RagConfig'''],
    '''retrieval_rag''': ['''RagRetriever'''],
    '''tokenization_rag''': ['''RagTokenizer'''],
}

try:
							if not is_torch_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							__UpperCamelCase  :      Tuple							      =		[
							    '''RagModel''',
							    '''RagPreTrainedModel''',
							    '''RagSequenceForGeneration''',
							    '''RagTokenForGeneration''',
							]

try:
							if not is_tf_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							__UpperCamelCase  :      Union[str, Any]							      =		[
							    '''TFRagModel''',
							    '''TFRagPreTrainedModel''',
							    '''TFRagSequenceForGeneration''',
							    '''TFRagTokenForGeneration''',
							]


if TYPE_CHECKING:
							from .configuration_rag import RagConfig
							from .retrieval_rag import RagRetriever
							from .tokenization_rag import RagTokenizer

							try:
														if not is_torch_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_rag import RagModel, RagPreTrainedModel, RagSequenceForGeneration, RagTokenForGeneration

							try:
														if not is_tf_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_tf_rag import (
														    TFRagModel,
														    TFRagPreTrainedModel,
														    TFRagSequenceForGeneration,
														    TFRagTokenForGeneration,
														)

else:
							import sys

							__UpperCamelCase  :      Dict							      =		_LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)




