import{S as Mv,i as Cv,s as Av,e as a,k as c,w as v,t as n,M as Pv,c as r,d as t,m as p,a as i,x as T,h as s,b as f,G as e,g,y,q as $,o as D,B as E,v as Rv,L as Ue}from"../../chunks/vendor-hf-doc-builder.js";import{T as at}from"../../chunks/Tip-hf-doc-builder.js";import{D as te}from"../../chunks/Docstring-hf-doc-builder.js";import{C as Qe}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as tt}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as He}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";import{P as Gc}from"../../chunks/PipelineTag-hf-doc-builder.js";function Lv(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import DebertaConfig, DebertaModel

# Initializing a DeBERTa microsoft/deberta-base style configuration
configuration = DebertaConfig()

# Initializing a model (with random weights) from the microsoft/deberta-base style configuration
model = DebertaModel(configuration)

# Accessing the model configuration
configuration = model.config`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DebertaConfig, DebertaModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a DeBERTa microsoft/deberta-base style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = DebertaConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the microsoft/deberta-base style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaModel(configuration)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Accessing the model configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = model.config`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Bv(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import DebertaTokenizer

tokenizer = DebertaTokenizer.from_pretrained("microsoft/deberta-base")
tokenizer("Hello world")["input_ids"]

tokenizer(" Hello world")["input_ids"]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DebertaTokenizer

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DebertaTokenizer.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer(<span class="hljs-string">&quot;Hello world&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
[<span class="hljs-number">1</span>, <span class="hljs-number">31414</span>, <span class="hljs-number">232</span>, <span class="hljs-number">2</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer(<span class="hljs-string">&quot; Hello world&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
[<span class="hljs-number">1</span>, <span class="hljs-number">20920</span>, <span class="hljs-number">232</span>, <span class="hljs-number">2</span>]`}}),{c(){d=a("p"),b=n("be encoded differently whether it is at the beginning of the sentence (without space) or not:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"be encoded differently whether it is at the beginning of the sentence (without space) or not:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Iv(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("When used with "),m=a("code"),u=n("is_split_into_words=True"),k=n(", this tokenizer will add a space before each word (even the first one).")},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"When used with "),m=r(h,"CODE",{});var z=i(m);u=s(z,"is_split_into_words=True"),z.forEach(t),k=s(h,", this tokenizer will add a space before each word (even the first one)."),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function Sv(x){let d,b,m,u,k;return u=new Qe({props:{code:`0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1
| first sequence    | second sequence |`,highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence    | second sequence |`}}),{c(){d=a("p"),b=n("sequence pair mask has the following format:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"sequence pair mask has the following format:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Ov(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import DebertaTokenizerFast

tokenizer = DebertaTokenizerFast.from_pretrained("microsoft/deberta-base")
tokenizer("Hello world")["input_ids"]

tokenizer(" Hello world")["input_ids"]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DebertaTokenizerFast

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DebertaTokenizerFast.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer(<span class="hljs-string">&quot;Hello world&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
[<span class="hljs-number">1</span>, <span class="hljs-number">31414</span>, <span class="hljs-number">232</span>, <span class="hljs-number">2</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer(<span class="hljs-string">&quot; Hello world&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
[<span class="hljs-number">1</span>, <span class="hljs-number">20920</span>, <span class="hljs-number">232</span>, <span class="hljs-number">2</span>]`}}),{c(){d=a("p"),b=n("be encoded differently whether it is at the beginning of the sentence (without space) or not:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"be encoded differently whether it is at the beginning of the sentence (without space) or not:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Nv(x){let d,b,m,u,k,l,h,z;return{c(){d=a("p"),b=n("When used with "),m=a("code"),u=n("is_split_into_words=True"),k=n(", this tokenizer needs to be instantiated with "),l=a("code"),h=n("add_prefix_space=True"),z=n(".")},l(ae){d=r(ae,"P",{});var V=i(d);b=s(V,"When used with "),m=r(V,"CODE",{});var L=i(m);u=s(L,"is_split_into_words=True"),L.forEach(t),k=s(V,", this tokenizer needs to be instantiated with "),l=r(V,"CODE",{});var oe=i(l);h=s(oe,"add_prefix_space=True"),oe.forEach(t),z=s(V,"."),V.forEach(t)},m(ae,V){g(ae,d,V),e(d,b),e(d,m),e(m,u),e(d,k),e(d,l),e(l,h),e(d,z)},d(ae){ae&&t(d)}}}function Wv(x){let d,b,m,u,k;return u=new Qe({props:{code:`0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1
| first sequence    | second sequence |`,highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence    | second sequence |`}}),{c(){d=a("p"),b=n("sequence pair mask has the following format:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"sequence pair mask has the following format:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Hv(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function Uv(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, DebertaModel
import torch

tokenizer = AutoTokenizer.from_pretrained("microsoft/deberta-base")
model = DebertaModel.from_pretrained("microsoft/deberta-base")

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
outputs = model(**inputs)

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DebertaModel
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaModel.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>last_hidden_states = outputs.last_hidden_state`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Qv(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function Kv(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, DebertaForMaskedLM
import torch

tokenizer = AutoTokenizer.from_pretrained("lsanochkin/deberta-large-feedback")
model = DebertaForMaskedLM.from_pretrained("lsanochkin/deberta-large-feedback")

inputs = tokenizer("The capital of France is [MASK].", return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

# retrieve index of [MASK]
mask_token_index = (inputs.input_ids == tokenizer.mask_token_id)[0].nonzero(as_tuple=True)[0]

predicted_token_id = logits[0, mask_token_index].argmax(axis=-1)
tokenizer.decode(predicted_token_id)

labels = tokenizer("The capital of France is Paris.", return_tensors="pt")["input_ids"]
# mask labels of non-[MASK] tokens
labels = torch.where(inputs.input_ids == tokenizer.mask_token_id, labels, -100)

outputs = model(**inputs, labels=labels)
round(outputs.loss.item(), 2)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DebertaForMaskedLM
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;lsanochkin/deberta-large-feedback&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaForMaskedLM.from_pretrained(<span class="hljs-string">&quot;lsanochkin/deberta-large-feedback&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is [MASK].&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># retrieve index of [MASK]</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>mask_token_index = (inputs.input_ids == tokenizer.mask_token_id)[<span class="hljs-number">0</span>].nonzero(as_tuple=<span class="hljs-literal">True</span>)[<span class="hljs-number">0</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_id = logits[<span class="hljs-number">0</span>, mask_token_index].argmax(axis=-<span class="hljs-number">1</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predicted_token_id)
<span class="hljs-string">&#x27; Paris&#x27;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># mask labels of non-[MASK] tokens</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(outputs.loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">0.54</span>`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Gv(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function Vv(x){let d,b,m,u,k;return u=new Qe({props:{code:`import torch
from transformers import AutoTokenizer, DebertaForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("microsoft/deberta-base")
model = DebertaForSequenceClassification.from_pretrained("microsoft/deberta-base")

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

predicted_class_id = logits.argmax().item()

# To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`
num_labels = len(model.config.id2label)
model = DebertaForSequenceClassification.from_pretrained("microsoft/deberta-base", num_labels=num_labels)

labels = torch.tensor([1])
loss = model(**inputs, labels=labels).loss`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DebertaForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = logits.argmax().item()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>, num_labels=num_labels)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.tensor([<span class="hljs-number">1</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=a("p"),b=n("Example of single-label classification:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example of single-label classification:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Jv(x){let d,b,m,u,k;return u=new Qe({props:{code:`import torch
from transformers import AutoTokenizer, DebertaForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("microsoft/deberta-base")
model = DebertaForSequenceClassification.from_pretrained("microsoft/deberta-base", problem_type="multi_label_classification")

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

predicted_class_ids = torch.arange(0, logits.shape[-1])[torch.sigmoid(logits).squeeze(dim=0) > 0.5]

# To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`
num_labels = len(model.config.id2label)
model = DebertaForSequenceClassification.from_pretrained(
    "microsoft/deberta-base", num_labels=num_labels, problem_type="multi_label_classification"
)

labels = torch.sum(
    torch.nn.functional.one_hot(predicted_class_ids[None, :].clone(), num_classes=num_labels), dim=1
).to(torch.float)
loss = model(**inputs, labels=labels).loss`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DebertaForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>, problem_type=<span class="hljs-string">&quot;multi_label_classification&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_ids = torch.arange(<span class="hljs-number">0</span>, logits.shape[-<span class="hljs-number">1</span>])[torch.sigmoid(logits).squeeze(dim=<span class="hljs-number">0</span>) &gt; <span class="hljs-number">0.5</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaForSequenceClassification.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>, num_labels=num_labels, problem_type=<span class="hljs-string">&quot;multi_label_classification&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.<span class="hljs-built_in">sum</span>(
<span class="hljs-meta">... </span>    torch.nn.functional.one_hot(predicted_class_ids[<span class="hljs-literal">None</span>, :].clone(), num_classes=num_labels), dim=<span class="hljs-number">1</span>
<span class="hljs-meta">... </span>).to(torch.<span class="hljs-built_in">float</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=a("p"),b=n("Example of multi-label classification:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example of multi-label classification:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Xv(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function Yv(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, DebertaForTokenClassification
import torch

tokenizer = AutoTokenizer.from_pretrained("microsoft/deberta-base")
model = DebertaForTokenClassification.from_pretrained("microsoft/deberta-base")

inputs = tokenizer(
    "HuggingFace is a company based in Paris and New York", add_special_tokens=False, return_tensors="pt"
)

with torch.no_grad():
    logits = model(**inputs).logits

predicted_token_class_ids = logits.argmax(-1)

# Note that tokens are classified rather then input words which means that
# there might be more predicted token classes than words.
# Multiple token classes might account for the same word
predicted_tokens_classes = [model.config.id2label[t.item()] for t in predicted_token_class_ids[0]]

labels = predicted_token_class_ids
loss = model(**inputs, labels=labels).loss`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DebertaForTokenClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaForTokenClassification.from_pretrained(<span class="hljs-string">&quot;microsoft/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;HuggingFace is a company based in Paris and New York&quot;</span>, add_special_tokens=<span class="hljs-literal">False</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_class_ids = logits.argmax(-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Note that tokens are classified rather then input words which means that</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># there might be more predicted token classes than words.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Multiple token classes might account for the same word</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes = [model.config.id2label[t.item()] <span class="hljs-keyword">for</span> t <span class="hljs-keyword">in</span> predicted_token_class_ids[<span class="hljs-number">0</span>]]

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function Zv(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function eT(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, DebertaForQuestionAnswering
import torch

tokenizer = AutoTokenizer.from_pretrained("Palak/microsoft_deberta-large_squad")
model = DebertaForQuestionAnswering.from_pretrained("Palak/microsoft_deberta-large_squad")

question, text = "Who was Jim Henson?", "Jim Henson was a nice puppet"

inputs = tokenizer(question, text, return_tensors="pt")
with torch.no_grad():
    outputs = model(**inputs)

answer_start_index = outputs.start_logits.argmax()
answer_end_index = outputs.end_logits.argmax()

predict_answer_tokens = inputs.input_ids[0, answer_start_index : answer_end_index + 1]
tokenizer.decode(predict_answer_tokens, skip_special_tokens=True)

# target is "nice puppet"
target_start_index = torch.tensor([12])
target_end_index = torch.tensor([14])

outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
loss = outputs.loss
round(loss.item(), 2)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DebertaForQuestionAnswering
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;Palak/microsoft_deberta-large_squad&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DebertaForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;Palak/microsoft_deberta-large_squad&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>question, text = <span class="hljs-string">&quot;Who was Jim Henson?&quot;</span>, <span class="hljs-string">&quot;Jim Henson was a nice puppet&quot;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(question, text, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    outputs = model(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>answer_start_index = outputs.start_logits.argmax()
<span class="hljs-meta">&gt;&gt;&gt; </span>answer_end_index = outputs.end_logits.argmax()

<span class="hljs-meta">&gt;&gt;&gt; </span>predict_answer_tokens = inputs.input_ids[<span class="hljs-number">0</span>, answer_start_index : answer_end_index + <span class="hljs-number">1</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predict_answer_tokens, skip_special_tokens=<span class="hljs-literal">True</span>)
<span class="hljs-string">&#x27; a nice puppet&#x27;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># target is &quot;nice puppet&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>target_start_index = torch.tensor([<span class="hljs-number">12</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>target_end_index = torch.tensor([<span class="hljs-number">14</span>])

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">0.14</span>`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function tT(x){let d,b,m,u,k,l,h,z,ae,V,L,oe,se,F,ye,G,$e,_e,S,De,de,J,Ee,be,Q,Fe,ke,K,qe,we,ne,M,C,ce,X,xe,ve,B,ze,pe,A,je,W,Me,Ce,H,Ae,Pe,I,re,O,me,Z,P,ue,R,Te,fe;return{c(){d=a("p"),b=n("TensorFlow models and layers in "),m=a("code"),u=n("transformers"),k=n(" accept two formats as input:"),l=c(),h=a("ul"),z=a("li"),ae=n("having all inputs as keyword arguments (like PyTorch models), or"),V=c(),L=a("li"),oe=n("having all inputs as a list, tuple or dict in the first positional argument."),se=c(),F=a("p"),ye=n(`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=a("code"),$e=n("model.fit()"),_e=n(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=a("code"),De=n("model.fit()"),de=n(` supports! If, however, you want to use the second
format outside of Keras methods like `),J=a("code"),Ee=n("fit()"),be=n(" and "),Q=a("code"),Fe=n("predict()"),ke=n(`, such as when creating your own layers or models with
the Keras `),K=a("code"),qe=n("Functional"),we=n(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),ne=c(),M=a("ul"),C=a("li"),ce=n("a single Tensor with "),X=a("code"),xe=n("input_ids"),ve=n(" only and nothing else: "),B=a("code"),ze=n("model(input_ids)"),pe=c(),A=a("li"),je=n(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=a("code"),Me=n("model([input_ids, attention_mask])"),Ce=n(" or "),H=a("code"),Ae=n("model([input_ids, attention_mask, token_type_ids])"),Pe=c(),I=a("li"),re=n(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=a("code"),me=n('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Z=c(),P=a("p"),ue=n(`Note that when creating models and layers with
`),R=a("a"),Te=n("subclassing"),fe=n(` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),this.h()},l(w){d=r(w,"P",{});var q=i(d);b=s(q,"TensorFlow models and layers in "),m=r(q,"CODE",{});var Be=i(m);u=s(Be,"transformers"),Be.forEach(t),k=s(q," accept two formats as input:"),q.forEach(t),l=p(w),h=r(w,"UL",{});var ie=i(h);z=r(ie,"LI",{});var le=i(z);ae=s(le,"having all inputs as keyword arguments (like PyTorch models), or"),le.forEach(t),V=p(ie),L=r(ie,"LI",{});var Ie=i(L);oe=s(Ie,"having all inputs as a list, tuple or dict in the first positional argument."),Ie.forEach(t),ie.forEach(t),se=p(w),F=r(w,"P",{});var j=i(F);ye=s(j,`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=r(j,"CODE",{});var Se=i(G);$e=s(Se,"model.fit()"),Se.forEach(t),_e=s(j,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(j,"CODE",{});var Ke=i(S);De=s(Ke,"model.fit()"),Ke.forEach(t),de=s(j,` supports! If, however, you want to use the second
format outside of Keras methods like `),J=r(j,"CODE",{});var Ge=i(J);Ee=s(Ge,"fit()"),Ge.forEach(t),be=s(j," and "),Q=r(j,"CODE",{});var Ve=i(Q);Fe=s(Ve,"predict()"),Ve.forEach(t),ke=s(j,`, such as when creating your own layers or models with
the Keras `),K=r(j,"CODE",{});var Oe=i(K);qe=s(Oe,"Functional"),Oe.forEach(t),we=s(j,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),j.forEach(t),ne=p(w),M=r(w,"UL",{});var N=i(M);C=r(N,"LI",{});var U=i(C);ce=s(U,"a single Tensor with "),X=r(U,"CODE",{});var Je=i(X);xe=s(Je,"input_ids"),Je.forEach(t),ve=s(U," only and nothing else: "),B=r(U,"CODE",{});var Xe=i(B);ze=s(Xe,"model(input_ids)"),Xe.forEach(t),U.forEach(t),pe=p(N),A=r(N,"LI",{});var Y=i(A);je=s(Y,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=r(Y,"CODE",{});var ge=i(W);Me=s(ge,"model([input_ids, attention_mask])"),ge.forEach(t),Ce=s(Y," or "),H=r(Y,"CODE",{});var We=i(H);Ae=s(We,"model([input_ids, attention_mask, token_type_ids])"),We.forEach(t),Y.forEach(t),Pe=p(N),I=r(N,"LI",{});var Re=i(I);re=s(Re,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=r(Re,"CODE",{});var Ye=i(O);me=s(Ye,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Ye.forEach(t),Re.forEach(t),N.forEach(t),Z=p(w),P=r(w,"P",{});var ee=i(P);ue=s(ee,`Note that when creating models and layers with
`),R=r(ee,"A",{href:!0,rel:!0});var Ze=i(R);Te=s(Ze,"subclassing"),Ze.forEach(t),fe=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){f(R,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),f(R,"rel","nofollow")},m(w,q){g(w,d,q),e(d,b),e(d,m),e(m,u),e(d,k),g(w,l,q),g(w,h,q),e(h,z),e(z,ae),e(h,V),e(h,L),e(L,oe),g(w,se,q),g(w,F,q),e(F,ye),e(F,G),e(G,$e),e(F,_e),e(F,S),e(S,De),e(F,de),e(F,J),e(J,Ee),e(F,be),e(F,Q),e(Q,Fe),e(F,ke),e(F,K),e(K,qe),e(F,we),g(w,ne,q),g(w,M,q),e(M,C),e(C,ce),e(C,X),e(X,xe),e(C,ve),e(C,B),e(B,ze),e(M,pe),e(M,A),e(A,je),e(A,W),e(W,Me),e(A,Ce),e(A,H),e(H,Ae),e(M,Pe),e(M,I),e(I,re),e(I,O),e(O,me),g(w,Z,q),g(w,P,q),e(P,ue),e(P,R),e(R,Te),e(P,fe)},d(w){w&&t(d),w&&t(l),w&&t(h),w&&t(se),w&&t(F),w&&t(ne),w&&t(M),w&&t(Z),w&&t(P)}}}function oT(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function nT(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, TFDebertaModel
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("kamalkraj/deberta-base")
model = TFDebertaModel.from_pretrained("kamalkraj/deberta-base")

inputs = tokenizer("Hello, my dog is cute", return_tensors="tf")
outputs = model(inputs)

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFDebertaModel
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDebertaModel.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>last_hidden_states = outputs.last_hidden_state`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function sT(x){let d,b,m,u,k,l,h,z,ae,V,L,oe,se,F,ye,G,$e,_e,S,De,de,J,Ee,be,Q,Fe,ke,K,qe,we,ne,M,C,ce,X,xe,ve,B,ze,pe,A,je,W,Me,Ce,H,Ae,Pe,I,re,O,me,Z,P,ue,R,Te,fe;return{c(){d=a("p"),b=n("TensorFlow models and layers in "),m=a("code"),u=n("transformers"),k=n(" accept two formats as input:"),l=c(),h=a("ul"),z=a("li"),ae=n("having all inputs as keyword arguments (like PyTorch models), or"),V=c(),L=a("li"),oe=n("having all inputs as a list, tuple or dict in the first positional argument."),se=c(),F=a("p"),ye=n(`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=a("code"),$e=n("model.fit()"),_e=n(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=a("code"),De=n("model.fit()"),de=n(` supports! If, however, you want to use the second
format outside of Keras methods like `),J=a("code"),Ee=n("fit()"),be=n(" and "),Q=a("code"),Fe=n("predict()"),ke=n(`, such as when creating your own layers or models with
the Keras `),K=a("code"),qe=n("Functional"),we=n(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),ne=c(),M=a("ul"),C=a("li"),ce=n("a single Tensor with "),X=a("code"),xe=n("input_ids"),ve=n(" only and nothing else: "),B=a("code"),ze=n("model(input_ids)"),pe=c(),A=a("li"),je=n(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=a("code"),Me=n("model([input_ids, attention_mask])"),Ce=n(" or "),H=a("code"),Ae=n("model([input_ids, attention_mask, token_type_ids])"),Pe=c(),I=a("li"),re=n(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=a("code"),me=n('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Z=c(),P=a("p"),ue=n(`Note that when creating models and layers with
`),R=a("a"),Te=n("subclassing"),fe=n(` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),this.h()},l(w){d=r(w,"P",{});var q=i(d);b=s(q,"TensorFlow models and layers in "),m=r(q,"CODE",{});var Be=i(m);u=s(Be,"transformers"),Be.forEach(t),k=s(q," accept two formats as input:"),q.forEach(t),l=p(w),h=r(w,"UL",{});var ie=i(h);z=r(ie,"LI",{});var le=i(z);ae=s(le,"having all inputs as keyword arguments (like PyTorch models), or"),le.forEach(t),V=p(ie),L=r(ie,"LI",{});var Ie=i(L);oe=s(Ie,"having all inputs as a list, tuple or dict in the first positional argument."),Ie.forEach(t),ie.forEach(t),se=p(w),F=r(w,"P",{});var j=i(F);ye=s(j,`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=r(j,"CODE",{});var Se=i(G);$e=s(Se,"model.fit()"),Se.forEach(t),_e=s(j,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(j,"CODE",{});var Ke=i(S);De=s(Ke,"model.fit()"),Ke.forEach(t),de=s(j,` supports! If, however, you want to use the second
format outside of Keras methods like `),J=r(j,"CODE",{});var Ge=i(J);Ee=s(Ge,"fit()"),Ge.forEach(t),be=s(j," and "),Q=r(j,"CODE",{});var Ve=i(Q);Fe=s(Ve,"predict()"),Ve.forEach(t),ke=s(j,`, such as when creating your own layers or models with
the Keras `),K=r(j,"CODE",{});var Oe=i(K);qe=s(Oe,"Functional"),Oe.forEach(t),we=s(j,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),j.forEach(t),ne=p(w),M=r(w,"UL",{});var N=i(M);C=r(N,"LI",{});var U=i(C);ce=s(U,"a single Tensor with "),X=r(U,"CODE",{});var Je=i(X);xe=s(Je,"input_ids"),Je.forEach(t),ve=s(U," only and nothing else: "),B=r(U,"CODE",{});var Xe=i(B);ze=s(Xe,"model(input_ids)"),Xe.forEach(t),U.forEach(t),pe=p(N),A=r(N,"LI",{});var Y=i(A);je=s(Y,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=r(Y,"CODE",{});var ge=i(W);Me=s(ge,"model([input_ids, attention_mask])"),ge.forEach(t),Ce=s(Y," or "),H=r(Y,"CODE",{});var We=i(H);Ae=s(We,"model([input_ids, attention_mask, token_type_ids])"),We.forEach(t),Y.forEach(t),Pe=p(N),I=r(N,"LI",{});var Re=i(I);re=s(Re,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=r(Re,"CODE",{});var Ye=i(O);me=s(Ye,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Ye.forEach(t),Re.forEach(t),N.forEach(t),Z=p(w),P=r(w,"P",{});var ee=i(P);ue=s(ee,`Note that when creating models and layers with
`),R=r(ee,"A",{href:!0,rel:!0});var Ze=i(R);Te=s(Ze,"subclassing"),Ze.forEach(t),fe=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){f(R,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),f(R,"rel","nofollow")},m(w,q){g(w,d,q),e(d,b),e(d,m),e(m,u),e(d,k),g(w,l,q),g(w,h,q),e(h,z),e(z,ae),e(h,V),e(h,L),e(L,oe),g(w,se,q),g(w,F,q),e(F,ye),e(F,G),e(G,$e),e(F,_e),e(F,S),e(S,De),e(F,de),e(F,J),e(J,Ee),e(F,be),e(F,Q),e(Q,Fe),e(F,ke),e(F,K),e(K,qe),e(F,we),g(w,ne,q),g(w,M,q),e(M,C),e(C,ce),e(C,X),e(X,xe),e(C,ve),e(C,B),e(B,ze),e(M,pe),e(M,A),e(A,je),e(A,W),e(W,Me),e(A,Ce),e(A,H),e(H,Ae),e(M,Pe),e(M,I),e(I,re),e(I,O),e(O,me),g(w,Z,q),g(w,P,q),e(P,ue),e(P,R),e(R,Te),e(P,fe)},d(w){w&&t(d),w&&t(l),w&&t(h),w&&t(se),w&&t(F),w&&t(ne),w&&t(M),w&&t(Z),w&&t(P)}}}function aT(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function rT(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, TFDebertaForMaskedLM
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("kamalkraj/deberta-base")
model = TFDebertaForMaskedLM.from_pretrained("kamalkraj/deberta-base")

inputs = tokenizer("The capital of France is [MASK].", return_tensors="tf")
logits = model(**inputs).logits

# retrieve index of [MASK]
mask_token_index = tf.where((inputs.input_ids == tokenizer.mask_token_id)[0])
selected_logits = tf.gather_nd(logits[0], indices=mask_token_index)

predicted_token_id = tf.math.argmax(selected_logits, axis=-1)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFDebertaForMaskedLM
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDebertaForMaskedLM.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is [MASK].&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># retrieve index of [MASK]</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>mask_token_index = tf.where((inputs.input_ids == tokenizer.mask_token_id)[<span class="hljs-number">0</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>selected_logits = tf.gather_nd(logits[<span class="hljs-number">0</span>], indices=mask_token_index)

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_id = tf.math.argmax(selected_logits, axis=-<span class="hljs-number">1</span>)`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function iT(x){let d,b;return d=new Qe({props:{code:`labels = tokenizer("The capital of France is Paris.", return_tensors="tf")["input_ids"]
# mask labels of non-[MASK] tokens
labels = tf.where(inputs.input_ids == tokenizer.mask_token_id, labels, -100)

outputs = model(**inputs, labels=labels)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># mask labels of non-[MASK] tokens</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tf.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)`}}),{c(){v(d.$$.fragment)},l(m){T(d.$$.fragment,m)},m(m,u){y(d,m,u),b=!0},p:Ue,i(m){b||($(d.$$.fragment,m),b=!0)},o(m){D(d.$$.fragment,m),b=!1},d(m){E(d,m)}}}function lT(x){let d,b,m,u,k,l,h,z,ae,V,L,oe,se,F,ye,G,$e,_e,S,De,de,J,Ee,be,Q,Fe,ke,K,qe,we,ne,M,C,ce,X,xe,ve,B,ze,pe,A,je,W,Me,Ce,H,Ae,Pe,I,re,O,me,Z,P,ue,R,Te,fe;return{c(){d=a("p"),b=n("TensorFlow models and layers in "),m=a("code"),u=n("transformers"),k=n(" accept two formats as input:"),l=c(),h=a("ul"),z=a("li"),ae=n("having all inputs as keyword arguments (like PyTorch models), or"),V=c(),L=a("li"),oe=n("having all inputs as a list, tuple or dict in the first positional argument."),se=c(),F=a("p"),ye=n(`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=a("code"),$e=n("model.fit()"),_e=n(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=a("code"),De=n("model.fit()"),de=n(` supports! If, however, you want to use the second
format outside of Keras methods like `),J=a("code"),Ee=n("fit()"),be=n(" and "),Q=a("code"),Fe=n("predict()"),ke=n(`, such as when creating your own layers or models with
the Keras `),K=a("code"),qe=n("Functional"),we=n(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),ne=c(),M=a("ul"),C=a("li"),ce=n("a single Tensor with "),X=a("code"),xe=n("input_ids"),ve=n(" only and nothing else: "),B=a("code"),ze=n("model(input_ids)"),pe=c(),A=a("li"),je=n(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=a("code"),Me=n("model([input_ids, attention_mask])"),Ce=n(" or "),H=a("code"),Ae=n("model([input_ids, attention_mask, token_type_ids])"),Pe=c(),I=a("li"),re=n(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=a("code"),me=n('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Z=c(),P=a("p"),ue=n(`Note that when creating models and layers with
`),R=a("a"),Te=n("subclassing"),fe=n(` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),this.h()},l(w){d=r(w,"P",{});var q=i(d);b=s(q,"TensorFlow models and layers in "),m=r(q,"CODE",{});var Be=i(m);u=s(Be,"transformers"),Be.forEach(t),k=s(q," accept two formats as input:"),q.forEach(t),l=p(w),h=r(w,"UL",{});var ie=i(h);z=r(ie,"LI",{});var le=i(z);ae=s(le,"having all inputs as keyword arguments (like PyTorch models), or"),le.forEach(t),V=p(ie),L=r(ie,"LI",{});var Ie=i(L);oe=s(Ie,"having all inputs as a list, tuple or dict in the first positional argument."),Ie.forEach(t),ie.forEach(t),se=p(w),F=r(w,"P",{});var j=i(F);ye=s(j,`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=r(j,"CODE",{});var Se=i(G);$e=s(Se,"model.fit()"),Se.forEach(t),_e=s(j,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(j,"CODE",{});var Ke=i(S);De=s(Ke,"model.fit()"),Ke.forEach(t),de=s(j,` supports! If, however, you want to use the second
format outside of Keras methods like `),J=r(j,"CODE",{});var Ge=i(J);Ee=s(Ge,"fit()"),Ge.forEach(t),be=s(j," and "),Q=r(j,"CODE",{});var Ve=i(Q);Fe=s(Ve,"predict()"),Ve.forEach(t),ke=s(j,`, such as when creating your own layers or models with
the Keras `),K=r(j,"CODE",{});var Oe=i(K);qe=s(Oe,"Functional"),Oe.forEach(t),we=s(j,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),j.forEach(t),ne=p(w),M=r(w,"UL",{});var N=i(M);C=r(N,"LI",{});var U=i(C);ce=s(U,"a single Tensor with "),X=r(U,"CODE",{});var Je=i(X);xe=s(Je,"input_ids"),Je.forEach(t),ve=s(U," only and nothing else: "),B=r(U,"CODE",{});var Xe=i(B);ze=s(Xe,"model(input_ids)"),Xe.forEach(t),U.forEach(t),pe=p(N),A=r(N,"LI",{});var Y=i(A);je=s(Y,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=r(Y,"CODE",{});var ge=i(W);Me=s(ge,"model([input_ids, attention_mask])"),ge.forEach(t),Ce=s(Y," or "),H=r(Y,"CODE",{});var We=i(H);Ae=s(We,"model([input_ids, attention_mask, token_type_ids])"),We.forEach(t),Y.forEach(t),Pe=p(N),I=r(N,"LI",{});var Re=i(I);re=s(Re,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=r(Re,"CODE",{});var Ye=i(O);me=s(Ye,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Ye.forEach(t),Re.forEach(t),N.forEach(t),Z=p(w),P=r(w,"P",{});var ee=i(P);ue=s(ee,`Note that when creating models and layers with
`),R=r(ee,"A",{href:!0,rel:!0});var Ze=i(R);Te=s(Ze,"subclassing"),Ze.forEach(t),fe=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){f(R,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),f(R,"rel","nofollow")},m(w,q){g(w,d,q),e(d,b),e(d,m),e(m,u),e(d,k),g(w,l,q),g(w,h,q),e(h,z),e(z,ae),e(h,V),e(h,L),e(L,oe),g(w,se,q),g(w,F,q),e(F,ye),e(F,G),e(G,$e),e(F,_e),e(F,S),e(S,De),e(F,de),e(F,J),e(J,Ee),e(F,be),e(F,Q),e(Q,Fe),e(F,ke),e(F,K),e(K,qe),e(F,we),g(w,ne,q),g(w,M,q),e(M,C),e(C,ce),e(C,X),e(X,xe),e(C,ve),e(C,B),e(B,ze),e(M,pe),e(M,A),e(A,je),e(A,W),e(W,Me),e(A,Ce),e(A,H),e(H,Ae),e(M,Pe),e(M,I),e(I,re),e(I,O),e(O,me),g(w,Z,q),g(w,P,q),e(P,ue),e(P,R),e(R,Te),e(P,fe)},d(w){w&&t(d),w&&t(l),w&&t(h),w&&t(se),w&&t(F),w&&t(ne),w&&t(M),w&&t(Z),w&&t(P)}}}function dT(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function cT(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, TFDebertaForSequenceClassification
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("kamalkraj/deberta-base")
model = TFDebertaForSequenceClassification.from_pretrained("kamalkraj/deberta-base")

inputs = tokenizer("Hello, my dog is cute", return_tensors="tf")

logits = model(**inputs).logits

predicted_class_id = int(tf.math.argmax(logits, axis=-1)[0])`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFDebertaForSequenceClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDebertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = <span class="hljs-built_in">int</span>(tf.math.argmax(logits, axis=-<span class="hljs-number">1</span>)[<span class="hljs-number">0</span>])`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function pT(x){let d,b;return d=new Qe({props:{code:'# To train a model on `num_labels` classes, you can pass `num_labels=num_labels` to `.from_pretrained(...)`\nnum_labels = len(model.config.id2label)\nmodel = TFDebertaForSequenceClassification.from_pretrained("kamalkraj/deberta-base", num_labels=num_labels)\n\nlabels = tf.constant(1)\nloss = model(**inputs, labels=labels).loss',highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on `num_labels` classes, you can pass `num_labels=num_labels` to `.from_pretrained(...)`</span>\n<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)\n<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDebertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>, num_labels=num_labels)\n\n<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tf.constant(<span class="hljs-number">1</span>)\n<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss'}}),{c(){v(d.$$.fragment)},l(m){T(d.$$.fragment,m)},m(m,u){y(d,m,u),b=!0},p:Ue,i(m){b||($(d.$$.fragment,m),b=!0)},o(m){D(d.$$.fragment,m),b=!1},d(m){E(d,m)}}}function hT(x){let d,b,m,u,k,l,h,z,ae,V,L,oe,se,F,ye,G,$e,_e,S,De,de,J,Ee,be,Q,Fe,ke,K,qe,we,ne,M,C,ce,X,xe,ve,B,ze,pe,A,je,W,Me,Ce,H,Ae,Pe,I,re,O,me,Z,P,ue,R,Te,fe;return{c(){d=a("p"),b=n("TensorFlow models and layers in "),m=a("code"),u=n("transformers"),k=n(" accept two formats as input:"),l=c(),h=a("ul"),z=a("li"),ae=n("having all inputs as keyword arguments (like PyTorch models), or"),V=c(),L=a("li"),oe=n("having all inputs as a list, tuple or dict in the first positional argument."),se=c(),F=a("p"),ye=n(`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=a("code"),$e=n("model.fit()"),_e=n(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=a("code"),De=n("model.fit()"),de=n(` supports! If, however, you want to use the second
format outside of Keras methods like `),J=a("code"),Ee=n("fit()"),be=n(" and "),Q=a("code"),Fe=n("predict()"),ke=n(`, such as when creating your own layers or models with
the Keras `),K=a("code"),qe=n("Functional"),we=n(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),ne=c(),M=a("ul"),C=a("li"),ce=n("a single Tensor with "),X=a("code"),xe=n("input_ids"),ve=n(" only and nothing else: "),B=a("code"),ze=n("model(input_ids)"),pe=c(),A=a("li"),je=n(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=a("code"),Me=n("model([input_ids, attention_mask])"),Ce=n(" or "),H=a("code"),Ae=n("model([input_ids, attention_mask, token_type_ids])"),Pe=c(),I=a("li"),re=n(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=a("code"),me=n('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Z=c(),P=a("p"),ue=n(`Note that when creating models and layers with
`),R=a("a"),Te=n("subclassing"),fe=n(` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),this.h()},l(w){d=r(w,"P",{});var q=i(d);b=s(q,"TensorFlow models and layers in "),m=r(q,"CODE",{});var Be=i(m);u=s(Be,"transformers"),Be.forEach(t),k=s(q," accept two formats as input:"),q.forEach(t),l=p(w),h=r(w,"UL",{});var ie=i(h);z=r(ie,"LI",{});var le=i(z);ae=s(le,"having all inputs as keyword arguments (like PyTorch models), or"),le.forEach(t),V=p(ie),L=r(ie,"LI",{});var Ie=i(L);oe=s(Ie,"having all inputs as a list, tuple or dict in the first positional argument."),Ie.forEach(t),ie.forEach(t),se=p(w),F=r(w,"P",{});var j=i(F);ye=s(j,`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=r(j,"CODE",{});var Se=i(G);$e=s(Se,"model.fit()"),Se.forEach(t),_e=s(j,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(j,"CODE",{});var Ke=i(S);De=s(Ke,"model.fit()"),Ke.forEach(t),de=s(j,` supports! If, however, you want to use the second
format outside of Keras methods like `),J=r(j,"CODE",{});var Ge=i(J);Ee=s(Ge,"fit()"),Ge.forEach(t),be=s(j," and "),Q=r(j,"CODE",{});var Ve=i(Q);Fe=s(Ve,"predict()"),Ve.forEach(t),ke=s(j,`, such as when creating your own layers or models with
the Keras `),K=r(j,"CODE",{});var Oe=i(K);qe=s(Oe,"Functional"),Oe.forEach(t),we=s(j,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),j.forEach(t),ne=p(w),M=r(w,"UL",{});var N=i(M);C=r(N,"LI",{});var U=i(C);ce=s(U,"a single Tensor with "),X=r(U,"CODE",{});var Je=i(X);xe=s(Je,"input_ids"),Je.forEach(t),ve=s(U," only and nothing else: "),B=r(U,"CODE",{});var Xe=i(B);ze=s(Xe,"model(input_ids)"),Xe.forEach(t),U.forEach(t),pe=p(N),A=r(N,"LI",{});var Y=i(A);je=s(Y,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=r(Y,"CODE",{});var ge=i(W);Me=s(ge,"model([input_ids, attention_mask])"),ge.forEach(t),Ce=s(Y," or "),H=r(Y,"CODE",{});var We=i(H);Ae=s(We,"model([input_ids, attention_mask, token_type_ids])"),We.forEach(t),Y.forEach(t),Pe=p(N),I=r(N,"LI",{});var Re=i(I);re=s(Re,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=r(Re,"CODE",{});var Ye=i(O);me=s(Ye,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Ye.forEach(t),Re.forEach(t),N.forEach(t),Z=p(w),P=r(w,"P",{});var ee=i(P);ue=s(ee,`Note that when creating models and layers with
`),R=r(ee,"A",{href:!0,rel:!0});var Ze=i(R);Te=s(Ze,"subclassing"),Ze.forEach(t),fe=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){f(R,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),f(R,"rel","nofollow")},m(w,q){g(w,d,q),e(d,b),e(d,m),e(m,u),e(d,k),g(w,l,q),g(w,h,q),e(h,z),e(z,ae),e(h,V),e(h,L),e(L,oe),g(w,se,q),g(w,F,q),e(F,ye),e(F,G),e(G,$e),e(F,_e),e(F,S),e(S,De),e(F,de),e(F,J),e(J,Ee),e(F,be),e(F,Q),e(Q,Fe),e(F,ke),e(F,K),e(K,qe),e(F,we),g(w,ne,q),g(w,M,q),e(M,C),e(C,ce),e(C,X),e(X,xe),e(C,ve),e(C,B),e(B,ze),e(M,pe),e(M,A),e(A,je),e(A,W),e(W,Me),e(A,Ce),e(A,H),e(H,Ae),e(M,Pe),e(M,I),e(I,re),e(I,O),e(O,me),g(w,Z,q),g(w,P,q),e(P,ue),e(P,R),e(R,Te),e(P,fe)},d(w){w&&t(d),w&&t(l),w&&t(h),w&&t(se),w&&t(F),w&&t(ne),w&&t(M),w&&t(Z),w&&t(P)}}}function fT(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function mT(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, TFDebertaForTokenClassification
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("kamalkraj/deberta-base")
model = TFDebertaForTokenClassification.from_pretrained("kamalkraj/deberta-base")

inputs = tokenizer(
    "HuggingFace is a company based in Paris and New York", add_special_tokens=False, return_tensors="tf"
)

logits = model(**inputs).logits
predicted_token_class_ids = tf.math.argmax(logits, axis=-1)

# Note that tokens are classified rather then input words which means that
# there might be more predicted token classes than words.
# Multiple token classes might account for the same word
predicted_tokens_classes = [model.config.id2label[t] for t in predicted_token_class_ids[0].numpy().tolist()]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFDebertaForTokenClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDebertaForTokenClassification.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;HuggingFace is a company based in Paris and New York&quot;</span>, add_special_tokens=<span class="hljs-literal">False</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_class_ids = tf.math.argmax(logits, axis=-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Note that tokens are classified rather then input words which means that</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># there might be more predicted token classes than words.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Multiple token classes might account for the same word</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes = [model.config.id2label[t] <span class="hljs-keyword">for</span> t <span class="hljs-keyword">in</span> predicted_token_class_ids[<span class="hljs-number">0</span>].numpy().tolist()]`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function uT(x){let d,b;return d=new Qe({props:{code:`labels = predicted_token_class_ids
loss = tf.math.reduce_mean(model(**inputs, labels=labels).loss)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(model(**inputs, labels=labels).loss)`}}),{c(){v(d.$$.fragment)},l(m){T(d.$$.fragment,m)},m(m,u){y(d,m,u),b=!0},p:Ue,i(m){b||($(d.$$.fragment,m),b=!0)},o(m){D(d.$$.fragment,m),b=!1},d(m){E(d,m)}}}function gT(x){let d,b,m,u,k,l,h,z,ae,V,L,oe,se,F,ye,G,$e,_e,S,De,de,J,Ee,be,Q,Fe,ke,K,qe,we,ne,M,C,ce,X,xe,ve,B,ze,pe,A,je,W,Me,Ce,H,Ae,Pe,I,re,O,me,Z,P,ue,R,Te,fe;return{c(){d=a("p"),b=n("TensorFlow models and layers in "),m=a("code"),u=n("transformers"),k=n(" accept two formats as input:"),l=c(),h=a("ul"),z=a("li"),ae=n("having all inputs as keyword arguments (like PyTorch models), or"),V=c(),L=a("li"),oe=n("having all inputs as a list, tuple or dict in the first positional argument."),se=c(),F=a("p"),ye=n(`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=a("code"),$e=n("model.fit()"),_e=n(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=a("code"),De=n("model.fit()"),de=n(` supports! If, however, you want to use the second
format outside of Keras methods like `),J=a("code"),Ee=n("fit()"),be=n(" and "),Q=a("code"),Fe=n("predict()"),ke=n(`, such as when creating your own layers or models with
the Keras `),K=a("code"),qe=n("Functional"),we=n(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),ne=c(),M=a("ul"),C=a("li"),ce=n("a single Tensor with "),X=a("code"),xe=n("input_ids"),ve=n(" only and nothing else: "),B=a("code"),ze=n("model(input_ids)"),pe=c(),A=a("li"),je=n(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=a("code"),Me=n("model([input_ids, attention_mask])"),Ce=n(" or "),H=a("code"),Ae=n("model([input_ids, attention_mask, token_type_ids])"),Pe=c(),I=a("li"),re=n(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=a("code"),me=n('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Z=c(),P=a("p"),ue=n(`Note that when creating models and layers with
`),R=a("a"),Te=n("subclassing"),fe=n(` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),this.h()},l(w){d=r(w,"P",{});var q=i(d);b=s(q,"TensorFlow models and layers in "),m=r(q,"CODE",{});var Be=i(m);u=s(Be,"transformers"),Be.forEach(t),k=s(q," accept two formats as input:"),q.forEach(t),l=p(w),h=r(w,"UL",{});var ie=i(h);z=r(ie,"LI",{});var le=i(z);ae=s(le,"having all inputs as keyword arguments (like PyTorch models), or"),le.forEach(t),V=p(ie),L=r(ie,"LI",{});var Ie=i(L);oe=s(Ie,"having all inputs as a list, tuple or dict in the first positional argument."),Ie.forEach(t),ie.forEach(t),se=p(w),F=r(w,"P",{});var j=i(F);ye=s(j,`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),G=r(j,"CODE",{});var Se=i(G);$e=s(Se,"model.fit()"),Se.forEach(t),_e=s(j,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(j,"CODE",{});var Ke=i(S);De=s(Ke,"model.fit()"),Ke.forEach(t),de=s(j,` supports! If, however, you want to use the second
format outside of Keras methods like `),J=r(j,"CODE",{});var Ge=i(J);Ee=s(Ge,"fit()"),Ge.forEach(t),be=s(j," and "),Q=r(j,"CODE",{});var Ve=i(Q);Fe=s(Ve,"predict()"),Ve.forEach(t),ke=s(j,`, such as when creating your own layers or models with
the Keras `),K=r(j,"CODE",{});var Oe=i(K);qe=s(Oe,"Functional"),Oe.forEach(t),we=s(j,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),j.forEach(t),ne=p(w),M=r(w,"UL",{});var N=i(M);C=r(N,"LI",{});var U=i(C);ce=s(U,"a single Tensor with "),X=r(U,"CODE",{});var Je=i(X);xe=s(Je,"input_ids"),Je.forEach(t),ve=s(U," only and nothing else: "),B=r(U,"CODE",{});var Xe=i(B);ze=s(Xe,"model(input_ids)"),Xe.forEach(t),U.forEach(t),pe=p(N),A=r(N,"LI",{});var Y=i(A);je=s(Y,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),W=r(Y,"CODE",{});var ge=i(W);Me=s(ge,"model([input_ids, attention_mask])"),ge.forEach(t),Ce=s(Y," or "),H=r(Y,"CODE",{});var We=i(H);Ae=s(We,"model([input_ids, attention_mask, token_type_ids])"),We.forEach(t),Y.forEach(t),Pe=p(N),I=r(N,"LI",{});var Re=i(I);re=s(Re,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=r(Re,"CODE",{});var Ye=i(O);me=s(Ye,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Ye.forEach(t),Re.forEach(t),N.forEach(t),Z=p(w),P=r(w,"P",{});var ee=i(P);ue=s(ee,`Note that when creating models and layers with
`),R=r(ee,"A",{href:!0,rel:!0});var Ze=i(R);Te=s(Ze,"subclassing"),Ze.forEach(t),fe=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){f(R,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),f(R,"rel","nofollow")},m(w,q){g(w,d,q),e(d,b),e(d,m),e(m,u),e(d,k),g(w,l,q),g(w,h,q),e(h,z),e(z,ae),e(h,V),e(h,L),e(L,oe),g(w,se,q),g(w,F,q),e(F,ye),e(F,G),e(G,$e),e(F,_e),e(F,S),e(S,De),e(F,de),e(F,J),e(J,Ee),e(F,be),e(F,Q),e(Q,Fe),e(F,ke),e(F,K),e(K,qe),e(F,we),g(w,ne,q),g(w,M,q),e(M,C),e(C,ce),e(C,X),e(X,xe),e(C,ve),e(C,B),e(B,ze),e(M,pe),e(M,A),e(A,je),e(A,W),e(W,Me),e(A,Ce),e(A,H),e(H,Ae),e(M,Pe),e(M,I),e(I,re),e(I,O),e(O,me),g(w,Z,q),g(w,P,q),e(P,ue),e(P,R),e(R,Te),e(P,fe)},d(w){w&&t(d),w&&t(l),w&&t(h),w&&t(se),w&&t(F),w&&t(ne),w&&t(M),w&&t(Z),w&&t(P)}}}function _T(x){let d,b,m,u,k;return{c(){d=a("p"),b=n("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a("code"),u=n("Module"),k=n(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=r(h,"CODE",{});var z=i(m);u=s(z,"Module"),z.forEach(t),k=s(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(l,h){g(l,d,h),e(d,b),e(d,m),e(m,u),e(d,k)},d(l){l&&t(d)}}}function bT(x){let d,b,m,u,k;return u=new Qe({props:{code:`from transformers import AutoTokenizer, TFDebertaForQuestionAnswering
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("kamalkraj/deberta-base")
model = TFDebertaForQuestionAnswering.from_pretrained("kamalkraj/deberta-base")

question, text = "Who was Jim Henson?", "Jim Henson was a nice puppet"

inputs = tokenizer(question, text, return_tensors="tf")
outputs = model(**inputs)

answer_start_index = int(tf.math.argmax(outputs.start_logits, axis=-1)[0])
answer_end_index = int(tf.math.argmax(outputs.end_logits, axis=-1)[0])

predict_answer_tokens = inputs.input_ids[0, answer_start_index : answer_end_index + 1]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFDebertaForQuestionAnswering
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDebertaForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;kamalkraj/deberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>question, text = <span class="hljs-string">&quot;Who was Jim Henson?&quot;</span>, <span class="hljs-string">&quot;Jim Henson was a nice puppet&quot;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(question, text, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>answer_start_index = <span class="hljs-built_in">int</span>(tf.math.argmax(outputs.start_logits, axis=-<span class="hljs-number">1</span>)[<span class="hljs-number">0</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>answer_end_index = <span class="hljs-built_in">int</span>(tf.math.argmax(outputs.end_logits, axis=-<span class="hljs-number">1</span>)[<span class="hljs-number">0</span>])

<span class="hljs-meta">&gt;&gt;&gt; </span>predict_answer_tokens = inputs.input_ids[<span class="hljs-number">0</span>, answer_start_index : answer_end_index + <span class="hljs-number">1</span>]`}}),{c(){d=a("p"),b=n("Example:"),m=c(),v(u.$$.fragment)},l(l){d=r(l,"P",{});var h=i(d);b=s(h,"Example:"),h.forEach(t),m=p(l),T(u.$$.fragment,l)},m(l,h){g(l,d,h),e(d,b),g(l,m,h),y(u,l,h),k=!0},p:Ue,i(l){k||($(u.$$.fragment,l),k=!0)},o(l){D(u.$$.fragment,l),k=!1},d(l){l&&t(d),l&&t(m),E(u,l)}}}function kT(x){let d,b;return d=new Qe({props:{code:`# target is "nice puppet"
target_start_index = tf.constant([14])
target_end_index = tf.constant([15])

outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
loss = tf.math.reduce_mean(outputs.loss)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># target is &quot;nice puppet&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>target_start_index = tf.constant([<span class="hljs-number">14</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>target_end_index = tf.constant([<span class="hljs-number">15</span>])

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(outputs.loss)`}}),{c(){v(d.$$.fragment)},l(m){T(d.$$.fragment,m)},m(m,u){y(d,m,u),b=!0},p:Ue,i(m){b||($(d.$$.fragment,m),b=!0)},o(m){D(d.$$.fragment,m),b=!1},d(m){E(d,m)}}}function wT(x){let d,b,m,u,k,l,h,z,ae,V,L,oe,se,F,ye,G,$e,_e,S,De,de,J,Ee,be,Q,Fe,ke,K,qe,we,ne,M,C,ce,X,xe,ve,B,ze,pe,A,je,W,Me,Ce,H,Ae,Pe,I,re,O,me,Z,P,ue,R,Te,fe,w,q,Be,ie,le,Ie,j,Se,Ke,Ge,Ve,Oe,N,U,Je,Xe,Y,ge,We,Re,Ye,ee,Ze,Vc,os,Jc,Xc,Yc,Bt,yr,Zc,ep,ns,tp,op,ss,np,sp,ap,Ti,$r,rp,Td,as,yd,pt,It,Dr,ip,lp,rs,dp,cp,is,pp,hp,fp,St,Er,mp,up,ls,gp,_p,ds,bp,kp,wp,Fr,cs,vp,Tp,yp,qr,ps,$p,Dp,Ep,yi,xr,Fp,$d,hs,Dd,Tt,Ot,zr,qp,xp,fs,zp,jp,ms,Mp,Cp,Ap,Nt,jr,Pp,Rp,us,Lp,Bp,gs,Ip,Sp,Op,Mr,_s,Np,Wp,Hp,$i,Cr,Up,Ed,bs,Fd,yt,Wt,Ar,Qp,Kp,ks,Gp,Vp,ws,Jp,Xp,Yp,Ht,Pr,Zp,eh,vs,th,oh,Ts,nh,sh,ah,Rr,ys,rh,ih,lh,Di,Lr,dh,qd,io,No,Ei,$s,ch,Fi,ph,xd,_t,Ds,hh,Pt,fh,Br,mh,uh,Ir,gh,_h,Es,bh,kh,wh,lo,vh,Sr,Th,yh,Or,$h,Dh,Eh,Wo,zd,co,Ho,qi,Fs,Fh,xi,qh,jd,he,qs,xh,zi,zh,jh,ji,Mh,Ch,Uo,Ah,xs,Ph,Mi,Rh,Lh,Bh,Qo,Ih,zs,Sh,Nr,Oh,Nh,Wh,Ut,js,Hh,Ci,Uh,Qh,Ms,Ai,Kh,Gh,Pi,Vh,Jh,Ko,Cs,Xh,po,Yh,Ri,Zh,ef,Li,tf,of,nf,$t,As,sf,Bi,af,rf,Go,lf,ho,df,Ii,cf,pf,Si,hf,ff,mf,Wr,Ps,Md,fo,Vo,Oi,Rs,uf,Ni,gf,Cd,Le,Ls,_f,Bs,bf,Wi,kf,wf,vf,Hi,Tf,yf,Jo,$f,Is,Df,Ui,Ef,Ff,qf,Xo,xf,Ss,zf,Hr,jf,Mf,Cf,Qt,Os,Af,Qi,Pf,Rf,Ns,Ki,Lf,Bf,Gi,If,Sf,Dt,Ws,Of,Vi,Nf,Wf,Yo,Hf,mo,Uf,Ji,Qf,Kf,Xi,Gf,Vf,Ad,uo,Zo,Yi,Hs,Jf,Zi,Xf,Pd,bt,Us,Yf,Qs,Zf,Ks,em,tm,om,Gs,nm,Vs,sm,am,rm,Et,Js,im,go,lm,Ur,dm,cm,el,pm,hm,fm,en,mm,tn,Rd,_o,on,tl,Xs,um,ol,gm,Ld,bo,Ys,_m,nl,bm,Bd,ko,nn,sl,Zs,km,al,wm,Id,kt,ea,vm,wo,Tm,rl,ym,$m,ta,Dm,Em,Fm,oa,qm,na,xm,zm,jm,Ft,sa,Mm,vo,Cm,Qr,Am,Pm,il,Rm,Lm,Bm,sn,Im,an,Sd,To,rn,ll,aa,Sm,dl,Om,Od,rt,ra,Nm,cl,Wm,Hm,ia,Um,la,Qm,Km,Gm,da,Vm,ca,Jm,Xm,Ym,ht,pa,Zm,yo,eu,Kr,tu,ou,pl,nu,su,au,ln,ru,dn,iu,cn,Nd,$o,pn,hl,ha,lu,fl,du,Wd,it,fa,cu,ml,pu,hu,ma,fu,ua,mu,uu,gu,ga,_u,_a,bu,ku,wu,qt,ba,vu,Do,Tu,Gr,yu,$u,ul,Du,Eu,Fu,hn,qu,fn,Hd,Eo,mn,gl,ka,xu,_l,zu,Ud,lt,wa,ju,Fo,Mu,bl,Cu,Au,kl,Pu,Ru,Lu,va,Bu,Ta,Iu,Su,Ou,ya,Nu,$a,Wu,Hu,Uu,xt,Da,Qu,qo,Ku,Vr,Gu,Vu,wl,Ju,Xu,Yu,un,Zu,gn,Qd,xo,_n,vl,Ea,eg,Tl,tg,Kd,dt,Fa,og,qa,ng,xa,sg,ag,rg,za,ig,ja,lg,dg,cg,bn,pg,zt,Ma,hg,zo,fg,Jr,mg,ug,yl,gg,_g,bg,kn,kg,wn,Gd,jo,vn,$l,Ca,wg,Dl,vg,Vd,Rt,Aa,Tg,El,yg,$g,jt,Pa,Dg,Fl,Eg,Fg,Ra,qg,ql,xg,zg,jg,wt,Mg,xl,Cg,Ag,zl,Pg,Rg,jl,Lg,Bg,Ml,Ig,Sg,Jd,Mo,Tn,Cl,La,Og,Al,Ng,Xd,ct,Ba,Wg,Co,Hg,Pl,Ug,Qg,Ia,Kg,Gg,Vg,Sa,Jg,Oa,Xg,Yg,Zg,yn,e_,ft,Na,t_,Ao,o_,Xr,n_,s_,Rl,a_,r_,i_,$n,l_,Dn,d_,En,Yd,Po,Fn,Ll,Wa,c_,Bl,p_,Zd,ot,Ha,h_,Il,f_,m_,Ua,u_,Qa,g_,__,b_,Ka,k_,Ga,w_,v_,T_,qn,y_,mt,Va,$_,Ro,D_,Yr,E_,F_,Sl,q_,x_,z_,xn,j_,zn,M_,jn,ec,Lo,Mn,Ol,Ja,C_,Nl,A_,tc,nt,Xa,P_,Wl,R_,L_,Ya,B_,Za,I_,S_,O_,er,N_,tr,W_,H_,U_,Cn,Q_,ut,or,K_,Bo,G_,Zr,V_,J_,Hl,X_,Y_,Z_,An,eb,Pn,tb,Rn,oc,Io,Ln,Ul,nr,ob,Ql,nb,nc,st,sr,sb,So,ab,Kl,rb,ib,Gl,lb,db,cb,ar,pb,rr,hb,fb,mb,ir,ub,lr,gb,_b,bb,Bn,kb,gt,dr,wb,Oo,vb,ei,Tb,yb,Vl,$b,Db,Eb,In,Fb,Sn,qb,On,sc;return l=new tt({}),F=new tt({}),Z=new tt({}),Be=new Gc({props:{pipeline:"text-classification"}}),as=new Gc({props:{pipeline:"token-classification"}}),hs=new Gc({props:{pipeline:"fill-mask"}}),bs=new Gc({props:{pipeline:"question-answering"}}),$s=new tt({}),Ds=new te({props:{name:"class transformers.DebertaConfig",anchor:"transformers.DebertaConfig",parameters:[{name:"vocab_size",val:" = 50265"},{name:"hidden_size",val:" = 768"},{name:"num_hidden_layers",val:" = 12"},{name:"num_attention_heads",val:" = 12"},{name:"intermediate_size",val:" = 3072"},{name:"hidden_act",val:" = 'gelu'"},{name:"hidden_dropout_prob",val:" = 0.1"},{name:"attention_probs_dropout_prob",val:" = 0.1"},{name:"max_position_embeddings",val:" = 512"},{name:"type_vocab_size",val:" = 0"},{name:"initializer_range",val:" = 0.02"},{name:"layer_norm_eps",val:" = 1e-07"},{name:"relative_attention",val:" = False"},{name:"max_relative_positions",val:" = -1"},{name:"pad_token_id",val:" = 0"},{name:"position_biased_input",val:" = True"},{name:"pos_att_type",val:" = None"},{name:"pooler_dropout",val:" = 0"},{name:"pooler_hidden_act",val:" = 'gelu'"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.DebertaConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 30522) &#x2014;
Vocabulary size of the DeBERTa model. Defines the number of different tokens that can be represented by the
<code>inputs_ids</code> passed when calling <a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaModel">DebertaModel</a> or <a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaModel">TFDebertaModel</a>.`,name:"vocab_size"},{anchor:"transformers.DebertaConfig.hidden_size",description:`<strong>hidden_size</strong> (<code>int</code>, <em>optional</em>, defaults to 768) &#x2014;
Dimensionality of the encoder layers and the pooler layer.`,name:"hidden_size"},{anchor:"transformers.DebertaConfig.num_hidden_layers",description:`<strong>num_hidden_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of hidden layers in the Transformer encoder.`,name:"num_hidden_layers"},{anchor:"transformers.DebertaConfig.num_attention_heads",description:`<strong>num_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of attention heads for each attention layer in the Transformer encoder.`,name:"num_attention_heads"},{anchor:"transformers.DebertaConfig.intermediate_size",description:`<strong>intermediate_size</strong> (<code>int</code>, <em>optional</em>, defaults to 3072) &#x2014;
Dimensionality of the &#x201C;intermediate&#x201D; (often named feed-forward) layer in the Transformer encoder.`,name:"intermediate_size"},{anchor:"transformers.DebertaConfig.hidden_act",description:`<strong>hidden_act</strong> (<code>str</code> or <code>Callable</code>, <em>optional</em>, defaults to <code>&quot;gelu&quot;</code>) &#x2014;
The non-linear activation function (function or string) in the encoder and pooler. If string, <code>&quot;gelu&quot;</code>,
<code>&quot;relu&quot;</code>, <code>&quot;silu&quot;</code>, <code>&quot;gelu&quot;</code>, <code>&quot;tanh&quot;</code>, <code>&quot;gelu_fast&quot;</code>, <code>&quot;mish&quot;</code>, <code>&quot;linear&quot;</code>, <code>&quot;sigmoid&quot;</code> and <code>&quot;gelu_new&quot;</code>
are supported.`,name:"hidden_act"},{anchor:"transformers.DebertaConfig.hidden_dropout_prob",description:`<strong>hidden_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout probability for all fully connected layers in the embeddings, encoder, and pooler.`,name:"hidden_dropout_prob"},{anchor:"transformers.DebertaConfig.attention_probs_dropout_prob",description:`<strong>attention_probs_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_probs_dropout_prob"},{anchor:"transformers.DebertaConfig.max_position_embeddings",description:`<strong>max_position_embeddings</strong> (<code>int</code>, <em>optional</em>, defaults to 512) &#x2014;
The maximum sequence length that this model might ever be used with. Typically set this to something large
just in case (e.g., 512 or 1024 or 2048).`,name:"max_position_embeddings"},{anchor:"transformers.DebertaConfig.type_vocab_size",description:`<strong>type_vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 2) &#x2014;
The vocabulary size of the <code>token_type_ids</code> passed when calling <a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaModel">DebertaModel</a> or <a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaModel">TFDebertaModel</a>.`,name:"type_vocab_size"},{anchor:"transformers.DebertaConfig.initializer_range",description:`<strong>initializer_range</strong> (<code>float</code>, <em>optional</em>, defaults to 0.02) &#x2014;
The standard deviation of the truncated_normal_initializer for initializing all weight matrices.`,name:"initializer_range"},{anchor:"transformers.DebertaConfig.layer_norm_eps",description:`<strong>layer_norm_eps</strong> (<code>float</code>, <em>optional</em>, defaults to 1e-12) &#x2014;
The epsilon used by the layer normalization layers.`,name:"layer_norm_eps"},{anchor:"transformers.DebertaConfig.relative_attention",description:`<strong>relative_attention</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether use relative position encoding.`,name:"relative_attention"},{anchor:"transformers.DebertaConfig.max_relative_positions",description:`<strong>max_relative_positions</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
The range of relative positions <code>[-max_position_embeddings, max_position_embeddings]</code>. Use the same value
as <code>max_position_embeddings</code>.`,name:"max_relative_positions"},{anchor:"transformers.DebertaConfig.pad_token_id",description:`<strong>pad_token_id</strong> (<code>int</code>, <em>optional</em>, defaults to 0) &#x2014;
The value used to pad input_ids.`,name:"pad_token_id"},{anchor:"transformers.DebertaConfig.position_biased_input",description:`<strong>position_biased_input</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether add absolute position embedding to content embedding.`,name:"position_biased_input"},{anchor:"transformers.DebertaConfig.pos_att_type",description:`<strong>pos_att_type</strong> (<code>List[str]</code>, <em>optional</em>) &#x2014;
The type of relative position attention, it can be a combination of <code>[&quot;p2c&quot;, &quot;c2p&quot;]</code>, e.g. <code>[&quot;p2c&quot;]</code>,
<code>[&quot;p2c&quot;, &quot;c2p&quot;]</code>.`,name:"pos_att_type"},{anchor:"transformers.DebertaConfig.layer_norm_eps",description:`<strong>layer_norm_eps</strong> (<code>float</code>, optional, defaults to 1e-12) &#x2014;
The epsilon used by the layer normalization layers.`,name:"layer_norm_eps"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/configuration_deberta.py#L40"}}),Wo=new He({props:{anchor:"transformers.DebertaConfig.example",$$slots:{default:[Lv]},$$scope:{ctx:x}}}),Fs=new tt({}),qs=new te({props:{name:"class transformers.DebertaTokenizer",anchor:"transformers.DebertaTokenizer",parameters:[{name:"vocab_file",val:""},{name:"merges_file",val:""},{name:"errors",val:" = 'replace'"},{name:"bos_token",val:" = '[CLS]'"},{name:"eos_token",val:" = '[SEP]'"},{name:"sep_token",val:" = '[SEP]'"},{name:"cls_token",val:" = '[CLS]'"},{name:"unk_token",val:" = '[UNK]'"},{name:"pad_token",val:" = '[PAD]'"},{name:"mask_token",val:" = '[MASK]'"},{name:"add_prefix_space",val:" = False"},{name:"add_bos_token",val:" = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.DebertaTokenizer.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
Path to the vocabulary file.`,name:"vocab_file"},{anchor:"transformers.DebertaTokenizer.merges_file",description:`<strong>merges_file</strong> (<code>str</code>) &#x2014;
Path to the merges file.`,name:"merges_file"},{anchor:"transformers.DebertaTokenizer.errors",description:`<strong>errors</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;replace&quot;</code>) &#x2014;
Paradigm to follow when decoding bytes to UTF-8. See
<a href="https://docs.python.org/3/library/stdtypes.html#bytes.decode" rel="nofollow">bytes.decode</a> for more information.`,name:"errors"},{anchor:"transformers.DebertaTokenizer.bos_token",description:`<strong>bos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
The beginning of sequence token.`,name:"bos_token"},{anchor:"transformers.DebertaTokenizer.eos_token",description:`<strong>eos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
The end of sequence token.`,name:"eos_token"},{anchor:"transformers.DebertaTokenizer.sep_token",description:`<strong>sep_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
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.`,name:"sep_token"},{anchor:"transformers.DebertaTokenizer.cls_token",description:`<strong>cls_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
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.`,name:"cls_token"},{anchor:"transformers.DebertaTokenizer.unk_token",description:`<strong>unk_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[UNK]&quot;</code>) &#x2014;
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.`,name:"unk_token"},{anchor:"transformers.DebertaTokenizer.pad_token",description:`<strong>pad_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[PAD]&quot;</code>) &#x2014;
The token used for padding, for example when batching sequences of different lengths.`,name:"pad_token"},{anchor:"transformers.DebertaTokenizer.mask_token",description:`<strong>mask_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[MASK]&quot;</code>) &#x2014;
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.`,name:"mask_token"},{anchor:"transformers.DebertaTokenizer.add_prefix_space",description:`<strong>add_prefix_space</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to add an initial space to the input. This allows to treat the leading word just as any
other word. (Deberta tokenizer detect beginning of words by the preceding space).`,name:"add_prefix_space"},{anchor:"transformers.DebertaTokenizer.add_bos_token",description:`<strong>add_bos_token</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to add an initial &lt;|endoftext|&gt; to the input. This allows to treat the leading word just as
any other word.`,name:"add_bos_token"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta.py#L112"}}),Uo=new He({props:{anchor:"transformers.DebertaTokenizer.example",$$slots:{default:[Bv]},$$scope:{ctx:x}}}),Qo=new at({props:{$$slots:{default:[Iv]},$$scope:{ctx:x}}}),js=new te({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.DebertaTokenizer.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.DebertaTokenizer.build_inputs_with_special_tokens.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs to which the special tokens will be added.`,name:"token_ids_0"},{anchor:"transformers.DebertaTokenizer.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta.py#L291",returnDescription:`
<p>List of <a href="../glossary#input-ids">input IDs</a> with the appropriate special tokens.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),Cs=new te({props:{name:"get_special_tokens_mask",anchor:"transformers.DebertaTokenizer.get_special_tokens_mask",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"},{name:"already_has_special_tokens",val:": bool = False"}],parametersDescription:[{anchor:"transformers.DebertaTokenizer.get_special_tokens_mask.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.DebertaTokenizer.get_special_tokens_mask.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"},{anchor:"transformers.DebertaTokenizer.get_special_tokens_mask.already_has_special_tokens",description:`<strong>already_has_special_tokens</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the token list is already formatted with special tokens for the model.`,name:"already_has_special_tokens"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta.py#L316",returnDescription:`
<p>A list of integers in the range [0, 1]: 1 for a special token, 0 for a sequence token.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),As=new te({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.DebertaTokenizer.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.DebertaTokenizer.create_token_type_ids_from_sequences.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.DebertaTokenizer.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta.py#L343",returnDescription:`
<p>List of <a href="../glossary#token-type-ids">token type IDs</a> according to the given sequence(s).</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),Go=new He({props:{anchor:"transformers.DebertaTokenizer.create_token_type_ids_from_sequences.example",$$slots:{default:[Sv]},$$scope:{ctx:x}}}),Ps=new te({props:{name:"save_vocabulary",anchor:"transformers.DebertaTokenizer.save_vocabulary",parameters:[{name:"save_directory",val:": str"},{name:"filename_prefix",val:": typing.Optional[str] = None"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta.py#L402"}}),Rs=new tt({}),Ls=new te({props:{name:"class transformers.DebertaTokenizerFast",anchor:"transformers.DebertaTokenizerFast",parameters:[{name:"vocab_file",val:" = None"},{name:"merges_file",val:" = None"},{name:"tokenizer_file",val:" = None"},{name:"errors",val:" = 'replace'"},{name:"bos_token",val:" = '[CLS]'"},{name:"eos_token",val:" = '[SEP]'"},{name:"sep_token",val:" = '[SEP]'"},{name:"cls_token",val:" = '[CLS]'"},{name:"unk_token",val:" = '[UNK]'"},{name:"pad_token",val:" = '[PAD]'"},{name:"mask_token",val:" = '[MASK]'"},{name:"add_prefix_space",val:" = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.DebertaTokenizerFast.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
Path to the vocabulary file.`,name:"vocab_file"},{anchor:"transformers.DebertaTokenizerFast.merges_file",description:`<strong>merges_file</strong> (<code>str</code>) &#x2014;
Path to the merges file.`,name:"merges_file"},{anchor:"transformers.DebertaTokenizerFast.tokenizer_file",description:`<strong>tokenizer_file</strong> (<code>str</code>, <em>optional</em>) &#x2014;
The path to a tokenizer file to use instead of the vocab file.`,name:"tokenizer_file"},{anchor:"transformers.DebertaTokenizerFast.errors",description:`<strong>errors</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;replace&quot;</code>) &#x2014;
Paradigm to follow when decoding bytes to UTF-8. See
<a href="https://docs.python.org/3/library/stdtypes.html#bytes.decode" rel="nofollow">bytes.decode</a> for more information.`,name:"errors"},{anchor:"transformers.DebertaTokenizerFast.bos_token",description:`<strong>bos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
The beginning of sequence token.`,name:"bos_token"},{anchor:"transformers.DebertaTokenizerFast.eos_token",description:`<strong>eos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
The end of sequence token.`,name:"eos_token"},{anchor:"transformers.DebertaTokenizerFast.sep_token",description:`<strong>sep_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
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.`,name:"sep_token"},{anchor:"transformers.DebertaTokenizerFast.cls_token",description:`<strong>cls_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
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.`,name:"cls_token"},{anchor:"transformers.DebertaTokenizerFast.unk_token",description:`<strong>unk_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[UNK]&quot;</code>) &#x2014;
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.`,name:"unk_token"},{anchor:"transformers.DebertaTokenizerFast.pad_token",description:`<strong>pad_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[PAD]&quot;</code>) &#x2014;
The token used for padding, for example when batching sequences of different lengths.`,name:"pad_token"},{anchor:"transformers.DebertaTokenizerFast.mask_token",description:`<strong>mask_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[MASK]&quot;</code>) &#x2014;
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.`,name:"mask_token"},{anchor:"transformers.DebertaTokenizerFast.add_prefix_space",description:`<strong>add_prefix_space</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to add an initial space to the input. This allows to treat the leading word just as any
other word. (Deberta tokenizer detect beginning of words by the preceding space).`,name:"add_prefix_space"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta_fast.py#L74"}}),Jo=new He({props:{anchor:"transformers.DebertaTokenizerFast.example",$$slots:{default:[Ov]},$$scope:{ctx:x}}}),Xo=new at({props:{$$slots:{default:[Nv]},$$scope:{ctx:x}}}),Os=new te({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.DebertaTokenizerFast.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.DebertaTokenizerFast.build_inputs_with_special_tokens.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs to which the special tokens will be added.`,name:"token_ids_0"},{anchor:"transformers.DebertaTokenizerFast.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta_fast.py#L211",returnDescription:`
<p>List of <a href="../glossary#input-ids">input IDs</a> with the appropriate special tokens.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),Ws=new te({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.DebertaTokenizerFast.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.DebertaTokenizerFast.create_token_type_ids_from_sequences.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.DebertaTokenizerFast.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/tokenization_deberta_fast.py#L236",returnDescription:`
<p>List of <a href="../glossary#token-type-ids">token type IDs</a> according to the given sequence(s).</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),Yo=new He({props:{anchor:"transformers.DebertaTokenizerFast.create_token_type_ids_from_sequences.example",$$slots:{default:[Wv]},$$scope:{ctx:x}}}),Hs=new tt({}),Us=new te({props:{name:"class transformers.DebertaModel",anchor:"transformers.DebertaModel",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.DebertaModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L912"}}),Js=new te({props:{name:"forward",anchor:"transformers.DebertaModel.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.DebertaModel.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.DebertaModel.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.DebertaModel.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.DebertaModel.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.DebertaModel.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DebertaModel.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.DebertaModel.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.DebertaModel.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L936",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutput"
>transformers.modeling_outputs.BaseModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutput"
>transformers.modeling_outputs.BaseModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),en=new at({props:{$$slots:{default:[Hv]},$$scope:{ctx:x}}}),tn=new He({props:{anchor:"transformers.DebertaModel.forward.example",$$slots:{default:[Uv]},$$scope:{ctx:x}}}),Xs=new tt({}),Ys=new te({props:{name:"class transformers.DebertaPreTrainedModel",anchor:"transformers.DebertaPreTrainedModel",parameters:[{name:"config",val:": PretrainedConfig"},{name:"*inputs",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L817"}}),Zs=new tt({}),ea=new te({props:{name:"class transformers.DebertaForMaskedLM",anchor:"transformers.DebertaForMaskedLM",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.DebertaForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1023"}}),sa=new te({props:{name:"forward",anchor:"transformers.DebertaForMaskedLM.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.DebertaForMaskedLM.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.DebertaForMaskedLM.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.DebertaForMaskedLM.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.DebertaForMaskedLM.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.DebertaForMaskedLM.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DebertaForMaskedLM.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.DebertaForMaskedLM.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.DebertaForMaskedLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DebertaForMaskedLM.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the masked language modeling loss. Indices should be in <code>[-100, 0, ..., config.vocab_size]</code> (see <code>input_ids</code> docstring) Tokens with indices set to <code>-100</code> are ignored (masked), the
loss is only computed for the tokens with labels in <code>[0, ..., config.vocab_size]</code>`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1042",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),sn=new at({props:{$$slots:{default:[Qv]},$$scope:{ctx:x}}}),an=new He({props:{anchor:"transformers.DebertaForMaskedLM.forward.example",$$slots:{default:[Kv]},$$scope:{ctx:x}}}),aa=new tt({}),ra=new te({props:{name:"class transformers.DebertaForSequenceClassification",anchor:"transformers.DebertaForSequenceClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.DebertaForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1160"}}),pa=new te({props:{name:"forward",anchor:"transformers.DebertaForSequenceClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.DebertaForSequenceClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.DebertaForSequenceClassification.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.DebertaForSequenceClassification.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.DebertaForSequenceClassification.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.DebertaForSequenceClassification.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DebertaForSequenceClassification.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.DebertaForSequenceClassification.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.DebertaForSequenceClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DebertaForSequenceClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1185",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ln=new at({props:{$$slots:{default:[Gv]},$$scope:{ctx:x}}}),dn=new He({props:{anchor:"transformers.DebertaForSequenceClassification.forward.example",$$slots:{default:[Vv]},$$scope:{ctx:x}}}),cn=new He({props:{anchor:"transformers.DebertaForSequenceClassification.forward.example-2",$$slots:{default:[Jv]},$$scope:{ctx:x}}}),ha=new tt({}),fa=new te({props:{name:"class transformers.DebertaForTokenClassification",anchor:"transformers.DebertaForTokenClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.DebertaForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1278"}}),ba=new te({props:{name:"forward",anchor:"transformers.DebertaForTokenClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.DebertaForTokenClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.DebertaForTokenClassification.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.DebertaForTokenClassification.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.DebertaForTokenClassification.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.DebertaForTokenClassification.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DebertaForTokenClassification.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.DebertaForTokenClassification.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.DebertaForTokenClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DebertaForTokenClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1292",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),hn=new at({props:{$$slots:{default:[Xv]},$$scope:{ctx:x}}}),fn=new He({props:{anchor:"transformers.DebertaForTokenClassification.forward.example",$$slots:{default:[Yv]},$$scope:{ctx:x}}}),ka=new tt({}),wa=new te({props:{name:"class transformers.DebertaForQuestionAnswering",anchor:"transformers.DebertaForQuestionAnswering",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.DebertaForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1353"}}),Da=new te({props:{name:"forward",anchor:"transformers.DebertaForQuestionAnswering.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"start_positions",val:": typing.Optional[torch.Tensor] = None"},{name:"end_positions",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.DebertaForQuestionAnswering.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.DebertaForQuestionAnswering.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.DebertaForQuestionAnswering.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.DebertaForQuestionAnswering.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.DebertaForQuestionAnswering.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DebertaForQuestionAnswering.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.DebertaForQuestionAnswering.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.DebertaForQuestionAnswering.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DebertaForQuestionAnswering.forward.start_positions",description:`<strong>start_positions</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the start of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"start_positions"},{anchor:"transformers.DebertaForQuestionAnswering.forward.end_positions",description:`<strong>end_positions</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the end of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"end_positions"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_deberta.py#L1366",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Total span extraction loss is the sum of a Cross-Entropy for the start and end positions.</p>
</li>
<li>
<p><strong>start_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),un=new at({props:{$$slots:{default:[Zv]},$$scope:{ctx:x}}}),gn=new He({props:{anchor:"transformers.DebertaForQuestionAnswering.forward.example",$$slots:{default:[eT]},$$scope:{ctx:x}}}),Ea=new tt({}),Fa=new te({props:{name:"class transformers.TFDebertaModel",anchor:"transformers.TFDebertaModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDebertaModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1089"}}),bn=new at({props:{$$slots:{default:[tT]},$$scope:{ctx:x}}}),Ma=new te({props:{name:"call",anchor:"transformers.TFDebertaModel.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFDebertaModel.call.input_ids",description:`<strong>input_ids</strong> (<code>np.ndarray</code>, <code>tf.Tensor</code>, <code>List[tf.Tensor]</code> \`<code>Dict[str, tf.Tensor]</code> or <code>Dict[str, np.ndarray]</code> and each example must have the shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDebertaModel.call.attention_mask",description:`<strong>attention_mask</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFDebertaModel.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFDebertaModel.call.position_ids",description:`<strong>position_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFDebertaModel.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDebertaModel.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFDebertaModel.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFDebertaModel.call.return_dict",description:"<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;\nWhether or not to return a [`~utils.ModelOutput&#x201C;] instead of a plain tuple.",name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1095",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutput"
>transformers.modeling_tf_outputs.TFBaseModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutput"
>transformers.modeling_tf_outputs.TFBaseModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),kn=new at({props:{$$slots:{default:[oT]},$$scope:{ctx:x}}}),wn=new He({props:{anchor:"transformers.TFDebertaModel.call.example",$$slots:{default:[nT]},$$scope:{ctx:x}}}),Ca=new tt({}),Aa=new te({props:{name:"class transformers.TFDebertaPreTrainedModel",anchor:"transformers.TFDebertaPreTrainedModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L989"}}),Pa=new te({props:{name:"call",anchor:"transformers.TFDebertaPreTrainedModel.call",parameters:[{name:"inputs",val:""},{name:"training",val:" = None"},{name:"mask",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/keras/engine/training.py#L563",returnDescription:`
<p>A tensor if there is a single output, or
a list of tensors if there are more than one outputs.</p>
`}}),La=new tt({}),Ba=new te({props:{name:"class transformers.TFDebertaForMaskedLM",anchor:"transformers.TFDebertaForMaskedLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDebertaForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1136"}}),yn=new at({props:{$$slots:{default:[sT]},$$scope:{ctx:x}}}),Na=new te({props:{name:"call",anchor:"transformers.TFDebertaForMaskedLM.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFDebertaForMaskedLM.call.input_ids",description:`<strong>input_ids</strong> (<code>np.ndarray</code>, <code>tf.Tensor</code>, <code>List[tf.Tensor]</code> \`<code>Dict[str, tf.Tensor]</code> or <code>Dict[str, np.ndarray]</code> and each example must have the shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDebertaForMaskedLM.call.attention_mask",description:`<strong>attention_mask</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFDebertaForMaskedLM.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFDebertaForMaskedLM.call.position_ids",description:`<strong>position_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFDebertaForMaskedLM.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDebertaForMaskedLM.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFDebertaForMaskedLM.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFDebertaForMaskedLM.call.return_dict",description:"<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;\nWhether or not to return a [`~utils.ModelOutput&#x201C;] instead of a plain tuple.",name:"return_dict"},{anchor:"transformers.TFDebertaForMaskedLM.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> or <code>np.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the masked language modeling loss. Indices should be in <code>[-100, 0, ..., config.vocab_size]</code> (see <code>input_ids</code> docstring) Tokens with indices set to <code>-100</code> are ignored (masked), the
loss is only computed for the tokens with labels in <code>[0, ..., config.vocab_size]</code>`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1152",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of non-masked labels, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),$n=new at({props:{$$slots:{default:[aT]},$$scope:{ctx:x}}}),Dn=new He({props:{anchor:"transformers.TFDebertaForMaskedLM.call.example",$$slots:{default:[rT]},$$scope:{ctx:x}}}),En=new He({props:{anchor:"transformers.TFDebertaForMaskedLM.call.example-2",$$slots:{default:[iT]},$$scope:{ctx:x}}}),Wa=new tt({}),Ha=new te({props:{name:"class transformers.TFDebertaForSequenceClassification",anchor:"transformers.TFDebertaForSequenceClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDebertaForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1218"}}),qn=new at({props:{$$slots:{default:[lT]},$$scope:{ctx:x}}}),Va=new te({props:{name:"call",anchor:"transformers.TFDebertaForSequenceClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFDebertaForSequenceClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>np.ndarray</code>, <code>tf.Tensor</code>, <code>List[tf.Tensor]</code> \`<code>Dict[str, tf.Tensor]</code> or <code>Dict[str, np.ndarray]</code> and each example must have the shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDebertaForSequenceClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFDebertaForSequenceClassification.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFDebertaForSequenceClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFDebertaForSequenceClassification.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDebertaForSequenceClassification.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFDebertaForSequenceClassification.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFDebertaForSequenceClassification.call.return_dict",description:"<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;\nWhether or not to return a [`~utils.ModelOutput&#x201C;] instead of a plain tuple.",name:"return_dict"},{anchor:"transformers.TFDebertaForSequenceClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> or <code>np.ndarray</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1236",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, )</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),xn=new at({props:{$$slots:{default:[dT]},$$scope:{ctx:x}}}),zn=new He({props:{anchor:"transformers.TFDebertaForSequenceClassification.call.example",$$slots:{default:[cT]},$$scope:{ctx:x}}}),jn=new He({props:{anchor:"transformers.TFDebertaForSequenceClassification.call.example-2",$$slots:{default:[pT]},$$scope:{ctx:x}}}),Ja=new tt({}),Xa=new te({props:{name:"class transformers.TFDebertaForTokenClassification",anchor:"transformers.TFDebertaForTokenClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDebertaForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1305"}}),Cn=new at({props:{$$slots:{default:[hT]},$$scope:{ctx:x}}}),or=new te({props:{name:"call",anchor:"transformers.TFDebertaForTokenClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFDebertaForTokenClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>np.ndarray</code>, <code>tf.Tensor</code>, <code>List[tf.Tensor]</code> \`<code>Dict[str, tf.Tensor]</code> or <code>Dict[str, np.ndarray]</code> and each example must have the shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDebertaForTokenClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFDebertaForTokenClassification.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFDebertaForTokenClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFDebertaForTokenClassification.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDebertaForTokenClassification.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFDebertaForTokenClassification.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFDebertaForTokenClassification.call.return_dict",description:"<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;\nWhether or not to return a [`~utils.ModelOutput&#x201C;] instead of a plain tuple.",name:"return_dict"},{anchor:"transformers.TFDebertaForTokenClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> or <code>np.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1317",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of unmasked labels, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),An=new at({props:{$$slots:{default:[fT]},$$scope:{ctx:x}}}),Pn=new He({props:{anchor:"transformers.TFDebertaForTokenClassification.call.example",$$slots:{default:[mT]},$$scope:{ctx:x}}}),Rn=new He({props:{anchor:"transformers.TFDebertaForTokenClassification.call.example-2",$$slots:{default:[uT]},$$scope:{ctx:x}}}),nr=new tt({}),sr=new te({props:{name:"class transformers.TFDebertaForQuestionAnswering",anchor:"transformers.TFDebertaForQuestionAnswering",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDebertaForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig">DebertaConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1382"}}),Bn=new at({props:{$$slots:{default:[gT]},$$scope:{ctx:x}}}),dr=new te({props:{name:"call",anchor:"transformers.TFDebertaForQuestionAnswering.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"start_positions",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"end_positions",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFDebertaForQuestionAnswering.call.input_ids",description:`<strong>input_ids</strong> (<code>np.ndarray</code>, <code>tf.Tensor</code>, <code>List[tf.Tensor]</code> \`<code>Dict[str, tf.Tensor]</code> or <code>Dict[str, np.ndarray]</code> and each example must have the shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.attention_mask",description:`<strong>attention_mask</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.position_ids",description:`<strong>position_ids</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>np.ndarray</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <em>input_ids</em> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.return_dict",description:"<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;\nWhether or not to return a [`~utils.ModelOutput&#x201C;] instead of a plain tuple.",name:"return_dict"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.start_positions",description:`<strong>start_positions</strong> (<code>tf.Tensor</code> or <code>np.ndarray</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the start of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"start_positions"},{anchor:"transformers.TFDebertaForQuestionAnswering.call.end_positions",description:`<strong>end_positions</strong> (<code>tf.Tensor</code> or <code>np.ndarray</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the end of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"end_positions"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/deberta/modeling_tf_deberta.py#L1393",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaConfig"
>DebertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, )</code>, <em>optional</em>, returned when <code>start_positions</code> and <code>end_positions</code> are provided) \u2014 Total span extraction loss is the sum of a Cross-Entropy for the start and end positions.</p>
</li>
<li>
<p><strong>start_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),In=new at({props:{$$slots:{default:[_T]},$$scope:{ctx:x}}}),Sn=new He({props:{anchor:"transformers.TFDebertaForQuestionAnswering.call.example",$$slots:{default:[bT]},$$scope:{ctx:x}}}),On=new He({props:{anchor:"transformers.TFDebertaForQuestionAnswering.call.example-2",$$slots:{default:[kT]},$$scope:{ctx:x}}}),{c(){d=a("meta"),b=c(),m=a("h1"),u=a("a"),k=a("span"),v(l.$$.fragment),h=c(),z=a("span"),ae=n("DeBERTa"),V=c(),L=a("h2"),oe=a("a"),se=a("span"),v(F.$$.fragment),ye=c(),G=a("span"),$e=n("Overview"),_e=c(),S=a("p"),De=n("The DeBERTa model was proposed in "),de=a("a"),J=n("DeBERTa: Decoding-enhanced BERT with Disentangled Attention"),Ee=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen It is based on Google\u2019s
BERT model released in 2018 and Facebook\u2019s RoBERTa model released in 2019.`),be=c(),Q=a("p"),Fe=n(`It builds on RoBERTa with disentangled attention and enhanced mask decoder training with half of the data used in
RoBERTa.`),ke=c(),K=a("p"),qe=n("The abstract from the paper is the following:"),we=c(),ne=a("p"),M=a("em"),C=n(`Recent progress in pre-trained neural language models has significantly improved the performance of many natural
language processing (NLP) tasks. In this paper we propose a new model architecture DeBERTa (Decoding-enhanced BERT with
disentangled attention) that improves the BERT and RoBERTa models using two novel techniques. The first is the
disentangled attention mechanism, where each word is represented using two vectors that encode its content and
position, respectively, and the attention weights among words are computed using disentangled matrices on their
contents and relative positions. Second, an enhanced mask decoder is used to replace the output softmax layer to
predict the masked tokens for model pretraining. We show that these two techniques significantly improve the efficiency
of model pretraining and performance of downstream tasks. Compared to RoBERTa-Large, a DeBERTa model trained on half of
the training data performs consistently better on a wide range of NLP tasks, achieving improvements on MNLI by +0.9%
(90.2% vs. 91.1%), on SQuAD v2.0 by +2.3% (88.4% vs. 90.7%) and RACE by +3.6% (83.2% vs. 86.8%). The DeBERTa code and
pre-trained models will be made publicly available at `),ce=a("a"),X=n("https://github.com/microsoft/DeBERTa"),xe=n("."),ve=c(),B=a("p"),ze=n("This model was contributed by "),pe=a("a"),A=n("DeBERTa"),je=n(`. This model TF 2.0 implementation was
contributed by `),W=a("a"),Me=n("kamalkraj"),Ce=n(" . The original code can be found "),H=a("a"),Ae=n("here"),Pe=n("."),I=c(),re=a("h2"),O=a("a"),me=a("span"),v(Z.$$.fragment),P=c(),ue=a("span"),R=n("Resources"),Te=c(),fe=a("p"),w=n("A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with DeBERTa. If you\u2019re interested in submitting a resource to be included here, please feel free to open a Pull Request and we\u2019ll review it! The resource should ideally demonstrate something new instead of duplicating an existing resource."),q=c(),v(Be.$$.fragment),ie=c(),le=a("ul"),Ie=a("li"),j=n("A blog post on how to "),Se=a("a"),Ke=n("Accelerate Large Model Training using DeepSpeed"),Ge=n(" with DeBERTa."),Ve=c(),Oe=a("li"),N=n("A blog post on "),U=a("a"),Je=n("Supercharged Customer Service with Machine Learning"),Xe=n(" with DeBERTa."),Y=c(),ge=a("li"),We=a("a"),Re=n("DebertaForSequenceClassification"),Ye=n(" is supported by this "),ee=a("a"),Ze=n("example script"),Vc=n(" and "),os=a("a"),Jc=n("notebook"),Xc=n("."),Yc=c(),Bt=a("li"),yr=a("a"),Zc=n("TFDebertaForSequenceClassification"),ep=n(" is supported by this "),ns=a("a"),tp=n("example script"),op=n(" and "),ss=a("a"),np=n("notebook"),sp=n("."),ap=c(),Ti=a("li"),$r=a("a"),rp=n("Text classification task guide"),Td=c(),v(as.$$.fragment),yd=c(),pt=a("ul"),It=a("li"),Dr=a("a"),ip=n("DebertaForTokenClassification"),lp=n(" is supported by this "),rs=a("a"),dp=n("example script"),cp=n(" and "),is=a("a"),pp=n("notebook"),hp=n("."),fp=c(),St=a("li"),Er=a("a"),mp=n("TFDebertaForTokenClassification"),up=n(" is supported by this "),ls=a("a"),gp=n("example script"),_p=n(" and "),ds=a("a"),bp=n("notebook"),kp=n("."),wp=c(),Fr=a("li"),cs=a("a"),vp=n("Token classification"),Tp=n(" chapter of the \u{1F917} Hugging Face Course."),yp=c(),qr=a("li"),ps=a("a"),$p=n("Byte-Pair Encoding tokenization"),Dp=n(" chapter of the \u{1F917} Hugging Face Course."),Ep=c(),yi=a("li"),xr=a("a"),Fp=n("Token classification task guide"),$d=c(),v(hs.$$.fragment),Dd=c(),Tt=a("ul"),Ot=a("li"),zr=a("a"),qp=n("DebertaForMaskedLM"),xp=n(" is supported by this "),fs=a("a"),zp=n("example script"),jp=n(" and "),ms=a("a"),Mp=n("notebook"),Cp=n("."),Ap=c(),Nt=a("li"),jr=a("a"),Pp=n("TFDebertaForMaskedLM"),Rp=n(" is supported by this "),us=a("a"),Lp=n("example script"),Bp=n(" and "),gs=a("a"),Ip=n("notebook"),Sp=n("."),Op=c(),Mr=a("li"),_s=a("a"),Np=n("Masked language modeling"),Wp=n(" chapter of the \u{1F917} Hugging Face Course."),Hp=c(),$i=a("li"),Cr=a("a"),Up=n("Masked language modeling task guide"),Ed=c(),v(bs.$$.fragment),Fd=c(),yt=a("ul"),Wt=a("li"),Ar=a("a"),Qp=n("DebertaForQuestionAnswering"),Kp=n(" is supported by this "),ks=a("a"),Gp=n("example script"),Vp=n(" and "),ws=a("a"),Jp=n("notebook"),Xp=n("."),Yp=c(),Ht=a("li"),Pr=a("a"),Zp=n("TFDebertaForQuestionAnswering"),eh=n(" is supported by this "),vs=a("a"),th=n("example script"),oh=n(" and "),Ts=a("a"),nh=n("notebook"),sh=n("."),ah=c(),Rr=a("li"),ys=a("a"),rh=n("Question answering"),ih=n(" chapter of the \u{1F917} Hugging Face Course."),lh=c(),Di=a("li"),Lr=a("a"),dh=n("Question answering task guide"),qd=c(),io=a("h2"),No=a("a"),Ei=a("span"),v($s.$$.fragment),ch=c(),Fi=a("span"),ph=n("DebertaConfig"),xd=c(),_t=a("div"),v(Ds.$$.fragment),hh=c(),Pt=a("p"),fh=n("This is the configuration class to store the configuration of a "),Br=a("a"),mh=n("DebertaModel"),uh=n(" or a "),Ir=a("a"),gh=n("TFDebertaModel"),_h=n(`. It is
used to instantiate a DeBERTa model according to the specified arguments, defining the model architecture.
Instantiating a configuration with the defaults will yield a similar configuration to that of the DeBERTa
`),Es=a("a"),bh=n("microsoft/deberta-base"),kh=n(" architecture."),wh=c(),lo=a("p"),vh=n("Configuration objects inherit from "),Sr=a("a"),Th=n("PretrainedConfig"),yh=n(` and can be used to control the model outputs. Read the
documentation from `),Or=a("a"),$h=n("PretrainedConfig"),Dh=n(" for more information."),Eh=c(),v(Wo.$$.fragment),zd=c(),co=a("h2"),Ho=a("a"),qi=a("span"),v(Fs.$$.fragment),Fh=c(),xi=a("span"),qh=n("DebertaTokenizer"),jd=c(),he=a("div"),v(qs.$$.fragment),xh=c(),zi=a("p"),zh=n("Construct a DeBERTa tokenizer. Based on byte-level Byte-Pair-Encoding."),jh=c(),ji=a("p"),Mh=n("This tokenizer has been trained to treat spaces like parts of the tokens (a bit like sentencepiece) so a word will"),Ch=c(),v(Uo.$$.fragment),Ah=c(),xs=a("p"),Ph=n("You can get around that behavior by passing "),Mi=a("code"),Rh=n("add_prefix_space=True"),Lh=n(` when instantiating this tokenizer or when you
call it on some text, but since the model was not pretrained this way, it might yield a decrease in performance.`),Bh=c(),v(Qo.$$.fragment),Ih=c(),zs=a("p"),Sh=n("This tokenizer inherits from "),Nr=a("a"),Oh=n("PreTrainedTokenizer"),Nh=n(` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Wh=c(),Ut=a("div"),v(js.$$.fragment),Hh=c(),Ci=a("p"),Uh=n(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A DeBERTa sequence has the following format:`),Qh=c(),Ms=a("ul"),Ai=a("li"),Kh=n("single sequence: [CLS] X [SEP]"),Gh=c(),Pi=a("li"),Vh=n("pair of sequences: [CLS] A [SEP] B [SEP]"),Jh=c(),Ko=a("div"),v(Cs.$$.fragment),Xh=c(),po=a("p"),Yh=n(`Retrieves sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),Ri=a("code"),Zh=n("prepare_for_model"),ef=n(" or "),Li=a("code"),tf=n("encode_plus"),of=n(" methods."),nf=c(),$t=a("div"),v(As.$$.fragment),sf=c(),Bi=a("p"),af=n("Create a mask from the two sequences passed to be used in a sequence-pair classification task. A DeBERTa"),rf=c(),v(Go.$$.fragment),lf=c(),ho=a("p"),df=n("If "),Ii=a("code"),cf=n("token_ids_1"),pf=n(" is "),Si=a("code"),hf=n("None"),ff=n(", this method only returns the first portion of the mask (0s)."),mf=c(),Wr=a("div"),v(Ps.$$.fragment),Md=c(),fo=a("h2"),Vo=a("a"),Oi=a("span"),v(Rs.$$.fragment),uf=c(),Ni=a("span"),gf=n("DebertaTokenizerFast"),Cd=c(),Le=a("div"),v(Ls.$$.fragment),_f=c(),Bs=a("p"),bf=n("Construct a \u201Cfast\u201D DeBERTa tokenizer (backed by HuggingFace\u2019s "),Wi=a("em"),kf=n("tokenizers"),wf=n(` library). Based on byte-level
Byte-Pair-Encoding.`),vf=c(),Hi=a("p"),Tf=n("This tokenizer has been trained to treat spaces like parts of the tokens (a bit like sentencepiece) so a word will"),yf=c(),v(Jo.$$.fragment),$f=c(),Is=a("p"),Df=n("You can get around that behavior by passing "),Ui=a("code"),Ef=n("add_prefix_space=True"),Ff=n(` when instantiating this tokenizer, but since
the model was not pretrained this way, it might yield a decrease in performance.`),qf=c(),v(Xo.$$.fragment),xf=c(),Ss=a("p"),zf=n("This tokenizer inherits from "),Hr=a("a"),jf=n("PreTrainedTokenizerFast"),Mf=n(` which contains most of the main methods. Users should
refer to this superclass for more information regarding those methods.`),Cf=c(),Qt=a("div"),v(Os.$$.fragment),Af=c(),Qi=a("p"),Pf=n(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A DeBERTa sequence has the following format:`),Rf=c(),Ns=a("ul"),Ki=a("li"),Lf=n("single sequence: [CLS] X [SEP]"),Bf=c(),Gi=a("li"),If=n("pair of sequences: [CLS] A [SEP] B [SEP]"),Sf=c(),Dt=a("div"),v(Ws.$$.fragment),Of=c(),Vi=a("p"),Nf=n("Create a mask from the two sequences passed to be used in a sequence-pair classification task. A DeBERTa"),Wf=c(),v(Yo.$$.fragment),Hf=c(),mo=a("p"),Uf=n("If "),Ji=a("code"),Qf=n("token_ids_1"),Kf=n(" is "),Xi=a("code"),Gf=n("None"),Vf=n(", this method only returns the first portion of the mask (0s)."),Ad=c(),uo=a("h2"),Zo=a("a"),Yi=a("span"),v(Hs.$$.fragment),Jf=c(),Zi=a("span"),Xf=n("DebertaModel"),Pd=c(),bt=a("div"),v(Us.$$.fragment),Yf=c(),Qs=a("p"),Zf=n(`The bare DeBERTa Model transformer outputting raw hidden-states without any specific head on top.
The DeBERTa model was proposed in `),Ks=a("a"),em=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),tm=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),om=c(),Gs=a("p"),nm=n("This model is also a PyTorch "),Vs=a("a"),sm=n("torch.nn.Module"),am=n(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),rm=c(),Et=a("div"),v(Js.$$.fragment),im=c(),go=a("p"),lm=n("The "),Ur=a("a"),dm=n("DebertaModel"),cm=n(" forward method, overrides the "),el=a("code"),pm=n("__call__"),hm=n(" special method."),fm=c(),v(en.$$.fragment),mm=c(),v(tn.$$.fragment),Rd=c(),_o=a("h2"),on=a("a"),tl=a("span"),v(Xs.$$.fragment),um=c(),ol=a("span"),gm=n("DebertaPreTrainedModel"),Ld=c(),bo=a("div"),v(Ys.$$.fragment),_m=c(),nl=a("p"),bm=n(`An abstract class to handle weights initialization and a simple interface for downloading and loading pretrained
models.`),Bd=c(),ko=a("h2"),nn=a("a"),sl=a("span"),v(Zs.$$.fragment),km=c(),al=a("span"),wm=n("DebertaForMaskedLM"),Id=c(),kt=a("div"),v(ea.$$.fragment),vm=c(),wo=a("p"),Tm=n("DeBERTa Model with a "),rl=a("code"),ym=n("language modeling"),$m=n(` head on top.
The DeBERTa model was proposed in `),ta=a("a"),Dm=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),Em=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Fm=c(),oa=a("p"),qm=n("This model is also a PyTorch "),na=a("a"),xm=n("torch.nn.Module"),zm=n(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),jm=c(),Ft=a("div"),v(sa.$$.fragment),Mm=c(),vo=a("p"),Cm=n("The "),Qr=a("a"),Am=n("DebertaForMaskedLM"),Pm=n(" forward method, overrides the "),il=a("code"),Rm=n("__call__"),Lm=n(" special method."),Bm=c(),v(sn.$$.fragment),Im=c(),v(an.$$.fragment),Sd=c(),To=a("h2"),rn=a("a"),ll=a("span"),v(aa.$$.fragment),Sm=c(),dl=a("span"),Om=n("DebertaForSequenceClassification"),Od=c(),rt=a("div"),v(ra.$$.fragment),Nm=c(),cl=a("p"),Wm=n(`DeBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),Hm=c(),ia=a("p"),Um=n("The DeBERTa model was proposed in "),la=a("a"),Qm=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),Km=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Gm=c(),da=a("p"),Vm=n("This model is also a PyTorch "),ca=a("a"),Jm=n("torch.nn.Module"),Xm=n(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Ym=c(),ht=a("div"),v(pa.$$.fragment),Zm=c(),yo=a("p"),eu=n("The "),Kr=a("a"),tu=n("DebertaForSequenceClassification"),ou=n(" forward method, overrides the "),pl=a("code"),nu=n("__call__"),su=n(" special method."),au=c(),v(ln.$$.fragment),ru=c(),v(dn.$$.fragment),iu=c(),v(cn.$$.fragment),Nd=c(),$o=a("h2"),pn=a("a"),hl=a("span"),v(ha.$$.fragment),lu=c(),fl=a("span"),du=n("DebertaForTokenClassification"),Wd=c(),it=a("div"),v(fa.$$.fragment),cu=c(),ml=a("p"),pu=n(`DeBERTa Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),hu=c(),ma=a("p"),fu=n("The DeBERTa model was proposed in "),ua=a("a"),mu=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),uu=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),gu=c(),ga=a("p"),_u=n("This model is also a PyTorch "),_a=a("a"),bu=n("torch.nn.Module"),ku=n(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),wu=c(),qt=a("div"),v(ba.$$.fragment),vu=c(),Do=a("p"),Tu=n("The "),Gr=a("a"),yu=n("DebertaForTokenClassification"),$u=n(" forward method, overrides the "),ul=a("code"),Du=n("__call__"),Eu=n(" special method."),Fu=c(),v(hn.$$.fragment),qu=c(),v(fn.$$.fragment),Hd=c(),Eo=a("h2"),mn=a("a"),gl=a("span"),v(ka.$$.fragment),xu=c(),_l=a("span"),zu=n("DebertaForQuestionAnswering"),Ud=c(),lt=a("div"),v(wa.$$.fragment),ju=c(),Fo=a("p"),Mu=n(`DeBERTa Model with a span classification head on top for extractive question-answering tasks like SQuAD (a linear
layers on top of the hidden-states output to compute `),bl=a("code"),Cu=n("span start logits"),Au=n(" and "),kl=a("code"),Pu=n("span end logits"),Ru=n(")."),Lu=c(),va=a("p"),Bu=n("The DeBERTa model was proposed in "),Ta=a("a"),Iu=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),Su=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Ou=c(),ya=a("p"),Nu=n("This model is also a PyTorch "),$a=a("a"),Wu=n("torch.nn.Module"),Hu=n(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Uu=c(),xt=a("div"),v(Da.$$.fragment),Qu=c(),qo=a("p"),Ku=n("The "),Vr=a("a"),Gu=n("DebertaForQuestionAnswering"),Vu=n(" forward method, overrides the "),wl=a("code"),Ju=n("__call__"),Xu=n(" special method."),Yu=c(),v(un.$$.fragment),Zu=c(),v(gn.$$.fragment),Qd=c(),xo=a("h2"),_n=a("a"),vl=a("span"),v(Ea.$$.fragment),eg=c(),Tl=a("span"),tg=n("TFDebertaModel"),Kd=c(),dt=a("div"),v(Fa.$$.fragment),og=c(),qa=a("p"),ng=n(`The bare DeBERTa Model transformer outputting raw hidden-states without any specific head on top.
The DeBERTa model was proposed in `),xa=a("a"),sg=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),ag=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),rg=c(),za=a("p"),ig=n("This model is also a "),ja=a("a"),lg=n("tf.keras.Model"),dg=n(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),cg=c(),v(bn.$$.fragment),pg=c(),zt=a("div"),v(Ma.$$.fragment),hg=c(),zo=a("p"),fg=n("The "),Jr=a("a"),mg=n("TFDebertaModel"),ug=n(" forward method, overrides the "),yl=a("code"),gg=n("__call__"),_g=n(" special method."),bg=c(),v(kn.$$.fragment),kg=c(),v(wn.$$.fragment),Gd=c(),jo=a("h2"),vn=a("a"),$l=a("span"),v(Ca.$$.fragment),wg=c(),Dl=a("span"),vg=n("TFDebertaPreTrainedModel"),Vd=c(),Rt=a("div"),v(Aa.$$.fragment),Tg=c(),El=a("p"),yg=n(`An abstract class to handle weights initialization and a simple interface for downloading and loading pretrained
models.`),$g=c(),jt=a("div"),v(Pa.$$.fragment),Dg=c(),Fl=a("p"),Eg=n("Calls the model on new inputs and returns the outputs as tensors."),Fg=c(),Ra=a("p"),qg=n("In this case "),ql=a("code"),xg=n("call()"),zg=n(` just reapplies
all ops in the graph to the new inputs
(e.g. build a new computational graph from the provided inputs).`),jg=c(),wt=a("p"),Mg=n(`Note: This method should not be called directly. It is only meant to be
overridden when subclassing `),xl=a("code"),Cg=n("tf.keras.Model"),Ag=n(`.
To call a model on an input, always use the `),zl=a("code"),Pg=n("__call__()"),Rg=n(` method,
i.e. `),jl=a("code"),Lg=n("model(inputs)"),Bg=n(", which relies on the underlying "),Ml=a("code"),Ig=n("call()"),Sg=n(" method."),Jd=c(),Mo=a("h2"),Tn=a("a"),Cl=a("span"),v(La.$$.fragment),Og=c(),Al=a("span"),Ng=n("TFDebertaForMaskedLM"),Xd=c(),ct=a("div"),v(Ba.$$.fragment),Wg=c(),Co=a("p"),Hg=n("DeBERTa Model with a "),Pl=a("code"),Ug=n("language modeling"),Qg=n(` head on top.
The DeBERTa model was proposed in `),Ia=a("a"),Kg=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),Gg=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Vg=c(),Sa=a("p"),Jg=n("This model is also a "),Oa=a("a"),Xg=n("tf.keras.Model"),Yg=n(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Zg=c(),v(yn.$$.fragment),e_=c(),ft=a("div"),v(Na.$$.fragment),t_=c(),Ao=a("p"),o_=n("The "),Xr=a("a"),n_=n("TFDebertaForMaskedLM"),s_=n(" forward method, overrides the "),Rl=a("code"),a_=n("__call__"),r_=n(" special method."),i_=c(),v($n.$$.fragment),l_=c(),v(Dn.$$.fragment),d_=c(),v(En.$$.fragment),Yd=c(),Po=a("h2"),Fn=a("a"),Ll=a("span"),v(Wa.$$.fragment),c_=c(),Bl=a("span"),p_=n("TFDebertaForSequenceClassification"),Zd=c(),ot=a("div"),v(Ha.$$.fragment),h_=c(),Il=a("p"),f_=n(`DeBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),m_=c(),Ua=a("p"),u_=n("The DeBERTa model was proposed in "),Qa=a("a"),g_=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),__=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),b_=c(),Ka=a("p"),k_=n("This model is also a "),Ga=a("a"),w_=n("tf.keras.Model"),v_=n(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),T_=c(),v(qn.$$.fragment),y_=c(),mt=a("div"),v(Va.$$.fragment),$_=c(),Ro=a("p"),D_=n("The "),Yr=a("a"),E_=n("TFDebertaForSequenceClassification"),F_=n(" forward method, overrides the "),Sl=a("code"),q_=n("__call__"),x_=n(" special method."),z_=c(),v(xn.$$.fragment),j_=c(),v(zn.$$.fragment),M_=c(),v(jn.$$.fragment),ec=c(),Lo=a("h2"),Mn=a("a"),Ol=a("span"),v(Ja.$$.fragment),C_=c(),Nl=a("span"),A_=n("TFDebertaForTokenClassification"),tc=c(),nt=a("div"),v(Xa.$$.fragment),P_=c(),Wl=a("p"),R_=n(`DeBERTa Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),L_=c(),Ya=a("p"),B_=n("The DeBERTa model was proposed in "),Za=a("a"),I_=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),S_=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),O_=c(),er=a("p"),N_=n("This model is also a "),tr=a("a"),W_=n("tf.keras.Model"),H_=n(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),U_=c(),v(Cn.$$.fragment),Q_=c(),ut=a("div"),v(or.$$.fragment),K_=c(),Bo=a("p"),G_=n("The "),Zr=a("a"),V_=n("TFDebertaForTokenClassification"),J_=n(" forward method, overrides the "),Hl=a("code"),X_=n("__call__"),Y_=n(" special method."),Z_=c(),v(An.$$.fragment),eb=c(),v(Pn.$$.fragment),tb=c(),v(Rn.$$.fragment),oc=c(),Io=a("h2"),Ln=a("a"),Ul=a("span"),v(nr.$$.fragment),ob=c(),Ql=a("span"),nb=n("TFDebertaForQuestionAnswering"),nc=c(),st=a("div"),v(sr.$$.fragment),sb=c(),So=a("p"),ab=n(`DeBERTa Model with a span classification head on top for extractive question-answering tasks like SQuAD (a linear
layers on top of the hidden-states output to compute `),Kl=a("code"),rb=n("span start logits"),ib=n(" and "),Gl=a("code"),lb=n("span end logits"),db=n(")."),cb=c(),ar=a("p"),pb=n("The DeBERTa model was proposed in "),rr=a("a"),hb=n(`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),fb=n(` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),mb=c(),ir=a("p"),ub=n("This model is also a "),lr=a("a"),gb=n("tf.keras.Model"),_b=n(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),bb=c(),v(Bn.$$.fragment),kb=c(),gt=a("div"),v(dr.$$.fragment),wb=c(),Oo=a("p"),vb=n("The "),ei=a("a"),Tb=n("TFDebertaForQuestionAnswering"),yb=n(" forward method, overrides the "),Vl=a("code"),$b=n("__call__"),Db=n(" special method."),Eb=c(),v(In.$$.fragment),Fb=c(),v(Sn.$$.fragment),qb=c(),v(On.$$.fragment),this.h()},l(o){const _=Pv('[data-svelte="svelte-1phssyn"]',document.head);d=r(_,"META",{name:!0,content:!0}),_.forEach(t),b=p(o),m=r(o,"H1",{class:!0});var cr=i(m);u=r(cr,"A",{id:!0,class:!0,href:!0});var Jl=i(u);k=r(Jl,"SPAN",{});var Xl=i(k);T(l.$$.fragment,Xl),Xl.forEach(t),Jl.forEach(t),h=p(cr),z=r(cr,"SPAN",{});var Yl=i(z);ae=s(Yl,"DeBERTa"),Yl.forEach(t),cr.forEach(t),V=p(o),L=r(o,"H2",{class:!0});var pr=i(L);oe=r(pr,"A",{id:!0,class:!0,href:!0});var Zl=i(oe);se=r(Zl,"SPAN",{});var ed=i(se);T(F.$$.fragment,ed),ed.forEach(t),Zl.forEach(t),ye=p(pr),G=r(pr,"SPAN",{});var td=i(G);$e=s(td,"Overview"),td.forEach(t),pr.forEach(t),_e=p(o),S=r(o,"P",{});var hr=i(S);De=s(hr,"The DeBERTa model was proposed in "),de=r(hr,"A",{href:!0,rel:!0});var od=i(de);J=s(od,"DeBERTa: Decoding-enhanced BERT with Disentangled Attention"),od.forEach(t),Ee=s(hr,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen It is based on Google\u2019s
BERT model released in 2018 and Facebook\u2019s RoBERTa model released in 2019.`),hr.forEach(t),be=p(o),Q=r(o,"P",{});var nd=i(Q);Fe=s(nd,`It builds on RoBERTa with disentangled attention and enhanced mask decoder training with half of the data used in
RoBERTa.`),nd.forEach(t),ke=p(o),K=r(o,"P",{});var sd=i(K);qe=s(sd,"The abstract from the paper is the following:"),sd.forEach(t),we=p(o),ne=r(o,"P",{});var ad=i(ne);M=r(ad,"EM",{});var fr=i(M);C=s(fr,`Recent progress in pre-trained neural language models has significantly improved the performance of many natural
language processing (NLP) tasks. In this paper we propose a new model architecture DeBERTa (Decoding-enhanced BERT with
disentangled attention) that improves the BERT and RoBERTa models using two novel techniques. The first is the
disentangled attention mechanism, where each word is represented using two vectors that encode its content and
position, respectively, and the attention weights among words are computed using disentangled matrices on their
contents and relative positions. Second, an enhanced mask decoder is used to replace the output softmax layer to
predict the masked tokens for model pretraining. We show that these two techniques significantly improve the efficiency
of model pretraining and performance of downstream tasks. Compared to RoBERTa-Large, a DeBERTa model trained on half of
the training data performs consistently better on a wide range of NLP tasks, achieving improvements on MNLI by +0.9%
(90.2% vs. 91.1%), on SQuAD v2.0 by +2.3% (88.4% vs. 90.7%) and RACE by +3.6% (83.2% vs. 86.8%). The DeBERTa code and
pre-trained models will be made publicly available at `),ce=r(fr,"A",{href:!0,rel:!0});var rd=i(ce);X=s(rd,"https://github.com/microsoft/DeBERTa"),rd.forEach(t),xe=s(fr,"."),fr.forEach(t),ad.forEach(t),ve=p(o),B=r(o,"P",{});var Lt=i(B);ze=s(Lt,"This model was contributed by "),pe=r(Lt,"A",{href:!0,rel:!0});var id=i(pe);A=s(id,"DeBERTa"),id.forEach(t),je=s(Lt,`. This model TF 2.0 implementation was
contributed by `),W=r(Lt,"A",{href:!0,rel:!0});var ld=i(W);Me=s(ld,"kamalkraj"),ld.forEach(t),Ce=s(Lt," . The original code can be found "),H=r(Lt,"A",{href:!0,rel:!0});var dd=i(H);Ae=s(dd,"here"),dd.forEach(t),Pe=s(Lt,"."),Lt.forEach(t),I=p(o),re=r(o,"H2",{class:!0});var mr=i(re);O=r(mr,"A",{id:!0,class:!0,href:!0});var cd=i(O);me=r(cd,"SPAN",{});var pd=i(me);T(Z.$$.fragment,pd),pd.forEach(t),cd.forEach(t),P=p(mr),ue=r(mr,"SPAN",{});var hd=i(ue);R=s(hd,"Resources"),hd.forEach(t),mr.forEach(t),Te=p(o),fe=r(o,"P",{});var fd=i(fe);w=s(fd,"A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with DeBERTa. If you\u2019re interested in submitting a resource to be included here, please feel free to open a Pull Request and we\u2019ll review it! The resource should ideally demonstrate something new instead of duplicating an existing resource."),fd.forEach(t),q=p(o),T(Be.$$.fragment,o),ie=p(o),le=r(o,"UL",{});var vt=i(le);Ie=r(vt,"LI",{});var ur=i(Ie);j=s(ur,"A blog post on how to "),Se=r(ur,"A",{href:!0,rel:!0});var md=i(Se);Ke=s(md,"Accelerate Large Model Training using DeepSpeed"),md.forEach(t),Ge=s(ur," with DeBERTa."),ur.forEach(t),Ve=p(vt),Oe=r(vt,"LI",{});var gr=i(Oe);N=s(gr,"A blog post on "),U=r(gr,"A",{href:!0,rel:!0});var ud=i(U);Je=s(ud,"Supercharged Customer Service with Machine Learning"),ud.forEach(t),Xe=s(gr," with DeBERTa."),gr.forEach(t),Y=p(vt),ge=r(vt,"LI",{});var Kt=i(ge);We=r(Kt,"A",{href:!0});var gd=i(We);Re=s(gd,"DebertaForSequenceClassification"),gd.forEach(t),Ye=s(Kt," is supported by this "),ee=r(Kt,"A",{href:!0,rel:!0});var _d=i(ee);Ze=s(_d,"example script"),_d.forEach(t),Vc=s(Kt," and "),os=r(Kt,"A",{href:!0,rel:!0});var bd=i(os);Jc=s(bd,"notebook"),bd.forEach(t),Xc=s(Kt,"."),Kt.forEach(t),Yc=p(vt),Bt=r(vt,"LI",{});var Gt=i(Bt);yr=r(Gt,"A",{href:!0});var kd=i(yr);Zc=s(kd,"TFDebertaForSequenceClassification"),kd.forEach(t),ep=s(Gt," is supported by this "),ns=r(Gt,"A",{href:!0,rel:!0});var wd=i(ns);tp=s(wd,"example script"),wd.forEach(t),op=s(Gt," and "),ss=r(Gt,"A",{href:!0,rel:!0});var vd=i(ss);np=s(vd,"notebook"),vd.forEach(t),sp=s(Gt,"."),Gt.forEach(t),ap=p(vt),Ti=r(vt,"LI",{});var Cb=i(Ti);$r=r(Cb,"A",{href:!0});var Ab=i($r);rp=s(Ab,"Text classification task guide"),Ab.forEach(t),Cb.forEach(t),vt.forEach(t),Td=p(o),T(as.$$.fragment,o),yd=p(o),pt=r(o,"UL",{});var Vt=i(pt);It=r(Vt,"LI",{});var _r=i(It);Dr=r(_r,"A",{href:!0});var Pb=i(Dr);ip=s(Pb,"DebertaForTokenClassification"),Pb.forEach(t),lp=s(_r," is supported by this "),rs=r(_r,"A",{href:!0,rel:!0});var Rb=i(rs);dp=s(Rb,"example script"),Rb.forEach(t),cp=s(_r," and "),is=r(_r,"A",{href:!0,rel:!0});var Lb=i(is);pp=s(Lb,"notebook"),Lb.forEach(t),hp=s(_r,"."),_r.forEach(t),fp=p(Vt),St=r(Vt,"LI",{});var br=i(St);Er=r(br,"A",{href:!0});var Bb=i(Er);mp=s(Bb,"TFDebertaForTokenClassification"),Bb.forEach(t),up=s(br," is supported by this "),ls=r(br,"A",{href:!0,rel:!0});var Ib=i(ls);gp=s(Ib,"example script"),Ib.forEach(t),_p=s(br," and "),ds=r(br,"A",{href:!0,rel:!0});var Sb=i(ds);bp=s(Sb,"notebook"),Sb.forEach(t),kp=s(br,"."),br.forEach(t),wp=p(Vt),Fr=r(Vt,"LI",{});var xb=i(Fr);cs=r(xb,"A",{href:!0,rel:!0});var Ob=i(cs);vp=s(Ob,"Token classification"),Ob.forEach(t),Tp=s(xb," chapter of the \u{1F917} Hugging Face Course."),xb.forEach(t),yp=p(Vt),qr=r(Vt,"LI",{});var zb=i(qr);ps=r(zb,"A",{href:!0,rel:!0});var Nb=i(ps);$p=s(Nb,"Byte-Pair Encoding tokenization"),Nb.forEach(t),Dp=s(zb," chapter of the \u{1F917} Hugging Face Course."),zb.forEach(t),Ep=p(Vt),yi=r(Vt,"LI",{});var Wb=i(yi);xr=r(Wb,"A",{href:!0});var Hb=i(xr);Fp=s(Hb,"Token classification task guide"),Hb.forEach(t),Wb.forEach(t),Vt.forEach(t),$d=p(o),T(hs.$$.fragment,o),Dd=p(o),Tt=r(o,"UL",{});var Nn=i(Tt);Ot=r(Nn,"LI",{});var kr=i(Ot);zr=r(kr,"A",{href:!0});var Ub=i(zr);qp=s(Ub,"DebertaForMaskedLM"),Ub.forEach(t),xp=s(kr," is supported by this "),fs=r(kr,"A",{href:!0,rel:!0});var Qb=i(fs);zp=s(Qb,"example script"),Qb.forEach(t),jp=s(kr," and "),ms=r(kr,"A",{href:!0,rel:!0});var Kb=i(ms);Mp=s(Kb,"notebook"),Kb.forEach(t),Cp=s(kr,"."),kr.forEach(t),Ap=p(Nn),Nt=r(Nn,"LI",{});var wr=i(Nt);jr=r(wr,"A",{href:!0});var Gb=i(jr);Pp=s(Gb,"TFDebertaForMaskedLM"),Gb.forEach(t),Rp=s(wr," is supported by this "),us=r(wr,"A",{href:!0,rel:!0});var Vb=i(us);Lp=s(Vb,"example script"),Vb.forEach(t),Bp=s(wr," and "),gs=r(wr,"A",{href:!0,rel:!0});var Jb=i(gs);Ip=s(Jb,"notebook"),Jb.forEach(t),Sp=s(wr,"."),wr.forEach(t),Op=p(Nn),Mr=r(Nn,"LI",{});var jb=i(Mr);_s=r(jb,"A",{href:!0,rel:!0});var Xb=i(_s);Np=s(Xb,"Masked language modeling"),Xb.forEach(t),Wp=s(jb," chapter of the \u{1F917} Hugging Face Course."),jb.forEach(t),Hp=p(Nn),$i=r(Nn,"LI",{});var Yb=i($i);Cr=r(Yb,"A",{href:!0});var Zb=i(Cr);Up=s(Zb,"Masked language modeling task guide"),Zb.forEach(t),Yb.forEach(t),Nn.forEach(t),Ed=p(o),T(bs.$$.fragment,o),Fd=p(o),yt=r(o,"UL",{});var Wn=i(yt);Wt=r(Wn,"LI",{});var vr=i(Wt);Ar=r(vr,"A",{href:!0});var ek=i(Ar);Qp=s(ek,"DebertaForQuestionAnswering"),ek.forEach(t),Kp=s(vr," is supported by this "),ks=r(vr,"A",{href:!0,rel:!0});var tk=i(ks);Gp=s(tk,"example script"),tk.forEach(t),Vp=s(vr," and "),ws=r(vr,"A",{href:!0,rel:!0});var ok=i(ws);Jp=s(ok,"notebook"),ok.forEach(t),Xp=s(vr,"."),vr.forEach(t),Yp=p(Wn),Ht=r(Wn,"LI",{});var Tr=i(Ht);Pr=r(Tr,"A",{href:!0});var nk=i(Pr);Zp=s(nk,"TFDebertaForQuestionAnswering"),nk.forEach(t),eh=s(Tr," is supported by this "),vs=r(Tr,"A",{href:!0,rel:!0});var sk=i(vs);th=s(sk,"example script"),sk.forEach(t),oh=s(Tr," and "),Ts=r(Tr,"A",{href:!0,rel:!0});var ak=i(Ts);nh=s(ak,"notebook"),ak.forEach(t),sh=s(Tr,"."),Tr.forEach(t),ah=p(Wn),Rr=r(Wn,"LI",{});var Mb=i(Rr);ys=r(Mb,"A",{href:!0,rel:!0});var rk=i(ys);rh=s(rk,"Question answering"),rk.forEach(t),ih=s(Mb," chapter of the \u{1F917} Hugging Face Course."),Mb.forEach(t),lh=p(Wn),Di=r(Wn,"LI",{});var ik=i(Di);Lr=r(ik,"A",{href:!0});var lk=i(Lr);dh=s(lk,"Question answering task guide"),lk.forEach(t),ik.forEach(t),Wn.forEach(t),qd=p(o),io=r(o,"H2",{class:!0});var ac=i(io);No=r(ac,"A",{id:!0,class:!0,href:!0});var dk=i(No);Ei=r(dk,"SPAN",{});var ck=i(Ei);T($s.$$.fragment,ck),ck.forEach(t),dk.forEach(t),ch=p(ac),Fi=r(ac,"SPAN",{});var pk=i(Fi);ph=s(pk,"DebertaConfig"),pk.forEach(t),ac.forEach(t),xd=p(o),_t=r(o,"DIV",{class:!0});var Hn=i(_t);T(Ds.$$.fragment,Hn),hh=p(Hn),Pt=r(Hn,"P",{});var Un=i(Pt);fh=s(Un,"This is the configuration class to store the configuration of a "),Br=r(Un,"A",{href:!0});var hk=i(Br);mh=s(hk,"DebertaModel"),hk.forEach(t),uh=s(Un," or a "),Ir=r(Un,"A",{href:!0});var fk=i(Ir);gh=s(fk,"TFDebertaModel"),fk.forEach(t),_h=s(Un,`. It is
used to instantiate a DeBERTa model according to the specified arguments, defining the model architecture.
Instantiating a configuration with the defaults will yield a similar configuration to that of the DeBERTa
`),Es=r(Un,"A",{href:!0,rel:!0});var mk=i(Es);bh=s(mk,"microsoft/deberta-base"),mk.forEach(t),kh=s(Un," architecture."),Un.forEach(t),wh=p(Hn),lo=r(Hn,"P",{});var ti=i(lo);vh=s(ti,"Configuration objects inherit from "),Sr=r(ti,"A",{href:!0});var uk=i(Sr);Th=s(uk,"PretrainedConfig"),uk.forEach(t),yh=s(ti,` and can be used to control the model outputs. Read the
documentation from `),Or=r(ti,"A",{href:!0});var gk=i(Or);$h=s(gk,"PretrainedConfig"),gk.forEach(t),Dh=s(ti," for more information."),ti.forEach(t),Eh=p(Hn),T(Wo.$$.fragment,Hn),Hn.forEach(t),zd=p(o),co=r(o,"H2",{class:!0});var rc=i(co);Ho=r(rc,"A",{id:!0,class:!0,href:!0});var _k=i(Ho);qi=r(_k,"SPAN",{});var bk=i(qi);T(Fs.$$.fragment,bk),bk.forEach(t),_k.forEach(t),Fh=p(rc),xi=r(rc,"SPAN",{});var kk=i(xi);qh=s(kk,"DebertaTokenizer"),kk.forEach(t),rc.forEach(t),jd=p(o),he=r(o,"DIV",{class:!0});var Ne=i(he);T(qs.$$.fragment,Ne),xh=p(Ne),zi=r(Ne,"P",{});var wk=i(zi);zh=s(wk,"Construct a DeBERTa tokenizer. Based on byte-level Byte-Pair-Encoding."),wk.forEach(t),jh=p(Ne),ji=r(Ne,"P",{});var vk=i(ji);Mh=s(vk,"This tokenizer has been trained to treat spaces like parts of the tokens (a bit like sentencepiece) so a word will"),vk.forEach(t),Ch=p(Ne),T(Uo.$$.fragment,Ne),Ah=p(Ne),xs=r(Ne,"P",{});var ic=i(xs);Ph=s(ic,"You can get around that behavior by passing "),Mi=r(ic,"CODE",{});var Tk=i(Mi);Rh=s(Tk,"add_prefix_space=True"),Tk.forEach(t),Lh=s(ic,` when instantiating this tokenizer or when you
call it on some text, but since the model was not pretrained this way, it might yield a decrease in performance.`),ic.forEach(t),Bh=p(Ne),T(Qo.$$.fragment,Ne),Ih=p(Ne),zs=r(Ne,"P",{});var lc=i(zs);Sh=s(lc,"This tokenizer inherits from "),Nr=r(lc,"A",{href:!0});var yk=i(Nr);Oh=s(yk,"PreTrainedTokenizer"),yk.forEach(t),Nh=s(lc,` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),lc.forEach(t),Wh=p(Ne),Ut=r(Ne,"DIV",{class:!0});var oi=i(Ut);T(js.$$.fragment,oi),Hh=p(oi),Ci=r(oi,"P",{});var $k=i(Ci);Uh=s($k,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A DeBERTa sequence has the following format:`),$k.forEach(t),Qh=p(oi),Ms=r(oi,"UL",{});var dc=i(Ms);Ai=r(dc,"LI",{});var Dk=i(Ai);Kh=s(Dk,"single sequence: [CLS] X [SEP]"),Dk.forEach(t),Gh=p(dc),Pi=r(dc,"LI",{});var Ek=i(Pi);Vh=s(Ek,"pair of sequences: [CLS] A [SEP] B [SEP]"),Ek.forEach(t),dc.forEach(t),oi.forEach(t),Jh=p(Ne),Ko=r(Ne,"DIV",{class:!0});var cc=i(Ko);T(Cs.$$.fragment,cc),Xh=p(cc),po=r(cc,"P",{});var ni=i(po);Yh=s(ni,`Retrieves sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),Ri=r(ni,"CODE",{});var Fk=i(Ri);Zh=s(Fk,"prepare_for_model"),Fk.forEach(t),ef=s(ni," or "),Li=r(ni,"CODE",{});var qk=i(Li);tf=s(qk,"encode_plus"),qk.forEach(t),of=s(ni," methods."),ni.forEach(t),cc.forEach(t),nf=p(Ne),$t=r(Ne,"DIV",{class:!0});var Qn=i($t);T(As.$$.fragment,Qn),sf=p(Qn),Bi=r(Qn,"P",{});var xk=i(Bi);af=s(xk,"Create a mask from the two sequences passed to be used in a sequence-pair classification task. A DeBERTa"),xk.forEach(t),rf=p(Qn),T(Go.$$.fragment,Qn),lf=p(Qn),ho=r(Qn,"P",{});var si=i(ho);df=s(si,"If "),Ii=r(si,"CODE",{});var zk=i(Ii);cf=s(zk,"token_ids_1"),zk.forEach(t),pf=s(si," is "),Si=r(si,"CODE",{});var jk=i(Si);hf=s(jk,"None"),jk.forEach(t),ff=s(si,", this method only returns the first portion of the mask (0s)."),si.forEach(t),Qn.forEach(t),mf=p(Ne),Wr=r(Ne,"DIV",{class:!0});var Mk=i(Wr);T(Ps.$$.fragment,Mk),Mk.forEach(t),Ne.forEach(t),Md=p(o),fo=r(o,"H2",{class:!0});var pc=i(fo);Vo=r(pc,"A",{id:!0,class:!0,href:!0});var Ck=i(Vo);Oi=r(Ck,"SPAN",{});var Ak=i(Oi);T(Rs.$$.fragment,Ak),Ak.forEach(t),Ck.forEach(t),uf=p(pc),Ni=r(pc,"SPAN",{});var Pk=i(Ni);gf=s(Pk,"DebertaTokenizerFast"),Pk.forEach(t),pc.forEach(t),Cd=p(o),Le=r(o,"DIV",{class:!0});var et=i(Le);T(Ls.$$.fragment,et),_f=p(et),Bs=r(et,"P",{});var hc=i(Bs);bf=s(hc,"Construct a \u201Cfast\u201D DeBERTa tokenizer (backed by HuggingFace\u2019s "),Wi=r(hc,"EM",{});var Rk=i(Wi);kf=s(Rk,"tokenizers"),Rk.forEach(t),wf=s(hc,` library). Based on byte-level
Byte-Pair-Encoding.`),hc.forEach(t),vf=p(et),Hi=r(et,"P",{});var Lk=i(Hi);Tf=s(Lk,"This tokenizer has been trained to treat spaces like parts of the tokens (a bit like sentencepiece) so a word will"),Lk.forEach(t),yf=p(et),T(Jo.$$.fragment,et),$f=p(et),Is=r(et,"P",{});var fc=i(Is);Df=s(fc,"You can get around that behavior by passing "),Ui=r(fc,"CODE",{});var Bk=i(Ui);Ef=s(Bk,"add_prefix_space=True"),Bk.forEach(t),Ff=s(fc,` when instantiating this tokenizer, but since
the model was not pretrained this way, it might yield a decrease in performance.`),fc.forEach(t),qf=p(et),T(Xo.$$.fragment,et),xf=p(et),Ss=r(et,"P",{});var mc=i(Ss);zf=s(mc,"This tokenizer inherits from "),Hr=r(mc,"A",{href:!0});var Ik=i(Hr);jf=s(Ik,"PreTrainedTokenizerFast"),Ik.forEach(t),Mf=s(mc,` which contains most of the main methods. Users should
refer to this superclass for more information regarding those methods.`),mc.forEach(t),Cf=p(et),Qt=r(et,"DIV",{class:!0});var ai=i(Qt);T(Os.$$.fragment,ai),Af=p(ai),Qi=r(ai,"P",{});var Sk=i(Qi);Pf=s(Sk,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A DeBERTa sequence has the following format:`),Sk.forEach(t),Rf=p(ai),Ns=r(ai,"UL",{});var uc=i(Ns);Ki=r(uc,"LI",{});var Ok=i(Ki);Lf=s(Ok,"single sequence: [CLS] X [SEP]"),Ok.forEach(t),Bf=p(uc),Gi=r(uc,"LI",{});var Nk=i(Gi);If=s(Nk,"pair of sequences: [CLS] A [SEP] B [SEP]"),Nk.forEach(t),uc.forEach(t),ai.forEach(t),Sf=p(et),Dt=r(et,"DIV",{class:!0});var Kn=i(Dt);T(Ws.$$.fragment,Kn),Of=p(Kn),Vi=r(Kn,"P",{});var Wk=i(Vi);Nf=s(Wk,"Create a mask from the two sequences passed to be used in a sequence-pair classification task. A DeBERTa"),Wk.forEach(t),Wf=p(Kn),T(Yo.$$.fragment,Kn),Hf=p(Kn),mo=r(Kn,"P",{});var ri=i(mo);Uf=s(ri,"If "),Ji=r(ri,"CODE",{});var Hk=i(Ji);Qf=s(Hk,"token_ids_1"),Hk.forEach(t),Kf=s(ri," is "),Xi=r(ri,"CODE",{});var Uk=i(Xi);Gf=s(Uk,"None"),Uk.forEach(t),Vf=s(ri,", this method only returns the first portion of the mask (0s)."),ri.forEach(t),Kn.forEach(t),et.forEach(t),Ad=p(o),uo=r(o,"H2",{class:!0});var gc=i(uo);Zo=r(gc,"A",{id:!0,class:!0,href:!0});var Qk=i(Zo);Yi=r(Qk,"SPAN",{});var Kk=i(Yi);T(Hs.$$.fragment,Kk),Kk.forEach(t),Qk.forEach(t),Jf=p(gc),Zi=r(gc,"SPAN",{});var Gk=i(Zi);Xf=s(Gk,"DebertaModel"),Gk.forEach(t),gc.forEach(t),Pd=p(o),bt=r(o,"DIV",{class:!0});var Gn=i(bt);T(Us.$$.fragment,Gn),Yf=p(Gn),Qs=r(Gn,"P",{});var _c=i(Qs);Zf=s(_c,`The bare DeBERTa Model transformer outputting raw hidden-states without any specific head on top.
The DeBERTa model was proposed in `),Ks=r(_c,"A",{href:!0,rel:!0});var Vk=i(Ks);em=s(Vk,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),Vk.forEach(t),tm=s(_c,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),_c.forEach(t),om=p(Gn),Gs=r(Gn,"P",{});var bc=i(Gs);nm=s(bc,"This model is also a PyTorch "),Vs=r(bc,"A",{href:!0,rel:!0});var Jk=i(Vs);sm=s(Jk,"torch.nn.Module"),Jk.forEach(t),am=s(bc,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),bc.forEach(t),rm=p(Gn),Et=r(Gn,"DIV",{class:!0});var Vn=i(Et);T(Js.$$.fragment,Vn),im=p(Vn),go=r(Vn,"P",{});var ii=i(go);lm=s(ii,"The "),Ur=r(ii,"A",{href:!0});var Xk=i(Ur);dm=s(Xk,"DebertaModel"),Xk.forEach(t),cm=s(ii," forward method, overrides the "),el=r(ii,"CODE",{});var Yk=i(el);pm=s(Yk,"__call__"),Yk.forEach(t),hm=s(ii," special method."),ii.forEach(t),fm=p(Vn),T(en.$$.fragment,Vn),mm=p(Vn),T(tn.$$.fragment,Vn),Vn.forEach(t),Gn.forEach(t),Rd=p(o),_o=r(o,"H2",{class:!0});var kc=i(_o);on=r(kc,"A",{id:!0,class:!0,href:!0});var Zk=i(on);tl=r(Zk,"SPAN",{});var ew=i(tl);T(Xs.$$.fragment,ew),ew.forEach(t),Zk.forEach(t),um=p(kc),ol=r(kc,"SPAN",{});var tw=i(ol);gm=s(tw,"DebertaPreTrainedModel"),tw.forEach(t),kc.forEach(t),Ld=p(o),bo=r(o,"DIV",{class:!0});var wc=i(bo);T(Ys.$$.fragment,wc),_m=p(wc),nl=r(wc,"P",{});var ow=i(nl);bm=s(ow,`An abstract class to handle weights initialization and a simple interface for downloading and loading pretrained
models.`),ow.forEach(t),wc.forEach(t),Bd=p(o),ko=r(o,"H2",{class:!0});var vc=i(ko);nn=r(vc,"A",{id:!0,class:!0,href:!0});var nw=i(nn);sl=r(nw,"SPAN",{});var sw=i(sl);T(Zs.$$.fragment,sw),sw.forEach(t),nw.forEach(t),km=p(vc),al=r(vc,"SPAN",{});var aw=i(al);wm=s(aw,"DebertaForMaskedLM"),aw.forEach(t),vc.forEach(t),Id=p(o),kt=r(o,"DIV",{class:!0});var Jn=i(kt);T(ea.$$.fragment,Jn),vm=p(Jn),wo=r(Jn,"P",{});var li=i(wo);Tm=s(li,"DeBERTa Model with a "),rl=r(li,"CODE",{});var rw=i(rl);ym=s(rw,"language modeling"),rw.forEach(t),$m=s(li,` head on top.
The DeBERTa model was proposed in `),ta=r(li,"A",{href:!0,rel:!0});var iw=i(ta);Dm=s(iw,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),iw.forEach(t),Em=s(li,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),li.forEach(t),Fm=p(Jn),oa=r(Jn,"P",{});var Tc=i(oa);qm=s(Tc,"This model is also a PyTorch "),na=r(Tc,"A",{href:!0,rel:!0});var lw=i(na);xm=s(lw,"torch.nn.Module"),lw.forEach(t),zm=s(Tc,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Tc.forEach(t),jm=p(Jn),Ft=r(Jn,"DIV",{class:!0});var Xn=i(Ft);T(sa.$$.fragment,Xn),Mm=p(Xn),vo=r(Xn,"P",{});var di=i(vo);Cm=s(di,"The "),Qr=r(di,"A",{href:!0});var dw=i(Qr);Am=s(dw,"DebertaForMaskedLM"),dw.forEach(t),Pm=s(di," forward method, overrides the "),il=r(di,"CODE",{});var cw=i(il);Rm=s(cw,"__call__"),cw.forEach(t),Lm=s(di," special method."),di.forEach(t),Bm=p(Xn),T(sn.$$.fragment,Xn),Im=p(Xn),T(an.$$.fragment,Xn),Xn.forEach(t),Jn.forEach(t),Sd=p(o),To=r(o,"H2",{class:!0});var yc=i(To);rn=r(yc,"A",{id:!0,class:!0,href:!0});var pw=i(rn);ll=r(pw,"SPAN",{});var hw=i(ll);T(aa.$$.fragment,hw),hw.forEach(t),pw.forEach(t),Sm=p(yc),dl=r(yc,"SPAN",{});var fw=i(dl);Om=s(fw,"DebertaForSequenceClassification"),fw.forEach(t),yc.forEach(t),Od=p(o),rt=r(o,"DIV",{class:!0});var Jt=i(rt);T(ra.$$.fragment,Jt),Nm=p(Jt),cl=r(Jt,"P",{});var mw=i(cl);Wm=s(mw,`DeBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),mw.forEach(t),Hm=p(Jt),ia=r(Jt,"P",{});var $c=i(ia);Um=s($c,"The DeBERTa model was proposed in "),la=r($c,"A",{href:!0,rel:!0});var uw=i(la);Qm=s(uw,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),uw.forEach(t),Km=s($c,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),$c.forEach(t),Gm=p(Jt),da=r(Jt,"P",{});var Dc=i(da);Vm=s(Dc,"This model is also a PyTorch "),ca=r(Dc,"A",{href:!0,rel:!0});var gw=i(ca);Jm=s(gw,"torch.nn.Module"),gw.forEach(t),Xm=s(Dc,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Dc.forEach(t),Ym=p(Jt),ht=r(Jt,"DIV",{class:!0});var Xt=i(ht);T(pa.$$.fragment,Xt),Zm=p(Xt),yo=r(Xt,"P",{});var ci=i(yo);eu=s(ci,"The "),Kr=r(ci,"A",{href:!0});var _w=i(Kr);tu=s(_w,"DebertaForSequenceClassification"),_w.forEach(t),ou=s(ci," forward method, overrides the "),pl=r(ci,"CODE",{});var bw=i(pl);nu=s(bw,"__call__"),bw.forEach(t),su=s(ci," special method."),ci.forEach(t),au=p(Xt),T(ln.$$.fragment,Xt),ru=p(Xt),T(dn.$$.fragment,Xt),iu=p(Xt),T(cn.$$.fragment,Xt),Xt.forEach(t),Jt.forEach(t),Nd=p(o),$o=r(o,"H2",{class:!0});var Ec=i($o);pn=r(Ec,"A",{id:!0,class:!0,href:!0});var kw=i(pn);hl=r(kw,"SPAN",{});var ww=i(hl);T(ha.$$.fragment,ww),ww.forEach(t),kw.forEach(t),lu=p(Ec),fl=r(Ec,"SPAN",{});var vw=i(fl);du=s(vw,"DebertaForTokenClassification"),vw.forEach(t),Ec.forEach(t),Wd=p(o),it=r(o,"DIV",{class:!0});var Yt=i(it);T(fa.$$.fragment,Yt),cu=p(Yt),ml=r(Yt,"P",{});var Tw=i(ml);pu=s(Tw,`DeBERTa Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),Tw.forEach(t),hu=p(Yt),ma=r(Yt,"P",{});var Fc=i(ma);fu=s(Fc,"The DeBERTa model was proposed in "),ua=r(Fc,"A",{href:!0,rel:!0});var yw=i(ua);mu=s(yw,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),yw.forEach(t),uu=s(Fc,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Fc.forEach(t),gu=p(Yt),ga=r(Yt,"P",{});var qc=i(ga);_u=s(qc,"This model is also a PyTorch "),_a=r(qc,"A",{href:!0,rel:!0});var $w=i(_a);bu=s($w,"torch.nn.Module"),$w.forEach(t),ku=s(qc,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),qc.forEach(t),wu=p(Yt),qt=r(Yt,"DIV",{class:!0});var Yn=i(qt);T(ba.$$.fragment,Yn),vu=p(Yn),Do=r(Yn,"P",{});var pi=i(Do);Tu=s(pi,"The "),Gr=r(pi,"A",{href:!0});var Dw=i(Gr);yu=s(Dw,"DebertaForTokenClassification"),Dw.forEach(t),$u=s(pi," forward method, overrides the "),ul=r(pi,"CODE",{});var Ew=i(ul);Du=s(Ew,"__call__"),Ew.forEach(t),Eu=s(pi," special method."),pi.forEach(t),Fu=p(Yn),T(hn.$$.fragment,Yn),qu=p(Yn),T(fn.$$.fragment,Yn),Yn.forEach(t),Yt.forEach(t),Hd=p(o),Eo=r(o,"H2",{class:!0});var xc=i(Eo);mn=r(xc,"A",{id:!0,class:!0,href:!0});var Fw=i(mn);gl=r(Fw,"SPAN",{});var qw=i(gl);T(ka.$$.fragment,qw),qw.forEach(t),Fw.forEach(t),xu=p(xc),_l=r(xc,"SPAN",{});var xw=i(_l);zu=s(xw,"DebertaForQuestionAnswering"),xw.forEach(t),xc.forEach(t),Ud=p(o),lt=r(o,"DIV",{class:!0});var Zt=i(lt);T(wa.$$.fragment,Zt),ju=p(Zt),Fo=r(Zt,"P",{});var hi=i(Fo);Mu=s(hi,`DeBERTa Model with a span classification head on top for extractive question-answering tasks like SQuAD (a linear
layers on top of the hidden-states output to compute `),bl=r(hi,"CODE",{});var zw=i(bl);Cu=s(zw,"span start logits"),zw.forEach(t),Au=s(hi," and "),kl=r(hi,"CODE",{});var jw=i(kl);Pu=s(jw,"span end logits"),jw.forEach(t),Ru=s(hi,")."),hi.forEach(t),Lu=p(Zt),va=r(Zt,"P",{});var zc=i(va);Bu=s(zc,"The DeBERTa model was proposed in "),Ta=r(zc,"A",{href:!0,rel:!0});var Mw=i(Ta);Iu=s(Mw,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),Mw.forEach(t),Su=s(zc,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),zc.forEach(t),Ou=p(Zt),ya=r(Zt,"P",{});var jc=i(ya);Nu=s(jc,"This model is also a PyTorch "),$a=r(jc,"A",{href:!0,rel:!0});var Cw=i($a);Wu=s(Cw,"torch.nn.Module"),Cw.forEach(t),Hu=s(jc,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),jc.forEach(t),Uu=p(Zt),xt=r(Zt,"DIV",{class:!0});var Zn=i(xt);T(Da.$$.fragment,Zn),Qu=p(Zn),qo=r(Zn,"P",{});var fi=i(qo);Ku=s(fi,"The "),Vr=r(fi,"A",{href:!0});var Aw=i(Vr);Gu=s(Aw,"DebertaForQuestionAnswering"),Aw.forEach(t),Vu=s(fi," forward method, overrides the "),wl=r(fi,"CODE",{});var Pw=i(wl);Ju=s(Pw,"__call__"),Pw.forEach(t),Xu=s(fi," special method."),fi.forEach(t),Yu=p(Zn),T(un.$$.fragment,Zn),Zu=p(Zn),T(gn.$$.fragment,Zn),Zn.forEach(t),Zt.forEach(t),Qd=p(o),xo=r(o,"H2",{class:!0});var Mc=i(xo);_n=r(Mc,"A",{id:!0,class:!0,href:!0});var Rw=i(_n);vl=r(Rw,"SPAN",{});var Lw=i(vl);T(Ea.$$.fragment,Lw),Lw.forEach(t),Rw.forEach(t),eg=p(Mc),Tl=r(Mc,"SPAN",{});var Bw=i(Tl);tg=s(Bw,"TFDebertaModel"),Bw.forEach(t),Mc.forEach(t),Kd=p(o),dt=r(o,"DIV",{class:!0});var eo=i(dt);T(Fa.$$.fragment,eo),og=p(eo),qa=r(eo,"P",{});var Cc=i(qa);ng=s(Cc,`The bare DeBERTa Model transformer outputting raw hidden-states without any specific head on top.
The DeBERTa model was proposed in `),xa=r(Cc,"A",{href:!0,rel:!0});var Iw=i(xa);sg=s(Iw,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),Iw.forEach(t),ag=s(Cc,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Cc.forEach(t),rg=p(eo),za=r(eo,"P",{});var Ac=i(za);ig=s(Ac,"This model is also a "),ja=r(Ac,"A",{href:!0,rel:!0});var Sw=i(ja);lg=s(Sw,"tf.keras.Model"),Sw.forEach(t),dg=s(Ac,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Ac.forEach(t),cg=p(eo),T(bn.$$.fragment,eo),pg=p(eo),zt=r(eo,"DIV",{class:!0});var es=i(zt);T(Ma.$$.fragment,es),hg=p(es),zo=r(es,"P",{});var mi=i(zo);fg=s(mi,"The "),Jr=r(mi,"A",{href:!0});var Ow=i(Jr);mg=s(Ow,"TFDebertaModel"),Ow.forEach(t),ug=s(mi," forward method, overrides the "),yl=r(mi,"CODE",{});var Nw=i(yl);gg=s(Nw,"__call__"),Nw.forEach(t),_g=s(mi," special method."),mi.forEach(t),bg=p(es),T(kn.$$.fragment,es),kg=p(es),T(wn.$$.fragment,es),es.forEach(t),eo.forEach(t),Gd=p(o),jo=r(o,"H2",{class:!0});var Pc=i(jo);vn=r(Pc,"A",{id:!0,class:!0,href:!0});var Ww=i(vn);$l=r(Ww,"SPAN",{});var Hw=i($l);T(Ca.$$.fragment,Hw),Hw.forEach(t),Ww.forEach(t),wg=p(Pc),Dl=r(Pc,"SPAN",{});var Uw=i(Dl);vg=s(Uw,"TFDebertaPreTrainedModel"),Uw.forEach(t),Pc.forEach(t),Vd=p(o),Rt=r(o,"DIV",{class:!0});var ui=i(Rt);T(Aa.$$.fragment,ui),Tg=p(ui),El=r(ui,"P",{});var Qw=i(El);yg=s(Qw,`An abstract class to handle weights initialization and a simple interface for downloading and loading pretrained
models.`),Qw.forEach(t),$g=p(ui),jt=r(ui,"DIV",{class:!0});var ts=i(jt);T(Pa.$$.fragment,ts),Dg=p(ts),Fl=r(ts,"P",{});var Kw=i(Fl);Eg=s(Kw,"Calls the model on new inputs and returns the outputs as tensors."),Kw.forEach(t),Fg=p(ts),Ra=r(ts,"P",{});var Rc=i(Ra);qg=s(Rc,"In this case "),ql=r(Rc,"CODE",{});var Gw=i(ql);xg=s(Gw,"call()"),Gw.forEach(t),zg=s(Rc,` just reapplies
all ops in the graph to the new inputs
(e.g. build a new computational graph from the provided inputs).`),Rc.forEach(t),jg=p(ts),wt=r(ts,"P",{});var to=i(wt);Mg=s(to,`Note: This method should not be called directly. It is only meant to be
overridden when subclassing `),xl=r(to,"CODE",{});var Vw=i(xl);Cg=s(Vw,"tf.keras.Model"),Vw.forEach(t),Ag=s(to,`.
To call a model on an input, always use the `),zl=r(to,"CODE",{});var Jw=i(zl);Pg=s(Jw,"__call__()"),Jw.forEach(t),Rg=s(to,` method,
i.e. `),jl=r(to,"CODE",{});var Xw=i(jl);Lg=s(Xw,"model(inputs)"),Xw.forEach(t),Bg=s(to,", which relies on the underlying "),Ml=r(to,"CODE",{});var Yw=i(Ml);Ig=s(Yw,"call()"),Yw.forEach(t),Sg=s(to," method."),to.forEach(t),ts.forEach(t),ui.forEach(t),Jd=p(o),Mo=r(o,"H2",{class:!0});var Lc=i(Mo);Tn=r(Lc,"A",{id:!0,class:!0,href:!0});var Zw=i(Tn);Cl=r(Zw,"SPAN",{});var ev=i(Cl);T(La.$$.fragment,ev),ev.forEach(t),Zw.forEach(t),Og=p(Lc),Al=r(Lc,"SPAN",{});var tv=i(Al);Ng=s(tv,"TFDebertaForMaskedLM"),tv.forEach(t),Lc.forEach(t),Xd=p(o),ct=r(o,"DIV",{class:!0});var oo=i(ct);T(Ba.$$.fragment,oo),Wg=p(oo),Co=r(oo,"P",{});var gi=i(Co);Hg=s(gi,"DeBERTa Model with a "),Pl=r(gi,"CODE",{});var ov=i(Pl);Ug=s(ov,"language modeling"),ov.forEach(t),Qg=s(gi,` head on top.
The DeBERTa model was proposed in `),Ia=r(gi,"A",{href:!0,rel:!0});var nv=i(Ia);Kg=s(nv,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),nv.forEach(t),Gg=s(gi,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),gi.forEach(t),Vg=p(oo),Sa=r(oo,"P",{});var Bc=i(Sa);Jg=s(Bc,"This model is also a "),Oa=r(Bc,"A",{href:!0,rel:!0});var sv=i(Oa);Xg=s(sv,"tf.keras.Model"),sv.forEach(t),Yg=s(Bc,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Bc.forEach(t),Zg=p(oo),T(yn.$$.fragment,oo),e_=p(oo),ft=r(oo,"DIV",{class:!0});var no=i(ft);T(Na.$$.fragment,no),t_=p(no),Ao=r(no,"P",{});var _i=i(Ao);o_=s(_i,"The "),Xr=r(_i,"A",{href:!0});var av=i(Xr);n_=s(av,"TFDebertaForMaskedLM"),av.forEach(t),s_=s(_i," forward method, overrides the "),Rl=r(_i,"CODE",{});var rv=i(Rl);a_=s(rv,"__call__"),rv.forEach(t),r_=s(_i," special method."),_i.forEach(t),i_=p(no),T($n.$$.fragment,no),l_=p(no),T(Dn.$$.fragment,no),d_=p(no),T(En.$$.fragment,no),no.forEach(t),oo.forEach(t),Yd=p(o),Po=r(o,"H2",{class:!0});var Ic=i(Po);Fn=r(Ic,"A",{id:!0,class:!0,href:!0});var iv=i(Fn);Ll=r(iv,"SPAN",{});var lv=i(Ll);T(Wa.$$.fragment,lv),lv.forEach(t),iv.forEach(t),c_=p(Ic),Bl=r(Ic,"SPAN",{});var dv=i(Bl);p_=s(dv,"TFDebertaForSequenceClassification"),dv.forEach(t),Ic.forEach(t),Zd=p(o),ot=r(o,"DIV",{class:!0});var Mt=i(ot);T(Ha.$$.fragment,Mt),h_=p(Mt),Il=r(Mt,"P",{});var cv=i(Il);f_=s(cv,`DeBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),cv.forEach(t),m_=p(Mt),Ua=r(Mt,"P",{});var Sc=i(Ua);u_=s(Sc,"The DeBERTa model was proposed in "),Qa=r(Sc,"A",{href:!0,rel:!0});var pv=i(Qa);g_=s(pv,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),pv.forEach(t),__=s(Sc,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Sc.forEach(t),b_=p(Mt),Ka=r(Mt,"P",{});var Oc=i(Ka);k_=s(Oc,"This model is also a "),Ga=r(Oc,"A",{href:!0,rel:!0});var hv=i(Ga);w_=s(hv,"tf.keras.Model"),hv.forEach(t),v_=s(Oc,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Oc.forEach(t),T_=p(Mt),T(qn.$$.fragment,Mt),y_=p(Mt),mt=r(Mt,"DIV",{class:!0});var so=i(mt);T(Va.$$.fragment,so),$_=p(so),Ro=r(so,"P",{});var bi=i(Ro);D_=s(bi,"The "),Yr=r(bi,"A",{href:!0});var fv=i(Yr);E_=s(fv,"TFDebertaForSequenceClassification"),fv.forEach(t),F_=s(bi," forward method, overrides the "),Sl=r(bi,"CODE",{});var mv=i(Sl);q_=s(mv,"__call__"),mv.forEach(t),x_=s(bi," special method."),bi.forEach(t),z_=p(so),T(xn.$$.fragment,so),j_=p(so),T(zn.$$.fragment,so),M_=p(so),T(jn.$$.fragment,so),so.forEach(t),Mt.forEach(t),ec=p(o),Lo=r(o,"H2",{class:!0});var Nc=i(Lo);Mn=r(Nc,"A",{id:!0,class:!0,href:!0});var uv=i(Mn);Ol=r(uv,"SPAN",{});var gv=i(Ol);T(Ja.$$.fragment,gv),gv.forEach(t),uv.forEach(t),C_=p(Nc),Nl=r(Nc,"SPAN",{});var _v=i(Nl);A_=s(_v,"TFDebertaForTokenClassification"),_v.forEach(t),Nc.forEach(t),tc=p(o),nt=r(o,"DIV",{class:!0});var Ct=i(nt);T(Xa.$$.fragment,Ct),P_=p(Ct),Wl=r(Ct,"P",{});var bv=i(Wl);R_=s(bv,`DeBERTa Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),bv.forEach(t),L_=p(Ct),Ya=r(Ct,"P",{});var Wc=i(Ya);B_=s(Wc,"The DeBERTa model was proposed in "),Za=r(Wc,"A",{href:!0,rel:!0});var kv=i(Za);I_=s(kv,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),kv.forEach(t),S_=s(Wc,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Wc.forEach(t),O_=p(Ct),er=r(Ct,"P",{});var Hc=i(er);N_=s(Hc,"This model is also a "),tr=r(Hc,"A",{href:!0,rel:!0});var wv=i(tr);W_=s(wv,"tf.keras.Model"),wv.forEach(t),H_=s(Hc,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Hc.forEach(t),U_=p(Ct),T(Cn.$$.fragment,Ct),Q_=p(Ct),ut=r(Ct,"DIV",{class:!0});var ao=i(ut);T(or.$$.fragment,ao),K_=p(ao),Bo=r(ao,"P",{});var ki=i(Bo);G_=s(ki,"The "),Zr=r(ki,"A",{href:!0});var vv=i(Zr);V_=s(vv,"TFDebertaForTokenClassification"),vv.forEach(t),J_=s(ki," forward method, overrides the "),Hl=r(ki,"CODE",{});var Tv=i(Hl);X_=s(Tv,"__call__"),Tv.forEach(t),Y_=s(ki," special method."),ki.forEach(t),Z_=p(ao),T(An.$$.fragment,ao),eb=p(ao),T(Pn.$$.fragment,ao),tb=p(ao),T(Rn.$$.fragment,ao),ao.forEach(t),Ct.forEach(t),oc=p(o),Io=r(o,"H2",{class:!0});var Uc=i(Io);Ln=r(Uc,"A",{id:!0,class:!0,href:!0});var yv=i(Ln);Ul=r(yv,"SPAN",{});var $v=i(Ul);T(nr.$$.fragment,$v),$v.forEach(t),yv.forEach(t),ob=p(Uc),Ql=r(Uc,"SPAN",{});var Dv=i(Ql);nb=s(Dv,"TFDebertaForQuestionAnswering"),Dv.forEach(t),Uc.forEach(t),nc=p(o),st=r(o,"DIV",{class:!0});var At=i(st);T(sr.$$.fragment,At),sb=p(At),So=r(At,"P",{});var wi=i(So);ab=s(wi,`DeBERTa Model with a span classification head on top for extractive question-answering tasks like SQuAD (a linear
layers on top of the hidden-states output to compute `),Kl=r(wi,"CODE",{});var Ev=i(Kl);rb=s(Ev,"span start logits"),Ev.forEach(t),ib=s(wi," and "),Gl=r(wi,"CODE",{});var Fv=i(Gl);lb=s(Fv,"span end logits"),Fv.forEach(t),db=s(wi,")."),wi.forEach(t),cb=p(At),ar=r(At,"P",{});var Qc=i(ar);pb=s(Qc,"The DeBERTa model was proposed in "),rr=r(Qc,"A",{href:!0,rel:!0});var qv=i(rr);hb=s(qv,`DeBERTa: Decoding-enhanced BERT with Disentangled
Attention`),qv.forEach(t),fb=s(Qc,` by Pengcheng He, Xiaodong Liu, Jianfeng Gao, Weizhu Chen. It\u2019s build
on top of BERT/RoBERTa with two improvements, i.e. disentangled attention and enhanced mask decoder. With those two
improvements, it out perform BERT/RoBERTa on a majority of tasks with 80GB pretraining data.`),Qc.forEach(t),mb=p(At),ir=r(At,"P",{});var Kc=i(ir);ub=s(Kc,"This model is also a "),lr=r(Kc,"A",{href:!0,rel:!0});var xv=i(lr);gb=s(xv,"tf.keras.Model"),xv.forEach(t),_b=s(Kc,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Kc.forEach(t),bb=p(At),T(Bn.$$.fragment,At),kb=p(At),gt=r(At,"DIV",{class:!0});var ro=i(gt);T(dr.$$.fragment,ro),wb=p(ro),Oo=r(ro,"P",{});var vi=i(Oo);vb=s(vi,"The "),ei=r(vi,"A",{href:!0});var zv=i(ei);Tb=s(zv,"TFDebertaForQuestionAnswering"),zv.forEach(t),yb=s(vi," forward method, overrides the "),Vl=r(vi,"CODE",{});var jv=i(Vl);$b=s(jv,"__call__"),jv.forEach(t),Db=s(vi," special method."),vi.forEach(t),Eb=p(ro),T(In.$$.fragment,ro),Fb=p(ro),T(Sn.$$.fragment,ro),qb=p(ro),T(On.$$.fragment,ro),ro.forEach(t),At.forEach(t),this.h()},h(){f(d,"name","hf:doc:metadata"),f(d,"content",JSON.stringify(vT)),f(u,"id","deberta"),f(u,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(u,"href","#deberta"),f(m,"class","relative group"),f(oe,"id","overview"),f(oe,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(oe,"href","#overview"),f(L,"class","relative group"),f(de,"href","https://arxiv.org/abs/2006.03654"),f(de,"rel","nofollow"),f(ce,"href","https://github.com/microsoft/DeBERTa"),f(ce,"rel","nofollow"),f(pe,"href","https://huggingface.co/DeBERTa"),f(pe,"rel","nofollow"),f(W,"href","https://huggingface.co/kamalkraj"),f(W,"rel","nofollow"),f(H,"href","https://github.com/microsoft/DeBERTa"),f(H,"rel","nofollow"),f(O,"id","resources"),f(O,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(O,"href","#resources"),f(re,"class","relative group"),f(Se,"href","https://huggingface.co/blog/accelerate-deepspeed"),f(Se,"rel","nofollow"),f(U,"href","https://huggingface.co/blog/supercharge-customer-service-with-machine-learning"),f(U,"rel","nofollow"),f(We,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForSequenceClassification"),f(ee,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/text-classification"),f(ee,"rel","nofollow"),f(os,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification.ipynb"),f(os,"rel","nofollow"),f(yr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForSequenceClassification"),f(ns,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/text-classification"),f(ns,"rel","nofollow"),f(ss,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification-tf.ipynb"),f(ss,"rel","nofollow"),f($r,"href","../tasks/sequence_classification"),f(Dr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForTokenClassification"),f(rs,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/token-classification"),f(rs,"rel","nofollow"),f(is,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification.ipynb"),f(is,"rel","nofollow"),f(Er,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForTokenClassification"),f(ls,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/token-classification"),f(ls,"rel","nofollow"),f(ds,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification-tf.ipynb"),f(ds,"rel","nofollow"),f(cs,"href","https://huggingface.co/course/chapter7/2?fw=pt"),f(cs,"rel","nofollow"),f(ps,"href","https://huggingface.co/course/chapter6/5?fw=pt"),f(ps,"rel","nofollow"),f(xr,"href","../tasks/token_classification"),f(zr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForMaskedLM"),f(fs,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/language-modeling#robertabertdistilbert-and-masked-language-modeling"),f(fs,"rel","nofollow"),f(ms,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling.ipynb"),f(ms,"rel","nofollow"),f(jr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForMaskedLM"),f(us,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/language-modeling#run_mlmpy"),f(us,"rel","nofollow"),f(gs,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling-tf.ipynb"),f(gs,"rel","nofollow"),f(_s,"href","https://huggingface.co/course/chapter7/3?fw=pt"),f(_s,"rel","nofollow"),f(Cr,"href","../tasks/masked_language_modeling"),f(Ar,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForQuestionAnswering"),f(ks,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/question-answering"),f(ks,"rel","nofollow"),f(ws,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering.ipynb"),f(ws,"rel","nofollow"),f(Pr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForQuestionAnswering"),f(vs,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/question-answering"),f(vs,"rel","nofollow"),f(Ts,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering-tf.ipynb"),f(Ts,"rel","nofollow"),f(ys,"href","https://huggingface.co/course/chapter7/7?fw=pt"),f(ys,"rel","nofollow"),f(Lr,"href","../tasks/question_answering"),f(No,"id","transformers.DebertaConfig"),f(No,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(No,"href","#transformers.DebertaConfig"),f(io,"class","relative group"),f(Br,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaModel"),f(Ir,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaModel"),f(Es,"href","https://huggingface.co/microsoft/deberta-base"),f(Es,"rel","nofollow"),f(Sr,"href","/docs/transformers/v4.29.0/en/main_classes/configuration#transformers.PretrainedConfig"),f(Or,"href","/docs/transformers/v4.29.0/en/main_classes/configuration#transformers.PretrainedConfig"),f(_t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Ho,"id","transformers.DebertaTokenizer"),f(Ho,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Ho,"href","#transformers.DebertaTokenizer"),f(co,"class","relative group"),f(Nr,"href","/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizer"),f(Ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Ko,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f($t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Wr,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(he,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Vo,"id","transformers.DebertaTokenizerFast"),f(Vo,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Vo,"href","#transformers.DebertaTokenizerFast"),f(fo,"class","relative group"),f(Hr,"href","/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast"),f(Qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Le,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Zo,"id","transformers.DebertaModel"),f(Zo,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Zo,"href","#transformers.DebertaModel"),f(uo,"class","relative group"),f(Ks,"href","https://arxiv.org/abs/2006.03654"),f(Ks,"rel","nofollow"),f(Vs,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(Vs,"rel","nofollow"),f(Ur,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaModel"),f(Et,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(on,"id","transformers.DebertaPreTrainedModel"),f(on,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(on,"href","#transformers.DebertaPreTrainedModel"),f(_o,"class","relative group"),f(bo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(nn,"id","transformers.DebertaForMaskedLM"),f(nn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(nn,"href","#transformers.DebertaForMaskedLM"),f(ko,"class","relative group"),f(ta,"href","https://arxiv.org/abs/2006.03654"),f(ta,"rel","nofollow"),f(na,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(na,"rel","nofollow"),f(Qr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForMaskedLM"),f(Ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(rn,"id","transformers.DebertaForSequenceClassification"),f(rn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(rn,"href","#transformers.DebertaForSequenceClassification"),f(To,"class","relative group"),f(la,"href","https://arxiv.org/abs/2006.03654"),f(la,"rel","nofollow"),f(ca,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(ca,"rel","nofollow"),f(Kr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForSequenceClassification"),f(ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(pn,"id","transformers.DebertaForTokenClassification"),f(pn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(pn,"href","#transformers.DebertaForTokenClassification"),f($o,"class","relative group"),f(ua,"href","https://arxiv.org/abs/2006.03654"),f(ua,"rel","nofollow"),f(_a,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(_a,"rel","nofollow"),f(Gr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForTokenClassification"),f(qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(it,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(mn,"id","transformers.DebertaForQuestionAnswering"),f(mn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(mn,"href","#transformers.DebertaForQuestionAnswering"),f(Eo,"class","relative group"),f(Ta,"href","https://arxiv.org/abs/2006.03654"),f(Ta,"rel","nofollow"),f($a,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f($a,"rel","nofollow"),f(Vr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.DebertaForQuestionAnswering"),f(xt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(lt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(_n,"id","transformers.TFDebertaModel"),f(_n,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(_n,"href","#transformers.TFDebertaModel"),f(xo,"class","relative group"),f(xa,"href","https://arxiv.org/abs/2006.03654"),f(xa,"rel","nofollow"),f(ja,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(ja,"rel","nofollow"),f(Jr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaModel"),f(zt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(vn,"id","transformers.TFDebertaPreTrainedModel"),f(vn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(vn,"href","#transformers.TFDebertaPreTrainedModel"),f(jo,"class","relative group"),f(jt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Tn,"id","transformers.TFDebertaForMaskedLM"),f(Tn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Tn,"href","#transformers.TFDebertaForMaskedLM"),f(Mo,"class","relative group"),f(Ia,"href","https://arxiv.org/abs/2006.03654"),f(Ia,"rel","nofollow"),f(Oa,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(Oa,"rel","nofollow"),f(Xr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForMaskedLM"),f(ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(ct,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Fn,"id","transformers.TFDebertaForSequenceClassification"),f(Fn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Fn,"href","#transformers.TFDebertaForSequenceClassification"),f(Po,"class","relative group"),f(Qa,"href","https://arxiv.org/abs/2006.03654"),f(Qa,"rel","nofollow"),f(Ga,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(Ga,"rel","nofollow"),f(Yr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForSequenceClassification"),f(mt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Mn,"id","transformers.TFDebertaForTokenClassification"),f(Mn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Mn,"href","#transformers.TFDebertaForTokenClassification"),f(Lo,"class","relative group"),f(Za,"href","https://arxiv.org/abs/2006.03654"),f(Za,"rel","nofollow"),f(tr,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(tr,"rel","nofollow"),f(Zr,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForTokenClassification"),f(ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(nt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Ln,"id","transformers.TFDebertaForQuestionAnswering"),f(Ln,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Ln,"href","#transformers.TFDebertaForQuestionAnswering"),f(Io,"class","relative group"),f(rr,"href","https://arxiv.org/abs/2006.03654"),f(rr,"rel","nofollow"),f(lr,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(lr,"rel","nofollow"),f(ei,"href","/docs/transformers/v4.29.0/en/model_doc/deberta#transformers.TFDebertaForQuestionAnswering"),f(gt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(st,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(o,_){e(document.head,d),g(o,b,_),g(o,m,_),e(m,u),e(u,k),y(l,k,null),e(m,h),e(m,z),e(z,ae),g(o,V,_),g(o,L,_),e(L,oe),e(oe,se),y(F,se,null),e(L,ye),e(L,G),e(G,$e),g(o,_e,_),g(o,S,_),e(S,De),e(S,de),e(de,J),e(S,Ee),g(o,be,_),g(o,Q,_),e(Q,Fe),g(o,ke,_),g(o,K,_),e(K,qe),g(o,we,_),g(o,ne,_),e(ne,M),e(M,C),e(M,ce),e(ce,X),e(M,xe),g(o,ve,_),g(o,B,_),e(B,ze),e(B,pe),e(pe,A),e(B,je),e(B,W),e(W,Me),e(B,Ce),e(B,H),e(H,Ae),e(B,Pe),g(o,I,_),g(o,re,_),e(re,O),e(O,me),y(Z,me,null),e(re,P),e(re,ue),e(ue,R),g(o,Te,_),g(o,fe,_),e(fe,w),g(o,q,_),y(Be,o,_),g(o,ie,_),g(o,le,_),e(le,Ie),e(Ie,j),e(Ie,Se),e(Se,Ke),e(Ie,Ge),e(le,Ve),e(le,Oe),e(Oe,N),e(Oe,U),e(U,Je),e(Oe,Xe),e(le,Y),e(le,ge),e(ge,We),e(We,Re),e(ge,Ye),e(ge,ee),e(ee,Ze),e(ge,Vc),e(ge,os),e(os,Jc),e(ge,Xc),e(le,Yc),e(le,Bt),e(Bt,yr),e(yr,Zc),e(Bt,ep),e(Bt,ns),e(ns,tp),e(Bt,op),e(Bt,ss),e(ss,np),e(Bt,sp),e(le,ap),e(le,Ti),e(Ti,$r),e($r,rp),g(o,Td,_),y(as,o,_),g(o,yd,_),g(o,pt,_),e(pt,It),e(It,Dr),e(Dr,ip),e(It,lp),e(It,rs),e(rs,dp),e(It,cp),e(It,is),e(is,pp),e(It,hp),e(pt,fp),e(pt,St),e(St,Er),e(Er,mp),e(St,up),e(St,ls),e(ls,gp),e(St,_p),e(St,ds),e(ds,bp),e(St,kp),e(pt,wp),e(pt,Fr),e(Fr,cs),e(cs,vp),e(Fr,Tp),e(pt,yp),e(pt,qr),e(qr,ps),e(ps,$p),e(qr,Dp),e(pt,Ep),e(pt,yi),e(yi,xr),e(xr,Fp),g(o,$d,_),y(hs,o,_),g(o,Dd,_),g(o,Tt,_),e(Tt,Ot),e(Ot,zr),e(zr,qp),e(Ot,xp),e(Ot,fs),e(fs,zp),e(Ot,jp),e(Ot,ms),e(ms,Mp),e(Ot,Cp),e(Tt,Ap),e(Tt,Nt),e(Nt,jr),e(jr,Pp),e(Nt,Rp),e(Nt,us),e(us,Lp),e(Nt,Bp),e(Nt,gs),e(gs,Ip),e(Nt,Sp),e(Tt,Op),e(Tt,Mr),e(Mr,_s),e(_s,Np),e(Mr,Wp),e(Tt,Hp),e(Tt,$i),e($i,Cr),e(Cr,Up),g(o,Ed,_),y(bs,o,_),g(o,Fd,_),g(o,yt,_),e(yt,Wt),e(Wt,Ar),e(Ar,Qp),e(Wt,Kp),e(Wt,ks),e(ks,Gp),e(Wt,Vp),e(Wt,ws),e(ws,Jp),e(Wt,Xp),e(yt,Yp),e(yt,Ht),e(Ht,Pr),e(Pr,Zp),e(Ht,eh),e(Ht,vs),e(vs,th),e(Ht,oh),e(Ht,Ts),e(Ts,nh),e(Ht,sh),e(yt,ah),e(yt,Rr),e(Rr,ys),e(ys,rh),e(Rr,ih),e(yt,lh),e(yt,Di),e(Di,Lr),e(Lr,dh),g(o,qd,_),g(o,io,_),e(io,No),e(No,Ei),y($s,Ei,null),e(io,ch),e(io,Fi),e(Fi,ph),g(o,xd,_),g(o,_t,_),y(Ds,_t,null),e(_t,hh),e(_t,Pt),e(Pt,fh),e(Pt,Br),e(Br,mh),e(Pt,uh),e(Pt,Ir),e(Ir,gh),e(Pt,_h),e(Pt,Es),e(Es,bh),e(Pt,kh),e(_t,wh),e(_t,lo),e(lo,vh),e(lo,Sr),e(Sr,Th),e(lo,yh),e(lo,Or),e(Or,$h),e(lo,Dh),e(_t,Eh),y(Wo,_t,null),g(o,zd,_),g(o,co,_),e(co,Ho),e(Ho,qi),y(Fs,qi,null),e(co,Fh),e(co,xi),e(xi,qh),g(o,jd,_),g(o,he,_),y(qs,he,null),e(he,xh),e(he,zi),e(zi,zh),e(he,jh),e(he,ji),e(ji,Mh),e(he,Ch),y(Uo,he,null),e(he,Ah),e(he,xs),e(xs,Ph),e(xs,Mi),e(Mi,Rh),e(xs,Lh),e(he,Bh),y(Qo,he,null),e(he,Ih),e(he,zs),e(zs,Sh),e(zs,Nr),e(Nr,Oh),e(zs,Nh),e(he,Wh),e(he,Ut),y(js,Ut,null),e(Ut,Hh),e(Ut,Ci),e(Ci,Uh),e(Ut,Qh),e(Ut,Ms),e(Ms,Ai),e(Ai,Kh),e(Ms,Gh),e(Ms,Pi),e(Pi,Vh),e(he,Jh),e(he,Ko),y(Cs,Ko,null),e(Ko,Xh),e(Ko,po),e(po,Yh),e(po,Ri),e(Ri,Zh),e(po,ef),e(po,Li),e(Li,tf),e(po,of),e(he,nf),e(he,$t),y(As,$t,null),e($t,sf),e($t,Bi),e(Bi,af),e($t,rf),y(Go,$t,null),e($t,lf),e($t,ho),e(ho,df),e(ho,Ii),e(Ii,cf),e(ho,pf),e(ho,Si),e(Si,hf),e(ho,ff),e(he,mf),e(he,Wr),y(Ps,Wr,null),g(o,Md,_),g(o,fo,_),e(fo,Vo),e(Vo,Oi),y(Rs,Oi,null),e(fo,uf),e(fo,Ni),e(Ni,gf),g(o,Cd,_),g(o,Le,_),y(Ls,Le,null),e(Le,_f),e(Le,Bs),e(Bs,bf),e(Bs,Wi),e(Wi,kf),e(Bs,wf),e(Le,vf),e(Le,Hi),e(Hi,Tf),e(Le,yf),y(Jo,Le,null),e(Le,$f),e(Le,Is),e(Is,Df),e(Is,Ui),e(Ui,Ef),e(Is,Ff),e(Le,qf),y(Xo,Le,null),e(Le,xf),e(Le,Ss),e(Ss,zf),e(Ss,Hr),e(Hr,jf),e(Ss,Mf),e(Le,Cf),e(Le,Qt),y(Os,Qt,null),e(Qt,Af),e(Qt,Qi),e(Qi,Pf),e(Qt,Rf),e(Qt,Ns),e(Ns,Ki),e(Ki,Lf),e(Ns,Bf),e(Ns,Gi),e(Gi,If),e(Le,Sf),e(Le,Dt),y(Ws,Dt,null),e(Dt,Of),e(Dt,Vi),e(Vi,Nf),e(Dt,Wf),y(Yo,Dt,null),e(Dt,Hf),e(Dt,mo),e(mo,Uf),e(mo,Ji),e(Ji,Qf),e(mo,Kf),e(mo,Xi),e(Xi,Gf),e(mo,Vf),g(o,Ad,_),g(o,uo,_),e(uo,Zo),e(Zo,Yi),y(Hs,Yi,null),e(uo,Jf),e(uo,Zi),e(Zi,Xf),g(o,Pd,_),g(o,bt,_),y(Us,bt,null),e(bt,Yf),e(bt,Qs),e(Qs,Zf),e(Qs,Ks),e(Ks,em),e(Qs,tm),e(bt,om),e(bt,Gs),e(Gs,nm),e(Gs,Vs),e(Vs,sm),e(Gs,am),e(bt,rm),e(bt,Et),y(Js,Et,null),e(Et,im),e(Et,go),e(go,lm),e(go,Ur),e(Ur,dm),e(go,cm),e(go,el),e(el,pm),e(go,hm),e(Et,fm),y(en,Et,null),e(Et,mm),y(tn,Et,null),g(o,Rd,_),g(o,_o,_),e(_o,on),e(on,tl),y(Xs,tl,null),e(_o,um),e(_o,ol),e(ol,gm),g(o,Ld,_),g(o,bo,_),y(Ys,bo,null),e(bo,_m),e(bo,nl),e(nl,bm),g(o,Bd,_),g(o,ko,_),e(ko,nn),e(nn,sl),y(Zs,sl,null),e(ko,km),e(ko,al),e(al,wm),g(o,Id,_),g(o,kt,_),y(ea,kt,null),e(kt,vm),e(kt,wo),e(wo,Tm),e(wo,rl),e(rl,ym),e(wo,$m),e(wo,ta),e(ta,Dm),e(wo,Em),e(kt,Fm),e(kt,oa),e(oa,qm),e(oa,na),e(na,xm),e(oa,zm),e(kt,jm),e(kt,Ft),y(sa,Ft,null),e(Ft,Mm),e(Ft,vo),e(vo,Cm),e(vo,Qr),e(Qr,Am),e(vo,Pm),e(vo,il),e(il,Rm),e(vo,Lm),e(Ft,Bm),y(sn,Ft,null),e(Ft,Im),y(an,Ft,null),g(o,Sd,_),g(o,To,_),e(To,rn),e(rn,ll),y(aa,ll,null),e(To,Sm),e(To,dl),e(dl,Om),g(o,Od,_),g(o,rt,_),y(ra,rt,null),e(rt,Nm),e(rt,cl),e(cl,Wm),e(rt,Hm),e(rt,ia),e(ia,Um),e(ia,la),e(la,Qm),e(ia,Km),e(rt,Gm),e(rt,da),e(da,Vm),e(da,ca),e(ca,Jm),e(da,Xm),e(rt,Ym),e(rt,ht),y(pa,ht,null),e(ht,Zm),e(ht,yo),e(yo,eu),e(yo,Kr),e(Kr,tu),e(yo,ou),e(yo,pl),e(pl,nu),e(yo,su),e(ht,au),y(ln,ht,null),e(ht,ru),y(dn,ht,null),e(ht,iu),y(cn,ht,null),g(o,Nd,_),g(o,$o,_),e($o,pn),e(pn,hl),y(ha,hl,null),e($o,lu),e($o,fl),e(fl,du),g(o,Wd,_),g(o,it,_),y(fa,it,null),e(it,cu),e(it,ml),e(ml,pu),e(it,hu),e(it,ma),e(ma,fu),e(ma,ua),e(ua,mu),e(ma,uu),e(it,gu),e(it,ga),e(ga,_u),e(ga,_a),e(_a,bu),e(ga,ku),e(it,wu),e(it,qt),y(ba,qt,null),e(qt,vu),e(qt,Do),e(Do,Tu),e(Do,Gr),e(Gr,yu),e(Do,$u),e(Do,ul),e(ul,Du),e(Do,Eu),e(qt,Fu),y(hn,qt,null),e(qt,qu),y(fn,qt,null),g(o,Hd,_),g(o,Eo,_),e(Eo,mn),e(mn,gl),y(ka,gl,null),e(Eo,xu),e(Eo,_l),e(_l,zu),g(o,Ud,_),g(o,lt,_),y(wa,lt,null),e(lt,ju),e(lt,Fo),e(Fo,Mu),e(Fo,bl),e(bl,Cu),e(Fo,Au),e(Fo,kl),e(kl,Pu),e(Fo,Ru),e(lt,Lu),e(lt,va),e(va,Bu),e(va,Ta),e(Ta,Iu),e(va,Su),e(lt,Ou),e(lt,ya),e(ya,Nu),e(ya,$a),e($a,Wu),e(ya,Hu),e(lt,Uu),e(lt,xt),y(Da,xt,null),e(xt,Qu),e(xt,qo),e(qo,Ku),e(qo,Vr),e(Vr,Gu),e(qo,Vu),e(qo,wl),e(wl,Ju),e(qo,Xu),e(xt,Yu),y(un,xt,null),e(xt,Zu),y(gn,xt,null),g(o,Qd,_),g(o,xo,_),e(xo,_n),e(_n,vl),y(Ea,vl,null),e(xo,eg),e(xo,Tl),e(Tl,tg),g(o,Kd,_),g(o,dt,_),y(Fa,dt,null),e(dt,og),e(dt,qa),e(qa,ng),e(qa,xa),e(xa,sg),e(qa,ag),e(dt,rg),e(dt,za),e(za,ig),e(za,ja),e(ja,lg),e(za,dg),e(dt,cg),y(bn,dt,null),e(dt,pg),e(dt,zt),y(Ma,zt,null),e(zt,hg),e(zt,zo),e(zo,fg),e(zo,Jr),e(Jr,mg),e(zo,ug),e(zo,yl),e(yl,gg),e(zo,_g),e(zt,bg),y(kn,zt,null),e(zt,kg),y(wn,zt,null),g(o,Gd,_),g(o,jo,_),e(jo,vn),e(vn,$l),y(Ca,$l,null),e(jo,wg),e(jo,Dl),e(Dl,vg),g(o,Vd,_),g(o,Rt,_),y(Aa,Rt,null),e(Rt,Tg),e(Rt,El),e(El,yg),e(Rt,$g),e(Rt,jt),y(Pa,jt,null),e(jt,Dg),e(jt,Fl),e(Fl,Eg),e(jt,Fg),e(jt,Ra),e(Ra,qg),e(Ra,ql),e(ql,xg),e(Ra,zg),e(jt,jg),e(jt,wt),e(wt,Mg),e(wt,xl),e(xl,Cg),e(wt,Ag),e(wt,zl),e(zl,Pg),e(wt,Rg),e(wt,jl),e(jl,Lg),e(wt,Bg),e(wt,Ml),e(Ml,Ig),e(wt,Sg),g(o,Jd,_),g(o,Mo,_),e(Mo,Tn),e(Tn,Cl),y(La,Cl,null),e(Mo,Og),e(Mo,Al),e(Al,Ng),g(o,Xd,_),g(o,ct,_),y(Ba,ct,null),e(ct,Wg),e(ct,Co),e(Co,Hg),e(Co,Pl),e(Pl,Ug),e(Co,Qg),e(Co,Ia),e(Ia,Kg),e(Co,Gg),e(ct,Vg),e(ct,Sa),e(Sa,Jg),e(Sa,Oa),e(Oa,Xg),e(Sa,Yg),e(ct,Zg),y(yn,ct,null),e(ct,e_),e(ct,ft),y(Na,ft,null),e(ft,t_),e(ft,Ao),e(Ao,o_),e(Ao,Xr),e(Xr,n_),e(Ao,s_),e(Ao,Rl),e(Rl,a_),e(Ao,r_),e(ft,i_),y($n,ft,null),e(ft,l_),y(Dn,ft,null),e(ft,d_),y(En,ft,null),g(o,Yd,_),g(o,Po,_),e(Po,Fn),e(Fn,Ll),y(Wa,Ll,null),e(Po,c_),e(Po,Bl),e(Bl,p_),g(o,Zd,_),g(o,ot,_),y(Ha,ot,null),e(ot,h_),e(ot,Il),e(Il,f_),e(ot,m_),e(ot,Ua),e(Ua,u_),e(Ua,Qa),e(Qa,g_),e(Ua,__),e(ot,b_),e(ot,Ka),e(Ka,k_),e(Ka,Ga),e(Ga,w_),e(Ka,v_),e(ot,T_),y(qn,ot,null),e(ot,y_),e(ot,mt),y(Va,mt,null),e(mt,$_),e(mt,Ro),e(Ro,D_),e(Ro,Yr),e(Yr,E_),e(Ro,F_),e(Ro,Sl),e(Sl,q_),e(Ro,x_),e(mt,z_),y(xn,mt,null),e(mt,j_),y(zn,mt,null),e(mt,M_),y(jn,mt,null),g(o,ec,_),g(o,Lo,_),e(Lo,Mn),e(Mn,Ol),y(Ja,Ol,null),e(Lo,C_),e(Lo,Nl),e(Nl,A_),g(o,tc,_),g(o,nt,_),y(Xa,nt,null),e(nt,P_),e(nt,Wl),e(Wl,R_),e(nt,L_),e(nt,Ya),e(Ya,B_),e(Ya,Za),e(Za,I_),e(Ya,S_),e(nt,O_),e(nt,er),e(er,N_),e(er,tr),e(tr,W_),e(er,H_),e(nt,U_),y(Cn,nt,null),e(nt,Q_),e(nt,ut),y(or,ut,null),e(ut,K_),e(ut,Bo),e(Bo,G_),e(Bo,Zr),e(Zr,V_),e(Bo,J_),e(Bo,Hl),e(Hl,X_),e(Bo,Y_),e(ut,Z_),y(An,ut,null),e(ut,eb),y(Pn,ut,null),e(ut,tb),y(Rn,ut,null),g(o,oc,_),g(o,Io,_),e(Io,Ln),e(Ln,Ul),y(nr,Ul,null),e(Io,ob),e(Io,Ql),e(Ql,nb),g(o,nc,_),g(o,st,_),y(sr,st,null),e(st,sb),e(st,So),e(So,ab),e(So,Kl),e(Kl,rb),e(So,ib),e(So,Gl),e(Gl,lb),e(So,db),e(st,cb),e(st,ar),e(ar,pb),e(ar,rr),e(rr,hb),e(ar,fb),e(st,mb),e(st,ir),e(ir,ub),e(ir,lr),e(lr,gb),e(ir,_b),e(st,bb),y(Bn,st,null),e(st,kb),e(st,gt),y(dr,gt,null),e(gt,wb),e(gt,Oo),e(Oo,vb),e(Oo,ei),e(ei,Tb),e(Oo,yb),e(Oo,Vl),e(Vl,$b),e(Oo,Db),e(gt,Eb),y(In,gt,null),e(gt,Fb),y(Sn,gt,null),e(gt,qb),y(On,gt,null),sc=!0},p(o,[_]){const cr={};_&2&&(cr.$$scope={dirty:_,ctx:o}),Wo.$set(cr);const Jl={};_&2&&(Jl.$$scope={dirty:_,ctx:o}),Uo.$set(Jl);const Xl={};_&2&&(Xl.$$scope={dirty:_,ctx:o}),Qo.$set(Xl);const Yl={};_&2&&(Yl.$$scope={dirty:_,ctx:o}),Go.$set(Yl);const pr={};_&2&&(pr.$$scope={dirty:_,ctx:o}),Jo.$set(pr);const Zl={};_&2&&(Zl.$$scope={dirty:_,ctx:o}),Xo.$set(Zl);const ed={};_&2&&(ed.$$scope={dirty:_,ctx:o}),Yo.$set(ed);const td={};_&2&&(td.$$scope={dirty:_,ctx:o}),en.$set(td);const hr={};_&2&&(hr.$$scope={dirty:_,ctx:o}),tn.$set(hr);const od={};_&2&&(od.$$scope={dirty:_,ctx:o}),sn.$set(od);const nd={};_&2&&(nd.$$scope={dirty:_,ctx:o}),an.$set(nd);const sd={};_&2&&(sd.$$scope={dirty:_,ctx:o}),ln.$set(sd);const ad={};_&2&&(ad.$$scope={dirty:_,ctx:o}),dn.$set(ad);const fr={};_&2&&(fr.$$scope={dirty:_,ctx:o}),cn.$set(fr);const rd={};_&2&&(rd.$$scope={dirty:_,ctx:o}),hn.$set(rd);const Lt={};_&2&&(Lt.$$scope={dirty:_,ctx:o}),fn.$set(Lt);const id={};_&2&&(id.$$scope={dirty:_,ctx:o}),un.$set(id);const ld={};_&2&&(ld.$$scope={dirty:_,ctx:o}),gn.$set(ld);const dd={};_&2&&(dd.$$scope={dirty:_,ctx:o}),bn.$set(dd);const mr={};_&2&&(mr.$$scope={dirty:_,ctx:o}),kn.$set(mr);const cd={};_&2&&(cd.$$scope={dirty:_,ctx:o}),wn.$set(cd);const pd={};_&2&&(pd.$$scope={dirty:_,ctx:o}),yn.$set(pd);const hd={};_&2&&(hd.$$scope={dirty:_,ctx:o}),$n.$set(hd);const fd={};_&2&&(fd.$$scope={dirty:_,ctx:o}),Dn.$set(fd);const vt={};_&2&&(vt.$$scope={dirty:_,ctx:o}),En.$set(vt);const ur={};_&2&&(ur.$$scope={dirty:_,ctx:o}),qn.$set(ur);const md={};_&2&&(md.$$scope={dirty:_,ctx:o}),xn.$set(md);const gr={};_&2&&(gr.$$scope={dirty:_,ctx:o}),zn.$set(gr);const ud={};_&2&&(ud.$$scope={dirty:_,ctx:o}),jn.$set(ud);const Kt={};_&2&&(Kt.$$scope={dirty:_,ctx:o}),Cn.$set(Kt);const gd={};_&2&&(gd.$$scope={dirty:_,ctx:o}),An.$set(gd);const _d={};_&2&&(_d.$$scope={dirty:_,ctx:o}),Pn.$set(_d);const bd={};_&2&&(bd.$$scope={dirty:_,ctx:o}),Rn.$set(bd);const Gt={};_&2&&(Gt.$$scope={dirty:_,ctx:o}),Bn.$set(Gt);const kd={};_&2&&(kd.$$scope={dirty:_,ctx:o}),In.$set(kd);const wd={};_&2&&(wd.$$scope={dirty:_,ctx:o}),Sn.$set(wd);const vd={};_&2&&(vd.$$scope={dirty:_,ctx:o}),On.$set(vd)},i(o){sc||($(l.$$.fragment,o),$(F.$$.fragment,o),$(Z.$$.fragment,o),$(Be.$$.fragment,o),$(as.$$.fragment,o),$(hs.$$.fragment,o),$(bs.$$.fragment,o),$($s.$$.fragment,o),$(Ds.$$.fragment,o),$(Wo.$$.fragment,o),$(Fs.$$.fragment,o),$(qs.$$.fragment,o),$(Uo.$$.fragment,o),$(Qo.$$.fragment,o),$(js.$$.fragment,o),$(Cs.$$.fragment,o),$(As.$$.fragment,o),$(Go.$$.fragment,o),$(Ps.$$.fragment,o),$(Rs.$$.fragment,o),$(Ls.$$.fragment,o),$(Jo.$$.fragment,o),$(Xo.$$.fragment,o),$(Os.$$.fragment,o),$(Ws.$$.fragment,o),$(Yo.$$.fragment,o),$(Hs.$$.fragment,o),$(Us.$$.fragment,o),$(Js.$$.fragment,o),$(en.$$.fragment,o),$(tn.$$.fragment,o),$(Xs.$$.fragment,o),$(Ys.$$.fragment,o),$(Zs.$$.fragment,o),$(ea.$$.fragment,o),$(sa.$$.fragment,o),$(sn.$$.fragment,o),$(an.$$.fragment,o),$(aa.$$.fragment,o),$(ra.$$.fragment,o),$(pa.$$.fragment,o),$(ln.$$.fragment,o),$(dn.$$.fragment,o),$(cn.$$.fragment,o),$(ha.$$.fragment,o),$(fa.$$.fragment,o),$(ba.$$.fragment,o),$(hn.$$.fragment,o),$(fn.$$.fragment,o),$(ka.$$.fragment,o),$(wa.$$.fragment,o),$(Da.$$.fragment,o),$(un.$$.fragment,o),$(gn.$$.fragment,o),$(Ea.$$.fragment,o),$(Fa.$$.fragment,o),$(bn.$$.fragment,o),$(Ma.$$.fragment,o),$(kn.$$.fragment,o),$(wn.$$.fragment,o),$(Ca.$$.fragment,o),$(Aa.$$.fragment,o),$(Pa.$$.fragment,o),$(La.$$.fragment,o),$(Ba.$$.fragment,o),$(yn.$$.fragment,o),$(Na.$$.fragment,o),$($n.$$.fragment,o),$(Dn.$$.fragment,o),$(En.$$.fragment,o),$(Wa.$$.fragment,o),$(Ha.$$.fragment,o),$(qn.$$.fragment,o),$(Va.$$.fragment,o),$(xn.$$.fragment,o),$(zn.$$.fragment,o),$(jn.$$.fragment,o),$(Ja.$$.fragment,o),$(Xa.$$.fragment,o),$(Cn.$$.fragment,o),$(or.$$.fragment,o),$(An.$$.fragment,o),$(Pn.$$.fragment,o),$(Rn.$$.fragment,o),$(nr.$$.fragment,o),$(sr.$$.fragment,o),$(Bn.$$.fragment,o),$(dr.$$.fragment,o),$(In.$$.fragment,o),$(Sn.$$.fragment,o),$(On.$$.fragment,o),sc=!0)},o(o){D(l.$$.fragment,o),D(F.$$.fragment,o),D(Z.$$.fragment,o),D(Be.$$.fragment,o),D(as.$$.fragment,o),D(hs.$$.fragment,o),D(bs.$$.fragment,o),D($s.$$.fragment,o),D(Ds.$$.fragment,o),D(Wo.$$.fragment,o),D(Fs.$$.fragment,o),D(qs.$$.fragment,o),D(Uo.$$.fragment,o),D(Qo.$$.fragment,o),D(js.$$.fragment,o),D(Cs.$$.fragment,o),D(As.$$.fragment,o),D(Go.$$.fragment,o),D(Ps.$$.fragment,o),D(Rs.$$.fragment,o),D(Ls.$$.fragment,o),D(Jo.$$.fragment,o),D(Xo.$$.fragment,o),D(Os.$$.fragment,o),D(Ws.$$.fragment,o),D(Yo.$$.fragment,o),D(Hs.$$.fragment,o),D(Us.$$.fragment,o),D(Js.$$.fragment,o),D(en.$$.fragment,o),D(tn.$$.fragment,o),D(Xs.$$.fragment,o),D(Ys.$$.fragment,o),D(Zs.$$.fragment,o),D(ea.$$.fragment,o),D(sa.$$.fragment,o),D(sn.$$.fragment,o),D(an.$$.fragment,o),D(aa.$$.fragment,o),D(ra.$$.fragment,o),D(pa.$$.fragment,o),D(ln.$$.fragment,o),D(dn.$$.fragment,o),D(cn.$$.fragment,o),D(ha.$$.fragment,o),D(fa.$$.fragment,o),D(ba.$$.fragment,o),D(hn.$$.fragment,o),D(fn.$$.fragment,o),D(ka.$$.fragment,o),D(wa.$$.fragment,o),D(Da.$$.fragment,o),D(un.$$.fragment,o),D(gn.$$.fragment,o),D(Ea.$$.fragment,o),D(Fa.$$.fragment,o),D(bn.$$.fragment,o),D(Ma.$$.fragment,o),D(kn.$$.fragment,o),D(wn.$$.fragment,o),D(Ca.$$.fragment,o),D(Aa.$$.fragment,o),D(Pa.$$.fragment,o),D(La.$$.fragment,o),D(Ba.$$.fragment,o),D(yn.$$.fragment,o),D(Na.$$.fragment,o),D($n.$$.fragment,o),D(Dn.$$.fragment,o),D(En.$$.fragment,o),D(Wa.$$.fragment,o),D(Ha.$$.fragment,o),D(qn.$$.fragment,o),D(Va.$$.fragment,o),D(xn.$$.fragment,o),D(zn.$$.fragment,o),D(jn.$$.fragment,o),D(Ja.$$.fragment,o),D(Xa.$$.fragment,o),D(Cn.$$.fragment,o),D(or.$$.fragment,o),D(An.$$.fragment,o),D(Pn.$$.fragment,o),D(Rn.$$.fragment,o),D(nr.$$.fragment,o),D(sr.$$.fragment,o),D(Bn.$$.fragment,o),D(dr.$$.fragment,o),D(In.$$.fragment,o),D(Sn.$$.fragment,o),D(On.$$.fragment,o),sc=!1},d(o){t(d),o&&t(b),o&&t(m),E(l),o&&t(V),o&&t(L),E(F),o&&t(_e),o&&t(S),o&&t(be),o&&t(Q),o&&t(ke),o&&t(K),o&&t(we),o&&t(ne),o&&t(ve),o&&t(B),o&&t(I),o&&t(re),E(Z),o&&t(Te),o&&t(fe),o&&t(q),E(Be,o),o&&t(ie),o&&t(le),o&&t(Td),E(as,o),o&&t(yd),o&&t(pt),o&&t($d),E(hs,o),o&&t(Dd),o&&t(Tt),o&&t(Ed),E(bs,o),o&&t(Fd),o&&t(yt),o&&t(qd),o&&t(io),E($s),o&&t(xd),o&&t(_t),E(Ds),E(Wo),o&&t(zd),o&&t(co),E(Fs),o&&t(jd),o&&t(he),E(qs),E(Uo),E(Qo),E(js),E(Cs),E(As),E(Go),E(Ps),o&&t(Md),o&&t(fo),E(Rs),o&&t(Cd),o&&t(Le),E(Ls),E(Jo),E(Xo),E(Os),E(Ws),E(Yo),o&&t(Ad),o&&t(uo),E(Hs),o&&t(Pd),o&&t(bt),E(Us),E(Js),E(en),E(tn),o&&t(Rd),o&&t(_o),E(Xs),o&&t(Ld),o&&t(bo),E(Ys),o&&t(Bd),o&&t(ko),E(Zs),o&&t(Id),o&&t(kt),E(ea),E(sa),E(sn),E(an),o&&t(Sd),o&&t(To),E(aa),o&&t(Od),o&&t(rt),E(ra),E(pa),E(ln),E(dn),E(cn),o&&t(Nd),o&&t($o),E(ha),o&&t(Wd),o&&t(it),E(fa),E(ba),E(hn),E(fn),o&&t(Hd),o&&t(Eo),E(ka),o&&t(Ud),o&&t(lt),E(wa),E(Da),E(un),E(gn),o&&t(Qd),o&&t(xo),E(Ea),o&&t(Kd),o&&t(dt),E(Fa),E(bn),E(Ma),E(kn),E(wn),o&&t(Gd),o&&t(jo),E(Ca),o&&t(Vd),o&&t(Rt),E(Aa),E(Pa),o&&t(Jd),o&&t(Mo),E(La),o&&t(Xd),o&&t(ct),E(Ba),E(yn),E(Na),E($n),E(Dn),E(En),o&&t(Yd),o&&t(Po),E(Wa),o&&t(Zd),o&&t(ot),E(Ha),E(qn),E(Va),E(xn),E(zn),E(jn),o&&t(ec),o&&t(Lo),E(Ja),o&&t(tc),o&&t(nt),E(Xa),E(Cn),E(or),E(An),E(Pn),E(Rn),o&&t(oc),o&&t(Io),E(nr),o&&t(nc),o&&t(st),E(sr),E(Bn),E(dr),E(In),E(Sn),E(On)}}}const vT={local:"deberta",sections:[{local:"overview",title:"Overview"},{local:"resources",title:"Resources"},{local:"transformers.DebertaConfig",title:"DebertaConfig"},{local:"transformers.DebertaTokenizer",title:"DebertaTokenizer"},{local:"transformers.DebertaTokenizerFast",title:"DebertaTokenizerFast"},{local:"transformers.DebertaModel",title:"DebertaModel"},{local:"transformers.DebertaPreTrainedModel",title:"DebertaPreTrainedModel"},{local:"transformers.DebertaForMaskedLM",title:"DebertaForMaskedLM"},{local:"transformers.DebertaForSequenceClassification",title:"DebertaForSequenceClassification"},{local:"transformers.DebertaForTokenClassification",title:"DebertaForTokenClassification"},{local:"transformers.DebertaForQuestionAnswering",title:"DebertaForQuestionAnswering"},{local:"transformers.TFDebertaModel",title:"TFDebertaModel"},{local:"transformers.TFDebertaPreTrainedModel",title:"TFDebertaPreTrainedModel"},{local:"transformers.TFDebertaForMaskedLM",title:"TFDebertaForMaskedLM"},{local:"transformers.TFDebertaForSequenceClassification",title:"TFDebertaForSequenceClassification"},{local:"transformers.TFDebertaForTokenClassification",title:"TFDebertaForTokenClassification"},{local:"transformers.TFDebertaForQuestionAnswering",title:"TFDebertaForQuestionAnswering"}],title:"DeBERTa"};function TT(x){return Rv(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class zT extends Mv{constructor(d){super();Cv(this,d,TT,wT,Av,{})}}export{zT as default,vT as metadata};
