import{S as $5,i as y5,s as D5,e as r,k as p,w,t as o,M as F5,c as a,d as t,m as h,a as i,x as T,h as s,b as c,G as e,g as _,y as $,q as y,o as D,B as F,v as E5,L as ue}from"../../chunks/vendor-hf-doc-builder.js";import{T as Se}from"../../chunks/Tip-hf-doc-builder.js";import{D as Y}from"../../chunks/Docstring-hf-doc-builder.js";import{C as me}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ne}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as fe}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";import{P as Sg}from"../../chunks/PipelineTag-hf-doc-builder.js";function B5(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertConfig, DistilBertModel

# Initializing a DistilBERT configuration
configuration = DistilBertConfig()

# Initializing a model (with random weights) from the configuration
model = DistilBertModel(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> DistilBertConfig, DistilBertModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a DistilBERT configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = DistilBertConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertModel(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=r("p"),b=o("Examples:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Examples:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function x5(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function M5(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, DistilBertModel
import torch

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = DistilBertModel.from_pretrained("distilbert-base-uncased")

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> DistilBertTokenizer, DistilBertModel
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertModel.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function z5(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function j5(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, DistilBertForMaskedLM
import torch

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = DistilBertForMaskedLM.from_pretrained("distilbert-base-uncased")

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)
`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, DistilBertForMaskedLM
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertForMaskedLM.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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)
`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function C5(B){let d,b;return d=new me({props:{code:`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>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>)
`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){$(d,f,m),b=!0},p:ue,i(f){b||(y(d.$$.fragment,f),b=!0)},o(f){D(d.$$.fragment,f),b=!1},d(f){F(d,f)}}}function P5(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function q5(B){let d,b,f,m,v;return m=new me({props:{code:`import torch
from transformers import DistilBertTokenizer, DistilBertForSequenceClassification

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = DistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased")

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

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

predicted_class_id = logits.argmax().item()
model.config.id2label[predicted_class_id]
`,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> DistilBertTokenizer, DistilBertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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>model.config.id2label[predicted_class_id]
`}}),{c(){d=r("p"),b=o("Example of single-label classification:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example of single-label classification:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function A5(B){let d,b;return d=new me({props:{code:`# 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 = DistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased", num_labels=num_labels)

labels = torch.tensor([1])
loss = model(**inputs, labels=labels).loss
round(loss.item(), 2)
`,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>
<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 = DistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(loss.item(), <span class="hljs-number">2</span>)
`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){$(d,f,m),b=!0},p:ue,i(f){b||(y(d.$$.fragment,f),b=!0)},o(f){D(d.$$.fragment,f),b=!1},d(f){F(d,f)}}}function O5(B){let d,b,f,m,v;return m=new me({props:{code:`import torch
from transformers import DistilBertTokenizer, DistilBertForSequenceClassification

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = DistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased", 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_id = logits.argmax().item()
model.config.id2label[predicted_class_id]
`,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> DistilBertTokenizer, DistilBertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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_id = logits.argmax().item()
<span class="hljs-meta">&gt;&gt;&gt; </span>model.config.id2label[predicted_class_id]
`}}),{c(){d=r("p"),b=o("Example of multi-label classification:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example of multi-label classification:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function L5(B){let d,b;return d=new me({props:{code:`# 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 = DistilBertForSequenceClassification.from_pretrained(
    "distilbert-base-uncased", num_labels=num_labels, problem_type="multi_label_classification"
)

labels = torch.nn.functional.one_hot(torch.tensor([predicted_class_id]), num_classes=num_labels).to(
    torch.float
)
loss = model(**inputs, labels=labels).loss
loss.backward()`,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>
<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 = DistilBertForSequenceClassification.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;distilbert-base-uncased&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.nn.functional.one_hot(torch.tensor([predicted_class_id]), num_classes=num_labels).to(
<span class="hljs-meta">... </span>    torch.<span class="hljs-built_in">float</span>
<span class="hljs-meta">... </span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss
<span class="hljs-meta">&gt;&gt;&gt; </span>loss.backward()`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){$(d,f,m),b=!0},p:ue,i(f){b||(y(d.$$.fragment,f),b=!0)},o(f){D(d.$$.fragment,f),b=!1},d(f){F(d,f)}}}function I5(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function S5(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, DistilBertForMultipleChoice
import torch

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-cased")
model = DistilBertForMultipleChoice.from_pretrained("distilbert-base-cased")

prompt = "In Italy, pizza served in formal settings, such as at a restaurant, is presented unsliced."
choice0 = "It is eaten with a fork and a knife."
choice1 = "It is eaten while held in the hand."
labels = torch.tensor(0).unsqueeze(0)  # choice0 is correct (according to Wikipedia ;)), batch size 1

encoding = tokenizer([[prompt, choice0], [prompt, choice1]], return_tensors="pt", padding=True)
outputs = model(**{k: v.unsqueeze(0) for k, v in encoding.items()}, labels=labels)  # batch size is 1

# the linear classifier still needs to be trained
loss = outputs.loss
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, DistilBertForMultipleChoice
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-cased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;distilbert-base-cased&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;In Italy, pizza served in formal settings, such as at a restaurant, is presented unsliced.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>choice0 = <span class="hljs-string">&quot;It is eaten with a fork and a knife.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>choice1 = <span class="hljs-string">&quot;It is eaten while held in the hand.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.tensor(<span class="hljs-number">0</span>).unsqueeze(<span class="hljs-number">0</span>)  <span class="hljs-comment"># choice0 is correct (according to Wikipedia ;)), batch size 1</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>encoding = tokenizer([[prompt, choice0], [prompt, choice1]], return_tensors=<span class="hljs-string">&quot;pt&quot;</span>, padding=<span class="hljs-literal">True</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**{k: v.unsqueeze(<span class="hljs-number">0</span>) <span class="hljs-keyword">for</span> k, v <span class="hljs-keyword">in</span> encoding.items()}, labels=labels)  <span class="hljs-comment"># batch size is 1</span>

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># the linear classifier still needs to be trained</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),{c(){d=r("p"),b=o("Examples:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Examples:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function N5(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function R5(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, DistilBertForTokenClassification
import torch

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = DistilBertForTokenClassification.from_pretrained("distilbert-base-uncased")

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]]
predicted_tokens_classes
`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, DistilBertForTokenClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertForTokenClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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>predicted_tokens_classes
`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function W5(B){let d,b;return d=new me({props:{code:`labels = predicted_token_class_ids
loss = model(**inputs, labels=labels).loss
round(loss.item(), 2)
`,highlighted:`<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
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(loss.item(), <span class="hljs-number">2</span>)
`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){$(d,f,m),b=!0},p:ue,i(f){b||(y(d.$$.fragment,f),b=!0)},o(f){D(d.$$.fragment,f),b=!1},d(f){F(d,f)}}}function Q5(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function U5(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, DistilBertForQuestionAnswering
import torch

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = DistilBertForQuestionAnswering.from_pretrained("distilbert-base-uncased")

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)
`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, DistilBertForQuestionAnswering
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = DistilBertForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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>)
`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function H5(B){let d,b;return d=new me({props:{code:`# target is "nice puppet"
target_start_index = torch.tensor([14])
target_end_index = torch.tensor([15])

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

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = TFDistilBertModel.from_pretrained("distilbert-base-uncased")

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

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = TFDistilBertForMaskedLM.from_pretrained("distilbert-base-uncased")

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

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = TFDistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased")

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])
model.config.id2label[predicted_class_id]
`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, TFDistilBertForSequenceClassification
<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 = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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>])
<span class="hljs-meta">&gt;&gt;&gt; </span>model.config.id2label[predicted_class_id]
`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function sM(B){let d,b;return d=new me({props:{code:`# 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 = TFDistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased", num_labels=num_labels)

labels = tf.constant(1)
loss = model(**inputs, labels=labels).loss
round(float(loss), 2)
`,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>
<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 = TFDistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>, num_labels=num_labels)

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

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = TFDistilBertForMultipleChoice.from_pretrained("distilbert-base-uncased")

prompt = "In Italy, pizza served in formal settings, such as at a restaurant, is presented unsliced."
choice0 = "It is eaten with a fork and a knife."
choice1 = "It is eaten while held in the hand."

encoding = tokenizer([prompt, prompt], [choice0, choice1], return_tensors="tf", padding=True)
inputs = {k: tf.expand_dims(v, 0) for k, v in encoding.items()}
outputs = model(inputs)  # batch size is 1

# the linear classifier still needs to be trained
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, TFDistilBertForMultipleChoice
<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 = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDistilBertForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;In Italy, pizza served in formal settings, such as at a restaurant, is presented unsliced.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>choice0 = <span class="hljs-string">&quot;It is eaten with a fork and a knife.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>choice1 = <span class="hljs-string">&quot;It is eaten while held in the hand.&quot;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>encoding = tokenizer([prompt, prompt], [choice0, choice1], return_tensors=<span class="hljs-string">&quot;tf&quot;</span>, padding=<span class="hljs-literal">True</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = {k: tf.expand_dims(v, <span class="hljs-number">0</span>) <span class="hljs-keyword">for</span> k, v <span class="hljs-keyword">in</span> encoding.items()}
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(inputs)  <span class="hljs-comment"># batch size is 1</span>

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

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = TFDistilBertForTokenClassification.from_pretrained("distilbert-base-uncased")

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

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = TFDistilBertForQuestionAnswering.from_pretrained("distilbert-base-uncased")

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]
tokenizer.decode(predict_answer_tokens)
`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, TFDistilBertForQuestionAnswering
<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 = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDistilBertForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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>]
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predict_answer_tokens)
`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function uM(B){let d,b;return d=new me({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)
round(float(loss), 2)
`,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)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(<span class="hljs-built_in">float</span>(loss), <span class="hljs-number">2</span>)
`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){$(d,f,m),b=!0},p:ue,i(f){b||(y(d.$$.fragment,f),b=!0)},o(f){D(d.$$.fragment,f),b=!1},d(f){F(d,f)}}}function mM(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function gM(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, FlaxDistilBertModel

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = FlaxDistilBertModel.from_pretrained("distilbert-base-uncased")

inputs = tokenizer("Hello, my dog is cute", return_tensors="jax")
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> DistilBertTokenizer, FlaxDistilBertModel

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxDistilBertModel.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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;jax&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=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function _M(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function bM(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, FlaxDistilBertForMaskedLM

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = FlaxDistilBertForMaskedLM.from_pretrained("distilbert-base-uncased")

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

outputs = model(**inputs)
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, FlaxDistilBertForMaskedLM

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxDistilBertForMaskedLM.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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;jax&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function vM(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function kM(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, FlaxDistilBertForSequenceClassification

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = FlaxDistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased")

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

outputs = model(**inputs)
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, FlaxDistilBertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxDistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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;jax&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function wM(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function TM(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, FlaxDistilBertForMultipleChoice

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = FlaxDistilBertForMultipleChoice.from_pretrained("distilbert-base-uncased")

prompt = "In Italy, pizza served in formal settings, such as at a restaurant, is presented unsliced."
choice0 = "It is eaten with a fork and a knife."
choice1 = "It is eaten while held in the hand."

encoding = tokenizer([prompt, prompt], [choice0, choice1], return_tensors="jax", padding=True)
outputs = model(**{k: v[None, :] for k, v in encoding.items()})

logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, FlaxDistilBertForMultipleChoice

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxDistilBertForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;In Italy, pizza served in formal settings, such as at a restaurant, is presented unsliced.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>choice0 = <span class="hljs-string">&quot;It is eaten with a fork and a knife.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>choice1 = <span class="hljs-string">&quot;It is eaten while held in the hand.&quot;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>encoding = tokenizer([prompt, prompt], [choice0, choice1], return_tensors=<span class="hljs-string">&quot;jax&quot;</span>, padding=<span class="hljs-literal">True</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**{k: v[<span class="hljs-literal">None</span>, :] <span class="hljs-keyword">for</span> k, v <span class="hljs-keyword">in</span> encoding.items()})

<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function $M(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function yM(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, FlaxDistilBertForTokenClassification

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = FlaxDistilBertForTokenClassification.from_pretrained("distilbert-base-uncased")

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

outputs = model(**inputs)
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, FlaxDistilBertForTokenClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxDistilBertForTokenClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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;jax&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function DM(B){let d,b,f,m,v;return{c(){d=r("p"),b=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r("code"),m=o("Module"),v=o(`
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=a(l,"P",{});var u=i(d);b=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(u,"CODE",{});var M=i(f);m=s(M,"Module"),M.forEach(t),v=s(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(l,u){_(l,d,u),e(d,b),e(d,f),e(f,m),e(d,v)},d(l){l&&t(d)}}}function FM(B){let d,b,f,m,v;return m=new me({props:{code:`from transformers import DistilBertTokenizer, FlaxDistilBertForQuestionAnswering

tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
model = FlaxDistilBertForQuestionAnswering.from_pretrained("distilbert-base-uncased")

question, text = "Who was Jim Henson?", "Jim Henson was a nice puppet"
inputs = tokenizer(question, text, return_tensors="jax")

outputs = model(**inputs)
start_scores = outputs.start_logits
end_scores = outputs.end_logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DistilBertTokenizer, FlaxDistilBertForQuestionAnswering

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = DistilBertTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxDistilBertForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&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;jax&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>start_scores = outputs.start_logits
<span class="hljs-meta">&gt;&gt;&gt; </span>end_scores = outputs.end_logits`}}),{c(){d=r("p"),b=o("Example:"),f=p(),w(m.$$.fragment)},l(l){d=a(l,"P",{});var u=i(d);b=s(u,"Example:"),u.forEach(t),f=h(l),T(m.$$.fragment,l)},m(l,u){_(l,d,u),e(d,b),_(l,f,u),$(m,l,u),v=!0},p:ue,i(l){v||(y(m.$$.fragment,l),v=!0)},o(l){D(m.$$.fragment,l),v=!1},d(l){l&&t(d),l&&t(f),F(m,l)}}}function EM(B){let d,b,f,m,v,l,u,M,we,ge,I,re,oe,E,Te,Q,$e,_e,O,ye,ae,H,De,ie,K,Fe,de,V,Ee,be,ee,j,q,le,U,Be,ve,W,xe,ke,C,se,J,ce,Me,G,pe,ze,S,he,X,je,ne,P,Ce,A,Pe,qe,k,x,He,Z,Ke,Ve,z,Je,Ge,Le,Xe,Ye,L,N,Oe,Re,R,Ze,We,Ae,Ue,te,et,gu,Er,_u,Ie,Br,Ng,xr,Rg,Wg,Qg,Mr,Ug,zr,Hg,Kg,Vg,jr,Jg,Cr,Gg,Xg,Yg,Pr,Zg,qr,e_,t_,o_,Ar,s_,Or,n_,r_,a_,Lr,i_,Ir,l_,d_,c_,Sr,p_,Nr,h_,f_,u_,fo,Nd,m_,g_,Rr,__,b_,Wr,v_,k_,w_,uo,Rd,T_,$_,Qr,y_,D_,Ur,F_,E_,B_,mo,Wd,x_,M_,Hr,z_,j_,Kr,C_,P_,bu,Vr,vu,Ot,go,Qd,q_,A_,Jr,O_,L_,Gr,I_,S_,N_,_o,Ud,R_,W_,Xr,Q_,U_,Yr,H_,K_,V_,zs,Hd,J_,G_,Zr,X_,Y_,Z_,Kd,ea,eb,tb,ku,ta,wu,Lt,bo,Vd,ob,sb,oa,nb,rb,sa,ab,ib,lb,vo,Jd,db,cb,na,pb,hb,ra,fb,ub,mb,ko,Gd,gb,_b,aa,bb,vb,ia,kb,wb,Tb,Xd,la,$b,yb,Tu,da,$u,It,wo,Yd,Db,Fb,ca,Eb,Bb,pa,xb,Mb,zb,To,Zd,jb,Cb,ha,Pb,qb,fa,Ab,Ob,Lb,js,ec,Ib,Sb,ua,Nb,Rb,Wb,tc,ma,Qb,Ub,yu,oc,bp,Hb,Du,Cs,$o,sc,Kb,Vb,ga,Jb,Gb,_a,Xb,Yb,Zb,yo,nc,ev,tv,ba,ov,sv,va,nv,rv,Fu,rc,av,Eu,Do,ka,iv,wa,lv,dv,cv,Ta,pv,$a,hv,fv,uv,ya,mv,Da,gv,_v,Bu,ac,bv,xu,Ps,Fa,vv,Ea,kv,wv,Tv,Ba,$v,xa,yv,Dv,Mu,ic,Fv,zu,Fo,Ma,Ev,za,Bv,xv,Mv,ja,zv,Ca,jv,Cv,Pv,Pa,qv,qa,Av,Ov,ju,Ro,qs,vp,Aa,Lv,kp,Iv,Cu,Pt,Oa,Sv,oo,Nv,lc,Rv,Wv,dc,Qv,Uv,La,Hv,Kv,Vv,Wo,Jv,cc,Gv,Xv,pc,Yv,Zv,ek,As,Pu,Qo,Os,wp,Ia,tk,Tp,ok,qu,qt,Sa,sk,$p,nk,rk,Ls,hc,ak,ik,fc,lk,dk,ck,Na,pk,uc,hk,fk,Au,Uo,Is,yp,Ra,uk,Dp,mk,Ou,At,Wa,gk,Qa,_k,Fp,bk,vk,kk,Ss,mc,wk,Tk,gc,$k,yk,Dk,Ua,Fk,_c,Ek,Bk,Lu,Ho,Ns,Ep,Ha,xk,Bp,Mk,Iu,ut,Ka,zk,xp,jk,Ck,Va,Pk,bc,qk,Ak,Ok,Ja,Lk,Ga,Ik,Sk,Nk,St,Xa,Rk,Ko,Wk,vc,Qk,Uk,Mp,Hk,Kk,Vk,Rs,Jk,Ws,Su,Vo,Qs,zp,Ya,Gk,jp,Xk,Nu,mt,Za,Yk,ei,Zk,Cp,ew,tw,ow,ti,sw,kc,nw,rw,aw,oi,iw,si,lw,dw,cw,kt,ni,pw,Jo,hw,wc,fw,uw,Pp,mw,gw,_w,Us,bw,Hs,vw,Ks,Ru,Go,Vs,qp,ri,kw,Ap,ww,Wu,gt,ai,Tw,Op,$w,yw,ii,Dw,Tc,Fw,Ew,Bw,li,xw,di,Mw,zw,jw,it,ci,Cw,Xo,Pw,$c,qw,Aw,Lp,Ow,Lw,Iw,Js,Sw,Gs,Nw,Xs,Rw,Ys,Ww,Zs,Qu,Yo,en,Ip,pi,Qw,Sp,Uw,Uu,_t,hi,Hw,Np,Kw,Vw,fi,Jw,yc,Gw,Xw,Yw,ui,Zw,mi,e1,t1,o1,Nt,gi,s1,Zo,n1,Dc,r1,a1,Rp,i1,l1,d1,tn,c1,on,Hu,es,sn,Wp,_i,p1,Qp,h1,Ku,bt,bi,f1,Up,u1,m1,vi,g1,Fc,_1,b1,v1,ki,k1,wi,w1,T1,$1,wt,Ti,y1,ts,D1,Ec,F1,E1,Hp,B1,x1,M1,nn,z1,rn,j1,an,Vu,os,ln,Kp,$i,C1,Vp,P1,Ju,vt,yi,q1,ss,A1,Jp,O1,L1,Gp,I1,S1,N1,Di,R1,Bc,W1,Q1,U1,Fi,H1,Ei,K1,V1,J1,Tt,Bi,G1,ns,X1,xc,Y1,Z1,Xp,eT,tT,oT,dn,sT,cn,nT,pn,Gu,rs,hn,Yp,xi,rT,Zp,aT,Xu,lt,Mi,iT,eh,lT,dT,zi,cT,Mc,pT,hT,fT,ji,uT,Ci,mT,gT,_T,fn,bT,Rt,Pi,vT,as,kT,zc,wT,TT,th,$T,yT,DT,un,FT,mn,Yu,is,gn,oh,qi,ET,sh,BT,Zu,dt,Ai,xT,Oi,MT,nh,zT,jT,CT,Li,PT,jc,qT,AT,OT,Ii,LT,Si,IT,ST,NT,_n,RT,$t,Ni,WT,ls,QT,Cc,UT,HT,rh,KT,VT,JT,bn,GT,vn,XT,kn,em,ds,wn,ah,Ri,YT,ih,ZT,tm,ct,Wi,e$,lh,t$,o$,Qi,s$,Pc,n$,r$,a$,Ui,i$,Hi,l$,d$,c$,Tn,p$,yt,Ki,h$,cs,f$,qc,u$,m$,dh,g$,_$,b$,$n,v$,yn,k$,Dn,om,ps,Fn,ch,Vi,w$,ph,T$,sm,pt,Ji,$$,hh,y$,D$,Gi,F$,Ac,E$,B$,x$,Xi,M$,Yi,z$,j$,C$,En,P$,Wt,Zi,q$,hs,A$,Oc,O$,L$,fh,I$,S$,N$,Bn,R$,xn,nm,fs,Mn,uh,el,W$,mh,Q$,rm,ht,tl,U$,gh,H$,K$,ol,V$,Lc,J$,G$,X$,sl,Y$,nl,Z$,ey,ty,zn,oy,Dt,rl,sy,us,ny,Ic,ry,ay,_h,iy,ly,dy,jn,cy,Cn,py,Pn,am,ms,qn,bh,al,hy,vh,fy,im,ft,il,uy,gs,my,kh,gy,_y,wh,by,vy,ky,ll,wy,Sc,Ty,$y,yy,dl,Dy,cl,Fy,Ey,By,An,xy,Ft,pl,My,_s,zy,Nc,jy,Cy,Th,Py,qy,Ay,On,Oy,Ln,Ly,In,lm,bs,Sn,$h,hl,Iy,yh,Sy,dm,tt,fl,Ny,Dh,Ry,Wy,ul,Qy,Rc,Uy,Hy,Ky,ml,Vy,gl,Jy,Gy,Xy,Fh,Yy,Zy,so,Eh,_l,e2,t2,Bh,bl,o2,s2,xh,vl,n2,r2,Mh,kl,a2,i2,Qt,wl,l2,vs,d2,zh,c2,p2,jh,h2,f2,u2,Nn,m2,Rn,cm,ks,Wn,Ch,Tl,g2,Ph,_2,pm,ot,$l,b2,yl,v2,qh,k2,w2,T2,Dl,$2,Wc,y2,D2,F2,Fl,E2,El,B2,x2,M2,Ah,z2,j2,no,Oh,Bl,C2,P2,Lh,xl,q2,A2,Ih,Ml,O2,L2,Sh,zl,I2,S2,Ut,jl,N2,ws,R2,Nh,W2,Q2,Rh,U2,H2,K2,Qn,V2,Un,hm,Ts,Hn,Wh,Cl,J2,Qh,G2,fm,st,Pl,X2,Uh,Y2,Z2,ql,eD,Qc,tD,oD,sD,Al,nD,Ol,rD,aD,iD,Hh,lD,dD,ro,Kh,Ll,cD,pD,Vh,Il,hD,fD,Jh,Sl,uD,mD,Gh,Nl,gD,_D,Ht,Rl,bD,$s,vD,Xh,kD,wD,Yh,TD,$D,yD,Kn,DD,Vn,um,ys,Jn,Zh,Wl,FD,ef,ED,mm,nt,Ql,BD,tf,xD,MD,Ul,zD,Uc,jD,CD,PD,Hl,qD,Kl,AD,OD,LD,of,ID,SD,ao,sf,Vl,ND,RD,nf,Jl,WD,QD,rf,Gl,UD,HD,af,Xl,KD,VD,Kt,Yl,JD,Ds,GD,lf,XD,YD,df,ZD,eF,tF,Gn,oF,Xn,gm,Fs,Yn,cf,Zl,sF,pf,nF,_m,rt,ed,rF,hf,aF,iF,td,lF,Hc,dF,cF,pF,od,hF,sd,fF,uF,mF,ff,gF,_F,io,uf,nd,bF,vF,mf,rd,kF,wF,gf,ad,TF,$F,_f,id,yF,DF,Vt,ld,FF,Es,EF,bf,BF,xF,vf,MF,zF,jF,Zn,CF,er,bm,Bs,tr,kf,dd,PF,wf,qF,vm,at,cd,AF,xs,OF,Tf,LF,IF,$f,SF,NF,RF,pd,WF,Kc,QF,UF,HF,hd,KF,fd,VF,JF,GF,yf,XF,YF,lo,Df,ud,ZF,e4,Ff,md,t4,o4,Ef,gd,s4,n4,Bf,_d,r4,a4,Jt,bd,i4,Ms,l4,xf,d4,c4,Mf,p4,h4,f4,or,u4,sr,km;return l=new Ne({}),E=new Ne({}),R=new Ne({}),Er=new Sg({props:{pipeline:"text-classification"}}),Vr=new Sg({props:{pipeline:"token-classification"}}),ta=new Sg({props:{pipeline:"fill-mask"}}),da=new Sg({props:{pipeline:"question-answering"}}),Aa=new Ne({}),Oa=new Y({props:{name:"class transformers.DistilBertConfig",anchor:"transformers.DistilBertConfig",parameters:[{name:"vocab_size",val:" = 30522"},{name:"max_position_embeddings",val:" = 512"},{name:"sinusoidal_pos_embds",val:" = False"},{name:"n_layers",val:" = 6"},{name:"n_heads",val:" = 12"},{name:"dim",val:" = 768"},{name:"hidden_dim",val:" = 3072"},{name:"dropout",val:" = 0.1"},{name:"attention_dropout",val:" = 0.1"},{name:"activation",val:" = 'gelu'"},{name:"initializer_range",val:" = 0.02"},{name:"qa_dropout",val:" = 0.1"},{name:"seq_classif_dropout",val:" = 0.2"},{name:"pad_token_id",val:" = 0"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.DistilBertConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 30522) &#x2014;
Vocabulary size of the DistilBERT 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.25.1/en/model_doc/distilbert#transformers.DistilBertModel">DistilBertModel</a> or <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertModel">TFDistilBertModel</a>.`,name:"vocab_size"},{anchor:"transformers.DistilBertConfig.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.DistilBertConfig.sinusoidal_pos_embds",description:`<strong>sinusoidal_pos_embds</strong> (<code>boolean</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to use sinusoidal positional embeddings.`,name:"sinusoidal_pos_embds"},{anchor:"transformers.DistilBertConfig.n_layers",description:`<strong>n_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 6) &#x2014;
Number of hidden layers in the Transformer encoder.`,name:"n_layers"},{anchor:"transformers.DistilBertConfig.n_heads",description:`<strong>n_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:"n_heads"},{anchor:"transformers.DistilBertConfig.dim",description:`<strong>dim</strong> (<code>int</code>, <em>optional</em>, defaults to 768) &#x2014;
Dimensionality of the encoder layers and the pooler layer.`,name:"dim"},{anchor:"transformers.DistilBertConfig.hidden_dim",description:`<strong>hidden_dim</strong> (<code>int</code>, <em>optional</em>, defaults to 3072) &#x2014;
The size of the &#x201C;intermediate&#x201D; (often named feed-forward) layer in the Transformer encoder.`,name:"hidden_dim"},{anchor:"transformers.DistilBertConfig.dropout",description:`<strong>dropout</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:"dropout"},{anchor:"transformers.DistilBertConfig.attention_dropout",description:`<strong>attention_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_dropout"},{anchor:"transformers.DistilBertConfig.activation",description:`<strong>activation</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> and <code>&quot;gelu_new&quot;</code> are supported.`,name:"activation"},{anchor:"transformers.DistilBertConfig.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.DistilBertConfig.qa_dropout",description:`<strong>qa_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout probabilities used in the question answering model <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForQuestionAnswering">DistilBertForQuestionAnswering</a>.`,name:"qa_dropout"},{anchor:"transformers.DistilBertConfig.seq_classif_dropout",description:`<strong>seq_classif_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.2) &#x2014;
The dropout probabilities used in the sequence classification and the multiple choice model
<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForSequenceClassification">DistilBertForSequenceClassification</a>.`,name:"seq_classif_dropout"}],source:"https://github.com/huggingface/transformers/blob/v4.25.1/src/transformers/models/distilbert/configuration_distilbert.py#L45"}}),As=new fe({props:{anchor:"transformers.DistilBertConfig.example",$$slots:{default:[B5]},$$scope:{ctx:B}}}),Ia=new Ne({}),Sa=new Y({props:{name:"class transformers.DistilBertTokenizer",anchor:"transformers.DistilBertTokenizer",parameters:[{name:"vocab_file",val:""},{name:"do_lower_case",val:" = True"},{name:"do_basic_tokenize",val:" = True"},{name:"never_split",val:" = None"},{name:"unk_token",val:" = '[UNK]'"},{name:"sep_token",val:" = '[SEP]'"},{name:"pad_token",val:" = '[PAD]'"},{name:"cls_token",val:" = '[CLS]'"},{name:"mask_token",val:" = '[MASK]'"},{name:"tokenize_chinese_chars",val:" = True"},{name:"strip_accents",val:" = None"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/v4.25.1/src/transformers/models/distilbert/tokenization_distilbert.py#L62"}}),Ra=new Ne({}),Wa=new Y({props:{name:"class transformers.DistilBertTokenizerFast",anchor:"transformers.DistilBertTokenizerFast",parameters:[{name:"vocab_file",val:" = None"},{name:"tokenizer_file",val:" = None"},{name:"do_lower_case",val:" = True"},{name:"unk_token",val:" = '[UNK]'"},{name:"sep_token",val:" = '[SEP]'"},{name:"pad_token",val:" = '[PAD]'"},{name:"cls_token",val:" = '[CLS]'"},{name:"mask_token",val:" = '[MASK]'"},{name:"tokenize_chinese_chars",val:" = True"},{name:"strip_accents",val:" = None"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/v4.25.1/src/transformers/models/distilbert/tokenization_distilbert_fast.py#L79"}}),Ha=new Ne({}),Ka=new Y({props:{name:"class transformers.DistilBertModel",anchor:"transformers.DistilBertModel",parameters:[{name:"config",val:": PretrainedConfig"}],parametersDescription:[{anchor:"transformers.DistilBertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L465"}}),Xa=new Y({props:{name:"forward",anchor:"transformers.DistilBertModel.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",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.DistilBertModel.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.DistilBertModel.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices)</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.DistilBertModel.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.DistilBertModel.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices, 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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DistilBertModel.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.DistilBertModel.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.DistilBertModel.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.25.1/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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L537",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_outputs.BaseModelOutput"
>transformers.modeling_outputs.BaseModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Rs=new Se({props:{$$slots:{default:[x5]},$$scope:{ctx:B}}}),Ws=new fe({props:{anchor:"transformers.DistilBertModel.forward.example",$$slots:{default:[M5]},$$scope:{ctx:B}}}),Ya=new Ne({}),Za=new Y({props:{name:"class transformers.DistilBertForMaskedLM",anchor:"transformers.DistilBertForMaskedLM",parameters:[{name:"config",val:": PretrainedConfig"}],parametersDescription:[{anchor:"transformers.DistilBertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L593"}}),ni=new Y({props:{name:"forward",anchor:"transformers.DistilBertForMaskedLM.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = 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.DistilBertForMaskedLM.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.DistilBertForMaskedLM.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices)</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.DistilBertForMaskedLM.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.DistilBertForMaskedLM.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices, 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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DistilBertForMaskedLM.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.DistilBertForMaskedLM.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.DistilBertForMaskedLM.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DistilBertForMaskedLM.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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L637",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Us=new Se({props:{$$slots:{default:[z5]},$$scope:{ctx:B}}}),Hs=new fe({props:{anchor:"transformers.DistilBertForMaskedLM.forward.example",$$slots:{default:[j5]},$$scope:{ctx:B}}}),Ks=new fe({props:{anchor:"transformers.DistilBertForMaskedLM.forward.example-2",$$slots:{default:[C5]},$$scope:{ctx:B}}}),ri=new Ne({}),ai=new Y({props:{name:"class transformers.DistilBertForSequenceClassification",anchor:"transformers.DistilBertForSequenceClassification",parameters:[{name:"config",val:": PretrainedConfig"}],parametersDescription:[{anchor:"transformers.DistilBertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L701"}}),ci=new Y({props:{name:"forward",anchor:"transformers.DistilBertForSequenceClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = 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.DistilBertForSequenceClassification.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.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.DistilBertForSequenceClassification.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.DistilBertForSequenceClassification.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.DistilBertForSequenceClassification.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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DistilBertForSequenceClassification.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.DistilBertForSequenceClassification.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.DistilBertForSequenceClassification.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DistilBertForSequenceClassification.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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L735",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Js=new Se({props:{$$slots:{default:[P5]},$$scope:{ctx:B}}}),Gs=new fe({props:{anchor:"transformers.DistilBertForSequenceClassification.forward.example",$$slots:{default:[q5]},$$scope:{ctx:B}}}),Xs=new fe({props:{anchor:"transformers.DistilBertForSequenceClassification.forward.example-2",$$slots:{default:[A5]},$$scope:{ctx:B}}}),Ys=new fe({props:{anchor:"transformers.DistilBertForSequenceClassification.forward.example-3",$$slots:{default:[O5]},$$scope:{ctx:B}}}),Zs=new fe({props:{anchor:"transformers.DistilBertForSequenceClassification.forward.example-4",$$slots:{default:[L5]},$$scope:{ctx:B}}}),pi=new Ne({}),hi=new Y({props:{name:"class transformers.DistilBertForMultipleChoice",anchor:"transformers.DistilBertForMultipleChoice",parameters:[{name:"config",val:": PretrainedConfig"}],parametersDescription:[{anchor:"transformers.DistilBertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L1033"}}),gi=new Y({props:{name:"forward",anchor:"transformers.DistilBertForMultipleChoice.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = 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.DistilBertForMultipleChoice.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.DistilBertForMultipleChoice.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices, 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.DistilBertForMultipleChoice.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.DistilBertForMultipleChoice.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices, 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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DistilBertForMultipleChoice.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.DistilBertForMultipleChoice.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.DistilBertForMultipleChoice.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DistilBertForMultipleChoice.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the multiple choice classification loss. Indices should be in <code>[0, ..., num_choices-1]</code> where <code>num_choices</code> is the size of the second dimension of the input tensors. (See
<code>input_ids</code> above)`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L1065",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <em>(1,)</em>, <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, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>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.25.1/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),tn=new Se({props:{$$slots:{default:[I5]},$$scope:{ctx:B}}}),on=new fe({props:{anchor:"transformers.DistilBertForMultipleChoice.forward.example",$$slots:{default:[S5]},$$scope:{ctx:B}}}),_i=new Ne({}),bi=new Y({props:{name:"class transformers.DistilBertForTokenClassification",anchor:"transformers.DistilBertForTokenClassification",parameters:[{name:"config",val:": PretrainedConfig"}],parametersDescription:[{anchor:"transformers.DistilBertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L938"}}),Ti=new Y({props:{name:"forward",anchor:"transformers.DistilBertForTokenClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = 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.DistilBertForTokenClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>({0})</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.DistilBertForTokenClassification.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>({0})</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.DistilBertForTokenClassification.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.DistilBertForTokenClassification.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>({0}, 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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DistilBertForTokenClassification.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.DistilBertForTokenClassification.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.DistilBertForTokenClassification.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DistilBertForTokenClassification.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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L970",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),nn=new Se({props:{$$slots:{default:[N5]},$$scope:{ctx:B}}}),rn=new fe({props:{anchor:"transformers.DistilBertForTokenClassification.forward.example",$$slots:{default:[R5]},$$scope:{ctx:B}}}),an=new fe({props:{anchor:"transformers.DistilBertForTokenClassification.forward.example-2",$$slots:{default:[W5]},$$scope:{ctx:B}}}),$i=new Ne({}),yi=new Y({props:{name:"class transformers.DistilBertForQuestionAnswering",anchor:"transformers.DistilBertForQuestionAnswering",parameters:[{name:"config",val:": PretrainedConfig"}],parametersDescription:[{anchor:"transformers.DistilBertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L819"}}),Bi=new Y({props:{name:"forward",anchor:"transformers.DistilBertForQuestionAnswering.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",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.DistilBertForQuestionAnswering.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.DistilBertForQuestionAnswering.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices)</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.DistilBertForQuestionAnswering.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.DistilBertForQuestionAnswering.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices, 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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.DistilBertForQuestionAnswering.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.DistilBertForQuestionAnswering.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.DistilBertForQuestionAnswering.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.DistilBertForQuestionAnswering.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.DistilBertForQuestionAnswering.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.25.1/src/transformers/models/distilbert/modeling_distilbert.py#L853",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),dn=new Se({props:{$$slots:{default:[Q5]},$$scope:{ctx:B}}}),cn=new fe({props:{anchor:"transformers.DistilBertForQuestionAnswering.forward.example",$$slots:{default:[U5]},$$scope:{ctx:B}}}),pn=new fe({props:{anchor:"transformers.DistilBertForQuestionAnswering.forward.example-2",$$slots:{default:[H5]},$$scope:{ctx:B}}}),xi=new Ne({}),Mi=new Y({props:{name:"class transformers.TFDistilBertModel",anchor:"transformers.TFDistilBertModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDistilBertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L537"}}),fn=new Se({props:{$$slots:{default:[K5]},$$scope:{ctx:B}}}),Pi=new Y({props:{name:"call",anchor:"transformers.TFDistilBertModel.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",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.TFDistilBertModel.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</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.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDistilBertModel.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</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.TFDistilBertModel.call.head_mask",description:`<strong>head_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFDistilBertModel.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDistilBertModel.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. This argument can be used only in eager mode, in graph mode the value in the
config will be used instead.`,name:"output_attentions"},{anchor:"transformers.TFDistilBertModel.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFDistilBertModel.call.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFDistilBertModel.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"}],source:"https://github.com/huggingface/transformers/blob/v4.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L542",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutput"
>transformers.modeling_tf_outputs.TFBaseModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),un=new Se({props:{$$slots:{default:[V5]},$$scope:{ctx:B}}}),mn=new fe({props:{anchor:"transformers.TFDistilBertModel.call.example",$$slots:{default:[J5]},$$scope:{ctx:B}}}),qi=new Ne({}),Ai=new Y({props:{name:"class transformers.TFDistilBertForMaskedLM",anchor:"transformers.TFDistilBertForMaskedLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDistilBertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L624"}}),_n=new Se({props:{$$slots:{default:[G5]},$$scope:{ctx:B}}}),Ni=new Y({props:{name:"call",anchor:"transformers.TFDistilBertForMaskedLM.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",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.TFDistilBertForMaskedLM.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</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.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDistilBertForMaskedLM.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</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.TFDistilBertForMaskedLM.call.head_mask",description:`<strong>head_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFDistilBertForMaskedLM.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDistilBertForMaskedLM.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. This argument can be used only in eager mode, in graph mode the value in the
config will be used instead.`,name:"output_attentions"},{anchor:"transformers.TFDistilBertForMaskedLM.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFDistilBertForMaskedLM.call.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFDistilBertForMaskedLM.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"},{anchor:"transformers.TFDistilBertForMaskedLM.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L644",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),bn=new Se({props:{$$slots:{default:[X5]},$$scope:{ctx:B}}}),vn=new fe({props:{anchor:"transformers.TFDistilBertForMaskedLM.call.example",$$slots:{default:[Y5]},$$scope:{ctx:B}}}),kn=new fe({props:{anchor:"transformers.TFDistilBertForMaskedLM.call.example-2",$$slots:{default:[Z5]},$$scope:{ctx:B}}}),Ri=new Ne({}),Wi=new Y({props:{name:"class transformers.TFDistilBertForSequenceClassification",anchor:"transformers.TFDistilBertForSequenceClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDistilBertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L714"}}),Tn=new Se({props:{$$slots:{default:[eM]},$$scope:{ctx:B}}}),Ki=new Y({props:{name:"call",anchor:"transformers.TFDistilBertForSequenceClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",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.TFDistilBertForSequenceClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</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.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDistilBertForSequenceClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</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.TFDistilBertForSequenceClassification.call.head_mask",description:`<strong>head_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFDistilBertForSequenceClassification.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDistilBertForSequenceClassification.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. This argument can be used only in eager mode, in graph mode the value in the
config will be used instead.`,name:"output_attentions"},{anchor:"transformers.TFDistilBertForSequenceClassification.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFDistilBertForSequenceClassification.call.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFDistilBertForSequenceClassification.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"},{anchor:"transformers.TFDistilBertForSequenceClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L731",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),$n=new Se({props:{$$slots:{default:[tM]},$$scope:{ctx:B}}}),yn=new fe({props:{anchor:"transformers.TFDistilBertForSequenceClassification.call.example",$$slots:{default:[oM]},$$scope:{ctx:B}}}),Dn=new fe({props:{anchor:"transformers.TFDistilBertForSequenceClassification.call.example-2",$$slots:{default:[sM]},$$scope:{ctx:B}}}),Vi=new Ne({}),Ji=new Y({props:{name:"class transformers.TFDistilBertForMultipleChoice",anchor:"transformers.TFDistilBertForMultipleChoice",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDistilBertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L877"}}),En=new Se({props:{$$slots:{default:[nM]},$$scope:{ctx:B}}}),Zi=new Y({props:{name:"call",anchor:"transformers.TFDistilBertForMultipleChoice.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",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.TFDistilBertForMultipleChoice.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDistilBertForMultipleChoice.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, 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.TFDistilBertForMultipleChoice.call.head_mask",description:`<strong>head_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFDistilBertForMultipleChoice.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, num_choices, 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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDistilBertForMultipleChoice.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. This argument can be used only in eager mode, in graph mode the value in the
config will be used instead.`,name:"output_attentions"},{anchor:"transformers.TFDistilBertForMultipleChoice.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFDistilBertForMultipleChoice.call.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFDistilBertForMultipleChoice.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"},{anchor:"transformers.TFDistilBertForMultipleChoice.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the multiple choice classification loss. Indices should be in <code>[0, ..., num_choices]</code>
where <code>num_choices</code> is the size of the second dimension of the input tensors. (See <code>input_ids</code> above)`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L903",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <em>(batch_size, )</em>, <em>optional</em>, 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, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>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.25.1/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Bn=new Se({props:{$$slots:{default:[rM]},$$scope:{ctx:B}}}),xn=new fe({props:{anchor:"transformers.TFDistilBertForMultipleChoice.call.example",$$slots:{default:[aM]},$$scope:{ctx:B}}}),el=new Ne({}),tl=new Y({props:{name:"class transformers.TFDistilBertForTokenClassification",anchor:"transformers.TFDistilBertForTokenClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDistilBertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L801"}}),zn=new Se({props:{$$slots:{default:[iM]},$$scope:{ctx:B}}}),rl=new Y({props:{name:"call",anchor:"transformers.TFDistilBertForTokenClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",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.TFDistilBertForTokenClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</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.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDistilBertForTokenClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</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.TFDistilBertForTokenClassification.call.head_mask",description:`<strong>head_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFDistilBertForTokenClassification.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDistilBertForTokenClassification.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. This argument can be used only in eager mode, in graph mode the value in the
config will be used instead.`,name:"output_attentions"},{anchor:"transformers.TFDistilBertForTokenClassification.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFDistilBertForTokenClassification.call.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFDistilBertForTokenClassification.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"},{anchor:"transformers.TFDistilBertForTokenClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L812",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),jn=new Se({props:{$$slots:{default:[lM]},$$scope:{ctx:B}}}),Cn=new fe({props:{anchor:"transformers.TFDistilBertForTokenClassification.call.example",$$slots:{default:[dM]},$$scope:{ctx:B}}}),Pn=new fe({props:{anchor:"transformers.TFDistilBertForTokenClassification.call.example-2",$$slots:{default:[cM]},$$scope:{ctx:B}}}),al=new Ne({}),il=new Y({props:{name:"class transformers.TFDistilBertForQuestionAnswering",anchor:"transformers.TFDistilBertForQuestionAnswering",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFDistilBertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L1002"}}),An=new Se({props:{$$slots:{default:[pM]},$$scope:{ctx:B}}}),pl=new Y({props:{name:"call",anchor:"transformers.TFDistilBertForQuestionAnswering.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",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.TFDistilBertForQuestionAnswering.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</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.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer">DistilBertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFDistilBertForQuestionAnswering.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</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.TFDistilBertForQuestionAnswering.call.head_mask",description:`<strong>head_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFDistilBertForQuestionAnswering.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<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 <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFDistilBertForQuestionAnswering.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. This argument can be used only in eager mode, in graph mode the value in the
config will be used instead.`,name:"output_attentions"},{anchor:"transformers.TFDistilBertForQuestionAnswering.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFDistilBertForQuestionAnswering.call.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.25.1/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFDistilBertForQuestionAnswering.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"},{anchor:"transformers.TFDistilBertForQuestionAnswering.call.start_positions",description:`<strong>start_positions</strong> (<code>tf.Tensor</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.TFDistilBertForQuestionAnswering.call.end_positions",description:`<strong>end_positions</strong> (<code>tf.Tensor</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.25.1/src/transformers/models/distilbert/modeling_tf_distilbert.py#L1013",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</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.25.1/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),On=new Se({props:{$$slots:{default:[hM]},$$scope:{ctx:B}}}),Ln=new fe({props:{anchor:"transformers.TFDistilBertForQuestionAnswering.call.example",$$slots:{default:[fM]},$$scope:{ctx:B}}}),In=new fe({props:{anchor:"transformers.TFDistilBertForQuestionAnswering.call.example-2",$$slots:{default:[uM]},$$scope:{ctx:B}}}),hl=new Ne({}),fl=new Y({props:{name:"class transformers.FlaxDistilBertModel",anchor:"transformers.FlaxDistilBertModel",parameters:[{name:"config",val:": DistilBertConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxDistilBertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L535"}}),wl=new Y({props:{name:"__call__",anchor:"transformers.FlaxDistilBertModel.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"head_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{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.FlaxDistilBertModel.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</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.25.1/en/model_doc/bert#transformers.BertTokenizer">BertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.FlaxDistilBertModel.__call__.attention_mask",description:`<strong>attention_mask</strong> (<code>numpy.ndarray</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.FlaxDistilBertModel.__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.FlaxDistilBertModel.__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.FlaxDistilBertModel.__call__.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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L458"}}),Nn=new Se({props:{$$slots:{default:[mM]},$$scope:{ctx:B}}}),Rn=new fe({props:{anchor:"transformers.FlaxDistilBertModel.__call__.example",$$slots:{default:[gM]},$$scope:{ctx:B}}}),Tl=new Ne({}),$l=new Y({props:{name:"class transformers.FlaxDistilBertForMaskedLM",anchor:"transformers.FlaxDistilBertForMaskedLM",parameters:[{name:"config",val:": DistilBertConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxDistilBertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L608"}}),jl=new Y({props:{name:"__call__",anchor:"transformers.FlaxDistilBertForMaskedLM.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"head_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{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.FlaxDistilBertForMaskedLM.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</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.25.1/en/model_doc/bert#transformers.BertTokenizer">BertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.FlaxDistilBertForMaskedLM.__call__.attention_mask",description:`<strong>attention_mask</strong> (<code>numpy.ndarray</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.FlaxDistilBertForMaskedLM.__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.FlaxDistilBertForMaskedLM.__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.FlaxDistilBertForMaskedLM.__call__.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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L458",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMaskedLMOutput"
>transformers.modeling_flax_outputs.FlaxMaskedLMOutput</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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMaskedLMOutput"
>transformers.modeling_flax_outputs.FlaxMaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Qn=new Se({props:{$$slots:{default:[_M]},$$scope:{ctx:B}}}),Un=new fe({props:{anchor:"transformers.FlaxDistilBertForMaskedLM.__call__.example",$$slots:{default:[bM]},$$scope:{ctx:B}}}),Cl=new Ne({}),Pl=new Y({props:{name:"class transformers.FlaxDistilBertForSequenceClassification",anchor:"transformers.FlaxDistilBertForSequenceClassification",parameters:[{name:"config",val:": DistilBertConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxDistilBertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L677"}}),Rl=new Y({props:{name:"__call__",anchor:"transformers.FlaxDistilBertForSequenceClassification.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"head_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{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.FlaxDistilBertForSequenceClassification.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</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.25.1/en/model_doc/bert#transformers.BertTokenizer">BertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.FlaxDistilBertForSequenceClassification.__call__.attention_mask",description:`<strong>attention_mask</strong> (<code>numpy.ndarray</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.FlaxDistilBertForSequenceClassification.__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.FlaxDistilBertForSequenceClassification.__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.FlaxDistilBertForSequenceClassification.__call__.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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L458",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Kn=new Se({props:{$$slots:{default:[vM]},$$scope:{ctx:B}}}),Vn=new fe({props:{anchor:"transformers.FlaxDistilBertForSequenceClassification.__call__.example",$$slots:{default:[kM]},$$scope:{ctx:B}}}),Wl=new Ne({}),Ql=new Y({props:{name:"class transformers.FlaxDistilBertForMultipleChoice",anchor:"transformers.FlaxDistilBertForMultipleChoice",parameters:[{name:"config",val:": DistilBertConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxDistilBertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L757"}}),Yl=new Y({props:{name:"__call__",anchor:"transformers.FlaxDistilBertForMultipleChoice.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"head_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{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.FlaxDistilBertForMultipleChoice.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.25.1/en/model_doc/bert#transformers.BertTokenizer">BertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.FlaxDistilBertForMultipleChoice.__call__.attention_mask",description:`<strong>attention_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, num_choices, 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.FlaxDistilBertForMultipleChoice.__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.FlaxDistilBertForMultipleChoice.__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.FlaxDistilBertForMultipleChoice.__call__.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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L458",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</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>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Gn=new Se({props:{$$slots:{default:[wM]},$$scope:{ctx:B}}}),Xn=new fe({props:{anchor:"transformers.FlaxDistilBertForMultipleChoice.__call__.example",$$slots:{default:[TM]},$$scope:{ctx:B}}}),Zl=new Ne({}),ed=new Y({props:{name:"class transformers.FlaxDistilBertForTokenClassification",anchor:"transformers.FlaxDistilBertForTokenClassification",parameters:[{name:"config",val:": DistilBertConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxDistilBertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L823"}}),ld=new Y({props:{name:"__call__",anchor:"transformers.FlaxDistilBertForTokenClassification.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"head_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{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.FlaxDistilBertForTokenClassification.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</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.25.1/en/model_doc/bert#transformers.BertTokenizer">BertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.FlaxDistilBertForTokenClassification.__call__.attention_mask",description:`<strong>attention_mask</strong> (<code>numpy.ndarray</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.FlaxDistilBertForTokenClassification.__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.FlaxDistilBertForTokenClassification.__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.FlaxDistilBertForTokenClassification.__call__.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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L458",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Zn=new Se({props:{$$slots:{default:[$M]},$$scope:{ctx:B}}}),er=new fe({props:{anchor:"transformers.FlaxDistilBertForTokenClassification.__call__.example",$$slots:{default:[yM]},$$scope:{ctx:B}}}),dd=new Ne({}),cd=new Y({props:{name:"class transformers.FlaxDistilBertForQuestionAnswering",anchor:"transformers.FlaxDistilBertForQuestionAnswering",parameters:[{name:"config",val:": DistilBertConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxDistilBertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertConfig">DistilBertConfig</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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L893"}}),bd=new Y({props:{name:"__call__",anchor:"transformers.FlaxDistilBertForQuestionAnswering.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"head_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{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.FlaxDistilBertForQuestionAnswering.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</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.25.1/en/model_doc/bert#transformers.BertTokenizer">BertTokenizer</a>. See <a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.25.1/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__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.FlaxDistilBertForQuestionAnswering.__call__.attention_mask",description:`<strong>attention_mask</strong> (<code>numpy.ndarray</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.FlaxDistilBertForQuestionAnswering.__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.FlaxDistilBertForQuestionAnswering.__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.FlaxDistilBertForQuestionAnswering.__call__.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.25.1/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.25.1/src/transformers/models/distilbert/modeling_flax_distilbert.py#L458",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</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.25.1/en/model_doc/distilbert#transformers.DistilBertConfig"
>DistilBertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>start_logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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(jnp.ndarray)</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>jnp.ndarray</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.25.1/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),or=new Se({props:{$$slots:{default:[DM]},$$scope:{ctx:B}}}),sr=new fe({props:{anchor:"transformers.FlaxDistilBertForQuestionAnswering.__call__.example",$$slots:{default:[FM]},$$scope:{ctx:B}}}),{c(){d=r("meta"),b=p(),f=r("h1"),m=r("a"),v=r("span"),w(l.$$.fragment),u=p(),M=r("span"),we=o("DistilBERT"),ge=p(),I=r("h2"),re=r("a"),oe=r("span"),w(E.$$.fragment),Te=p(),Q=r("span"),$e=o("Overview"),_e=p(),O=r("p"),ye=o("The DistilBERT model was proposed in the blog post "),ae=r("a"),H=o(`Smaller, faster, cheaper, lighter: Introducing DistilBERT, a
distilled version of BERT`),De=o(", and the paper "),ie=r("a"),K=o(`DistilBERT, a
distilled version of BERT: smaller, faster, cheaper and lighter`),Fe=o(`. DistilBERT is a
small, fast, cheap and light Transformer model trained by distilling BERT base. It has 40% less parameters than
`),de=r("em"),V=o("bert-base-uncased"),Ee=o(`, runs 60% faster while preserving over 95% of BERT\u2019s performances as measured on the GLUE language
understanding benchmark.`),be=p(),ee=r("p"),j=o("The abstract from the paper is the following:"),q=p(),le=r("p"),U=r("em"),Be=o(`As Transfer Learning from large-scale pre-trained models becomes more prevalent in Natural Language Processing (NLP),
operating these large models in on-the-edge and/or under constrained computational training or inference budgets
remains challenging. In this work, we propose a method to pre-train a smaller general-purpose language representation
model, called DistilBERT, which can then be fine-tuned with good performances on a wide range of tasks like its larger
counterparts. While most prior work investigated the use of distillation for building task-specific models, we leverage
knowledge distillation during the pretraining phase and show that it is possible to reduce the size of a BERT model by
40%, while retaining 97% of its language understanding capabilities and being 60% faster. To leverage the inductive
biases learned by larger models during pretraining, we introduce a triple loss combining language modeling,
distillation and cosine-distance losses. Our smaller, faster and lighter model is cheaper to pre-train and we
demonstrate its capabilities for on-device computations in a proof-of-concept experiment and a comparative on-device
study.`),ve=p(),W=r("p"),xe=o("Tips:"),ke=p(),C=r("ul"),se=r("li"),J=o("DistilBERT doesn\u2019t have "),ce=r("code"),Me=o("token_type_ids"),G=o(`, you don\u2019t need to indicate which token belongs to which segment. Just
separate your segments with the separation token `),pe=r("code"),ze=o("tokenizer.sep_token"),S=o(" (or "),he=r("code"),X=o("[SEP]"),je=o(")."),ne=p(),P=r("li"),Ce=o("DistilBERT doesn\u2019t have options to select the input positions ("),A=r("code"),Pe=o("position_ids"),qe=o(` input). This could be added if
necessary though, just let us know if you need this option.`),k=p(),x=r("p"),He=o("This model was contributed by "),Z=r("a"),Ke=o("victorsanh"),Ve=o(`. This model jax version was
contributed by `),z=r("a"),Je=o("kamalkraj"),Ge=o(". The original code can be found "),Le=r("a"),Xe=o("here"),Ye=o("."),L=p(),N=r("h2"),Oe=r("a"),Re=r("span"),w(R.$$.fragment),Ze=p(),We=r("span"),Ae=o("Resources"),Ue=p(),te=r("p"),et=o("A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with DistilBERT. 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."),gu=p(),w(Er.$$.fragment),_u=p(),Ie=r("ul"),Br=r("li"),Ng=o("A blog post on "),xr=r("a"),Rg=o("Getting Started with Sentiment Analysis using Python"),Wg=o(" with DistilBERT."),Qg=p(),Mr=r("li"),Ug=o("A blog post on how to "),zr=r("a"),Hg=o("train DistilBERT with Blurr for sequence classification"),Kg=o("."),Vg=p(),jr=r("li"),Jg=o("A blog post on how to use "),Cr=r("a"),Gg=o("Ray to tune DistilBERT hyperparameters"),Xg=o("."),Yg=p(),Pr=r("li"),Zg=o("A blog post on how to "),qr=r("a"),e_=o("train DistilBERT with Hugging Face and Amazon SageMaker"),t_=o("."),o_=p(),Ar=r("li"),s_=o("A notebook on how to "),Or=r("a"),n_=o("finetune DistilBERT for multi-label classification"),r_=o(". \u{1F30E}"),a_=p(),Lr=r("li"),i_=o("A notebook on how to "),Ir=r("a"),l_=o("finetune DistilBERT for multiclass classification with PyTorch"),d_=o(". \u{1F30E}"),c_=p(),Sr=r("li"),p_=o("A notebook on how to "),Nr=r("a"),h_=o("finetune DistilBERT for text classification in TensorFlow"),f_=o(". \u{1F30E}"),u_=p(),fo=r("li"),Nd=r("a"),m_=o("DistilBertForSequenceClassification"),g_=o(" is supported by this "),Rr=r("a"),__=o("example script"),b_=o(" and "),Wr=r("a"),v_=o("notebook"),k_=o("."),w_=p(),uo=r("li"),Rd=r("a"),T_=o("TFDistilBertForSequenceClassification"),$_=o(" is supported by this "),Qr=r("a"),y_=o("example script"),D_=o(" and "),Ur=r("a"),F_=o("notebook"),E_=o("."),B_=p(),mo=r("li"),Wd=r("a"),x_=o("FlaxDistilBertForSequenceClassification"),M_=o(" is supported by this "),Hr=r("a"),z_=o("example script"),j_=o(" and "),Kr=r("a"),C_=o("notebook"),P_=o("."),bu=p(),w(Vr.$$.fragment),vu=p(),Ot=r("ul"),go=r("li"),Qd=r("a"),q_=o("DistilBertForTokenClassification"),A_=o(" is supported by this "),Jr=r("a"),O_=o("example script"),L_=o(" and "),Gr=r("a"),I_=o("notebook"),S_=o("."),N_=p(),_o=r("li"),Ud=r("a"),R_=o("TFDistilBertForTokenClassification"),W_=o(" is supported by this "),Xr=r("a"),Q_=o("example script"),U_=o(" and "),Yr=r("a"),H_=o("notebook"),K_=o("."),V_=p(),zs=r("li"),Hd=r("a"),J_=o("FlaxDistilBertForTokenClassification"),G_=o(" is supported by this "),Zr=r("a"),X_=o("example script"),Y_=o("."),Z_=p(),Kd=r("li"),ea=r("a"),eb=o("Token classification"),tb=o(" chapter of the \u{1F917} Hugging Face Course."),ku=p(),w(ta.$$.fragment),wu=p(),Lt=r("ul"),bo=r("li"),Vd=r("a"),ob=o("DistilBertForMaskedLM"),sb=o(" is supported by this "),oa=r("a"),nb=o("example script"),rb=o(" and "),sa=r("a"),ab=o("notebook"),ib=o("."),lb=p(),vo=r("li"),Jd=r("a"),db=o("TFDistilBertForMaskedLM"),cb=o(" is supported by this "),na=r("a"),pb=o("example script"),hb=o(" and "),ra=r("a"),fb=o("notebook"),ub=o("."),mb=p(),ko=r("li"),Gd=r("a"),gb=o("FlaxDistilBertForMaskedLM"),_b=o(" is supported by this "),aa=r("a"),bb=o("example script"),vb=o(" and "),ia=r("a"),kb=o("notebook"),wb=o("."),Tb=p(),Xd=r("li"),la=r("a"),$b=o("Masked language modeling"),yb=o(" chapter of the \u{1F917} Hugging Face Course."),Tu=p(),w(da.$$.fragment),$u=p(),It=r("ul"),wo=r("li"),Yd=r("a"),Db=o("DistilBertForQuestionAnswering"),Fb=o(" is supported by this "),ca=r("a"),Eb=o("example script"),Bb=o(" and "),pa=r("a"),xb=o("notebook"),Mb=o("."),zb=p(),To=r("li"),Zd=r("a"),jb=o("TFDistilBertForQuestionAnswering"),Cb=o(" is supported by this "),ha=r("a"),Pb=o("example script"),qb=o(" and "),fa=r("a"),Ab=o("notebook"),Ob=o("."),Lb=p(),js=r("li"),ec=r("a"),Ib=o("FlaxDistilBertForQuestionAnswering"),Sb=o(" is supported by this "),ua=r("a"),Nb=o("example script"),Rb=o("."),Wb=p(),tc=r("li"),ma=r("a"),Qb=o("Question answering"),Ub=o(" chapter of the \u{1F917} Hugging Face Course."),yu=p(),oc=r("p"),bp=r("strong"),Hb=o("Multiple choice"),Du=p(),Cs=r("ul"),$o=r("li"),sc=r("a"),Kb=o("DistilBertForMultipleChoice"),Vb=o(" is supported by this "),ga=r("a"),Jb=o("example script"),Gb=o(" and "),_a=r("a"),Xb=o("notebook"),Yb=o("."),Zb=p(),yo=r("li"),nc=r("a"),ev=o("TFDistilBertForMultipleChoice"),tv=o(" is supported by this "),ba=r("a"),ov=o("example script"),sv=o(" and "),va=r("a"),nv=o("notebook"),rv=o("."),Fu=p(),rc=r("p"),av=o("\u2697\uFE0F Optimization"),Eu=p(),Do=r("ul"),ka=r("li"),iv=o("A blog post on how to "),wa=r("a"),lv=o("quantize DistilBERT with \u{1F917} Optimum and Intel"),dv=o("."),cv=p(),Ta=r("li"),pv=o("A blog post on how "),$a=r("a"),hv=o("Optimizing Transformers for GPUs with \u{1F917} Optimum"),fv=o("."),uv=p(),ya=r("li"),mv=o("A blog post on "),Da=r("a"),gv=o("Optimizing Transformers with Hugging Face Optimum"),_v=o("."),Bu=p(),ac=r("p"),bv=o("\u26A1\uFE0F Inference"),xu=p(),Ps=r("ul"),Fa=r("li"),vv=o("A blog post on how to "),Ea=r("a"),kv=o("Accelerate BERT inference with Hugging Face Transformers and AWS Inferentia"),wv=o(" with DistilBERT."),Tv=p(),Ba=r("li"),$v=o("A blog post on "),xa=r("a"),yv=o("Serverless Inference with Hugging Face\u2019s Transformers, DistilBERT and Amazon SageMaker"),Dv=o("."),Mu=p(),ic=r("p"),Fv=o("\u{1F680} Deploy"),zu=p(),Fo=r("ul"),Ma=r("li"),Ev=o("A blog post on how to "),za=r("a"),Bv=o("deploy DistilBERT on Google Cloud"),xv=o("."),Mv=p(),ja=r("li"),zv=o("A blog post on how to "),Ca=r("a"),jv=o("deploy DistilBERT with Amazon SageMaker"),Cv=o("."),Pv=p(),Pa=r("li"),qv=o("A blog post on how to "),qa=r("a"),Av=o("Deploy BERT with Hugging Face Transformers, Amazon SageMaker and Terraform module"),Ov=o("."),ju=p(),Ro=r("h2"),qs=r("a"),vp=r("span"),w(Aa.$$.fragment),Lv=p(),kp=r("span"),Iv=o("DistilBertConfig"),Cu=p(),Pt=r("div"),w(Oa.$$.fragment),Sv=p(),oo=r("p"),Nv=o("This is the configuration class to store the configuration of a "),lc=r("a"),Rv=o("DistilBertModel"),Wv=o(" or a "),dc=r("a"),Qv=o("TFDistilBertModel"),Uv=o(`. It
is used to instantiate a DistilBERT 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 DistilBERT
`),La=r("a"),Hv=o("distilbert-base-uncased"),Kv=o(" architecture."),Vv=p(),Wo=r("p"),Jv=o("Configuration objects inherit from "),cc=r("a"),Gv=o("PretrainedConfig"),Xv=o(` and can be used to control the model outputs. Read the
documentation from `),pc=r("a"),Yv=o("PretrainedConfig"),Zv=o(" for more information."),ek=p(),w(As.$$.fragment),Pu=p(),Qo=r("h2"),Os=r("a"),wp=r("span"),w(Ia.$$.fragment),tk=p(),Tp=r("span"),ok=o("DistilBertTokenizer"),qu=p(),qt=r("div"),w(Sa.$$.fragment),sk=p(),$p=r("p"),nk=o("Construct a DistilBERT tokenizer."),rk=p(),Ls=r("p"),hc=r("a"),ak=o("DistilBertTokenizer"),ik=o(" is identical to "),fc=r("a"),lk=o("BertTokenizer"),dk=o(` and runs end-to-end tokenization: punctuation splitting
and wordpiece.`),ck=p(),Na=r("p"),pk=o("Refer to superclass "),uc=r("a"),hk=o("BertTokenizer"),fk=o(" for usage examples and documentation concerning parameters."),Au=p(),Uo=r("h2"),Is=r("a"),yp=r("span"),w(Ra.$$.fragment),uk=p(),Dp=r("span"),mk=o("DistilBertTokenizerFast"),Ou=p(),At=r("div"),w(Wa.$$.fragment),gk=p(),Qa=r("p"),_k=o("Construct a \u201Cfast\u201D DistilBERT tokenizer (backed by HuggingFace\u2019s "),Fp=r("em"),bk=o("tokenizers"),vk=o(" library)."),kk=p(),Ss=r("p"),mc=r("a"),wk=o("DistilBertTokenizerFast"),Tk=o(" is identical to "),gc=r("a"),$k=o("BertTokenizerFast"),yk=o(` and runs end-to-end tokenization: punctuation
splitting and wordpiece.`),Dk=p(),Ua=r("p"),Fk=o("Refer to superclass "),_c=r("a"),Ek=o("BertTokenizerFast"),Bk=o(" for usage examples and documentation concerning parameters."),Lu=p(),Ho=r("h2"),Ns=r("a"),Ep=r("span"),w(Ha.$$.fragment),xk=p(),Bp=r("span"),Mk=o("DistilBertModel"),Iu=p(),ut=r("div"),w(Ka.$$.fragment),zk=p(),xp=r("p"),jk=o("The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),Ck=p(),Va=r("p"),Pk=o("This model inherits from "),bc=r("a"),qk=o("PreTrainedModel"),Ak=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Ok=p(),Ja=r("p"),Lk=o("This model is also a PyTorch "),Ga=r("a"),Ik=o("torch.nn.Module"),Sk=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Nk=p(),St=r("div"),w(Xa.$$.fragment),Rk=p(),Ko=r("p"),Wk=o("The "),vc=r("a"),Qk=o("DistilBertModel"),Uk=o(" forward method, overrides the "),Mp=r("code"),Hk=o("__call__"),Kk=o(" special method."),Vk=p(),w(Rs.$$.fragment),Jk=p(),w(Ws.$$.fragment),Su=p(),Vo=r("h2"),Qs=r("a"),zp=r("span"),w(Ya.$$.fragment),Gk=p(),jp=r("span"),Xk=o("DistilBertForMaskedLM"),Nu=p(),mt=r("div"),w(Za.$$.fragment),Yk=p(),ei=r("p"),Zk=o("DistilBert Model with a "),Cp=r("code"),ew=o("masked language modeling"),tw=o(" head on top."),ow=p(),ti=r("p"),sw=o("This model inherits from "),kc=r("a"),nw=o("PreTrainedModel"),rw=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),aw=p(),oi=r("p"),iw=o("This model is also a PyTorch "),si=r("a"),lw=o("torch.nn.Module"),dw=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),cw=p(),kt=r("div"),w(ni.$$.fragment),pw=p(),Jo=r("p"),hw=o("The "),wc=r("a"),fw=o("DistilBertForMaskedLM"),uw=o(" forward method, overrides the "),Pp=r("code"),mw=o("__call__"),gw=o(" special method."),_w=p(),w(Us.$$.fragment),bw=p(),w(Hs.$$.fragment),vw=p(),w(Ks.$$.fragment),Ru=p(),Go=r("h2"),Vs=r("a"),qp=r("span"),w(ri.$$.fragment),kw=p(),Ap=r("span"),ww=o("DistilBertForSequenceClassification"),Wu=p(),gt=r("div"),w(ai.$$.fragment),Tw=p(),Op=r("p"),$w=o(`DistilBert Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),yw=p(),ii=r("p"),Dw=o("This model inherits from "),Tc=r("a"),Fw=o("PreTrainedModel"),Ew=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Bw=p(),li=r("p"),xw=o("This model is also a PyTorch "),di=r("a"),Mw=o("torch.nn.Module"),zw=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),jw=p(),it=r("div"),w(ci.$$.fragment),Cw=p(),Xo=r("p"),Pw=o("The "),$c=r("a"),qw=o("DistilBertForSequenceClassification"),Aw=o(" forward method, overrides the "),Lp=r("code"),Ow=o("__call__"),Lw=o(" special method."),Iw=p(),w(Js.$$.fragment),Sw=p(),w(Gs.$$.fragment),Nw=p(),w(Xs.$$.fragment),Rw=p(),w(Ys.$$.fragment),Ww=p(),w(Zs.$$.fragment),Qu=p(),Yo=r("h2"),en=r("a"),Ip=r("span"),w(pi.$$.fragment),Qw=p(),Sp=r("span"),Uw=o("DistilBertForMultipleChoice"),Uu=p(),_t=r("div"),w(hi.$$.fragment),Hw=p(),Np=r("p"),Kw=o(`DistilBert Model with a multiple choice classification head on top (a linear layer on top of the pooled output and
a softmax) e.g. for RocStories/SWAG tasks.`),Vw=p(),fi=r("p"),Jw=o("This model inherits from "),yc=r("a"),Gw=o("PreTrainedModel"),Xw=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Yw=p(),ui=r("p"),Zw=o("This model is also a PyTorch "),mi=r("a"),e1=o("torch.nn.Module"),t1=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),o1=p(),Nt=r("div"),w(gi.$$.fragment),s1=p(),Zo=r("p"),n1=o("The "),Dc=r("a"),r1=o("DistilBertForMultipleChoice"),a1=o(" forward method, overrides the "),Rp=r("code"),i1=o("__call__"),l1=o(" special method."),d1=p(),w(tn.$$.fragment),c1=p(),w(on.$$.fragment),Hu=p(),es=r("h2"),sn=r("a"),Wp=r("span"),w(_i.$$.fragment),p1=p(),Qp=r("span"),h1=o("DistilBertForTokenClassification"),Ku=p(),bt=r("div"),w(bi.$$.fragment),f1=p(),Up=r("p"),u1=o(`DistilBert 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.`),m1=p(),vi=r("p"),g1=o("This model inherits from "),Fc=r("a"),_1=o("PreTrainedModel"),b1=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),v1=p(),ki=r("p"),k1=o("This model is also a PyTorch "),wi=r("a"),w1=o("torch.nn.Module"),T1=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),$1=p(),wt=r("div"),w(Ti.$$.fragment),y1=p(),ts=r("p"),D1=o("The "),Ec=r("a"),F1=o("DistilBertForTokenClassification"),E1=o(" forward method, overrides the "),Hp=r("code"),B1=o("__call__"),x1=o(" special method."),M1=p(),w(nn.$$.fragment),z1=p(),w(rn.$$.fragment),j1=p(),w(an.$$.fragment),Vu=p(),os=r("h2"),ln=r("a"),Kp=r("span"),w($i.$$.fragment),C1=p(),Vp=r("span"),P1=o("DistilBertForQuestionAnswering"),Ju=p(),vt=r("div"),w(yi.$$.fragment),q1=p(),ss=r("p"),A1=o(`DistilBert 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 `),Jp=r("code"),O1=o("span start logits"),L1=o(" and "),Gp=r("code"),I1=o("span end logits"),S1=o(")."),N1=p(),Di=r("p"),R1=o("This model inherits from "),Bc=r("a"),W1=o("PreTrainedModel"),Q1=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),U1=p(),Fi=r("p"),H1=o("This model is also a PyTorch "),Ei=r("a"),K1=o("torch.nn.Module"),V1=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),J1=p(),Tt=r("div"),w(Bi.$$.fragment),G1=p(),ns=r("p"),X1=o("The "),xc=r("a"),Y1=o("DistilBertForQuestionAnswering"),Z1=o(" forward method, overrides the "),Xp=r("code"),eT=o("__call__"),tT=o(" special method."),oT=p(),w(dn.$$.fragment),sT=p(),w(cn.$$.fragment),nT=p(),w(pn.$$.fragment),Gu=p(),rs=r("h2"),hn=r("a"),Yp=r("span"),w(xi.$$.fragment),rT=p(),Zp=r("span"),aT=o("TFDistilBertModel"),Xu=p(),lt=r("div"),w(Mi.$$.fragment),iT=p(),eh=r("p"),lT=o("The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),dT=p(),zi=r("p"),cT=o("This model inherits from "),Mc=r("a"),pT=o("TFPreTrainedModel"),hT=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),fT=p(),ji=r("p"),uT=o("This model is also a "),Ci=r("a"),mT=o("tf.keras.Model"),gT=o(` 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=p(),w(fn.$$.fragment),bT=p(),Rt=r("div"),w(Pi.$$.fragment),vT=p(),as=r("p"),kT=o("The "),zc=r("a"),wT=o("TFDistilBertModel"),TT=o(" forward method, overrides the "),th=r("code"),$T=o("__call__"),yT=o(" special method."),DT=p(),w(un.$$.fragment),FT=p(),w(mn.$$.fragment),Yu=p(),is=r("h2"),gn=r("a"),oh=r("span"),w(qi.$$.fragment),ET=p(),sh=r("span"),BT=o("TFDistilBertForMaskedLM"),Zu=p(),dt=r("div"),w(Ai.$$.fragment),xT=p(),Oi=r("p"),MT=o("DistilBert Model with a "),nh=r("code"),zT=o("masked language modeling"),jT=o(" head on top."),CT=p(),Li=r("p"),PT=o("This model inherits from "),jc=r("a"),qT=o("TFPreTrainedModel"),AT=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),OT=p(),Ii=r("p"),LT=o("This model is also a "),Si=r("a"),IT=o("tf.keras.Model"),ST=o(` 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.`),NT=p(),w(_n.$$.fragment),RT=p(),$t=r("div"),w(Ni.$$.fragment),WT=p(),ls=r("p"),QT=o("The "),Cc=r("a"),UT=o("TFDistilBertForMaskedLM"),HT=o(" forward method, overrides the "),rh=r("code"),KT=o("__call__"),VT=o(" special method."),JT=p(),w(bn.$$.fragment),GT=p(),w(vn.$$.fragment),XT=p(),w(kn.$$.fragment),em=p(),ds=r("h2"),wn=r("a"),ah=r("span"),w(Ri.$$.fragment),YT=p(),ih=r("span"),ZT=o("TFDistilBertForSequenceClassification"),tm=p(),ct=r("div"),w(Wi.$$.fragment),e$=p(),lh=r("p"),t$=o(`DistilBert Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),o$=p(),Qi=r("p"),s$=o("This model inherits from "),Pc=r("a"),n$=o("TFPreTrainedModel"),r$=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),a$=p(),Ui=r("p"),i$=o("This model is also a "),Hi=r("a"),l$=o("tf.keras.Model"),d$=o(` 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.`),c$=p(),w(Tn.$$.fragment),p$=p(),yt=r("div"),w(Ki.$$.fragment),h$=p(),cs=r("p"),f$=o("The "),qc=r("a"),u$=o("TFDistilBertForSequenceClassification"),m$=o(" forward method, overrides the "),dh=r("code"),g$=o("__call__"),_$=o(" special method."),b$=p(),w($n.$$.fragment),v$=p(),w(yn.$$.fragment),k$=p(),w(Dn.$$.fragment),om=p(),ps=r("h2"),Fn=r("a"),ch=r("span"),w(Vi.$$.fragment),w$=p(),ph=r("span"),T$=o("TFDistilBertForMultipleChoice"),sm=p(),pt=r("div"),w(Ji.$$.fragment),$$=p(),hh=r("p"),y$=o(`DistilBert Model with a multiple choice classification head on top (a linear layer on top of the pooled output and
a softmax) e.g. for RocStories/SWAG tasks.`),D$=p(),Gi=r("p"),F$=o("This model inherits from "),Ac=r("a"),E$=o("TFPreTrainedModel"),B$=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),x$=p(),Xi=r("p"),M$=o("This model is also a "),Yi=r("a"),z$=o("tf.keras.Model"),j$=o(` 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.`),C$=p(),w(En.$$.fragment),P$=p(),Wt=r("div"),w(Zi.$$.fragment),q$=p(),hs=r("p"),A$=o("The "),Oc=r("a"),O$=o("TFDistilBertForMultipleChoice"),L$=o(" forward method, overrides the "),fh=r("code"),I$=o("__call__"),S$=o(" special method."),N$=p(),w(Bn.$$.fragment),R$=p(),w(xn.$$.fragment),nm=p(),fs=r("h2"),Mn=r("a"),uh=r("span"),w(el.$$.fragment),W$=p(),mh=r("span"),Q$=o("TFDistilBertForTokenClassification"),rm=p(),ht=r("div"),w(tl.$$.fragment),U$=p(),gh=r("p"),H$=o(`DistilBert 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.`),K$=p(),ol=r("p"),V$=o("This model inherits from "),Lc=r("a"),J$=o("TFPreTrainedModel"),G$=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),X$=p(),sl=r("p"),Y$=o("This model is also a "),nl=r("a"),Z$=o("tf.keras.Model"),ey=o(` 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.`),ty=p(),w(zn.$$.fragment),oy=p(),Dt=r("div"),w(rl.$$.fragment),sy=p(),us=r("p"),ny=o("The "),Ic=r("a"),ry=o("TFDistilBertForTokenClassification"),ay=o(" forward method, overrides the "),_h=r("code"),iy=o("__call__"),ly=o(" special method."),dy=p(),w(jn.$$.fragment),cy=p(),w(Cn.$$.fragment),py=p(),w(Pn.$$.fragment),am=p(),ms=r("h2"),qn=r("a"),bh=r("span"),w(al.$$.fragment),hy=p(),vh=r("span"),fy=o("TFDistilBertForQuestionAnswering"),im=p(),ft=r("div"),w(il.$$.fragment),uy=p(),gs=r("p"),my=o(`DistilBert Model with a span classification head on top for extractive question-answering tasks like SQuAD (a
linear layer on top of the hidden-states output to compute `),kh=r("code"),gy=o("span start logits"),_y=o(" and "),wh=r("code"),by=o("span end logits"),vy=o(")."),ky=p(),ll=r("p"),wy=o("This model inherits from "),Sc=r("a"),Ty=o("TFPreTrainedModel"),$y=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),yy=p(),dl=r("p"),Dy=o("This model is also a "),cl=r("a"),Fy=o("tf.keras.Model"),Ey=o(` 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.`),By=p(),w(An.$$.fragment),xy=p(),Ft=r("div"),w(pl.$$.fragment),My=p(),_s=r("p"),zy=o("The "),Nc=r("a"),jy=o("TFDistilBertForQuestionAnswering"),Cy=o(" forward method, overrides the "),Th=r("code"),Py=o("__call__"),qy=o(" special method."),Ay=p(),w(On.$$.fragment),Oy=p(),w(Ln.$$.fragment),Ly=p(),w(In.$$.fragment),lm=p(),bs=r("h2"),Sn=r("a"),$h=r("span"),w(hl.$$.fragment),Iy=p(),yh=r("span"),Sy=o("FlaxDistilBertModel"),dm=p(),tt=r("div"),w(fl.$$.fragment),Ny=p(),Dh=r("p"),Ry=o("The bare DistilBert Model transformer outputting raw hidden-states without any specific head on top."),Wy=p(),ul=r("p"),Qy=o("This model inherits from "),Rc=r("a"),Uy=o("FlaxPreTrainedModel"),Hy=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),Ky=p(),ml=r("p"),Vy=o("This model is also a Flax Linen "),gl=r("a"),Jy=o("flax.linen.Module"),Gy=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Xy=p(),Fh=r("p"),Yy=o("Finally, this model supports inherent JAX features such as:"),Zy=p(),so=r("ul"),Eh=r("li"),_l=r("a"),e2=o("Just-In-Time (JIT) compilation"),t2=p(),Bh=r("li"),bl=r("a"),o2=o("Automatic Differentiation"),s2=p(),xh=r("li"),vl=r("a"),n2=o("Vectorization"),r2=p(),Mh=r("li"),kl=r("a"),a2=o("Parallelization"),i2=p(),Qt=r("div"),w(wl.$$.fragment),l2=p(),vs=r("p"),d2=o("The "),zh=r("code"),c2=o("FlaxDistilBertPreTrainedModel"),p2=o(" forward method, overrides the "),jh=r("code"),h2=o("__call__"),f2=o(" special method."),u2=p(),w(Nn.$$.fragment),m2=p(),w(Rn.$$.fragment),cm=p(),ks=r("h2"),Wn=r("a"),Ch=r("span"),w(Tl.$$.fragment),g2=p(),Ph=r("span"),_2=o("FlaxDistilBertForMaskedLM"),pm=p(),ot=r("div"),w($l.$$.fragment),b2=p(),yl=r("p"),v2=o("DistilBert Model with a "),qh=r("code"),k2=o("language modeling"),w2=o(" head on top."),T2=p(),Dl=r("p"),$2=o("This model inherits from "),Wc=r("a"),y2=o("FlaxPreTrainedModel"),D2=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),F2=p(),Fl=r("p"),E2=o("This model is also a Flax Linen "),El=r("a"),B2=o("flax.linen.Module"),x2=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),M2=p(),Ah=r("p"),z2=o("Finally, this model supports inherent JAX features such as:"),j2=p(),no=r("ul"),Oh=r("li"),Bl=r("a"),C2=o("Just-In-Time (JIT) compilation"),P2=p(),Lh=r("li"),xl=r("a"),q2=o("Automatic Differentiation"),A2=p(),Ih=r("li"),Ml=r("a"),O2=o("Vectorization"),L2=p(),Sh=r("li"),zl=r("a"),I2=o("Parallelization"),S2=p(),Ut=r("div"),w(jl.$$.fragment),N2=p(),ws=r("p"),R2=o("The "),Nh=r("code"),W2=o("FlaxDistilBertPreTrainedModel"),Q2=o(" forward method, overrides the "),Rh=r("code"),U2=o("__call__"),H2=o(" special method."),K2=p(),w(Qn.$$.fragment),V2=p(),w(Un.$$.fragment),hm=p(),Ts=r("h2"),Hn=r("a"),Wh=r("span"),w(Cl.$$.fragment),J2=p(),Qh=r("span"),G2=o("FlaxDistilBertForSequenceClassification"),fm=p(),st=r("div"),w(Pl.$$.fragment),X2=p(),Uh=r("p"),Y2=o(`DistilBert Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),Z2=p(),ql=r("p"),eD=o("This model inherits from "),Qc=r("a"),tD=o("FlaxPreTrainedModel"),oD=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),sD=p(),Al=r("p"),nD=o("This model is also a Flax Linen "),Ol=r("a"),rD=o("flax.linen.Module"),aD=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),iD=p(),Hh=r("p"),lD=o("Finally, this model supports inherent JAX features such as:"),dD=p(),ro=r("ul"),Kh=r("li"),Ll=r("a"),cD=o("Just-In-Time (JIT) compilation"),pD=p(),Vh=r("li"),Il=r("a"),hD=o("Automatic Differentiation"),fD=p(),Jh=r("li"),Sl=r("a"),uD=o("Vectorization"),mD=p(),Gh=r("li"),Nl=r("a"),gD=o("Parallelization"),_D=p(),Ht=r("div"),w(Rl.$$.fragment),bD=p(),$s=r("p"),vD=o("The "),Xh=r("code"),kD=o("FlaxDistilBertPreTrainedModel"),wD=o(" forward method, overrides the "),Yh=r("code"),TD=o("__call__"),$D=o(" special method."),yD=p(),w(Kn.$$.fragment),DD=p(),w(Vn.$$.fragment),um=p(),ys=r("h2"),Jn=r("a"),Zh=r("span"),w(Wl.$$.fragment),FD=p(),ef=r("span"),ED=o("FlaxDistilBertForMultipleChoice"),mm=p(),nt=r("div"),w(Ql.$$.fragment),BD=p(),tf=r("p"),xD=o(`DistilBert Model with a multiple choice classification head on top (a linear layer on top of the pooled output and
a softmax) e.g. for RocStories/SWAG tasks.`),MD=p(),Ul=r("p"),zD=o("This model inherits from "),Uc=r("a"),jD=o("FlaxPreTrainedModel"),CD=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),PD=p(),Hl=r("p"),qD=o("This model is also a Flax Linen "),Kl=r("a"),AD=o("flax.linen.Module"),OD=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),LD=p(),of=r("p"),ID=o("Finally, this model supports inherent JAX features such as:"),SD=p(),ao=r("ul"),sf=r("li"),Vl=r("a"),ND=o("Just-In-Time (JIT) compilation"),RD=p(),nf=r("li"),Jl=r("a"),WD=o("Automatic Differentiation"),QD=p(),rf=r("li"),Gl=r("a"),UD=o("Vectorization"),HD=p(),af=r("li"),Xl=r("a"),KD=o("Parallelization"),VD=p(),Kt=r("div"),w(Yl.$$.fragment),JD=p(),Ds=r("p"),GD=o("The "),lf=r("code"),XD=o("FlaxDistilBertPreTrainedModel"),YD=o(" forward method, overrides the "),df=r("code"),ZD=o("__call__"),eF=o(" special method."),tF=p(),w(Gn.$$.fragment),oF=p(),w(Xn.$$.fragment),gm=p(),Fs=r("h2"),Yn=r("a"),cf=r("span"),w(Zl.$$.fragment),sF=p(),pf=r("span"),nF=o("FlaxDistilBertForTokenClassification"),_m=p(),rt=r("div"),w(ed.$$.fragment),rF=p(),hf=r("p"),aF=o(`DistilBert 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.`),iF=p(),td=r("p"),lF=o("This model inherits from "),Hc=r("a"),dF=o("FlaxPreTrainedModel"),cF=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),pF=p(),od=r("p"),hF=o("This model is also a Flax Linen "),sd=r("a"),fF=o("flax.linen.Module"),uF=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),mF=p(),ff=r("p"),gF=o("Finally, this model supports inherent JAX features such as:"),_F=p(),io=r("ul"),uf=r("li"),nd=r("a"),bF=o("Just-In-Time (JIT) compilation"),vF=p(),mf=r("li"),rd=r("a"),kF=o("Automatic Differentiation"),wF=p(),gf=r("li"),ad=r("a"),TF=o("Vectorization"),$F=p(),_f=r("li"),id=r("a"),yF=o("Parallelization"),DF=p(),Vt=r("div"),w(ld.$$.fragment),FF=p(),Es=r("p"),EF=o("The "),bf=r("code"),BF=o("FlaxDistilBertPreTrainedModel"),xF=o(" forward method, overrides the "),vf=r("code"),MF=o("__call__"),zF=o(" special method."),jF=p(),w(Zn.$$.fragment),CF=p(),w(er.$$.fragment),bm=p(),Bs=r("h2"),tr=r("a"),kf=r("span"),w(dd.$$.fragment),PF=p(),wf=r("span"),qF=o("FlaxDistilBertForQuestionAnswering"),vm=p(),at=r("div"),w(cd.$$.fragment),AF=p(),xs=r("p"),OF=o(`DistilBert 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 `),Tf=r("code"),LF=o("span start logits"),IF=o(" and "),$f=r("code"),SF=o("span end logits"),NF=o(")."),RF=p(),pd=r("p"),WF=o("This model inherits from "),Kc=r("a"),QF=o("FlaxPreTrainedModel"),UF=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),HF=p(),hd=r("p"),KF=o("This model is also a Flax Linen "),fd=r("a"),VF=o("flax.linen.Module"),JF=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),GF=p(),yf=r("p"),XF=o("Finally, this model supports inherent JAX features such as:"),YF=p(),lo=r("ul"),Df=r("li"),ud=r("a"),ZF=o("Just-In-Time (JIT) compilation"),e4=p(),Ff=r("li"),md=r("a"),t4=o("Automatic Differentiation"),o4=p(),Ef=r("li"),gd=r("a"),s4=o("Vectorization"),n4=p(),Bf=r("li"),_d=r("a"),r4=o("Parallelization"),a4=p(),Jt=r("div"),w(bd.$$.fragment),i4=p(),Ms=r("p"),l4=o("The "),xf=r("code"),d4=o("FlaxDistilBertPreTrainedModel"),c4=o(" forward method, overrides the "),Mf=r("code"),p4=o("__call__"),h4=o(" special method."),f4=p(),w(or.$$.fragment),u4=p(),w(sr.$$.fragment),this.h()},l(n){const g=F5('[data-svelte="svelte-1phssyn"]',document.head);d=a(g,"META",{name:!0,content:!0}),g.forEach(t),b=h(n),f=a(n,"H1",{class:!0});var vd=i(f);m=a(vd,"A",{id:!0,class:!0,href:!0});var zf=i(m);v=a(zf,"SPAN",{});var jf=i(v);T(l.$$.fragment,jf),jf.forEach(t),zf.forEach(t),u=h(vd),M=a(vd,"SPAN",{});var Cf=i(M);we=s(Cf,"DistilBERT"),Cf.forEach(t),vd.forEach(t),ge=h(n),I=a(n,"H2",{class:!0});var kd=i(I);re=a(kd,"A",{id:!0,class:!0,href:!0});var Pf=i(re);oe=a(Pf,"SPAN",{});var qf=i(oe);T(E.$$.fragment,qf),qf.forEach(t),Pf.forEach(t),Te=h(kd),Q=a(kd,"SPAN",{});var Af=i(Q);$e=s(Af,"Overview"),Af.forEach(t),kd.forEach(t),_e=h(n),O=a(n,"P",{});var co=i(O);ye=s(co,"The DistilBERT model was proposed in the blog post "),ae=a(co,"A",{href:!0,rel:!0});var Of=i(ae);H=s(Of,`Smaller, faster, cheaper, lighter: Introducing DistilBERT, a
distilled version of BERT`),Of.forEach(t),De=s(co,", and the paper "),ie=a(co,"A",{href:!0,rel:!0});var Lf=i(ie);K=s(Lf,`DistilBERT, a
distilled version of BERT: smaller, faster, cheaper and lighter`),Lf.forEach(t),Fe=s(co,`. DistilBERT is a
small, fast, cheap and light Transformer model trained by distilling BERT base. It has 40% less parameters than
`),de=a(co,"EM",{});var If=i(de);V=s(If,"bert-base-uncased"),If.forEach(t),Ee=s(co,`, runs 60% faster while preserving over 95% of BERT\u2019s performances as measured on the GLUE language
understanding benchmark.`),co.forEach(t),be=h(n),ee=a(n,"P",{});var Sf=i(ee);j=s(Sf,"The abstract from the paper is the following:"),Sf.forEach(t),q=h(n),le=a(n,"P",{});var Nf=i(le);U=a(Nf,"EM",{});var Rf=i(U);Be=s(Rf,`As Transfer Learning from large-scale pre-trained models becomes more prevalent in Natural Language Processing (NLP),
operating these large models in on-the-edge and/or under constrained computational training or inference budgets
remains challenging. In this work, we propose a method to pre-train a smaller general-purpose language representation
model, called DistilBERT, which can then be fine-tuned with good performances on a wide range of tasks like its larger
counterparts. While most prior work investigated the use of distillation for building task-specific models, we leverage
knowledge distillation during the pretraining phase and show that it is possible to reduce the size of a BERT model by
40%, while retaining 97% of its language understanding capabilities and being 60% faster. To leverage the inductive
biases learned by larger models during pretraining, we introduce a triple loss combining language modeling,
distillation and cosine-distance losses. Our smaller, faster and lighter model is cheaper to pre-train and we
demonstrate its capabilities for on-device computations in a proof-of-concept experiment and a comparative on-device
study.`),Rf.forEach(t),Nf.forEach(t),ve=h(n),W=a(n,"P",{});var Wf=i(W);xe=s(Wf,"Tips:"),Wf.forEach(t),ke=h(n),C=a(n,"UL",{});var wd=i(C);se=a(wd,"LI",{});var po=i(se);J=s(po,"DistilBERT doesn\u2019t have "),ce=a(po,"CODE",{});var Qf=i(ce);Me=s(Qf,"token_type_ids"),Qf.forEach(t),G=s(po,`, you don\u2019t need to indicate which token belongs to which segment. Just
separate your segments with the separation token `),pe=a(po,"CODE",{});var Uf=i(pe);ze=s(Uf,"tokenizer.sep_token"),Uf.forEach(t),S=s(po," (or "),he=a(po,"CODE",{});var Hf=i(he);X=s(Hf,"[SEP]"),Hf.forEach(t),je=s(po,")."),po.forEach(t),ne=h(wd),P=a(wd,"LI",{});var Td=i(P);Ce=s(Td,"DistilBERT doesn\u2019t have options to select the input positions ("),A=a(Td,"CODE",{});var Kf=i(A);Pe=s(Kf,"position_ids"),Kf.forEach(t),qe=s(Td,` input). This could be added if
necessary though, just let us know if you need this option.`),Td.forEach(t),wd.forEach(t),k=h(n),x=a(n,"P",{});var ho=i(x);He=s(ho,"This model was contributed by "),Z=a(ho,"A",{href:!0,rel:!0});var Vf=i(Z);Ke=s(Vf,"victorsanh"),Vf.forEach(t),Ve=s(ho,`. This model jax version was
contributed by `),z=a(ho,"A",{href:!0,rel:!0});var Jf=i(z);Je=s(Jf,"kamalkraj"),Jf.forEach(t),Ge=s(ho,". The original code can be found "),Le=a(ho,"A",{href:!0,rel:!0});var Gf=i(Le);Xe=s(Gf,"here"),Gf.forEach(t),Ye=s(ho,"."),ho.forEach(t),L=h(n),N=a(n,"H2",{class:!0});var $d=i(N);Oe=a($d,"A",{id:!0,class:!0,href:!0});var Xf=i(Oe);Re=a(Xf,"SPAN",{});var Yf=i(Re);T(R.$$.fragment,Yf),Yf.forEach(t),Xf.forEach(t),Ze=h($d),We=a($d,"SPAN",{});var Zf=i(We);Ae=s(Zf,"Resources"),Zf.forEach(t),$d.forEach(t),Ue=h(n),te=a(n,"P",{});var eu=i(te);et=s(eu,"A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with DistilBERT. 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."),eu.forEach(t),gu=h(n),T(Er.$$.fragment,n),_u=h(n),Ie=a(n,"UL",{});var Qe=i(Ie);Br=a(Qe,"LI",{});var yd=i(Br);Ng=s(yd,"A blog post on "),xr=a(yd,"A",{href:!0,rel:!0});var tu=i(xr);Rg=s(tu,"Getting Started with Sentiment Analysis using Python"),tu.forEach(t),Wg=s(yd," with DistilBERT."),yd.forEach(t),Qg=h(Qe),Mr=a(Qe,"LI",{});var Dd=i(Mr);Ug=s(Dd,"A blog post on how to "),zr=a(Dd,"A",{href:!0,rel:!0});var ou=i(zr);Hg=s(ou,"train DistilBERT with Blurr for sequence classification"),ou.forEach(t),Kg=s(Dd,"."),Dd.forEach(t),Vg=h(Qe),jr=a(Qe,"LI",{});var Fd=i(jr);Jg=s(Fd,"A blog post on how to use "),Cr=a(Fd,"A",{href:!0,rel:!0});var su=i(Cr);Gg=s(su,"Ray to tune DistilBERT hyperparameters"),su.forEach(t),Xg=s(Fd,"."),Fd.forEach(t),Yg=h(Qe),Pr=a(Qe,"LI",{});var Ed=i(Pr);Zg=s(Ed,"A blog post on how to "),qr=a(Ed,"A",{href:!0,rel:!0});var nu=i(qr);e_=s(nu,"train DistilBERT with Hugging Face and Amazon SageMaker"),nu.forEach(t),t_=s(Ed,"."),Ed.forEach(t),o_=h(Qe),Ar=a(Qe,"LI",{});var Bd=i(Ar);s_=s(Bd,"A notebook on how to "),Or=a(Bd,"A",{href:!0,rel:!0});var ru=i(Or);n_=s(ru,"finetune DistilBERT for multi-label classification"),ru.forEach(t),r_=s(Bd,". \u{1F30E}"),Bd.forEach(t),a_=h(Qe),Lr=a(Qe,"LI",{});var xd=i(Lr);i_=s(xd,"A notebook on how to "),Ir=a(xd,"A",{href:!0,rel:!0});var au=i(Ir);l_=s(au,"finetune DistilBERT for multiclass classification with PyTorch"),au.forEach(t),d_=s(xd,". \u{1F30E}"),xd.forEach(t),c_=h(Qe),Sr=a(Qe,"LI",{});var Md=i(Sr);p_=s(Md,"A notebook on how to "),Nr=a(Md,"A",{href:!0,rel:!0});var iu=i(Nr);h_=s(iu,"finetune DistilBERT for text classification in TensorFlow"),iu.forEach(t),f_=s(Md,". \u{1F30E}"),Md.forEach(t),u_=h(Qe),fo=a(Qe,"LI",{});var Eo=i(fo);Nd=a(Eo,"A",{href:!0});var lu=i(Nd);m_=s(lu,"DistilBertForSequenceClassification"),lu.forEach(t),g_=s(Eo," is supported by this "),Rr=a(Eo,"A",{href:!0,rel:!0});var du=i(Rr);__=s(du,"example script"),du.forEach(t),b_=s(Eo," and "),Wr=a(Eo,"A",{href:!0,rel:!0});var cu=i(Wr);v_=s(cu,"notebook"),cu.forEach(t),k_=s(Eo,"."),Eo.forEach(t),w_=h(Qe),uo=a(Qe,"LI",{});var Bo=i(uo);Rd=a(Bo,"A",{href:!0});var pu=i(Rd);T_=s(pu,"TFDistilBertForSequenceClassification"),pu.forEach(t),$_=s(Bo," is supported by this "),Qr=a(Bo,"A",{href:!0,rel:!0});var b4=i(Qr);y_=s(b4,"example script"),b4.forEach(t),D_=s(Bo," and "),Ur=a(Bo,"A",{href:!0,rel:!0});var v4=i(Ur);F_=s(v4,"notebook"),v4.forEach(t),E_=s(Bo,"."),Bo.forEach(t),B_=h(Qe),mo=a(Qe,"LI",{});var zd=i(mo);Wd=a(zd,"A",{href:!0});var k4=i(Wd);x_=s(k4,"FlaxDistilBertForSequenceClassification"),k4.forEach(t),M_=s(zd," is supported by this "),Hr=a(zd,"A",{href:!0,rel:!0});var w4=i(Hr);z_=s(w4,"example script"),w4.forEach(t),j_=s(zd," and "),Kr=a(zd,"A",{href:!0,rel:!0});var T4=i(Kr);C_=s(T4,"notebook"),T4.forEach(t),P_=s(zd,"."),zd.forEach(t),Qe.forEach(t),bu=h(n),T(Vr.$$.fragment,n),vu=h(n),Ot=a(n,"UL",{});var nr=i(Ot);go=a(nr,"LI",{});var jd=i(go);Qd=a(jd,"A",{href:!0});var $4=i(Qd);q_=s($4,"DistilBertForTokenClassification"),$4.forEach(t),A_=s(jd," is supported by this "),Jr=a(jd,"A",{href:!0,rel:!0});var y4=i(Jr);O_=s(y4,"example script"),y4.forEach(t),L_=s(jd," and "),Gr=a(jd,"A",{href:!0,rel:!0});var D4=i(Gr);I_=s(D4,"notebook"),D4.forEach(t),S_=s(jd,"."),jd.forEach(t),N_=h(nr),_o=a(nr,"LI",{});var Cd=i(_o);Ud=a(Cd,"A",{href:!0});var F4=i(Ud);R_=s(F4,"TFDistilBertForTokenClassification"),F4.forEach(t),W_=s(Cd," is supported by this "),Xr=a(Cd,"A",{href:!0,rel:!0});var E4=i(Xr);Q_=s(E4,"example script"),E4.forEach(t),U_=s(Cd," and "),Yr=a(Cd,"A",{href:!0,rel:!0});var B4=i(Yr);H_=s(B4,"notebook"),B4.forEach(t),K_=s(Cd,"."),Cd.forEach(t),V_=h(nr),zs=a(nr,"LI",{});var hu=i(zs);Hd=a(hu,"A",{href:!0});var x4=i(Hd);J_=s(x4,"FlaxDistilBertForTokenClassification"),x4.forEach(t),G_=s(hu," is supported by this "),Zr=a(hu,"A",{href:!0,rel:!0});var M4=i(Zr);X_=s(M4,"example script"),M4.forEach(t),Y_=s(hu,"."),hu.forEach(t),Z_=h(nr),Kd=a(nr,"LI",{});var m4=i(Kd);ea=a(m4,"A",{href:!0,rel:!0});var z4=i(ea);eb=s(z4,"Token classification"),z4.forEach(t),tb=s(m4," chapter of the \u{1F917} Hugging Face Course."),m4.forEach(t),nr.forEach(t),ku=h(n),T(ta.$$.fragment,n),wu=h(n),Lt=a(n,"UL",{});var rr=i(Lt);bo=a(rr,"LI",{});var Pd=i(bo);Vd=a(Pd,"A",{href:!0});var j4=i(Vd);ob=s(j4,"DistilBertForMaskedLM"),j4.forEach(t),sb=s(Pd," is supported by this "),oa=a(Pd,"A",{href:!0,rel:!0});var C4=i(oa);nb=s(C4,"example script"),C4.forEach(t),rb=s(Pd," and "),sa=a(Pd,"A",{href:!0,rel:!0});var P4=i(sa);ab=s(P4,"notebook"),P4.forEach(t),ib=s(Pd,"."),Pd.forEach(t),lb=h(rr),vo=a(rr,"LI",{});var qd=i(vo);Jd=a(qd,"A",{href:!0});var q4=i(Jd);db=s(q4,"TFDistilBertForMaskedLM"),q4.forEach(t),cb=s(qd," is supported by this "),na=a(qd,"A",{href:!0,rel:!0});var A4=i(na);pb=s(A4,"example script"),A4.forEach(t),hb=s(qd," and "),ra=a(qd,"A",{href:!0,rel:!0});var O4=i(ra);fb=s(O4,"notebook"),O4.forEach(t),ub=s(qd,"."),qd.forEach(t),mb=h(rr),ko=a(rr,"LI",{});var Ad=i(ko);Gd=a(Ad,"A",{href:!0});var L4=i(Gd);gb=s(L4,"FlaxDistilBertForMaskedLM"),L4.forEach(t),_b=s(Ad," is supported by this "),aa=a(Ad,"A",{href:!0,rel:!0});var I4=i(aa);bb=s(I4,"example script"),I4.forEach(t),vb=s(Ad," and "),ia=a(Ad,"A",{href:!0,rel:!0});var S4=i(ia);kb=s(S4,"notebook"),S4.forEach(t),wb=s(Ad,"."),Ad.forEach(t),Tb=h(rr),Xd=a(rr,"LI",{});var g4=i(Xd);la=a(g4,"A",{href:!0,rel:!0});var N4=i(la);$b=s(N4,"Masked language modeling"),N4.forEach(t),yb=s(g4," chapter of the \u{1F917} Hugging Face Course."),g4.forEach(t),rr.forEach(t),Tu=h(n),T(da.$$.fragment,n),$u=h(n),It=a(n,"UL",{});var ar=i(It);wo=a(ar,"LI",{});var Od=i(wo);Yd=a(Od,"A",{href:!0});var R4=i(Yd);Db=s(R4,"DistilBertForQuestionAnswering"),R4.forEach(t),Fb=s(Od," is supported by this "),ca=a(Od,"A",{href:!0,rel:!0});var W4=i(ca);Eb=s(W4,"example script"),W4.forEach(t),Bb=s(Od," and "),pa=a(Od,"A",{href:!0,rel:!0});var Q4=i(pa);xb=s(Q4,"notebook"),Q4.forEach(t),Mb=s(Od,"."),Od.forEach(t),zb=h(ar),To=a(ar,"LI",{});var Ld=i(To);Zd=a(Ld,"A",{href:!0});var U4=i(Zd);jb=s(U4,"TFDistilBertForQuestionAnswering"),U4.forEach(t),Cb=s(Ld," is supported by this "),ha=a(Ld,"A",{href:!0,rel:!0});var H4=i(ha);Pb=s(H4,"example script"),H4.forEach(t),qb=s(Ld," and "),fa=a(Ld,"A",{href:!0,rel:!0});var K4=i(fa);Ab=s(K4,"notebook"),K4.forEach(t),Ob=s(Ld,"."),Ld.forEach(t),Lb=h(ar),js=a(ar,"LI",{});var fu=i(js);ec=a(fu,"A",{href:!0});var V4=i(ec);Ib=s(V4,"FlaxDistilBertForQuestionAnswering"),V4.forEach(t),Sb=s(fu," is supported by this "),ua=a(fu,"A",{href:!0,rel:!0});var J4=i(ua);Nb=s(J4,"example script"),J4.forEach(t),Rb=s(fu,"."),fu.forEach(t),Wb=h(ar),tc=a(ar,"LI",{});var _4=i(tc);ma=a(_4,"A",{href:!0,rel:!0});var G4=i(ma);Qb=s(G4,"Question answering"),G4.forEach(t),Ub=s(_4," chapter of the \u{1F917} Hugging Face Course."),_4.forEach(t),ar.forEach(t),yu=h(n),oc=a(n,"P",{});var X4=i(oc);bp=a(X4,"STRONG",{});var Y4=i(bp);Hb=s(Y4,"Multiple choice"),Y4.forEach(t),X4.forEach(t),Du=h(n),Cs=a(n,"UL",{});var wm=i(Cs);$o=a(wm,"LI",{});var Id=i($o);sc=a(Id,"A",{href:!0});var Z4=i(sc);Kb=s(Z4,"DistilBertForMultipleChoice"),Z4.forEach(t),Vb=s(Id," is supported by this "),ga=a(Id,"A",{href:!0,rel:!0});var eE=i(ga);Jb=s(eE,"example script"),eE.forEach(t),Gb=s(Id," and "),_a=a(Id,"A",{href:!0,rel:!0});var tE=i(_a);Xb=s(tE,"notebook"),tE.forEach(t),Yb=s(Id,"."),Id.forEach(t),Zb=h(wm),yo=a(wm,"LI",{});var Sd=i(yo);nc=a(Sd,"A",{href:!0});var oE=i(nc);ev=s(oE,"TFDistilBertForMultipleChoice"),oE.forEach(t),tv=s(Sd," is supported by this "),ba=a(Sd,"A",{href:!0,rel:!0});var sE=i(ba);ov=s(sE,"example script"),sE.forEach(t),sv=s(Sd," and "),va=a(Sd,"A",{href:!0,rel:!0});var nE=i(va);nv=s(nE,"notebook"),nE.forEach(t),rv=s(Sd,"."),Sd.forEach(t),wm.forEach(t),Fu=h(n),rc=a(n,"P",{});var rE=i(rc);av=s(rE,"\u2697\uFE0F Optimization"),rE.forEach(t),Eu=h(n),Do=a(n,"UL",{});var Vc=i(Do);ka=a(Vc,"LI",{});var Tm=i(ka);iv=s(Tm,"A blog post on how to "),wa=a(Tm,"A",{href:!0,rel:!0});var aE=i(wa);lv=s(aE,"quantize DistilBERT with \u{1F917} Optimum and Intel"),aE.forEach(t),dv=s(Tm,"."),Tm.forEach(t),cv=h(Vc),Ta=a(Vc,"LI",{});var $m=i(Ta);pv=s($m,"A blog post on how "),$a=a($m,"A",{href:!0,rel:!0});var iE=i($a);hv=s(iE,"Optimizing Transformers for GPUs with \u{1F917} Optimum"),iE.forEach(t),fv=s($m,"."),$m.forEach(t),uv=h(Vc),ya=a(Vc,"LI",{});var ym=i(ya);mv=s(ym,"A blog post on "),Da=a(ym,"A",{href:!0,rel:!0});var lE=i(Da);gv=s(lE,"Optimizing Transformers with Hugging Face Optimum"),lE.forEach(t),_v=s(ym,"."),ym.forEach(t),Vc.forEach(t),Bu=h(n),ac=a(n,"P",{});var dE=i(ac);bv=s(dE,"\u26A1\uFE0F Inference"),dE.forEach(t),xu=h(n),Ps=a(n,"UL",{});var Dm=i(Ps);Fa=a(Dm,"LI",{});var Fm=i(Fa);vv=s(Fm,"A blog post on how to "),Ea=a(Fm,"A",{href:!0,rel:!0});var cE=i(Ea);kv=s(cE,"Accelerate BERT inference with Hugging Face Transformers and AWS Inferentia"),cE.forEach(t),wv=s(Fm," with DistilBERT."),Fm.forEach(t),Tv=h(Dm),Ba=a(Dm,"LI",{});var Em=i(Ba);$v=s(Em,"A blog post on "),xa=a(Em,"A",{href:!0,rel:!0});var pE=i(xa);yv=s(pE,"Serverless Inference with Hugging Face\u2019s Transformers, DistilBERT and Amazon SageMaker"),pE.forEach(t),Dv=s(Em,"."),Em.forEach(t),Dm.forEach(t),Mu=h(n),ic=a(n,"P",{});var hE=i(ic);Fv=s(hE,"\u{1F680} Deploy"),hE.forEach(t),zu=h(n),Fo=a(n,"UL",{});var Jc=i(Fo);Ma=a(Jc,"LI",{});var Bm=i(Ma);Ev=s(Bm,"A blog post on how to "),za=a(Bm,"A",{href:!0,rel:!0});var fE=i(za);Bv=s(fE,"deploy DistilBERT on Google Cloud"),fE.forEach(t),xv=s(Bm,"."),Bm.forEach(t),Mv=h(Jc),ja=a(Jc,"LI",{});var xm=i(ja);zv=s(xm,"A blog post on how to "),Ca=a(xm,"A",{href:!0,rel:!0});var uE=i(Ca);jv=s(uE,"deploy DistilBERT with Amazon SageMaker"),uE.forEach(t),Cv=s(xm,"."),xm.forEach(t),Pv=h(Jc),Pa=a(Jc,"LI",{});var Mm=i(Pa);qv=s(Mm,"A blog post on how to "),qa=a(Mm,"A",{href:!0,rel:!0});var mE=i(qa);Av=s(mE,"Deploy BERT with Hugging Face Transformers, Amazon SageMaker and Terraform module"),mE.forEach(t),Ov=s(Mm,"."),Mm.forEach(t),Jc.forEach(t),ju=h(n),Ro=a(n,"H2",{class:!0});var zm=i(Ro);qs=a(zm,"A",{id:!0,class:!0,href:!0});var gE=i(qs);vp=a(gE,"SPAN",{});var _E=i(vp);T(Aa.$$.fragment,_E),_E.forEach(t),gE.forEach(t),Lv=h(zm),kp=a(zm,"SPAN",{});var bE=i(kp);Iv=s(bE,"DistilBertConfig"),bE.forEach(t),zm.forEach(t),Cu=h(n),Pt=a(n,"DIV",{class:!0});var ir=i(Pt);T(Oa.$$.fragment,ir),Sv=h(ir),oo=a(ir,"P",{});var lr=i(oo);Nv=s(lr,"This is the configuration class to store the configuration of a "),lc=a(lr,"A",{href:!0});var vE=i(lc);Rv=s(vE,"DistilBertModel"),vE.forEach(t),Wv=s(lr," or a "),dc=a(lr,"A",{href:!0});var kE=i(dc);Qv=s(kE,"TFDistilBertModel"),kE.forEach(t),Uv=s(lr,`. It
is used to instantiate a DistilBERT 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 DistilBERT
`),La=a(lr,"A",{href:!0,rel:!0});var wE=i(La);Hv=s(wE,"distilbert-base-uncased"),wE.forEach(t),Kv=s(lr," architecture."),lr.forEach(t),Vv=h(ir),Wo=a(ir,"P",{});var Gc=i(Wo);Jv=s(Gc,"Configuration objects inherit from "),cc=a(Gc,"A",{href:!0});var TE=i(cc);Gv=s(TE,"PretrainedConfig"),TE.forEach(t),Xv=s(Gc,` and can be used to control the model outputs. Read the
documentation from `),pc=a(Gc,"A",{href:!0});var $E=i(pc);Yv=s($E,"PretrainedConfig"),$E.forEach(t),Zv=s(Gc," for more information."),Gc.forEach(t),ek=h(ir),T(As.$$.fragment,ir),ir.forEach(t),Pu=h(n),Qo=a(n,"H2",{class:!0});var jm=i(Qo);Os=a(jm,"A",{id:!0,class:!0,href:!0});var yE=i(Os);wp=a(yE,"SPAN",{});var DE=i(wp);T(Ia.$$.fragment,DE),DE.forEach(t),yE.forEach(t),tk=h(jm),Tp=a(jm,"SPAN",{});var FE=i(Tp);ok=s(FE,"DistilBertTokenizer"),FE.forEach(t),jm.forEach(t),qu=h(n),qt=a(n,"DIV",{class:!0});var dr=i(qt);T(Sa.$$.fragment,dr),sk=h(dr),$p=a(dr,"P",{});var EE=i($p);nk=s(EE,"Construct a DistilBERT tokenizer."),EE.forEach(t),rk=h(dr),Ls=a(dr,"P",{});var uu=i(Ls);hc=a(uu,"A",{href:!0});var BE=i(hc);ak=s(BE,"DistilBertTokenizer"),BE.forEach(t),ik=s(uu," is identical to "),fc=a(uu,"A",{href:!0});var xE=i(fc);lk=s(xE,"BertTokenizer"),xE.forEach(t),dk=s(uu,` and runs end-to-end tokenization: punctuation splitting
and wordpiece.`),uu.forEach(t),ck=h(dr),Na=a(dr,"P",{});var Cm=i(Na);pk=s(Cm,"Refer to superclass "),uc=a(Cm,"A",{href:!0});var ME=i(uc);hk=s(ME,"BertTokenizer"),ME.forEach(t),fk=s(Cm," for usage examples and documentation concerning parameters."),Cm.forEach(t),dr.forEach(t),Au=h(n),Uo=a(n,"H2",{class:!0});var Pm=i(Uo);Is=a(Pm,"A",{id:!0,class:!0,href:!0});var zE=i(Is);yp=a(zE,"SPAN",{});var jE=i(yp);T(Ra.$$.fragment,jE),jE.forEach(t),zE.forEach(t),uk=h(Pm),Dp=a(Pm,"SPAN",{});var CE=i(Dp);mk=s(CE,"DistilBertTokenizerFast"),CE.forEach(t),Pm.forEach(t),Ou=h(n),At=a(n,"DIV",{class:!0});var cr=i(At);T(Wa.$$.fragment,cr),gk=h(cr),Qa=a(cr,"P",{});var qm=i(Qa);_k=s(qm,"Construct a \u201Cfast\u201D DistilBERT tokenizer (backed by HuggingFace\u2019s "),Fp=a(qm,"EM",{});var PE=i(Fp);bk=s(PE,"tokenizers"),PE.forEach(t),vk=s(qm," library)."),qm.forEach(t),kk=h(cr),Ss=a(cr,"P",{});var mu=i(Ss);mc=a(mu,"A",{href:!0});var qE=i(mc);wk=s(qE,"DistilBertTokenizerFast"),qE.forEach(t),Tk=s(mu," is identical to "),gc=a(mu,"A",{href:!0});var AE=i(gc);$k=s(AE,"BertTokenizerFast"),AE.forEach(t),yk=s(mu,` and runs end-to-end tokenization: punctuation
splitting and wordpiece.`),mu.forEach(t),Dk=h(cr),Ua=a(cr,"P",{});var Am=i(Ua);Fk=s(Am,"Refer to superclass "),_c=a(Am,"A",{href:!0});var OE=i(_c);Ek=s(OE,"BertTokenizerFast"),OE.forEach(t),Bk=s(Am," for usage examples and documentation concerning parameters."),Am.forEach(t),cr.forEach(t),Lu=h(n),Ho=a(n,"H2",{class:!0});var Om=i(Ho);Ns=a(Om,"A",{id:!0,class:!0,href:!0});var LE=i(Ns);Ep=a(LE,"SPAN",{});var IE=i(Ep);T(Ha.$$.fragment,IE),IE.forEach(t),LE.forEach(t),xk=h(Om),Bp=a(Om,"SPAN",{});var SE=i(Bp);Mk=s(SE,"DistilBertModel"),SE.forEach(t),Om.forEach(t),Iu=h(n),ut=a(n,"DIV",{class:!0});var xo=i(ut);T(Ka.$$.fragment,xo),zk=h(xo),xp=a(xo,"P",{});var NE=i(xp);jk=s(NE,"The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),NE.forEach(t),Ck=h(xo),Va=a(xo,"P",{});var Lm=i(Va);Pk=s(Lm,"This model inherits from "),bc=a(Lm,"A",{href:!0});var RE=i(bc);qk=s(RE,"PreTrainedModel"),RE.forEach(t),Ak=s(Lm,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Lm.forEach(t),Ok=h(xo),Ja=a(xo,"P",{});var Im=i(Ja);Lk=s(Im,"This model is also a PyTorch "),Ga=a(Im,"A",{href:!0,rel:!0});var WE=i(Ga);Ik=s(WE,"torch.nn.Module"),WE.forEach(t),Sk=s(Im,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Im.forEach(t),Nk=h(xo),St=a(xo,"DIV",{class:!0});var pr=i(St);T(Xa.$$.fragment,pr),Rk=h(pr),Ko=a(pr,"P",{});var Xc=i(Ko);Wk=s(Xc,"The "),vc=a(Xc,"A",{href:!0});var QE=i(vc);Qk=s(QE,"DistilBertModel"),QE.forEach(t),Uk=s(Xc," forward method, overrides the "),Mp=a(Xc,"CODE",{});var UE=i(Mp);Hk=s(UE,"__call__"),UE.forEach(t),Kk=s(Xc," special method."),Xc.forEach(t),Vk=h(pr),T(Rs.$$.fragment,pr),Jk=h(pr),T(Ws.$$.fragment,pr),pr.forEach(t),xo.forEach(t),Su=h(n),Vo=a(n,"H2",{class:!0});var Sm=i(Vo);Qs=a(Sm,"A",{id:!0,class:!0,href:!0});var HE=i(Qs);zp=a(HE,"SPAN",{});var KE=i(zp);T(Ya.$$.fragment,KE),KE.forEach(t),HE.forEach(t),Gk=h(Sm),jp=a(Sm,"SPAN",{});var VE=i(jp);Xk=s(VE,"DistilBertForMaskedLM"),VE.forEach(t),Sm.forEach(t),Nu=h(n),mt=a(n,"DIV",{class:!0});var Mo=i(mt);T(Za.$$.fragment,Mo),Yk=h(Mo),ei=a(Mo,"P",{});var Nm=i(ei);Zk=s(Nm,"DistilBert Model with a "),Cp=a(Nm,"CODE",{});var JE=i(Cp);ew=s(JE,"masked language modeling"),JE.forEach(t),tw=s(Nm," head on top."),Nm.forEach(t),ow=h(Mo),ti=a(Mo,"P",{});var Rm=i(ti);sw=s(Rm,"This model inherits from "),kc=a(Rm,"A",{href:!0});var GE=i(kc);nw=s(GE,"PreTrainedModel"),GE.forEach(t),rw=s(Rm,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Rm.forEach(t),aw=h(Mo),oi=a(Mo,"P",{});var Wm=i(oi);iw=s(Wm,"This model is also a PyTorch "),si=a(Wm,"A",{href:!0,rel:!0});var XE=i(si);lw=s(XE,"torch.nn.Module"),XE.forEach(t),dw=s(Wm,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Wm.forEach(t),cw=h(Mo),kt=a(Mo,"DIV",{class:!0});var zo=i(kt);T(ni.$$.fragment,zo),pw=h(zo),Jo=a(zo,"P",{});var Yc=i(Jo);hw=s(Yc,"The "),wc=a(Yc,"A",{href:!0});var YE=i(wc);fw=s(YE,"DistilBertForMaskedLM"),YE.forEach(t),uw=s(Yc," forward method, overrides the "),Pp=a(Yc,"CODE",{});var ZE=i(Pp);mw=s(ZE,"__call__"),ZE.forEach(t),gw=s(Yc," special method."),Yc.forEach(t),_w=h(zo),T(Us.$$.fragment,zo),bw=h(zo),T(Hs.$$.fragment,zo),vw=h(zo),T(Ks.$$.fragment,zo),zo.forEach(t),Mo.forEach(t),Ru=h(n),Go=a(n,"H2",{class:!0});var Qm=i(Go);Vs=a(Qm,"A",{id:!0,class:!0,href:!0});var e0=i(Vs);qp=a(e0,"SPAN",{});var t0=i(qp);T(ri.$$.fragment,t0),t0.forEach(t),e0.forEach(t),kw=h(Qm),Ap=a(Qm,"SPAN",{});var o0=i(Ap);ww=s(o0,"DistilBertForSequenceClassification"),o0.forEach(t),Qm.forEach(t),Wu=h(n),gt=a(n,"DIV",{class:!0});var jo=i(gt);T(ai.$$.fragment,jo),Tw=h(jo),Op=a(jo,"P",{});var s0=i(Op);$w=s(s0,`DistilBert Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),s0.forEach(t),yw=h(jo),ii=a(jo,"P",{});var Um=i(ii);Dw=s(Um,"This model inherits from "),Tc=a(Um,"A",{href:!0});var n0=i(Tc);Fw=s(n0,"PreTrainedModel"),n0.forEach(t),Ew=s(Um,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Um.forEach(t),Bw=h(jo),li=a(jo,"P",{});var Hm=i(li);xw=s(Hm,"This model is also a PyTorch "),di=a(Hm,"A",{href:!0,rel:!0});var r0=i(di);Mw=s(r0,"torch.nn.Module"),r0.forEach(t),zw=s(Hm,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Hm.forEach(t),jw=h(jo),it=a(jo,"DIV",{class:!0});var Et=i(it);T(ci.$$.fragment,Et),Cw=h(Et),Xo=a(Et,"P",{});var Zc=i(Xo);Pw=s(Zc,"The "),$c=a(Zc,"A",{href:!0});var a0=i($c);qw=s(a0,"DistilBertForSequenceClassification"),a0.forEach(t),Aw=s(Zc," forward method, overrides the "),Lp=a(Zc,"CODE",{});var i0=i(Lp);Ow=s(i0,"__call__"),i0.forEach(t),Lw=s(Zc," special method."),Zc.forEach(t),Iw=h(Et),T(Js.$$.fragment,Et),Sw=h(Et),T(Gs.$$.fragment,Et),Nw=h(Et),T(Xs.$$.fragment,Et),Rw=h(Et),T(Ys.$$.fragment,Et),Ww=h(Et),T(Zs.$$.fragment,Et),Et.forEach(t),jo.forEach(t),Qu=h(n),Yo=a(n,"H2",{class:!0});var Km=i(Yo);en=a(Km,"A",{id:!0,class:!0,href:!0});var l0=i(en);Ip=a(l0,"SPAN",{});var d0=i(Ip);T(pi.$$.fragment,d0),d0.forEach(t),l0.forEach(t),Qw=h(Km),Sp=a(Km,"SPAN",{});var c0=i(Sp);Uw=s(c0,"DistilBertForMultipleChoice"),c0.forEach(t),Km.forEach(t),Uu=h(n),_t=a(n,"DIV",{class:!0});var Co=i(_t);T(hi.$$.fragment,Co),Hw=h(Co),Np=a(Co,"P",{});var p0=i(Np);Kw=s(p0,`DistilBert Model with a multiple choice classification head on top (a linear layer on top of the pooled output and
a softmax) e.g. for RocStories/SWAG tasks.`),p0.forEach(t),Vw=h(Co),fi=a(Co,"P",{});var Vm=i(fi);Jw=s(Vm,"This model inherits from "),yc=a(Vm,"A",{href:!0});var h0=i(yc);Gw=s(h0,"PreTrainedModel"),h0.forEach(t),Xw=s(Vm,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Vm.forEach(t),Yw=h(Co),ui=a(Co,"P",{});var Jm=i(ui);Zw=s(Jm,"This model is also a PyTorch "),mi=a(Jm,"A",{href:!0,rel:!0});var f0=i(mi);e1=s(f0,"torch.nn.Module"),f0.forEach(t),t1=s(Jm,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Jm.forEach(t),o1=h(Co),Nt=a(Co,"DIV",{class:!0});var hr=i(Nt);T(gi.$$.fragment,hr),s1=h(hr),Zo=a(hr,"P",{});var ep=i(Zo);n1=s(ep,"The "),Dc=a(ep,"A",{href:!0});var u0=i(Dc);r1=s(u0,"DistilBertForMultipleChoice"),u0.forEach(t),a1=s(ep," forward method, overrides the "),Rp=a(ep,"CODE",{});var m0=i(Rp);i1=s(m0,"__call__"),m0.forEach(t),l1=s(ep," special method."),ep.forEach(t),d1=h(hr),T(tn.$$.fragment,hr),c1=h(hr),T(on.$$.fragment,hr),hr.forEach(t),Co.forEach(t),Hu=h(n),es=a(n,"H2",{class:!0});var Gm=i(es);sn=a(Gm,"A",{id:!0,class:!0,href:!0});var g0=i(sn);Wp=a(g0,"SPAN",{});var _0=i(Wp);T(_i.$$.fragment,_0),_0.forEach(t),g0.forEach(t),p1=h(Gm),Qp=a(Gm,"SPAN",{});var b0=i(Qp);h1=s(b0,"DistilBertForTokenClassification"),b0.forEach(t),Gm.forEach(t),Ku=h(n),bt=a(n,"DIV",{class:!0});var Po=i(bt);T(bi.$$.fragment,Po),f1=h(Po),Up=a(Po,"P",{});var v0=i(Up);u1=s(v0,`DistilBert 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.`),v0.forEach(t),m1=h(Po),vi=a(Po,"P",{});var Xm=i(vi);g1=s(Xm,"This model inherits from "),Fc=a(Xm,"A",{href:!0});var k0=i(Fc);_1=s(k0,"PreTrainedModel"),k0.forEach(t),b1=s(Xm,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Xm.forEach(t),v1=h(Po),ki=a(Po,"P",{});var Ym=i(ki);k1=s(Ym,"This model is also a PyTorch "),wi=a(Ym,"A",{href:!0,rel:!0});var w0=i(wi);w1=s(w0,"torch.nn.Module"),w0.forEach(t),T1=s(Ym,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Ym.forEach(t),$1=h(Po),wt=a(Po,"DIV",{class:!0});var qo=i(wt);T(Ti.$$.fragment,qo),y1=h(qo),ts=a(qo,"P",{});var tp=i(ts);D1=s(tp,"The "),Ec=a(tp,"A",{href:!0});var T0=i(Ec);F1=s(T0,"DistilBertForTokenClassification"),T0.forEach(t),E1=s(tp," forward method, overrides the "),Hp=a(tp,"CODE",{});var $0=i(Hp);B1=s($0,"__call__"),$0.forEach(t),x1=s(tp," special method."),tp.forEach(t),M1=h(qo),T(nn.$$.fragment,qo),z1=h(qo),T(rn.$$.fragment,qo),j1=h(qo),T(an.$$.fragment,qo),qo.forEach(t),Po.forEach(t),Vu=h(n),os=a(n,"H2",{class:!0});var Zm=i(os);ln=a(Zm,"A",{id:!0,class:!0,href:!0});var y0=i(ln);Kp=a(y0,"SPAN",{});var D0=i(Kp);T($i.$$.fragment,D0),D0.forEach(t),y0.forEach(t),C1=h(Zm),Vp=a(Zm,"SPAN",{});var F0=i(Vp);P1=s(F0,"DistilBertForQuestionAnswering"),F0.forEach(t),Zm.forEach(t),Ju=h(n),vt=a(n,"DIV",{class:!0});var Ao=i(vt);T(yi.$$.fragment,Ao),q1=h(Ao),ss=a(Ao,"P",{});var op=i(ss);A1=s(op,`DistilBert 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 `),Jp=a(op,"CODE",{});var E0=i(Jp);O1=s(E0,"span start logits"),E0.forEach(t),L1=s(op," and "),Gp=a(op,"CODE",{});var B0=i(Gp);I1=s(B0,"span end logits"),B0.forEach(t),S1=s(op,")."),op.forEach(t),N1=h(Ao),Di=a(Ao,"P",{});var eg=i(Di);R1=s(eg,"This model inherits from "),Bc=a(eg,"A",{href:!0});var x0=i(Bc);W1=s(x0,"PreTrainedModel"),x0.forEach(t),Q1=s(eg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),eg.forEach(t),U1=h(Ao),Fi=a(Ao,"P",{});var tg=i(Fi);H1=s(tg,"This model is also a PyTorch "),Ei=a(tg,"A",{href:!0,rel:!0});var M0=i(Ei);K1=s(M0,"torch.nn.Module"),M0.forEach(t),V1=s(tg,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),tg.forEach(t),J1=h(Ao),Tt=a(Ao,"DIV",{class:!0});var Oo=i(Tt);T(Bi.$$.fragment,Oo),G1=h(Oo),ns=a(Oo,"P",{});var sp=i(ns);X1=s(sp,"The "),xc=a(sp,"A",{href:!0});var z0=i(xc);Y1=s(z0,"DistilBertForQuestionAnswering"),z0.forEach(t),Z1=s(sp," forward method, overrides the "),Xp=a(sp,"CODE",{});var j0=i(Xp);eT=s(j0,"__call__"),j0.forEach(t),tT=s(sp," special method."),sp.forEach(t),oT=h(Oo),T(dn.$$.fragment,Oo),sT=h(Oo),T(cn.$$.fragment,Oo),nT=h(Oo),T(pn.$$.fragment,Oo),Oo.forEach(t),Ao.forEach(t),Gu=h(n),rs=a(n,"H2",{class:!0});var og=i(rs);hn=a(og,"A",{id:!0,class:!0,href:!0});var C0=i(hn);Yp=a(C0,"SPAN",{});var P0=i(Yp);T(xi.$$.fragment,P0),P0.forEach(t),C0.forEach(t),rT=h(og),Zp=a(og,"SPAN",{});var q0=i(Zp);aT=s(q0,"TFDistilBertModel"),q0.forEach(t),og.forEach(t),Xu=h(n),lt=a(n,"DIV",{class:!0});var Gt=i(lt);T(Mi.$$.fragment,Gt),iT=h(Gt),eh=a(Gt,"P",{});var A0=i(eh);lT=s(A0,"The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),A0.forEach(t),dT=h(Gt),zi=a(Gt,"P",{});var sg=i(zi);cT=s(sg,"This model inherits from "),Mc=a(sg,"A",{href:!0});var O0=i(Mc);pT=s(O0,"TFPreTrainedModel"),O0.forEach(t),hT=s(sg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),sg.forEach(t),fT=h(Gt),ji=a(Gt,"P",{});var ng=i(ji);uT=s(ng,"This model is also a "),Ci=a(ng,"A",{href:!0,rel:!0});var L0=i(Ci);mT=s(L0,"tf.keras.Model"),L0.forEach(t),gT=s(ng,` 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.`),ng.forEach(t),_T=h(Gt),T(fn.$$.fragment,Gt),bT=h(Gt),Rt=a(Gt,"DIV",{class:!0});var fr=i(Rt);T(Pi.$$.fragment,fr),vT=h(fr),as=a(fr,"P",{});var np=i(as);kT=s(np,"The "),zc=a(np,"A",{href:!0});var I0=i(zc);wT=s(I0,"TFDistilBertModel"),I0.forEach(t),TT=s(np," forward method, overrides the "),th=a(np,"CODE",{});var S0=i(th);$T=s(S0,"__call__"),S0.forEach(t),yT=s(np," special method."),np.forEach(t),DT=h(fr),T(un.$$.fragment,fr),FT=h(fr),T(mn.$$.fragment,fr),fr.forEach(t),Gt.forEach(t),Yu=h(n),is=a(n,"H2",{class:!0});var rg=i(is);gn=a(rg,"A",{id:!0,class:!0,href:!0});var N0=i(gn);oh=a(N0,"SPAN",{});var R0=i(oh);T(qi.$$.fragment,R0),R0.forEach(t),N0.forEach(t),ET=h(rg),sh=a(rg,"SPAN",{});var W0=i(sh);BT=s(W0,"TFDistilBertForMaskedLM"),W0.forEach(t),rg.forEach(t),Zu=h(n),dt=a(n,"DIV",{class:!0});var Xt=i(dt);T(Ai.$$.fragment,Xt),xT=h(Xt),Oi=a(Xt,"P",{});var ag=i(Oi);MT=s(ag,"DistilBert Model with a "),nh=a(ag,"CODE",{});var Q0=i(nh);zT=s(Q0,"masked language modeling"),Q0.forEach(t),jT=s(ag," head on top."),ag.forEach(t),CT=h(Xt),Li=a(Xt,"P",{});var ig=i(Li);PT=s(ig,"This model inherits from "),jc=a(ig,"A",{href:!0});var U0=i(jc);qT=s(U0,"TFPreTrainedModel"),U0.forEach(t),AT=s(ig,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ig.forEach(t),OT=h(Xt),Ii=a(Xt,"P",{});var lg=i(Ii);LT=s(lg,"This model is also a "),Si=a(lg,"A",{href:!0,rel:!0});var H0=i(Si);IT=s(H0,"tf.keras.Model"),H0.forEach(t),ST=s(lg,` 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.`),lg.forEach(t),NT=h(Xt),T(_n.$$.fragment,Xt),RT=h(Xt),$t=a(Xt,"DIV",{class:!0});var Lo=i($t);T(Ni.$$.fragment,Lo),WT=h(Lo),ls=a(Lo,"P",{});var rp=i(ls);QT=s(rp,"The "),Cc=a(rp,"A",{href:!0});var K0=i(Cc);UT=s(K0,"TFDistilBertForMaskedLM"),K0.forEach(t),HT=s(rp," forward method, overrides the "),rh=a(rp,"CODE",{});var V0=i(rh);KT=s(V0,"__call__"),V0.forEach(t),VT=s(rp," special method."),rp.forEach(t),JT=h(Lo),T(bn.$$.fragment,Lo),GT=h(Lo),T(vn.$$.fragment,Lo),XT=h(Lo),T(kn.$$.fragment,Lo),Lo.forEach(t),Xt.forEach(t),em=h(n),ds=a(n,"H2",{class:!0});var dg=i(ds);wn=a(dg,"A",{id:!0,class:!0,href:!0});var J0=i(wn);ah=a(J0,"SPAN",{});var G0=i(ah);T(Ri.$$.fragment,G0),G0.forEach(t),J0.forEach(t),YT=h(dg),ih=a(dg,"SPAN",{});var X0=i(ih);ZT=s(X0,"TFDistilBertForSequenceClassification"),X0.forEach(t),dg.forEach(t),tm=h(n),ct=a(n,"DIV",{class:!0});var Yt=i(ct);T(Wi.$$.fragment,Yt),e$=h(Yt),lh=a(Yt,"P",{});var Y0=i(lh);t$=s(Y0,`DistilBert Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),Y0.forEach(t),o$=h(Yt),Qi=a(Yt,"P",{});var cg=i(Qi);s$=s(cg,"This model inherits from "),Pc=a(cg,"A",{href:!0});var Z0=i(Pc);n$=s(Z0,"TFPreTrainedModel"),Z0.forEach(t),r$=s(cg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),cg.forEach(t),a$=h(Yt),Ui=a(Yt,"P",{});var pg=i(Ui);i$=s(pg,"This model is also a "),Hi=a(pg,"A",{href:!0,rel:!0});var eB=i(Hi);l$=s(eB,"tf.keras.Model"),eB.forEach(t),d$=s(pg,` 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.`),pg.forEach(t),c$=h(Yt),T(Tn.$$.fragment,Yt),p$=h(Yt),yt=a(Yt,"DIV",{class:!0});var Io=i(yt);T(Ki.$$.fragment,Io),h$=h(Io),cs=a(Io,"P",{});var ap=i(cs);f$=s(ap,"The "),qc=a(ap,"A",{href:!0});var tB=i(qc);u$=s(tB,"TFDistilBertForSequenceClassification"),tB.forEach(t),m$=s(ap," forward method, overrides the "),dh=a(ap,"CODE",{});var oB=i(dh);g$=s(oB,"__call__"),oB.forEach(t),_$=s(ap," special method."),ap.forEach(t),b$=h(Io),T($n.$$.fragment,Io),v$=h(Io),T(yn.$$.fragment,Io),k$=h(Io),T(Dn.$$.fragment,Io),Io.forEach(t),Yt.forEach(t),om=h(n),ps=a(n,"H2",{class:!0});var hg=i(ps);Fn=a(hg,"A",{id:!0,class:!0,href:!0});var sB=i(Fn);ch=a(sB,"SPAN",{});var nB=i(ch);T(Vi.$$.fragment,nB),nB.forEach(t),sB.forEach(t),w$=h(hg),ph=a(hg,"SPAN",{});var rB=i(ph);T$=s(rB,"TFDistilBertForMultipleChoice"),rB.forEach(t),hg.forEach(t),sm=h(n),pt=a(n,"DIV",{class:!0});var Zt=i(pt);T(Ji.$$.fragment,Zt),$$=h(Zt),hh=a(Zt,"P",{});var aB=i(hh);y$=s(aB,`DistilBert Model with a multiple choice classification head on top (a linear layer on top of the pooled output and
a softmax) e.g. for RocStories/SWAG tasks.`),aB.forEach(t),D$=h(Zt),Gi=a(Zt,"P",{});var fg=i(Gi);F$=s(fg,"This model inherits from "),Ac=a(fg,"A",{href:!0});var iB=i(Ac);E$=s(iB,"TFPreTrainedModel"),iB.forEach(t),B$=s(fg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),fg.forEach(t),x$=h(Zt),Xi=a(Zt,"P",{});var ug=i(Xi);M$=s(ug,"This model is also a "),Yi=a(ug,"A",{href:!0,rel:!0});var lB=i(Yi);z$=s(lB,"tf.keras.Model"),lB.forEach(t),j$=s(ug,` 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.`),ug.forEach(t),C$=h(Zt),T(En.$$.fragment,Zt),P$=h(Zt),Wt=a(Zt,"DIV",{class:!0});var ur=i(Wt);T(Zi.$$.fragment,ur),q$=h(ur),hs=a(ur,"P",{});var ip=i(hs);A$=s(ip,"The "),Oc=a(ip,"A",{href:!0});var dB=i(Oc);O$=s(dB,"TFDistilBertForMultipleChoice"),dB.forEach(t),L$=s(ip," forward method, overrides the "),fh=a(ip,"CODE",{});var cB=i(fh);I$=s(cB,"__call__"),cB.forEach(t),S$=s(ip," special method."),ip.forEach(t),N$=h(ur),T(Bn.$$.fragment,ur),R$=h(ur),T(xn.$$.fragment,ur),ur.forEach(t),Zt.forEach(t),nm=h(n),fs=a(n,"H2",{class:!0});var mg=i(fs);Mn=a(mg,"A",{id:!0,class:!0,href:!0});var pB=i(Mn);uh=a(pB,"SPAN",{});var hB=i(uh);T(el.$$.fragment,hB),hB.forEach(t),pB.forEach(t),W$=h(mg),mh=a(mg,"SPAN",{});var fB=i(mh);Q$=s(fB,"TFDistilBertForTokenClassification"),fB.forEach(t),mg.forEach(t),rm=h(n),ht=a(n,"DIV",{class:!0});var eo=i(ht);T(tl.$$.fragment,eo),U$=h(eo),gh=a(eo,"P",{});var uB=i(gh);H$=s(uB,`DistilBert 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.`),uB.forEach(t),K$=h(eo),ol=a(eo,"P",{});var gg=i(ol);V$=s(gg,"This model inherits from "),Lc=a(gg,"A",{href:!0});var mB=i(Lc);J$=s(mB,"TFPreTrainedModel"),mB.forEach(t),G$=s(gg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),gg.forEach(t),X$=h(eo),sl=a(eo,"P",{});var _g=i(sl);Y$=s(_g,"This model is also a "),nl=a(_g,"A",{href:!0,rel:!0});var gB=i(nl);Z$=s(gB,"tf.keras.Model"),gB.forEach(t),ey=s(_g,` 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.`),_g.forEach(t),ty=h(eo),T(zn.$$.fragment,eo),oy=h(eo),Dt=a(eo,"DIV",{class:!0});var So=i(Dt);T(rl.$$.fragment,So),sy=h(So),us=a(So,"P",{});var lp=i(us);ny=s(lp,"The "),Ic=a(lp,"A",{href:!0});var _B=i(Ic);ry=s(_B,"TFDistilBertForTokenClassification"),_B.forEach(t),ay=s(lp," forward method, overrides the "),_h=a(lp,"CODE",{});var bB=i(_h);iy=s(bB,"__call__"),bB.forEach(t),ly=s(lp," special method."),lp.forEach(t),dy=h(So),T(jn.$$.fragment,So),cy=h(So),T(Cn.$$.fragment,So),py=h(So),T(Pn.$$.fragment,So),So.forEach(t),eo.forEach(t),am=h(n),ms=a(n,"H2",{class:!0});var bg=i(ms);qn=a(bg,"A",{id:!0,class:!0,href:!0});var vB=i(qn);bh=a(vB,"SPAN",{});var kB=i(bh);T(al.$$.fragment,kB),kB.forEach(t),vB.forEach(t),hy=h(bg),vh=a(bg,"SPAN",{});var wB=i(vh);fy=s(wB,"TFDistilBertForQuestionAnswering"),wB.forEach(t),bg.forEach(t),im=h(n),ft=a(n,"DIV",{class:!0});var to=i(ft);T(il.$$.fragment,to),uy=h(to),gs=a(to,"P",{});var dp=i(gs);my=s(dp,`DistilBert Model with a span classification head on top for extractive question-answering tasks like SQuAD (a
linear layer on top of the hidden-states output to compute `),kh=a(dp,"CODE",{});var TB=i(kh);gy=s(TB,"span start logits"),TB.forEach(t),_y=s(dp," and "),wh=a(dp,"CODE",{});var $B=i(wh);by=s($B,"span end logits"),$B.forEach(t),vy=s(dp,")."),dp.forEach(t),ky=h(to),ll=a(to,"P",{});var vg=i(ll);wy=s(vg,"This model inherits from "),Sc=a(vg,"A",{href:!0});var yB=i(Sc);Ty=s(yB,"TFPreTrainedModel"),yB.forEach(t),$y=s(vg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),vg.forEach(t),yy=h(to),dl=a(to,"P",{});var kg=i(dl);Dy=s(kg,"This model is also a "),cl=a(kg,"A",{href:!0,rel:!0});var DB=i(cl);Fy=s(DB,"tf.keras.Model"),DB.forEach(t),Ey=s(kg,` 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.`),kg.forEach(t),By=h(to),T(An.$$.fragment,to),xy=h(to),Ft=a(to,"DIV",{class:!0});var No=i(Ft);T(pl.$$.fragment,No),My=h(No),_s=a(No,"P",{});var cp=i(_s);zy=s(cp,"The "),Nc=a(cp,"A",{href:!0});var FB=i(Nc);jy=s(FB,"TFDistilBertForQuestionAnswering"),FB.forEach(t),Cy=s(cp," forward method, overrides the "),Th=a(cp,"CODE",{});var EB=i(Th);Py=s(EB,"__call__"),EB.forEach(t),qy=s(cp," special method."),cp.forEach(t),Ay=h(No),T(On.$$.fragment,No),Oy=h(No),T(Ln.$$.fragment,No),Ly=h(No),T(In.$$.fragment,No),No.forEach(t),to.forEach(t),lm=h(n),bs=a(n,"H2",{class:!0});var wg=i(bs);Sn=a(wg,"A",{id:!0,class:!0,href:!0});var BB=i(Sn);$h=a(BB,"SPAN",{});var xB=i($h);T(hl.$$.fragment,xB),xB.forEach(t),BB.forEach(t),Iy=h(wg),yh=a(wg,"SPAN",{});var MB=i(yh);Sy=s(MB,"FlaxDistilBertModel"),MB.forEach(t),wg.forEach(t),dm=h(n),tt=a(n,"DIV",{class:!0});var Bt=i(tt);T(fl.$$.fragment,Bt),Ny=h(Bt),Dh=a(Bt,"P",{});var zB=i(Dh);Ry=s(zB,"The bare DistilBert Model transformer outputting raw hidden-states without any specific head on top."),zB.forEach(t),Wy=h(Bt),ul=a(Bt,"P",{});var Tg=i(ul);Qy=s(Tg,"This model inherits from "),Rc=a(Tg,"A",{href:!0});var jB=i(Rc);Uy=s(jB,"FlaxPreTrainedModel"),jB.forEach(t),Hy=s(Tg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),Tg.forEach(t),Ky=h(Bt),ml=a(Bt,"P",{});var $g=i(ml);Vy=s($g,"This model is also a Flax Linen "),gl=a($g,"A",{href:!0,rel:!0});var CB=i(gl);Jy=s(CB,"flax.linen.Module"),CB.forEach(t),Gy=s($g,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),$g.forEach(t),Xy=h(Bt),Fh=a(Bt,"P",{});var PB=i(Fh);Yy=s(PB,"Finally, this model supports inherent JAX features such as:"),PB.forEach(t),Zy=h(Bt),so=a(Bt,"UL",{});var mr=i(so);Eh=a(mr,"LI",{});var qB=i(Eh);_l=a(qB,"A",{href:!0,rel:!0});var AB=i(_l);e2=s(AB,"Just-In-Time (JIT) compilation"),AB.forEach(t),qB.forEach(t),t2=h(mr),Bh=a(mr,"LI",{});var OB=i(Bh);bl=a(OB,"A",{href:!0,rel:!0});var LB=i(bl);o2=s(LB,"Automatic Differentiation"),LB.forEach(t),OB.forEach(t),s2=h(mr),xh=a(mr,"LI",{});var IB=i(xh);vl=a(IB,"A",{href:!0,rel:!0});var SB=i(vl);n2=s(SB,"Vectorization"),SB.forEach(t),IB.forEach(t),r2=h(mr),Mh=a(mr,"LI",{});var NB=i(Mh);kl=a(NB,"A",{href:!0,rel:!0});var RB=i(kl);a2=s(RB,"Parallelization"),RB.forEach(t),NB.forEach(t),mr.forEach(t),i2=h(Bt),Qt=a(Bt,"DIV",{class:!0});var gr=i(Qt);T(wl.$$.fragment,gr),l2=h(gr),vs=a(gr,"P",{});var pp=i(vs);d2=s(pp,"The "),zh=a(pp,"CODE",{});var WB=i(zh);c2=s(WB,"FlaxDistilBertPreTrainedModel"),WB.forEach(t),p2=s(pp," forward method, overrides the "),jh=a(pp,"CODE",{});var QB=i(jh);h2=s(QB,"__call__"),QB.forEach(t),f2=s(pp," special method."),pp.forEach(t),u2=h(gr),T(Nn.$$.fragment,gr),m2=h(gr),T(Rn.$$.fragment,gr),gr.forEach(t),Bt.forEach(t),cm=h(n),ks=a(n,"H2",{class:!0});var yg=i(ks);Wn=a(yg,"A",{id:!0,class:!0,href:!0});var UB=i(Wn);Ch=a(UB,"SPAN",{});var HB=i(Ch);T(Tl.$$.fragment,HB),HB.forEach(t),UB.forEach(t),g2=h(yg),Ph=a(yg,"SPAN",{});var KB=i(Ph);_2=s(KB,"FlaxDistilBertForMaskedLM"),KB.forEach(t),yg.forEach(t),pm=h(n),ot=a(n,"DIV",{class:!0});var xt=i(ot);T($l.$$.fragment,xt),b2=h(xt),yl=a(xt,"P",{});var Dg=i(yl);v2=s(Dg,"DistilBert Model with a "),qh=a(Dg,"CODE",{});var VB=i(qh);k2=s(VB,"language modeling"),VB.forEach(t),w2=s(Dg," head on top."),Dg.forEach(t),T2=h(xt),Dl=a(xt,"P",{});var Fg=i(Dl);$2=s(Fg,"This model inherits from "),Wc=a(Fg,"A",{href:!0});var JB=i(Wc);y2=s(JB,"FlaxPreTrainedModel"),JB.forEach(t),D2=s(Fg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),Fg.forEach(t),F2=h(xt),Fl=a(xt,"P",{});var Eg=i(Fl);E2=s(Eg,"This model is also a Flax Linen "),El=a(Eg,"A",{href:!0,rel:!0});var GB=i(El);B2=s(GB,"flax.linen.Module"),GB.forEach(t),x2=s(Eg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Eg.forEach(t),M2=h(xt),Ah=a(xt,"P",{});var XB=i(Ah);z2=s(XB,"Finally, this model supports inherent JAX features such as:"),XB.forEach(t),j2=h(xt),no=a(xt,"UL",{});var _r=i(no);Oh=a(_r,"LI",{});var YB=i(Oh);Bl=a(YB,"A",{href:!0,rel:!0});var ZB=i(Bl);C2=s(ZB,"Just-In-Time (JIT) compilation"),ZB.forEach(t),YB.forEach(t),P2=h(_r),Lh=a(_r,"LI",{});var ex=i(Lh);xl=a(ex,"A",{href:!0,rel:!0});var tx=i(xl);q2=s(tx,"Automatic Differentiation"),tx.forEach(t),ex.forEach(t),A2=h(_r),Ih=a(_r,"LI",{});var ox=i(Ih);Ml=a(ox,"A",{href:!0,rel:!0});var sx=i(Ml);O2=s(sx,"Vectorization"),sx.forEach(t),ox.forEach(t),L2=h(_r),Sh=a(_r,"LI",{});var nx=i(Sh);zl=a(nx,"A",{href:!0,rel:!0});var rx=i(zl);I2=s(rx,"Parallelization"),rx.forEach(t),nx.forEach(t),_r.forEach(t),S2=h(xt),Ut=a(xt,"DIV",{class:!0});var br=i(Ut);T(jl.$$.fragment,br),N2=h(br),ws=a(br,"P",{});var hp=i(ws);R2=s(hp,"The "),Nh=a(hp,"CODE",{});var ax=i(Nh);W2=s(ax,"FlaxDistilBertPreTrainedModel"),ax.forEach(t),Q2=s(hp," forward method, overrides the "),Rh=a(hp,"CODE",{});var ix=i(Rh);U2=s(ix,"__call__"),ix.forEach(t),H2=s(hp," special method."),hp.forEach(t),K2=h(br),T(Qn.$$.fragment,br),V2=h(br),T(Un.$$.fragment,br),br.forEach(t),xt.forEach(t),hm=h(n),Ts=a(n,"H2",{class:!0});var Bg=i(Ts);Hn=a(Bg,"A",{id:!0,class:!0,href:!0});var lx=i(Hn);Wh=a(lx,"SPAN",{});var dx=i(Wh);T(Cl.$$.fragment,dx),dx.forEach(t),lx.forEach(t),J2=h(Bg),Qh=a(Bg,"SPAN",{});var cx=i(Qh);G2=s(cx,"FlaxDistilBertForSequenceClassification"),cx.forEach(t),Bg.forEach(t),fm=h(n),st=a(n,"DIV",{class:!0});var Mt=i(st);T(Pl.$$.fragment,Mt),X2=h(Mt),Uh=a(Mt,"P",{});var px=i(Uh);Y2=s(px,`DistilBert Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),px.forEach(t),Z2=h(Mt),ql=a(Mt,"P",{});var xg=i(ql);eD=s(xg,"This model inherits from "),Qc=a(xg,"A",{href:!0});var hx=i(Qc);tD=s(hx,"FlaxPreTrainedModel"),hx.forEach(t),oD=s(xg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),xg.forEach(t),sD=h(Mt),Al=a(Mt,"P",{});var Mg=i(Al);nD=s(Mg,"This model is also a Flax Linen "),Ol=a(Mg,"A",{href:!0,rel:!0});var fx=i(Ol);rD=s(fx,"flax.linen.Module"),fx.forEach(t),aD=s(Mg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Mg.forEach(t),iD=h(Mt),Hh=a(Mt,"P",{});var ux=i(Hh);lD=s(ux,"Finally, this model supports inherent JAX features such as:"),ux.forEach(t),dD=h(Mt),ro=a(Mt,"UL",{});var vr=i(ro);Kh=a(vr,"LI",{});var mx=i(Kh);Ll=a(mx,"A",{href:!0,rel:!0});var gx=i(Ll);cD=s(gx,"Just-In-Time (JIT) compilation"),gx.forEach(t),mx.forEach(t),pD=h(vr),Vh=a(vr,"LI",{});var _x=i(Vh);Il=a(_x,"A",{href:!0,rel:!0});var bx=i(Il);hD=s(bx,"Automatic Differentiation"),bx.forEach(t),_x.forEach(t),fD=h(vr),Jh=a(vr,"LI",{});var vx=i(Jh);Sl=a(vx,"A",{href:!0,rel:!0});var kx=i(Sl);uD=s(kx,"Vectorization"),kx.forEach(t),vx.forEach(t),mD=h(vr),Gh=a(vr,"LI",{});var wx=i(Gh);Nl=a(wx,"A",{href:!0,rel:!0});var Tx=i(Nl);gD=s(Tx,"Parallelization"),Tx.forEach(t),wx.forEach(t),vr.forEach(t),_D=h(Mt),Ht=a(Mt,"DIV",{class:!0});var kr=i(Ht);T(Rl.$$.fragment,kr),bD=h(kr),$s=a(kr,"P",{});var fp=i($s);vD=s(fp,"The "),Xh=a(fp,"CODE",{});var $x=i(Xh);kD=s($x,"FlaxDistilBertPreTrainedModel"),$x.forEach(t),wD=s(fp," forward method, overrides the "),Yh=a(fp,"CODE",{});var yx=i(Yh);TD=s(yx,"__call__"),yx.forEach(t),$D=s(fp," special method."),fp.forEach(t),yD=h(kr),T(Kn.$$.fragment,kr),DD=h(kr),T(Vn.$$.fragment,kr),kr.forEach(t),Mt.forEach(t),um=h(n),ys=a(n,"H2",{class:!0});var zg=i(ys);Jn=a(zg,"A",{id:!0,class:!0,href:!0});var Dx=i(Jn);Zh=a(Dx,"SPAN",{});var Fx=i(Zh);T(Wl.$$.fragment,Fx),Fx.forEach(t),Dx.forEach(t),FD=h(zg),ef=a(zg,"SPAN",{});var Ex=i(ef);ED=s(Ex,"FlaxDistilBertForMultipleChoice"),Ex.forEach(t),zg.forEach(t),mm=h(n),nt=a(n,"DIV",{class:!0});var zt=i(nt);T(Ql.$$.fragment,zt),BD=h(zt),tf=a(zt,"P",{});var Bx=i(tf);xD=s(Bx,`DistilBert Model with a multiple choice classification head on top (a linear layer on top of the pooled output and
a softmax) e.g. for RocStories/SWAG tasks.`),Bx.forEach(t),MD=h(zt),Ul=a(zt,"P",{});var jg=i(Ul);zD=s(jg,"This model inherits from "),Uc=a(jg,"A",{href:!0});var xx=i(Uc);jD=s(xx,"FlaxPreTrainedModel"),xx.forEach(t),CD=s(jg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),jg.forEach(t),PD=h(zt),Hl=a(zt,"P",{});var Cg=i(Hl);qD=s(Cg,"This model is also a Flax Linen "),Kl=a(Cg,"A",{href:!0,rel:!0});var Mx=i(Kl);AD=s(Mx,"flax.linen.Module"),Mx.forEach(t),OD=s(Cg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Cg.forEach(t),LD=h(zt),of=a(zt,"P",{});var zx=i(of);ID=s(zx,"Finally, this model supports inherent JAX features such as:"),zx.forEach(t),SD=h(zt),ao=a(zt,"UL",{});var wr=i(ao);sf=a(wr,"LI",{});var jx=i(sf);Vl=a(jx,"A",{href:!0,rel:!0});var Cx=i(Vl);ND=s(Cx,"Just-In-Time (JIT) compilation"),Cx.forEach(t),jx.forEach(t),RD=h(wr),nf=a(wr,"LI",{});var Px=i(nf);Jl=a(Px,"A",{href:!0,rel:!0});var qx=i(Jl);WD=s(qx,"Automatic Differentiation"),qx.forEach(t),Px.forEach(t),QD=h(wr),rf=a(wr,"LI",{});var Ax=i(rf);Gl=a(Ax,"A",{href:!0,rel:!0});var Ox=i(Gl);UD=s(Ox,"Vectorization"),Ox.forEach(t),Ax.forEach(t),HD=h(wr),af=a(wr,"LI",{});var Lx=i(af);Xl=a(Lx,"A",{href:!0,rel:!0});var Ix=i(Xl);KD=s(Ix,"Parallelization"),Ix.forEach(t),Lx.forEach(t),wr.forEach(t),VD=h(zt),Kt=a(zt,"DIV",{class:!0});var Tr=i(Kt);T(Yl.$$.fragment,Tr),JD=h(Tr),Ds=a(Tr,"P",{});var up=i(Ds);GD=s(up,"The "),lf=a(up,"CODE",{});var Sx=i(lf);XD=s(Sx,"FlaxDistilBertPreTrainedModel"),Sx.forEach(t),YD=s(up," forward method, overrides the "),df=a(up,"CODE",{});var Nx=i(df);ZD=s(Nx,"__call__"),Nx.forEach(t),eF=s(up," special method."),up.forEach(t),tF=h(Tr),T(Gn.$$.fragment,Tr),oF=h(Tr),T(Xn.$$.fragment,Tr),Tr.forEach(t),zt.forEach(t),gm=h(n),Fs=a(n,"H2",{class:!0});var Pg=i(Fs);Yn=a(Pg,"A",{id:!0,class:!0,href:!0});var Rx=i(Yn);cf=a(Rx,"SPAN",{});var Wx=i(cf);T(Zl.$$.fragment,Wx),Wx.forEach(t),Rx.forEach(t),sF=h(Pg),pf=a(Pg,"SPAN",{});var Qx=i(pf);nF=s(Qx,"FlaxDistilBertForTokenClassification"),Qx.forEach(t),Pg.forEach(t),_m=h(n),rt=a(n,"DIV",{class:!0});var jt=i(rt);T(ed.$$.fragment,jt),rF=h(jt),hf=a(jt,"P",{});var Ux=i(hf);aF=s(Ux,`DistilBert 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.`),Ux.forEach(t),iF=h(jt),td=a(jt,"P",{});var qg=i(td);lF=s(qg,"This model inherits from "),Hc=a(qg,"A",{href:!0});var Hx=i(Hc);dF=s(Hx,"FlaxPreTrainedModel"),Hx.forEach(t),cF=s(qg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),qg.forEach(t),pF=h(jt),od=a(jt,"P",{});var Ag=i(od);hF=s(Ag,"This model is also a Flax Linen "),sd=a(Ag,"A",{href:!0,rel:!0});var Kx=i(sd);fF=s(Kx,"flax.linen.Module"),Kx.forEach(t),uF=s(Ag,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Ag.forEach(t),mF=h(jt),ff=a(jt,"P",{});var Vx=i(ff);gF=s(Vx,"Finally, this model supports inherent JAX features such as:"),Vx.forEach(t),_F=h(jt),io=a(jt,"UL",{});var $r=i(io);uf=a($r,"LI",{});var Jx=i(uf);nd=a(Jx,"A",{href:!0,rel:!0});var Gx=i(nd);bF=s(Gx,"Just-In-Time (JIT) compilation"),Gx.forEach(t),Jx.forEach(t),vF=h($r),mf=a($r,"LI",{});var Xx=i(mf);rd=a(Xx,"A",{href:!0,rel:!0});var Yx=i(rd);kF=s(Yx,"Automatic Differentiation"),Yx.forEach(t),Xx.forEach(t),wF=h($r),gf=a($r,"LI",{});var Zx=i(gf);ad=a(Zx,"A",{href:!0,rel:!0});var e5=i(ad);TF=s(e5,"Vectorization"),e5.forEach(t),Zx.forEach(t),$F=h($r),_f=a($r,"LI",{});var t5=i(_f);id=a(t5,"A",{href:!0,rel:!0});var o5=i(id);yF=s(o5,"Parallelization"),o5.forEach(t),t5.forEach(t),$r.forEach(t),DF=h(jt),Vt=a(jt,"DIV",{class:!0});var yr=i(Vt);T(ld.$$.fragment,yr),FF=h(yr),Es=a(yr,"P",{});var mp=i(Es);EF=s(mp,"The "),bf=a(mp,"CODE",{});var s5=i(bf);BF=s(s5,"FlaxDistilBertPreTrainedModel"),s5.forEach(t),xF=s(mp," forward method, overrides the "),vf=a(mp,"CODE",{});var n5=i(vf);MF=s(n5,"__call__"),n5.forEach(t),zF=s(mp," special method."),mp.forEach(t),jF=h(yr),T(Zn.$$.fragment,yr),CF=h(yr),T(er.$$.fragment,yr),yr.forEach(t),jt.forEach(t),bm=h(n),Bs=a(n,"H2",{class:!0});var Og=i(Bs);tr=a(Og,"A",{id:!0,class:!0,href:!0});var r5=i(tr);kf=a(r5,"SPAN",{});var a5=i(kf);T(dd.$$.fragment,a5),a5.forEach(t),r5.forEach(t),PF=h(Og),wf=a(Og,"SPAN",{});var i5=i(wf);qF=s(i5,"FlaxDistilBertForQuestionAnswering"),i5.forEach(t),Og.forEach(t),vm=h(n),at=a(n,"DIV",{class:!0});var Ct=i(at);T(cd.$$.fragment,Ct),AF=h(Ct),xs=a(Ct,"P",{});var gp=i(xs);OF=s(gp,`DistilBert 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 `),Tf=a(gp,"CODE",{});var l5=i(Tf);LF=s(l5,"span start logits"),l5.forEach(t),IF=s(gp," and "),$f=a(gp,"CODE",{});var d5=i($f);SF=s(d5,"span end logits"),d5.forEach(t),NF=s(gp,")."),gp.forEach(t),RF=h(Ct),pd=a(Ct,"P",{});var Lg=i(pd);WF=s(Lg,"This model inherits from "),Kc=a(Lg,"A",{href:!0});var c5=i(Kc);QF=s(c5,"FlaxPreTrainedModel"),c5.forEach(t),UF=s(Lg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),Lg.forEach(t),HF=h(Ct),hd=a(Ct,"P",{});var Ig=i(hd);KF=s(Ig,"This model is also a Flax Linen "),fd=a(Ig,"A",{href:!0,rel:!0});var p5=i(fd);VF=s(p5,"flax.linen.Module"),p5.forEach(t),JF=s(Ig,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Ig.forEach(t),GF=h(Ct),yf=a(Ct,"P",{});var h5=i(yf);XF=s(h5,"Finally, this model supports inherent JAX features such as:"),h5.forEach(t),YF=h(Ct),lo=a(Ct,"UL",{});var Dr=i(lo);Df=a(Dr,"LI",{});var f5=i(Df);ud=a(f5,"A",{href:!0,rel:!0});var u5=i(ud);ZF=s(u5,"Just-In-Time (JIT) compilation"),u5.forEach(t),f5.forEach(t),e4=h(Dr),Ff=a(Dr,"LI",{});var m5=i(Ff);md=a(m5,"A",{href:!0,rel:!0});var g5=i(md);t4=s(g5,"Automatic Differentiation"),g5.forEach(t),m5.forEach(t),o4=h(Dr),Ef=a(Dr,"LI",{});var _5=i(Ef);gd=a(_5,"A",{href:!0,rel:!0});var b5=i(gd);s4=s(b5,"Vectorization"),b5.forEach(t),_5.forEach(t),n4=h(Dr),Bf=a(Dr,"LI",{});var v5=i(Bf);_d=a(v5,"A",{href:!0,rel:!0});var k5=i(_d);r4=s(k5,"Parallelization"),k5.forEach(t),v5.forEach(t),Dr.forEach(t),a4=h(Ct),Jt=a(Ct,"DIV",{class:!0});var Fr=i(Jt);T(bd.$$.fragment,Fr),i4=h(Fr),Ms=a(Fr,"P",{});var _p=i(Ms);l4=s(_p,"The "),xf=a(_p,"CODE",{});var w5=i(xf);d4=s(w5,"FlaxDistilBertPreTrainedModel"),w5.forEach(t),c4=s(_p," forward method, overrides the "),Mf=a(_p,"CODE",{});var T5=i(Mf);p4=s(T5,"__call__"),T5.forEach(t),h4=s(_p," special method."),_p.forEach(t),f4=h(Fr),T(or.$$.fragment,Fr),u4=h(Fr),T(sr.$$.fragment,Fr),Fr.forEach(t),Ct.forEach(t),this.h()},h(){c(d,"name","hf:doc:metadata"),c(d,"content",JSON.stringify(BM)),c(m,"id","distilbert"),c(m,"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"),c(m,"href","#distilbert"),c(f,"class","relative group"),c(re,"id","overview"),c(re,"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"),c(re,"href","#overview"),c(I,"class","relative group"),c(ae,"href","https://medium.com/huggingface/distilbert-8cf3380435b5"),c(ae,"rel","nofollow"),c(ie,"href","https://arxiv.org/abs/1910.01108"),c(ie,"rel","nofollow"),c(Z,"href","https://huggingface.co/victorsanh"),c(Z,"rel","nofollow"),c(z,"href","https://huggingface.co/kamalkraj"),c(z,"rel","nofollow"),c(Le,"href","https://github.com/huggingface/transformers/tree/main/examples/research_projects/distillation"),c(Le,"rel","nofollow"),c(Oe,"id","resources"),c(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"),c(Oe,"href","#resources"),c(N,"class","relative group"),c(xr,"href","https://huggingface.co/blog/sentiment-analysis-python"),c(xr,"rel","nofollow"),c(zr,"href","https://huggingface.co/blog/fastai"),c(zr,"rel","nofollow"),c(Cr,"href","https://huggingface.co/blog/ray-tune"),c(Cr,"rel","nofollow"),c(qr,"href","https://huggingface.co/blog/the-partnership-amazon-sagemaker-and-hugging-face"),c(qr,"rel","nofollow"),c(Or,"href","https://colab.research.google.com/github/DhavalTaunk08/Transformers_scripts/blob/master/Transformers_multilabel_distilbert.ipynb"),c(Or,"rel","nofollow"),c(Ir,"href","https://colab.research.google.com/github/abhimishra91/transformers-tutorials/blob/master/transformers_multiclass_classification.ipynb"),c(Ir,"rel","nofollow"),c(Nr,"href","https://colab.research.google.com/github/peterbayerle/huggingface_notebook/blob/main/distilbert_tf.ipynb"),c(Nr,"rel","nofollow"),c(Nd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForSequenceClassification"),c(Rr,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/text-classification"),c(Rr,"rel","nofollow"),c(Wr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification.ipynb"),c(Wr,"rel","nofollow"),c(Rd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForSequenceClassification"),c(Qr,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/text-classification"),c(Qr,"rel","nofollow"),c(Ur,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification-tf.ipynb"),c(Ur,"rel","nofollow"),c(Wd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.FlaxDistilBertForSequenceClassification"),c(Hr,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/text-classification"),c(Hr,"rel","nofollow"),c(Kr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification_flax.ipynb"),c(Kr,"rel","nofollow"),c(Qd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForTokenClassification"),c(Jr,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/token-classification"),c(Jr,"rel","nofollow"),c(Gr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification.ipynb"),c(Gr,"rel","nofollow"),c(Ud,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForTokenClassification"),c(Xr,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/token-classification"),c(Xr,"rel","nofollow"),c(Yr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification-tf.ipynb"),c(Yr,"rel","nofollow"),c(Hd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.FlaxDistilBertForTokenClassification"),c(Zr,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/token-classification"),c(Zr,"rel","nofollow"),c(ea,"href","https://huggingface.co/course/chapter7/2?fw=pt"),c(ea,"rel","nofollow"),c(Vd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForMaskedLM"),c(oa,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/language-modeling#robertabertdistilbert-and-masked-language-modeling"),c(oa,"rel","nofollow"),c(sa,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling.ipynb"),c(sa,"rel","nofollow"),c(Jd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForMaskedLM"),c(na,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/language-modeling#run_mlmpy"),c(na,"rel","nofollow"),c(ra,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling-tf.ipynb"),c(ra,"rel","nofollow"),c(Gd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.FlaxDistilBertForMaskedLM"),c(aa,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/language-modeling#masked-language-modeling"),c(aa,"rel","nofollow"),c(ia,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/masked_language_modeling_flax.ipynb"),c(ia,"rel","nofollow"),c(la,"href","https://huggingface.co/course/chapter7/3?fw=pt"),c(la,"rel","nofollow"),c(Yd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForQuestionAnswering"),c(ca,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/question-answering"),c(ca,"rel","nofollow"),c(pa,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering.ipynb"),c(pa,"rel","nofollow"),c(Zd,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForQuestionAnswering"),c(ha,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/question-answering"),c(ha,"rel","nofollow"),c(fa,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering-tf.ipynb"),c(fa,"rel","nofollow"),c(ec,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.FlaxDistilBertForQuestionAnswering"),c(ua,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/question-answering"),c(ua,"rel","nofollow"),c(ma,"href","https://huggingface.co/course/chapter7/7?fw=pt"),c(ma,"rel","nofollow"),c(sc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForMultipleChoice"),c(ga,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/multiple-choice"),c(ga,"rel","nofollow"),c(_a,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/multiple_choice.ipynb"),c(_a,"rel","nofollow"),c(nc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForMultipleChoice"),c(ba,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/multiple-choice"),c(ba,"rel","nofollow"),c(va,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/multiple_choice-tf.ipynb"),c(va,"rel","nofollow"),c(wa,"href","https://huggingface.co/blog/intel"),c(wa,"rel","nofollow"),c($a,"href","https://www.philschmid.de/optimizing-transformers-with-optimum-gpu"),c($a,"rel","nofollow"),c(Da,"href","https://www.philschmid.de/optimizing-transformers-with-optimum"),c(Da,"rel","nofollow"),c(Ea,"href","https://huggingface.co/blog/bert-inferentia-sagemaker"),c(Ea,"rel","nofollow"),c(xa,"href","https://www.philschmid.de/sagemaker-serverless-huggingface-distilbert"),c(xa,"rel","nofollow"),c(za,"href","https://huggingface.co/blog/how-to-deploy-a-pipeline-to-google-clouds"),c(za,"rel","nofollow"),c(Ca,"href","https://huggingface.co/blog/deploy-hugging-face-models-easily-with-amazon-sagemaker"),c(Ca,"rel","nofollow"),c(qa,"href","https://www.philschmid.de/terraform-huggingface-amazon-sagemaker"),c(qa,"rel","nofollow"),c(qs,"id","transformers.DistilBertConfig"),c(qs,"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"),c(qs,"href","#transformers.DistilBertConfig"),c(Ro,"class","relative group"),c(lc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertModel"),c(dc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertModel"),c(La,"href","https://huggingface.co/distilbert-base-uncased"),c(La,"rel","nofollow"),c(cc,"href","/docs/transformers/v4.25.1/en/main_classes/configuration#transformers.PretrainedConfig"),c(pc,"href","/docs/transformers/v4.25.1/en/main_classes/configuration#transformers.PretrainedConfig"),c(Pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Os,"id","transformers.DistilBertTokenizer"),c(Os,"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"),c(Os,"href","#transformers.DistilBertTokenizer"),c(Qo,"class","relative group"),c(hc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizer"),c(fc,"href","/docs/transformers/v4.25.1/en/model_doc/bert#transformers.BertTokenizer"),c(uc,"href","/docs/transformers/v4.25.1/en/model_doc/bert#transformers.BertTokenizer"),c(qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Is,"id","transformers.DistilBertTokenizerFast"),c(Is,"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"),c(Is,"href","#transformers.DistilBertTokenizerFast"),c(Uo,"class","relative group"),c(mc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertTokenizerFast"),c(gc,"href","/docs/transformers/v4.25.1/en/model_doc/bert#transformers.BertTokenizerFast"),c(_c,"href","/docs/transformers/v4.25.1/en/model_doc/bert#transformers.BertTokenizerFast"),c(At,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Ns,"id","transformers.DistilBertModel"),c(Ns,"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"),c(Ns,"href","#transformers.DistilBertModel"),c(Ho,"class","relative group"),c(bc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.PreTrainedModel"),c(Ga,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Ga,"rel","nofollow"),c(vc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertModel"),c(St,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Qs,"id","transformers.DistilBertForMaskedLM"),c(Qs,"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"),c(Qs,"href","#transformers.DistilBertForMaskedLM"),c(Vo,"class","relative group"),c(kc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.PreTrainedModel"),c(si,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(si,"rel","nofollow"),c(wc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForMaskedLM"),c(kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(mt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Vs,"id","transformers.DistilBertForSequenceClassification"),c(Vs,"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"),c(Vs,"href","#transformers.DistilBertForSequenceClassification"),c(Go,"class","relative group"),c(Tc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.PreTrainedModel"),c(di,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(di,"rel","nofollow"),c($c,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForSequenceClassification"),c(it,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(gt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(en,"id","transformers.DistilBertForMultipleChoice"),c(en,"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"),c(en,"href","#transformers.DistilBertForMultipleChoice"),c(Yo,"class","relative group"),c(yc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.PreTrainedModel"),c(mi,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(mi,"rel","nofollow"),c(Dc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForMultipleChoice"),c(Nt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(_t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(sn,"id","transformers.DistilBertForTokenClassification"),c(sn,"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"),c(sn,"href","#transformers.DistilBertForTokenClassification"),c(es,"class","relative group"),c(Fc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.PreTrainedModel"),c(wi,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(wi,"rel","nofollow"),c(Ec,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForTokenClassification"),c(wt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ln,"id","transformers.DistilBertForQuestionAnswering"),c(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"),c(ln,"href","#transformers.DistilBertForQuestionAnswering"),c(os,"class","relative group"),c(Bc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.PreTrainedModel"),c(Ei,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Ei,"rel","nofollow"),c(xc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.DistilBertForQuestionAnswering"),c(Tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(vt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(hn,"id","transformers.TFDistilBertModel"),c(hn,"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"),c(hn,"href","#transformers.TFDistilBertModel"),c(rs,"class","relative group"),c(Mc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.TFPreTrainedModel"),c(Ci,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Ci,"rel","nofollow"),c(zc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertModel"),c(Rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(lt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(gn,"id","transformers.TFDistilBertForMaskedLM"),c(gn,"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"),c(gn,"href","#transformers.TFDistilBertForMaskedLM"),c(is,"class","relative group"),c(jc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.TFPreTrainedModel"),c(Si,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Si,"rel","nofollow"),c(Cc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForMaskedLM"),c($t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(wn,"id","transformers.TFDistilBertForSequenceClassification"),c(wn,"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"),c(wn,"href","#transformers.TFDistilBertForSequenceClassification"),c(ds,"class","relative group"),c(Pc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.TFPreTrainedModel"),c(Hi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Hi,"rel","nofollow"),c(qc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForSequenceClassification"),c(yt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ct,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Fn,"id","transformers.TFDistilBertForMultipleChoice"),c(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"),c(Fn,"href","#transformers.TFDistilBertForMultipleChoice"),c(ps,"class","relative group"),c(Ac,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.TFPreTrainedModel"),c(Yi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Yi,"rel","nofollow"),c(Oc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForMultipleChoice"),c(Wt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Mn,"id","transformers.TFDistilBertForTokenClassification"),c(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"),c(Mn,"href","#transformers.TFDistilBertForTokenClassification"),c(fs,"class","relative group"),c(Lc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.TFPreTrainedModel"),c(nl,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(nl,"rel","nofollow"),c(Ic,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForTokenClassification"),c(Dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(qn,"id","transformers.TFDistilBertForQuestionAnswering"),c(qn,"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"),c(qn,"href","#transformers.TFDistilBertForQuestionAnswering"),c(ms,"class","relative group"),c(Sc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.TFPreTrainedModel"),c(cl,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(cl,"rel","nofollow"),c(Nc,"href","/docs/transformers/v4.25.1/en/model_doc/distilbert#transformers.TFDistilBertForQuestionAnswering"),c(Ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Sn,"id","transformers.FlaxDistilBertModel"),c(Sn,"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"),c(Sn,"href","#transformers.FlaxDistilBertModel"),c(bs,"class","relative group"),c(Rc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(gl,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(gl,"rel","nofollow"),c(_l,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(_l,"rel","nofollow"),c(bl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(bl,"rel","nofollow"),c(vl,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(vl,"rel","nofollow"),c(kl,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(kl,"rel","nofollow"),c(Qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Wn,"id","transformers.FlaxDistilBertForMaskedLM"),c(Wn,"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"),c(Wn,"href","#transformers.FlaxDistilBertForMaskedLM"),c(ks,"class","relative group"),c(Wc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(El,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(El,"rel","nofollow"),c(Bl,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Bl,"rel","nofollow"),c(xl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(xl,"rel","nofollow"),c(Ml,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Ml,"rel","nofollow"),c(zl,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(zl,"rel","nofollow"),c(Ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Hn,"id","transformers.FlaxDistilBertForSequenceClassification"),c(Hn,"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"),c(Hn,"href","#transformers.FlaxDistilBertForSequenceClassification"),c(Ts,"class","relative group"),c(Qc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Ol,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Ol,"rel","nofollow"),c(Ll,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Ll,"rel","nofollow"),c(Il,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Il,"rel","nofollow"),c(Sl,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Sl,"rel","nofollow"),c(Nl,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Nl,"rel","nofollow"),c(Ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(st,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Jn,"id","transformers.FlaxDistilBertForMultipleChoice"),c(Jn,"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"),c(Jn,"href","#transformers.FlaxDistilBertForMultipleChoice"),c(ys,"class","relative group"),c(Uc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Kl,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Kl,"rel","nofollow"),c(Vl,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Vl,"rel","nofollow"),c(Jl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Jl,"rel","nofollow"),c(Gl,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Gl,"rel","nofollow"),c(Xl,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Xl,"rel","nofollow"),c(Kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(nt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Yn,"id","transformers.FlaxDistilBertForTokenClassification"),c(Yn,"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"),c(Yn,"href","#transformers.FlaxDistilBertForTokenClassification"),c(Fs,"class","relative group"),c(Hc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(sd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(sd,"rel","nofollow"),c(nd,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(nd,"rel","nofollow"),c(rd,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(rd,"rel","nofollow"),c(ad,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(ad,"rel","nofollow"),c(id,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(id,"rel","nofollow"),c(Vt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(tr,"id","transformers.FlaxDistilBertForQuestionAnswering"),c(tr,"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"),c(tr,"href","#transformers.FlaxDistilBertForQuestionAnswering"),c(Bs,"class","relative group"),c(Kc,"href","/docs/transformers/v4.25.1/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(fd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(fd,"rel","nofollow"),c(ud,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(ud,"rel","nofollow"),c(md,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(md,"rel","nofollow"),c(gd,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(gd,"rel","nofollow"),c(_d,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(_d,"rel","nofollow"),c(Jt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(at,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(n,g){e(document.head,d),_(n,b,g),_(n,f,g),e(f,m),e(m,v),$(l,v,null),e(f,u),e(f,M),e(M,we),_(n,ge,g),_(n,I,g),e(I,re),e(re,oe),$(E,oe,null),e(I,Te),e(I,Q),e(Q,$e),_(n,_e,g),_(n,O,g),e(O,ye),e(O,ae),e(ae,H),e(O,De),e(O,ie),e(ie,K),e(O,Fe),e(O,de),e(de,V),e(O,Ee),_(n,be,g),_(n,ee,g),e(ee,j),_(n,q,g),_(n,le,g),e(le,U),e(U,Be),_(n,ve,g),_(n,W,g),e(W,xe),_(n,ke,g),_(n,C,g),e(C,se),e(se,J),e(se,ce),e(ce,Me),e(se,G),e(se,pe),e(pe,ze),e(se,S),e(se,he),e(he,X),e(se,je),e(C,ne),e(C,P),e(P,Ce),e(P,A),e(A,Pe),e(P,qe),_(n,k,g),_(n,x,g),e(x,He),e(x,Z),e(Z,Ke),e(x,Ve),e(x,z),e(z,Je),e(x,Ge),e(x,Le),e(Le,Xe),e(x,Ye),_(n,L,g),_(n,N,g),e(N,Oe),e(Oe,Re),$(R,Re,null),e(N,Ze),e(N,We),e(We,Ae),_(n,Ue,g),_(n,te,g),e(te,et),_(n,gu,g),$(Er,n,g),_(n,_u,g),_(n,Ie,g),e(Ie,Br),e(Br,Ng),e(Br,xr),e(xr,Rg),e(Br,Wg),e(Ie,Qg),e(Ie,Mr),e(Mr,Ug),e(Mr,zr),e(zr,Hg),e(Mr,Kg),e(Ie,Vg),e(Ie,jr),e(jr,Jg),e(jr,Cr),e(Cr,Gg),e(jr,Xg),e(Ie,Yg),e(Ie,Pr),e(Pr,Zg),e(Pr,qr),e(qr,e_),e(Pr,t_),e(Ie,o_),e(Ie,Ar),e(Ar,s_),e(Ar,Or),e(Or,n_),e(Ar,r_),e(Ie,a_),e(Ie,Lr),e(Lr,i_),e(Lr,Ir),e(Ir,l_),e(Lr,d_),e(Ie,c_),e(Ie,Sr),e(Sr,p_),e(Sr,Nr),e(Nr,h_),e(Sr,f_),e(Ie,u_),e(Ie,fo),e(fo,Nd),e(Nd,m_),e(fo,g_),e(fo,Rr),e(Rr,__),e(fo,b_),e(fo,Wr),e(Wr,v_),e(fo,k_),e(Ie,w_),e(Ie,uo),e(uo,Rd),e(Rd,T_),e(uo,$_),e(uo,Qr),e(Qr,y_),e(uo,D_),e(uo,Ur),e(Ur,F_),e(uo,E_),e(Ie,B_),e(Ie,mo),e(mo,Wd),e(Wd,x_),e(mo,M_),e(mo,Hr),e(Hr,z_),e(mo,j_),e(mo,Kr),e(Kr,C_),e(mo,P_),_(n,bu,g),$(Vr,n,g),_(n,vu,g),_(n,Ot,g),e(Ot,go),e(go,Qd),e(Qd,q_),e(go,A_),e(go,Jr),e(Jr,O_),e(go,L_),e(go,Gr),e(Gr,I_),e(go,S_),e(Ot,N_),e(Ot,_o),e(_o,Ud),e(Ud,R_),e(_o,W_),e(_o,Xr),e(Xr,Q_),e(_o,U_),e(_o,Yr),e(Yr,H_),e(_o,K_),e(Ot,V_),e(Ot,zs),e(zs,Hd),e(Hd,J_),e(zs,G_),e(zs,Zr),e(Zr,X_),e(zs,Y_),e(Ot,Z_),e(Ot,Kd),e(Kd,ea),e(ea,eb),e(Kd,tb),_(n,ku,g),$(ta,n,g),_(n,wu,g),_(n,Lt,g),e(Lt,bo),e(bo,Vd),e(Vd,ob),e(bo,sb),e(bo,oa),e(oa,nb),e(bo,rb),e(bo,sa),e(sa,ab),e(bo,ib),e(Lt,lb),e(Lt,vo),e(vo,Jd),e(Jd,db),e(vo,cb),e(vo,na),e(na,pb),e(vo,hb),e(vo,ra),e(ra,fb),e(vo,ub),e(Lt,mb),e(Lt,ko),e(ko,Gd),e(Gd,gb),e(ko,_b),e(ko,aa),e(aa,bb),e(ko,vb),e(ko,ia),e(ia,kb),e(ko,wb),e(Lt,Tb),e(Lt,Xd),e(Xd,la),e(la,$b),e(Xd,yb),_(n,Tu,g),$(da,n,g),_(n,$u,g),_(n,It,g),e(It,wo),e(wo,Yd),e(Yd,Db),e(wo,Fb),e(wo,ca),e(ca,Eb),e(wo,Bb),e(wo,pa),e(pa,xb),e(wo,Mb),e(It,zb),e(It,To),e(To,Zd),e(Zd,jb),e(To,Cb),e(To,ha),e(ha,Pb),e(To,qb),e(To,fa),e(fa,Ab),e(To,Ob),e(It,Lb),e(It,js),e(js,ec),e(ec,Ib),e(js,Sb),e(js,ua),e(ua,Nb),e(js,Rb),e(It,Wb),e(It,tc),e(tc,ma),e(ma,Qb),e(tc,Ub),_(n,yu,g),_(n,oc,g),e(oc,bp),e(bp,Hb),_(n,Du,g),_(n,Cs,g),e(Cs,$o),e($o,sc),e(sc,Kb),e($o,Vb),e($o,ga),e(ga,Jb),e($o,Gb),e($o,_a),e(_a,Xb),e($o,Yb),e(Cs,Zb),e(Cs,yo),e(yo,nc),e(nc,ev),e(yo,tv),e(yo,ba),e(ba,ov),e(yo,sv),e(yo,va),e(va,nv),e(yo,rv),_(n,Fu,g),_(n,rc,g),e(rc,av),_(n,Eu,g),_(n,Do,g),e(Do,ka),e(ka,iv),e(ka,wa),e(wa,lv),e(ka,dv),e(Do,cv),e(Do,Ta),e(Ta,pv),e(Ta,$a),e($a,hv),e(Ta,fv),e(Do,uv),e(Do,ya),e(ya,mv),e(ya,Da),e(Da,gv),e(ya,_v),_(n,Bu,g),_(n,ac,g),e(ac,bv),_(n,xu,g),_(n,Ps,g),e(Ps,Fa),e(Fa,vv),e(Fa,Ea),e(Ea,kv),e(Fa,wv),e(Ps,Tv),e(Ps,Ba),e(Ba,$v),e(Ba,xa),e(xa,yv),e(Ba,Dv),_(n,Mu,g),_(n,ic,g),e(ic,Fv),_(n,zu,g),_(n,Fo,g),e(Fo,Ma),e(Ma,Ev),e(Ma,za),e(za,Bv),e(Ma,xv),e(Fo,Mv),e(Fo,ja),e(ja,zv),e(ja,Ca),e(Ca,jv),e(ja,Cv),e(Fo,Pv),e(Fo,Pa),e(Pa,qv),e(Pa,qa),e(qa,Av),e(Pa,Ov),_(n,ju,g),_(n,Ro,g),e(Ro,qs),e(qs,vp),$(Aa,vp,null),e(Ro,Lv),e(Ro,kp),e(kp,Iv),_(n,Cu,g),_(n,Pt,g),$(Oa,Pt,null),e(Pt,Sv),e(Pt,oo),e(oo,Nv),e(oo,lc),e(lc,Rv),e(oo,Wv),e(oo,dc),e(dc,Qv),e(oo,Uv),e(oo,La),e(La,Hv),e(oo,Kv),e(Pt,Vv),e(Pt,Wo),e(Wo,Jv),e(Wo,cc),e(cc,Gv),e(Wo,Xv),e(Wo,pc),e(pc,Yv),e(Wo,Zv),e(Pt,ek),$(As,Pt,null),_(n,Pu,g),_(n,Qo,g),e(Qo,Os),e(Os,wp),$(Ia,wp,null),e(Qo,tk),e(Qo,Tp),e(Tp,ok),_(n,qu,g),_(n,qt,g),$(Sa,qt,null),e(qt,sk),e(qt,$p),e($p,nk),e(qt,rk),e(qt,Ls),e(Ls,hc),e(hc,ak),e(Ls,ik),e(Ls,fc),e(fc,lk),e(Ls,dk),e(qt,ck),e(qt,Na),e(Na,pk),e(Na,uc),e(uc,hk),e(Na,fk),_(n,Au,g),_(n,Uo,g),e(Uo,Is),e(Is,yp),$(Ra,yp,null),e(Uo,uk),e(Uo,Dp),e(Dp,mk),_(n,Ou,g),_(n,At,g),$(Wa,At,null),e(At,gk),e(At,Qa),e(Qa,_k),e(Qa,Fp),e(Fp,bk),e(Qa,vk),e(At,kk),e(At,Ss),e(Ss,mc),e(mc,wk),e(Ss,Tk),e(Ss,gc),e(gc,$k),e(Ss,yk),e(At,Dk),e(At,Ua),e(Ua,Fk),e(Ua,_c),e(_c,Ek),e(Ua,Bk),_(n,Lu,g),_(n,Ho,g),e(Ho,Ns),e(Ns,Ep),$(Ha,Ep,null),e(Ho,xk),e(Ho,Bp),e(Bp,Mk),_(n,Iu,g),_(n,ut,g),$(Ka,ut,null),e(ut,zk),e(ut,xp),e(xp,jk),e(ut,Ck),e(ut,Va),e(Va,Pk),e(Va,bc),e(bc,qk),e(Va,Ak),e(ut,Ok),e(ut,Ja),e(Ja,Lk),e(Ja,Ga),e(Ga,Ik),e(Ja,Sk),e(ut,Nk),e(ut,St),$(Xa,St,null),e(St,Rk),e(St,Ko),e(Ko,Wk),e(Ko,vc),e(vc,Qk),e(Ko,Uk),e(Ko,Mp),e(Mp,Hk),e(Ko,Kk),e(St,Vk),$(Rs,St,null),e(St,Jk),$(Ws,St,null),_(n,Su,g),_(n,Vo,g),e(Vo,Qs),e(Qs,zp),$(Ya,zp,null),e(Vo,Gk),e(Vo,jp),e(jp,Xk),_(n,Nu,g),_(n,mt,g),$(Za,mt,null),e(mt,Yk),e(mt,ei),e(ei,Zk),e(ei,Cp),e(Cp,ew),e(ei,tw),e(mt,ow),e(mt,ti),e(ti,sw),e(ti,kc),e(kc,nw),e(ti,rw),e(mt,aw),e(mt,oi),e(oi,iw),e(oi,si),e(si,lw),e(oi,dw),e(mt,cw),e(mt,kt),$(ni,kt,null),e(kt,pw),e(kt,Jo),e(Jo,hw),e(Jo,wc),e(wc,fw),e(Jo,uw),e(Jo,Pp),e(Pp,mw),e(Jo,gw),e(kt,_w),$(Us,kt,null),e(kt,bw),$(Hs,kt,null),e(kt,vw),$(Ks,kt,null),_(n,Ru,g),_(n,Go,g),e(Go,Vs),e(Vs,qp),$(ri,qp,null),e(Go,kw),e(Go,Ap),e(Ap,ww),_(n,Wu,g),_(n,gt,g),$(ai,gt,null),e(gt,Tw),e(gt,Op),e(Op,$w),e(gt,yw),e(gt,ii),e(ii,Dw),e(ii,Tc),e(Tc,Fw),e(ii,Ew),e(gt,Bw),e(gt,li),e(li,xw),e(li,di),e(di,Mw),e(li,zw),e(gt,jw),e(gt,it),$(ci,it,null),e(it,Cw),e(it,Xo),e(Xo,Pw),e(Xo,$c),e($c,qw),e(Xo,Aw),e(Xo,Lp),e(Lp,Ow),e(Xo,Lw),e(it,Iw),$(Js,it,null),e(it,Sw),$(Gs,it,null),e(it,Nw),$(Xs,it,null),e(it,Rw),$(Ys,it,null),e(it,Ww),$(Zs,it,null),_(n,Qu,g),_(n,Yo,g),e(Yo,en),e(en,Ip),$(pi,Ip,null),e(Yo,Qw),e(Yo,Sp),e(Sp,Uw),_(n,Uu,g),_(n,_t,g),$(hi,_t,null),e(_t,Hw),e(_t,Np),e(Np,Kw),e(_t,Vw),e(_t,fi),e(fi,Jw),e(fi,yc),e(yc,Gw),e(fi,Xw),e(_t,Yw),e(_t,ui),e(ui,Zw),e(ui,mi),e(mi,e1),e(ui,t1),e(_t,o1),e(_t,Nt),$(gi,Nt,null),e(Nt,s1),e(Nt,Zo),e(Zo,n1),e(Zo,Dc),e(Dc,r1),e(Zo,a1),e(Zo,Rp),e(Rp,i1),e(Zo,l1),e(Nt,d1),$(tn,Nt,null),e(Nt,c1),$(on,Nt,null),_(n,Hu,g),_(n,es,g),e(es,sn),e(sn,Wp),$(_i,Wp,null),e(es,p1),e(es,Qp),e(Qp,h1),_(n,Ku,g),_(n,bt,g),$(bi,bt,null),e(bt,f1),e(bt,Up),e(Up,u1),e(bt,m1),e(bt,vi),e(vi,g1),e(vi,Fc),e(Fc,_1),e(vi,b1),e(bt,v1),e(bt,ki),e(ki,k1),e(ki,wi),e(wi,w1),e(ki,T1),e(bt,$1),e(bt,wt),$(Ti,wt,null),e(wt,y1),e(wt,ts),e(ts,D1),e(ts,Ec),e(Ec,F1),e(ts,E1),e(ts,Hp),e(Hp,B1),e(ts,x1),e(wt,M1),$(nn,wt,null),e(wt,z1),$(rn,wt,null),e(wt,j1),$(an,wt,null),_(n,Vu,g),_(n,os,g),e(os,ln),e(ln,Kp),$($i,Kp,null),e(os,C1),e(os,Vp),e(Vp,P1),_(n,Ju,g),_(n,vt,g),$(yi,vt,null),e(vt,q1),e(vt,ss),e(ss,A1),e(ss,Jp),e(Jp,O1),e(ss,L1),e(ss,Gp),e(Gp,I1),e(ss,S1),e(vt,N1),e(vt,Di),e(Di,R1),e(Di,Bc),e(Bc,W1),e(Di,Q1),e(vt,U1),e(vt,Fi),e(Fi,H1),e(Fi,Ei),e(Ei,K1),e(Fi,V1),e(vt,J1),e(vt,Tt),$(Bi,Tt,null),e(Tt,G1),e(Tt,ns),e(ns,X1),e(ns,xc),e(xc,Y1),e(ns,Z1),e(ns,Xp),e(Xp,eT),e(ns,tT),e(Tt,oT),$(dn,Tt,null),e(Tt,sT),$(cn,Tt,null),e(Tt,nT),$(pn,Tt,null),_(n,Gu,g),_(n,rs,g),e(rs,hn),e(hn,Yp),$(xi,Yp,null),e(rs,rT),e(rs,Zp),e(Zp,aT),_(n,Xu,g),_(n,lt,g),$(Mi,lt,null),e(lt,iT),e(lt,eh),e(eh,lT),e(lt,dT),e(lt,zi),e(zi,cT),e(zi,Mc),e(Mc,pT),e(zi,hT),e(lt,fT),e(lt,ji),e(ji,uT),e(ji,Ci),e(Ci,mT),e(ji,gT),e(lt,_T),$(fn,lt,null),e(lt,bT),e(lt,Rt),$(Pi,Rt,null),e(Rt,vT),e(Rt,as),e(as,kT),e(as,zc),e(zc,wT),e(as,TT),e(as,th),e(th,$T),e(as,yT),e(Rt,DT),$(un,Rt,null),e(Rt,FT),$(mn,Rt,null),_(n,Yu,g),_(n,is,g),e(is,gn),e(gn,oh),$(qi,oh,null),e(is,ET),e(is,sh),e(sh,BT),_(n,Zu,g),_(n,dt,g),$(Ai,dt,null),e(dt,xT),e(dt,Oi),e(Oi,MT),e(Oi,nh),e(nh,zT),e(Oi,jT),e(dt,CT),e(dt,Li),e(Li,PT),e(Li,jc),e(jc,qT),e(Li,AT),e(dt,OT),e(dt,Ii),e(Ii,LT),e(Ii,Si),e(Si,IT),e(Ii,ST),e(dt,NT),$(_n,dt,null),e(dt,RT),e(dt,$t),$(Ni,$t,null),e($t,WT),e($t,ls),e(ls,QT),e(ls,Cc),e(Cc,UT),e(ls,HT),e(ls,rh),e(rh,KT),e(ls,VT),e($t,JT),$(bn,$t,null),e($t,GT),$(vn,$t,null),e($t,XT),$(kn,$t,null),_(n,em,g),_(n,ds,g),e(ds,wn),e(wn,ah),$(Ri,ah,null),e(ds,YT),e(ds,ih),e(ih,ZT),_(n,tm,g),_(n,ct,g),$(Wi,ct,null),e(ct,e$),e(ct,lh),e(lh,t$),e(ct,o$),e(ct,Qi),e(Qi,s$),e(Qi,Pc),e(Pc,n$),e(Qi,r$),e(ct,a$),e(ct,Ui),e(Ui,i$),e(Ui,Hi),e(Hi,l$),e(Ui,d$),e(ct,c$),$(Tn,ct,null),e(ct,p$),e(ct,yt),$(Ki,yt,null),e(yt,h$),e(yt,cs),e(cs,f$),e(cs,qc),e(qc,u$),e(cs,m$),e(cs,dh),e(dh,g$),e(cs,_$),e(yt,b$),$($n,yt,null),e(yt,v$),$(yn,yt,null),e(yt,k$),$(Dn,yt,null),_(n,om,g),_(n,ps,g),e(ps,Fn),e(Fn,ch),$(Vi,ch,null),e(ps,w$),e(ps,ph),e(ph,T$),_(n,sm,g),_(n,pt,g),$(Ji,pt,null),e(pt,$$),e(pt,hh),e(hh,y$),e(pt,D$),e(pt,Gi),e(Gi,F$),e(Gi,Ac),e(Ac,E$),e(Gi,B$),e(pt,x$),e(pt,Xi),e(Xi,M$),e(Xi,Yi),e(Yi,z$),e(Xi,j$),e(pt,C$),$(En,pt,null),e(pt,P$),e(pt,Wt),$(Zi,Wt,null),e(Wt,q$),e(Wt,hs),e(hs,A$),e(hs,Oc),e(Oc,O$),e(hs,L$),e(hs,fh),e(fh,I$),e(hs,S$),e(Wt,N$),$(Bn,Wt,null),e(Wt,R$),$(xn,Wt,null),_(n,nm,g),_(n,fs,g),e(fs,Mn),e(Mn,uh),$(el,uh,null),e(fs,W$),e(fs,mh),e(mh,Q$),_(n,rm,g),_(n,ht,g),$(tl,ht,null),e(ht,U$),e(ht,gh),e(gh,H$),e(ht,K$),e(ht,ol),e(ol,V$),e(ol,Lc),e(Lc,J$),e(ol,G$),e(ht,X$),e(ht,sl),e(sl,Y$),e(sl,nl),e(nl,Z$),e(sl,ey),e(ht,ty),$(zn,ht,null),e(ht,oy),e(ht,Dt),$(rl,Dt,null),e(Dt,sy),e(Dt,us),e(us,ny),e(us,Ic),e(Ic,ry),e(us,ay),e(us,_h),e(_h,iy),e(us,ly),e(Dt,dy),$(jn,Dt,null),e(Dt,cy),$(Cn,Dt,null),e(Dt,py),$(Pn,Dt,null),_(n,am,g),_(n,ms,g),e(ms,qn),e(qn,bh),$(al,bh,null),e(ms,hy),e(ms,vh),e(vh,fy),_(n,im,g),_(n,ft,g),$(il,ft,null),e(ft,uy),e(ft,gs),e(gs,my),e(gs,kh),e(kh,gy),e(gs,_y),e(gs,wh),e(wh,by),e(gs,vy),e(ft,ky),e(ft,ll),e(ll,wy),e(ll,Sc),e(Sc,Ty),e(ll,$y),e(ft,yy),e(ft,dl),e(dl,Dy),e(dl,cl),e(cl,Fy),e(dl,Ey),e(ft,By),$(An,ft,null),e(ft,xy),e(ft,Ft),$(pl,Ft,null),e(Ft,My),e(Ft,_s),e(_s,zy),e(_s,Nc),e(Nc,jy),e(_s,Cy),e(_s,Th),e(Th,Py),e(_s,qy),e(Ft,Ay),$(On,Ft,null),e(Ft,Oy),$(Ln,Ft,null),e(Ft,Ly),$(In,Ft,null),_(n,lm,g),_(n,bs,g),e(bs,Sn),e(Sn,$h),$(hl,$h,null),e(bs,Iy),e(bs,yh),e(yh,Sy),_(n,dm,g),_(n,tt,g),$(fl,tt,null),e(tt,Ny),e(tt,Dh),e(Dh,Ry),e(tt,Wy),e(tt,ul),e(ul,Qy),e(ul,Rc),e(Rc,Uy),e(ul,Hy),e(tt,Ky),e(tt,ml),e(ml,Vy),e(ml,gl),e(gl,Jy),e(ml,Gy),e(tt,Xy),e(tt,Fh),e(Fh,Yy),e(tt,Zy),e(tt,so),e(so,Eh),e(Eh,_l),e(_l,e2),e(so,t2),e(so,Bh),e(Bh,bl),e(bl,o2),e(so,s2),e(so,xh),e(xh,vl),e(vl,n2),e(so,r2),e(so,Mh),e(Mh,kl),e(kl,a2),e(tt,i2),e(tt,Qt),$(wl,Qt,null),e(Qt,l2),e(Qt,vs),e(vs,d2),e(vs,zh),e(zh,c2),e(vs,p2),e(vs,jh),e(jh,h2),e(vs,f2),e(Qt,u2),$(Nn,Qt,null),e(Qt,m2),$(Rn,Qt,null),_(n,cm,g),_(n,ks,g),e(ks,Wn),e(Wn,Ch),$(Tl,Ch,null),e(ks,g2),e(ks,Ph),e(Ph,_2),_(n,pm,g),_(n,ot,g),$($l,ot,null),e(ot,b2),e(ot,yl),e(yl,v2),e(yl,qh),e(qh,k2),e(yl,w2),e(ot,T2),e(ot,Dl),e(Dl,$2),e(Dl,Wc),e(Wc,y2),e(Dl,D2),e(ot,F2),e(ot,Fl),e(Fl,E2),e(Fl,El),e(El,B2),e(Fl,x2),e(ot,M2),e(ot,Ah),e(Ah,z2),e(ot,j2),e(ot,no),e(no,Oh),e(Oh,Bl),e(Bl,C2),e(no,P2),e(no,Lh),e(Lh,xl),e(xl,q2),e(no,A2),e(no,Ih),e(Ih,Ml),e(Ml,O2),e(no,L2),e(no,Sh),e(Sh,zl),e(zl,I2),e(ot,S2),e(ot,Ut),$(jl,Ut,null),e(Ut,N2),e(Ut,ws),e(ws,R2),e(ws,Nh),e(Nh,W2),e(ws,Q2),e(ws,Rh),e(Rh,U2),e(ws,H2),e(Ut,K2),$(Qn,Ut,null),e(Ut,V2),$(Un,Ut,null),_(n,hm,g),_(n,Ts,g),e(Ts,Hn),e(Hn,Wh),$(Cl,Wh,null),e(Ts,J2),e(Ts,Qh),e(Qh,G2),_(n,fm,g),_(n,st,g),$(Pl,st,null),e(st,X2),e(st,Uh),e(Uh,Y2),e(st,Z2),e(st,ql),e(ql,eD),e(ql,Qc),e(Qc,tD),e(ql,oD),e(st,sD),e(st,Al),e(Al,nD),e(Al,Ol),e(Ol,rD),e(Al,aD),e(st,iD),e(st,Hh),e(Hh,lD),e(st,dD),e(st,ro),e(ro,Kh),e(Kh,Ll),e(Ll,cD),e(ro,pD),e(ro,Vh),e(Vh,Il),e(Il,hD),e(ro,fD),e(ro,Jh),e(Jh,Sl),e(Sl,uD),e(ro,mD),e(ro,Gh),e(Gh,Nl),e(Nl,gD),e(st,_D),e(st,Ht),$(Rl,Ht,null),e(Ht,bD),e(Ht,$s),e($s,vD),e($s,Xh),e(Xh,kD),e($s,wD),e($s,Yh),e(Yh,TD),e($s,$D),e(Ht,yD),$(Kn,Ht,null),e(Ht,DD),$(Vn,Ht,null),_(n,um,g),_(n,ys,g),e(ys,Jn),e(Jn,Zh),$(Wl,Zh,null),e(ys,FD),e(ys,ef),e(ef,ED),_(n,mm,g),_(n,nt,g),$(Ql,nt,null),e(nt,BD),e(nt,tf),e(tf,xD),e(nt,MD),e(nt,Ul),e(Ul,zD),e(Ul,Uc),e(Uc,jD),e(Ul,CD),e(nt,PD),e(nt,Hl),e(Hl,qD),e(Hl,Kl),e(Kl,AD),e(Hl,OD),e(nt,LD),e(nt,of),e(of,ID),e(nt,SD),e(nt,ao),e(ao,sf),e(sf,Vl),e(Vl,ND),e(ao,RD),e(ao,nf),e(nf,Jl),e(Jl,WD),e(ao,QD),e(ao,rf),e(rf,Gl),e(Gl,UD),e(ao,HD),e(ao,af),e(af,Xl),e(Xl,KD),e(nt,VD),e(nt,Kt),$(Yl,Kt,null),e(Kt,JD),e(Kt,Ds),e(Ds,GD),e(Ds,lf),e(lf,XD),e(Ds,YD),e(Ds,df),e(df,ZD),e(Ds,eF),e(Kt,tF),$(Gn,Kt,null),e(Kt,oF),$(Xn,Kt,null),_(n,gm,g),_(n,Fs,g),e(Fs,Yn),e(Yn,cf),$(Zl,cf,null),e(Fs,sF),e(Fs,pf),e(pf,nF),_(n,_m,g),_(n,rt,g),$(ed,rt,null),e(rt,rF),e(rt,hf),e(hf,aF),e(rt,iF),e(rt,td),e(td,lF),e(td,Hc),e(Hc,dF),e(td,cF),e(rt,pF),e(rt,od),e(od,hF),e(od,sd),e(sd,fF),e(od,uF),e(rt,mF),e(rt,ff),e(ff,gF),e(rt,_F),e(rt,io),e(io,uf),e(uf,nd),e(nd,bF),e(io,vF),e(io,mf),e(mf,rd),e(rd,kF),e(io,wF),e(io,gf),e(gf,ad),e(ad,TF),e(io,$F),e(io,_f),e(_f,id),e(id,yF),e(rt,DF),e(rt,Vt),$(ld,Vt,null),e(Vt,FF),e(Vt,Es),e(Es,EF),e(Es,bf),e(bf,BF),e(Es,xF),e(Es,vf),e(vf,MF),e(Es,zF),e(Vt,jF),$(Zn,Vt,null),e(Vt,CF),$(er,Vt,null),_(n,bm,g),_(n,Bs,g),e(Bs,tr),e(tr,kf),$(dd,kf,null),e(Bs,PF),e(Bs,wf),e(wf,qF),_(n,vm,g),_(n,at,g),$(cd,at,null),e(at,AF),e(at,xs),e(xs,OF),e(xs,Tf),e(Tf,LF),e(xs,IF),e(xs,$f),e($f,SF),e(xs,NF),e(at,RF),e(at,pd),e(pd,WF),e(pd,Kc),e(Kc,QF),e(pd,UF),e(at,HF),e(at,hd),e(hd,KF),e(hd,fd),e(fd,VF),e(hd,JF),e(at,GF),e(at,yf),e(yf,XF),e(at,YF),e(at,lo),e(lo,Df),e(Df,ud),e(ud,ZF),e(lo,e4),e(lo,Ff),e(Ff,md),e(md,t4),e(lo,o4),e(lo,Ef),e(Ef,gd),e(gd,s4),e(lo,n4),e(lo,Bf),e(Bf,_d),e(_d,r4),e(at,a4),e(at,Jt),$(bd,Jt,null),e(Jt,i4),e(Jt,Ms),e(Ms,l4),e(Ms,xf),e(xf,d4),e(Ms,c4),e(Ms,Mf),e(Mf,p4),e(Ms,h4),e(Jt,f4),$(or,Jt,null),e(Jt,u4),$(sr,Jt,null),km=!0},p(n,[g]){const vd={};g&2&&(vd.$$scope={dirty:g,ctx:n}),As.$set(vd);const zf={};g&2&&(zf.$$scope={dirty:g,ctx:n}),Rs.$set(zf);const jf={};g&2&&(jf.$$scope={dirty:g,ctx:n}),Ws.$set(jf);const Cf={};g&2&&(Cf.$$scope={dirty:g,ctx:n}),Us.$set(Cf);const kd={};g&2&&(kd.$$scope={dirty:g,ctx:n}),Hs.$set(kd);const Pf={};g&2&&(Pf.$$scope={dirty:g,ctx:n}),Ks.$set(Pf);const qf={};g&2&&(qf.$$scope={dirty:g,ctx:n}),Js.$set(qf);const Af={};g&2&&(Af.$$scope={dirty:g,ctx:n}),Gs.$set(Af);const co={};g&2&&(co.$$scope={dirty:g,ctx:n}),Xs.$set(co);const Of={};g&2&&(Of.$$scope={dirty:g,ctx:n}),Ys.$set(Of);const Lf={};g&2&&(Lf.$$scope={dirty:g,ctx:n}),Zs.$set(Lf);const If={};g&2&&(If.$$scope={dirty:g,ctx:n}),tn.$set(If);const Sf={};g&2&&(Sf.$$scope={dirty:g,ctx:n}),on.$set(Sf);const Nf={};g&2&&(Nf.$$scope={dirty:g,ctx:n}),nn.$set(Nf);const Rf={};g&2&&(Rf.$$scope={dirty:g,ctx:n}),rn.$set(Rf);const Wf={};g&2&&(Wf.$$scope={dirty:g,ctx:n}),an.$set(Wf);const wd={};g&2&&(wd.$$scope={dirty:g,ctx:n}),dn.$set(wd);const po={};g&2&&(po.$$scope={dirty:g,ctx:n}),cn.$set(po);const Qf={};g&2&&(Qf.$$scope={dirty:g,ctx:n}),pn.$set(Qf);const Uf={};g&2&&(Uf.$$scope={dirty:g,ctx:n}),fn.$set(Uf);const Hf={};g&2&&(Hf.$$scope={dirty:g,ctx:n}),un.$set(Hf);const Td={};g&2&&(Td.$$scope={dirty:g,ctx:n}),mn.$set(Td);const Kf={};g&2&&(Kf.$$scope={dirty:g,ctx:n}),_n.$set(Kf);const ho={};g&2&&(ho.$$scope={dirty:g,ctx:n}),bn.$set(ho);const Vf={};g&2&&(Vf.$$scope={dirty:g,ctx:n}),vn.$set(Vf);const Jf={};g&2&&(Jf.$$scope={dirty:g,ctx:n}),kn.$set(Jf);const Gf={};g&2&&(Gf.$$scope={dirty:g,ctx:n}),Tn.$set(Gf);const $d={};g&2&&($d.$$scope={dirty:g,ctx:n}),$n.$set($d);const Xf={};g&2&&(Xf.$$scope={dirty:g,ctx:n}),yn.$set(Xf);const Yf={};g&2&&(Yf.$$scope={dirty:g,ctx:n}),Dn.$set(Yf);const Zf={};g&2&&(Zf.$$scope={dirty:g,ctx:n}),En.$set(Zf);const eu={};g&2&&(eu.$$scope={dirty:g,ctx:n}),Bn.$set(eu);const Qe={};g&2&&(Qe.$$scope={dirty:g,ctx:n}),xn.$set(Qe);const yd={};g&2&&(yd.$$scope={dirty:g,ctx:n}),zn.$set(yd);const tu={};g&2&&(tu.$$scope={dirty:g,ctx:n}),jn.$set(tu);const Dd={};g&2&&(Dd.$$scope={dirty:g,ctx:n}),Cn.$set(Dd);const ou={};g&2&&(ou.$$scope={dirty:g,ctx:n}),Pn.$set(ou);const Fd={};g&2&&(Fd.$$scope={dirty:g,ctx:n}),An.$set(Fd);const su={};g&2&&(su.$$scope={dirty:g,ctx:n}),On.$set(su);const Ed={};g&2&&(Ed.$$scope={dirty:g,ctx:n}),Ln.$set(Ed);const nu={};g&2&&(nu.$$scope={dirty:g,ctx:n}),In.$set(nu);const Bd={};g&2&&(Bd.$$scope={dirty:g,ctx:n}),Nn.$set(Bd);const ru={};g&2&&(ru.$$scope={dirty:g,ctx:n}),Rn.$set(ru);const xd={};g&2&&(xd.$$scope={dirty:g,ctx:n}),Qn.$set(xd);const au={};g&2&&(au.$$scope={dirty:g,ctx:n}),Un.$set(au);const Md={};g&2&&(Md.$$scope={dirty:g,ctx:n}),Kn.$set(Md);const iu={};g&2&&(iu.$$scope={dirty:g,ctx:n}),Vn.$set(iu);const Eo={};g&2&&(Eo.$$scope={dirty:g,ctx:n}),Gn.$set(Eo);const lu={};g&2&&(lu.$$scope={dirty:g,ctx:n}),Xn.$set(lu);const du={};g&2&&(du.$$scope={dirty:g,ctx:n}),Zn.$set(du);const cu={};g&2&&(cu.$$scope={dirty:g,ctx:n}),er.$set(cu);const Bo={};g&2&&(Bo.$$scope={dirty:g,ctx:n}),or.$set(Bo);const pu={};g&2&&(pu.$$scope={dirty:g,ctx:n}),sr.$set(pu)},i(n){km||(y(l.$$.fragment,n),y(E.$$.fragment,n),y(R.$$.fragment,n),y(Er.$$.fragment,n),y(Vr.$$.fragment,n),y(ta.$$.fragment,n),y(da.$$.fragment,n),y(Aa.$$.fragment,n),y(Oa.$$.fragment,n),y(As.$$.fragment,n),y(Ia.$$.fragment,n),y(Sa.$$.fragment,n),y(Ra.$$.fragment,n),y(Wa.$$.fragment,n),y(Ha.$$.fragment,n),y(Ka.$$.fragment,n),y(Xa.$$.fragment,n),y(Rs.$$.fragment,n),y(Ws.$$.fragment,n),y(Ya.$$.fragment,n),y(Za.$$.fragment,n),y(ni.$$.fragment,n),y(Us.$$.fragment,n),y(Hs.$$.fragment,n),y(Ks.$$.fragment,n),y(ri.$$.fragment,n),y(ai.$$.fragment,n),y(ci.$$.fragment,n),y(Js.$$.fragment,n),y(Gs.$$.fragment,n),y(Xs.$$.fragment,n),y(Ys.$$.fragment,n),y(Zs.$$.fragment,n),y(pi.$$.fragment,n),y(hi.$$.fragment,n),y(gi.$$.fragment,n),y(tn.$$.fragment,n),y(on.$$.fragment,n),y(_i.$$.fragment,n),y(bi.$$.fragment,n),y(Ti.$$.fragment,n),y(nn.$$.fragment,n),y(rn.$$.fragment,n),y(an.$$.fragment,n),y($i.$$.fragment,n),y(yi.$$.fragment,n),y(Bi.$$.fragment,n),y(dn.$$.fragment,n),y(cn.$$.fragment,n),y(pn.$$.fragment,n),y(xi.$$.fragment,n),y(Mi.$$.fragment,n),y(fn.$$.fragment,n),y(Pi.$$.fragment,n),y(un.$$.fragment,n),y(mn.$$.fragment,n),y(qi.$$.fragment,n),y(Ai.$$.fragment,n),y(_n.$$.fragment,n),y(Ni.$$.fragment,n),y(bn.$$.fragment,n),y(vn.$$.fragment,n),y(kn.$$.fragment,n),y(Ri.$$.fragment,n),y(Wi.$$.fragment,n),y(Tn.$$.fragment,n),y(Ki.$$.fragment,n),y($n.$$.fragment,n),y(yn.$$.fragment,n),y(Dn.$$.fragment,n),y(Vi.$$.fragment,n),y(Ji.$$.fragment,n),y(En.$$.fragment,n),y(Zi.$$.fragment,n),y(Bn.$$.fragment,n),y(xn.$$.fragment,n),y(el.$$.fragment,n),y(tl.$$.fragment,n),y(zn.$$.fragment,n),y(rl.$$.fragment,n),y(jn.$$.fragment,n),y(Cn.$$.fragment,n),y(Pn.$$.fragment,n),y(al.$$.fragment,n),y(il.$$.fragment,n),y(An.$$.fragment,n),y(pl.$$.fragment,n),y(On.$$.fragment,n),y(Ln.$$.fragment,n),y(In.$$.fragment,n),y(hl.$$.fragment,n),y(fl.$$.fragment,n),y(wl.$$.fragment,n),y(Nn.$$.fragment,n),y(Rn.$$.fragment,n),y(Tl.$$.fragment,n),y($l.$$.fragment,n),y(jl.$$.fragment,n),y(Qn.$$.fragment,n),y(Un.$$.fragment,n),y(Cl.$$.fragment,n),y(Pl.$$.fragment,n),y(Rl.$$.fragment,n),y(Kn.$$.fragment,n),y(Vn.$$.fragment,n),y(Wl.$$.fragment,n),y(Ql.$$.fragment,n),y(Yl.$$.fragment,n),y(Gn.$$.fragment,n),y(Xn.$$.fragment,n),y(Zl.$$.fragment,n),y(ed.$$.fragment,n),y(ld.$$.fragment,n),y(Zn.$$.fragment,n),y(er.$$.fragment,n),y(dd.$$.fragment,n),y(cd.$$.fragment,n),y(bd.$$.fragment,n),y(or.$$.fragment,n),y(sr.$$.fragment,n),km=!0)},o(n){D(l.$$.fragment,n),D(E.$$.fragment,n),D(R.$$.fragment,n),D(Er.$$.fragment,n),D(Vr.$$.fragment,n),D(ta.$$.fragment,n),D(da.$$.fragment,n),D(Aa.$$.fragment,n),D(Oa.$$.fragment,n),D(As.$$.fragment,n),D(Ia.$$.fragment,n),D(Sa.$$.fragment,n),D(Ra.$$.fragment,n),D(Wa.$$.fragment,n),D(Ha.$$.fragment,n),D(Ka.$$.fragment,n),D(Xa.$$.fragment,n),D(Rs.$$.fragment,n),D(Ws.$$.fragment,n),D(Ya.$$.fragment,n),D(Za.$$.fragment,n),D(ni.$$.fragment,n),D(Us.$$.fragment,n),D(Hs.$$.fragment,n),D(Ks.$$.fragment,n),D(ri.$$.fragment,n),D(ai.$$.fragment,n),D(ci.$$.fragment,n),D(Js.$$.fragment,n),D(Gs.$$.fragment,n),D(Xs.$$.fragment,n),D(Ys.$$.fragment,n),D(Zs.$$.fragment,n),D(pi.$$.fragment,n),D(hi.$$.fragment,n),D(gi.$$.fragment,n),D(tn.$$.fragment,n),D(on.$$.fragment,n),D(_i.$$.fragment,n),D(bi.$$.fragment,n),D(Ti.$$.fragment,n),D(nn.$$.fragment,n),D(rn.$$.fragment,n),D(an.$$.fragment,n),D($i.$$.fragment,n),D(yi.$$.fragment,n),D(Bi.$$.fragment,n),D(dn.$$.fragment,n),D(cn.$$.fragment,n),D(pn.$$.fragment,n),D(xi.$$.fragment,n),D(Mi.$$.fragment,n),D(fn.$$.fragment,n),D(Pi.$$.fragment,n),D(un.$$.fragment,n),D(mn.$$.fragment,n),D(qi.$$.fragment,n),D(Ai.$$.fragment,n),D(_n.$$.fragment,n),D(Ni.$$.fragment,n),D(bn.$$.fragment,n),D(vn.$$.fragment,n),D(kn.$$.fragment,n),D(Ri.$$.fragment,n),D(Wi.$$.fragment,n),D(Tn.$$.fragment,n),D(Ki.$$.fragment,n),D($n.$$.fragment,n),D(yn.$$.fragment,n),D(Dn.$$.fragment,n),D(Vi.$$.fragment,n),D(Ji.$$.fragment,n),D(En.$$.fragment,n),D(Zi.$$.fragment,n),D(Bn.$$.fragment,n),D(xn.$$.fragment,n),D(el.$$.fragment,n),D(tl.$$.fragment,n),D(zn.$$.fragment,n),D(rl.$$.fragment,n),D(jn.$$.fragment,n),D(Cn.$$.fragment,n),D(Pn.$$.fragment,n),D(al.$$.fragment,n),D(il.$$.fragment,n),D(An.$$.fragment,n),D(pl.$$.fragment,n),D(On.$$.fragment,n),D(Ln.$$.fragment,n),D(In.$$.fragment,n),D(hl.$$.fragment,n),D(fl.$$.fragment,n),D(wl.$$.fragment,n),D(Nn.$$.fragment,n),D(Rn.$$.fragment,n),D(Tl.$$.fragment,n),D($l.$$.fragment,n),D(jl.$$.fragment,n),D(Qn.$$.fragment,n),D(Un.$$.fragment,n),D(Cl.$$.fragment,n),D(Pl.$$.fragment,n),D(Rl.$$.fragment,n),D(Kn.$$.fragment,n),D(Vn.$$.fragment,n),D(Wl.$$.fragment,n),D(Ql.$$.fragment,n),D(Yl.$$.fragment,n),D(Gn.$$.fragment,n),D(Xn.$$.fragment,n),D(Zl.$$.fragment,n),D(ed.$$.fragment,n),D(ld.$$.fragment,n),D(Zn.$$.fragment,n),D(er.$$.fragment,n),D(dd.$$.fragment,n),D(cd.$$.fragment,n),D(bd.$$.fragment,n),D(or.$$.fragment,n),D(sr.$$.fragment,n),km=!1},d(n){t(d),n&&t(b),n&&t(f),F(l),n&&t(ge),n&&t(I),F(E),n&&t(_e),n&&t(O),n&&t(be),n&&t(ee),n&&t(q),n&&t(le),n&&t(ve),n&&t(W),n&&t(ke),n&&t(C),n&&t(k),n&&t(x),n&&t(L),n&&t(N),F(R),n&&t(Ue),n&&t(te),n&&t(gu),F(Er,n),n&&t(_u),n&&t(Ie),n&&t(bu),F(Vr,n),n&&t(vu),n&&t(Ot),n&&t(ku),F(ta,n),n&&t(wu),n&&t(Lt),n&&t(Tu),F(da,n),n&&t($u),n&&t(It),n&&t(yu),n&&t(oc),n&&t(Du),n&&t(Cs),n&&t(Fu),n&&t(rc),n&&t(Eu),n&&t(Do),n&&t(Bu),n&&t(ac),n&&t(xu),n&&t(Ps),n&&t(Mu),n&&t(ic),n&&t(zu),n&&t(Fo),n&&t(ju),n&&t(Ro),F(Aa),n&&t(Cu),n&&t(Pt),F(Oa),F(As),n&&t(Pu),n&&t(Qo),F(Ia),n&&t(qu),n&&t(qt),F(Sa),n&&t(Au),n&&t(Uo),F(Ra),n&&t(Ou),n&&t(At),F(Wa),n&&t(Lu),n&&t(Ho),F(Ha),n&&t(Iu),n&&t(ut),F(Ka),F(Xa),F(Rs),F(Ws),n&&t(Su),n&&t(Vo),F(Ya),n&&t(Nu),n&&t(mt),F(Za),F(ni),F(Us),F(Hs),F(Ks),n&&t(Ru),n&&t(Go),F(ri),n&&t(Wu),n&&t(gt),F(ai),F(ci),F(Js),F(Gs),F(Xs),F(Ys),F(Zs),n&&t(Qu),n&&t(Yo),F(pi),n&&t(Uu),n&&t(_t),F(hi),F(gi),F(tn),F(on),n&&t(Hu),n&&t(es),F(_i),n&&t(Ku),n&&t(bt),F(bi),F(Ti),F(nn),F(rn),F(an),n&&t(Vu),n&&t(os),F($i),n&&t(Ju),n&&t(vt),F(yi),F(Bi),F(dn),F(cn),F(pn),n&&t(Gu),n&&t(rs),F(xi),n&&t(Xu),n&&t(lt),F(Mi),F(fn),F(Pi),F(un),F(mn),n&&t(Yu),n&&t(is),F(qi),n&&t(Zu),n&&t(dt),F(Ai),F(_n),F(Ni),F(bn),F(vn),F(kn),n&&t(em),n&&t(ds),F(Ri),n&&t(tm),n&&t(ct),F(Wi),F(Tn),F(Ki),F($n),F(yn),F(Dn),n&&t(om),n&&t(ps),F(Vi),n&&t(sm),n&&t(pt),F(Ji),F(En),F(Zi),F(Bn),F(xn),n&&t(nm),n&&t(fs),F(el),n&&t(rm),n&&t(ht),F(tl),F(zn),F(rl),F(jn),F(Cn),F(Pn),n&&t(am),n&&t(ms),F(al),n&&t(im),n&&t(ft),F(il),F(An),F(pl),F(On),F(Ln),F(In),n&&t(lm),n&&t(bs),F(hl),n&&t(dm),n&&t(tt),F(fl),F(wl),F(Nn),F(Rn),n&&t(cm),n&&t(ks),F(Tl),n&&t(pm),n&&t(ot),F($l),F(jl),F(Qn),F(Un),n&&t(hm),n&&t(Ts),F(Cl),n&&t(fm),n&&t(st),F(Pl),F(Rl),F(Kn),F(Vn),n&&t(um),n&&t(ys),F(Wl),n&&t(mm),n&&t(nt),F(Ql),F(Yl),F(Gn),F(Xn),n&&t(gm),n&&t(Fs),F(Zl),n&&t(_m),n&&t(rt),F(ed),F(ld),F(Zn),F(er),n&&t(bm),n&&t(Bs),F(dd),n&&t(vm),n&&t(at),F(cd),F(bd),F(or),F(sr)}}}const BM={local:"distilbert",sections:[{local:"overview",title:"Overview"},{local:"resources",title:"Resources"},{local:"transformers.DistilBertConfig",title:"DistilBertConfig"},{local:"transformers.DistilBertTokenizer",title:"DistilBertTokenizer"},{local:"transformers.DistilBertTokenizerFast",title:"DistilBertTokenizerFast"},{local:"transformers.DistilBertModel",title:"DistilBertModel"},{local:"transformers.DistilBertForMaskedLM",title:"DistilBertForMaskedLM"},{local:"transformers.DistilBertForSequenceClassification",title:"DistilBertForSequenceClassification"},{local:"transformers.DistilBertForMultipleChoice",title:"DistilBertForMultipleChoice"},{local:"transformers.DistilBertForTokenClassification",title:"DistilBertForTokenClassification"},{local:"transformers.DistilBertForQuestionAnswering",title:"DistilBertForQuestionAnswering"},{local:"transformers.TFDistilBertModel",title:"TFDistilBertModel"},{local:"transformers.TFDistilBertForMaskedLM",title:"TFDistilBertForMaskedLM"},{local:"transformers.TFDistilBertForSequenceClassification",title:"TFDistilBertForSequenceClassification"},{local:"transformers.TFDistilBertForMultipleChoice",title:"TFDistilBertForMultipleChoice"},{local:"transformers.TFDistilBertForTokenClassification",title:"TFDistilBertForTokenClassification"},{local:"transformers.TFDistilBertForQuestionAnswering",title:"TFDistilBertForQuestionAnswering"},{local:"transformers.FlaxDistilBertModel",title:"FlaxDistilBertModel"},{local:"transformers.FlaxDistilBertForMaskedLM",title:"FlaxDistilBertForMaskedLM"},{local:"transformers.FlaxDistilBertForSequenceClassification",title:"FlaxDistilBertForSequenceClassification"},{local:"transformers.FlaxDistilBertForMultipleChoice",title:"FlaxDistilBertForMultipleChoice"},{local:"transformers.FlaxDistilBertForTokenClassification",title:"FlaxDistilBertForTokenClassification"},{local:"transformers.FlaxDistilBertForQuestionAnswering",title:"FlaxDistilBertForQuestionAnswering"}],title:"DistilBERT"};function xM(B){return E5(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class OM extends $5{constructor(d){super();y5(this,d,xM,EM,D5,{})}}export{OM as default,BM as metadata};
