Ë
    ÛÓ^ju  ã                   óv   — d Z ddlm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JetMoe model configurationé    )Ústricté   )ÚPreTrainedConfig)ÚRopeParameters)Úauto_docstringzjetmoe/jetmoe-8b)Ú
checkpointc                   ó’  ‡ — e Zd ZU dZdZdgZddi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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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 z  d z  e	d%<   d&Z!ee	d'<   dZ"ee	d(<   d)Z#eez  e	d*<   ˆ fd+„Z$d,„ Z%ˆ xZ&S )-ÚJetMoeConfigaj  
    kv_channels (`int`, *optional*, defaults to 128):
        Defines the number of channels for the key and value tensors.
    num_local_experts (`int`, *optional*, defaults to 8):
        Defines the number of experts in the MoE and MoA.

    ```python
    >>> from transformers import JetMoeModel, JetMoeConfig

    >>> # Initializing a JetMoe 4B style configuration
    >>> configuration = JetMoeConfig()

    >>> # Initializing a model from the JetMoe 4B style configuration
    >>> model = JetMoeModel(configuration)

    >>> # Accessing the model configuration
    >>> configuration = model.config
    ```
    ÚjetmoeÚpast_key_valuesÚhead_dimÚkv_channelsi }  Ú
vocab_sizei   Úhidden_sizeé   Únum_hidden_layersé   Únum_key_value_headsé€   i   Úintermediate_sizei   Úmax_position_embeddingsÚsiluÚactivation_functioné   Únum_local_expertsé   Únum_experts_per_tokFÚoutput_router_logitsg{®Gáz„?Úaux_loss_coefTÚ	use_cacheé   NÚbos_token_idÚeos_token_idÚpad_token_idÚtie_word_embeddingsÚrope_parametersg�íµ ÷Æ°>Úrms_norm_epsÚinitializer_rangeg        Úattention_dropoutc                 ó`   •— | j                   | j                  z  | _        t        ‰| �  di |¤Ž y )N© )r   r   Únum_attention_headsÚsuperÚ__post_init__)ÚselfÚkwargsÚ	__class__s     €úz/var/www/ramen.bs-engineer-server.com/venv/lib/python3.12/site-packages/transformers/models/jetmoe/configuration_jetmoe.pyr.   zJetMoeConfig.__post_init__H   s,   ø€ Ø#'×#;Ñ#;¸d×>VÑ>VÑ#VˆÔ Ü‰ÑÑ' Ó'ó    c                 óL   — | j                   | j                  kD  rt        d«      ‚y)zOPart of `@strict`-powered validation. Validates the architecture of the config.zG`num_experts_per_tok` must be less than or equal to `num_local_experts`N)r   r   Ú
ValueError)r/   s    r2   Úvalidate_architecturez"JetMoeConfig.validate_architectureL   s'   € à×#Ñ# d×&<Ñ&<Ò<ÜÐfÓgÐgð =r3   )'Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ú
model_typeÚkeys_to_ignore_at_inferenceÚattribute_mapr   ÚintÚ__annotations__r   r   r   r   r   r   r   Ústrr   r   r   Úboolr   Úfloatr    r"   r#   Úlistr$   r%   r&   r   Údictr'   r(   r)   r.   r6   Ú__classcell__)r1   s   @r2   r
   r
      s-  ø… ñð( €JØ#4Ð"5ÐØ Ð/€Mà€J�ÓØ€K�ÓØÐ�sÓØ!Ð˜Ó!Ø€K�ÓØ!Ð�sÓ!Ø#'Ð˜SÓ'Ø%Ð˜Ó%ØÐ�sÓØ Ð˜Ó Ø!&Ð˜$Ó&Ø€M�5ÓØ€IˆtÓØ €L�#˜‘*Ó Ø+,€L�#˜˜S™	‘/ DÑ(Ó,Ø#€L�#˜‘*Ó#Ø $Ð˜Ó$Ø48€O�^ dÑ*¨TÑ1Ó8Ø€L�%ÓØ#Ð�uÓ#Ø%(Ð�u˜s‘{Ó(ô(öhr3   r
   N)r:   Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úmodeling_rope_utilsr   Úutilsr   r
   Ú__all__r+   r3   r2   ú<module>rK      sN   ðñ !å .å 3Ý 1Ý #ñ Ð-Ô.Øô6hÐ#ó 6hó ó /ð6hðr Ð
�r3   