
    bi^                         d dl Z d dlmZmZ d dlmZ d dlmZ d dlm	Z	  G d de
e j                        Ze G d d	e             Zy)
    N)	dataclassfield)Union)PromptLearningConfig)PeftTypec                       e Zd ZdZdZy)#PromptEncoderReparameterizationTypeMLPLSTMN)__name__
__module____qualname__r
   r        V/home/cdr/jupyterlab/.venv/lib/python3.12/site-packages/peft/tuners/p_tuning/config.pyr	   r	      s    
CDr   r	   c                        e Zd ZU dZ eej                  ddi      Zee	ef   e
d<    edddi      Zee
d<    ed	dd
i      Zee
d<    edddi      Zee
d<    fdZ xZS )PromptEncoderConfiga  
    This is the configuration class to store the configuration of a [`PromptEncoder`].

    Args:
        encoder_reparameterization_type (Union[[`PromptEncoderReparameterizationType`], `str`]):
            The type of reparameterization to use.
        encoder_hidden_size (`int`): The hidden size of the prompt encoder.
        encoder_num_layers (`int`): The number of layers of the prompt encoder.
        encoder_dropout (`float`): The dropout probability of the prompt encoder.
    helpz(How to reparameterize the prompt encoder)defaultmetadataencoder_reparameterization_typeNz%The hidden size of the prompt encoderencoder_hidden_size   z*The number of layers of the prompt encoderencoder_num_layersg        z!The dropout of the prompt encoderencoder_dropoutc                 L    t         |           t        j                  | _        y )N)super__post_init__r   P_TUNING	peft_type)self	__class__s    r   r   z!PromptEncoderConfig.__post_init__:   s    !**r   )r   r   r   __doc__r   r	   r
   r   r   str__annotations__r   intr   r   floatr   __classcell__)r"   s   @r   r   r      s    	 X]377DEX#U30S+S%T   %AB   $FG  #=>OU 
+ +r   r   )enumdataclassesr   r   typingr   peft.configr   
peft.utilsr   r$   Enumr	   r   r   r   r   <module>r/      sD     (  , #tyy 
 +. + +r   