



'''simple docstring'''






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


UpperCamelCase__:     str										=    logging.get_logger(__name__)

UpperCamelCase__:     str										=    {
    "google/pegasus-large": "https://huggingface.co/google/pegasus-large/resolve/main/config.json",
    # See all PEGASUS models at https://huggingface.co/models?filter=pegasus
}

class        SCREAMING_SNAKE_CASE(							A__    ):







	"""simple docstring"""






	lowerCamelCase__    				= """pegasus"""
	lowerCamelCase__    				= ["""past_key_values"""]
	lowerCamelCase__    				= {"""num_attention_heads""": """encoder_attention_heads""", """hidden_size""": """d_model"""}







	def __init__(		self    :  Optional[int]	,    __snake_case    :  Union[str, Any]=50265	,    __snake_case    :  List[str]=1024	,    __snake_case    :  Optional[int]=12	,    __snake_case    :  Any=4096	,    __snake_case    :  Optional[int]=16	,    __snake_case    :  int=12	,    __snake_case    :  List[Any]=4096	,    __snake_case    :  Tuple=16	,    __snake_case    :  Tuple=0.0	,    __snake_case    :  str=0.0	,    __snake_case    :  Optional[Any]=True	,    __snake_case    :  Optional[Any]=True	,    __snake_case    :  Optional[int]="gelu"	,    __snake_case    :  Optional[Any]=1024	,    __snake_case    :  Union[str, Any]=0.1	,    __snake_case    :  Dict=0.0	,    __snake_case    :  Tuple=0.0	,    __snake_case    :  List[str]=0.02	,    __snake_case    :  Optional[Any]=0	,    __snake_case    :  Optional[Any]=False	,    __snake_case    :  List[str]=0	,    __snake_case    :  List[str]=1	,    __snake_case    :  List[Any]=1	,    **__snake_case    :  int	,    )    ->	Dict:
								UpperCAmelCase				: Optional[Any]											=	vocab_size
								UpperCAmelCase				: Union[str, Any]											=	max_position_embeddings
								UpperCAmelCase				: Optional[Any]											=	d_model
								UpperCAmelCase				: Optional[Any]											=	encoder_ffn_dim
								UpperCAmelCase				: Union[str, Any]											=	encoder_layers
								UpperCAmelCase				: Tuple											=	encoder_attention_heads
								UpperCAmelCase				: List[str]											=	decoder_ffn_dim
								UpperCAmelCase				: Tuple											=	decoder_layers
								UpperCAmelCase				: Optional[int]											=	decoder_attention_heads
								UpperCAmelCase				: Any											=	dropout
								UpperCAmelCase				: Optional[int]											=	attention_dropout
								UpperCAmelCase				: List[str]											=	activation_dropout
								UpperCAmelCase				: Tuple											=	activation_function
								UpperCAmelCase				: Optional[int]											=	init_std
								UpperCAmelCase				: int											=	encoder_layerdrop
								UpperCAmelCase				: Dict											=	decoder_layerdrop
								UpperCAmelCase				: Dict											=	use_cache
								UpperCAmelCase				: str											=	encoder_layers
								UpperCAmelCase				: str											=	scale_embedding  # scale factor will be sqrt(d_model) if True
								super().__init__(
								    pad_token_id=__snake_case	,    eos_token_id=__snake_case	,    is_encoder_decoder=__snake_case	,    decoder_start_token_id=__snake_case	,    forced_eos_token_id=__snake_case	,    **__snake_case	,    )







	@property
	def   A			(		self    :  Tuple	)    ->	int:
								return self.encoder_attention_heads







	@property
	def   A			(		self    :  List[Any]	)    ->	int:
								return self.d_model










'''simple docstring'''






from dataclasses import dataclass, field
from typing import ClassVar, Dict

from ..features import Features, Value
from .base import TaskTemplate

@dataclass(frozen=A__    )
class        SCREAMING_SNAKE_CASE(							A__    ):







	"""simple docstring"""






	lowerCamelCase__    				= field(default="""language-modeling"""							,	metadata={"""include_in_asdict_even_if_is_default""": True}    )

	lowerCamelCase__    				= Features({"""text""": Value("""string"""    )}    )
	lowerCamelCase__    				= Features({}    )
	lowerCamelCase__    				= "text"







	@property
	def   A			(		self    :  Optional[Any]	)    ->	Dict[str, str]:
								return {self.text_column: "text"}





