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