



"""simple docstring"""






from collections import OrderedDict
from typing import Mapping

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging


lowerCAmelCase__        =				logging.get_logger(__name__)

lowerCAmelCase__        =				{
    '''roberta-base''': '''https://huggingface.co/roberta-base/resolve/main/config.json''',
    '''roberta-large''': '''https://huggingface.co/roberta-large/resolve/main/config.json''',
    '''roberta-large-mnli''': '''https://huggingface.co/roberta-large-mnli/resolve/main/config.json''',
    '''distilroberta-base''': '''https://huggingface.co/distilroberta-base/resolve/main/config.json''',
    '''roberta-base-openai-detector''': '''https://huggingface.co/roberta-base-openai-detector/resolve/main/config.json''',
    '''roberta-large-openai-detector''': '''https://huggingface.co/roberta-large-openai-detector/resolve/main/config.json''',
}






class        __snake_case       (	_lowercase):
  snake_case__				:   List[Any]  			=						"roberta"




  def __init__( self     :						Union[str, Any]						,					__lowerCAmelCase     :						Optional[int]=5_0_2_6_5						,					__lowerCAmelCase     :						List[str]=7_6_8						,					__lowerCAmelCase     :						Any=1_2						,					__lowerCAmelCase     :						Optional[Any]=1_2						,					__lowerCAmelCase     :						Union[str, Any]=3_0_7_2						,					__lowerCAmelCase     :						int="gelu"						,					__lowerCAmelCase     :						Optional[int]=0.1						,					__lowerCAmelCase     :						List[str]=0.1						,					__lowerCAmelCase     :						Dict=5_1_2						,					__lowerCAmelCase     :						str=2						,					__lowerCAmelCase     :						Optional[int]=0.02						,					__lowerCAmelCase     :						List[Any]=1E-12						,					__lowerCAmelCase     :						str=1						,					__lowerCAmelCase     :						List[Any]=0						,					__lowerCAmelCase     :						str=2						,					__lowerCAmelCase     :						Tuple="absolute"						,					__lowerCAmelCase     :						Optional[int]=True						,					__lowerCAmelCase     :						Any=None						,					**__lowerCAmelCase     :						List[Any]						,					):






         """simple docstring"""






         super().__init__(pad_token_id=__lowerCAmelCase						,					bos_token_id=__lowerCAmelCase						,					eos_token_id=__lowerCAmelCase						,					**__lowerCAmelCase		)

         _lowerCamelCase						:				Dict    			= vocab_size
         _lowerCamelCase						:				List[str]    			= hidden_size
         _lowerCamelCase						:				Any    			= num_hidden_layers
         _lowerCamelCase						:				List[str]    			= num_attention_heads
         _lowerCamelCase						:				Dict    			= hidden_act
         _lowerCamelCase						:				str    			= intermediate_size
         _lowerCamelCase						:				Optional[Any]    			= hidden_dropout_prob
         _lowerCamelCase						:				Dict    			= attention_probs_dropout_prob
         _lowerCamelCase						:				Tuple    			= max_position_embeddings
         _lowerCamelCase						:				Any    			= type_vocab_size
         _lowerCamelCase						:				Optional[Any]    			= initializer_range
         _lowerCamelCase						:				Optional[Any]    			= layer_norm_eps
         _lowerCamelCase						:				int    			= position_embedding_type
         _lowerCamelCase						:				List[Any]    			= use_cache
         _lowerCamelCase						:				Any    			= classifier_dropout






class        __snake_case       (	_lowercase):




  @property
  def 						SCREAMING_SNAKE_CASE				( self     :						Tuple		):






         """simple docstring"""






         if self.task == "multiple-choice":
                _lowerCamelCase						:				List[str]    			= {0: '''batch''', 1: '''choice''', 2: '''sequence'''}
         else:
                _lowerCamelCase						:				Optional[Any]    			= {0: '''batch''', 1: '''sequence'''}
         return OrderedDict(
             [
                 ('''input_ids''', dynamic_axis),
                 ('''attention_mask''', dynamic_axis),
             ]		)




