Ë
    ÛÓ^jÈ  ã                   ój   — d Z ddlmZ ddlmZ ddlmZ  ed¬«      e G d„ d	e«      «       «       Zd	gZy
)zOpenAI GPT-2 configurationé    )Ústricté   )ÚPreTrainedConfig)Úauto_docstringzopenai-community/gpt2)Ú
checkpointc                   óØ  — e Zd ZU dZdZdgZdddddœZd	Zee	d
<   dZ
ee	d<   dZee	d<   dZee	d<   dZee	d<   dZedz  e	d<   dZee	d<   dZeez  e	d<   dZeez  e	d<   dZeez  e	d<   dZee	d<   dZee	d<   dZee	d<   dZee	d<   dZedz  e	d<   dZee	d<   dZeez  e	d <   dZee	d!<   dZee	d"<   d#Zedz  e	d$<   d#Z ee!e   z  dz  e	d%<   dZ"edz  e	d&<   d'Z#ee	d(<   d'Z$ee	d)<   d'Z%ee	d*<   dZ&ee	d+<   y),Ú
GPT2ConfigaH	  
    summary_type (`string`, *optional*, defaults to `"cls_index"`):
        Argument used when doing sequence summary, used in the models [`GPT2DoubleHeadsModel`].
        Has to be one of the following options:
            - `"last"`: Take the last token hidden state (like XLNet).
            - `"first"`: Take the first token hidden state (like BERT).
            - `"mean"`: Take the mean of all tokens hidden states.
            - `"cls_index"`: Supply a Tensor of classification token position (like GPT/GPT-2).
            - `"attn"`: Not implemented now, use multi-head attention.
    summary_use_proj (`bool`, *optional*, defaults to `True`):
        Argument used when doing sequence summary, used in the models [`GPT2DoubleHeadsModel`].
        Whether or not to add a projection after the vector extraction.
    summary_activation (`str`, *optional*):
        Argument used when doing sequence summary. Used in for the multiple choice head in
        [`GPT2DoubleHeadsModel`].
        Pass `"tanh"` for a tanh activation to the output, any other value will result in no activation.
    summary_proj_to_labels (`bool`, *optional*, defaults to `True`):
        Argument used when doing sequence summary, used in the models [`GPT2DoubleHeadsModel`].
        Whether the projection outputs should have `config.num_labels` or `config.hidden_size` classes.
    summary_first_dropout (`float`, *optional*, defaults to 0.1):
        Argument used when doing sequence summary, used in the models [`GPT2DoubleHeadsModel`].
        The dropout ratio to be used after the projection and activation.
    scale_attn_by_inverse_layer_idx (`bool`, *optional*, defaults to `False`):
        Whether to additionally scale attention weights by `1 / layer_idx + 1`.
    reorder_and_upcast_attn (`bool`, *optional*, defaults to `False`):
        Whether to scale keys (K) prior to computing attention (dot-product) and upcast attention
        dot-product/softmax to float() when training with mixed precision.

    Example:

    ```python
    >>> from transformers import GPT2Config, GPT2Model

    >>> # Initializing a GPT2 configuration
    >>> configuration = GPT2Config()

    >>> # Initializing a model (with random weights) from the configuration
    >>> model = GPT2Model(configuration)

    >>> # Accessing the model configuration
    >>> configuration = model.config
    ```Úgpt2Úpast_key_valuesÚn_embdÚn_positionsÚn_headÚn_layer)Úhidden_sizeÚmax_position_embeddingsÚnum_attention_headsÚnum_hidden_layersiQÄ  Ú
vocab_sizei   i   é   NÚn_innerÚgelu_newÚactivation_functiongš™™™™™¹?Úresid_pdropÚ
embd_pdropÚ
attn_pdropgñhãˆµøä>Úlayer_norm_epsilong{®Gáz”?Úinitializer_rangeÚ	cls_indexÚsummary_typeTÚsummary_use_projÚsummary_activationÚsummary_proj_to_labelsÚsummary_first_dropoutÚscale_attn_weightsÚ	use_cacheiPÄ  Úbos_token_idÚeos_token_idÚpad_token_idFÚscale_attn_by_inverse_layer_idxÚreorder_and_upcast_attnÚadd_cross_attentionÚtie_word_embeddings)'Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ú
model_typeÚkeys_to_ignore_at_inferenceÚattribute_mapr   ÚintÚ__annotations__r   r   r   r   r   r   Ústrr   Úfloatr   r   r   r   r   r    Úboolr!   r"   r#   r$   r%   r&   r'   Úlistr(   r)   r*   r+   r,   © ó    úv/var/www/ramen.bs-engineer-server.com/venv/lib/python3.12/site-packages/transformers/models/gpt2/configuration_gpt2.pyr	   r	      sj  … ñ)ðV €JØ#4Ð"5ÐàØ#0Ø'Ø&ñ	€Mð €J�ÓØ€K�ÓØ€FˆCÓØ€GˆSÓØ€FˆCÓØ€GˆS�4‰ZÓØ)Ð˜Ó)Ø"€K�˜‘Ó"Ø!€J�˜‘Ó!Ø!€J�˜‘Ó!Ø $Ð˜Ó$Ø#Ð�uÓ#Ø#€L�#Ó#Ø!Ð�dÓ!Ø%)Ð˜˜d™
Ó)Ø#'Ð˜DÓ'Ø),Ð˜5 3™;Ó,Ø#Ð˜Ó#Ø€IˆtÓØ$€L�#˜‘*Ó$Ø+0€L�#˜˜S™	‘/ DÑ(Ó0Ø#€L�#˜‘*Ó#Ø,1Ð# TÓ1Ø$)Ð˜TÓ)Ø %Ð˜Ó%Ø $Ð˜Ô$r;   r	   N)	r0   Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úutilsr   r	   Ú__all__r:   r;   r<   ú<module>rA      sJ   ðñ !å .å 3Ý #ñ Ð2Ô3ØôN%Ð!ó N%ó ó 4ðN%ðb ˆ.�r;   