class_docstr: Constructs a DeBERTa-v2 tokenizer. Based on [SentencePiece](https://github.com/google/sentencepiece).
  
  Args:
      vocab_file (`str`):
          [SentencePiece](https://github.com/google/sentencepiece) file (generally has a *.spm* extension) that
          contains the vocabulary necessary to instantiate a tokenizer.
      do_lower_case (`bool`, *optional*, defaults to `False`):
          Whether or not to lowercase the input when tokenizing.
      bos_token (`string`, *optional*, defaults to `"[CLS]"`):
          The beginning of sequence token that was used during pre-training. Can be used a sequence classifier token.
          When building a sequence using special tokens, this is not the token that is used for the beginning of
          sequence. The token used is the `cls_token`.
      eos_token (`string`, *optional*, defaults to `"[SEP]"`):
          The end of sequence token. When building a sequence using special tokens, this is not the token that is
          used for the end of sequence. The token used is the `sep_token`.
      unk_token (`str`, *optional*, defaults to `"[UNK]"`):
          The unknown token. A token that is not in the vocabulary cannot be converted to an ID and is set to be this
          token instead.
      sep_token (`str`, *optional*, defaults to `"[SEP]"`):
          The separator token, which is used when building a sequence from multiple sequences, e.g. two sequences for
          sequence classification or for a text and a question for question answering. It is also used as the last
          token of a sequence built with special tokens.
      pad_token (`str`, *optional*, defaults to `"[PAD]"`):
          The token used for padding, for example when batching sequences of different lengths.
      cls_token (`str`, *optional*, defaults to `"[CLS]"`):
          The classifier token which is used when doing sequence classification (classification of the whole sequence
          instead of per-token classification). It is the first token of the sequence when built with special tokens.
      mask_token (`str`, *optional*, defaults to `"[MASK]"`):
          The token used for masking values. This is the token used when training this model with masked language
          modeling. This is the token which the model will try to predict.
      sp_model_kwargs (`dict`, *optional*):
          Will be passed to the `SentencePieceProcessor.__init__()` method. The [Python wrapper for
          SentencePiece](https://github.com/google/sentencepiece/tree/master/python) can be used, among other things,
          to set:
  
          - `enable_sampling`: Enable subword regularization.
          - `nbest_size`: Sampling parameters for unigram. Invalid for BPE-Dropout.
  
            - `nbest_size = {0,1}`: No sampling is performed.
            - `nbest_size > 1`: samples from the nbest_size results.
            - `nbest_size < 0`: assuming that nbest_size is infinite and samples from the all hypothesis (lattice)
              using forward-filtering-and-backward-sampling algorithm.
  
          - `alpha`: Smoothing parameter for unigram sampling, and dropout probability of merge operations for
            BPE-dropout.
class_docstr_tok: ["Constructs","a","DeBERTa-v2","tokenizer",".","Based","on","[","SentencePiece","]","(","https",":","\/\/github.com\/google\/sentencepiece",")",".","Args",":","vocab_file","(","`","str","`",")",":","[","SentencePiece","]","(","https",":","\/\/github.com\/google\/sentencepiece",")","file","(","generally","has","a","*",".spm","*","extension",")","that","contains","the","vocabulary","necessary","to","instantiate","a","tokenizer",".","do_lower_case","(","`","bool","`",",","*","optional","*",",","defaults","to","`","False","`",")",":","Whether","or","not","to","lowercase","the","input","when","tokenizing",".","bos_token","(","`","string","`",",","*","optional","*",",","defaults","to","`","``","[","CLS","]","''","`",")",":","The","beginning","of","sequence","token","that","was","used","during","pre-training",".","Can","be","used","a","sequence","classifier","token",".","When","building","a","sequence","using","special","tokens",",","this","is","not","the","token","that","is","used","for","the","beginning","of","sequence",".","The","token","used","is","the","`","cls_token","`",".","eos_token","(","`","string","`",",","*","optional","*",",","defaults","to","`","``","[","SEP","]","''","`",")",":","The","end","of","sequence","token",".","When","building","a","sequence","using","special","tokens",",","this","is","not","the","token","that","is","used","for","the","end","of","sequence",".","The","token","used","is","the","`","sep_token","`",".","unk_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","[","UNK","]","''","`",")",":","The","unknown","token",".","A","token","that","is","not","in","the","vocabulary","can","not","be","converted","to","an","ID","and","is","set","to","be","this","token","instead",".","sep_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","[","SEP","]","''","`",")",":","The","separator","token",",","which","is","used","when","building","a","sequence","from","multiple","sequences",",","e.g",".","two","sequences","for","sequence","classification","or","for","a","text","and","a","question","for","question","answering",".","It","is","also","used","as","the","last","token","of","a","sequence","built","with","special","tokens",".","pad_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","[","PAD","]","''","`",")",":","The","token","used","for","padding",",","for","example","when","batching","sequences","of","different","lengths",".","cls_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","[","CLS","]","''","`",")",":","The","classifier","token","which","is","used","when","doing","sequence","classification","(","classification","of","the","whole","sequence","instead","of","per-token","classification",")",".","It","is","the","first","token","of","the","sequence","when","built","with","special","tokens",".","mask_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","[","MASK","]","''","`",")",":","The","token","used","for","masking","values",".","This","is","the","token","used","when","training","this","model","with","masked","language","modeling",".","This","is","the","token","which","the","model","will","try","to","predict",".","sp_model_kwargs","(","`","dict","`",",","*","optional","*",")",":","Will","be","passed","to","the","`","SentencePieceProcessor.__init__","(",")","`","method",".","The","[","Python","wrapper","for","SentencePiece","]","(","https",":","\/\/github.com\/google\/sentencepiece\/tree\/master\/python",")","can","be","used",",","among","other","things",",","to","set",":","-","`","enable_sampling","`",":","Enable","subword","regularization",".","-","`","nbest_size","`",":","Sampling","parameters","for","unigram",".","Invalid","for","BPE-Dropout",".","-","`","nbest_size","=","{","0,1","}","`",":","No","sampling","is","performed",".","-","`","nbest_size",">","1","`",":","samples","from","the","nbest_size","results",".","-","`","nbest_size","<","0","`",":","assuming","that","nbest_size","is","infinite","and","samples","from","the","all","hypothesis","(","lattice",")","using","forward-filtering-and-backward-sampling","algorithm",".","-","`","alpha","`",":","Smoothing","parameter","for","unigram","sampling",",","and","dropout","probability","of","merge","operations","for","BPE-dropout","."]
docstr: Create a mask from the two sequences passed to be used in a sequence-pair classification task. A DeBERTa
  sequence pair mask has the following format:
  
  ```
  0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1
  | first sequence    | second sequence |
  ```
  
  If `token_ids_1` is `None`, this method only returns the first portion of the mask (0s).
  
  Args:
      token_ids_0 (`List[int]`):
          List of IDs.
      token_ids_1 (`List[int]`, *optional*):
          Optional second list of IDs for sequence pairs.
  
  Returns:
      `List[int]`: List of [token type IDs](../glossary#token-type-ids) according to the given sequence(s).
docstr_tok: ["Create","a","mask","from","the","two","sequences","passed","to","be","used","in","a","sequence-pair","classification","task",".","A","DeBERTa","sequence","pair","mask","has","the","following","format",":","``","`","0","0","0","0","0","0","0","0","0","0","0","1","1","1","1","1","1","1","1","1","|","first","sequence","|","second","sequence","|","``","`","If","`","token_ids_1","`","is","`","None","`",",","this","method","only","returns","the","first","portion","of","the","mask","(","0s",")",".","Args",":","token_ids_0","(","`","List","[","int","]","`",")",":","List","of","IDs",".","token_ids_1","(","`","List","[","int","]","`",",","*","optional","*",")",":","Optional","second","list","of","IDs","for","sequence","pairs",".","Returns",":","`","List","[","int","]","`",":","List","of","[","token","type","IDs","]","(","..","\/glossary","#","token-type-ids",")","according","to","the","given","sequence","(","s",")","."]
code: def create_token_type_ids_from_sequences(
      self, token_ids_0, token_ids_1=None
  ):
      """
      Create a mask from the two sequences passed to be used in a sequence-pair classification task. A DeBERTa
      sequence pair mask has the following format:
  
      ```
      0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1
      | first sequence    | second sequence |
      ```
  
      If `token_ids_1` is `None`, this method only returns the first portion of the mask (0s).
  
      Args:
          token_ids_0 (`List[int]`):
              List of IDs.
          token_ids_1 (`List[int]`, *optional*):
              Optional second list of IDs for sequence pairs.
  
      Returns:
          `List[int]`: List of [token type IDs](../glossary#token-type-ids) according to the given sequence(s).
      """
      sep = [self.sep_token_id]
      cls = [self.cls_token_id]
      if token_ids_1 is None:
          return len(cls + token_ids_0 + sep) * [0]
      return len(cls + token_ids_0 + sep) * [0] + len(
          token_ids_1 + sep
      ) * [1]
  
imports: import os
  import unicodedata
  from typing import Any, Dict, List, Optional, Tuple
  import sentencepiece
  from ...tokenization_utils import PreTrainedTokenizer
label_desc: Use image node_id 11 for calling the DebertaV2Tokenizer obj's underlying member method code with example usage: obj.create_token_type_ids_from_sequences(token_ids_0, token_ids_1) and returns: unknown, unknown