"""simple docstring"""





from collections import OrderedDict
from typing import Mapping

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig


_a		       =							{
    'albert-base-v1': 'https://huggingface.co/albert-base-v1/resolve/main/config.json',
    'albert-large-v1': 'https://huggingface.co/albert-large-v1/resolve/main/config.json',
    'albert-xlarge-v1': 'https://huggingface.co/albert-xlarge-v1/resolve/main/config.json',
    'albert-xxlarge-v1': 'https://huggingface.co/albert-xxlarge-v1/resolve/main/config.json',
    'albert-base-v2': 'https://huggingface.co/albert-base-v2/resolve/main/config.json',
    'albert-large-v2': 'https://huggingface.co/albert-large-v2/resolve/main/config.json',
    'albert-xlarge-v2': 'https://huggingface.co/albert-xlarge-v2/resolve/main/config.json',
    'albert-xxlarge-v2': 'https://huggingface.co/albert-xxlarge-v2/resolve/main/config.json',
}


class A_	(lowercase__      ):




  '''simple docstring'''
  SCREAMING_SNAKE_CASE__			:						Optional[Any]       =		"""albert"""







  def __init__(		self				,   lowercase_=3_0000				,   lowercase_=128				,   lowercase_=4096				,   lowercase_=12				,   lowercase_=1				,   lowercase_=64				,   lowercase_=1_6384				,   lowercase_=1				,   lowercase_="gelu_new"				,   lowercase_=0				,   lowercase_=0				,   lowercase_=512				,   lowercase_=2				,   lowercase_=0.02				,   lowercase_=1E-1_2				,   lowercase_=0.1				,   lowercase_="absolute"				,   lowercase_=0				,   lowercase_=2				,   lowercase_=3				,   **lowercase_				,   ):

     """simple docstring"""
     super().__init__(pad_token_id=lowercase_				,   bos_token_id=lowercase_				,   eos_token_id=lowercase_				,   **lowercase_  )

     UpperCAmelCase_					:					int			     =    vocab_size
     UpperCAmelCase_					:					Optional[int]			     =    embedding_size
     UpperCAmelCase_					:					List[str]			     =    hidden_size
     UpperCAmelCase_					:					Optional[int]			     =    num_hidden_layers
     UpperCAmelCase_					:					Union[str, Any]			     =    num_hidden_groups
     UpperCAmelCase_					:					Dict			     =    num_attention_heads
     UpperCAmelCase_					:					Any			     =    inner_group_num
     UpperCAmelCase_					:					Union[str, Any]			     =    hidden_act
     UpperCAmelCase_					:					Union[str, Any]			     =    intermediate_size
     UpperCAmelCase_					:					List[str]			     =    hidden_dropout_prob
     UpperCAmelCase_					:					Union[str, Any]			     =    attention_probs_dropout_prob
     UpperCAmelCase_					:					Optional[Any]			     =    max_position_embeddings
     UpperCAmelCase_					:					Any			     =    type_vocab_size
     UpperCAmelCase_					:					List[str]			     =    initializer_range
     UpperCAmelCase_					:					Optional[int]			     =    layer_norm_eps
     UpperCAmelCase_					:					List[Any]			     =    classifier_dropout_prob
     UpperCAmelCase_					:					Tuple			     =    position_embedding_type




class A_	(lowercase__      ):




  '''simple docstring'''







  @property
  def        UpperCamelCase__					(		self  ):

     """simple docstring"""
     if self.task == "multiple-choice":
        UpperCAmelCase_					:					int			     =    {0: "batch", 1: "choice", 2: "sequence"}
     else:
        UpperCAmelCase_					:					Optional[Any]			     =    {0: "batch", 1: "sequence"}
     return OrderedDict(
         [
             ("input_ids", dynamic_axis),
             ("attention_mask", dynamic_axis),
             ("token_type_ids", dynamic_axis),
         ]  )


