
    hl                     h    d Z ddlmZmZ ddlmZ ddlmZmZm	Z	m
Z
mZ ddlmZ  G d de      ZdgZy	)
z
Processor class for Bros.
    )OptionalUnion   )ProcessorMixin)BatchEncodingPaddingStrategyPreTokenizedInput	TextInputTruncationStrategy)
TensorTypec            "            e Zd ZdZdgZdZd fd	Z	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 ddeee	e
e   e
e	   f   dedeeeef   deeeef   d	ee   d
edee   dee   dee   dedededededeeeef      def dZ xZS )BrosProcessora  
    Constructs a Bros processor which wraps a BERT tokenizer.

    [`BrosProcessor`] offers all the functionalities of [`BertTokenizerFast`]. See the docstring of
    [`~BrosProcessor.__call__`] and [`~BrosProcessor.decode`] for more information.

    Args:
        tokenizer (`BertTokenizerFast`, *optional*):
            An instance of ['BertTokenizerFast`]. The tokenizer is a required input.
    	tokenizer)BertTokenizerBertTokenizerFastc                 >    |t        d      t        | 	  |       y )Nz"You need to specify a `tokenizer`.)
ValueErrorsuper__init__)selfr   kwargs	__class__s      f/var/www/html/eduruby.in/venv/lib/python3.12/site-packages/transformers/models/bros/processing_bros.pyr   zBrosProcessor.__init__)   s"    ABB#    textadd_special_tokenspadding
truncation
max_lengthstridepad_to_multiple_ofreturn_token_type_idsreturn_attention_maskreturn_overflowing_tokensreturn_special_tokens_maskreturn_offsets_mappingreturn_lengthverbosereturn_tensorsreturnc                 J     | j                   d|||||||||	|
|||||d|}|S )z
        This method uses [`BertTokenizerFast.__call__`] to prepare text for the model.

        Please refer to the docstring of the above two methods for more information.
        )r   r   r   r   r   r    r!   r"   r#   r$   r%   r&   r'   r(   r)    )r   )r   r   r   r   r   r   r    r!   r"   r#   r$   r%   r&   r'   r(   r)   r   encodings                     r   __call__zBrosProcessor.__call__/   sW    0 "4>> 
1!!1"7"7&?'A#9')
  !
& r   )N)NTFNNr   NNNFFFFTN)__name__
__module____qualname____doc__
attributestokenizer_classr   r   r
   r	   listboolstrr   r   r   intr   r   r.   __classcell__)r   s   @r   r   r      s?   	 J<O$ _c#'5:;?$(,00404*/+0',#;?!+I0$y/4HYCZZ[+ !+ tS/12	+
 $%778+ SM+ + %SM+  (~+  (~+ $(+ %)+ !%+ + +  !sJ!78!+$ 
%+r   r   N)r2   typingr   r   processing_utilsr   tokenization_utils_baser   r   r	   r
   r   utilsr   r   __all__r,   r   r   <module>r?      s4    # . w w @N @F 
r   