import{S as uC,i as fC,s as mC,e as n,k as p,w,t as o,M as gC,c as r,d as t,m as h,a,x as T,h as s,b as c,N as CB,G as e,g,y as k,q as M,o as $,B as E,v as _C,L as We}from"../../chunks/vendor-hf-doc-builder.js";import{T as Ze}from"../../chunks/Tip-hf-doc-builder.js";import{D as R}from"../../chunks/Docstring-hf-doc-builder.js";import{C as Ae}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ge}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as Ie}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";import{P as Q_}from"../../chunks/PipelineTag-hf-doc-builder.js";function bC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMERpc3RpbEJlcnRDb25maWclMkMlMjBEaXN0aWxCZXJ0TW9kZWwlMEElMEElMjMlMjBJbml0aWFsaXppbmclMjBhJTIwRGlzdGlsQkVSVCUyMGNvbmZpZ3VyYXRpb24lMEFjb25maWd1cmF0aW9uJTIwJTNEJTIwRGlzdGlsQmVydENvbmZpZygpJTBBJTBBJTIzJTIwSW5pdGlhbGl6aW5nJTIwYSUyMG1vZGVsJTIwKHdpdGglMjByYW5kb20lMjB3ZWlnaHRzKSUyMGZyb20lMjB0aGUlMjBjb25maWd1cmF0aW9uJTBBbW9kZWwlMjAlM0QlMjBEaXN0aWxCZXJ0TW9kZWwoY29uZmlndXJhdGlvbiklMEElMEElMjMlMjBBY2Nlc3NpbmclMjB0aGUlMjBtb2RlbCUyMGNvbmZpZ3VyYXRpb24lMEFjb25maWd1cmF0aW9uJTIwJTNEJTIwbW9kZWwuY29uZmln",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=n("p"),v=o("Examples:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Examples:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function vC(B){let d,v,f,m,b;return m=new Ae({props:{code:"MCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMEElN0MlMjBmaXJzdCUyMHNlcXVlbmNlJTIwJTIwJTIwJTIwJTdDJTIwc2Vjb25kJTIwc2VxdWVuY2UlMjAlN0M=",highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence    | second sequence |`}}),{c(){d=n("p"),v=o("pair mask has the following format:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"pair mask has the following format:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function yC(B){let d,v,f,m,b;return m=new Ae({props:{code:"MCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMEElN0MlMjBmaXJzdCUyMHNlcXVlbmNlJTIwJTIwJTIwJTIwJTdDJTIwc2Vjb25kJTIwc2VxdWVuY2UlMjAlN0M=",highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence    | second sequence |`}}),{c(){d=n("p"),v=o("pair mask has the following format:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"pair mask has the following format:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function wC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function TC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBEaXN0aWxCZXJ0TW9kZWwlMEFpbXBvcnQlMjB0b3JjaCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMmRpc3RpbGJlcnQtYmFzZS11bmNhc2VkJTIyKSUwQW1vZGVsJTIwJTNEJTIwRGlzdGlsQmVydE1vZGVsLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIoJTIySGVsbG8lMkMlMjBteSUyMGRvZyUyMGlzJTIwY3V0ZSUyMiUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIpJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKSUwQSUwQWxhc3RfaGlkZGVuX3N0YXRlcyUyMCUzRCUyMG91dHB1dHMubGFzdF9oaWRkZW5fc3RhdGU=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function kC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function MC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBEaXN0aWxCZXJ0Rm9yTWFza2VkTE0lMEFpbXBvcnQlMjB0b3JjaCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMmRpc3RpbGJlcnQtYmFzZS11bmNhc2VkJTIyKSUwQW1vZGVsJTIwJTNEJTIwRGlzdGlsQmVydEZvck1hc2tlZExNLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIoJTIyVGhlJTIwY2FwaXRhbCUyMG9mJTIwRnJhbmNlJTIwaXMlMjAlNUJNQVNLJTVELiUyMiUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIpJTBBJTBBd2l0aCUyMHRvcmNoLm5vX2dyYWQoKSUzQSUwQSUyMCUyMCUyMCUyMGxvZ2l0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKS5sb2dpdHMlMEElMEElMjMlMjByZXRyaWV2ZSUyMGluZGV4JTIwb2YlMjAlNUJNQVNLJTVEJTBBbWFza190b2tlbl9pbmRleCUyMCUzRCUyMChpbnB1dHMuaW5wdXRfaWRzJTIwJTNEJTNEJTIwdG9rZW5pemVyLm1hc2tfdG9rZW5faWQpJTVCMCU1RC5ub256ZXJvKGFzX3R1cGxlJTNEVHJ1ZSklNUIwJTVEJTBBJTBBcHJlZGljdGVkX3Rva2VuX2lkJTIwJTNEJTIwbG9naXRzJTVCMCUyQyUyMG1hc2tfdG9rZW5faW5kZXglNUQuYXJnbWF4KGF4aXMlM0QtMSklMEElMEFsYWJlbHMlMjAlM0QlMjB0b2tlbml6ZXIoJTIyVGhlJTIwY2FwaXRhbCUyMG9mJTIwRnJhbmNlJTIwaXMlMjBQYXJpcy4lMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSU1QiUyMmlucHV0X2lkcyUyMiU1RCUwQSUyMyUyMG1hc2slMjBsYWJlbHMlMjBvZiUyMG5vbi0lNUJNQVNLJTVEJTIwdG9rZW5zJTBBbGFiZWxzJTIwJTNEJTIwdG9yY2gud2hlcmUoaW5wdXRzLmlucHV0X2lkcyUyMCUzRCUzRCUyMHRva2VuaXplci5tYXNrX3Rva2VuX2lkJTJDJTIwbGFiZWxzJTJDJTIwLTEwMCklMEElMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMlMkMlMjBsYWJlbHMlM0RsYWJlbHMp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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>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)`}}),{c(){d=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function $C(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function EC(B){let d,v,f,m,b;return m=new Ae({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMERpc3RpbEJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBEaXN0aWxCZXJ0Rm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBsb2dpdHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cykubG9naXRzJTBBJTBBcHJlZGljdGVkX2NsYXNzX2lkJTIwJTNEJTIwbG9naXRzLmFyZ21heCgpLml0ZW0oKSUwQSUwQSUyMyUyMFRvJTIwdHJhaW4lMjBhJTIwbW9kZWwlMjBvbiUyMCU2MG51bV9sYWJlbHMlNjAlMjBjbGFzc2VzJTJDJTIweW91JTIwY2FuJTIwcGFzcyUyMCU2MG51bV9sYWJlbHMlM0RudW1fbGFiZWxzJTYwJTIwdG8lMjAlNjAuZnJvbV9wcmV0cmFpbmVkKC4uLiklNjAlMEFudW1fbGFiZWxzJTIwJTNEJTIwbGVuKG1vZGVsLmNvbmZpZy5pZDJsYWJlbCklMEFtb2RlbCUyMCUzRCUyMERpc3RpbEJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiUyQyUyMG51bV9sYWJlbHMlM0RudW1fbGFiZWxzKSUwQSUwQWxhYmVscyUyMCUzRCUyMHRvcmNoLnRlbnNvciglNUIxJTVEKSUwQWxvc3MlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscykubG9zcw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DistilBertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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><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`}}),{c(){d=n("p"),v=o("Example of single-label classification:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example of single-label classification:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function FC(B){let d,v,f,m,b;return m=new Ae({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMERpc3RpbEJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBEaXN0aWxCZXJ0Rm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIlMkMlMjBwcm9ibGVtX3R5cGUlM0QlMjJtdWx0aV9sYWJlbF9jbGFzc2lmaWNhdGlvbiUyMiklMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIoJTIySGVsbG8lMkMlMjBteSUyMGRvZyUyMGlzJTIwY3V0ZSUyMiUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIpJTBBJTBBd2l0aCUyMHRvcmNoLm5vX2dyYWQoKSUzQSUwQSUyMCUyMCUyMCUyMGxvZ2l0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKS5sb2dpdHMlMEElMEFwcmVkaWN0ZWRfY2xhc3NfaWRzJTIwJTNEJTIwdG9yY2guYXJhbmdlKDAlMkMlMjBsb2dpdHMuc2hhcGUlNUItMSU1RCklNUJ0b3JjaC5zaWdtb2lkKGxvZ2l0cykuc3F1ZWV6ZShkaW0lM0QwKSUyMCUzRSUyMDAuNSU1RCUwQSUwQSUyMyUyMFRvJTIwdHJhaW4lMjBhJTIwbW9kZWwlMjBvbiUyMCU2MG51bV9sYWJlbHMlNjAlMjBjbGFzc2VzJTJDJTIweW91JTIwY2FuJTIwcGFzcyUyMCU2MG51bV9sYWJlbHMlM0RudW1fbGFiZWxzJTYwJTIwdG8lMjAlNjAuZnJvbV9wcmV0cmFpbmVkKC4uLiklNjAlMEFudW1fbGFiZWxzJTIwJTNEJTIwbGVuKG1vZGVsLmNvbmZpZy5pZDJsYWJlbCklMEFtb2RlbCUyMCUzRCUyMERpc3RpbEJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMEElMjAlMjAlMjAlMjAlMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiUyQyUyMG51bV9sYWJlbHMlM0RudW1fbGFiZWxzJTJDJTIwcHJvYmxlbV90eXBlJTNEJTIybXVsdGlfbGFiZWxfY2xhc3NpZmljYXRpb24lMjIlMEEpJTBBJTBBbGFiZWxzJTIwJTNEJTIwdG9yY2guc3VtKCUwQSUyMCUyMCUyMCUyMHRvcmNoLm5uLmZ1bmN0aW9uYWwub25lX2hvdChwcmVkaWN0ZWRfY2xhc3NfaWRzJTVCTm9uZSUyQyUyMCUzQSU1RC5jbG9uZSgpJTJDJTIwbnVtX2NsYXNzZXMlM0RudW1fbGFiZWxzKSUyQyUyMGRpbSUzRDElMEEpLnRvKHRvcmNoLmZsb2F0KSUwQWxvc3MlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscykubG9zcw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, DistilBertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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_ids = torch.arange(<span class="hljs-number">0</span>, logits.shape[-<span class="hljs-number">1</span>])[torch.sigmoid(logits).squeeze(dim=<span class="hljs-number">0</span>) &gt; <span class="hljs-number">0.5</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = 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.<span class="hljs-built_in">sum</span>(
<span class="hljs-meta">... </span>    torch.nn.functional.one_hot(predicted_class_ids[<span class="hljs-literal">None</span>, :].clone(), num_classes=num_labels), dim=<span class="hljs-number">1</span>
<span class="hljs-meta">... </span>).to(torch.<span class="hljs-built_in">float</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=n("p"),v=o("Example of multi-label classification:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example of multi-label classification:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function BC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function jC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBEaXN0aWxCZXJ0Rm9yTXVsdGlwbGVDaG9pY2UlMEFpbXBvcnQlMjB0b3JjaCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMmRpc3RpbGJlcnQtYmFzZS1jYXNlZCUyMiklMEFtb2RlbCUyMCUzRCUyMERpc3RpbEJlcnRGb3JNdWx0aXBsZUNob2ljZS5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLWNhc2VkJTIyKSUwQSUwQXByb21wdCUyMCUzRCUyMCUyMkluJTIwSXRhbHklMkMlMjBwaXp6YSUyMHNlcnZlZCUyMGluJTIwZm9ybWFsJTIwc2V0dGluZ3MlMkMlMjBzdWNoJTIwYXMlMjBhdCUyMGElMjByZXN0YXVyYW50JTJDJTIwaXMlMjBwcmVzZW50ZWQlMjB1bnNsaWNlZC4lMjIlMEFjaG9pY2UwJTIwJTNEJTIwJTIySXQlMjBpcyUyMGVhdGVuJTIwd2l0aCUyMGElMjBmb3JrJTIwYW5kJTIwYSUyMGtuaWZlLiUyMiUwQWNob2ljZTElMjAlM0QlMjAlMjJJdCUyMGlzJTIwZWF0ZW4lMjB3aGlsZSUyMGhlbGQlMjBpbiUyMHRoZSUyMGhhbmQuJTIyJTBBbGFiZWxzJTIwJTNEJTIwdG9yY2gudGVuc29yKDApLnVuc3F1ZWV6ZSgwKSUyMCUyMCUyMyUyMGNob2ljZTAlMjBpcyUyMGNvcnJlY3QlMjAoYWNjb3JkaW5nJTIwdG8lMjBXaWtpcGVkaWElMjAlM0IpKSUyQyUyMGJhdGNoJTIwc2l6ZSUyMDElMEElMEFlbmNvZGluZyUyMCUzRCUyMHRva2VuaXplciglNUIlNUJwcm9tcHQlMkMlMjBjaG9pY2UwJTVEJTJDJTIwJTVCcHJvbXB0JTJDJTIwY2hvaWNlMSU1RCU1RCUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIlMkMlMjBwYWRkaW5nJTNEVHJ1ZSklMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKiolN0JrJTNBJTIwdi51bnNxdWVlemUoMCklMjBmb3IlMjBrJTJDJTIwdiUyMGluJTIwZW5jb2RpbmcuaXRlbXMoKSU3RCUyQyUyMGxhYmVscyUzRGxhYmVscyklMjAlMjAlMjMlMjBiYXRjaCUyMHNpemUlMjBpcyUyMDElMEElMEElMjMlMjB0aGUlMjBsaW5lYXIlMjBjbGFzc2lmaWVyJTIwc3RpbGwlMjBuZWVkcyUyMHRvJTIwYmUlMjB0cmFpbmVkJTBBbG9zcyUyMCUzRCUyMG91dHB1dHMubG9zcyUwQWxvZ2l0cyUyMCUzRCUyMG91dHB1dHMubG9naXRz",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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=n("p"),v=o("Examples:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Examples:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function DC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function xC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBEaXN0aWxCZXJ0Rm9yVG9rZW5DbGFzc2lmaWNhdGlvbiUwQWltcG9ydCUyMHRvcmNoJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBEaXN0aWxCZXJ0Rm9yVG9rZW5DbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUwQSUyMCUyMCUyMCUyMCUyMkh1Z2dpbmdGYWNlJTIwaXMlMjBhJTIwY29tcGFueSUyMGJhc2VkJTIwaW4lMjBQYXJpcyUyMGFuZCUyME5ldyUyMFlvcmslMjIlMkMlMjBhZGRfc3BlY2lhbF90b2tlbnMlM0RGYWxzZSUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIlMEEpJTBBJTBBd2l0aCUyMHRvcmNoLm5vX2dyYWQoKSUzQSUwQSUyMCUyMCUyMCUyMGxvZ2l0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKS5sb2dpdHMlMEElMEFwcmVkaWN0ZWRfdG9rZW5fY2xhc3NfaWRzJTIwJTNEJTIwbG9naXRzLmFyZ21heCgtMSklMEElMEElMjMlMjBOb3RlJTIwdGhhdCUyMHRva2VucyUyMGFyZSUyMGNsYXNzaWZpZWQlMjByYXRoZXIlMjB0aGVuJTIwaW5wdXQlMjB3b3JkcyUyMHdoaWNoJTIwbWVhbnMlMjB0aGF0JTBBJTIzJTIwdGhlcmUlMjBtaWdodCUyMGJlJTIwbW9yZSUyMHByZWRpY3RlZCUyMHRva2VuJTIwY2xhc3NlcyUyMHRoYW4lMjB3b3Jkcy4lMEElMjMlMjBNdWx0aXBsZSUyMHRva2VuJTIwY2xhc3NlcyUyMG1pZ2h0JTIwYWNjb3VudCUyMGZvciUyMHRoZSUyMHNhbWUlMjB3b3JkJTBBcHJlZGljdGVkX3Rva2Vuc19jbGFzc2VzJTIwJTNEJTIwJTVCbW9kZWwuY29uZmlnLmlkMmxhYmVsJTVCdC5pdGVtKCklNUQlMjBmb3IlMjB0JTIwaW4lMjBwcmVkaWN0ZWRfdG9rZW5fY2xhc3NfaWRzJTVCMCU1RCU1RCUwQSUwQWxhYmVscyUyMCUzRCUyMHByZWRpY3RlZF90b2tlbl9jbGFzc19pZHMlMEFsb3NzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMlMkMlMjBsYWJlbHMlM0RsYWJlbHMpLmxvc3M=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function CC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function JC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBEaXN0aWxCZXJ0Rm9yUXVlc3Rpb25BbnN3ZXJpbmclMEFpbXBvcnQlMjB0b3JjaCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMmRpc3RpbGJlcnQtYmFzZS11bmNhc2VkJTIyKSUwQW1vZGVsJTIwJTNEJTIwRGlzdGlsQmVydEZvclF1ZXN0aW9uQW5zd2VyaW5nLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEElMEFxdWVzdGlvbiUyQyUyMHRleHQlMjAlM0QlMjAlMjJXaG8lMjB3YXMlMjBKaW0lMjBIZW5zb24lM0YlMjIlMkMlMjAlMjJKaW0lMjBIZW5zb24lMjB3YXMlMjBhJTIwbmljZSUyMHB1cHBldCUyMiUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplcihxdWVzdGlvbiUyQyUyMHRleHQlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBJTBBYW5zd2VyX3N0YXJ0X2luZGV4JTIwJTNEJTIwb3V0cHV0cy5zdGFydF9sb2dpdHMuYXJnbWF4KCklMEFhbnN3ZXJfZW5kX2luZGV4JTIwJTNEJTIwb3V0cHV0cy5lbmRfbG9naXRzLmFyZ21heCgpJTBBJTBBcHJlZGljdF9hbnN3ZXJfdG9rZW5zJTIwJTNEJTIwaW5wdXRzLmlucHV0X2lkcyU1QjAlMkMlMjBhbnN3ZXJfc3RhcnRfaW5kZXglMjAlM0ElMjBhbnN3ZXJfZW5kX2luZGV4JTIwJTJCJTIwMSU1RCUwQSUwQSUyMyUyMHRhcmdldCUyMGlzJTIwJTIybmljZSUyMHB1cHBldCUyMiUwQXRhcmdldF9zdGFydF9pbmRleCUyMCUzRCUyMHRvcmNoLnRlbnNvciglNUIxNCU1RCklMEF0YXJnZXRfZW5kX2luZGV4JTIwJTNEJTIwdG9yY2gudGVuc29yKCU1QjE1JTVEKSUwQSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMHN0YXJ0X3Bvc2l0aW9ucyUzRHRhcmdldF9zdGFydF9pbmRleCUyQyUyMGVuZF9wb3NpdGlvbnMlM0R0YXJnZXRfZW5kX2luZGV4KSUwQWxvc3MlMjAlM0QlMjBvdXRwdXRzLmxvc3M=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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><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`}}),{c(){d=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function zC(B){let d,v,f,m,b,i,u,j,ke,ye,W,ie,K,F,Me,q,de,ze,S,ce,pe,Y,we,se,Z,fe,re,L,me,$e,te,C,U,ae,Q,Ee,le,O,Fe,ge,I,Be,P,he,je,V,ue,_e,N,Te,X,De,oe,J,be,z,xe,ve;return{c(){d=n("p"),v=o("TensorFlow models and layers in "),f=n("code"),m=o("transformers"),b=o(" accept two formats as input:"),i=p(),u=n("ul"),j=n("li"),ke=o("having all inputs as keyword arguments (like PyTorch models), or"),ye=p(),W=n("li"),ie=o("having all inputs as a list, tuple or dict in the first positional argument."),K=p(),F=n("p"),Me=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=n("code"),de=o("model.fit()"),ze=o(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=n("code"),ce=o("model.fit()"),pe=o(` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=n("code"),we=o("fit()"),se=o(" and "),Z=n("code"),fe=o("predict()"),re=o(`, such as when creating your own layers or models with
the Keras `),L=n("code"),me=o("Functional"),$e=o(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),te=p(),C=n("ul"),U=n("li"),ae=o("a single Tensor with "),Q=n("code"),Ee=o("input_ids"),le=o(" only and nothing else: "),O=n("code"),Fe=o("model(input_ids)"),ge=p(),I=n("li"),Be=o(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=n("code"),he=o("model([input_ids, attention_mask])"),je=o(" or "),V=n("code"),ue=o("model([input_ids, attention_mask, token_type_ids])"),_e=p(),N=n("li"),Te=o(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=n("code"),De=o('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),oe=p(),J=n("p"),be=o(`Note that when creating models and layers with
`),z=n("a"),xe=o("subclassing"),ve=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(y){d=r(y,"P",{});var D=a(d);v=s(D,"TensorFlow models and layers in "),f=r(D,"CODE",{});var qe=a(f);m=s(qe,"transformers"),qe.forEach(t),b=s(D," accept two formats as input:"),D.forEach(t),i=h(y),u=r(y,"UL",{});var ne=a(u);j=r(ne,"LI",{});var Se=a(j);ke=s(Se,"having all inputs as keyword arguments (like PyTorch models), or"),Se.forEach(t),ye=h(ne),W=r(ne,"LI",{});var Xe=a(W);ie=s(Xe,"having all inputs as a list, tuple or dict in the first positional argument."),Xe.forEach(t),ne.forEach(t),K=h(y),F=r(y,"P",{});var x=a(F);Me=s(x,`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(x,"CODE",{});var Le=a(q);de=s(Le,"model.fit()"),Le.forEach(t),ze=s(x,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(x,"CODE",{});var Qe=a(S);ce=s(Qe,"model.fit()"),Qe.forEach(t),pe=s(x,` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=r(x,"CODE",{});var Pe=a(Y);we=s(Pe,"fit()"),Pe.forEach(t),se=s(x," and "),Z=r(x,"CODE",{});var Ne=a(Z);fe=s(Ne,"predict()"),Ne.forEach(t),re=s(x,`, such as when creating your own layers or models with
the Keras `),L=r(x,"CODE",{});var Oe=a(L);me=s(Oe,"Functional"),Oe.forEach(t),$e=s(x,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),x.forEach(t),te=h(y),C=r(y,"UL",{});var A=a(C);U=r(A,"LI",{});var H=a(U);ae=s(H,"a single Tensor with "),Q=r(H,"CODE",{});var He=a(Q);Ee=s(He,"input_ids"),He.forEach(t),le=s(H," only and nothing else: "),O=r(H,"CODE",{});var Ye=a(O);Fe=s(Ye,"model(input_ids)"),Ye.forEach(t),H.forEach(t),ge=h(A),I=r(A,"LI",{});var G=a(I);Be=s(G,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=r(G,"CODE",{});var Ve=a(P);he=s(Ve,"model([input_ids, attention_mask])"),Ve.forEach(t),je=s(G," or "),V=r(G,"CODE",{});var Ke=a(V);ue=s(Ke,"model([input_ids, attention_mask, token_type_ids])"),Ke.forEach(t),G.forEach(t),_e=h(A),N=r(A,"LI",{});var Ce=a(N);Te=s(Ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=r(Ce,"CODE",{});var Je=a(X);De=s(Je,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Je.forEach(t),Ce.forEach(t),A.forEach(t),oe=h(y),J=r(y,"P",{});var ee=a(J);be=s(ee,`Note that when creating models and layers with
`),z=r(ee,"A",{href:!0,rel:!0});var et=a(z);xe=s(et,"subclassing"),et.forEach(t),ve=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){c(z,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),c(z,"rel","nofollow")},m(y,D){g(y,d,D),e(d,v),e(d,f),e(f,m),e(d,b),g(y,i,D),g(y,u,D),e(u,j),e(j,ke),e(u,ye),e(u,W),e(W,ie),g(y,K,D),g(y,F,D),e(F,Me),e(F,q),e(q,de),e(F,ze),e(F,S),e(S,ce),e(F,pe),e(F,Y),e(Y,we),e(F,se),e(F,Z),e(Z,fe),e(F,re),e(F,L),e(L,me),e(F,$e),g(y,te,D),g(y,C,D),e(C,U),e(U,ae),e(U,Q),e(Q,Ee),e(U,le),e(U,O),e(O,Fe),e(C,ge),e(C,I),e(I,Be),e(I,P),e(P,he),e(I,je),e(I,V),e(V,ue),e(C,_e),e(C,N),e(N,Te),e(N,X),e(X,De),g(y,oe,D),g(y,J,D),e(J,be),e(J,z),e(z,xe),e(J,ve)},d(y){y&&t(d),y&&t(i),y&&t(u),y&&t(K),y&&t(F),y&&t(te),y&&t(C),y&&t(oe),y&&t(J)}}}function UC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function IC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURkRpc3RpbEJlcnRNb2RlbCUwQWltcG9ydCUyMHRlbnNvcmZsb3clMjBhcyUyMHRmJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBURkRpc3RpbEJlcnRNb2RlbC5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnRmJTIyKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbChpbnB1dHMpJTBBJTBBbGFzdF9oaWRkZW5fc3RhdGVzJTIwJTNEJTIwb3V0cHV0cy5sYXN0X2hpZGRlbl9zdGF0ZQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function WC(B){let d,v,f,m,b,i,u,j,ke,ye,W,ie,K,F,Me,q,de,ze,S,ce,pe,Y,we,se,Z,fe,re,L,me,$e,te,C,U,ae,Q,Ee,le,O,Fe,ge,I,Be,P,he,je,V,ue,_e,N,Te,X,De,oe,J,be,z,xe,ve;return{c(){d=n("p"),v=o("TensorFlow models and layers in "),f=n("code"),m=o("transformers"),b=o(" accept two formats as input:"),i=p(),u=n("ul"),j=n("li"),ke=o("having all inputs as keyword arguments (like PyTorch models), or"),ye=p(),W=n("li"),ie=o("having all inputs as a list, tuple or dict in the first positional argument."),K=p(),F=n("p"),Me=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=n("code"),de=o("model.fit()"),ze=o(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=n("code"),ce=o("model.fit()"),pe=o(` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=n("code"),we=o("fit()"),se=o(" and "),Z=n("code"),fe=o("predict()"),re=o(`, such as when creating your own layers or models with
the Keras `),L=n("code"),me=o("Functional"),$e=o(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),te=p(),C=n("ul"),U=n("li"),ae=o("a single Tensor with "),Q=n("code"),Ee=o("input_ids"),le=o(" only and nothing else: "),O=n("code"),Fe=o("model(input_ids)"),ge=p(),I=n("li"),Be=o(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=n("code"),he=o("model([input_ids, attention_mask])"),je=o(" or "),V=n("code"),ue=o("model([input_ids, attention_mask, token_type_ids])"),_e=p(),N=n("li"),Te=o(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=n("code"),De=o('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),oe=p(),J=n("p"),be=o(`Note that when creating models and layers with
`),z=n("a"),xe=o("subclassing"),ve=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(y){d=r(y,"P",{});var D=a(d);v=s(D,"TensorFlow models and layers in "),f=r(D,"CODE",{});var qe=a(f);m=s(qe,"transformers"),qe.forEach(t),b=s(D," accept two formats as input:"),D.forEach(t),i=h(y),u=r(y,"UL",{});var ne=a(u);j=r(ne,"LI",{});var Se=a(j);ke=s(Se,"having all inputs as keyword arguments (like PyTorch models), or"),Se.forEach(t),ye=h(ne),W=r(ne,"LI",{});var Xe=a(W);ie=s(Xe,"having all inputs as a list, tuple or dict in the first positional argument."),Xe.forEach(t),ne.forEach(t),K=h(y),F=r(y,"P",{});var x=a(F);Me=s(x,`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(x,"CODE",{});var Le=a(q);de=s(Le,"model.fit()"),Le.forEach(t),ze=s(x,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(x,"CODE",{});var Qe=a(S);ce=s(Qe,"model.fit()"),Qe.forEach(t),pe=s(x,` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=r(x,"CODE",{});var Pe=a(Y);we=s(Pe,"fit()"),Pe.forEach(t),se=s(x," and "),Z=r(x,"CODE",{});var Ne=a(Z);fe=s(Ne,"predict()"),Ne.forEach(t),re=s(x,`, such as when creating your own layers or models with
the Keras `),L=r(x,"CODE",{});var Oe=a(L);me=s(Oe,"Functional"),Oe.forEach(t),$e=s(x,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),x.forEach(t),te=h(y),C=r(y,"UL",{});var A=a(C);U=r(A,"LI",{});var H=a(U);ae=s(H,"a single Tensor with "),Q=r(H,"CODE",{});var He=a(Q);Ee=s(He,"input_ids"),He.forEach(t),le=s(H," only and nothing else: "),O=r(H,"CODE",{});var Ye=a(O);Fe=s(Ye,"model(input_ids)"),Ye.forEach(t),H.forEach(t),ge=h(A),I=r(A,"LI",{});var G=a(I);Be=s(G,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=r(G,"CODE",{});var Ve=a(P);he=s(Ve,"model([input_ids, attention_mask])"),Ve.forEach(t),je=s(G," or "),V=r(G,"CODE",{});var Ke=a(V);ue=s(Ke,"model([input_ids, attention_mask, token_type_ids])"),Ke.forEach(t),G.forEach(t),_e=h(A),N=r(A,"LI",{});var Ce=a(N);Te=s(Ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=r(Ce,"CODE",{});var Je=a(X);De=s(Je,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Je.forEach(t),Ce.forEach(t),A.forEach(t),oe=h(y),J=r(y,"P",{});var ee=a(J);be=s(ee,`Note that when creating models and layers with
`),z=r(ee,"A",{href:!0,rel:!0});var et=a(z);xe=s(et,"subclassing"),et.forEach(t),ve=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){c(z,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),c(z,"rel","nofollow")},m(y,D){g(y,d,D),e(d,v),e(d,f),e(f,m),e(d,b),g(y,i,D),g(y,u,D),e(u,j),e(j,ke),e(u,ye),e(u,W),e(W,ie),g(y,K,D),g(y,F,D),e(F,Me),e(F,q),e(q,de),e(F,ze),e(F,S),e(S,ce),e(F,pe),e(F,Y),e(Y,we),e(F,se),e(F,Z),e(Z,fe),e(F,re),e(F,L),e(L,me),e(F,$e),g(y,te,D),g(y,C,D),e(C,U),e(U,ae),e(U,Q),e(Q,Ee),e(U,le),e(U,O),e(O,Fe),e(C,ge),e(C,I),e(I,Be),e(I,P),e(P,he),e(I,je),e(I,V),e(V,ue),e(C,_e),e(C,N),e(N,Te),e(N,X),e(X,De),g(y,oe,D),g(y,J,D),e(J,be),e(J,z),e(z,xe),e(J,ve)},d(y){y&&t(d),y&&t(i),y&&t(u),y&&t(K),y&&t(F),y&&t(te),y&&t(C),y&&t(oe),y&&t(J)}}}function AC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function NC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURkRpc3RpbEJlcnRGb3JNYXNrZWRMTSUwQWltcG9ydCUyMHRlbnNvcmZsb3clMjBhcyUyMHRmJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBURkRpc3RpbEJlcnRGb3JNYXNrZWRMTS5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMlRoZSUyMGNhcGl0YWwlMjBvZiUyMEZyYW5jZSUyMGlzJTIwJTVCTUFTSyU1RC4lMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnRmJTIyKSUwQWxvZ2l0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKS5sb2dpdHMlMEElMEElMjMlMjByZXRyaWV2ZSUyMGluZGV4JTIwb2YlMjAlNUJNQVNLJTVEJTBBbWFza190b2tlbl9pbmRleCUyMCUzRCUyMHRmLndoZXJlKChpbnB1dHMuaW5wdXRfaWRzJTIwJTNEJTNEJTIwdG9rZW5pemVyLm1hc2tfdG9rZW5faWQpJTVCMCU1RCklMEFzZWxlY3RlZF9sb2dpdHMlMjAlM0QlMjB0Zi5nYXRoZXJfbmQobG9naXRzJTVCMCU1RCUyQyUyMGluZGljZXMlM0RtYXNrX3Rva2VuX2luZGV4KSUwQSUwQXByZWRpY3RlZF90b2tlbl9pZCUyMCUzRCUyMHRmLm1hdGguYXJnbWF4KHNlbGVjdGVkX2xvZ2l0cyUyQyUyMGF4aXMlM0QtMSk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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>)`}}),{c(){d=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function RC(B){let d,v;return d=new Ae({props:{code:"bGFiZWxzJTIwJTNEJTIwdG9rZW5pemVyKCUyMlRoZSUyMGNhcGl0YWwlMjBvZiUyMEZyYW5jZSUyMGlzJTIwUGFyaXMuJTIyJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJ0ZiUyMiklNUIlMjJpbnB1dF9pZHMlMjIlNUQlMEElMjMlMjBtYXNrJTIwbGFiZWxzJTIwb2YlMjBub24tJTVCTUFTSyU1RCUyMHRva2VucyUwQWxhYmVscyUyMCUzRCUyMHRmLndoZXJlKGlucHV0cy5pbnB1dF9pZHMlMjAlM0QlM0QlMjB0b2tlbml6ZXIubWFza190b2tlbl9pZCUyQyUyMGxhYmVscyUyQyUyMC0xMDApJTBBJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzJTJDJTIwbGFiZWxzJTNEbGFiZWxzKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># mask labels of non-[MASK] tokens</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tf.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){k(d,f,m),v=!0},p:We,i(f){v||(M(d.$$.fragment,f),v=!0)},o(f){$(d.$$.fragment,f),v=!1},d(f){E(d,f)}}}function ZC(B){let d,v,f,m,b,i,u,j,ke,ye,W,ie,K,F,Me,q,de,ze,S,ce,pe,Y,we,se,Z,fe,re,L,me,$e,te,C,U,ae,Q,Ee,le,O,Fe,ge,I,Be,P,he,je,V,ue,_e,N,Te,X,De,oe,J,be,z,xe,ve;return{c(){d=n("p"),v=o("TensorFlow models and layers in "),f=n("code"),m=o("transformers"),b=o(" accept two formats as input:"),i=p(),u=n("ul"),j=n("li"),ke=o("having all inputs as keyword arguments (like PyTorch models), or"),ye=p(),W=n("li"),ie=o("having all inputs as a list, tuple or dict in the first positional argument."),K=p(),F=n("p"),Me=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=n("code"),de=o("model.fit()"),ze=o(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=n("code"),ce=o("model.fit()"),pe=o(` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=n("code"),we=o("fit()"),se=o(" and "),Z=n("code"),fe=o("predict()"),re=o(`, such as when creating your own layers or models with
the Keras `),L=n("code"),me=o("Functional"),$e=o(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),te=p(),C=n("ul"),U=n("li"),ae=o("a single Tensor with "),Q=n("code"),Ee=o("input_ids"),le=o(" only and nothing else: "),O=n("code"),Fe=o("model(input_ids)"),ge=p(),I=n("li"),Be=o(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=n("code"),he=o("model([input_ids, attention_mask])"),je=o(" or "),V=n("code"),ue=o("model([input_ids, attention_mask, token_type_ids])"),_e=p(),N=n("li"),Te=o(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=n("code"),De=o('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),oe=p(),J=n("p"),be=o(`Note that when creating models and layers with
`),z=n("a"),xe=o("subclassing"),ve=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(y){d=r(y,"P",{});var D=a(d);v=s(D,"TensorFlow models and layers in "),f=r(D,"CODE",{});var qe=a(f);m=s(qe,"transformers"),qe.forEach(t),b=s(D," accept two formats as input:"),D.forEach(t),i=h(y),u=r(y,"UL",{});var ne=a(u);j=r(ne,"LI",{});var Se=a(j);ke=s(Se,"having all inputs as keyword arguments (like PyTorch models), or"),Se.forEach(t),ye=h(ne),W=r(ne,"LI",{});var Xe=a(W);ie=s(Xe,"having all inputs as a list, tuple or dict in the first positional argument."),Xe.forEach(t),ne.forEach(t),K=h(y),F=r(y,"P",{});var x=a(F);Me=s(x,`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(x,"CODE",{});var Le=a(q);de=s(Le,"model.fit()"),Le.forEach(t),ze=s(x,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(x,"CODE",{});var Qe=a(S);ce=s(Qe,"model.fit()"),Qe.forEach(t),pe=s(x,` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=r(x,"CODE",{});var Pe=a(Y);we=s(Pe,"fit()"),Pe.forEach(t),se=s(x," and "),Z=r(x,"CODE",{});var Ne=a(Z);fe=s(Ne,"predict()"),Ne.forEach(t),re=s(x,`, such as when creating your own layers or models with
the Keras `),L=r(x,"CODE",{});var Oe=a(L);me=s(Oe,"Functional"),Oe.forEach(t),$e=s(x,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),x.forEach(t),te=h(y),C=r(y,"UL",{});var A=a(C);U=r(A,"LI",{});var H=a(U);ae=s(H,"a single Tensor with "),Q=r(H,"CODE",{});var He=a(Q);Ee=s(He,"input_ids"),He.forEach(t),le=s(H," only and nothing else: "),O=r(H,"CODE",{});var Ye=a(O);Fe=s(Ye,"model(input_ids)"),Ye.forEach(t),H.forEach(t),ge=h(A),I=r(A,"LI",{});var G=a(I);Be=s(G,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=r(G,"CODE",{});var Ve=a(P);he=s(Ve,"model([input_ids, attention_mask])"),Ve.forEach(t),je=s(G," or "),V=r(G,"CODE",{});var Ke=a(V);ue=s(Ke,"model([input_ids, attention_mask, token_type_ids])"),Ke.forEach(t),G.forEach(t),_e=h(A),N=r(A,"LI",{});var Ce=a(N);Te=s(Ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=r(Ce,"CODE",{});var Je=a(X);De=s(Je,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Je.forEach(t),Ce.forEach(t),A.forEach(t),oe=h(y),J=r(y,"P",{});var ee=a(J);be=s(ee,`Note that when creating models and layers with
`),z=r(ee,"A",{href:!0,rel:!0});var et=a(z);xe=s(et,"subclassing"),et.forEach(t),ve=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){c(z,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),c(z,"rel","nofollow")},m(y,D){g(y,d,D),e(d,v),e(d,f),e(f,m),e(d,b),g(y,i,D),g(y,u,D),e(u,j),e(j,ke),e(u,ye),e(u,W),e(W,ie),g(y,K,D),g(y,F,D),e(F,Me),e(F,q),e(q,de),e(F,ze),e(F,S),e(S,ce),e(F,pe),e(F,Y),e(Y,we),e(F,se),e(F,Z),e(Z,fe),e(F,re),e(F,L),e(L,me),e(F,$e),g(y,te,D),g(y,C,D),e(C,U),e(U,ae),e(U,Q),e(Q,Ee),e(U,le),e(U,O),e(O,Fe),e(C,ge),e(C,I),e(I,Be),e(I,P),e(P,he),e(I,je),e(I,V),e(V,ue),e(C,_e),e(C,N),e(N,Te),e(N,X),e(X,De),g(y,oe,D),g(y,J,D),e(J,be),e(J,z),e(z,xe),e(J,ve)},d(y){y&&t(d),y&&t(i),y&&t(u),y&&t(K),y&&t(F),y&&t(te),y&&t(C),y&&t(oe),y&&t(J)}}}function GC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function qC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURkRpc3RpbEJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uJTBBaW1wb3J0JTIwdGVuc29yZmxvdyUyMGFzJTIwdGYlMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEFtb2RlbCUyMCUzRCUyMFRGRGlzdGlsQmVydEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMmRpc3RpbGJlcnQtYmFzZS11bmNhc2VkJTIyKSUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplciglMjJIZWxsbyUyQyUyMG15JTIwZG9nJTIwaXMlMjBjdXRlJTIyJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJ0ZiUyMiklMEElMEFsb2dpdHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cykubG9naXRzJTBBJTBBcHJlZGljdGVkX2NsYXNzX2lkJTIwJTNEJTIwaW50KHRmLm1hdGguYXJnbWF4KGxvZ2l0cyUyQyUyMGF4aXMlM0QtMSklNUIwJTVEKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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>])`}}),{c(){d=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function XC(B){let d,v;return d=new Ae({props:{code:"JTIzJTIwVG8lMjB0cmFpbiUyMGElMjBtb2RlbCUyMG9uJTIwJTYwbnVtX2xhYmVscyU2MCUyMGNsYXNzZXMlMkMlMjB5b3UlMjBjYW4lMjBwYXNzJTIwJTYwbnVtX2xhYmVscyUzRG51bV9sYWJlbHMlNjAlMjB0byUyMCU2MC5mcm9tX3ByZXRyYWluZWQoLi4uKSU2MCUwQW51bV9sYWJlbHMlMjAlM0QlMjBsZW4obW9kZWwuY29uZmlnLmlkMmxhYmVsKSUwQW1vZGVsJTIwJTNEJTIwVEZEaXN0aWxCZXJ0Rm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIlMkMlMjBudW1fbGFiZWxzJTNEbnVtX2xhYmVscyklMEElMEFsYWJlbHMlMjAlM0QlMjB0Zi5jb25zdGFudCgxKSUwQWxvc3MlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscykubG9zcw==",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on `num_labels` classes, you can pass `num_labels=num_labels` to `.from_pretrained(...)`</span>\n<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)\n<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFDistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert-base-uncased&quot;</span>, num_labels=num_labels)\n\n<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tf.constant(<span class="hljs-number">1</span>)\n<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss'}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){k(d,f,m),v=!0},p:We,i(f){v||(M(d.$$.fragment,f),v=!0)},o(f){$(d.$$.fragment,f),v=!1},d(f){E(d,f)}}}function PC(B){let d,v,f,m,b,i,u,j,ke,ye,W,ie,K,F,Me,q,de,ze,S,ce,pe,Y,we,se,Z,fe,re,L,me,$e,te,C,U,ae,Q,Ee,le,O,Fe,ge,I,Be,P,he,je,V,ue,_e,N,Te,X,De,oe,J,be,z,xe,ve;return{c(){d=n("p"),v=o("TensorFlow models and layers in "),f=n("code"),m=o("transformers"),b=o(" accept two formats as input:"),i=p(),u=n("ul"),j=n("li"),ke=o("having all inputs as keyword arguments (like PyTorch models), or"),ye=p(),W=n("li"),ie=o("having all inputs as a list, tuple or dict in the first positional argument."),K=p(),F=n("p"),Me=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=n("code"),de=o("model.fit()"),ze=o(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=n("code"),ce=o("model.fit()"),pe=o(` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=n("code"),we=o("fit()"),se=o(" and "),Z=n("code"),fe=o("predict()"),re=o(`, such as when creating your own layers or models with
the Keras `),L=n("code"),me=o("Functional"),$e=o(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),te=p(),C=n("ul"),U=n("li"),ae=o("a single Tensor with "),Q=n("code"),Ee=o("input_ids"),le=o(" only and nothing else: "),O=n("code"),Fe=o("model(input_ids)"),ge=p(),I=n("li"),Be=o(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=n("code"),he=o("model([input_ids, attention_mask])"),je=o(" or "),V=n("code"),ue=o("model([input_ids, attention_mask, token_type_ids])"),_e=p(),N=n("li"),Te=o(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=n("code"),De=o('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),oe=p(),J=n("p"),be=o(`Note that when creating models and layers with
`),z=n("a"),xe=o("subclassing"),ve=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(y){d=r(y,"P",{});var D=a(d);v=s(D,"TensorFlow models and layers in "),f=r(D,"CODE",{});var qe=a(f);m=s(qe,"transformers"),qe.forEach(t),b=s(D," accept two formats as input:"),D.forEach(t),i=h(y),u=r(y,"UL",{});var ne=a(u);j=r(ne,"LI",{});var Se=a(j);ke=s(Se,"having all inputs as keyword arguments (like PyTorch models), or"),Se.forEach(t),ye=h(ne),W=r(ne,"LI",{});var Xe=a(W);ie=s(Xe,"having all inputs as a list, tuple or dict in the first positional argument."),Xe.forEach(t),ne.forEach(t),K=h(y),F=r(y,"P",{});var x=a(F);Me=s(x,`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(x,"CODE",{});var Le=a(q);de=s(Le,"model.fit()"),Le.forEach(t),ze=s(x,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(x,"CODE",{});var Qe=a(S);ce=s(Qe,"model.fit()"),Qe.forEach(t),pe=s(x,` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=r(x,"CODE",{});var Pe=a(Y);we=s(Pe,"fit()"),Pe.forEach(t),se=s(x," and "),Z=r(x,"CODE",{});var Ne=a(Z);fe=s(Ne,"predict()"),Ne.forEach(t),re=s(x,`, such as when creating your own layers or models with
the Keras `),L=r(x,"CODE",{});var Oe=a(L);me=s(Oe,"Functional"),Oe.forEach(t),$e=s(x,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),x.forEach(t),te=h(y),C=r(y,"UL",{});var A=a(C);U=r(A,"LI",{});var H=a(U);ae=s(H,"a single Tensor with "),Q=r(H,"CODE",{});var He=a(Q);Ee=s(He,"input_ids"),He.forEach(t),le=s(H," only and nothing else: "),O=r(H,"CODE",{});var Ye=a(O);Fe=s(Ye,"model(input_ids)"),Ye.forEach(t),H.forEach(t),ge=h(A),I=r(A,"LI",{});var G=a(I);Be=s(G,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=r(G,"CODE",{});var Ve=a(P);he=s(Ve,"model([input_ids, attention_mask])"),Ve.forEach(t),je=s(G," or "),V=r(G,"CODE",{});var Ke=a(V);ue=s(Ke,"model([input_ids, attention_mask, token_type_ids])"),Ke.forEach(t),G.forEach(t),_e=h(A),N=r(A,"LI",{});var Ce=a(N);Te=s(Ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=r(Ce,"CODE",{});var Je=a(X);De=s(Je,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Je.forEach(t),Ce.forEach(t),A.forEach(t),oe=h(y),J=r(y,"P",{});var ee=a(J);be=s(ee,`Note that when creating models and layers with
`),z=r(ee,"A",{href:!0,rel:!0});var et=a(z);xe=s(et,"subclassing"),et.forEach(t),ve=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){c(z,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),c(z,"rel","nofollow")},m(y,D){g(y,d,D),e(d,v),e(d,f),e(f,m),e(d,b),g(y,i,D),g(y,u,D),e(u,j),e(j,ke),e(u,ye),e(u,W),e(W,ie),g(y,K,D),g(y,F,D),e(F,Me),e(F,q),e(q,de),e(F,ze),e(F,S),e(S,ce),e(F,pe),e(F,Y),e(Y,we),e(F,se),e(F,Z),e(Z,fe),e(F,re),e(F,L),e(L,me),e(F,$e),g(y,te,D),g(y,C,D),e(C,U),e(U,ae),e(U,Q),e(Q,Ee),e(U,le),e(U,O),e(O,Fe),e(C,ge),e(C,I),e(I,Be),e(I,P),e(P,he),e(I,je),e(I,V),e(V,ue),e(C,_e),e(C,N),e(N,Te),e(N,X),e(X,De),g(y,oe,D),g(y,J,D),e(J,be),e(J,z),e(z,xe),e(J,ve)},d(y){y&&t(d),y&&t(i),y&&t(u),y&&t(K),y&&t(F),y&&t(te),y&&t(C),y&&t(oe),y&&t(J)}}}function VC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function SC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURkRpc3RpbEJlcnRGb3JNdWx0aXBsZUNob2ljZSUwQWltcG9ydCUyMHRlbnNvcmZsb3clMjBhcyUyMHRmJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBURkRpc3RpbEJlcnRGb3JNdWx0aXBsZUNob2ljZS5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBcHJvbXB0JTIwJTNEJTIwJTIySW4lMjBJdGFseSUyQyUyMHBpenphJTIwc2VydmVkJTIwaW4lMjBmb3JtYWwlMjBzZXR0aW5ncyUyQyUyMHN1Y2glMjBhcyUyMGF0JTIwYSUyMHJlc3RhdXJhbnQlMkMlMjBpcyUyMHByZXNlbnRlZCUyMHVuc2xpY2VkLiUyMiUwQWNob2ljZTAlMjAlM0QlMjAlMjJJdCUyMGlzJTIwZWF0ZW4lMjB3aXRoJTIwYSUyMGZvcmslMjBhbmQlMjBhJTIwa25pZmUuJTIyJTBBY2hvaWNlMSUyMCUzRCUyMCUyMkl0JTIwaXMlMjBlYXRlbiUyMHdoaWxlJTIwaGVsZCUyMGluJTIwdGhlJTIwaGFuZC4lMjIlMEElMEFlbmNvZGluZyUyMCUzRCUyMHRva2VuaXplciglNUJwcm9tcHQlMkMlMjBwcm9tcHQlNUQlMkMlMjAlNUJjaG9pY2UwJTJDJTIwY2hvaWNlMSU1RCUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIydGYlMjIlMkMlMjBwYWRkaW5nJTNEVHJ1ZSklMEFpbnB1dHMlMjAlM0QlMjAlN0JrJTNBJTIwdGYuZXhwYW5kX2RpbXModiUyQyUyMDApJTIwZm9yJTIwayUyQyUyMHYlMjBpbiUyMGVuY29kaW5nLml0ZW1zKCklN0QlMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoaW5wdXRzKSUyMCUyMCUyMyUyMGJhdGNoJTIwc2l6ZSUyMGlzJTIwMSUwQSUwQSUyMyUyMHRoZSUyMGxpbmVhciUyMGNsYXNzaWZpZXIlMjBzdGlsbCUyMG5lZWRzJTIwdG8lMjBiZSUyMHRyYWluZWQlMEFsb2dpdHMlMjAlM0QlMjBvdXRwdXRzLmxvZ2l0cw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function LC(B){let d,v,f,m,b,i,u,j,ke,ye,W,ie,K,F,Me,q,de,ze,S,ce,pe,Y,we,se,Z,fe,re,L,me,$e,te,C,U,ae,Q,Ee,le,O,Fe,ge,I,Be,P,he,je,V,ue,_e,N,Te,X,De,oe,J,be,z,xe,ve;return{c(){d=n("p"),v=o("TensorFlow models and layers in "),f=n("code"),m=o("transformers"),b=o(" accept two formats as input:"),i=p(),u=n("ul"),j=n("li"),ke=o("having all inputs as keyword arguments (like PyTorch models), or"),ye=p(),W=n("li"),ie=o("having all inputs as a list, tuple or dict in the first positional argument."),K=p(),F=n("p"),Me=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=n("code"),de=o("model.fit()"),ze=o(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=n("code"),ce=o("model.fit()"),pe=o(` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=n("code"),we=o("fit()"),se=o(" and "),Z=n("code"),fe=o("predict()"),re=o(`, such as when creating your own layers or models with
the Keras `),L=n("code"),me=o("Functional"),$e=o(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),te=p(),C=n("ul"),U=n("li"),ae=o("a single Tensor with "),Q=n("code"),Ee=o("input_ids"),le=o(" only and nothing else: "),O=n("code"),Fe=o("model(input_ids)"),ge=p(),I=n("li"),Be=o(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=n("code"),he=o("model([input_ids, attention_mask])"),je=o(" or "),V=n("code"),ue=o("model([input_ids, attention_mask, token_type_ids])"),_e=p(),N=n("li"),Te=o(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=n("code"),De=o('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),oe=p(),J=n("p"),be=o(`Note that when creating models and layers with
`),z=n("a"),xe=o("subclassing"),ve=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(y){d=r(y,"P",{});var D=a(d);v=s(D,"TensorFlow models and layers in "),f=r(D,"CODE",{});var qe=a(f);m=s(qe,"transformers"),qe.forEach(t),b=s(D," accept two formats as input:"),D.forEach(t),i=h(y),u=r(y,"UL",{});var ne=a(u);j=r(ne,"LI",{});var Se=a(j);ke=s(Se,"having all inputs as keyword arguments (like PyTorch models), or"),Se.forEach(t),ye=h(ne),W=r(ne,"LI",{});var Xe=a(W);ie=s(Xe,"having all inputs as a list, tuple or dict in the first positional argument."),Xe.forEach(t),ne.forEach(t),K=h(y),F=r(y,"P",{});var x=a(F);Me=s(x,`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(x,"CODE",{});var Le=a(q);de=s(Le,"model.fit()"),Le.forEach(t),ze=s(x,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(x,"CODE",{});var Qe=a(S);ce=s(Qe,"model.fit()"),Qe.forEach(t),pe=s(x,` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=r(x,"CODE",{});var Pe=a(Y);we=s(Pe,"fit()"),Pe.forEach(t),se=s(x," and "),Z=r(x,"CODE",{});var Ne=a(Z);fe=s(Ne,"predict()"),Ne.forEach(t),re=s(x,`, such as when creating your own layers or models with
the Keras `),L=r(x,"CODE",{});var Oe=a(L);me=s(Oe,"Functional"),Oe.forEach(t),$e=s(x,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),x.forEach(t),te=h(y),C=r(y,"UL",{});var A=a(C);U=r(A,"LI",{});var H=a(U);ae=s(H,"a single Tensor with "),Q=r(H,"CODE",{});var He=a(Q);Ee=s(He,"input_ids"),He.forEach(t),le=s(H," only and nothing else: "),O=r(H,"CODE",{});var Ye=a(O);Fe=s(Ye,"model(input_ids)"),Ye.forEach(t),H.forEach(t),ge=h(A),I=r(A,"LI",{});var G=a(I);Be=s(G,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=r(G,"CODE",{});var Ve=a(P);he=s(Ve,"model([input_ids, attention_mask])"),Ve.forEach(t),je=s(G," or "),V=r(G,"CODE",{});var Ke=a(V);ue=s(Ke,"model([input_ids, attention_mask, token_type_ids])"),Ke.forEach(t),G.forEach(t),_e=h(A),N=r(A,"LI",{});var Ce=a(N);Te=s(Ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=r(Ce,"CODE",{});var Je=a(X);De=s(Je,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Je.forEach(t),Ce.forEach(t),A.forEach(t),oe=h(y),J=r(y,"P",{});var ee=a(J);be=s(ee,`Note that when creating models and layers with
`),z=r(ee,"A",{href:!0,rel:!0});var et=a(z);xe=s(et,"subclassing"),et.forEach(t),ve=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){c(z,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),c(z,"rel","nofollow")},m(y,D){g(y,d,D),e(d,v),e(d,f),e(f,m),e(d,b),g(y,i,D),g(y,u,D),e(u,j),e(j,ke),e(u,ye),e(u,W),e(W,ie),g(y,K,D),g(y,F,D),e(F,Me),e(F,q),e(q,de),e(F,ze),e(F,S),e(S,ce),e(F,pe),e(F,Y),e(Y,we),e(F,se),e(F,Z),e(Z,fe),e(F,re),e(F,L),e(L,me),e(F,$e),g(y,te,D),g(y,C,D),e(C,U),e(U,ae),e(U,Q),e(Q,Ee),e(U,le),e(U,O),e(O,Fe),e(C,ge),e(C,I),e(I,Be),e(I,P),e(P,he),e(I,je),e(I,V),e(V,ue),e(C,_e),e(C,N),e(N,Te),e(N,X),e(X,De),g(y,oe,D),g(y,J,D),e(J,be),e(J,z),e(z,xe),e(J,ve)},d(y){y&&t(d),y&&t(i),y&&t(u),y&&t(K),y&&t(F),y&&t(te),y&&t(C),y&&t(oe),y&&t(J)}}}function QC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function OC(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURkRpc3RpbEJlcnRGb3JUb2tlbkNsYXNzaWZpY2F0aW9uJTBBaW1wb3J0JTIwdGVuc29yZmxvdyUyMGFzJTIwdGYlMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEFtb2RlbCUyMCUzRCUyMFRGRGlzdGlsQmVydEZvclRva2VuQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMmRpc3RpbGJlcnQtYmFzZS11bmNhc2VkJTIyKSUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplciglMEElMjAlMjAlMjAlMjAlMjJIdWdnaW5nRmFjZSUyMGlzJTIwYSUyMGNvbXBhbnklMjBiYXNlZCUyMGluJTIwUGFyaXMlMjBhbmQlMjBOZXclMjBZb3JrJTIyJTJDJTIwYWRkX3NwZWNpYWxfdG9rZW5zJTNERmFsc2UlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnRmJTIyJTBBKSUwQSUwQWxvZ2l0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKS5sb2dpdHMlMEFwcmVkaWN0ZWRfdG9rZW5fY2xhc3NfaWRzJTIwJTNEJTIwdGYubWF0aC5hcmdtYXgobG9naXRzJTJDJTIwYXhpcyUzRC0xKSUwQSUwQSUyMyUyME5vdGUlMjB0aGF0JTIwdG9rZW5zJTIwYXJlJTIwY2xhc3NpZmllZCUyMHJhdGhlciUyMHRoZW4lMjBpbnB1dCUyMHdvcmRzJTIwd2hpY2glMjBtZWFucyUyMHRoYXQlMEElMjMlMjB0aGVyZSUyMG1pZ2h0JTIwYmUlMjBtb3JlJTIwcHJlZGljdGVkJTIwdG9rZW4lMjBjbGFzc2VzJTIwdGhhbiUyMHdvcmRzLiUwQSUyMyUyME11bHRpcGxlJTIwdG9rZW4lMjBjbGFzc2VzJTIwbWlnaHQlMjBhY2NvdW50JTIwZm9yJTIwdGhlJTIwc2FtZSUyMHdvcmQlMEFwcmVkaWN0ZWRfdG9rZW5zX2NsYXNzZXMlMjAlM0QlMjAlNUJtb2RlbC5jb25maWcuaWQybGFiZWwlNUJ0JTVEJTIwZm9yJTIwdCUyMGluJTIwcHJlZGljdGVkX3Rva2VuX2NsYXNzX2lkcyU1QjAlNUQubnVtcHkoKS50b2xpc3QoKSU1RA==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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()]`}}),{c(){d=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function HC(B){let d,v;return d=new Ae({props:{code:"bGFiZWxzJTIwJTNEJTIwcHJlZGljdGVkX3Rva2VuX2NsYXNzX2lkcyUwQWxvc3MlMjAlM0QlMjB0Zi5tYXRoLnJlZHVjZV9tZWFuKG1vZGVsKCoqaW5wdXRzJTJDJTIwbGFiZWxzJTNEbGFiZWxzKS5sb3NzKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(model(**inputs, labels=labels).loss)`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){k(d,f,m),v=!0},p:We,i(f){v||(M(d.$$.fragment,f),v=!0)},o(f){$(d.$$.fragment,f),v=!1},d(f){E(d,f)}}}function YC(B){let d,v,f,m,b,i,u,j,ke,ye,W,ie,K,F,Me,q,de,ze,S,ce,pe,Y,we,se,Z,fe,re,L,me,$e,te,C,U,ae,Q,Ee,le,O,Fe,ge,I,Be,P,he,je,V,ue,_e,N,Te,X,De,oe,J,be,z,xe,ve;return{c(){d=n("p"),v=o("TensorFlow models and layers in "),f=n("code"),m=o("transformers"),b=o(" accept two formats as input:"),i=p(),u=n("ul"),j=n("li"),ke=o("having all inputs as keyword arguments (like PyTorch models), or"),ye=p(),W=n("li"),ie=o("having all inputs as a list, tuple or dict in the first positional argument."),K=p(),F=n("p"),Me=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=n("code"),de=o("model.fit()"),ze=o(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=n("code"),ce=o("model.fit()"),pe=o(` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=n("code"),we=o("fit()"),se=o(" and "),Z=n("code"),fe=o("predict()"),re=o(`, such as when creating your own layers or models with
the Keras `),L=n("code"),me=o("Functional"),$e=o(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),te=p(),C=n("ul"),U=n("li"),ae=o("a single Tensor with "),Q=n("code"),Ee=o("input_ids"),le=o(" only and nothing else: "),O=n("code"),Fe=o("model(input_ids)"),ge=p(),I=n("li"),Be=o(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=n("code"),he=o("model([input_ids, attention_mask])"),je=o(" or "),V=n("code"),ue=o("model([input_ids, attention_mask, token_type_ids])"),_e=p(),N=n("li"),Te=o(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=n("code"),De=o('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),oe=p(),J=n("p"),be=o(`Note that when creating models and layers with
`),z=n("a"),xe=o("subclassing"),ve=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(y){d=r(y,"P",{});var D=a(d);v=s(D,"TensorFlow models and layers in "),f=r(D,"CODE",{});var qe=a(f);m=s(qe,"transformers"),qe.forEach(t),b=s(D," accept two formats as input:"),D.forEach(t),i=h(y),u=r(y,"UL",{});var ne=a(u);j=r(ne,"LI",{});var Se=a(j);ke=s(Se,"having all inputs as keyword arguments (like PyTorch models), or"),Se.forEach(t),ye=h(ne),W=r(ne,"LI",{});var Xe=a(W);ie=s(Xe,"having all inputs as a list, tuple or dict in the first positional argument."),Xe.forEach(t),ne.forEach(t),K=h(y),F=r(y,"P",{});var x=a(F);Me=s(x,`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(x,"CODE",{});var Le=a(q);de=s(Le,"model.fit()"),Le.forEach(t),ze=s(x,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),S=r(x,"CODE",{});var Qe=a(S);ce=s(Qe,"model.fit()"),Qe.forEach(t),pe=s(x,` supports! If, however, you want to use the second
format outside of Keras methods like `),Y=r(x,"CODE",{});var Pe=a(Y);we=s(Pe,"fit()"),Pe.forEach(t),se=s(x," and "),Z=r(x,"CODE",{});var Ne=a(Z);fe=s(Ne,"predict()"),Ne.forEach(t),re=s(x,`, such as when creating your own layers or models with
the Keras `),L=r(x,"CODE",{});var Oe=a(L);me=s(Oe,"Functional"),Oe.forEach(t),$e=s(x,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),x.forEach(t),te=h(y),C=r(y,"UL",{});var A=a(C);U=r(A,"LI",{});var H=a(U);ae=s(H,"a single Tensor with "),Q=r(H,"CODE",{});var He=a(Q);Ee=s(He,"input_ids"),He.forEach(t),le=s(H," only and nothing else: "),O=r(H,"CODE",{});var Ye=a(O);Fe=s(Ye,"model(input_ids)"),Ye.forEach(t),H.forEach(t),ge=h(A),I=r(A,"LI",{});var G=a(I);Be=s(G,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),P=r(G,"CODE",{});var Ve=a(P);he=s(Ve,"model([input_ids, attention_mask])"),Ve.forEach(t),je=s(G," or "),V=r(G,"CODE",{});var Ke=a(V);ue=s(Ke,"model([input_ids, attention_mask, token_type_ids])"),Ke.forEach(t),G.forEach(t),_e=h(A),N=r(A,"LI",{});var Ce=a(N);Te=s(Ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),X=r(Ce,"CODE",{});var Je=a(X);De=s(Je,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Je.forEach(t),Ce.forEach(t),A.forEach(t),oe=h(y),J=r(y,"P",{});var ee=a(J);be=s(ee,`Note that when creating models and layers with
`),z=r(ee,"A",{href:!0,rel:!0});var et=a(z);xe=s(et,"subclassing"),et.forEach(t),ve=s(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){c(z,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),c(z,"rel","nofollow")},m(y,D){g(y,d,D),e(d,v),e(d,f),e(f,m),e(d,b),g(y,i,D),g(y,u,D),e(u,j),e(j,ke),e(u,ye),e(u,W),e(W,ie),g(y,K,D),g(y,F,D),e(F,Me),e(F,q),e(q,de),e(F,ze),e(F,S),e(S,ce),e(F,pe),e(F,Y),e(Y,we),e(F,se),e(F,Z),e(Z,fe),e(F,re),e(F,L),e(L,me),e(F,$e),g(y,te,D),g(y,C,D),e(C,U),e(U,ae),e(U,Q),e(Q,Ee),e(U,le),e(U,O),e(O,Fe),e(C,ge),e(C,I),e(I,Be),e(I,P),e(P,he),e(I,je),e(I,V),e(V,ue),e(C,_e),e(C,N),e(N,Te),e(N,X),e(X,De),g(y,oe,D),g(y,J,D),e(J,be),e(J,z),e(z,xe),e(J,ve)},d(y){y&&t(d),y&&t(i),y&&t(u),y&&t(K),y&&t(F),y&&t(te),y&&t(C),y&&t(oe),y&&t(J)}}}function KC(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function eJ(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURkRpc3RpbEJlcnRGb3JRdWVzdGlvbkFuc3dlcmluZyUwQWltcG9ydCUyMHRlbnNvcmZsb3clMjBhcyUyMHRmJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBURkRpc3RpbEJlcnRGb3JRdWVzdGlvbkFuc3dlcmluZy5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBcXVlc3Rpb24lMkMlMjB0ZXh0JTIwJTNEJTIwJTIyV2hvJTIwd2FzJTIwSmltJTIwSGVuc29uJTNGJTIyJTJDJTIwJTIySmltJTIwSGVuc29uJTIwd2FzJTIwYSUyMG5pY2UlMjBwdXBwZXQlMjIlMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIocXVlc3Rpb24lMkMlMjB0ZXh0JTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJ0ZiUyMiklMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBJTBBYW5zd2VyX3N0YXJ0X2luZGV4JTIwJTNEJTIwaW50KHRmLm1hdGguYXJnbWF4KG91dHB1dHMuc3RhcnRfbG9naXRzJTJDJTIwYXhpcyUzRC0xKSU1QjAlNUQpJTBBYW5zd2VyX2VuZF9pbmRleCUyMCUzRCUyMGludCh0Zi5tYXRoLmFyZ21heChvdXRwdXRzLmVuZF9sb2dpdHMlMkMlMjBheGlzJTNELTEpJTVCMCU1RCklMEElMEFwcmVkaWN0X2Fuc3dlcl90b2tlbnMlMjAlM0QlMjBpbnB1dHMuaW5wdXRfaWRzJTVCMCUyQyUyMGFuc3dlcl9zdGFydF9pbmRleCUyMCUzQSUyMGFuc3dlcl9lbmRfaW5kZXglMjAlMkIlMjAxJTVE",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, 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 = AutoTokenizer.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>]`}}),{c(){d=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function tJ(B){let d,v;return d=new Ae({props:{code:"JTIzJTIwdGFyZ2V0JTIwaXMlMjAlMjJuaWNlJTIwcHVwcGV0JTIyJTBBdGFyZ2V0X3N0YXJ0X2luZGV4JTIwJTNEJTIwdGYuY29uc3RhbnQoJTVCMTQlNUQpJTBBdGFyZ2V0X2VuZF9pbmRleCUyMCUzRCUyMHRmLmNvbnN0YW50KCU1QjE1JTVEKSUwQSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMHN0YXJ0X3Bvc2l0aW9ucyUzRHRhcmdldF9zdGFydF9pbmRleCUyQyUyMGVuZF9wb3NpdGlvbnMlM0R0YXJnZXRfZW5kX2luZGV4KSUwQWxvc3MlMjAlM0QlMjB0Zi5tYXRoLnJlZHVjZV9tZWFuKG91dHB1dHMubG9zcyk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># target is &quot;nice puppet&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>target_start_index = tf.constant([<span class="hljs-number">14</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>target_end_index = tf.constant([<span class="hljs-number">15</span>])

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(outputs.loss)`}}),{c(){w(d.$$.fragment)},l(f){T(d.$$.fragment,f)},m(f,m){k(d,f,m),v=!0},p:We,i(f){v||(M(d.$$.fragment,f),v=!0)},o(f){$(d.$$.fragment,f),v=!1},d(f){E(d,f)}}}function oJ(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function sJ(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4RGlzdGlsQmVydE1vZGVsJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBGbGF4RGlzdGlsQmVydE1vZGVsLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIoJTIySGVsbG8lMkMlMjBteSUyMGRvZyUyMGlzJTIwY3V0ZSUyMiUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIyamF4JTIyKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyklMEElMEFsYXN0X2hpZGRlbl9zdGF0ZXMlMjAlM0QlMjBvdXRwdXRzLmxhc3RfaGlkZGVuX3N0YXRl",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxDistilBertModel

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function nJ(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function rJ(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4RGlzdGlsQmVydEZvck1hc2tlZExNJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBGbGF4RGlzdGlsQmVydEZvck1hc2tlZExNLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIoJTIyVGhlJTIwY2FwaXRhbCUyMG9mJTIwRnJhbmNlJTIwaXMlMjAlNUJNQVNLJTVELiUyMiUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIyamF4JTIyKSUwQSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyklMEFsb2dpdHMlMjAlM0QlMjBvdXRwdXRzLmxvZ2l0cw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxDistilBertForMaskedLM

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function aJ(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function lJ(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4RGlzdGlsQmVydEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24lMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhEaXN0aWxCZXJ0Rm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMmpheCUyMiklMEElMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5sb2dpdHM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxDistilBertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function iJ(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function dJ(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4RGlzdGlsQmVydEZvck11bHRpcGxlQ2hvaWNlJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBGbGF4RGlzdGlsQmVydEZvck11bHRpcGxlQ2hvaWNlLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEElMEFwcm9tcHQlMjAlM0QlMjAlMjJJbiUyMEl0YWx5JTJDJTIwcGl6emElMjBzZXJ2ZWQlMjBpbiUyMGZvcm1hbCUyMHNldHRpbmdzJTJDJTIwc3VjaCUyMGFzJTIwYXQlMjBhJTIwcmVzdGF1cmFudCUyQyUyMGlzJTIwcHJlc2VudGVkJTIwdW5zbGljZWQuJTIyJTBBY2hvaWNlMCUyMCUzRCUyMCUyMkl0JTIwaXMlMjBlYXRlbiUyMHdpdGglMjBhJTIwZm9yayUyMGFuZCUyMGElMjBrbmlmZS4lMjIlMEFjaG9pY2UxJTIwJTNEJTIwJTIySXQlMjBpcyUyMGVhdGVuJTIwd2hpbGUlMjBoZWxkJTIwaW4lMjB0aGUlMjBoYW5kLiUyMiUwQSUwQWVuY29kaW5nJTIwJTNEJTIwdG9rZW5pemVyKCU1QnByb21wdCUyQyUyMHByb21wdCU1RCUyQyUyMCU1QmNob2ljZTAlMkMlMjBjaG9pY2UxJTVEJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJqYXglMjIlMkMlMjBwYWRkaW5nJTNEVHJ1ZSklMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKiolN0JrJTNBJTIwdiU1Qk5vbmUlMkMlMjAlM0ElNUQlMjBmb3IlMjBrJTJDJTIwdiUyMGluJTIwZW5jb2RpbmcuaXRlbXMoKSU3RCklMEElMEFsb2dpdHMlMjAlM0QlMjBvdXRwdXRzLmxvZ2l0cw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxDistilBertForMultipleChoice

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function cJ(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function pJ(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4RGlzdGlsQmVydEZvclRva2VuQ2xhc3NpZmljYXRpb24lMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhEaXN0aWxCZXJ0Rm9yVG9rZW5DbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMmpheCUyMiklMEElMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5sb2dpdHM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxDistilBertForTokenClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function hJ(B){let d,v,f,m,b;return{c(){d=n("p"),v=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=o("Module"),b=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(i){d=r(i,"P",{});var u=a(d);v=s(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=r(u,"CODE",{});var j=a(f);m=s(j,"Module"),j.forEach(t),b=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(i,u){g(i,d,u),e(d,v),e(d,f),e(f,m),e(d,b)},d(i){i&&t(d)}}}function uJ(B){let d,v,f,m,b;return m=new Ae({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4RGlzdGlsQmVydEZvclF1ZXN0aW9uQW5zd2VyaW5nJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIpJTBBbW9kZWwlMjAlM0QlMjBGbGF4RGlzdGlsQmVydEZvclF1ZXN0aW9uQW5zd2VyaW5nLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiklMEElMEFxdWVzdGlvbiUyQyUyMHRleHQlMjAlM0QlMjAlMjJXaG8lMjB3YXMlMjBKaW0lMjBIZW5zb24lM0YlMjIlMkMlMjAlMjJKaW0lMjBIZW5zb24lMjB3YXMlMjBhJTIwbmljZSUyMHB1cHBldCUyMiUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplcihxdWVzdGlvbiUyQyUyMHRleHQlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMmpheCUyMiklMEElMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBc3RhcnRfc2NvcmVzJTIwJTNEJTIwb3V0cHV0cy5zdGFydF9sb2dpdHMlMEFlbmRfc2NvcmVzJTIwJTNEJTIwb3V0cHV0cy5lbmRfbG9naXRz",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxDistilBertForQuestionAnswering

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.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=n("p"),v=o("Example:"),f=p(),w(m.$$.fragment)},l(i){d=r(i,"P",{});var u=a(d);v=s(u,"Example:"),u.forEach(t),f=h(i),T(m.$$.fragment,i)},m(i,u){g(i,d,u),e(d,v),g(i,f,u),k(m,i,u),b=!0},p:We,i(i){b||(M(m.$$.fragment,i),b=!0)},o(i){$(m.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(f),E(m,i)}}}function fJ(B){let d,v,f,m,b,i,u,j,ke,ye,W,ie,K,F,Me,q,de,ze,S,ce,pe,Y,we,se,Z,fe,re,L,me,$e,te,C,U,ae,Q,Ee,le,O,Fe,ge,I,Be,P,he,je,V,ue,_e,N,Te,X,De,oe,J,be,z,xe,ve,y,D,qe,ne,Se,Xe,x,Le,Qe,Pe,Ne,Oe,A,H,He,Ye,G,Ve,Ke,Ce,Je,ee,et,O_,Qp,H_,Y_,Op,K_,fm,Wt,eb,Ir,tb,ob,Wr,sb,nb,Ar,rb,ab,mm,Lo,qs,Hp,Nr,lb,Yp,ib,gm,lc,db,_m,Rr,bm,Ue,Zr,cb,Gr,pb,hb,ub,qr,fb,Xr,mb,gb,_b,Pr,bb,Vr,vb,yb,wb,Sr,Tb,Lr,kb,Mb,$b,Qr,Eb,Or,Fb,Bb,jb,Hr,Db,Yr,xb,Cb,Jb,Kr,zb,ea,Ub,Ib,Wb,go,ic,Ab,Nb,ta,Rb,Zb,oa,Gb,qb,Xb,_o,dc,Pb,Vb,sa,Sb,Lb,na,Qb,Ob,Hb,bo,cc,Yb,Kb,ra,ev,tv,aa,ov,sv,nv,Kp,pc,rv,vm,la,ym,wt,vo,hc,av,lv,ia,iv,dv,da,cv,pv,hv,yo,uc,uv,fv,ca,mv,gv,pa,_v,bv,vv,Xs,fc,yv,wv,ha,Tv,kv,Mv,mc,ua,$v,Ev,Fv,eh,gc,Bv,wm,fa,Tm,Tt,wo,_c,jv,Dv,ma,xv,Cv,ga,Jv,zv,Uv,To,bc,Iv,Wv,_a,Av,Nv,ba,Rv,Zv,Gv,ko,vc,qv,Xv,va,Pv,Vv,ya,Sv,Lv,Qv,yc,wa,Ov,Hv,Yv,th,wc,Kv,km,Ta,Mm,kt,Mo,Tc,ey,ty,ka,oy,sy,Ma,ny,ry,ay,$o,kc,ly,iy,$a,dy,cy,Ea,py,hy,uy,Ps,Mc,fy,my,Fa,gy,_y,by,$c,Ba,vy,yy,wy,oh,Ec,Ty,$m,Fc,sh,ky,Em,Eo,Fo,Bc,My,$y,ja,Ey,Fy,Da,By,jy,Dy,Bo,jc,xy,Cy,xa,Jy,zy,Ca,Uy,Iy,Wy,nh,Dc,Ay,Fm,xc,Ny,Bm,jo,Ja,Ry,za,Zy,Gy,qy,Ua,Xy,Ia,Py,Vy,Sy,Wa,Ly,Aa,Qy,Oy,jm,Cc,Hy,Dm,Vs,Na,Yy,Ra,Ky,ew,tw,Za,ow,Ga,sw,nw,xm,Jc,rw,Cm,Do,qa,aw,Xa,lw,iw,dw,Pa,cw,Va,pw,hw,uw,Sa,fw,La,mw,gw,Jm,Qo,Ss,rh,Qa,_w,ah,bw,zm,It,Oa,vw,ro,yw,zc,ww,Tw,Uc,kw,Mw,Ha,$w,Ew,Fw,Oo,Bw,Ic,jw,Dw,Wc,xw,Cw,Jw,Ls,Um,Ho,Qs,lh,Ya,zw,ih,Uw,Im,tt,Ka,Iw,dh,Ww,Aw,el,Nw,Ac,Rw,Zw,Gw,xo,tl,qw,ch,Xw,Pw,ol,Nc,Vw,ph,Sw,Lw,Rc,Qw,hh,Ow,Hw,Os,sl,Yw,uh,Kw,eT,At,nl,tT,fh,oT,sT,Hs,nT,Yo,rT,mh,aT,lT,gh,iT,dT,cT,Ys,rl,pT,al,hT,_h,uT,fT,Wm,Ko,Ks,bh,ll,mT,vh,gT,Am,ft,il,_T,dl,bT,yh,vT,yT,wT,cl,TT,Zc,kT,MT,$T,Co,pl,ET,wh,FT,BT,hl,Gc,jT,Th,DT,xT,qc,CT,kh,JT,zT,Nt,ul,UT,Mh,IT,WT,en,AT,es,NT,$h,RT,ZT,Eh,GT,qT,Nm,ts,tn,Fh,fl,XT,Bh,PT,Rm,mt,ml,VT,jh,ST,LT,gl,QT,Xc,OT,HT,YT,_l,KT,bl,ek,tk,ok,Rt,vl,sk,os,nk,Pc,rk,ak,Dh,lk,ik,dk,on,ck,sn,Zm,ss,nn,xh,yl,pk,Ch,hk,Gm,gt,wl,uk,Tl,fk,Jh,mk,gk,_k,kl,bk,Vc,vk,yk,wk,Ml,Tk,$l,kk,Mk,$k,Zt,El,Ek,ns,Fk,Sc,Bk,jk,zh,Dk,xk,Ck,rn,Jk,an,qm,rs,ln,Uh,Fl,zk,Ih,Uk,Xm,_t,Bl,Ik,Wh,Wk,Ak,jl,Nk,Lc,Rk,Zk,Gk,Dl,qk,xl,Xk,Pk,Vk,Mt,Cl,Sk,as,Lk,Qc,Qk,Ok,Ah,Hk,Yk,Kk,dn,eM,cn,tM,pn,Pm,ls,hn,Nh,Jl,oM,Rh,sM,Vm,bt,zl,nM,Zh,rM,aM,Ul,lM,Oc,iM,dM,cM,Il,pM,Wl,hM,uM,fM,Gt,Al,mM,is,gM,Hc,_M,bM,Gh,vM,yM,wM,un,TM,fn,Sm,ds,mn,qh,Nl,kM,Xh,MM,Lm,vt,Rl,$M,Ph,EM,FM,Zl,BM,Yc,jM,DM,xM,Gl,CM,ql,JM,zM,UM,qt,Xl,IM,cs,WM,Kc,AM,NM,Vh,RM,ZM,GM,gn,qM,_n,Qm,ps,bn,Sh,Pl,XM,Lh,PM,Om,yt,Vl,VM,hs,SM,Qh,LM,QM,Oh,OM,HM,YM,Sl,KM,ep,e2,t2,o2,Ll,s2,Ql,n2,r2,a2,Xt,Ol,l2,us,i2,tp,d2,c2,Hh,p2,h2,u2,vn,f2,yn,Hm,fs,wn,Yh,Hl,m2,Kh,g2,Ym,it,Yl,_2,eu,b2,v2,Kl,y2,op,w2,T2,k2,ei,M2,ti,$2,E2,F2,Tn,B2,Pt,oi,j2,ms,D2,sp,x2,C2,tu,J2,z2,U2,kn,I2,Mn,Km,gs,$n,ou,si,W2,su,A2,eg,dt,ni,N2,ri,R2,nu,Z2,G2,q2,ai,X2,np,P2,V2,S2,li,L2,ii,Q2,O2,H2,En,Y2,$t,di,K2,_s,e1,rp,t1,o1,ru,s1,n1,r1,Fn,a1,Bn,l1,jn,tg,bs,Dn,au,ci,i1,lu,d1,og,ct,pi,c1,iu,p1,h1,hi,u1,ap,f1,m1,g1,ui,_1,fi,b1,v1,y1,xn,w1,Et,mi,T1,vs,k1,lp,M1,$1,du,E1,F1,B1,Cn,j1,Jn,D1,zn,sg,ys,Un,cu,gi,x1,pu,C1,ng,pt,_i,J1,hu,z1,U1,bi,I1,ip,W1,A1,N1,vi,R1,yi,Z1,G1,q1,In,X1,Vt,wi,P1,ws,V1,dp,S1,L1,uu,Q1,O1,H1,Wn,Y1,An,rg,Ts,Nn,fu,Ti,K1,mu,e0,ag,ht,ki,t0,gu,o0,s0,Mi,n0,cp,r0,a0,l0,$i,i0,Ei,d0,c0,p0,Rn,h0,Ft,Fi,u0,ks,f0,pp,m0,g0,_u,_0,b0,v0,Zn,y0,Gn,w0,qn,lg,Ms,Xn,bu,Bi,T0,vu,k0,ig,ut,ji,M0,$s,$0,yu,E0,F0,wu,B0,j0,D0,Di,x0,hp,C0,J0,z0,xi,U0,Ci,I0,W0,A0,Pn,N0,Bt,Ji,R0,Es,Z0,up,G0,q0,Tu,X0,P0,V0,Vn,S0,Sn,L0,Ln,dg,Fs,Qn,ku,zi,Q0,Mu,O0,cg,ot,Ui,H0,$u,Y0,K0,Ii,e$,fp,t$,o$,s$,Wi,n$,Ai,r$,a$,l$,Eu,i$,d$,ao,Fu,Ni,c$,p$,Bu,Ri,h$,u$,ju,Zi,f$,m$,Du,Gi,g$,_$,St,qi,b$,Bs,v$,xu,y$,w$,Cu,T$,k$,M$,On,$$,Hn,pg,js,Yn,Ju,Xi,E$,zu,F$,hg,st,Pi,B$,Vi,j$,Uu,D$,x$,C$,Si,J$,mp,z$,U$,I$,Li,W$,Qi,A$,N$,R$,Iu,Z$,G$,lo,Wu,Oi,q$,X$,Au,Hi,P$,V$,Nu,Yi,S$,L$,Ru,Ki,Q$,O$,Lt,ed,H$,Ds,Y$,Zu,K$,eE,Gu,tE,oE,sE,Kn,nE,er,ug,xs,tr,qu,td,rE,Xu,aE,fg,nt,od,lE,Pu,iE,dE,sd,cE,gp,pE,hE,uE,nd,fE,rd,mE,gE,_E,Vu,bE,vE,io,Su,ad,yE,wE,Lu,ld,TE,kE,Qu,id,ME,$E,Ou,dd,EE,FE,Qt,cd,BE,Cs,jE,Hu,DE,xE,Yu,CE,JE,zE,or,UE,sr,mg,Js,nr,Ku,pd,IE,ef,WE,gg,rt,hd,AE,tf,NE,RE,ud,ZE,_p,GE,qE,XE,fd,PE,md,VE,SE,LE,of,QE,OE,co,sf,gd,HE,YE,nf,_d,KE,eF,rf,bd,tF,oF,af,vd,sF,nF,Ot,yd,rF,zs,aF,lf,lF,iF,df,dF,cF,pF,rr,hF,ar,_g,Us,lr,cf,wd,uF,pf,fF,bg,at,Td,mF,hf,gF,_F,kd,bF,bp,vF,yF,wF,Md,TF,$d,kF,MF,$F,uf,EF,FF,po,ff,Ed,BF,jF,mf,Fd,DF,xF,gf,Bd,CF,JF,_f,jd,zF,UF,Ht,Dd,IF,Is,WF,bf,AF,NF,vf,RF,ZF,GF,ir,qF,dr,vg,Ws,cr,yf,xd,XF,wf,PF,yg,lt,Cd,VF,As,SF,Tf,LF,QF,kf,OF,HF,YF,Jd,KF,vp,eB,tB,oB,zd,sB,Ud,nB,rB,aB,Mf,lB,iB,ho,$f,Id,dB,cB,Ef,Wd,pB,hB,Ff,Ad,uB,fB,Bf,Nd,mB,gB,Yt,Rd,_B,Ns,bB,jf,vB,yB,Df,wB,TB,kB,pr,MB,hr,wg;return i=new Ge({}),re=new Ge({}),Nr=new Ge({}),Rr=new Q_({props:{pipeline:"text-classification"}}),la=new Q_({props:{pipeline:"token-classification"}}),fa=new Q_({props:{pipeline:"fill-mask"}}),Ta=new Q_({props:{pipeline:"question-answering"}}),Qa=new Ge({}),Oa=new R({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.32.0/en/model_doc/distilbert#transformers.DistilBertModel">DistilBertModel</a> or <a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/model_doc/distilbert#transformers.DistilBertForSequenceClassification">DistilBertForSequenceClassification</a>.`,name:"seq_classif_dropout"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/configuration_distilbert.py#L45"}}),Ls=new Ie({props:{anchor:"transformers.DistilBertConfig.example",$$slots:{default:[bC]},$$scope:{ctx:B}}}),Ya=new Ge({}),Ka=new R({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:""}],parametersDescription:[{anchor:"transformers.DistilBertTokenizer.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
File containing the vocabulary.`,name:"vocab_file"},{anchor:"transformers.DistilBertTokenizer.do_lower_case",description:`<strong>do_lower_case</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to lowercase the input when tokenizing.`,name:"do_lower_case"},{anchor:"transformers.DistilBertTokenizer.do_basic_tokenize",description:`<strong>do_basic_tokenize</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to do basic tokenization before WordPiece.`,name:"do_basic_tokenize"},{anchor:"transformers.DistilBertTokenizer.never_split",description:`<strong>never_split</strong> (<code>Iterable</code>, <em>optional</em>) &#x2014;
Collection of tokens which will never be split during tokenization. Only has an effect when
<code>do_basic_tokenize=True</code>`,name:"never_split"},{anchor:"transformers.DistilBertTokenizer.unk_token",description:`<strong>unk_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[UNK]&quot;</code>) &#x2014;
The unknown token. A token that is not in the vocabulary cannot be converted to an ID and is set to be this
token instead.`,name:"unk_token"},{anchor:"transformers.DistilBertTokenizer.sep_token",description:`<strong>sep_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
The separator token, which is used when building a sequence from multiple sequences, e.g. two sequences for
sequence classification or for a text and a question for question answering. It is also used as the last
token of a sequence built with special tokens.`,name:"sep_token"},{anchor:"transformers.DistilBertTokenizer.pad_token",description:`<strong>pad_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[PAD]&quot;</code>) &#x2014;
The token used for padding, for example when batching sequences of different lengths.`,name:"pad_token"},{anchor:"transformers.DistilBertTokenizer.cls_token",description:`<strong>cls_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
The classifier token which is used when doing sequence classification (classification of the whole sequence
instead of per-token classification). It is the first token of the sequence when built with special tokens.`,name:"cls_token"},{anchor:"transformers.DistilBertTokenizer.mask_token",description:`<strong>mask_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[MASK]&quot;</code>) &#x2014;
The token used for masking values. This is the token used when training this model with masked language
modeling. This is the token which the model will try to predict.`,name:"mask_token"},{anchor:"transformers.DistilBertTokenizer.tokenize_chinese_chars",description:`<strong>tokenize_chinese_chars</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to tokenize Chinese characters.</p>
<p>This should likely be deactivated for Japanese (see this
<a href="https://github.com/huggingface/transformers/issues/328" rel="nofollow">issue</a>).`,name:"tokenize_chinese_chars"},{anchor:"transformers.DistilBertTokenizer.strip_accents",description:`<strong>strip_accents</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to strip all accents. If this option is not specified, then it will be determined by the
value for <code>lowercase</code> (as in the original BERT).`,name:"strip_accents"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert.py#L89"}}),tl=new R({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.DistilBertTokenizer.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.DistilBertTokenizer.build_inputs_with_special_tokens.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs to which the special tokens will be added.`,name:"token_ids_0"},{anchor:"transformers.DistilBertTokenizer.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert.py#L230",returnDescription:`
<p>List of <a href="../glossary#input-ids">input IDs</a> with the appropriate special tokens.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),sl=new R({props:{name:"convert_tokens_to_string",anchor:"transformers.DistilBertTokenizer.convert_tokens_to_string",parameters:[{name:"tokens",val:""}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert.py#L224"}}),nl=new R({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.DistilBertTokenizer.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.DistilBertTokenizer.create_token_type_ids_from_sequences.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.DistilBertTokenizer.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert.py#L285",returnDescription:`
<p>List of <a href="../glossary#token-type-ids">token type IDs</a> according to the given sequence(s).</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),Hs=new Ie({props:{anchor:"transformers.DistilBertTokenizer.create_token_type_ids_from_sequences.example",$$slots:{default:[vC]},$$scope:{ctx:B}}}),rl=new R({props:{name:"get_special_tokens_mask",anchor:"transformers.DistilBertTokenizer.get_special_tokens_mask",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"},{name:"already_has_special_tokens",val:": bool = False"}],parametersDescription:[{anchor:"transformers.DistilBertTokenizer.get_special_tokens_mask.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.DistilBertTokenizer.get_special_tokens_mask.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"},{anchor:"transformers.DistilBertTokenizer.get_special_tokens_mask.already_has_special_tokens",description:`<strong>already_has_special_tokens</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the token list is already formatted with special tokens for the model.`,name:"already_has_special_tokens"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert.py#L256",returnDescription:`
<p>A list of integers in the range [0, 1]: 1 for a special token, 0 for a sequence token.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),ll=new Ge({}),il=new R({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:""}],parametersDescription:[{anchor:"transformers.DistilBertTokenizerFast.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
File containing the vocabulary.`,name:"vocab_file"},{anchor:"transformers.DistilBertTokenizerFast.do_lower_case",description:`<strong>do_lower_case</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to lowercase the input when tokenizing.`,name:"do_lower_case"},{anchor:"transformers.DistilBertTokenizerFast.unk_token",description:`<strong>unk_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[UNK]&quot;</code>) &#x2014;
The unknown token. A token that is not in the vocabulary cannot be converted to an ID and is set to be this
token instead.`,name:"unk_token"},{anchor:"transformers.DistilBertTokenizerFast.sep_token",description:`<strong>sep_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
The separator token, which is used when building a sequence from multiple sequences, e.g. two sequences for
sequence classification or for a text and a question for question answering. It is also used as the last
token of a sequence built with special tokens.`,name:"sep_token"},{anchor:"transformers.DistilBertTokenizerFast.pad_token",description:`<strong>pad_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[PAD]&quot;</code>) &#x2014;
The token used for padding, for example when batching sequences of different lengths.`,name:"pad_token"},{anchor:"transformers.DistilBertTokenizerFast.cls_token",description:`<strong>cls_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
The classifier token which is used when doing sequence classification (classification of the whole sequence
instead of per-token classification). It is the first token of the sequence when built with special tokens.`,name:"cls_token"},{anchor:"transformers.DistilBertTokenizerFast.mask_token",description:`<strong>mask_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[MASK]&quot;</code>) &#x2014;
The token used for masking values. This is the token used when training this model with masked language
modeling. This is the token which the model will try to predict.`,name:"mask_token"},{anchor:"transformers.DistilBertTokenizerFast.clean_text",description:`<strong>clean_text</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to clean the text before tokenization by removing any control characters and replacing all
whitespaces by the classic one.`,name:"clean_text"},{anchor:"transformers.DistilBertTokenizerFast.tokenize_chinese_chars",description:`<strong>tokenize_chinese_chars</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to tokenize Chinese characters. This should likely be deactivated for Japanese (see <a href="https://github.com/huggingface/transformers/issues/328" rel="nofollow">this
issue</a>).`,name:"tokenize_chinese_chars"},{anchor:"transformers.DistilBertTokenizerFast.strip_accents",description:`<strong>strip_accents</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to strip all accents. If this option is not specified, then it will be determined by the
value for <code>lowercase</code> (as in the original BERT).`,name:"strip_accents"},{anchor:"transformers.DistilBertTokenizerFast.wordpieces_prefix",description:`<strong>wordpieces_prefix</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;##&quot;</code>) &#x2014;
The prefix for subwords.`,name:"wordpieces_prefix"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert_fast.py#L84"}}),pl=new R({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.DistilBertTokenizerFast.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:""},{name:"token_ids_1",val:" = None"}],parametersDescription:[{anchor:"transformers.DistilBertTokenizerFast.build_inputs_with_special_tokens.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs to which the special tokens will be added.`,name:"token_ids_0"},{anchor:"transformers.DistilBertTokenizerFast.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert_fast.py#L174",returnDescription:`
<p>List of <a href="../glossary#input-ids">input IDs</a> with the appropriate special tokens.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),ul=new R({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.DistilBertTokenizerFast.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.DistilBertTokenizerFast.create_token_type_ids_from_sequences.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.DistilBertTokenizerFast.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/tokenization_distilbert_fast.py#L199",returnDescription:`
<p>List of <a href="../glossary#token-type-ids">token type IDs</a> according to the given sequence(s).</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),en=new Ie({props:{anchor:"transformers.DistilBertTokenizerFast.create_token_type_ids_from_sequences.example",$$slots:{default:[yC]},$$scope:{ctx:B}}}),fl=new Ge({}),ml=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L495"}}),vl=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L567",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutput"
>transformers.modeling_outputs.BaseModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutput"
>transformers.modeling_outputs.BaseModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),on=new Ze({props:{$$slots:{default:[wC]},$$scope:{ctx:B}}}),sn=new Ie({props:{anchor:"transformers.DistilBertModel.forward.example",$$slots:{default:[TC]},$$scope:{ctx:B}}}),yl=new Ge({}),wl=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L623"}}),El=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L667",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),rn=new Ze({props:{$$slots:{default:[kC]},$$scope:{ctx:B}}}),an=new Ie({props:{anchor:"transformers.DistilBertForMaskedLM.forward.example",$$slots:{default:[MC]},$$scope:{ctx:B}}}),Fl=new Ge({}),Bl=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L730"}}),Cl=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L764",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),dn=new Ze({props:{$$slots:{default:[$C]},$$scope:{ctx:B}}}),cn=new Ie({props:{anchor:"transformers.DistilBertForSequenceClassification.forward.example",$$slots:{default:[EC]},$$scope:{ctx:B}}}),pn=new Ie({props:{anchor:"transformers.DistilBertForSequenceClassification.forward.example-2",$$slots:{default:[FC]},$$scope:{ctx:B}}}),Jl=new Ge({}),zl=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L1059"}}),Al=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L1091",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),un=new Ze({props:{$$slots:{default:[BC]},$$scope:{ctx:B}}}),fn=new Ie({props:{anchor:"transformers.DistilBertForMultipleChoice.forward.example",$$slots:{default:[jC]},$$scope:{ctx:B}}}),Nl=new Ge({}),Rl=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L965"}}),Xl=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L997",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),gn=new Ze({props:{$$slots:{default:[DC]},$$scope:{ctx:B}}}),_n=new Ie({props:{anchor:"transformers.DistilBertForTokenClassification.forward.example",$$slots:{default:[xC]},$$scope:{ctx:B}}}),Pl=new Ge({}),Vl=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L847"}}),Ol=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_distilbert.py#L881",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),vn=new Ze({props:{$$slots:{default:[CC]},$$scope:{ctx:B}}}),yn=new Ie({props:{anchor:"transformers.DistilBertForQuestionAnswering.forward.example",$$slots:{default:[JC]},$$scope:{ctx:B}}}),Hl=new Ge({}),Yl=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L516"}}),Tn=new Ze({props:{$$slots:{default:[zC]},$$scope:{ctx:B}}}),oi=new R({props:{name:"call",anchor:"transformers.TFDistilBertModel.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"training",val:": 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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L521",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutput"
>transformers.modeling_tf_outputs.TFBaseModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutput"
>transformers.modeling_tf_outputs.TFBaseModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),kn=new Ze({props:{$$slots:{default:[UC]},$$scope:{ctx:B}}}),Mn=new Ie({props:{anchor:"transformers.TFDistilBertModel.call.example",$$slots:{default:[IC]},$$scope:{ctx:B}}}),si=new Ge({}),ni=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L596"}}),En=new Ze({props:{$$slots:{default:[WC]},$$scope:{ctx:B}}}),di=new R({props:{name:"call",anchor:"transformers.TFDistilBertForMaskedLM.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": 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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L616",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Fn=new Ze({props:{$$slots:{default:[AC]},$$scope:{ctx:B}}}),Bn=new Ie({props:{anchor:"transformers.TFDistilBertForMaskedLM.call.example",$$slots:{default:[NC]},$$scope:{ctx:B}}}),jn=new Ie({props:{anchor:"transformers.TFDistilBertForMaskedLM.call.example-2",$$slots:{default:[RC]},$$scope:{ctx:B}}}),ci=new Ge({}),pi=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L678"}}),xn=new Ze({props:{$$slots:{default:[ZC]},$$scope:{ctx:B}}}),mi=new R({props:{name:"call",anchor:"transformers.TFDistilBertForSequenceClassification.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": 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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L695",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Cn=new Ze({props:{$$slots:{default:[GC]},$$scope:{ctx:B}}}),Jn=new Ie({props:{anchor:"transformers.TFDistilBertForSequenceClassification.call.example",$$slots:{default:[qC]},$$scope:{ctx:B}}}),zn=new Ie({props:{anchor:"transformers.TFDistilBertForSequenceClassification.call.example-2",$$slots:{default:[XC]},$$scope:{ctx:B}}}),gi=new Ge({}),_i=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L825"}}),In=new Ze({props:{$$slots:{default:[PC]},$$scope:{ctx:B}}}),wi=new R({props:{name:"call",anchor:"transformers.TFDistilBertForMultipleChoice.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": 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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L841",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Wn=new Ze({props:{$$slots:{default:[VC]},$$scope:{ctx:B}}}),An=new Ie({props:{anchor:"transformers.TFDistilBertForMultipleChoice.call.example",$$slots:{default:[SC]},$$scope:{ctx:B}}}),Ti=new Ge({}),ki=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L757"}}),Rn=new Ze({props:{$$slots:{default:[LC]},$$scope:{ctx:B}}}),Fi=new R({props:{name:"call",anchor:"transformers.TFDistilBertForTokenClassification.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": 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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L768",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Zn=new Ze({props:{$$slots:{default:[QC]},$$scope:{ctx:B}}}),Gn=new Ie({props:{anchor:"transformers.TFDistilBertForTokenClassification.call.example",$$slots:{default:[OC]},$$scope:{ctx:B}}}),qn=new Ie({props:{anchor:"transformers.TFDistilBertForTokenClassification.call.example-2",$$slots:{default:[HC]},$$scope:{ctx:B}}}),Bi=new Ge({}),ji=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L919"}}),Pn=new Ze({props:{$$slots:{default:[YC]},$$scope:{ctx:B}}}),Ji=new R({props:{name:"call",anchor:"transformers.TFDistilBertForQuestionAnswering.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"start_positions",val:": np.ndarray | tf.Tensor | None = None"},{name:"end_positions",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": 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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/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.32.0/src/transformers/models/distilbert/modeling_tf_distilbert.py#L930",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Vn=new Ze({props:{$$slots:{default:[KC]},$$scope:{ctx:B}}}),Sn=new Ie({props:{anchor:"transformers.TFDistilBertForQuestionAnswering.call.example",$$slots:{default:[eJ]},$$scope:{ctx:B}}}),Ln=new Ie({props:{anchor:"transformers.TFDistilBertForQuestionAnswering.call.example-2",$$slots:{default:[tJ]},$$scope:{ctx:B}}}),zi=new Ge({}),Ui=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L532"}}),qi=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L455"}}),On=new Ze({props:{$$slots:{default:[oJ]},$$scope:{ctx:B}}}),Hn=new Ie({props:{anchor:"transformers.FlaxDistilBertModel.__call__.example",$$slots:{default:[sJ]},$$scope:{ctx:B}}}),Xi=new Ge({}),Pi=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L605"}}),ed=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L455",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMaskedLMOutput"
>transformers.modeling_flax_outputs.FlaxMaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Kn=new Ze({props:{$$slots:{default:[nJ]},$$scope:{ctx:B}}}),er=new Ie({props:{anchor:"transformers.FlaxDistilBertForMaskedLM.__call__.example",$$slots:{default:[rJ]},$$scope:{ctx:B}}}),td=new Ge({}),od=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L672"}}),cd=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L455",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),or=new Ze({props:{$$slots:{default:[aJ]},$$scope:{ctx:B}}}),sr=new Ie({props:{anchor:"transformers.FlaxDistilBertForSequenceClassification.__call__.example",$$slots:{default:[lJ]},$$scope:{ctx:B}}}),pd=new Ge({}),hd=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L751"}}),yd=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L455",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),rr=new Ze({props:{$$slots:{default:[iJ]},$$scope:{ctx:B}}}),ar=new Ie({props:{anchor:"transformers.FlaxDistilBertForMultipleChoice.__call__.example",$$slots:{default:[dJ]},$$scope:{ctx:B}}}),wd=new Ge({}),Td=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L816"}}),Dd=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L455",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ir=new Ze({props:{$$slots:{default:[cJ]},$$scope:{ctx:B}}}),dr=new Ie({props:{anchor:"transformers.FlaxDistilBertForTokenClassification.__call__.example",$$slots:{default:[pJ]},$$scope:{ctx:B}}}),xd=new Ge({}),Cd=new R({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.32.0/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.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L885"}}),Rd=new R({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.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/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.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/distilbert/modeling_flax_distilbert.py#L455",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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.32.0/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.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),pr=new Ze({props:{$$slots:{default:[hJ]},$$scope:{ctx:B}}}),hr=new Ie({props:{anchor:"transformers.FlaxDistilBertForQuestionAnswering.__call__.example",$$slots:{default:[uJ]},$$scope:{ctx:B}}}),{c(){d=n("meta"),v=p(),f=n("h1"),m=n("a"),b=n("span"),w(i.$$.fragment),u=p(),j=n("span"),ke=o("DistilBERT"),ye=p(),W=n("div"),ie=n("a"),K=n("img"),Me=p(),q=n("a"),de=n("img"),S=p(),ce=n("a"),pe=n("img"),we=p(),se=n("h2"),Z=n("a"),fe=n("span"),w(re.$$.fragment),L=p(),me=n("span"),$e=o("Overview"),te=p(),C=n("p"),U=o("The DistilBERT model was proposed in the blog post "),ae=n("a"),Q=o(`Smaller, faster, cheaper, lighter: Introducing DistilBERT, a
distilled version of BERT`),Ee=o(", and the paper "),le=n("a"),O=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
`),ge=n("em"),I=o("bert-base-uncased"),Be=o(`, runs 60% faster while preserving over 95% of BERT\u2019s performances as measured on the GLUE language
understanding benchmark.`),P=p(),he=n("p"),je=o("The abstract from the paper is the following:"),V=p(),ue=n("p"),_e=n("em"),N=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.`),Te=p(),X=n("p"),De=o("Tips:"),oe=p(),J=n("ul"),be=n("li"),z=n("p"),xe=o("DistilBERT doesn\u2019t have "),ve=n("code"),y=o("token_type_ids"),D=o(`, you don\u2019t need to indicate which token belongs to which segment. Just
separate your segments with the separation token `),qe=n("code"),ne=o("tokenizer.sep_token"),Se=o(" (or "),Xe=n("code"),x=o("[SEP]"),Le=o(")."),Qe=p(),Pe=n("li"),Ne=n("p"),Oe=o("DistilBERT doesn\u2019t have options to select the input positions ("),A=n("code"),H=o("position_ids"),He=o(` input). This could be added if
necessary though, just let us know if you need this option.`),Ye=p(),G=n("li"),Ve=n("p"),Ke=o("Same as BERT but smaller. Trained by distillation of the pretrained BERT model, meaning it\u2019s been trained to predict the same probabilities as the larger model. The actual objective is a combination of:"),Ce=p(),Je=n("ul"),ee=n("li"),et=o("finding the same probabilities as the teacher model"),O_=p(),Qp=n("li"),H_=o("predicting the masked tokens correctly (but no next-sentence objective)"),Y_=p(),Op=n("li"),K_=o("a cosine similarity between the hidden states of the student and the teacher model"),fm=p(),Wt=n("p"),eb=o("This model was contributed by "),Ir=n("a"),tb=o("victorsanh"),ob=o(`. This model jax version was
contributed by `),Wr=n("a"),sb=o("kamalkraj"),nb=o(". The original code can be found "),Ar=n("a"),rb=o("here"),ab=o("."),mm=p(),Lo=n("h2"),qs=n("a"),Hp=n("span"),w(Nr.$$.fragment),lb=p(),Yp=n("span"),ib=o("Resources"),gm=p(),lc=n("p"),db=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."),_m=p(),w(Rr.$$.fragment),bm=p(),Ue=n("ul"),Zr=n("li"),cb=o("A blog post on "),Gr=n("a"),pb=o("Getting Started with Sentiment Analysis using Python"),hb=o(" with DistilBERT."),ub=p(),qr=n("li"),fb=o("A blog post on how to "),Xr=n("a"),mb=o("train DistilBERT with Blurr for sequence classification"),gb=o("."),_b=p(),Pr=n("li"),bb=o("A blog post on how to use "),Vr=n("a"),vb=o("Ray to tune DistilBERT hyperparameters"),yb=o("."),wb=p(),Sr=n("li"),Tb=o("A blog post on how to "),Lr=n("a"),kb=o("train DistilBERT with Hugging Face and Amazon SageMaker"),Mb=o("."),$b=p(),Qr=n("li"),Eb=o("A notebook on how to "),Or=n("a"),Fb=o("finetune DistilBERT for multi-label classification"),Bb=o(". \u{1F30E}"),jb=p(),Hr=n("li"),Db=o("A notebook on how to "),Yr=n("a"),xb=o("finetune DistilBERT for multiclass classification with PyTorch"),Cb=o(". \u{1F30E}"),Jb=p(),Kr=n("li"),zb=o("A notebook on how to "),ea=n("a"),Ub=o("finetune DistilBERT for text classification in TensorFlow"),Ib=o(". \u{1F30E}"),Wb=p(),go=n("li"),ic=n("a"),Ab=o("DistilBertForSequenceClassification"),Nb=o(" is supported by this "),ta=n("a"),Rb=o("example script"),Zb=o(" and "),oa=n("a"),Gb=o("notebook"),qb=o("."),Xb=p(),_o=n("li"),dc=n("a"),Pb=o("TFDistilBertForSequenceClassification"),Vb=o(" is supported by this "),sa=n("a"),Sb=o("example script"),Lb=o(" and "),na=n("a"),Qb=o("notebook"),Ob=o("."),Hb=p(),bo=n("li"),cc=n("a"),Yb=o("FlaxDistilBertForSequenceClassification"),Kb=o(" is supported by this "),ra=n("a"),ev=o("example script"),tv=o(" and "),aa=n("a"),ov=o("notebook"),sv=o("."),nv=p(),Kp=n("li"),pc=n("a"),rv=o("Text classification task guide"),vm=p(),w(la.$$.fragment),ym=p(),wt=n("ul"),vo=n("li"),hc=n("a"),av=o("DistilBertForTokenClassification"),lv=o(" is supported by this "),ia=n("a"),iv=o("example script"),dv=o(" and "),da=n("a"),cv=o("notebook"),pv=o("."),hv=p(),yo=n("li"),uc=n("a"),uv=o("TFDistilBertForTokenClassification"),fv=o(" is supported by this "),ca=n("a"),mv=o("example script"),gv=o(" and "),pa=n("a"),_v=o("notebook"),bv=o("."),vv=p(),Xs=n("li"),fc=n("a"),yv=o("FlaxDistilBertForTokenClassification"),wv=o(" is supported by this "),ha=n("a"),Tv=o("example script"),kv=o("."),Mv=p(),mc=n("li"),ua=n("a"),$v=o("Token classification"),Ev=o(" chapter of the \u{1F917} Hugging Face Course."),Fv=p(),eh=n("li"),gc=n("a"),Bv=o("Token classification task guide"),wm=p(),w(fa.$$.fragment),Tm=p(),Tt=n("ul"),wo=n("li"),_c=n("a"),jv=o("DistilBertForMaskedLM"),Dv=o(" is supported by this "),ma=n("a"),xv=o("example script"),Cv=o(" and "),ga=n("a"),Jv=o("notebook"),zv=o("."),Uv=p(),To=n("li"),bc=n("a"),Iv=o("TFDistilBertForMaskedLM"),Wv=o(" is supported by this "),_a=n("a"),Av=o("example script"),Nv=o(" and "),ba=n("a"),Rv=o("notebook"),Zv=o("."),Gv=p(),ko=n("li"),vc=n("a"),qv=o("FlaxDistilBertForMaskedLM"),Xv=o(" is supported by this "),va=n("a"),Pv=o("example script"),Vv=o(" and "),ya=n("a"),Sv=o("notebook"),Lv=o("."),Qv=p(),yc=n("li"),wa=n("a"),Ov=o("Masked language modeling"),Hv=o(" chapter of the \u{1F917} Hugging Face Course."),Yv=p(),th=n("li"),wc=n("a"),Kv=o("Masked language modeling task guide"),km=p(),w(Ta.$$.fragment),Mm=p(),kt=n("ul"),Mo=n("li"),Tc=n("a"),ey=o("DistilBertForQuestionAnswering"),ty=o(" is supported by this "),ka=n("a"),oy=o("example script"),sy=o(" and "),Ma=n("a"),ny=o("notebook"),ry=o("."),ay=p(),$o=n("li"),kc=n("a"),ly=o("TFDistilBertForQuestionAnswering"),iy=o(" is supported by this "),$a=n("a"),dy=o("example script"),cy=o(" and "),Ea=n("a"),py=o("notebook"),hy=o("."),uy=p(),Ps=n("li"),Mc=n("a"),fy=o("FlaxDistilBertForQuestionAnswering"),my=o(" is supported by this "),Fa=n("a"),gy=o("example script"),_y=o("."),by=p(),$c=n("li"),Ba=n("a"),vy=o("Question answering"),yy=o(" chapter of the \u{1F917} Hugging Face Course."),wy=p(),oh=n("li"),Ec=n("a"),Ty=o("Question answering task guide"),$m=p(),Fc=n("p"),sh=n("strong"),ky=o("Multiple choice"),Em=p(),Eo=n("ul"),Fo=n("li"),Bc=n("a"),My=o("DistilBertForMultipleChoice"),$y=o(" is supported by this "),ja=n("a"),Ey=o("example script"),Fy=o(" and "),Da=n("a"),By=o("notebook"),jy=o("."),Dy=p(),Bo=n("li"),jc=n("a"),xy=o("TFDistilBertForMultipleChoice"),Cy=o(" is supported by this "),xa=n("a"),Jy=o("example script"),zy=o(" and "),Ca=n("a"),Uy=o("notebook"),Iy=o("."),Wy=p(),nh=n("li"),Dc=n("a"),Ay=o("Multiple choice task guide"),Fm=p(),xc=n("p"),Ny=o("\u2697\uFE0F Optimization"),Bm=p(),jo=n("ul"),Ja=n("li"),Ry=o("A blog post on how to "),za=n("a"),Zy=o("quantize DistilBERT with \u{1F917} Optimum and Intel"),Gy=o("."),qy=p(),Ua=n("li"),Xy=o("A blog post on how "),Ia=n("a"),Py=o("Optimizing Transformers for GPUs with \u{1F917} Optimum"),Vy=o("."),Sy=p(),Wa=n("li"),Ly=o("A blog post on "),Aa=n("a"),Qy=o("Optimizing Transformers with Hugging Face Optimum"),Oy=o("."),jm=p(),Cc=n("p"),Hy=o("\u26A1\uFE0F Inference"),Dm=p(),Vs=n("ul"),Na=n("li"),Yy=o("A blog post on how to "),Ra=n("a"),Ky=o("Accelerate BERT inference with Hugging Face Transformers and AWS Inferentia"),ew=o(" with DistilBERT."),tw=p(),Za=n("li"),ow=o("A blog post on "),Ga=n("a"),sw=o("Serverless Inference with Hugging Face\u2019s Transformers, DistilBERT and Amazon SageMaker"),nw=o("."),xm=p(),Jc=n("p"),rw=o("\u{1F680} Deploy"),Cm=p(),Do=n("ul"),qa=n("li"),aw=o("A blog post on how to "),Xa=n("a"),lw=o("deploy DistilBERT on Google Cloud"),iw=o("."),dw=p(),Pa=n("li"),cw=o("A blog post on how to "),Va=n("a"),pw=o("deploy DistilBERT with Amazon SageMaker"),hw=o("."),uw=p(),Sa=n("li"),fw=o("A blog post on how to "),La=n("a"),mw=o("Deploy BERT with Hugging Face Transformers, Amazon SageMaker and Terraform module"),gw=o("."),Jm=p(),Qo=n("h2"),Ss=n("a"),rh=n("span"),w(Qa.$$.fragment),_w=p(),ah=n("span"),bw=o("DistilBertConfig"),zm=p(),It=n("div"),w(Oa.$$.fragment),vw=p(),ro=n("p"),yw=o("This is the configuration class to store the configuration of a "),zc=n("a"),ww=o("DistilBertModel"),Tw=o(" or a "),Uc=n("a"),kw=o("TFDistilBertModel"),Mw=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
`),Ha=n("a"),$w=o("distilbert-base-uncased"),Ew=o(" architecture."),Fw=p(),Oo=n("p"),Bw=o("Configuration objects inherit from "),Ic=n("a"),jw=o("PretrainedConfig"),Dw=o(` and can be used to control the model outputs. Read the
documentation from `),Wc=n("a"),xw=o("PretrainedConfig"),Cw=o(" for more information."),Jw=p(),w(Ls.$$.fragment),Um=p(),Ho=n("h2"),Qs=n("a"),lh=n("span"),w(Ya.$$.fragment),zw=p(),ih=n("span"),Uw=o("DistilBertTokenizer"),Im=p(),tt=n("div"),w(Ka.$$.fragment),Iw=p(),dh=n("p"),Ww=o("Construct a DistilBERT tokenizer. Based on WordPiece."),Aw=p(),el=n("p"),Nw=o("This tokenizer inherits from "),Ac=n("a"),Rw=o("PreTrainedTokenizer"),Zw=o(` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Gw=p(),xo=n("div"),w(tl.$$.fragment),qw=p(),ch=n("p"),Xw=o(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A BERT sequence has the following format:`),Pw=p(),ol=n("ul"),Nc=n("li"),Vw=o("single sequence: "),ph=n("code"),Sw=o("[CLS] X [SEP]"),Lw=p(),Rc=n("li"),Qw=o("pair of sequences: "),hh=n("code"),Ow=o("[CLS] A [SEP] B [SEP]"),Hw=p(),Os=n("div"),w(sl.$$.fragment),Yw=p(),uh=n("p"),Kw=o("Converts a sequence of tokens (string) in a single string."),eT=p(),At=n("div"),w(nl.$$.fragment),tT=p(),fh=n("p"),oT=o("Create a mask from the two sequences passed to be used in a sequence-pair classification task. A BERT sequence"),sT=p(),w(Hs.$$.fragment),nT=p(),Yo=n("p"),rT=o("If "),mh=n("code"),aT=o("token_ids_1"),lT=o(" is "),gh=n("code"),iT=o("None"),dT=o(", this method only returns the first portion of the mask (0s)."),cT=p(),Ys=n("div"),w(rl.$$.fragment),pT=p(),al=n("p"),hT=o(`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),_h=n("code"),uT=o("prepare_for_model"),fT=o(" method."),Wm=p(),Ko=n("h2"),Ks=n("a"),bh=n("span"),w(ll.$$.fragment),mT=p(),vh=n("span"),gT=o("DistilBertTokenizerFast"),Am=p(),ft=n("div"),w(il.$$.fragment),_T=p(),dl=n("p"),bT=o("Construct a \u201Cfast\u201D DistilBERT tokenizer (backed by HuggingFace\u2019s "),yh=n("em"),vT=o("tokenizers"),yT=o(" library). Based on WordPiece."),wT=p(),cl=n("p"),TT=o("This tokenizer inherits from "),Zc=n("a"),kT=o("PreTrainedTokenizerFast"),MT=o(` which contains most of the main methods. Users should
refer to this superclass for more information regarding those methods.`),$T=p(),Co=n("div"),w(pl.$$.fragment),ET=p(),wh=n("p"),FT=o(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A BERT sequence has the following format:`),BT=p(),hl=n("ul"),Gc=n("li"),jT=o("single sequence: "),Th=n("code"),DT=o("[CLS] X [SEP]"),xT=p(),qc=n("li"),CT=o("pair of sequences: "),kh=n("code"),JT=o("[CLS] A [SEP] B [SEP]"),zT=p(),Nt=n("div"),w(ul.$$.fragment),UT=p(),Mh=n("p"),IT=o("Create a mask from the two sequences passed to be used in a sequence-pair classification task. A BERT sequence"),WT=p(),w(en.$$.fragment),AT=p(),es=n("p"),NT=o("If "),$h=n("code"),RT=o("token_ids_1"),ZT=o(" is "),Eh=n("code"),GT=o("None"),qT=o(", this method only returns the first portion of the mask (0s)."),Nm=p(),ts=n("h2"),tn=n("a"),Fh=n("span"),w(fl.$$.fragment),XT=p(),Bh=n("span"),PT=o("DistilBertModel"),Rm=p(),mt=n("div"),w(ml.$$.fragment),VT=p(),jh=n("p"),ST=o("The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),LT=p(),gl=n("p"),QT=o("This model inherits from "),Xc=n("a"),OT=o("PreTrainedModel"),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.)`),YT=p(),_l=n("p"),KT=o("This model is also a PyTorch "),bl=n("a"),ek=o("torch.nn.Module"),tk=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),ok=p(),Rt=n("div"),w(vl.$$.fragment),sk=p(),os=n("p"),nk=o("The "),Pc=n("a"),rk=o("DistilBertModel"),ak=o(" forward method, overrides the "),Dh=n("code"),lk=o("__call__"),ik=o(" special method."),dk=p(),w(on.$$.fragment),ck=p(),w(sn.$$.fragment),Zm=p(),ss=n("h2"),nn=n("a"),xh=n("span"),w(yl.$$.fragment),pk=p(),Ch=n("span"),hk=o("DistilBertForMaskedLM"),Gm=p(),gt=n("div"),w(wl.$$.fragment),uk=p(),Tl=n("p"),fk=o("DistilBert Model with a "),Jh=n("code"),mk=o("masked language modeling"),gk=o(" head on top."),_k=p(),kl=n("p"),bk=o("This model inherits from "),Vc=n("a"),vk=o("PreTrainedModel"),yk=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.)`),wk=p(),Ml=n("p"),Tk=o("This model is also a PyTorch "),$l=n("a"),kk=o("torch.nn.Module"),Mk=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),$k=p(),Zt=n("div"),w(El.$$.fragment),Ek=p(),ns=n("p"),Fk=o("The "),Sc=n("a"),Bk=o("DistilBertForMaskedLM"),jk=o(" forward method, overrides the "),zh=n("code"),Dk=o("__call__"),xk=o(" special method."),Ck=p(),w(rn.$$.fragment),Jk=p(),w(an.$$.fragment),qm=p(),rs=n("h2"),ln=n("a"),Uh=n("span"),w(Fl.$$.fragment),zk=p(),Ih=n("span"),Uk=o("DistilBertForSequenceClassification"),Xm=p(),_t=n("div"),w(Bl.$$.fragment),Ik=p(),Wh=n("p"),Wk=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.`),Ak=p(),jl=n("p"),Nk=o("This model inherits from "),Lc=n("a"),Rk=o("PreTrainedModel"),Zk=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.)`),Gk=p(),Dl=n("p"),qk=o("This model is also a PyTorch "),xl=n("a"),Xk=o("torch.nn.Module"),Pk=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Vk=p(),Mt=n("div"),w(Cl.$$.fragment),Sk=p(),as=n("p"),Lk=o("The "),Qc=n("a"),Qk=o("DistilBertForSequenceClassification"),Ok=o(" forward method, overrides the "),Ah=n("code"),Hk=o("__call__"),Yk=o(" special method."),Kk=p(),w(dn.$$.fragment),eM=p(),w(cn.$$.fragment),tM=p(),w(pn.$$.fragment),Pm=p(),ls=n("h2"),hn=n("a"),Nh=n("span"),w(Jl.$$.fragment),oM=p(),Rh=n("span"),sM=o("DistilBertForMultipleChoice"),Vm=p(),bt=n("div"),w(zl.$$.fragment),nM=p(),Zh=n("p"),rM=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.`),aM=p(),Ul=n("p"),lM=o("This model inherits from "),Oc=n("a"),iM=o("PreTrainedModel"),dM=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.)`),cM=p(),Il=n("p"),pM=o("This model is also a PyTorch "),Wl=n("a"),hM=o("torch.nn.Module"),uM=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),fM=p(),Gt=n("div"),w(Al.$$.fragment),mM=p(),is=n("p"),gM=o("The "),Hc=n("a"),_M=o("DistilBertForMultipleChoice"),bM=o(" forward method, overrides the "),Gh=n("code"),vM=o("__call__"),yM=o(" special method."),wM=p(),w(un.$$.fragment),TM=p(),w(fn.$$.fragment),Sm=p(),ds=n("h2"),mn=n("a"),qh=n("span"),w(Nl.$$.fragment),kM=p(),Xh=n("span"),MM=o("DistilBertForTokenClassification"),Lm=p(),vt=n("div"),w(Rl.$$.fragment),$M=p(),Ph=n("p"),EM=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.`),FM=p(),Zl=n("p"),BM=o("This model inherits from "),Yc=n("a"),jM=o("PreTrainedModel"),DM=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.)`),xM=p(),Gl=n("p"),CM=o("This model is also a PyTorch "),ql=n("a"),JM=o("torch.nn.Module"),zM=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),UM=p(),qt=n("div"),w(Xl.$$.fragment),IM=p(),cs=n("p"),WM=o("The "),Kc=n("a"),AM=o("DistilBertForTokenClassification"),NM=o(" forward method, overrides the "),Vh=n("code"),RM=o("__call__"),ZM=o(" special method."),GM=p(),w(gn.$$.fragment),qM=p(),w(_n.$$.fragment),Qm=p(),ps=n("h2"),bn=n("a"),Sh=n("span"),w(Pl.$$.fragment),XM=p(),Lh=n("span"),PM=o("DistilBertForQuestionAnswering"),Om=p(),yt=n("div"),w(Vl.$$.fragment),VM=p(),hs=n("p"),SM=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 `),Qh=n("code"),LM=o("span start logits"),QM=o(" and "),Oh=n("code"),OM=o("span end logits"),HM=o(")."),YM=p(),Sl=n("p"),KM=o("This model inherits from "),ep=n("a"),e2=o("PreTrainedModel"),t2=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.)`),o2=p(),Ll=n("p"),s2=o("This model is also a PyTorch "),Ql=n("a"),n2=o("torch.nn.Module"),r2=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),a2=p(),Xt=n("div"),w(Ol.$$.fragment),l2=p(),us=n("p"),i2=o("The "),tp=n("a"),d2=o("DistilBertForQuestionAnswering"),c2=o(" forward method, overrides the "),Hh=n("code"),p2=o("__call__"),h2=o(" special method."),u2=p(),w(vn.$$.fragment),f2=p(),w(yn.$$.fragment),Hm=p(),fs=n("h2"),wn=n("a"),Yh=n("span"),w(Hl.$$.fragment),m2=p(),Kh=n("span"),g2=o("TFDistilBertModel"),Ym=p(),it=n("div"),w(Yl.$$.fragment),_2=p(),eu=n("p"),b2=o("The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),v2=p(),Kl=n("p"),y2=o("This model inherits from "),op=n("a"),w2=o("TFPreTrainedModel"),T2=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.)`),k2=p(),ei=n("p"),M2=o("This model is also a "),ti=n("a"),$2=o("tf.keras.Model"),E2=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.`),F2=p(),w(Tn.$$.fragment),B2=p(),Pt=n("div"),w(oi.$$.fragment),j2=p(),ms=n("p"),D2=o("The "),sp=n("a"),x2=o("TFDistilBertModel"),C2=o(" forward method, overrides the "),tu=n("code"),J2=o("__call__"),z2=o(" special method."),U2=p(),w(kn.$$.fragment),I2=p(),w(Mn.$$.fragment),Km=p(),gs=n("h2"),$n=n("a"),ou=n("span"),w(si.$$.fragment),W2=p(),su=n("span"),A2=o("TFDistilBertForMaskedLM"),eg=p(),dt=n("div"),w(ni.$$.fragment),N2=p(),ri=n("p"),R2=o("DistilBert Model with a "),nu=n("code"),Z2=o("masked language modeling"),G2=o(" head on top."),q2=p(),ai=n("p"),X2=o("This model inherits from "),np=n("a"),P2=o("TFPreTrainedModel"),V2=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.)`),S2=p(),li=n("p"),L2=o("This model is also a "),ii=n("a"),Q2=o("tf.keras.Model"),O2=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.`),H2=p(),w(En.$$.fragment),Y2=p(),$t=n("div"),w(di.$$.fragment),K2=p(),_s=n("p"),e1=o("The "),rp=n("a"),t1=o("TFDistilBertForMaskedLM"),o1=o(" forward method, overrides the "),ru=n("code"),s1=o("__call__"),n1=o(" special method."),r1=p(),w(Fn.$$.fragment),a1=p(),w(Bn.$$.fragment),l1=p(),w(jn.$$.fragment),tg=p(),bs=n("h2"),Dn=n("a"),au=n("span"),w(ci.$$.fragment),i1=p(),lu=n("span"),d1=o("TFDistilBertForSequenceClassification"),og=p(),ct=n("div"),w(pi.$$.fragment),c1=p(),iu=n("p"),p1=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.`),h1=p(),hi=n("p"),u1=o("This model inherits from "),ap=n("a"),f1=o("TFPreTrainedModel"),m1=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.)`),g1=p(),ui=n("p"),_1=o("This model is also a "),fi=n("a"),b1=o("tf.keras.Model"),v1=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.`),y1=p(),w(xn.$$.fragment),w1=p(),Et=n("div"),w(mi.$$.fragment),T1=p(),vs=n("p"),k1=o("The "),lp=n("a"),M1=o("TFDistilBertForSequenceClassification"),$1=o(" forward method, overrides the "),du=n("code"),E1=o("__call__"),F1=o(" special method."),B1=p(),w(Cn.$$.fragment),j1=p(),w(Jn.$$.fragment),D1=p(),w(zn.$$.fragment),sg=p(),ys=n("h2"),Un=n("a"),cu=n("span"),w(gi.$$.fragment),x1=p(),pu=n("span"),C1=o("TFDistilBertForMultipleChoice"),ng=p(),pt=n("div"),w(_i.$$.fragment),J1=p(),hu=n("p"),z1=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.`),U1=p(),bi=n("p"),I1=o("This model inherits from "),ip=n("a"),W1=o("TFPreTrainedModel"),A1=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.)`),N1=p(),vi=n("p"),R1=o("This model is also a "),yi=n("a"),Z1=o("tf.keras.Model"),G1=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.`),q1=p(),w(In.$$.fragment),X1=p(),Vt=n("div"),w(wi.$$.fragment),P1=p(),ws=n("p"),V1=o("The "),dp=n("a"),S1=o("TFDistilBertForMultipleChoice"),L1=o(" forward method, overrides the "),uu=n("code"),Q1=o("__call__"),O1=o(" special method."),H1=p(),w(Wn.$$.fragment),Y1=p(),w(An.$$.fragment),rg=p(),Ts=n("h2"),Nn=n("a"),fu=n("span"),w(Ti.$$.fragment),K1=p(),mu=n("span"),e0=o("TFDistilBertForTokenClassification"),ag=p(),ht=n("div"),w(ki.$$.fragment),t0=p(),gu=n("p"),o0=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.`),s0=p(),Mi=n("p"),n0=o("This model inherits from "),cp=n("a"),r0=o("TFPreTrainedModel"),a0=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.)`),l0=p(),$i=n("p"),i0=o("This model is also a "),Ei=n("a"),d0=o("tf.keras.Model"),c0=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.`),p0=p(),w(Rn.$$.fragment),h0=p(),Ft=n("div"),w(Fi.$$.fragment),u0=p(),ks=n("p"),f0=o("The "),pp=n("a"),m0=o("TFDistilBertForTokenClassification"),g0=o(" forward method, overrides the "),_u=n("code"),_0=o("__call__"),b0=o(" special method."),v0=p(),w(Zn.$$.fragment),y0=p(),w(Gn.$$.fragment),w0=p(),w(qn.$$.fragment),lg=p(),Ms=n("h2"),Xn=n("a"),bu=n("span"),w(Bi.$$.fragment),T0=p(),vu=n("span"),k0=o("TFDistilBertForQuestionAnswering"),ig=p(),ut=n("div"),w(ji.$$.fragment),M0=p(),$s=n("p"),$0=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 `),yu=n("code"),E0=o("span start logits"),F0=o(" and "),wu=n("code"),B0=o("span end logits"),j0=o(")."),D0=p(),Di=n("p"),x0=o("This model inherits from "),hp=n("a"),C0=o("TFPreTrainedModel"),J0=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.)`),z0=p(),xi=n("p"),U0=o("This model is also a "),Ci=n("a"),I0=o("tf.keras.Model"),W0=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.`),A0=p(),w(Pn.$$.fragment),N0=p(),Bt=n("div"),w(Ji.$$.fragment),R0=p(),Es=n("p"),Z0=o("The "),up=n("a"),G0=o("TFDistilBertForQuestionAnswering"),q0=o(" forward method, overrides the "),Tu=n("code"),X0=o("__call__"),P0=o(" special method."),V0=p(),w(Vn.$$.fragment),S0=p(),w(Sn.$$.fragment),L0=p(),w(Ln.$$.fragment),dg=p(),Fs=n("h2"),Qn=n("a"),ku=n("span"),w(zi.$$.fragment),Q0=p(),Mu=n("span"),O0=o("FlaxDistilBertModel"),cg=p(),ot=n("div"),w(Ui.$$.fragment),H0=p(),$u=n("p"),Y0=o("The bare DistilBert Model transformer outputting raw hidden-states without any specific head on top."),K0=p(),Ii=n("p"),e$=o("This model inherits from "),fp=n("a"),t$=o("FlaxPreTrainedModel"),o$=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)`),s$=p(),Wi=n("p"),n$=o("This model is also a Flax Linen "),Ai=n("a"),r$=o("flax.linen.Module"),a$=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.`),l$=p(),Eu=n("p"),i$=o("Finally, this model supports inherent JAX features such as:"),d$=p(),ao=n("ul"),Fu=n("li"),Ni=n("a"),c$=o("Just-In-Time (JIT) compilation"),p$=p(),Bu=n("li"),Ri=n("a"),h$=o("Automatic Differentiation"),u$=p(),ju=n("li"),Zi=n("a"),f$=o("Vectorization"),m$=p(),Du=n("li"),Gi=n("a"),g$=o("Parallelization"),_$=p(),St=n("div"),w(qi.$$.fragment),b$=p(),Bs=n("p"),v$=o("The "),xu=n("code"),y$=o("FlaxDistilBertPreTrainedModel"),w$=o(" forward method, overrides the "),Cu=n("code"),T$=o("__call__"),k$=o(" special method."),M$=p(),w(On.$$.fragment),$$=p(),w(Hn.$$.fragment),pg=p(),js=n("h2"),Yn=n("a"),Ju=n("span"),w(Xi.$$.fragment),E$=p(),zu=n("span"),F$=o("FlaxDistilBertForMaskedLM"),hg=p(),st=n("div"),w(Pi.$$.fragment),B$=p(),Vi=n("p"),j$=o("DistilBert Model with a "),Uu=n("code"),D$=o("language modeling"),x$=o(" head on top."),C$=p(),Si=n("p"),J$=o("This model inherits from "),mp=n("a"),z$=o("FlaxPreTrainedModel"),U$=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)`),I$=p(),Li=n("p"),W$=o("This model is also a Flax Linen "),Qi=n("a"),A$=o("flax.linen.Module"),N$=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.`),R$=p(),Iu=n("p"),Z$=o("Finally, this model supports inherent JAX features such as:"),G$=p(),lo=n("ul"),Wu=n("li"),Oi=n("a"),q$=o("Just-In-Time (JIT) compilation"),X$=p(),Au=n("li"),Hi=n("a"),P$=o("Automatic Differentiation"),V$=p(),Nu=n("li"),Yi=n("a"),S$=o("Vectorization"),L$=p(),Ru=n("li"),Ki=n("a"),Q$=o("Parallelization"),O$=p(),Lt=n("div"),w(ed.$$.fragment),H$=p(),Ds=n("p"),Y$=o("The "),Zu=n("code"),K$=o("FlaxDistilBertPreTrainedModel"),eE=o(" forward method, overrides the "),Gu=n("code"),tE=o("__call__"),oE=o(" special method."),sE=p(),w(Kn.$$.fragment),nE=p(),w(er.$$.fragment),ug=p(),xs=n("h2"),tr=n("a"),qu=n("span"),w(td.$$.fragment),rE=p(),Xu=n("span"),aE=o("FlaxDistilBertForSequenceClassification"),fg=p(),nt=n("div"),w(od.$$.fragment),lE=p(),Pu=n("p"),iE=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.`),dE=p(),sd=n("p"),cE=o("This model inherits from "),gp=n("a"),pE=o("FlaxPreTrainedModel"),hE=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)`),uE=p(),nd=n("p"),fE=o("This model is also a Flax Linen "),rd=n("a"),mE=o("flax.linen.Module"),gE=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.`),_E=p(),Vu=n("p"),bE=o("Finally, this model supports inherent JAX features such as:"),vE=p(),io=n("ul"),Su=n("li"),ad=n("a"),yE=o("Just-In-Time (JIT) compilation"),wE=p(),Lu=n("li"),ld=n("a"),TE=o("Automatic Differentiation"),kE=p(),Qu=n("li"),id=n("a"),ME=o("Vectorization"),$E=p(),Ou=n("li"),dd=n("a"),EE=o("Parallelization"),FE=p(),Qt=n("div"),w(cd.$$.fragment),BE=p(),Cs=n("p"),jE=o("The "),Hu=n("code"),DE=o("FlaxDistilBertPreTrainedModel"),xE=o(" forward method, overrides the "),Yu=n("code"),CE=o("__call__"),JE=o(" special method."),zE=p(),w(or.$$.fragment),UE=p(),w(sr.$$.fragment),mg=p(),Js=n("h2"),nr=n("a"),Ku=n("span"),w(pd.$$.fragment),IE=p(),ef=n("span"),WE=o("FlaxDistilBertForMultipleChoice"),gg=p(),rt=n("div"),w(hd.$$.fragment),AE=p(),tf=n("p"),NE=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.`),RE=p(),ud=n("p"),ZE=o("This model inherits from "),_p=n("a"),GE=o("FlaxPreTrainedModel"),qE=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)`),XE=p(),fd=n("p"),PE=o("This model is also a Flax Linen "),md=n("a"),VE=o("flax.linen.Module"),SE=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.`),LE=p(),of=n("p"),QE=o("Finally, this model supports inherent JAX features such as:"),OE=p(),co=n("ul"),sf=n("li"),gd=n("a"),HE=o("Just-In-Time (JIT) compilation"),YE=p(),nf=n("li"),_d=n("a"),KE=o("Automatic Differentiation"),eF=p(),rf=n("li"),bd=n("a"),tF=o("Vectorization"),oF=p(),af=n("li"),vd=n("a"),sF=o("Parallelization"),nF=p(),Ot=n("div"),w(yd.$$.fragment),rF=p(),zs=n("p"),aF=o("The "),lf=n("code"),lF=o("FlaxDistilBertPreTrainedModel"),iF=o(" forward method, overrides the "),df=n("code"),dF=o("__call__"),cF=o(" special method."),pF=p(),w(rr.$$.fragment),hF=p(),w(ar.$$.fragment),_g=p(),Us=n("h2"),lr=n("a"),cf=n("span"),w(wd.$$.fragment),uF=p(),pf=n("span"),fF=o("FlaxDistilBertForTokenClassification"),bg=p(),at=n("div"),w(Td.$$.fragment),mF=p(),hf=n("p"),gF=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.`),_F=p(),kd=n("p"),bF=o("This model inherits from "),bp=n("a"),vF=o("FlaxPreTrainedModel"),yF=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)`),wF=p(),Md=n("p"),TF=o("This model is also a Flax Linen "),$d=n("a"),kF=o("flax.linen.Module"),MF=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.`),$F=p(),uf=n("p"),EF=o("Finally, this model supports inherent JAX features such as:"),FF=p(),po=n("ul"),ff=n("li"),Ed=n("a"),BF=o("Just-In-Time (JIT) compilation"),jF=p(),mf=n("li"),Fd=n("a"),DF=o("Automatic Differentiation"),xF=p(),gf=n("li"),Bd=n("a"),CF=o("Vectorization"),JF=p(),_f=n("li"),jd=n("a"),zF=o("Parallelization"),UF=p(),Ht=n("div"),w(Dd.$$.fragment),IF=p(),Is=n("p"),WF=o("The "),bf=n("code"),AF=o("FlaxDistilBertPreTrainedModel"),NF=o(" forward method, overrides the "),vf=n("code"),RF=o("__call__"),ZF=o(" special method."),GF=p(),w(ir.$$.fragment),qF=p(),w(dr.$$.fragment),vg=p(),Ws=n("h2"),cr=n("a"),yf=n("span"),w(xd.$$.fragment),XF=p(),wf=n("span"),PF=o("FlaxDistilBertForQuestionAnswering"),yg=p(),lt=n("div"),w(Cd.$$.fragment),VF=p(),As=n("p"),SF=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=n("code"),LF=o("span start logits"),QF=o(" and "),kf=n("code"),OF=o("span end logits"),HF=o(")."),YF=p(),Jd=n("p"),KF=o("This model inherits from "),vp=n("a"),eB=o("FlaxPreTrainedModel"),tB=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)`),oB=p(),zd=n("p"),sB=o("This model is also a Flax Linen "),Ud=n("a"),nB=o("flax.linen.Module"),rB=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.`),aB=p(),Mf=n("p"),lB=o("Finally, this model supports inherent JAX features such as:"),iB=p(),ho=n("ul"),$f=n("li"),Id=n("a"),dB=o("Just-In-Time (JIT) compilation"),cB=p(),Ef=n("li"),Wd=n("a"),pB=o("Automatic Differentiation"),hB=p(),Ff=n("li"),Ad=n("a"),uB=o("Vectorization"),fB=p(),Bf=n("li"),Nd=n("a"),mB=o("Parallelization"),gB=p(),Yt=n("div"),w(Rd.$$.fragment),_B=p(),Ns=n("p"),bB=o("The "),jf=n("code"),vB=o("FlaxDistilBertPreTrainedModel"),yB=o(" forward method, overrides the "),Df=n("code"),wB=o("__call__"),TB=o(" special method."),kB=p(),w(pr.$$.fragment),MB=p(),w(hr.$$.fragment),this.h()},l(l){const _=gC('[data-svelte="svelte-1phssyn"]',document.head);d=r(_,"META",{name:!0,content:!0}),_.forEach(t),v=h(l),f=r(l,"H1",{class:!0});var Zd=a(f);m=r(Zd,"A",{id:!0,class:!0,href:!0});var xf=a(m);b=r(xf,"SPAN",{});var Cf=a(b);T(i.$$.fragment,Cf),Cf.forEach(t),xf.forEach(t),u=h(Zd),j=r(Zd,"SPAN",{});var Jf=a(j);ke=s(Jf,"DistilBERT"),Jf.forEach(t),Zd.forEach(t),ye=h(l),W=r(l,"DIV",{class:!0});var Rs=a(W);ie=r(Rs,"A",{href:!0});var zf=a(ie);K=r(zf,"IMG",{alt:!0,src:!0}),zf.forEach(t),Me=h(Rs),q=r(Rs,"A",{href:!0});var Uf=a(q);de=r(Uf,"IMG",{alt:!0,src:!0}),Uf.forEach(t),S=h(Rs),ce=r(Rs,"A",{href:!0});var If=a(ce);pe=r(If,"IMG",{alt:!0,src:!0}),If.forEach(t),Rs.forEach(t),we=h(l),se=r(l,"H2",{class:!0});var Gd=a(se);Z=r(Gd,"A",{id:!0,class:!0,href:!0});var Wf=a(Z);fe=r(Wf,"SPAN",{});var Af=a(fe);T(re.$$.fragment,Af),Af.forEach(t),Wf.forEach(t),L=h(Gd),me=r(Gd,"SPAN",{});var Nf=a(me);$e=s(Nf,"Overview"),Nf.forEach(t),Gd.forEach(t),te=h(l),C=r(l,"P",{});var uo=a(C);U=s(uo,"The DistilBERT model was proposed in the blog post "),ae=r(uo,"A",{href:!0,rel:!0});var Rf=a(ae);Q=s(Rf,`Smaller, faster, cheaper, lighter: Introducing DistilBERT, a
distilled version of BERT`),Rf.forEach(t),Ee=s(uo,", and the paper "),le=r(uo,"A",{href:!0,rel:!0});var Zf=a(le);O=s(Zf,`DistilBERT, a
distilled version of BERT: smaller, faster, cheaper and lighter`),Zf.forEach(t),Fe=s(uo,`. DistilBERT is a
small, fast, cheap and light Transformer model trained by distilling BERT base. It has 40% less parameters than
`),ge=r(uo,"EM",{});var Gf=a(ge);I=s(Gf,"bert-base-uncased"),Gf.forEach(t),Be=s(uo,`, runs 60% faster while preserving over 95% of BERT\u2019s performances as measured on the GLUE language
understanding benchmark.`),uo.forEach(t),P=h(l),he=r(l,"P",{});var qf=a(he);je=s(qf,"The abstract from the paper is the following:"),qf.forEach(t),V=h(l),ue=r(l,"P",{});var Xf=a(ue);_e=r(Xf,"EM",{});var Pf=a(_e);N=s(Pf,`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.`),Pf.forEach(t),Xf.forEach(t),Te=h(l),X=r(l,"P",{});var Vf=a(X);De=s(Vf,"Tips:"),Vf.forEach(t),oe=h(l),J=r(l,"UL",{});var Zs=a(J);be=r(Zs,"LI",{});var Sf=a(be);z=r(Sf,"P",{});var fo=a(z);xe=s(fo,"DistilBERT doesn\u2019t have "),ve=r(fo,"CODE",{});var Lf=a(ve);y=s(Lf,"token_type_ids"),Lf.forEach(t),D=s(fo,`, you don\u2019t need to indicate which token belongs to which segment. Just
separate your segments with the separation token `),qe=r(fo,"CODE",{});var Qf=a(qe);ne=s(Qf,"tokenizer.sep_token"),Qf.forEach(t),Se=s(fo," (or "),Xe=r(fo,"CODE",{});var Of=a(Xe);x=s(Of,"[SEP]"),Of.forEach(t),Le=s(fo,")."),fo.forEach(t),Sf.forEach(t),Qe=h(Zs),Pe=r(Zs,"LI",{});var Hf=a(Pe);Ne=r(Hf,"P",{});var qd=a(Ne);Oe=s(qd,"DistilBERT doesn\u2019t have options to select the input positions ("),A=r(qd,"CODE",{});var Yf=a(A);H=s(Yf,"position_ids"),Yf.forEach(t),He=s(qd,` input). This could be added if
necessary though, just let us know if you need this option.`),qd.forEach(t),Hf.forEach(t),Ye=h(Zs),G=r(Zs,"LI",{});var Xd=a(G);Ve=r(Xd,"P",{});var Kf=a(Ve);Ke=s(Kf,"Same as BERT but smaller. Trained by distillation of the pretrained BERT model, meaning it\u2019s been trained to predict the same probabilities as the larger model. The actual objective is a combination of:"),Kf.forEach(t),Ce=h(Xd),Je=r(Xd,"UL",{});var Gs=a(Je);ee=r(Gs,"LI",{});var em=a(ee);et=s(em,"finding the same probabilities as the teacher model"),em.forEach(t),O_=h(Gs),Qp=r(Gs,"LI",{});var tm=a(Qp);H_=s(tm,"predicting the masked tokens correctly (but no next-sentence objective)"),tm.forEach(t),Y_=h(Gs),Op=r(Gs,"LI",{});var om=a(Op);K_=s(om,"a cosine similarity between the hidden states of the student and the teacher model"),om.forEach(t),Gs.forEach(t),Xd.forEach(t),Zs.forEach(t),fm=h(l),Wt=r(l,"P",{});var mo=a(Wt);eb=s(mo,"This model was contributed by "),Ir=r(mo,"A",{href:!0,rel:!0});var sm=a(Ir);tb=s(sm,"victorsanh"),sm.forEach(t),ob=s(mo,`. This model jax version was
contributed by `),Wr=r(mo,"A",{href:!0,rel:!0});var nm=a(Wr);sb=s(nm,"kamalkraj"),nm.forEach(t),nb=s(mo,". The original code can be found "),Ar=r(mo,"A",{href:!0,rel:!0});var rm=a(Ar);rb=s(rm,"here"),rm.forEach(t),ab=s(mo,"."),mo.forEach(t),mm=h(l),Lo=r(l,"H2",{class:!0});var Pd=a(Lo);qs=r(Pd,"A",{id:!0,class:!0,href:!0});var am=a(qs);Hp=r(am,"SPAN",{});var lm=a(Hp);T(Nr.$$.fragment,lm),lm.forEach(t),am.forEach(t),lb=h(Pd),Yp=r(Pd,"SPAN",{});var im=a(Yp);ib=s(im,"Resources"),im.forEach(t),Pd.forEach(t),gm=h(l),lc=r(l,"P",{});var dm=a(lc);db=s(dm,"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."),dm.forEach(t),_m=h(l),T(Rr.$$.fragment,l),bm=h(l),Ue=r(l,"UL",{});var Re=a(Ue);Zr=r(Re,"LI",{});var Vd=a(Zr);cb=s(Vd,"A blog post on "),Gr=r(Vd,"A",{href:!0,rel:!0});var cm=a(Gr);pb=s(cm,"Getting Started with Sentiment Analysis using Python"),cm.forEach(t),hb=s(Vd," with DistilBERT."),Vd.forEach(t),ub=h(Re),qr=r(Re,"LI",{});var Sd=a(qr);fb=s(Sd,"A blog post on how to "),Xr=r(Sd,"A",{href:!0,rel:!0});var pm=a(Xr);mb=s(pm,"train DistilBERT with Blurr for sequence classification"),pm.forEach(t),gb=s(Sd,"."),Sd.forEach(t),_b=h(Re),Pr=r(Re,"LI",{});var Ld=a(Pr);bb=s(Ld,"A blog post on how to use "),Vr=r(Ld,"A",{href:!0,rel:!0});var JB=a(Vr);vb=s(JB,"Ray to tune DistilBERT hyperparameters"),JB.forEach(t),yb=s(Ld,"."),Ld.forEach(t),wb=h(Re),Sr=r(Re,"LI",{});var Tg=a(Sr);Tb=s(Tg,"A blog post on how to "),Lr=r(Tg,"A",{href:!0,rel:!0});var zB=a(Lr);kb=s(zB,"train DistilBERT with Hugging Face and Amazon SageMaker"),zB.forEach(t),Mb=s(Tg,"."),Tg.forEach(t),$b=h(Re),Qr=r(Re,"LI",{});var kg=a(Qr);Eb=s(kg,"A notebook on how to "),Or=r(kg,"A",{href:!0,rel:!0});var UB=a(Or);Fb=s(UB,"finetune DistilBERT for multi-label classification"),UB.forEach(t),Bb=s(kg,". \u{1F30E}"),kg.forEach(t),jb=h(Re),Hr=r(Re,"LI",{});var Mg=a(Hr);Db=s(Mg,"A notebook on how to "),Yr=r(Mg,"A",{href:!0,rel:!0});var IB=a(Yr);xb=s(IB,"finetune DistilBERT for multiclass classification with PyTorch"),IB.forEach(t),Cb=s(Mg,". \u{1F30E}"),Mg.forEach(t),Jb=h(Re),Kr=r(Re,"LI",{});var $g=a(Kr);zb=s($g,"A notebook on how to "),ea=r($g,"A",{href:!0,rel:!0});var WB=a(ea);Ub=s(WB,"finetune DistilBERT for text classification in TensorFlow"),WB.forEach(t),Ib=s($g,". \u{1F30E}"),$g.forEach(t),Wb=h(Re),go=r(Re,"LI",{});var Qd=a(go);ic=r(Qd,"A",{href:!0});var AB=a(ic);Ab=s(AB,"DistilBertForSequenceClassification"),AB.forEach(t),Nb=s(Qd," is supported by this "),ta=r(Qd,"A",{href:!0,rel:!0});var NB=a(ta);Rb=s(NB,"example script"),NB.forEach(t),Zb=s(Qd," and "),oa=r(Qd,"A",{href:!0,rel:!0});var RB=a(oa);Gb=s(RB,"notebook"),RB.forEach(t),qb=s(Qd,"."),Qd.forEach(t),Xb=h(Re),_o=r(Re,"LI",{});var Od=a(_o);dc=r(Od,"A",{href:!0});var ZB=a(dc);Pb=s(ZB,"TFDistilBertForSequenceClassification"),ZB.forEach(t),Vb=s(Od," is supported by this "),sa=r(Od,"A",{href:!0,rel:!0});var GB=a(sa);Sb=s(GB,"example script"),GB.forEach(t),Lb=s(Od," and "),na=r(Od,"A",{href:!0,rel:!0});var qB=a(na);Qb=s(qB,"notebook"),qB.forEach(t),Ob=s(Od,"."),Od.forEach(t),Hb=h(Re),bo=r(Re,"LI",{});var Hd=a(bo);cc=r(Hd,"A",{href:!0});var XB=a(cc);Yb=s(XB,"FlaxDistilBertForSequenceClassification"),XB.forEach(t),Kb=s(Hd," is supported by this "),ra=r(Hd,"A",{href:!0,rel:!0});var PB=a(ra);ev=s(PB,"example script"),PB.forEach(t),tv=s(Hd," and "),aa=r(Hd,"A",{href:!0,rel:!0});var VB=a(aa);ov=s(VB,"notebook"),VB.forEach(t),sv=s(Hd,"."),Hd.forEach(t),nv=h(Re),Kp=r(Re,"LI",{});var SB=a(Kp);pc=r(SB,"A",{href:!0});var LB=a(pc);rv=s(LB,"Text classification task guide"),LB.forEach(t),SB.forEach(t),Re.forEach(t),vm=h(l),T(la.$$.fragment,l),ym=h(l),wt=r(l,"UL",{});var Jo=a(wt);vo=r(Jo,"LI",{});var Yd=a(vo);hc=r(Yd,"A",{href:!0});var QB=a(hc);av=s(QB,"DistilBertForTokenClassification"),QB.forEach(t),lv=s(Yd," is supported by this "),ia=r(Yd,"A",{href:!0,rel:!0});var OB=a(ia);iv=s(OB,"example script"),OB.forEach(t),dv=s(Yd," and "),da=r(Yd,"A",{href:!0,rel:!0});var HB=a(da);cv=s(HB,"notebook"),HB.forEach(t),pv=s(Yd,"."),Yd.forEach(t),hv=h(Jo),yo=r(Jo,"LI",{});var Kd=a(yo);uc=r(Kd,"A",{href:!0});var YB=a(uc);uv=s(YB,"TFDistilBertForTokenClassification"),YB.forEach(t),fv=s(Kd," is supported by this "),ca=r(Kd,"A",{href:!0,rel:!0});var KB=a(ca);mv=s(KB,"example script"),KB.forEach(t),gv=s(Kd," and "),pa=r(Kd,"A",{href:!0,rel:!0});var e3=a(pa);_v=s(e3,"notebook"),e3.forEach(t),bv=s(Kd,"."),Kd.forEach(t),vv=h(Jo),Xs=r(Jo,"LI",{});var hm=a(Xs);fc=r(hm,"A",{href:!0});var t3=a(fc);yv=s(t3,"FlaxDistilBertForTokenClassification"),t3.forEach(t),wv=s(hm," is supported by this "),ha=r(hm,"A",{href:!0,rel:!0});var o3=a(ha);Tv=s(o3,"example script"),o3.forEach(t),kv=s(hm,"."),hm.forEach(t),Mv=h(Jo),mc=r(Jo,"LI",{});var $B=a(mc);ua=r($B,"A",{href:!0,rel:!0});var s3=a(ua);$v=s(s3,"Token classification"),s3.forEach(t),Ev=s($B," chapter of the \u{1F917} Hugging Face Course."),$B.forEach(t),Fv=h(Jo),eh=r(Jo,"LI",{});var n3=a(eh);gc=r(n3,"A",{href:!0});var r3=a(gc);Bv=s(r3,"Token classification task guide"),r3.forEach(t),n3.forEach(t),Jo.forEach(t),wm=h(l),T(fa.$$.fragment,l),Tm=h(l),Tt=r(l,"UL",{});var zo=a(Tt);wo=r(zo,"LI",{});var ec=a(wo);_c=r(ec,"A",{href:!0});var a3=a(_c);jv=s(a3,"DistilBertForMaskedLM"),a3.forEach(t),Dv=s(ec," is supported by this "),ma=r(ec,"A",{href:!0,rel:!0});var l3=a(ma);xv=s(l3,"example script"),l3.forEach(t),Cv=s(ec," and "),ga=r(ec,"A",{href:!0,rel:!0});var i3=a(ga);Jv=s(i3,"notebook"),i3.forEach(t),zv=s(ec,"."),ec.forEach(t),Uv=h(zo),To=r(zo,"LI",{});var tc=a(To);bc=r(tc,"A",{href:!0});var d3=a(bc);Iv=s(d3,"TFDistilBertForMaskedLM"),d3.forEach(t),Wv=s(tc," is supported by this "),_a=r(tc,"A",{href:!0,rel:!0});var c3=a(_a);Av=s(c3,"example script"),c3.forEach(t),Nv=s(tc," and "),ba=r(tc,"A",{href:!0,rel:!0});var p3=a(ba);Rv=s(p3,"notebook"),p3.forEach(t),Zv=s(tc,"."),tc.forEach(t),Gv=h(zo),ko=r(zo,"LI",{});var oc=a(ko);vc=r(oc,"A",{href:!0});var h3=a(vc);qv=s(h3,"FlaxDistilBertForMaskedLM"),h3.forEach(t),Xv=s(oc," is supported by this "),va=r(oc,"A",{href:!0,rel:!0});var u3=a(va);Pv=s(u3,"example script"),u3.forEach(t),Vv=s(oc," and "),ya=r(oc,"A",{href:!0,rel:!0});var f3=a(ya);Sv=s(f3,"notebook"),f3.forEach(t),Lv=s(oc,"."),oc.forEach(t),Qv=h(zo),yc=r(zo,"LI",{});var EB=a(yc);wa=r(EB,"A",{href:!0,rel:!0});var m3=a(wa);Ov=s(m3,"Masked language modeling"),m3.forEach(t),Hv=s(EB," chapter of the \u{1F917} Hugging Face Course."),EB.forEach(t),Yv=h(zo),th=r(zo,"LI",{});var g3=a(th);wc=r(g3,"A",{href:!0});var _3=a(wc);Kv=s(_3,"Masked language modeling task guide"),_3.forEach(t),g3.forEach(t),zo.forEach(t),km=h(l),T(Ta.$$.fragment,l),Mm=h(l),kt=r(l,"UL",{});var Uo=a(kt);Mo=r(Uo,"LI",{});var sc=a(Mo);Tc=r(sc,"A",{href:!0});var b3=a(Tc);ey=s(b3,"DistilBertForQuestionAnswering"),b3.forEach(t),ty=s(sc," is supported by this "),ka=r(sc,"A",{href:!0,rel:!0});var v3=a(ka);oy=s(v3,"example script"),v3.forEach(t),sy=s(sc," and "),Ma=r(sc,"A",{href:!0,rel:!0});var y3=a(Ma);ny=s(y3,"notebook"),y3.forEach(t),ry=s(sc,"."),sc.forEach(t),ay=h(Uo),$o=r(Uo,"LI",{});var nc=a($o);kc=r(nc,"A",{href:!0});var w3=a(kc);ly=s(w3,"TFDistilBertForQuestionAnswering"),w3.forEach(t),iy=s(nc," is supported by this "),$a=r(nc,"A",{href:!0,rel:!0});var T3=a($a);dy=s(T3,"example script"),T3.forEach(t),cy=s(nc," and "),Ea=r(nc,"A",{href:!0,rel:!0});var k3=a(Ea);py=s(k3,"notebook"),k3.forEach(t),hy=s(nc,"."),nc.forEach(t),uy=h(Uo),Ps=r(Uo,"LI",{});var um=a(Ps);Mc=r(um,"A",{href:!0});var M3=a(Mc);fy=s(M3,"FlaxDistilBertForQuestionAnswering"),M3.forEach(t),my=s(um," is supported by this "),Fa=r(um,"A",{href:!0,rel:!0});var $3=a(Fa);gy=s($3,"example script"),$3.forEach(t),_y=s(um,"."),um.forEach(t),by=h(Uo),$c=r(Uo,"LI",{});var FB=a($c);Ba=r(FB,"A",{href:!0,rel:!0});var E3=a(Ba);vy=s(E3,"Question answering"),E3.forEach(t),yy=s(FB," chapter of the \u{1F917} Hugging Face Course."),FB.forEach(t),wy=h(Uo),oh=r(Uo,"LI",{});var F3=a(oh);Ec=r(F3,"A",{href:!0});var B3=a(Ec);Ty=s(B3,"Question answering task guide"),B3.forEach(t),F3.forEach(t),Uo.forEach(t),$m=h(l),Fc=r(l,"P",{});var j3=a(Fc);sh=r(j3,"STRONG",{});var D3=a(sh);ky=s(D3,"Multiple choice"),D3.forEach(t),j3.forEach(t),Em=h(l),Eo=r(l,"UL",{});var yp=a(Eo);Fo=r(yp,"LI",{});var rc=a(Fo);Bc=r(rc,"A",{href:!0});var x3=a(Bc);My=s(x3,"DistilBertForMultipleChoice"),x3.forEach(t),$y=s(rc," is supported by this "),ja=r(rc,"A",{href:!0,rel:!0});var C3=a(ja);Ey=s(C3,"example script"),C3.forEach(t),Fy=s(rc," and "),Da=r(rc,"A",{href:!0,rel:!0});var J3=a(Da);By=s(J3,"notebook"),J3.forEach(t),jy=s(rc,"."),rc.forEach(t),Dy=h(yp),Bo=r(yp,"LI",{});var ac=a(Bo);jc=r(ac,"A",{href:!0});var z3=a(jc);xy=s(z3,"TFDistilBertForMultipleChoice"),z3.forEach(t),Cy=s(ac," is supported by this "),xa=r(ac,"A",{href:!0,rel:!0});var U3=a(xa);Jy=s(U3,"example script"),U3.forEach(t),zy=s(ac," and "),Ca=r(ac,"A",{href:!0,rel:!0});var I3=a(Ca);Uy=s(I3,"notebook"),I3.forEach(t),Iy=s(ac,"."),ac.forEach(t),Wy=h(yp),nh=r(yp,"LI",{});var W3=a(nh);Dc=r(W3,"A",{href:!0});var A3=a(Dc);Ay=s(A3,"Multiple choice task guide"),A3.forEach(t),W3.forEach(t),yp.forEach(t),Fm=h(l),xc=r(l,"P",{});var N3=a(xc);Ny=s(N3,"\u2697\uFE0F Optimization"),N3.forEach(t),Bm=h(l),jo=r(l,"UL",{});var wp=a(jo);Ja=r(wp,"LI",{});var Eg=a(Ja);Ry=s(Eg,"A blog post on how to "),za=r(Eg,"A",{href:!0,rel:!0});var R3=a(za);Zy=s(R3,"quantize DistilBERT with \u{1F917} Optimum and Intel"),R3.forEach(t),Gy=s(Eg,"."),Eg.forEach(t),qy=h(wp),Ua=r(wp,"LI",{});var Fg=a(Ua);Xy=s(Fg,"A blog post on how "),Ia=r(Fg,"A",{href:!0,rel:!0});var Z3=a(Ia);Py=s(Z3,"Optimizing Transformers for GPUs with \u{1F917} Optimum"),Z3.forEach(t),Vy=s(Fg,"."),Fg.forEach(t),Sy=h(wp),Wa=r(wp,"LI",{});var Bg=a(Wa);Ly=s(Bg,"A blog post on "),Aa=r(Bg,"A",{href:!0,rel:!0});var G3=a(Aa);Qy=s(G3,"Optimizing Transformers with Hugging Face Optimum"),G3.forEach(t),Oy=s(Bg,"."),Bg.forEach(t),wp.forEach(t),jm=h(l),Cc=r(l,"P",{});var q3=a(Cc);Hy=s(q3,"\u26A1\uFE0F Inference"),q3.forEach(t),Dm=h(l),Vs=r(l,"UL",{});var jg=a(Vs);Na=r(jg,"LI",{});var Dg=a(Na);Yy=s(Dg,"A blog post on how to "),Ra=r(Dg,"A",{href:!0,rel:!0});var X3=a(Ra);Ky=s(X3,"Accelerate BERT inference with Hugging Face Transformers and AWS Inferentia"),X3.forEach(t),ew=s(Dg," with DistilBERT."),Dg.forEach(t),tw=h(jg),Za=r(jg,"LI",{});var xg=a(Za);ow=s(xg,"A blog post on "),Ga=r(xg,"A",{href:!0,rel:!0});var P3=a(Ga);sw=s(P3,"Serverless Inference with Hugging Face\u2019s Transformers, DistilBERT and Amazon SageMaker"),P3.forEach(t),nw=s(xg,"."),xg.forEach(t),jg.forEach(t),xm=h(l),Jc=r(l,"P",{});var V3=a(Jc);rw=s(V3,"\u{1F680} Deploy"),V3.forEach(t),Cm=h(l),Do=r(l,"UL",{});var Tp=a(Do);qa=r(Tp,"LI",{});var Cg=a(qa);aw=s(Cg,"A blog post on how to "),Xa=r(Cg,"A",{href:!0,rel:!0});var S3=a(Xa);lw=s(S3,"deploy DistilBERT on Google Cloud"),S3.forEach(t),iw=s(Cg,"."),Cg.forEach(t),dw=h(Tp),Pa=r(Tp,"LI",{});var Jg=a(Pa);cw=s(Jg,"A blog post on how to "),Va=r(Jg,"A",{href:!0,rel:!0});var L3=a(Va);pw=s(L3,"deploy DistilBERT with Amazon SageMaker"),L3.forEach(t),hw=s(Jg,"."),Jg.forEach(t),uw=h(Tp),Sa=r(Tp,"LI",{});var zg=a(Sa);fw=s(zg,"A blog post on how to "),La=r(zg,"A",{href:!0,rel:!0});var Q3=a(La);mw=s(Q3,"Deploy BERT with Hugging Face Transformers, Amazon SageMaker and Terraform module"),Q3.forEach(t),gw=s(zg,"."),zg.forEach(t),Tp.forEach(t),Jm=h(l),Qo=r(l,"H2",{class:!0});var Ug=a(Qo);Ss=r(Ug,"A",{id:!0,class:!0,href:!0});var O3=a(Ss);rh=r(O3,"SPAN",{});var H3=a(rh);T(Qa.$$.fragment,H3),H3.forEach(t),O3.forEach(t),_w=h(Ug),ah=r(Ug,"SPAN",{});var Y3=a(ah);bw=s(Y3,"DistilBertConfig"),Y3.forEach(t),Ug.forEach(t),zm=h(l),It=r(l,"DIV",{class:!0});var ur=a(It);T(Oa.$$.fragment,ur),vw=h(ur),ro=r(ur,"P",{});var fr=a(ro);yw=s(fr,"This is the configuration class to store the configuration of a "),zc=r(fr,"A",{href:!0});var K3=a(zc);ww=s(K3,"DistilBertModel"),K3.forEach(t),Tw=s(fr," or a "),Uc=r(fr,"A",{href:!0});var e4=a(Uc);kw=s(e4,"TFDistilBertModel"),e4.forEach(t),Mw=s(fr,`. 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
`),Ha=r(fr,"A",{href:!0,rel:!0});var t4=a(Ha);$w=s(t4,"distilbert-base-uncased"),t4.forEach(t),Ew=s(fr," architecture."),fr.forEach(t),Fw=h(ur),Oo=r(ur,"P",{});var kp=a(Oo);Bw=s(kp,"Configuration objects inherit from "),Ic=r(kp,"A",{href:!0});var o4=a(Ic);jw=s(o4,"PretrainedConfig"),o4.forEach(t),Dw=s(kp,` and can be used to control the model outputs. Read the
documentation from `),Wc=r(kp,"A",{href:!0});var s4=a(Wc);xw=s(s4,"PretrainedConfig"),s4.forEach(t),Cw=s(kp," for more information."),kp.forEach(t),Jw=h(ur),T(Ls.$$.fragment,ur),ur.forEach(t),Um=h(l),Ho=r(l,"H2",{class:!0});var Ig=a(Ho);Qs=r(Ig,"A",{id:!0,class:!0,href:!0});var n4=a(Qs);lh=r(n4,"SPAN",{});var r4=a(lh);T(Ya.$$.fragment,r4),r4.forEach(t),n4.forEach(t),zw=h(Ig),ih=r(Ig,"SPAN",{});var a4=a(ih);Uw=s(a4,"DistilBertTokenizer"),a4.forEach(t),Ig.forEach(t),Im=h(l),tt=r(l,"DIV",{class:!0});var jt=a(tt);T(Ka.$$.fragment,jt),Iw=h(jt),dh=r(jt,"P",{});var l4=a(dh);Ww=s(l4,"Construct a DistilBERT tokenizer. Based on WordPiece."),l4.forEach(t),Aw=h(jt),el=r(jt,"P",{});var Wg=a(el);Nw=s(Wg,"This tokenizer inherits from "),Ac=r(Wg,"A",{href:!0});var i4=a(Ac);Rw=s(i4,"PreTrainedTokenizer"),i4.forEach(t),Zw=s(Wg,` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Wg.forEach(t),Gw=h(jt),xo=r(jt,"DIV",{class:!0});var Mp=a(xo);T(tl.$$.fragment,Mp),qw=h(Mp),ch=r(Mp,"P",{});var d4=a(ch);Xw=s(d4,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A BERT sequence has the following format:`),d4.forEach(t),Pw=h(Mp),ol=r(Mp,"UL",{});var Ag=a(ol);Nc=r(Ag,"LI",{});var BB=a(Nc);Vw=s(BB,"single sequence: "),ph=r(BB,"CODE",{});var c4=a(ph);Sw=s(c4,"[CLS] X [SEP]"),c4.forEach(t),BB.forEach(t),Lw=h(Ag),Rc=r(Ag,"LI",{});var jB=a(Rc);Qw=s(jB,"pair of sequences: "),hh=r(jB,"CODE",{});var p4=a(hh);Ow=s(p4,"[CLS] A [SEP] B [SEP]"),p4.forEach(t),jB.forEach(t),Ag.forEach(t),Mp.forEach(t),Hw=h(jt),Os=r(jt,"DIV",{class:!0});var Ng=a(Os);T(sl.$$.fragment,Ng),Yw=h(Ng),uh=r(Ng,"P",{});var h4=a(uh);Kw=s(h4,"Converts a sequence of tokens (string) in a single string."),h4.forEach(t),Ng.forEach(t),eT=h(jt),At=r(jt,"DIV",{class:!0});var mr=a(At);T(nl.$$.fragment,mr),tT=h(mr),fh=r(mr,"P",{});var u4=a(fh);oT=s(u4,"Create a mask from the two sequences passed to be used in a sequence-pair classification task. A BERT sequence"),u4.forEach(t),sT=h(mr),T(Hs.$$.fragment,mr),nT=h(mr),Yo=r(mr,"P",{});var $p=a(Yo);rT=s($p,"If "),mh=r($p,"CODE",{});var f4=a(mh);aT=s(f4,"token_ids_1"),f4.forEach(t),lT=s($p," is "),gh=r($p,"CODE",{});var m4=a(gh);iT=s(m4,"None"),m4.forEach(t),dT=s($p,", this method only returns the first portion of the mask (0s)."),$p.forEach(t),mr.forEach(t),cT=h(jt),Ys=r(jt,"DIV",{class:!0});var Rg=a(Ys);T(rl.$$.fragment,Rg),pT=h(Rg),al=r(Rg,"P",{});var Zg=a(al);hT=s(Zg,`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),_h=r(Zg,"CODE",{});var g4=a(_h);uT=s(g4,"prepare_for_model"),g4.forEach(t),fT=s(Zg," method."),Zg.forEach(t),Rg.forEach(t),jt.forEach(t),Wm=h(l),Ko=r(l,"H2",{class:!0});var Gg=a(Ko);Ks=r(Gg,"A",{id:!0,class:!0,href:!0});var _4=a(Ks);bh=r(_4,"SPAN",{});var b4=a(bh);T(ll.$$.fragment,b4),b4.forEach(t),_4.forEach(t),mT=h(Gg),vh=r(Gg,"SPAN",{});var v4=a(vh);gT=s(v4,"DistilBertTokenizerFast"),v4.forEach(t),Gg.forEach(t),Am=h(l),ft=r(l,"DIV",{class:!0});var Io=a(ft);T(il.$$.fragment,Io),_T=h(Io),dl=r(Io,"P",{});var qg=a(dl);bT=s(qg,"Construct a \u201Cfast\u201D DistilBERT tokenizer (backed by HuggingFace\u2019s "),yh=r(qg,"EM",{});var y4=a(yh);vT=s(y4,"tokenizers"),y4.forEach(t),yT=s(qg," library). Based on WordPiece."),qg.forEach(t),wT=h(Io),cl=r(Io,"P",{});var Xg=a(cl);TT=s(Xg,"This tokenizer inherits from "),Zc=r(Xg,"A",{href:!0});var w4=a(Zc);kT=s(w4,"PreTrainedTokenizerFast"),w4.forEach(t),MT=s(Xg,` which contains most of the main methods. Users should
refer to this superclass for more information regarding those methods.`),Xg.forEach(t),$T=h(Io),Co=r(Io,"DIV",{class:!0});var Ep=a(Co);T(pl.$$.fragment,Ep),ET=h(Ep),wh=r(Ep,"P",{});var T4=a(wh);FT=s(T4,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. A BERT sequence has the following format:`),T4.forEach(t),BT=h(Ep),hl=r(Ep,"UL",{});var Pg=a(hl);Gc=r(Pg,"LI",{});var DB=a(Gc);jT=s(DB,"single sequence: "),Th=r(DB,"CODE",{});var k4=a(Th);DT=s(k4,"[CLS] X [SEP]"),k4.forEach(t),DB.forEach(t),xT=h(Pg),qc=r(Pg,"LI",{});var xB=a(qc);CT=s(xB,"pair of sequences: "),kh=r(xB,"CODE",{});var M4=a(kh);JT=s(M4,"[CLS] A [SEP] B [SEP]"),M4.forEach(t),xB.forEach(t),Pg.forEach(t),Ep.forEach(t),zT=h(Io),Nt=r(Io,"DIV",{class:!0});var gr=a(Nt);T(ul.$$.fragment,gr),UT=h(gr),Mh=r(gr,"P",{});var $4=a(Mh);IT=s($4,"Create a mask from the two sequences passed to be used in a sequence-pair classification task. A BERT sequence"),$4.forEach(t),WT=h(gr),T(en.$$.fragment,gr),AT=h(gr),es=r(gr,"P",{});var Fp=a(es);NT=s(Fp,"If "),$h=r(Fp,"CODE",{});var E4=a($h);RT=s(E4,"token_ids_1"),E4.forEach(t),ZT=s(Fp," is "),Eh=r(Fp,"CODE",{});var F4=a(Eh);GT=s(F4,"None"),F4.forEach(t),qT=s(Fp,", this method only returns the first portion of the mask (0s)."),Fp.forEach(t),gr.forEach(t),Io.forEach(t),Nm=h(l),ts=r(l,"H2",{class:!0});var Vg=a(ts);tn=r(Vg,"A",{id:!0,class:!0,href:!0});var B4=a(tn);Fh=r(B4,"SPAN",{});var j4=a(Fh);T(fl.$$.fragment,j4),j4.forEach(t),B4.forEach(t),XT=h(Vg),Bh=r(Vg,"SPAN",{});var D4=a(Bh);PT=s(D4,"DistilBertModel"),D4.forEach(t),Vg.forEach(t),Rm=h(l),mt=r(l,"DIV",{class:!0});var Wo=a(mt);T(ml.$$.fragment,Wo),VT=h(Wo),jh=r(Wo,"P",{});var x4=a(jh);ST=s(x4,"The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),x4.forEach(t),LT=h(Wo),gl=r(Wo,"P",{});var Sg=a(gl);QT=s(Sg,"This model inherits from "),Xc=r(Sg,"A",{href:!0});var C4=a(Xc);OT=s(C4,"PreTrainedModel"),C4.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),YT=h(Wo),_l=r(Wo,"P",{});var Lg=a(_l);KT=s(Lg,"This model is also a PyTorch "),bl=r(Lg,"A",{href:!0,rel:!0});var J4=a(bl);ek=s(J4,"torch.nn.Module"),J4.forEach(t),tk=s(Lg,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Lg.forEach(t),ok=h(Wo),Rt=r(Wo,"DIV",{class:!0});var _r=a(Rt);T(vl.$$.fragment,_r),sk=h(_r),os=r(_r,"P",{});var Bp=a(os);nk=s(Bp,"The "),Pc=r(Bp,"A",{href:!0});var z4=a(Pc);rk=s(z4,"DistilBertModel"),z4.forEach(t),ak=s(Bp," forward method, overrides the "),Dh=r(Bp,"CODE",{});var U4=a(Dh);lk=s(U4,"__call__"),U4.forEach(t),ik=s(Bp," special method."),Bp.forEach(t),dk=h(_r),T(on.$$.fragment,_r),ck=h(_r),T(sn.$$.fragment,_r),_r.forEach(t),Wo.forEach(t),Zm=h(l),ss=r(l,"H2",{class:!0});var Qg=a(ss);nn=r(Qg,"A",{id:!0,class:!0,href:!0});var I4=a(nn);xh=r(I4,"SPAN",{});var W4=a(xh);T(yl.$$.fragment,W4),W4.forEach(t),I4.forEach(t),pk=h(Qg),Ch=r(Qg,"SPAN",{});var A4=a(Ch);hk=s(A4,"DistilBertForMaskedLM"),A4.forEach(t),Qg.forEach(t),Gm=h(l),gt=r(l,"DIV",{class:!0});var Ao=a(gt);T(wl.$$.fragment,Ao),uk=h(Ao),Tl=r(Ao,"P",{});var Og=a(Tl);fk=s(Og,"DistilBert Model with a "),Jh=r(Og,"CODE",{});var N4=a(Jh);mk=s(N4,"masked language modeling"),N4.forEach(t),gk=s(Og," head on top."),Og.forEach(t),_k=h(Ao),kl=r(Ao,"P",{});var Hg=a(kl);bk=s(Hg,"This model inherits from "),Vc=r(Hg,"A",{href:!0});var R4=a(Vc);vk=s(R4,"PreTrainedModel"),R4.forEach(t),yk=s(Hg,`. 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.)`),Hg.forEach(t),wk=h(Ao),Ml=r(Ao,"P",{});var Yg=a(Ml);Tk=s(Yg,"This model is also a PyTorch "),$l=r(Yg,"A",{href:!0,rel:!0});var Z4=a($l);kk=s(Z4,"torch.nn.Module"),Z4.forEach(t),Mk=s(Yg,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Yg.forEach(t),$k=h(Ao),Zt=r(Ao,"DIV",{class:!0});var br=a(Zt);T(El.$$.fragment,br),Ek=h(br),ns=r(br,"P",{});var jp=a(ns);Fk=s(jp,"The "),Sc=r(jp,"A",{href:!0});var G4=a(Sc);Bk=s(G4,"DistilBertForMaskedLM"),G4.forEach(t),jk=s(jp," forward method, overrides the "),zh=r(jp,"CODE",{});var q4=a(zh);Dk=s(q4,"__call__"),q4.forEach(t),xk=s(jp," special method."),jp.forEach(t),Ck=h(br),T(rn.$$.fragment,br),Jk=h(br),T(an.$$.fragment,br),br.forEach(t),Ao.forEach(t),qm=h(l),rs=r(l,"H2",{class:!0});var Kg=a(rs);ln=r(Kg,"A",{id:!0,class:!0,href:!0});var X4=a(ln);Uh=r(X4,"SPAN",{});var P4=a(Uh);T(Fl.$$.fragment,P4),P4.forEach(t),X4.forEach(t),zk=h(Kg),Ih=r(Kg,"SPAN",{});var V4=a(Ih);Uk=s(V4,"DistilBertForSequenceClassification"),V4.forEach(t),Kg.forEach(t),Xm=h(l),_t=r(l,"DIV",{class:!0});var No=a(_t);T(Bl.$$.fragment,No),Ik=h(No),Wh=r(No,"P",{});var S4=a(Wh);Wk=s(S4,`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.`),S4.forEach(t),Ak=h(No),jl=r(No,"P",{});var e_=a(jl);Nk=s(e_,"This model inherits from "),Lc=r(e_,"A",{href:!0});var L4=a(Lc);Rk=s(L4,"PreTrainedModel"),L4.forEach(t),Zk=s(e_,`. 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.)`),e_.forEach(t),Gk=h(No),Dl=r(No,"P",{});var t_=a(Dl);qk=s(t_,"This model is also a PyTorch "),xl=r(t_,"A",{href:!0,rel:!0});var Q4=a(xl);Xk=s(Q4,"torch.nn.Module"),Q4.forEach(t),Pk=s(t_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),t_.forEach(t),Vk=h(No),Mt=r(No,"DIV",{class:!0});var Ro=a(Mt);T(Cl.$$.fragment,Ro),Sk=h(Ro),as=r(Ro,"P",{});var Dp=a(as);Lk=s(Dp,"The "),Qc=r(Dp,"A",{href:!0});var O4=a(Qc);Qk=s(O4,"DistilBertForSequenceClassification"),O4.forEach(t),Ok=s(Dp," forward method, overrides the "),Ah=r(Dp,"CODE",{});var H4=a(Ah);Hk=s(H4,"__call__"),H4.forEach(t),Yk=s(Dp," special method."),Dp.forEach(t),Kk=h(Ro),T(dn.$$.fragment,Ro),eM=h(Ro),T(cn.$$.fragment,Ro),tM=h(Ro),T(pn.$$.fragment,Ro),Ro.forEach(t),No.forEach(t),Pm=h(l),ls=r(l,"H2",{class:!0});var o_=a(ls);hn=r(o_,"A",{id:!0,class:!0,href:!0});var Y4=a(hn);Nh=r(Y4,"SPAN",{});var K4=a(Nh);T(Jl.$$.fragment,K4),K4.forEach(t),Y4.forEach(t),oM=h(o_),Rh=r(o_,"SPAN",{});var ej=a(Rh);sM=s(ej,"DistilBertForMultipleChoice"),ej.forEach(t),o_.forEach(t),Vm=h(l),bt=r(l,"DIV",{class:!0});var Zo=a(bt);T(zl.$$.fragment,Zo),nM=h(Zo),Zh=r(Zo,"P",{});var tj=a(Zh);rM=s(tj,`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.`),tj.forEach(t),aM=h(Zo),Ul=r(Zo,"P",{});var s_=a(Ul);lM=s(s_,"This model inherits from "),Oc=r(s_,"A",{href:!0});var oj=a(Oc);iM=s(oj,"PreTrainedModel"),oj.forEach(t),dM=s(s_,`. 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.)`),s_.forEach(t),cM=h(Zo),Il=r(Zo,"P",{});var n_=a(Il);pM=s(n_,"This model is also a PyTorch "),Wl=r(n_,"A",{href:!0,rel:!0});var sj=a(Wl);hM=s(sj,"torch.nn.Module"),sj.forEach(t),uM=s(n_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),n_.forEach(t),fM=h(Zo),Gt=r(Zo,"DIV",{class:!0});var vr=a(Gt);T(Al.$$.fragment,vr),mM=h(vr),is=r(vr,"P",{});var xp=a(is);gM=s(xp,"The "),Hc=r(xp,"A",{href:!0});var nj=a(Hc);_M=s(nj,"DistilBertForMultipleChoice"),nj.forEach(t),bM=s(xp," forward method, overrides the "),Gh=r(xp,"CODE",{});var rj=a(Gh);vM=s(rj,"__call__"),rj.forEach(t),yM=s(xp," special method."),xp.forEach(t),wM=h(vr),T(un.$$.fragment,vr),TM=h(vr),T(fn.$$.fragment,vr),vr.forEach(t),Zo.forEach(t),Sm=h(l),ds=r(l,"H2",{class:!0});var r_=a(ds);mn=r(r_,"A",{id:!0,class:!0,href:!0});var aj=a(mn);qh=r(aj,"SPAN",{});var lj=a(qh);T(Nl.$$.fragment,lj),lj.forEach(t),aj.forEach(t),kM=h(r_),Xh=r(r_,"SPAN",{});var ij=a(Xh);MM=s(ij,"DistilBertForTokenClassification"),ij.forEach(t),r_.forEach(t),Lm=h(l),vt=r(l,"DIV",{class:!0});var Go=a(vt);T(Rl.$$.fragment,Go),$M=h(Go),Ph=r(Go,"P",{});var dj=a(Ph);EM=s(dj,`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.`),dj.forEach(t),FM=h(Go),Zl=r(Go,"P",{});var a_=a(Zl);BM=s(a_,"This model inherits from "),Yc=r(a_,"A",{href:!0});var cj=a(Yc);jM=s(cj,"PreTrainedModel"),cj.forEach(t),DM=s(a_,`. 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_.forEach(t),xM=h(Go),Gl=r(Go,"P",{});var l_=a(Gl);CM=s(l_,"This model is also a PyTorch "),ql=r(l_,"A",{href:!0,rel:!0});var pj=a(ql);JM=s(pj,"torch.nn.Module"),pj.forEach(t),zM=s(l_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),l_.forEach(t),UM=h(Go),qt=r(Go,"DIV",{class:!0});var yr=a(qt);T(Xl.$$.fragment,yr),IM=h(yr),cs=r(yr,"P",{});var Cp=a(cs);WM=s(Cp,"The "),Kc=r(Cp,"A",{href:!0});var hj=a(Kc);AM=s(hj,"DistilBertForTokenClassification"),hj.forEach(t),NM=s(Cp," forward method, overrides the "),Vh=r(Cp,"CODE",{});var uj=a(Vh);RM=s(uj,"__call__"),uj.forEach(t),ZM=s(Cp," special method."),Cp.forEach(t),GM=h(yr),T(gn.$$.fragment,yr),qM=h(yr),T(_n.$$.fragment,yr),yr.forEach(t),Go.forEach(t),Qm=h(l),ps=r(l,"H2",{class:!0});var i_=a(ps);bn=r(i_,"A",{id:!0,class:!0,href:!0});var fj=a(bn);Sh=r(fj,"SPAN",{});var mj=a(Sh);T(Pl.$$.fragment,mj),mj.forEach(t),fj.forEach(t),XM=h(i_),Lh=r(i_,"SPAN",{});var gj=a(Lh);PM=s(gj,"DistilBertForQuestionAnswering"),gj.forEach(t),i_.forEach(t),Om=h(l),yt=r(l,"DIV",{class:!0});var qo=a(yt);T(Vl.$$.fragment,qo),VM=h(qo),hs=r(qo,"P",{});var Jp=a(hs);SM=s(Jp,`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 `),Qh=r(Jp,"CODE",{});var _j=a(Qh);LM=s(_j,"span start logits"),_j.forEach(t),QM=s(Jp," and "),Oh=r(Jp,"CODE",{});var bj=a(Oh);OM=s(bj,"span end logits"),bj.forEach(t),HM=s(Jp,")."),Jp.forEach(t),YM=h(qo),Sl=r(qo,"P",{});var d_=a(Sl);KM=s(d_,"This model inherits from "),ep=r(d_,"A",{href:!0});var vj=a(ep);e2=s(vj,"PreTrainedModel"),vj.forEach(t),t2=s(d_,`. 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.)`),d_.forEach(t),o2=h(qo),Ll=r(qo,"P",{});var c_=a(Ll);s2=s(c_,"This model is also a PyTorch "),Ql=r(c_,"A",{href:!0,rel:!0});var yj=a(Ql);n2=s(yj,"torch.nn.Module"),yj.forEach(t),r2=s(c_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),c_.forEach(t),a2=h(qo),Xt=r(qo,"DIV",{class:!0});var wr=a(Xt);T(Ol.$$.fragment,wr),l2=h(wr),us=r(wr,"P",{});var zp=a(us);i2=s(zp,"The "),tp=r(zp,"A",{href:!0});var wj=a(tp);d2=s(wj,"DistilBertForQuestionAnswering"),wj.forEach(t),c2=s(zp," forward method, overrides the "),Hh=r(zp,"CODE",{});var Tj=a(Hh);p2=s(Tj,"__call__"),Tj.forEach(t),h2=s(zp," special method."),zp.forEach(t),u2=h(wr),T(vn.$$.fragment,wr),f2=h(wr),T(yn.$$.fragment,wr),wr.forEach(t),qo.forEach(t),Hm=h(l),fs=r(l,"H2",{class:!0});var p_=a(fs);wn=r(p_,"A",{id:!0,class:!0,href:!0});var kj=a(wn);Yh=r(kj,"SPAN",{});var Mj=a(Yh);T(Hl.$$.fragment,Mj),Mj.forEach(t),kj.forEach(t),m2=h(p_),Kh=r(p_,"SPAN",{});var $j=a(Kh);g2=s($j,"TFDistilBertModel"),$j.forEach(t),p_.forEach(t),Ym=h(l),it=r(l,"DIV",{class:!0});var Kt=a(it);T(Yl.$$.fragment,Kt),_2=h(Kt),eu=r(Kt,"P",{});var Ej=a(eu);b2=s(Ej,"The bare DistilBERT encoder/transformer outputting raw hidden-states without any specific head on top."),Ej.forEach(t),v2=h(Kt),Kl=r(Kt,"P",{});var h_=a(Kl);y2=s(h_,"This model inherits from "),op=r(h_,"A",{href:!0});var Fj=a(op);w2=s(Fj,"TFPreTrainedModel"),Fj.forEach(t),T2=s(h_,`. 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.)`),h_.forEach(t),k2=h(Kt),ei=r(Kt,"P",{});var u_=a(ei);M2=s(u_,"This model is also a "),ti=r(u_,"A",{href:!0,rel:!0});var Bj=a(ti);$2=s(Bj,"tf.keras.Model"),Bj.forEach(t),E2=s(u_,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),u_.forEach(t),F2=h(Kt),T(Tn.$$.fragment,Kt),B2=h(Kt),Pt=r(Kt,"DIV",{class:!0});var Tr=a(Pt);T(oi.$$.fragment,Tr),j2=h(Tr),ms=r(Tr,"P",{});var Up=a(ms);D2=s(Up,"The "),sp=r(Up,"A",{href:!0});var jj=a(sp);x2=s(jj,"TFDistilBertModel"),jj.forEach(t),C2=s(Up," forward method, overrides the "),tu=r(Up,"CODE",{});var Dj=a(tu);J2=s(Dj,"__call__"),Dj.forEach(t),z2=s(Up," special method."),Up.forEach(t),U2=h(Tr),T(kn.$$.fragment,Tr),I2=h(Tr),T(Mn.$$.fragment,Tr),Tr.forEach(t),Kt.forEach(t),Km=h(l),gs=r(l,"H2",{class:!0});var f_=a(gs);$n=r(f_,"A",{id:!0,class:!0,href:!0});var xj=a($n);ou=r(xj,"SPAN",{});var Cj=a(ou);T(si.$$.fragment,Cj),Cj.forEach(t),xj.forEach(t),W2=h(f_),su=r(f_,"SPAN",{});var Jj=a(su);A2=s(Jj,"TFDistilBertForMaskedLM"),Jj.forEach(t),f_.forEach(t),eg=h(l),dt=r(l,"DIV",{class:!0});var eo=a(dt);T(ni.$$.fragment,eo),N2=h(eo),ri=r(eo,"P",{});var m_=a(ri);R2=s(m_,"DistilBert Model with a "),nu=r(m_,"CODE",{});var zj=a(nu);Z2=s(zj,"masked language modeling"),zj.forEach(t),G2=s(m_," head on top."),m_.forEach(t),q2=h(eo),ai=r(eo,"P",{});var g_=a(ai);X2=s(g_,"This model inherits from "),np=r(g_,"A",{href:!0});var Uj=a(np);P2=s(Uj,"TFPreTrainedModel"),Uj.forEach(t),V2=s(g_,`. 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.)`),g_.forEach(t),S2=h(eo),li=r(eo,"P",{});var __=a(li);L2=s(__,"This model is also a "),ii=r(__,"A",{href:!0,rel:!0});var Ij=a(ii);Q2=s(Ij,"tf.keras.Model"),Ij.forEach(t),O2=s(__,` 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.`),__.forEach(t),H2=h(eo),T(En.$$.fragment,eo),Y2=h(eo),$t=r(eo,"DIV",{class:!0});var Xo=a($t);T(di.$$.fragment,Xo),K2=h(Xo),_s=r(Xo,"P",{});var Ip=a(_s);e1=s(Ip,"The "),rp=r(Ip,"A",{href:!0});var Wj=a(rp);t1=s(Wj,"TFDistilBertForMaskedLM"),Wj.forEach(t),o1=s(Ip," forward method, overrides the "),ru=r(Ip,"CODE",{});var Aj=a(ru);s1=s(Aj,"__call__"),Aj.forEach(t),n1=s(Ip," special method."),Ip.forEach(t),r1=h(Xo),T(Fn.$$.fragment,Xo),a1=h(Xo),T(Bn.$$.fragment,Xo),l1=h(Xo),T(jn.$$.fragment,Xo),Xo.forEach(t),eo.forEach(t),tg=h(l),bs=r(l,"H2",{class:!0});var b_=a(bs);Dn=r(b_,"A",{id:!0,class:!0,href:!0});var Nj=a(Dn);au=r(Nj,"SPAN",{});var Rj=a(au);T(ci.$$.fragment,Rj),Rj.forEach(t),Nj.forEach(t),i1=h(b_),lu=r(b_,"SPAN",{});var Zj=a(lu);d1=s(Zj,"TFDistilBertForSequenceClassification"),Zj.forEach(t),b_.forEach(t),og=h(l),ct=r(l,"DIV",{class:!0});var to=a(ct);T(pi.$$.fragment,to),c1=h(to),iu=r(to,"P",{});var Gj=a(iu);p1=s(Gj,`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.`),Gj.forEach(t),h1=h(to),hi=r(to,"P",{});var v_=a(hi);u1=s(v_,"This model inherits from "),ap=r(v_,"A",{href:!0});var qj=a(ap);f1=s(qj,"TFPreTrainedModel"),qj.forEach(t),m1=s(v_,`. 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.)`),v_.forEach(t),g1=h(to),ui=r(to,"P",{});var y_=a(ui);_1=s(y_,"This model is also a "),fi=r(y_,"A",{href:!0,rel:!0});var Xj=a(fi);b1=s(Xj,"tf.keras.Model"),Xj.forEach(t),v1=s(y_,` 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.`),y_.forEach(t),y1=h(to),T(xn.$$.fragment,to),w1=h(to),Et=r(to,"DIV",{class:!0});var Po=a(Et);T(mi.$$.fragment,Po),T1=h(Po),vs=r(Po,"P",{});var Wp=a(vs);k1=s(Wp,"The "),lp=r(Wp,"A",{href:!0});var Pj=a(lp);M1=s(Pj,"TFDistilBertForSequenceClassification"),Pj.forEach(t),$1=s(Wp," forward method, overrides the "),du=r(Wp,"CODE",{});var Vj=a(du);E1=s(Vj,"__call__"),Vj.forEach(t),F1=s(Wp," special method."),Wp.forEach(t),B1=h(Po),T(Cn.$$.fragment,Po),j1=h(Po),T(Jn.$$.fragment,Po),D1=h(Po),T(zn.$$.fragment,Po),Po.forEach(t),to.forEach(t),sg=h(l),ys=r(l,"H2",{class:!0});var w_=a(ys);Un=r(w_,"A",{id:!0,class:!0,href:!0});var Sj=a(Un);cu=r(Sj,"SPAN",{});var Lj=a(cu);T(gi.$$.fragment,Lj),Lj.forEach(t),Sj.forEach(t),x1=h(w_),pu=r(w_,"SPAN",{});var Qj=a(pu);C1=s(Qj,"TFDistilBertForMultipleChoice"),Qj.forEach(t),w_.forEach(t),ng=h(l),pt=r(l,"DIV",{class:!0});var oo=a(pt);T(_i.$$.fragment,oo),J1=h(oo),hu=r(oo,"P",{});var Oj=a(hu);z1=s(Oj,`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.`),Oj.forEach(t),U1=h(oo),bi=r(oo,"P",{});var T_=a(bi);I1=s(T_,"This model inherits from "),ip=r(T_,"A",{href:!0});var Hj=a(ip);W1=s(Hj,"TFPreTrainedModel"),Hj.forEach(t),A1=s(T_,`. 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.)`),T_.forEach(t),N1=h(oo),vi=r(oo,"P",{});var k_=a(vi);R1=s(k_,"This model is also a "),yi=r(k_,"A",{href:!0,rel:!0});var Yj=a(yi);Z1=s(Yj,"tf.keras.Model"),Yj.forEach(t),G1=s(k_,` 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.`),k_.forEach(t),q1=h(oo),T(In.$$.fragment,oo),X1=h(oo),Vt=r(oo,"DIV",{class:!0});var kr=a(Vt);T(wi.$$.fragment,kr),P1=h(kr),ws=r(kr,"P",{});var Ap=a(ws);V1=s(Ap,"The "),dp=r(Ap,"A",{href:!0});var Kj=a(dp);S1=s(Kj,"TFDistilBertForMultipleChoice"),Kj.forEach(t),L1=s(Ap," forward method, overrides the "),uu=r(Ap,"CODE",{});var eD=a(uu);Q1=s(eD,"__call__"),eD.forEach(t),O1=s(Ap," special method."),Ap.forEach(t),H1=h(kr),T(Wn.$$.fragment,kr),Y1=h(kr),T(An.$$.fragment,kr),kr.forEach(t),oo.forEach(t),rg=h(l),Ts=r(l,"H2",{class:!0});var M_=a(Ts);Nn=r(M_,"A",{id:!0,class:!0,href:!0});var tD=a(Nn);fu=r(tD,"SPAN",{});var oD=a(fu);T(Ti.$$.fragment,oD),oD.forEach(t),tD.forEach(t),K1=h(M_),mu=r(M_,"SPAN",{});var sD=a(mu);e0=s(sD,"TFDistilBertForTokenClassification"),sD.forEach(t),M_.forEach(t),ag=h(l),ht=r(l,"DIV",{class:!0});var so=a(ht);T(ki.$$.fragment,so),t0=h(so),gu=r(so,"P",{});var nD=a(gu);o0=s(nD,`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.`),nD.forEach(t),s0=h(so),Mi=r(so,"P",{});var $_=a(Mi);n0=s($_,"This model inherits from "),cp=r($_,"A",{href:!0});var rD=a(cp);r0=s(rD,"TFPreTrainedModel"),rD.forEach(t),a0=s($_,`. 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.)`),$_.forEach(t),l0=h(so),$i=r(so,"P",{});var E_=a($i);i0=s(E_,"This model is also a "),Ei=r(E_,"A",{href:!0,rel:!0});var aD=a(Ei);d0=s(aD,"tf.keras.Model"),aD.forEach(t),c0=s(E_,` 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.`),E_.forEach(t),p0=h(so),T(Rn.$$.fragment,so),h0=h(so),Ft=r(so,"DIV",{class:!0});var Vo=a(Ft);T(Fi.$$.fragment,Vo),u0=h(Vo),ks=r(Vo,"P",{});var Np=a(ks);f0=s(Np,"The "),pp=r(Np,"A",{href:!0});var lD=a(pp);m0=s(lD,"TFDistilBertForTokenClassification"),lD.forEach(t),g0=s(Np," forward method, overrides the "),_u=r(Np,"CODE",{});var iD=a(_u);_0=s(iD,"__call__"),iD.forEach(t),b0=s(Np," special method."),Np.forEach(t),v0=h(Vo),T(Zn.$$.fragment,Vo),y0=h(Vo),T(Gn.$$.fragment,Vo),w0=h(Vo),T(qn.$$.fragment,Vo),Vo.forEach(t),so.forEach(t),lg=h(l),Ms=r(l,"H2",{class:!0});var F_=a(Ms);Xn=r(F_,"A",{id:!0,class:!0,href:!0});var dD=a(Xn);bu=r(dD,"SPAN",{});var cD=a(bu);T(Bi.$$.fragment,cD),cD.forEach(t),dD.forEach(t),T0=h(F_),vu=r(F_,"SPAN",{});var pD=a(vu);k0=s(pD,"TFDistilBertForQuestionAnswering"),pD.forEach(t),F_.forEach(t),ig=h(l),ut=r(l,"DIV",{class:!0});var no=a(ut);T(ji.$$.fragment,no),M0=h(no),$s=r(no,"P",{});var Rp=a($s);$0=s(Rp,`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 `),yu=r(Rp,"CODE",{});var hD=a(yu);E0=s(hD,"span start logits"),hD.forEach(t),F0=s(Rp," and "),wu=r(Rp,"CODE",{});var uD=a(wu);B0=s(uD,"span end logits"),uD.forEach(t),j0=s(Rp,")."),Rp.forEach(t),D0=h(no),Di=r(no,"P",{});var B_=a(Di);x0=s(B_,"This model inherits from "),hp=r(B_,"A",{href:!0});var fD=a(hp);C0=s(fD,"TFPreTrainedModel"),fD.forEach(t),J0=s(B_,`. 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.)`),B_.forEach(t),z0=h(no),xi=r(no,"P",{});var j_=a(xi);U0=s(j_,"This model is also a "),Ci=r(j_,"A",{href:!0,rel:!0});var mD=a(Ci);I0=s(mD,"tf.keras.Model"),mD.forEach(t),W0=s(j_,` 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.`),j_.forEach(t),A0=h(no),T(Pn.$$.fragment,no),N0=h(no),Bt=r(no,"DIV",{class:!0});var So=a(Bt);T(Ji.$$.fragment,So),R0=h(So),Es=r(So,"P",{});var Zp=a(Es);Z0=s(Zp,"The "),up=r(Zp,"A",{href:!0});var gD=a(up);G0=s(gD,"TFDistilBertForQuestionAnswering"),gD.forEach(t),q0=s(Zp," forward method, overrides the "),Tu=r(Zp,"CODE",{});var _D=a(Tu);X0=s(_D,"__call__"),_D.forEach(t),P0=s(Zp," special method."),Zp.forEach(t),V0=h(So),T(Vn.$$.fragment,So),S0=h(So),T(Sn.$$.fragment,So),L0=h(So),T(Ln.$$.fragment,So),So.forEach(t),no.forEach(t),dg=h(l),Fs=r(l,"H2",{class:!0});var D_=a(Fs);Qn=r(D_,"A",{id:!0,class:!0,href:!0});var bD=a(Qn);ku=r(bD,"SPAN",{});var vD=a(ku);T(zi.$$.fragment,vD),vD.forEach(t),bD.forEach(t),Q0=h(D_),Mu=r(D_,"SPAN",{});var yD=a(Mu);O0=s(yD,"FlaxDistilBertModel"),yD.forEach(t),D_.forEach(t),cg=h(l),ot=r(l,"DIV",{class:!0});var Dt=a(ot);T(Ui.$$.fragment,Dt),H0=h(Dt),$u=r(Dt,"P",{});var wD=a($u);Y0=s(wD,"The bare DistilBert Model transformer outputting raw hidden-states without any specific head on top."),wD.forEach(t),K0=h(Dt),Ii=r(Dt,"P",{});var x_=a(Ii);e$=s(x_,"This model inherits from "),fp=r(x_,"A",{href:!0});var TD=a(fp);t$=s(TD,"FlaxPreTrainedModel"),TD.forEach(t),o$=s(x_,`. 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)`),x_.forEach(t),s$=h(Dt),Wi=r(Dt,"P",{});var C_=a(Wi);n$=s(C_,"This model is also a Flax Linen "),Ai=r(C_,"A",{href:!0,rel:!0});var kD=a(Ai);r$=s(kD,"flax.linen.Module"),kD.forEach(t),a$=s(C_,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),C_.forEach(t),l$=h(Dt),Eu=r(Dt,"P",{});var MD=a(Eu);i$=s(MD,"Finally, this model supports inherent JAX features such as:"),MD.forEach(t),d$=h(Dt),ao=r(Dt,"UL",{});var Mr=a(ao);Fu=r(Mr,"LI",{});var $D=a(Fu);Ni=r($D,"A",{href:!0,rel:!0});var ED=a(Ni);c$=s(ED,"Just-In-Time (JIT) compilation"),ED.forEach(t),$D.forEach(t),p$=h(Mr),Bu=r(Mr,"LI",{});var FD=a(Bu);Ri=r(FD,"A",{href:!0,rel:!0});var BD=a(Ri);h$=s(BD,"Automatic Differentiation"),BD.forEach(t),FD.forEach(t),u$=h(Mr),ju=r(Mr,"LI",{});var jD=a(ju);Zi=r(jD,"A",{href:!0,rel:!0});var DD=a(Zi);f$=s(DD,"Vectorization"),DD.forEach(t),jD.forEach(t),m$=h(Mr),Du=r(Mr,"LI",{});var xD=a(Du);Gi=r(xD,"A",{href:!0,rel:!0});var CD=a(Gi);g$=s(CD,"Parallelization"),CD.forEach(t),xD.forEach(t),Mr.forEach(t),_$=h(Dt),St=r(Dt,"DIV",{class:!0});var $r=a(St);T(qi.$$.fragment,$r),b$=h($r),Bs=r($r,"P",{});var Gp=a(Bs);v$=s(Gp,"The "),xu=r(Gp,"CODE",{});var JD=a(xu);y$=s(JD,"FlaxDistilBertPreTrainedModel"),JD.forEach(t),w$=s(Gp," forward method, overrides the "),Cu=r(Gp,"CODE",{});var zD=a(Cu);T$=s(zD,"__call__"),zD.forEach(t),k$=s(Gp," special method."),Gp.forEach(t),M$=h($r),T(On.$$.fragment,$r),$$=h($r),T(Hn.$$.fragment,$r),$r.forEach(t),Dt.forEach(t),pg=h(l),js=r(l,"H2",{class:!0});var J_=a(js);Yn=r(J_,"A",{id:!0,class:!0,href:!0});var UD=a(Yn);Ju=r(UD,"SPAN",{});var ID=a(Ju);T(Xi.$$.fragment,ID),ID.forEach(t),UD.forEach(t),E$=h(J_),zu=r(J_,"SPAN",{});var WD=a(zu);F$=s(WD,"FlaxDistilBertForMaskedLM"),WD.forEach(t),J_.forEach(t),hg=h(l),st=r(l,"DIV",{class:!0});var xt=a(st);T(Pi.$$.fragment,xt),B$=h(xt),Vi=r(xt,"P",{});var z_=a(Vi);j$=s(z_,"DistilBert Model with a "),Uu=r(z_,"CODE",{});var AD=a(Uu);D$=s(AD,"language modeling"),AD.forEach(t),x$=s(z_," head on top."),z_.forEach(t),C$=h(xt),Si=r(xt,"P",{});var U_=a(Si);J$=s(U_,"This model inherits from "),mp=r(U_,"A",{href:!0});var ND=a(mp);z$=s(ND,"FlaxPreTrainedModel"),ND.forEach(t),U$=s(U_,`. 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)`),U_.forEach(t),I$=h(xt),Li=r(xt,"P",{});var I_=a(Li);W$=s(I_,"This model is also a Flax Linen "),Qi=r(I_,"A",{href:!0,rel:!0});var RD=a(Qi);A$=s(RD,"flax.linen.Module"),RD.forEach(t),N$=s(I_,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),I_.forEach(t),R$=h(xt),Iu=r(xt,"P",{});var ZD=a(Iu);Z$=s(ZD,"Finally, this model supports inherent JAX features such as:"),ZD.forEach(t),G$=h(xt),lo=r(xt,"UL",{});var Er=a(lo);Wu=r(Er,"LI",{});var GD=a(Wu);Oi=r(GD,"A",{href:!0,rel:!0});var qD=a(Oi);q$=s(qD,"Just-In-Time (JIT) compilation"),qD.forEach(t),GD.forEach(t),X$=h(Er),Au=r(Er,"LI",{});var XD=a(Au);Hi=r(XD,"A",{href:!0,rel:!0});var PD=a(Hi);P$=s(PD,"Automatic Differentiation"),PD.forEach(t),XD.forEach(t),V$=h(Er),Nu=r(Er,"LI",{});var VD=a(Nu);Yi=r(VD,"A",{href:!0,rel:!0});var SD=a(Yi);S$=s(SD,"Vectorization"),SD.forEach(t),VD.forEach(t),L$=h(Er),Ru=r(Er,"LI",{});var LD=a(Ru);Ki=r(LD,"A",{href:!0,rel:!0});var QD=a(Ki);Q$=s(QD,"Parallelization"),QD.forEach(t),LD.forEach(t),Er.forEach(t),O$=h(xt),Lt=r(xt,"DIV",{class:!0});var Fr=a(Lt);T(ed.$$.fragment,Fr),H$=h(Fr),Ds=r(Fr,"P",{});var qp=a(Ds);Y$=s(qp,"The "),Zu=r(qp,"CODE",{});var OD=a(Zu);K$=s(OD,"FlaxDistilBertPreTrainedModel"),OD.forEach(t),eE=s(qp," forward method, overrides the "),Gu=r(qp,"CODE",{});var HD=a(Gu);tE=s(HD,"__call__"),HD.forEach(t),oE=s(qp," special method."),qp.forEach(t),sE=h(Fr),T(Kn.$$.fragment,Fr),nE=h(Fr),T(er.$$.fragment,Fr),Fr.forEach(t),xt.forEach(t),ug=h(l),xs=r(l,"H2",{class:!0});var W_=a(xs);tr=r(W_,"A",{id:!0,class:!0,href:!0});var YD=a(tr);qu=r(YD,"SPAN",{});var KD=a(qu);T(td.$$.fragment,KD),KD.forEach(t),YD.forEach(t),rE=h(W_),Xu=r(W_,"SPAN",{});var ex=a(Xu);aE=s(ex,"FlaxDistilBertForSequenceClassification"),ex.forEach(t),W_.forEach(t),fg=h(l),nt=r(l,"DIV",{class:!0});var Ct=a(nt);T(od.$$.fragment,Ct),lE=h(Ct),Pu=r(Ct,"P",{});var tx=a(Pu);iE=s(tx,`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.`),tx.forEach(t),dE=h(Ct),sd=r(Ct,"P",{});var A_=a(sd);cE=s(A_,"This model inherits from "),gp=r(A_,"A",{href:!0});var ox=a(gp);pE=s(ox,"FlaxPreTrainedModel"),ox.forEach(t),hE=s(A_,`. 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)`),A_.forEach(t),uE=h(Ct),nd=r(Ct,"P",{});var N_=a(nd);fE=s(N_,"This model is also a Flax Linen "),rd=r(N_,"A",{href:!0,rel:!0});var sx=a(rd);mE=s(sx,"flax.linen.Module"),sx.forEach(t),gE=s(N_,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),N_.forEach(t),_E=h(Ct),Vu=r(Ct,"P",{});var nx=a(Vu);bE=s(nx,"Finally, this model supports inherent JAX features such as:"),nx.forEach(t),vE=h(Ct),io=r(Ct,"UL",{});var Br=a(io);Su=r(Br,"LI",{});var rx=a(Su);ad=r(rx,"A",{href:!0,rel:!0});var ax=a(ad);yE=s(ax,"Just-In-Time (JIT) compilation"),ax.forEach(t),rx.forEach(t),wE=h(Br),Lu=r(Br,"LI",{});var lx=a(Lu);ld=r(lx,"A",{href:!0,rel:!0});var ix=a(ld);TE=s(ix,"Automatic Differentiation"),ix.forEach(t),lx.forEach(t),kE=h(Br),Qu=r(Br,"LI",{});var dx=a(Qu);id=r(dx,"A",{href:!0,rel:!0});var cx=a(id);ME=s(cx,"Vectorization"),cx.forEach(t),dx.forEach(t),$E=h(Br),Ou=r(Br,"LI",{});var px=a(Ou);dd=r(px,"A",{href:!0,rel:!0});var hx=a(dd);EE=s(hx,"Parallelization"),hx.forEach(t),px.forEach(t),Br.forEach(t),FE=h(Ct),Qt=r(Ct,"DIV",{class:!0});var jr=a(Qt);T(cd.$$.fragment,jr),BE=h(jr),Cs=r(jr,"P",{});var Xp=a(Cs);jE=s(Xp,"The "),Hu=r(Xp,"CODE",{});var ux=a(Hu);DE=s(ux,"FlaxDistilBertPreTrainedModel"),ux.forEach(t),xE=s(Xp," forward method, overrides the "),Yu=r(Xp,"CODE",{});var fx=a(Yu);CE=s(fx,"__call__"),fx.forEach(t),JE=s(Xp," special method."),Xp.forEach(t),zE=h(jr),T(or.$$.fragment,jr),UE=h(jr),T(sr.$$.fragment,jr),jr.forEach(t),Ct.forEach(t),mg=h(l),Js=r(l,"H2",{class:!0});var R_=a(Js);nr=r(R_,"A",{id:!0,class:!0,href:!0});var mx=a(nr);Ku=r(mx,"SPAN",{});var gx=a(Ku);T(pd.$$.fragment,gx),gx.forEach(t),mx.forEach(t),IE=h(R_),ef=r(R_,"SPAN",{});var _x=a(ef);WE=s(_x,"FlaxDistilBertForMultipleChoice"),_x.forEach(t),R_.forEach(t),gg=h(l),rt=r(l,"DIV",{class:!0});var Jt=a(rt);T(hd.$$.fragment,Jt),AE=h(Jt),tf=r(Jt,"P",{});var bx=a(tf);NE=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),RE=h(Jt),ud=r(Jt,"P",{});var Z_=a(ud);ZE=s(Z_,"This model inherits from "),_p=r(Z_,"A",{href:!0});var vx=a(_p);GE=s(vx,"FlaxPreTrainedModel"),vx.forEach(t),qE=s(Z_,`. 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)`),Z_.forEach(t),XE=h(Jt),fd=r(Jt,"P",{});var G_=a(fd);PE=s(G_,"This model is also a Flax Linen "),md=r(G_,"A",{href:!0,rel:!0});var yx=a(md);VE=s(yx,"flax.linen.Module"),yx.forEach(t),SE=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),LE=h(Jt),of=r(Jt,"P",{});var wx=a(of);QE=s(wx,"Finally, this model supports inherent JAX features such as:"),wx.forEach(t),OE=h(Jt),co=r(Jt,"UL",{});var Dr=a(co);sf=r(Dr,"LI",{});var Tx=a(sf);gd=r(Tx,"A",{href:!0,rel:!0});var kx=a(gd);HE=s(kx,"Just-In-Time (JIT) compilation"),kx.forEach(t),Tx.forEach(t),YE=h(Dr),nf=r(Dr,"LI",{});var Mx=a(nf);_d=r(Mx,"A",{href:!0,rel:!0});var $x=a(_d);KE=s($x,"Automatic Differentiation"),$x.forEach(t),Mx.forEach(t),eF=h(Dr),rf=r(Dr,"LI",{});var Ex=a(rf);bd=r(Ex,"A",{href:!0,rel:!0});var Fx=a(bd);tF=s(Fx,"Vectorization"),Fx.forEach(t),Ex.forEach(t),oF=h(Dr),af=r(Dr,"LI",{});var Bx=a(af);vd=r(Bx,"A",{href:!0,rel:!0});var jx=a(vd);sF=s(jx,"Parallelization"),jx.forEach(t),Bx.forEach(t),Dr.forEach(t),nF=h(Jt),Ot=r(Jt,"DIV",{class:!0});var xr=a(Ot);T(yd.$$.fragment,xr),rF=h(xr),zs=r(xr,"P",{});var Pp=a(zs);aF=s(Pp,"The "),lf=r(Pp,"CODE",{});var Dx=a(lf);lF=s(Dx,"FlaxDistilBertPreTrainedModel"),Dx.forEach(t),iF=s(Pp," forward method, overrides the "),df=r(Pp,"CODE",{});var xx=a(df);dF=s(xx,"__call__"),xx.forEach(t),cF=s(Pp," special method."),Pp.forEach(t),pF=h(xr),T(rr.$$.fragment,xr),hF=h(xr),T(ar.$$.fragment,xr),xr.forEach(t),Jt.forEach(t),_g=h(l),Us=r(l,"H2",{class:!0});var q_=a(Us);lr=r(q_,"A",{id:!0,class:!0,href:!0});var Cx=a(lr);cf=r(Cx,"SPAN",{});var Jx=a(cf);T(wd.$$.fragment,Jx),Jx.forEach(t),Cx.forEach(t),uF=h(q_),pf=r(q_,"SPAN",{});var zx=a(pf);fF=s(zx,"FlaxDistilBertForTokenClassification"),zx.forEach(t),q_.forEach(t),bg=h(l),at=r(l,"DIV",{class:!0});var zt=a(at);T(Td.$$.fragment,zt),mF=h(zt),hf=r(zt,"P",{});var Ux=a(hf);gF=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),_F=h(zt),kd=r(zt,"P",{});var X_=a(kd);bF=s(X_,"This model inherits from "),bp=r(X_,"A",{href:!0});var Ix=a(bp);vF=s(Ix,"FlaxPreTrainedModel"),Ix.forEach(t),yF=s(X_,`. 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)`),X_.forEach(t),wF=h(zt),Md=r(zt,"P",{});var P_=a(Md);TF=s(P_,"This model is also a Flax Linen "),$d=r(P_,"A",{href:!0,rel:!0});var Wx=a($d);kF=s(Wx,"flax.linen.Module"),Wx.forEach(t),MF=s(P_,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),P_.forEach(t),$F=h(zt),uf=r(zt,"P",{});var Ax=a(uf);EF=s(Ax,"Finally, this model supports inherent JAX features such as:"),Ax.forEach(t),FF=h(zt),po=r(zt,"UL",{});var Cr=a(po);ff=r(Cr,"LI",{});var Nx=a(ff);Ed=r(Nx,"A",{href:!0,rel:!0});var Rx=a(Ed);BF=s(Rx,"Just-In-Time (JIT) compilation"),Rx.forEach(t),Nx.forEach(t),jF=h(Cr),mf=r(Cr,"LI",{});var Zx=a(mf);Fd=r(Zx,"A",{href:!0,rel:!0});var Gx=a(Fd);DF=s(Gx,"Automatic Differentiation"),Gx.forEach(t),Zx.forEach(t),xF=h(Cr),gf=r(Cr,"LI",{});var qx=a(gf);Bd=r(qx,"A",{href:!0,rel:!0});var Xx=a(Bd);CF=s(Xx,"Vectorization"),Xx.forEach(t),qx.forEach(t),JF=h(Cr),_f=r(Cr,"LI",{});var Px=a(_f);jd=r(Px,"A",{href:!0,rel:!0});var Vx=a(jd);zF=s(Vx,"Parallelization"),Vx.forEach(t),Px.forEach(t),Cr.forEach(t),UF=h(zt),Ht=r(zt,"DIV",{class:!0});var Jr=a(Ht);T(Dd.$$.fragment,Jr),IF=h(Jr),Is=r(Jr,"P",{});var Vp=a(Is);WF=s(Vp,"The "),bf=r(Vp,"CODE",{});var Sx=a(bf);AF=s(Sx,"FlaxDistilBertPreTrainedModel"),Sx.forEach(t),NF=s(Vp," forward method, overrides the "),vf=r(Vp,"CODE",{});var Lx=a(vf);RF=s(Lx,"__call__"),Lx.forEach(t),ZF=s(Vp," special method."),Vp.forEach(t),GF=h(Jr),T(ir.$$.fragment,Jr),qF=h(Jr),T(dr.$$.fragment,Jr),Jr.forEach(t),zt.forEach(t),vg=h(l),Ws=r(l,"H2",{class:!0});var V_=a(Ws);cr=r(V_,"A",{id:!0,class:!0,href:!0});var Qx=a(cr);yf=r(Qx,"SPAN",{});var Ox=a(yf);T(xd.$$.fragment,Ox),Ox.forEach(t),Qx.forEach(t),XF=h(V_),wf=r(V_,"SPAN",{});var Hx=a(wf);PF=s(Hx,"FlaxDistilBertForQuestionAnswering"),Hx.forEach(t),V_.forEach(t),yg=h(l),lt=r(l,"DIV",{class:!0});var Ut=a(lt);T(Cd.$$.fragment,Ut),VF=h(Ut),As=r(Ut,"P",{});var Sp=a(As);SF=s(Sp,`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(Sp,"CODE",{});var Yx=a(Tf);LF=s(Yx,"span start logits"),Yx.forEach(t),QF=s(Sp," and "),kf=r(Sp,"CODE",{});var Kx=a(kf);OF=s(Kx,"span end logits"),Kx.forEach(t),HF=s(Sp,")."),Sp.forEach(t),YF=h(Ut),Jd=r(Ut,"P",{});var S_=a(Jd);KF=s(S_,"This model inherits from "),vp=r(S_,"A",{href:!0});var eC=a(vp);eB=s(eC,"FlaxPreTrainedModel"),eC.forEach(t),tB=s(S_,`. 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)`),S_.forEach(t),oB=h(Ut),zd=r(Ut,"P",{});var L_=a(zd);sB=s(L_,"This model is also a Flax Linen "),Ud=r(L_,"A",{href:!0,rel:!0});var tC=a(Ud);nB=s(tC,"flax.linen.Module"),tC.forEach(t),rB=s(L_,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),L_.forEach(t),aB=h(Ut),Mf=r(Ut,"P",{});var oC=a(Mf);lB=s(oC,"Finally, this model supports inherent JAX features such as:"),oC.forEach(t),iB=h(Ut),ho=r(Ut,"UL",{});var zr=a(ho);$f=r(zr,"LI",{});var sC=a($f);Id=r(sC,"A",{href:!0,rel:!0});var nC=a(Id);dB=s(nC,"Just-In-Time (JIT) compilation"),nC.forEach(t),sC.forEach(t),cB=h(zr),Ef=r(zr,"LI",{});var rC=a(Ef);Wd=r(rC,"A",{href:!0,rel:!0});var aC=a(Wd);pB=s(aC,"Automatic Differentiation"),aC.forEach(t),rC.forEach(t),hB=h(zr),Ff=r(zr,"LI",{});var lC=a(Ff);Ad=r(lC,"A",{href:!0,rel:!0});var iC=a(Ad);uB=s(iC,"Vectorization"),iC.forEach(t),lC.forEach(t),fB=h(zr),Bf=r(zr,"LI",{});var dC=a(Bf);Nd=r(dC,"A",{href:!0,rel:!0});var cC=a(Nd);mB=s(cC,"Parallelization"),cC.forEach(t),dC.forEach(t),zr.forEach(t),gB=h(Ut),Yt=r(Ut,"DIV",{class:!0});var Ur=a(Yt);T(Rd.$$.fragment,Ur),_B=h(Ur),Ns=r(Ur,"P",{});var Lp=a(Ns);bB=s(Lp,"The "),jf=r(Lp,"CODE",{});var pC=a(jf);vB=s(pC,"FlaxDistilBertPreTrainedModel"),pC.forEach(t),yB=s(Lp," forward method, overrides the "),Df=r(Lp,"CODE",{});var hC=a(Df);wB=s(hC,"__call__"),hC.forEach(t),TB=s(Lp," special method."),Lp.forEach(t),kB=h(Ur),T(pr.$$.fragment,Ur),MB=h(Ur),T(hr.$$.fragment,Ur),Ur.forEach(t),Ut.forEach(t),this.h()},h(){c(d,"name","hf:doc:metadata"),c(d,"content",JSON.stringify(mJ)),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(K,"alt","Models"),CB(K.src,F="https://img.shields.io/badge/All_model_pages-distilbert-blueviolet")||c(K,"src",F),c(ie,"href","https://huggingface.co/models?filter=distilbert"),c(de,"alt","Spaces"),CB(de.src,ze="https://img.shields.io/badge/%F0%9F%A4%97%20Hugging%20Face-Spaces-blue")||c(de,"src",ze),c(q,"href","https://huggingface.co/spaces/docs-demos/distilbert-base-uncased"),c(pe,"alt","Paper page"),CB(pe.src,Y="https://img.shields.io/badge/Paper%20page-1910.01108-green")||c(pe,"src",Y),c(ce,"href","https://huggingface.co/papers/1910.01108"),c(W,"class","flex flex-wrap space-x-1"),c(Z,"id","overview"),c(Z,"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(Z,"href","#overview"),c(se,"class","relative group"),c(ae,"href","https://medium.com/huggingface/distilbert-8cf3380435b5"),c(ae,"rel","nofollow"),c(le,"href","https://arxiv.org/papers/1910.01108"),c(le,"rel","nofollow"),c(Ir,"href","https://huggingface.co/victorsanh"),c(Ir,"rel","nofollow"),c(Wr,"href","https://huggingface.co/kamalkraj"),c(Wr,"rel","nofollow"),c(Ar,"href","https://github.com/huggingface/transformers/tree/main/examples/research_projects/distillation"),c(Ar,"rel","nofollow"),c(qs,"id","resources"),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","#resources"),c(Lo,"class","relative group"),c(Gr,"href","https://huggingface.co/blog/sentiment-analysis-python"),c(Gr,"rel","nofollow"),c(Xr,"href","https://huggingface.co/blog/fastai"),c(Xr,"rel","nofollow"),c(Vr,"href","https://huggingface.co/blog/ray-tune"),c(Vr,"rel","nofollow"),c(Lr,"href","https://huggingface.co/blog/the-partnership-amazon-sagemaker-and-hugging-face"),c(Lr,"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(Yr,"href","https://colab.research.google.com/github/abhimishra91/transformers-tutorials/blob/master/transformers_multiclass_classification.ipynb"),c(Yr,"rel","nofollow"),c(ea,"href","https://colab.research.google.com/github/peterbayerle/huggingface_notebook/blob/main/distilbert_tf.ipynb"),c(ea,"rel","nofollow"),c(ic,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForSequenceClassification"),c(ta,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/text-classification"),c(ta,"rel","nofollow"),c(oa,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification.ipynb"),c(oa,"rel","nofollow"),c(dc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForSequenceClassification"),c(sa,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/text-classification"),c(sa,"rel","nofollow"),c(na,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification-tf.ipynb"),c(na,"rel","nofollow"),c(cc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.FlaxDistilBertForSequenceClassification"),c(ra,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/text-classification"),c(ra,"rel","nofollow"),c(aa,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification_flax.ipynb"),c(aa,"rel","nofollow"),c(pc,"href","../tasks/sequence_classification"),c(hc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForTokenClassification"),c(ia,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/token-classification"),c(ia,"rel","nofollow"),c(da,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification.ipynb"),c(da,"rel","nofollow"),c(uc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForTokenClassification"),c(ca,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/token-classification"),c(ca,"rel","nofollow"),c(pa,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification-tf.ipynb"),c(pa,"rel","nofollow"),c(fc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.FlaxDistilBertForTokenClassification"),c(ha,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/token-classification"),c(ha,"rel","nofollow"),c(ua,"href","https://huggingface.co/course/chapter7/2?fw=pt"),c(ua,"rel","nofollow"),c(gc,"href","../tasks/token_classification"),c(_c,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForMaskedLM"),c(ma,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/language-modeling#robertabertdistilbert-and-masked-language-modeling"),c(ma,"rel","nofollow"),c(ga,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling.ipynb"),c(ga,"rel","nofollow"),c(bc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForMaskedLM"),c(_a,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/language-modeling#run_mlmpy"),c(_a,"rel","nofollow"),c(ba,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling-tf.ipynb"),c(ba,"rel","nofollow"),c(vc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.FlaxDistilBertForMaskedLM"),c(va,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/language-modeling#masked-language-modeling"),c(va,"rel","nofollow"),c(ya,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/masked_language_modeling_flax.ipynb"),c(ya,"rel","nofollow"),c(wa,"href","https://huggingface.co/course/chapter7/3?fw=pt"),c(wa,"rel","nofollow"),c(wc,"href","../tasks/masked_language_modeling"),c(Tc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForQuestionAnswering"),c(ka,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/question-answering"),c(ka,"rel","nofollow"),c(Ma,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering.ipynb"),c(Ma,"rel","nofollow"),c(kc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForQuestionAnswering"),c($a,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/question-answering"),c($a,"rel","nofollow"),c(Ea,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering-tf.ipynb"),c(Ea,"rel","nofollow"),c(Mc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.FlaxDistilBertForQuestionAnswering"),c(Fa,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/question-answering"),c(Fa,"rel","nofollow"),c(Ba,"href","https://huggingface.co/course/chapter7/7?fw=pt"),c(Ba,"rel","nofollow"),c(Ec,"href","../tasks/question_answering"),c(Bc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForMultipleChoice"),c(ja,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/multiple-choice"),c(ja,"rel","nofollow"),c(Da,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/multiple_choice.ipynb"),c(Da,"rel","nofollow"),c(jc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForMultipleChoice"),c(xa,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/multiple-choice"),c(xa,"rel","nofollow"),c(Ca,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/multiple_choice-tf.ipynb"),c(Ca,"rel","nofollow"),c(Dc,"href","../tasks/multiple_choice"),c(za,"href","https://huggingface.co/blog/intel"),c(za,"rel","nofollow"),c(Ia,"href","https://www.philschmid.de/optimizing-transformers-with-optimum-gpu"),c(Ia,"rel","nofollow"),c(Aa,"href","https://www.philschmid.de/optimizing-transformers-with-optimum"),c(Aa,"rel","nofollow"),c(Ra,"href","https://huggingface.co/blog/bert-inferentia-sagemaker"),c(Ra,"rel","nofollow"),c(Ga,"href","https://www.philschmid.de/sagemaker-serverless-huggingface-distilbert"),c(Ga,"rel","nofollow"),c(Xa,"href","https://huggingface.co/blog/how-to-deploy-a-pipeline-to-google-clouds"),c(Xa,"rel","nofollow"),c(Va,"href","https://huggingface.co/blog/deploy-hugging-face-models-easily-with-amazon-sagemaker"),c(Va,"rel","nofollow"),c(La,"href","https://www.philschmid.de/terraform-huggingface-amazon-sagemaker"),c(La,"rel","nofollow"),c(Ss,"id","transformers.DistilBertConfig"),c(Ss,"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(Ss,"href","#transformers.DistilBertConfig"),c(Qo,"class","relative group"),c(zc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertModel"),c(Uc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertModel"),c(Ha,"href","https://huggingface.co/distilbert-base-uncased"),c(Ha,"rel","nofollow"),c(Ic,"href","/docs/transformers/v4.32.0/en/main_classes/configuration#transformers.PretrainedConfig"),c(Wc,"href","/docs/transformers/v4.32.0/en/main_classes/configuration#transformers.PretrainedConfig"),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(Qs,"id","transformers.DistilBertTokenizer"),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.DistilBertTokenizer"),c(Ho,"class","relative group"),c(Ac,"href","/docs/transformers/v4.32.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizer"),c(xo,"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,"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"),c(Ys,"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(Ks,"id","transformers.DistilBertTokenizerFast"),c(Ks,"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(Ks,"href","#transformers.DistilBertTokenizerFast"),c(Ko,"class","relative group"),c(Zc,"href","/docs/transformers/v4.32.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast"),c(Co,"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(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(tn,"id","transformers.DistilBertModel"),c(tn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(tn,"href","#transformers.DistilBertModel"),c(ts,"class","relative group"),c(Xc,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(bl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(bl,"rel","nofollow"),c(Pc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertModel"),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(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(nn,"id","transformers.DistilBertForMaskedLM"),c(nn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(nn,"href","#transformers.DistilBertForMaskedLM"),c(ss,"class","relative group"),c(Vc,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c($l,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c($l,"rel","nofollow"),c(Sc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForMaskedLM"),c(Zt,"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(ln,"id","transformers.DistilBertForSequenceClassification"),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.DistilBertForSequenceClassification"),c(rs,"class","relative group"),c(Lc,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(xl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(xl,"rel","nofollow"),c(Qc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForSequenceClassification"),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(_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(hn,"id","transformers.DistilBertForMultipleChoice"),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.DistilBertForMultipleChoice"),c(ls,"class","relative group"),c(Oc,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(Wl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Wl,"rel","nofollow"),c(Hc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForMultipleChoice"),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(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(mn,"id","transformers.DistilBertForTokenClassification"),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.DistilBertForTokenClassification"),c(ds,"class","relative group"),c(Yc,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(ql,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(ql,"rel","nofollow"),c(Kc,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForTokenClassification"),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(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(bn,"id","transformers.DistilBertForQuestionAnswering"),c(bn,"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(bn,"href","#transformers.DistilBertForQuestionAnswering"),c(ps,"class","relative group"),c(ep,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(Ql,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Ql,"rel","nofollow"),c(tp,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.DistilBertForQuestionAnswering"),c(Xt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),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(wn,"id","transformers.TFDistilBertModel"),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.TFDistilBertModel"),c(fs,"class","relative group"),c(op,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(ti,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(ti,"rel","nofollow"),c(sp,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertModel"),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(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($n,"id","transformers.TFDistilBertForMaskedLM"),c($n,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c($n,"href","#transformers.TFDistilBertForMaskedLM"),c(gs,"class","relative group"),c(np,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(ii,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(ii,"rel","nofollow"),c(rp,"href","/docs/transformers/v4.32.0/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(Dn,"id","transformers.TFDistilBertForSequenceClassification"),c(Dn,"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(Dn,"href","#transformers.TFDistilBertForSequenceClassification"),c(bs,"class","relative group"),c(ap,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(fi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(fi,"rel","nofollow"),c(lp,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForSequenceClassification"),c(Et,"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(Un,"id","transformers.TFDistilBertForMultipleChoice"),c(Un,"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(Un,"href","#transformers.TFDistilBertForMultipleChoice"),c(ys,"class","relative group"),c(ip,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(yi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(yi,"rel","nofollow"),c(dp,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForMultipleChoice"),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(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(Nn,"id","transformers.TFDistilBertForTokenClassification"),c(Nn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Nn,"href","#transformers.TFDistilBertForTokenClassification"),c(Ts,"class","relative group"),c(cp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(Ei,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Ei,"rel","nofollow"),c(pp,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForTokenClassification"),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(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(Xn,"id","transformers.TFDistilBertForQuestionAnswering"),c(Xn,"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(Xn,"href","#transformers.TFDistilBertForQuestionAnswering"),c(Ms,"class","relative group"),c(hp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(Ci,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Ci,"rel","nofollow"),c(up,"href","/docs/transformers/v4.32.0/en/model_doc/distilbert#transformers.TFDistilBertForQuestionAnswering"),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(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(Qn,"id","transformers.FlaxDistilBertModel"),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.FlaxDistilBertModel"),c(Fs,"class","relative group"),c(fp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Ai,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Ai,"rel","nofollow"),c(Ni,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Ni,"rel","nofollow"),c(Ri,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Ri,"rel","nofollow"),c(Zi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Zi,"rel","nofollow"),c(Gi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Gi,"rel","nofollow"),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(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(Yn,"id","transformers.FlaxDistilBertForMaskedLM"),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.FlaxDistilBertForMaskedLM"),c(js,"class","relative group"),c(mp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Qi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Qi,"rel","nofollow"),c(Oi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Oi,"rel","nofollow"),c(Hi,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Hi,"rel","nofollow"),c(Yi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Yi,"rel","nofollow"),c(Ki,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Ki,"rel","nofollow"),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(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(tr,"id","transformers.FlaxDistilBertForSequenceClassification"),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.FlaxDistilBertForSequenceClassification"),c(xs,"class","relative group"),c(gp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(rd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(rd,"rel","nofollow"),c(ad,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(ad,"rel","nofollow"),c(ld,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(ld,"rel","nofollow"),c(id,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(id,"rel","nofollow"),c(dd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(dd,"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(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(nr,"id","transformers.FlaxDistilBertForMultipleChoice"),c(nr,"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(nr,"href","#transformers.FlaxDistilBertForMultipleChoice"),c(Js,"class","relative group"),c(_p,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(md,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(md,"rel","nofollow"),c(gd,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(gd,"rel","nofollow"),c(_d,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(_d,"rel","nofollow"),c(bd,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(bd,"rel","nofollow"),c(vd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(vd,"rel","nofollow"),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(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(lr,"id","transformers.FlaxDistilBertForTokenClassification"),c(lr,"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(lr,"href","#transformers.FlaxDistilBertForTokenClassification"),c(Us,"class","relative group"),c(bp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c($d,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c($d,"rel","nofollow"),c(Ed,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Ed,"rel","nofollow"),c(Fd,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Fd,"rel","nofollow"),c(Bd,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Bd,"rel","nofollow"),c(jd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(jd,"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(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(cr,"id","transformers.FlaxDistilBertForQuestionAnswering"),c(cr,"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(cr,"href","#transformers.FlaxDistilBertForQuestionAnswering"),c(Ws,"class","relative group"),c(vp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Ud,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Ud,"rel","nofollow"),c(Id,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Id,"rel","nofollow"),c(Wd,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Wd,"rel","nofollow"),c(Ad,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Ad,"rel","nofollow"),c(Nd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Nd,"rel","nofollow"),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(lt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(l,_){e(document.head,d),g(l,v,_),g(l,f,_),e(f,m),e(m,b),k(i,b,null),e(f,u),e(f,j),e(j,ke),g(l,ye,_),g(l,W,_),e(W,ie),e(ie,K),e(W,Me),e(W,q),e(q,de),e(W,S),e(W,ce),e(ce,pe),g(l,we,_),g(l,se,_),e(se,Z),e(Z,fe),k(re,fe,null),e(se,L),e(se,me),e(me,$e),g(l,te,_),g(l,C,_),e(C,U),e(C,ae),e(ae,Q),e(C,Ee),e(C,le),e(le,O),e(C,Fe),e(C,ge),e(ge,I),e(C,Be),g(l,P,_),g(l,he,_),e(he,je),g(l,V,_),g(l,ue,_),e(ue,_e),e(_e,N),g(l,Te,_),g(l,X,_),e(X,De),g(l,oe,_),g(l,J,_),e(J,be),e(be,z),e(z,xe),e(z,ve),e(ve,y),e(z,D),e(z,qe),e(qe,ne),e(z,Se),e(z,Xe),e(Xe,x),e(z,Le),e(J,Qe),e(J,Pe),e(Pe,Ne),e(Ne,Oe),e(Ne,A),e(A,H),e(Ne,He),e(J,Ye),e(J,G),e(G,Ve),e(Ve,Ke),e(G,Ce),e(G,Je),e(Je,ee),e(ee,et),e(Je,O_),e(Je,Qp),e(Qp,H_),e(Je,Y_),e(Je,Op),e(Op,K_),g(l,fm,_),g(l,Wt,_),e(Wt,eb),e(Wt,Ir),e(Ir,tb),e(Wt,ob),e(Wt,Wr),e(Wr,sb),e(Wt,nb),e(Wt,Ar),e(Ar,rb),e(Wt,ab),g(l,mm,_),g(l,Lo,_),e(Lo,qs),e(qs,Hp),k(Nr,Hp,null),e(Lo,lb),e(Lo,Yp),e(Yp,ib),g(l,gm,_),g(l,lc,_),e(lc,db),g(l,_m,_),k(Rr,l,_),g(l,bm,_),g(l,Ue,_),e(Ue,Zr),e(Zr,cb),e(Zr,Gr),e(Gr,pb),e(Zr,hb),e(Ue,ub),e(Ue,qr),e(qr,fb),e(qr,Xr),e(Xr,mb),e(qr,gb),e(Ue,_b),e(Ue,Pr),e(Pr,bb),e(Pr,Vr),e(Vr,vb),e(Pr,yb),e(Ue,wb),e(Ue,Sr),e(Sr,Tb),e(Sr,Lr),e(Lr,kb),e(Sr,Mb),e(Ue,$b),e(Ue,Qr),e(Qr,Eb),e(Qr,Or),e(Or,Fb),e(Qr,Bb),e(Ue,jb),e(Ue,Hr),e(Hr,Db),e(Hr,Yr),e(Yr,xb),e(Hr,Cb),e(Ue,Jb),e(Ue,Kr),e(Kr,zb),e(Kr,ea),e(ea,Ub),e(Kr,Ib),e(Ue,Wb),e(Ue,go),e(go,ic),e(ic,Ab),e(go,Nb),e(go,ta),e(ta,Rb),e(go,Zb),e(go,oa),e(oa,Gb),e(go,qb),e(Ue,Xb),e(Ue,_o),e(_o,dc),e(dc,Pb),e(_o,Vb),e(_o,sa),e(sa,Sb),e(_o,Lb),e(_o,na),e(na,Qb),e(_o,Ob),e(Ue,Hb),e(Ue,bo),e(bo,cc),e(cc,Yb),e(bo,Kb),e(bo,ra),e(ra,ev),e(bo,tv),e(bo,aa),e(aa,ov),e(bo,sv),e(Ue,nv),e(Ue,Kp),e(Kp,pc),e(pc,rv),g(l,vm,_),k(la,l,_),g(l,ym,_),g(l,wt,_),e(wt,vo),e(vo,hc),e(hc,av),e(vo,lv),e(vo,ia),e(ia,iv),e(vo,dv),e(vo,da),e(da,cv),e(vo,pv),e(wt,hv),e(wt,yo),e(yo,uc),e(uc,uv),e(yo,fv),e(yo,ca),e(ca,mv),e(yo,gv),e(yo,pa),e(pa,_v),e(yo,bv),e(wt,vv),e(wt,Xs),e(Xs,fc),e(fc,yv),e(Xs,wv),e(Xs,ha),e(ha,Tv),e(Xs,kv),e(wt,Mv),e(wt,mc),e(mc,ua),e(ua,$v),e(mc,Ev),e(wt,Fv),e(wt,eh),e(eh,gc),e(gc,Bv),g(l,wm,_),k(fa,l,_),g(l,Tm,_),g(l,Tt,_),e(Tt,wo),e(wo,_c),e(_c,jv),e(wo,Dv),e(wo,ma),e(ma,xv),e(wo,Cv),e(wo,ga),e(ga,Jv),e(wo,zv),e(Tt,Uv),e(Tt,To),e(To,bc),e(bc,Iv),e(To,Wv),e(To,_a),e(_a,Av),e(To,Nv),e(To,ba),e(ba,Rv),e(To,Zv),e(Tt,Gv),e(Tt,ko),e(ko,vc),e(vc,qv),e(ko,Xv),e(ko,va),e(va,Pv),e(ko,Vv),e(ko,ya),e(ya,Sv),e(ko,Lv),e(Tt,Qv),e(Tt,yc),e(yc,wa),e(wa,Ov),e(yc,Hv),e(Tt,Yv),e(Tt,th),e(th,wc),e(wc,Kv),g(l,km,_),k(Ta,l,_),g(l,Mm,_),g(l,kt,_),e(kt,Mo),e(Mo,Tc),e(Tc,ey),e(Mo,ty),e(Mo,ka),e(ka,oy),e(Mo,sy),e(Mo,Ma),e(Ma,ny),e(Mo,ry),e(kt,ay),e(kt,$o),e($o,kc),e(kc,ly),e($o,iy),e($o,$a),e($a,dy),e($o,cy),e($o,Ea),e(Ea,py),e($o,hy),e(kt,uy),e(kt,Ps),e(Ps,Mc),e(Mc,fy),e(Ps,my),e(Ps,Fa),e(Fa,gy),e(Ps,_y),e(kt,by),e(kt,$c),e($c,Ba),e(Ba,vy),e($c,yy),e(kt,wy),e(kt,oh),e(oh,Ec),e(Ec,Ty),g(l,$m,_),g(l,Fc,_),e(Fc,sh),e(sh,ky),g(l,Em,_),g(l,Eo,_),e(Eo,Fo),e(Fo,Bc),e(Bc,My),e(Fo,$y),e(Fo,ja),e(ja,Ey),e(Fo,Fy),e(Fo,Da),e(Da,By),e(Fo,jy),e(Eo,Dy),e(Eo,Bo),e(Bo,jc),e(jc,xy),e(Bo,Cy),e(Bo,xa),e(xa,Jy),e(Bo,zy),e(Bo,Ca),e(Ca,Uy),e(Bo,Iy),e(Eo,Wy),e(Eo,nh),e(nh,Dc),e(Dc,Ay),g(l,Fm,_),g(l,xc,_),e(xc,Ny),g(l,Bm,_),g(l,jo,_),e(jo,Ja),e(Ja,Ry),e(Ja,za),e(za,Zy),e(Ja,Gy),e(jo,qy),e(jo,Ua),e(Ua,Xy),e(Ua,Ia),e(Ia,Py),e(Ua,Vy),e(jo,Sy),e(jo,Wa),e(Wa,Ly),e(Wa,Aa),e(Aa,Qy),e(Wa,Oy),g(l,jm,_),g(l,Cc,_),e(Cc,Hy),g(l,Dm,_),g(l,Vs,_),e(Vs,Na),e(Na,Yy),e(Na,Ra),e(Ra,Ky),e(Na,ew),e(Vs,tw),e(Vs,Za),e(Za,ow),e(Za,Ga),e(Ga,sw),e(Za,nw),g(l,xm,_),g(l,Jc,_),e(Jc,rw),g(l,Cm,_),g(l,Do,_),e(Do,qa),e(qa,aw),e(qa,Xa),e(Xa,lw),e(qa,iw),e(Do,dw),e(Do,Pa),e(Pa,cw),e(Pa,Va),e(Va,pw),e(Pa,hw),e(Do,uw),e(Do,Sa),e(Sa,fw),e(Sa,La),e(La,mw),e(Sa,gw),g(l,Jm,_),g(l,Qo,_),e(Qo,Ss),e(Ss,rh),k(Qa,rh,null),e(Qo,_w),e(Qo,ah),e(ah,bw),g(l,zm,_),g(l,It,_),k(Oa,It,null),e(It,vw),e(It,ro),e(ro,yw),e(ro,zc),e(zc,ww),e(ro,Tw),e(ro,Uc),e(Uc,kw),e(ro,Mw),e(ro,Ha),e(Ha,$w),e(ro,Ew),e(It,Fw),e(It,Oo),e(Oo,Bw),e(Oo,Ic),e(Ic,jw),e(Oo,Dw),e(Oo,Wc),e(Wc,xw),e(Oo,Cw),e(It,Jw),k(Ls,It,null),g(l,Um,_),g(l,Ho,_),e(Ho,Qs),e(Qs,lh),k(Ya,lh,null),e(Ho,zw),e(Ho,ih),e(ih,Uw),g(l,Im,_),g(l,tt,_),k(Ka,tt,null),e(tt,Iw),e(tt,dh),e(dh,Ww),e(tt,Aw),e(tt,el),e(el,Nw),e(el,Ac),e(Ac,Rw),e(el,Zw),e(tt,Gw),e(tt,xo),k(tl,xo,null),e(xo,qw),e(xo,ch),e(ch,Xw),e(xo,Pw),e(xo,ol),e(ol,Nc),e(Nc,Vw),e(Nc,ph),e(ph,Sw),e(ol,Lw),e(ol,Rc),e(Rc,Qw),e(Rc,hh),e(hh,Ow),e(tt,Hw),e(tt,Os),k(sl,Os,null),e(Os,Yw),e(Os,uh),e(uh,Kw),e(tt,eT),e(tt,At),k(nl,At,null),e(At,tT),e(At,fh),e(fh,oT),e(At,sT),k(Hs,At,null),e(At,nT),e(At,Yo),e(Yo,rT),e(Yo,mh),e(mh,aT),e(Yo,lT),e(Yo,gh),e(gh,iT),e(Yo,dT),e(tt,cT),e(tt,Ys),k(rl,Ys,null),e(Ys,pT),e(Ys,al),e(al,hT),e(al,_h),e(_h,uT),e(al,fT),g(l,Wm,_),g(l,Ko,_),e(Ko,Ks),e(Ks,bh),k(ll,bh,null),e(Ko,mT),e(Ko,vh),e(vh,gT),g(l,Am,_),g(l,ft,_),k(il,ft,null),e(ft,_T),e(ft,dl),e(dl,bT),e(dl,yh),e(yh,vT),e(dl,yT),e(ft,wT),e(ft,cl),e(cl,TT),e(cl,Zc),e(Zc,kT),e(cl,MT),e(ft,$T),e(ft,Co),k(pl,Co,null),e(Co,ET),e(Co,wh),e(wh,FT),e(Co,BT),e(Co,hl),e(hl,Gc),e(Gc,jT),e(Gc,Th),e(Th,DT),e(hl,xT),e(hl,qc),e(qc,CT),e(qc,kh),e(kh,JT),e(ft,zT),e(ft,Nt),k(ul,Nt,null),e(Nt,UT),e(Nt,Mh),e(Mh,IT),e(Nt,WT),k(en,Nt,null),e(Nt,AT),e(Nt,es),e(es,NT),e(es,$h),e($h,RT),e(es,ZT),e(es,Eh),e(Eh,GT),e(es,qT),g(l,Nm,_),g(l,ts,_),e(ts,tn),e(tn,Fh),k(fl,Fh,null),e(ts,XT),e(ts,Bh),e(Bh,PT),g(l,Rm,_),g(l,mt,_),k(ml,mt,null),e(mt,VT),e(mt,jh),e(jh,ST),e(mt,LT),e(mt,gl),e(gl,QT),e(gl,Xc),e(Xc,OT),e(gl,HT),e(mt,YT),e(mt,_l),e(_l,KT),e(_l,bl),e(bl,ek),e(_l,tk),e(mt,ok),e(mt,Rt),k(vl,Rt,null),e(Rt,sk),e(Rt,os),e(os,nk),e(os,Pc),e(Pc,rk),e(os,ak),e(os,Dh),e(Dh,lk),e(os,ik),e(Rt,dk),k(on,Rt,null),e(Rt,ck),k(sn,Rt,null),g(l,Zm,_),g(l,ss,_),e(ss,nn),e(nn,xh),k(yl,xh,null),e(ss,pk),e(ss,Ch),e(Ch,hk),g(l,Gm,_),g(l,gt,_),k(wl,gt,null),e(gt,uk),e(gt,Tl),e(Tl,fk),e(Tl,Jh),e(Jh,mk),e(Tl,gk),e(gt,_k),e(gt,kl),e(kl,bk),e(kl,Vc),e(Vc,vk),e(kl,yk),e(gt,wk),e(gt,Ml),e(Ml,Tk),e(Ml,$l),e($l,kk),e(Ml,Mk),e(gt,$k),e(gt,Zt),k(El,Zt,null),e(Zt,Ek),e(Zt,ns),e(ns,Fk),e(ns,Sc),e(Sc,Bk),e(ns,jk),e(ns,zh),e(zh,Dk),e(ns,xk),e(Zt,Ck),k(rn,Zt,null),e(Zt,Jk),k(an,Zt,null),g(l,qm,_),g(l,rs,_),e(rs,ln),e(ln,Uh),k(Fl,Uh,null),e(rs,zk),e(rs,Ih),e(Ih,Uk),g(l,Xm,_),g(l,_t,_),k(Bl,_t,null),e(_t,Ik),e(_t,Wh),e(Wh,Wk),e(_t,Ak),e(_t,jl),e(jl,Nk),e(jl,Lc),e(Lc,Rk),e(jl,Zk),e(_t,Gk),e(_t,Dl),e(Dl,qk),e(Dl,xl),e(xl,Xk),e(Dl,Pk),e(_t,Vk),e(_t,Mt),k(Cl,Mt,null),e(Mt,Sk),e(Mt,as),e(as,Lk),e(as,Qc),e(Qc,Qk),e(as,Ok),e(as,Ah),e(Ah,Hk),e(as,Yk),e(Mt,Kk),k(dn,Mt,null),e(Mt,eM),k(cn,Mt,null),e(Mt,tM),k(pn,Mt,null),g(l,Pm,_),g(l,ls,_),e(ls,hn),e(hn,Nh),k(Jl,Nh,null),e(ls,oM),e(ls,Rh),e(Rh,sM),g(l,Vm,_),g(l,bt,_),k(zl,bt,null),e(bt,nM),e(bt,Zh),e(Zh,rM),e(bt,aM),e(bt,Ul),e(Ul,lM),e(Ul,Oc),e(Oc,iM),e(Ul,dM),e(bt,cM),e(bt,Il),e(Il,pM),e(Il,Wl),e(Wl,hM),e(Il,uM),e(bt,fM),e(bt,Gt),k(Al,Gt,null),e(Gt,mM),e(Gt,is),e(is,gM),e(is,Hc),e(Hc,_M),e(is,bM),e(is,Gh),e(Gh,vM),e(is,yM),e(Gt,wM),k(un,Gt,null),e(Gt,TM),k(fn,Gt,null),g(l,Sm,_),g(l,ds,_),e(ds,mn),e(mn,qh),k(Nl,qh,null),e(ds,kM),e(ds,Xh),e(Xh,MM),g(l,Lm,_),g(l,vt,_),k(Rl,vt,null),e(vt,$M),e(vt,Ph),e(Ph,EM),e(vt,FM),e(vt,Zl),e(Zl,BM),e(Zl,Yc),e(Yc,jM),e(Zl,DM),e(vt,xM),e(vt,Gl),e(Gl,CM),e(Gl,ql),e(ql,JM),e(Gl,zM),e(vt,UM),e(vt,qt),k(Xl,qt,null),e(qt,IM),e(qt,cs),e(cs,WM),e(cs,Kc),e(Kc,AM),e(cs,NM),e(cs,Vh),e(Vh,RM),e(cs,ZM),e(qt,GM),k(gn,qt,null),e(qt,qM),k(_n,qt,null),g(l,Qm,_),g(l,ps,_),e(ps,bn),e(bn,Sh),k(Pl,Sh,null),e(ps,XM),e(ps,Lh),e(Lh,PM),g(l,Om,_),g(l,yt,_),k(Vl,yt,null),e(yt,VM),e(yt,hs),e(hs,SM),e(hs,Qh),e(Qh,LM),e(hs,QM),e(hs,Oh),e(Oh,OM),e(hs,HM),e(yt,YM),e(yt,Sl),e(Sl,KM),e(Sl,ep),e(ep,e2),e(Sl,t2),e(yt,o2),e(yt,Ll),e(Ll,s2),e(Ll,Ql),e(Ql,n2),e(Ll,r2),e(yt,a2),e(yt,Xt),k(Ol,Xt,null),e(Xt,l2),e(Xt,us),e(us,i2),e(us,tp),e(tp,d2),e(us,c2),e(us,Hh),e(Hh,p2),e(us,h2),e(Xt,u2),k(vn,Xt,null),e(Xt,f2),k(yn,Xt,null),g(l,Hm,_),g(l,fs,_),e(fs,wn),e(wn,Yh),k(Hl,Yh,null),e(fs,m2),e(fs,Kh),e(Kh,g2),g(l,Ym,_),g(l,it,_),k(Yl,it,null),e(it,_2),e(it,eu),e(eu,b2),e(it,v2),e(it,Kl),e(Kl,y2),e(Kl,op),e(op,w2),e(Kl,T2),e(it,k2),e(it,ei),e(ei,M2),e(ei,ti),e(ti,$2),e(ei,E2),e(it,F2),k(Tn,it,null),e(it,B2),e(it,Pt),k(oi,Pt,null),e(Pt,j2),e(Pt,ms),e(ms,D2),e(ms,sp),e(sp,x2),e(ms,C2),e(ms,tu),e(tu,J2),e(ms,z2),e(Pt,U2),k(kn,Pt,null),e(Pt,I2),k(Mn,Pt,null),g(l,Km,_),g(l,gs,_),e(gs,$n),e($n,ou),k(si,ou,null),e(gs,W2),e(gs,su),e(su,A2),g(l,eg,_),g(l,dt,_),k(ni,dt,null),e(dt,N2),e(dt,ri),e(ri,R2),e(ri,nu),e(nu,Z2),e(ri,G2),e(dt,q2),e(dt,ai),e(ai,X2),e(ai,np),e(np,P2),e(ai,V2),e(dt,S2),e(dt,li),e(li,L2),e(li,ii),e(ii,Q2),e(li,O2),e(dt,H2),k(En,dt,null),e(dt,Y2),e(dt,$t),k(di,$t,null),e($t,K2),e($t,_s),e(_s,e1),e(_s,rp),e(rp,t1),e(_s,o1),e(_s,ru),e(ru,s1),e(_s,n1),e($t,r1),k(Fn,$t,null),e($t,a1),k(Bn,$t,null),e($t,l1),k(jn,$t,null),g(l,tg,_),g(l,bs,_),e(bs,Dn),e(Dn,au),k(ci,au,null),e(bs,i1),e(bs,lu),e(lu,d1),g(l,og,_),g(l,ct,_),k(pi,ct,null),e(ct,c1),e(ct,iu),e(iu,p1),e(ct,h1),e(ct,hi),e(hi,u1),e(hi,ap),e(ap,f1),e(hi,m1),e(ct,g1),e(ct,ui),e(ui,_1),e(ui,fi),e(fi,b1),e(ui,v1),e(ct,y1),k(xn,ct,null),e(ct,w1),e(ct,Et),k(mi,Et,null),e(Et,T1),e(Et,vs),e(vs,k1),e(vs,lp),e(lp,M1),e(vs,$1),e(vs,du),e(du,E1),e(vs,F1),e(Et,B1),k(Cn,Et,null),e(Et,j1),k(Jn,Et,null),e(Et,D1),k(zn,Et,null),g(l,sg,_),g(l,ys,_),e(ys,Un),e(Un,cu),k(gi,cu,null),e(ys,x1),e(ys,pu),e(pu,C1),g(l,ng,_),g(l,pt,_),k(_i,pt,null),e(pt,J1),e(pt,hu),e(hu,z1),e(pt,U1),e(pt,bi),e(bi,I1),e(bi,ip),e(ip,W1),e(bi,A1),e(pt,N1),e(pt,vi),e(vi,R1),e(vi,yi),e(yi,Z1),e(vi,G1),e(pt,q1),k(In,pt,null),e(pt,X1),e(pt,Vt),k(wi,Vt,null),e(Vt,P1),e(Vt,ws),e(ws,V1),e(ws,dp),e(dp,S1),e(ws,L1),e(ws,uu),e(uu,Q1),e(ws,O1),e(Vt,H1),k(Wn,Vt,null),e(Vt,Y1),k(An,Vt,null),g(l,rg,_),g(l,Ts,_),e(Ts,Nn),e(Nn,fu),k(Ti,fu,null),e(Ts,K1),e(Ts,mu),e(mu,e0),g(l,ag,_),g(l,ht,_),k(ki,ht,null),e(ht,t0),e(ht,gu),e(gu,o0),e(ht,s0),e(ht,Mi),e(Mi,n0),e(Mi,cp),e(cp,r0),e(Mi,a0),e(ht,l0),e(ht,$i),e($i,i0),e($i,Ei),e(Ei,d0),e($i,c0),e(ht,p0),k(Rn,ht,null),e(ht,h0),e(ht,Ft),k(Fi,Ft,null),e(Ft,u0),e(Ft,ks),e(ks,f0),e(ks,pp),e(pp,m0),e(ks,g0),e(ks,_u),e(_u,_0),e(ks,b0),e(Ft,v0),k(Zn,Ft,null),e(Ft,y0),k(Gn,Ft,null),e(Ft,w0),k(qn,Ft,null),g(l,lg,_),g(l,Ms,_),e(Ms,Xn),e(Xn,bu),k(Bi,bu,null),e(Ms,T0),e(Ms,vu),e(vu,k0),g(l,ig,_),g(l,ut,_),k(ji,ut,null),e(ut,M0),e(ut,$s),e($s,$0),e($s,yu),e(yu,E0),e($s,F0),e($s,wu),e(wu,B0),e($s,j0),e(ut,D0),e(ut,Di),e(Di,x0),e(Di,hp),e(hp,C0),e(Di,J0),e(ut,z0),e(ut,xi),e(xi,U0),e(xi,Ci),e(Ci,I0),e(xi,W0),e(ut,A0),k(Pn,ut,null),e(ut,N0),e(ut,Bt),k(Ji,Bt,null),e(Bt,R0),e(Bt,Es),e(Es,Z0),e(Es,up),e(up,G0),e(Es,q0),e(Es,Tu),e(Tu,X0),e(Es,P0),e(Bt,V0),k(Vn,Bt,null),e(Bt,S0),k(Sn,Bt,null),e(Bt,L0),k(Ln,Bt,null),g(l,dg,_),g(l,Fs,_),e(Fs,Qn),e(Qn,ku),k(zi,ku,null),e(Fs,Q0),e(Fs,Mu),e(Mu,O0),g(l,cg,_),g(l,ot,_),k(Ui,ot,null),e(ot,H0),e(ot,$u),e($u,Y0),e(ot,K0),e(ot,Ii),e(Ii,e$),e(Ii,fp),e(fp,t$),e(Ii,o$),e(ot,s$),e(ot,Wi),e(Wi,n$),e(Wi,Ai),e(Ai,r$),e(Wi,a$),e(ot,l$),e(ot,Eu),e(Eu,i$),e(ot,d$),e(ot,ao),e(ao,Fu),e(Fu,Ni),e(Ni,c$),e(ao,p$),e(ao,Bu),e(Bu,Ri),e(Ri,h$),e(ao,u$),e(ao,ju),e(ju,Zi),e(Zi,f$),e(ao,m$),e(ao,Du),e(Du,Gi),e(Gi,g$),e(ot,_$),e(ot,St),k(qi,St,null),e(St,b$),e(St,Bs),e(Bs,v$),e(Bs,xu),e(xu,y$),e(Bs,w$),e(Bs,Cu),e(Cu,T$),e(Bs,k$),e(St,M$),k(On,St,null),e(St,$$),k(Hn,St,null),g(l,pg,_),g(l,js,_),e(js,Yn),e(Yn,Ju),k(Xi,Ju,null),e(js,E$),e(js,zu),e(zu,F$),g(l,hg,_),g(l,st,_),k(Pi,st,null),e(st,B$),e(st,Vi),e(Vi,j$),e(Vi,Uu),e(Uu,D$),e(Vi,x$),e(st,C$),e(st,Si),e(Si,J$),e(Si,mp),e(mp,z$),e(Si,U$),e(st,I$),e(st,Li),e(Li,W$),e(Li,Qi),e(Qi,A$),e(Li,N$),e(st,R$),e(st,Iu),e(Iu,Z$),e(st,G$),e(st,lo),e(lo,Wu),e(Wu,Oi),e(Oi,q$),e(lo,X$),e(lo,Au),e(Au,Hi),e(Hi,P$),e(lo,V$),e(lo,Nu),e(Nu,Yi),e(Yi,S$),e(lo,L$),e(lo,Ru),e(Ru,Ki),e(Ki,Q$),e(st,O$),e(st,Lt),k(ed,Lt,null),e(Lt,H$),e(Lt,Ds),e(Ds,Y$),e(Ds,Zu),e(Zu,K$),e(Ds,eE),e(Ds,Gu),e(Gu,tE),e(Ds,oE),e(Lt,sE),k(Kn,Lt,null),e(Lt,nE),k(er,Lt,null),g(l,ug,_),g(l,xs,_),e(xs,tr),e(tr,qu),k(td,qu,null),e(xs,rE),e(xs,Xu),e(Xu,aE),g(l,fg,_),g(l,nt,_),k(od,nt,null),e(nt,lE),e(nt,Pu),e(Pu,iE),e(nt,dE),e(nt,sd),e(sd,cE),e(sd,gp),e(gp,pE),e(sd,hE),e(nt,uE),e(nt,nd),e(nd,fE),e(nd,rd),e(rd,mE),e(nd,gE),e(nt,_E),e(nt,Vu),e(Vu,bE),e(nt,vE),e(nt,io),e(io,Su),e(Su,ad),e(ad,yE),e(io,wE),e(io,Lu),e(Lu,ld),e(ld,TE),e(io,kE),e(io,Qu),e(Qu,id),e(id,ME),e(io,$E),e(io,Ou),e(Ou,dd),e(dd,EE),e(nt,FE),e(nt,Qt),k(cd,Qt,null),e(Qt,BE),e(Qt,Cs),e(Cs,jE),e(Cs,Hu),e(Hu,DE),e(Cs,xE),e(Cs,Yu),e(Yu,CE),e(Cs,JE),e(Qt,zE),k(or,Qt,null),e(Qt,UE),k(sr,Qt,null),g(l,mg,_),g(l,Js,_),e(Js,nr),e(nr,Ku),k(pd,Ku,null),e(Js,IE),e(Js,ef),e(ef,WE),g(l,gg,_),g(l,rt,_),k(hd,rt,null),e(rt,AE),e(rt,tf),e(tf,NE),e(rt,RE),e(rt,ud),e(ud,ZE),e(ud,_p),e(_p,GE),e(ud,qE),e(rt,XE),e(rt,fd),e(fd,PE),e(fd,md),e(md,VE),e(fd,SE),e(rt,LE),e(rt,of),e(of,QE),e(rt,OE),e(rt,co),e(co,sf),e(sf,gd),e(gd,HE),e(co,YE),e(co,nf),e(nf,_d),e(_d,KE),e(co,eF),e(co,rf),e(rf,bd),e(bd,tF),e(co,oF),e(co,af),e(af,vd),e(vd,sF),e(rt,nF),e(rt,Ot),k(yd,Ot,null),e(Ot,rF),e(Ot,zs),e(zs,aF),e(zs,lf),e(lf,lF),e(zs,iF),e(zs,df),e(df,dF),e(zs,cF),e(Ot,pF),k(rr,Ot,null),e(Ot,hF),k(ar,Ot,null),g(l,_g,_),g(l,Us,_),e(Us,lr),e(lr,cf),k(wd,cf,null),e(Us,uF),e(Us,pf),e(pf,fF),g(l,bg,_),g(l,at,_),k(Td,at,null),e(at,mF),e(at,hf),e(hf,gF),e(at,_F),e(at,kd),e(kd,bF),e(kd,bp),e(bp,vF),e(kd,yF),e(at,wF),e(at,Md),e(Md,TF),e(Md,$d),e($d,kF),e(Md,MF),e(at,$F),e(at,uf),e(uf,EF),e(at,FF),e(at,po),e(po,ff),e(ff,Ed),e(Ed,BF),e(po,jF),e(po,mf),e(mf,Fd),e(Fd,DF),e(po,xF),e(po,gf),e(gf,Bd),e(Bd,CF),e(po,JF),e(po,_f),e(_f,jd),e(jd,zF),e(at,UF),e(at,Ht),k(Dd,Ht,null),e(Ht,IF),e(Ht,Is),e(Is,WF),e(Is,bf),e(bf,AF),e(Is,NF),e(Is,vf),e(vf,RF),e(Is,ZF),e(Ht,GF),k(ir,Ht,null),e(Ht,qF),k(dr,Ht,null),g(l,vg,_),g(l,Ws,_),e(Ws,cr),e(cr,yf),k(xd,yf,null),e(Ws,XF),e(Ws,wf),e(wf,PF),g(l,yg,_),g(l,lt,_),k(Cd,lt,null),e(lt,VF),e(lt,As),e(As,SF),e(As,Tf),e(Tf,LF),e(As,QF),e(As,kf),e(kf,OF),e(As,HF),e(lt,YF),e(lt,Jd),e(Jd,KF),e(Jd,vp),e(vp,eB),e(Jd,tB),e(lt,oB),e(lt,zd),e(zd,sB),e(zd,Ud),e(Ud,nB),e(zd,rB),e(lt,aB),e(lt,Mf),e(Mf,lB),e(lt,iB),e(lt,ho),e(ho,$f),e($f,Id),e(Id,dB),e(ho,cB),e(ho,Ef),e(Ef,Wd),e(Wd,pB),e(ho,hB),e(ho,Ff),e(Ff,Ad),e(Ad,uB),e(ho,fB),e(ho,Bf),e(Bf,Nd),e(Nd,mB),e(lt,gB),e(lt,Yt),k(Rd,Yt,null),e(Yt,_B),e(Yt,Ns),e(Ns,bB),e(Ns,jf),e(jf,vB),e(Ns,yB),e(Ns,Df),e(Df,wB),e(Ns,TB),e(Yt,kB),k(pr,Yt,null),e(Yt,MB),k(hr,Yt,null),wg=!0},p(l,[_]){const Zd={};_&2&&(Zd.$$scope={dirty:_,ctx:l}),Ls.$set(Zd);const xf={};_&2&&(xf.$$scope={dirty:_,ctx:l}),Hs.$set(xf);const Cf={};_&2&&(Cf.$$scope={dirty:_,ctx:l}),en.$set(Cf);const Jf={};_&2&&(Jf.$$scope={dirty:_,ctx:l}),on.$set(Jf);const Rs={};_&2&&(Rs.$$scope={dirty:_,ctx:l}),sn.$set(Rs);const zf={};_&2&&(zf.$$scope={dirty:_,ctx:l}),rn.$set(zf);const Uf={};_&2&&(Uf.$$scope={dirty:_,ctx:l}),an.$set(Uf);const If={};_&2&&(If.$$scope={dirty:_,ctx:l}),dn.$set(If);const Gd={};_&2&&(Gd.$$scope={dirty:_,ctx:l}),cn.$set(Gd);const Wf={};_&2&&(Wf.$$scope={dirty:_,ctx:l}),pn.$set(Wf);const Af={};_&2&&(Af.$$scope={dirty:_,ctx:l}),un.$set(Af);const Nf={};_&2&&(Nf.$$scope={dirty:_,ctx:l}),fn.$set(Nf);const uo={};_&2&&(uo.$$scope={dirty:_,ctx:l}),gn.$set(uo);const Rf={};_&2&&(Rf.$$scope={dirty:_,ctx:l}),_n.$set(Rf);const Zf={};_&2&&(Zf.$$scope={dirty:_,ctx:l}),vn.$set(Zf);const Gf={};_&2&&(Gf.$$scope={dirty:_,ctx:l}),yn.$set(Gf);const qf={};_&2&&(qf.$$scope={dirty:_,ctx:l}),Tn.$set(qf);const Xf={};_&2&&(Xf.$$scope={dirty:_,ctx:l}),kn.$set(Xf);const Pf={};_&2&&(Pf.$$scope={dirty:_,ctx:l}),Mn.$set(Pf);const Vf={};_&2&&(Vf.$$scope={dirty:_,ctx:l}),En.$set(Vf);const Zs={};_&2&&(Zs.$$scope={dirty:_,ctx:l}),Fn.$set(Zs);const Sf={};_&2&&(Sf.$$scope={dirty:_,ctx:l}),Bn.$set(Sf);const fo={};_&2&&(fo.$$scope={dirty:_,ctx:l}),jn.$set(fo);const Lf={};_&2&&(Lf.$$scope={dirty:_,ctx:l}),xn.$set(Lf);const Qf={};_&2&&(Qf.$$scope={dirty:_,ctx:l}),Cn.$set(Qf);const Of={};_&2&&(Of.$$scope={dirty:_,ctx:l}),Jn.$set(Of);const Hf={};_&2&&(Hf.$$scope={dirty:_,ctx:l}),zn.$set(Hf);const qd={};_&2&&(qd.$$scope={dirty:_,ctx:l}),In.$set(qd);const Yf={};_&2&&(Yf.$$scope={dirty:_,ctx:l}),Wn.$set(Yf);const Xd={};_&2&&(Xd.$$scope={dirty:_,ctx:l}),An.$set(Xd);const Kf={};_&2&&(Kf.$$scope={dirty:_,ctx:l}),Rn.$set(Kf);const Gs={};_&2&&(Gs.$$scope={dirty:_,ctx:l}),Zn.$set(Gs);const em={};_&2&&(em.$$scope={dirty:_,ctx:l}),Gn.$set(em);const tm={};_&2&&(tm.$$scope={dirty:_,ctx:l}),qn.$set(tm);const om={};_&2&&(om.$$scope={dirty:_,ctx:l}),Pn.$set(om);const mo={};_&2&&(mo.$$scope={dirty:_,ctx:l}),Vn.$set(mo);const sm={};_&2&&(sm.$$scope={dirty:_,ctx:l}),Sn.$set(sm);const nm={};_&2&&(nm.$$scope={dirty:_,ctx:l}),Ln.$set(nm);const rm={};_&2&&(rm.$$scope={dirty:_,ctx:l}),On.$set(rm);const Pd={};_&2&&(Pd.$$scope={dirty:_,ctx:l}),Hn.$set(Pd);const am={};_&2&&(am.$$scope={dirty:_,ctx:l}),Kn.$set(am);const lm={};_&2&&(lm.$$scope={dirty:_,ctx:l}),er.$set(lm);const im={};_&2&&(im.$$scope={dirty:_,ctx:l}),or.$set(im);const dm={};_&2&&(dm.$$scope={dirty:_,ctx:l}),sr.$set(dm);const Re={};_&2&&(Re.$$scope={dirty:_,ctx:l}),rr.$set(Re);const Vd={};_&2&&(Vd.$$scope={dirty:_,ctx:l}),ar.$set(Vd);const cm={};_&2&&(cm.$$scope={dirty:_,ctx:l}),ir.$set(cm);const Sd={};_&2&&(Sd.$$scope={dirty:_,ctx:l}),dr.$set(Sd);const pm={};_&2&&(pm.$$scope={dirty:_,ctx:l}),pr.$set(pm);const Ld={};_&2&&(Ld.$$scope={dirty:_,ctx:l}),hr.$set(Ld)},i(l){wg||(M(i.$$.fragment,l),M(re.$$.fragment,l),M(Nr.$$.fragment,l),M(Rr.$$.fragment,l),M(la.$$.fragment,l),M(fa.$$.fragment,l),M(Ta.$$.fragment,l),M(Qa.$$.fragment,l),M(Oa.$$.fragment,l),M(Ls.$$.fragment,l),M(Ya.$$.fragment,l),M(Ka.$$.fragment,l),M(tl.$$.fragment,l),M(sl.$$.fragment,l),M(nl.$$.fragment,l),M(Hs.$$.fragment,l),M(rl.$$.fragment,l),M(ll.$$.fragment,l),M(il.$$.fragment,l),M(pl.$$.fragment,l),M(ul.$$.fragment,l),M(en.$$.fragment,l),M(fl.$$.fragment,l),M(ml.$$.fragment,l),M(vl.$$.fragment,l),M(on.$$.fragment,l),M(sn.$$.fragment,l),M(yl.$$.fragment,l),M(wl.$$.fragment,l),M(El.$$.fragment,l),M(rn.$$.fragment,l),M(an.$$.fragment,l),M(Fl.$$.fragment,l),M(Bl.$$.fragment,l),M(Cl.$$.fragment,l),M(dn.$$.fragment,l),M(cn.$$.fragment,l),M(pn.$$.fragment,l),M(Jl.$$.fragment,l),M(zl.$$.fragment,l),M(Al.$$.fragment,l),M(un.$$.fragment,l),M(fn.$$.fragment,l),M(Nl.$$.fragment,l),M(Rl.$$.fragment,l),M(Xl.$$.fragment,l),M(gn.$$.fragment,l),M(_n.$$.fragment,l),M(Pl.$$.fragment,l),M(Vl.$$.fragment,l),M(Ol.$$.fragment,l),M(vn.$$.fragment,l),M(yn.$$.fragment,l),M(Hl.$$.fragment,l),M(Yl.$$.fragment,l),M(Tn.$$.fragment,l),M(oi.$$.fragment,l),M(kn.$$.fragment,l),M(Mn.$$.fragment,l),M(si.$$.fragment,l),M(ni.$$.fragment,l),M(En.$$.fragment,l),M(di.$$.fragment,l),M(Fn.$$.fragment,l),M(Bn.$$.fragment,l),M(jn.$$.fragment,l),M(ci.$$.fragment,l),M(pi.$$.fragment,l),M(xn.$$.fragment,l),M(mi.$$.fragment,l),M(Cn.$$.fragment,l),M(Jn.$$.fragment,l),M(zn.$$.fragment,l),M(gi.$$.fragment,l),M(_i.$$.fragment,l),M(In.$$.fragment,l),M(wi.$$.fragment,l),M(Wn.$$.fragment,l),M(An.$$.fragment,l),M(Ti.$$.fragment,l),M(ki.$$.fragment,l),M(Rn.$$.fragment,l),M(Fi.$$.fragment,l),M(Zn.$$.fragment,l),M(Gn.$$.fragment,l),M(qn.$$.fragment,l),M(Bi.$$.fragment,l),M(ji.$$.fragment,l),M(Pn.$$.fragment,l),M(Ji.$$.fragment,l),M(Vn.$$.fragment,l),M(Sn.$$.fragment,l),M(Ln.$$.fragment,l),M(zi.$$.fragment,l),M(Ui.$$.fragment,l),M(qi.$$.fragment,l),M(On.$$.fragment,l),M(Hn.$$.fragment,l),M(Xi.$$.fragment,l),M(Pi.$$.fragment,l),M(ed.$$.fragment,l),M(Kn.$$.fragment,l),M(er.$$.fragment,l),M(td.$$.fragment,l),M(od.$$.fragment,l),M(cd.$$.fragment,l),M(or.$$.fragment,l),M(sr.$$.fragment,l),M(pd.$$.fragment,l),M(hd.$$.fragment,l),M(yd.$$.fragment,l),M(rr.$$.fragment,l),M(ar.$$.fragment,l),M(wd.$$.fragment,l),M(Td.$$.fragment,l),M(Dd.$$.fragment,l),M(ir.$$.fragment,l),M(dr.$$.fragment,l),M(xd.$$.fragment,l),M(Cd.$$.fragment,l),M(Rd.$$.fragment,l),M(pr.$$.fragment,l),M(hr.$$.fragment,l),wg=!0)},o(l){$(i.$$.fragment,l),$(re.$$.fragment,l),$(Nr.$$.fragment,l),$(Rr.$$.fragment,l),$(la.$$.fragment,l),$(fa.$$.fragment,l),$(Ta.$$.fragment,l),$(Qa.$$.fragment,l),$(Oa.$$.fragment,l),$(Ls.$$.fragment,l),$(Ya.$$.fragment,l),$(Ka.$$.fragment,l),$(tl.$$.fragment,l),$(sl.$$.fragment,l),$(nl.$$.fragment,l),$(Hs.$$.fragment,l),$(rl.$$.fragment,l),$(ll.$$.fragment,l),$(il.$$.fragment,l),$(pl.$$.fragment,l),$(ul.$$.fragment,l),$(en.$$.fragment,l),$(fl.$$.fragment,l),$(ml.$$.fragment,l),$(vl.$$.fragment,l),$(on.$$.fragment,l),$(sn.$$.fragment,l),$(yl.$$.fragment,l),$(wl.$$.fragment,l),$(El.$$.fragment,l),$(rn.$$.fragment,l),$(an.$$.fragment,l),$(Fl.$$.fragment,l),$(Bl.$$.fragment,l),$(Cl.$$.fragment,l),$(dn.$$.fragment,l),$(cn.$$.fragment,l),$(pn.$$.fragment,l),$(Jl.$$.fragment,l),$(zl.$$.fragment,l),$(Al.$$.fragment,l),$(un.$$.fragment,l),$(fn.$$.fragment,l),$(Nl.$$.fragment,l),$(Rl.$$.fragment,l),$(Xl.$$.fragment,l),$(gn.$$.fragment,l),$(_n.$$.fragment,l),$(Pl.$$.fragment,l),$(Vl.$$.fragment,l),$(Ol.$$.fragment,l),$(vn.$$.fragment,l),$(yn.$$.fragment,l),$(Hl.$$.fragment,l),$(Yl.$$.fragment,l),$(Tn.$$.fragment,l),$(oi.$$.fragment,l),$(kn.$$.fragment,l),$(Mn.$$.fragment,l),$(si.$$.fragment,l),$(ni.$$.fragment,l),$(En.$$.fragment,l),$(di.$$.fragment,l),$(Fn.$$.fragment,l),$(Bn.$$.fragment,l),$(jn.$$.fragment,l),$(ci.$$.fragment,l),$(pi.$$.fragment,l),$(xn.$$.fragment,l),$(mi.$$.fragment,l),$(Cn.$$.fragment,l),$(Jn.$$.fragment,l),$(zn.$$.fragment,l),$(gi.$$.fragment,l),$(_i.$$.fragment,l),$(In.$$.fragment,l),$(wi.$$.fragment,l),$(Wn.$$.fragment,l),$(An.$$.fragment,l),$(Ti.$$.fragment,l),$(ki.$$.fragment,l),$(Rn.$$.fragment,l),$(Fi.$$.fragment,l),$(Zn.$$.fragment,l),$(Gn.$$.fragment,l),$(qn.$$.fragment,l),$(Bi.$$.fragment,l),$(ji.$$.fragment,l),$(Pn.$$.fragment,l),$(Ji.$$.fragment,l),$(Vn.$$.fragment,l),$(Sn.$$.fragment,l),$(Ln.$$.fragment,l),$(zi.$$.fragment,l),$(Ui.$$.fragment,l),$(qi.$$.fragment,l),$(On.$$.fragment,l),$(Hn.$$.fragment,l),$(Xi.$$.fragment,l),$(Pi.$$.fragment,l),$(ed.$$.fragment,l),$(Kn.$$.fragment,l),$(er.$$.fragment,l),$(td.$$.fragment,l),$(od.$$.fragment,l),$(cd.$$.fragment,l),$(or.$$.fragment,l),$(sr.$$.fragment,l),$(pd.$$.fragment,l),$(hd.$$.fragment,l),$(yd.$$.fragment,l),$(rr.$$.fragment,l),$(ar.$$.fragment,l),$(wd.$$.fragment,l),$(Td.$$.fragment,l),$(Dd.$$.fragment,l),$(ir.$$.fragment,l),$(dr.$$.fragment,l),$(xd.$$.fragment,l),$(Cd.$$.fragment,l),$(Rd.$$.fragment,l),$(pr.$$.fragment,l),$(hr.$$.fragment,l),wg=!1},d(l){t(d),l&&t(v),l&&t(f),E(i),l&&t(ye),l&&t(W),l&&t(we),l&&t(se),E(re),l&&t(te),l&&t(C),l&&t(P),l&&t(he),l&&t(V),l&&t(ue),l&&t(Te),l&&t(X),l&&t(oe),l&&t(J),l&&t(fm),l&&t(Wt),l&&t(mm),l&&t(Lo),E(Nr),l&&t(gm),l&&t(lc),l&&t(_m),E(Rr,l),l&&t(bm),l&&t(Ue),l&&t(vm),E(la,l),l&&t(ym),l&&t(wt),l&&t(wm),E(fa,l),l&&t(Tm),l&&t(Tt),l&&t(km),E(Ta,l),l&&t(Mm),l&&t(kt),l&&t($m),l&&t(Fc),l&&t(Em),l&&t(Eo),l&&t(Fm),l&&t(xc),l&&t(Bm),l&&t(jo),l&&t(jm),l&&t(Cc),l&&t(Dm),l&&t(Vs),l&&t(xm),l&&t(Jc),l&&t(Cm),l&&t(Do),l&&t(Jm),l&&t(Qo),E(Qa),l&&t(zm),l&&t(It),E(Oa),E(Ls),l&&t(Um),l&&t(Ho),E(Ya),l&&t(Im),l&&t(tt),E(Ka),E(tl),E(sl),E(nl),E(Hs),E(rl),l&&t(Wm),l&&t(Ko),E(ll),l&&t(Am),l&&t(ft),E(il),E(pl),E(ul),E(en),l&&t(Nm),l&&t(ts),E(fl),l&&t(Rm),l&&t(mt),E(ml),E(vl),E(on),E(sn),l&&t(Zm),l&&t(ss),E(yl),l&&t(Gm),l&&t(gt),E(wl),E(El),E(rn),E(an),l&&t(qm),l&&t(rs),E(Fl),l&&t(Xm),l&&t(_t),E(Bl),E(Cl),E(dn),E(cn),E(pn),l&&t(Pm),l&&t(ls),E(Jl),l&&t(Vm),l&&t(bt),E(zl),E(Al),E(un),E(fn),l&&t(Sm),l&&t(ds),E(Nl),l&&t(Lm),l&&t(vt),E(Rl),E(Xl),E(gn),E(_n),l&&t(Qm),l&&t(ps),E(Pl),l&&t(Om),l&&t(yt),E(Vl),E(Ol),E(vn),E(yn),l&&t(Hm),l&&t(fs),E(Hl),l&&t(Ym),l&&t(it),E(Yl),E(Tn),E(oi),E(kn),E(Mn),l&&t(Km),l&&t(gs),E(si),l&&t(eg),l&&t(dt),E(ni),E(En),E(di),E(Fn),E(Bn),E(jn),l&&t(tg),l&&t(bs),E(ci),l&&t(og),l&&t(ct),E(pi),E(xn),E(mi),E(Cn),E(Jn),E(zn),l&&t(sg),l&&t(ys),E(gi),l&&t(ng),l&&t(pt),E(_i),E(In),E(wi),E(Wn),E(An),l&&t(rg),l&&t(Ts),E(Ti),l&&t(ag),l&&t(ht),E(ki),E(Rn),E(Fi),E(Zn),E(Gn),E(qn),l&&t(lg),l&&t(Ms),E(Bi),l&&t(ig),l&&t(ut),E(ji),E(Pn),E(Ji),E(Vn),E(Sn),E(Ln),l&&t(dg),l&&t(Fs),E(zi),l&&t(cg),l&&t(ot),E(Ui),E(qi),E(On),E(Hn),l&&t(pg),l&&t(js),E(Xi),l&&t(hg),l&&t(st),E(Pi),E(ed),E(Kn),E(er),l&&t(ug),l&&t(xs),E(td),l&&t(fg),l&&t(nt),E(od),E(cd),E(or),E(sr),l&&t(mg),l&&t(Js),E(pd),l&&t(gg),l&&t(rt),E(hd),E(yd),E(rr),E(ar),l&&t(_g),l&&t(Us),E(wd),l&&t(bg),l&&t(at),E(Td),E(Dd),E(ir),E(dr),l&&t(vg),l&&t(Ws),E(xd),l&&t(yg),l&&t(lt),E(Cd),E(Rd),E(pr),E(hr)}}}const mJ={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 gJ(B){return _C(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class MJ extends uC{constructor(d){super();fC(this,d,gJ,fJ,mC,{})}}export{MJ as default,mJ as metadata};
