import{S as rJ,i as lJ,s as iJ,e as n,k as c,w as k,t as a,M as dJ,c as s,d as t,m as p,a as l,x as w,h as r,b as u,N as aJ,G as e,g,y as v,q as M,o as $,B as F,v as cJ,L as We}from"../../chunks/vendor-hf-doc-builder.js";import{T as Re}from"../../chunks/Tip-hf-doc-builder.js";import{D as q}from"../../chunks/Docstring-hf-doc-builder.js";import{C as qe}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ve}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as Ne}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";function pJ(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEFsYmVydENvbmZpZyUyQyUyMEFsYmVydE1vZGVsJTBBJTBBJTIzJTIwSW5pdGlhbGl6aW5nJTIwYW4lMjBBTEJFUlQteHhsYXJnZSUyMHN0eWxlJTIwY29uZmlndXJhdGlvbiUwQWFsYmVydF94eGxhcmdlX2NvbmZpZ3VyYXRpb24lMjAlM0QlMjBBbGJlcnRDb25maWcoKSUwQSUwQSUyMyUyMEluaXRpYWxpemluZyUyMGFuJTIwQUxCRVJULWJhc2UlMjBzdHlsZSUyMGNvbmZpZ3VyYXRpb24lMEFhbGJlcnRfYmFzZV9jb25maWd1cmF0aW9uJTIwJTNEJTIwQWxiZXJ0Q29uZmlnKCUwQSUyMCUyMCUyMCUyMGhpZGRlbl9zaXplJTNENzY4JTJDJTBBJTIwJTIwJTIwJTIwbnVtX2F0dGVudGlvbl9oZWFkcyUzRDEyJTJDJTBBJTIwJTIwJTIwJTIwaW50ZXJtZWRpYXRlX3NpemUlM0QzMDcyJTJDJTBBKSUwQSUwQSUyMyUyMEluaXRpYWxpemluZyUyMGElMjBtb2RlbCUyMCh3aXRoJTIwcmFuZG9tJTIwd2VpZ2h0cyklMjBmcm9tJTIwdGhlJTIwQUxCRVJULWJhc2UlMjBzdHlsZSUyMGNvbmZpZ3VyYXRpb24lMEFtb2RlbCUyMCUzRCUyMEFsYmVydE1vZGVsKGFsYmVydF94eGxhcmdlX2NvbmZpZ3VyYXRpb24pJTBBJTBBJTIzJTIwQWNjZXNzaW5nJTIwdGhlJTIwbW9kZWwlMjBjb25maWd1cmF0aW9uJTBBY29uZmlndXJhdGlvbiUyMCUzRCUyMG1vZGVsLmNvbmZpZw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertConfig, AlbertModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing an ALBERT-xxlarge style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>albert_xxlarge_configuration = AlbertConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing an ALBERT-base style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>albert_base_configuration = AlbertConfig(
<span class="hljs-meta">... </span>    hidden_size=<span class="hljs-number">768</span>,
<span class="hljs-meta">... </span>    num_attention_heads=<span class="hljs-number">12</span>,
<span class="hljs-meta">... </span>    intermediate_size=<span class="hljs-number">3072</span>,
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the ALBERT-base style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertModel(albert_xxlarge_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=a("Examples:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Examples:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function hJ(E){let d,y,m,f,b;return f=new qe({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=a("sequence pair mask has the following format:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"sequence pair mask has the following format:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function mJ(E){let d,y,m,f,b;return f=new qe({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=a("sequence pair mask has the following format:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"sequence pair mask has the following format:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function uJ(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function fJ(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBBbGJlcnRNb2RlbCUwQWltcG9ydCUyMHRvcmNoJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBbW9kZWwlMjAlM0QlMjBBbGJlcnRNb2RlbC5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyklMEElMEFsYXN0X2hpZGRlbl9zdGF0ZXMlMjAlM0QlMjBvdXRwdXRzLmxhc3RfaGlkZGVuX3N0YXRl",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, AlbertModel
<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;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertModel.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function gJ(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function _J(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBBbGJlcnRGb3JQcmVUcmFpbmluZyUwQWltcG9ydCUyMHRvcmNoJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBbW9kZWwlMjAlM0QlMjBBbGJlcnRGb3JQcmVUcmFpbmluZy5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBaW5wdXRfaWRzJTIwJTNEJTIwdG9yY2gudGVuc29yKHRva2VuaXplci5lbmNvZGUoJTIySGVsbG8lMkMlMjBteSUyMGRvZyUyMGlzJTIwY3V0ZSUyMiUyQyUyMGFkZF9zcGVjaWFsX3Rva2VucyUzRFRydWUpKS51bnNxdWVlemUoMCklMEElMjMlMjBCYXRjaCUyMHNpemUlMjAxJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKGlucHV0X2lkcyklMEElMEFwcmVkaWN0aW9uX2xvZ2l0cyUyMCUzRCUyMG91dHB1dHMucHJlZGljdGlvbl9sb2dpdHMlMEFzb3BfbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5zb3BfbG9naXRz",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, AlbertForPreTraining
<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;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForPreTraining.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>input_ids = torch.tensor(tokenizer.encode(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, add_special_tokens=<span class="hljs-literal">True</span>)).unsqueeze(<span class="hljs-number">0</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Batch size 1</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(input_ids)

<span class="hljs-meta">&gt;&gt;&gt; </span>prediction_logits = outputs.prediction_logits
<span class="hljs-meta">&gt;&gt;&gt; </span>sop_logits = outputs.sop_logits`}}),{c(){d=n("p"),y=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function bJ(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function yJ(E){let d,y,m,f,b;return f=new qe({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMEFsYmVydEZvck1hc2tlZExNJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBbW9kZWwlMjAlM0QlMjBBbGJlcnRGb3JNYXNrZWRMTS5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBJTIzJTIwYWRkJTIwbWFza190b2tlbiUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplciglMjJUaGUlMjBjYXBpdGFsJTIwb2YlMjAlNUJNQVNLJTVEJTIwaXMlMjBQYXJpcy4lMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBsb2dpdHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cykubG9naXRzJTBBJTBBJTIzJTIwcmV0cmlldmUlMjBpbmRleCUyMG9mJTIwJTVCTUFTSyU1RCUwQW1hc2tfdG9rZW5faW5kZXglMjAlM0QlMjAoaW5wdXRzLmlucHV0X2lkcyUyMCUzRCUzRCUyMHRva2VuaXplci5tYXNrX3Rva2VuX2lkKSU1QjAlNUQubm9uemVybyhhc190dXBsZSUzRFRydWUpJTVCMCU1RCUwQXByZWRpY3RlZF90b2tlbl9pZCUyMCUzRCUyMGxvZ2l0cyU1QjAlMkMlMjBtYXNrX3Rva2VuX2luZGV4JTVELmFyZ21heChheGlzJTNELTEpJTBBdG9rZW5pemVyLmRlY29kZShwcmVkaWN0ZWRfdG9rZW5faWQp",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, AlbertForMaskedLM

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForMaskedLM.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># add mask_token</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of [MASK] is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># retrieve index of [MASK]</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>mask_token_index = (inputs.input_ids == tokenizer.mask_token_id)[<span class="hljs-number">0</span>].nonzero(as_tuple=<span class="hljs-literal">True</span>)[<span class="hljs-number">0</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_id = logits[<span class="hljs-number">0</span>, mask_token_index].argmax(axis=-<span class="hljs-number">1</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predicted_token_id)
<span class="hljs-string">&#x27;france&#x27;</span>`}}),{c(){d=n("p"),y=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function TJ(E){let d,y;return d=new qe({props:{code:"bGFiZWxzJTIwJTNEJTIwdG9rZW5pemVyKCUyMlRoZSUyMGNhcGl0YWwlMjBvZiUyMEZyYW5jZSUyMGlzJTIwUGFyaXMuJTIyJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJwdCUyMiklNUIlMjJpbnB1dF9pZHMlMjIlNUQlMEFsYWJlbHMlMjAlM0QlMjB0b3JjaC53aGVyZShpbnB1dHMuaW5wdXRfaWRzJTIwJTNEJTNEJTIwdG9rZW5pemVyLm1hc2tfdG9rZW5faWQlMkMlMjBsYWJlbHMlMkMlMjAtMTAwKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscyklMEFyb3VuZChvdXRwdXRzLmxvc3MuaXRlbSgpJTJDJTIwMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(outputs.loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">0.81</span>`}}),{c(){k(d.$$.fragment)},l(m){w(d.$$.fragment,m)},m(m,f){v(d,m,f),y=!0},p:We,i(m){y||(M(d.$$.fragment,m),y=!0)},o(m){$(d.$$.fragment,m),y=!1},d(m){F(d,m)}}}function kJ(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function wJ(E){let d,y,m,f,b;return f=new qe({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMEFsYmVydEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24lMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJ0ZXh0YXR0YWNrJTJGYWxiZXJ0LWJhc2UtdjItaW1kYiUyMiklMEFtb2RlbCUyMCUzRCUyMEFsYmVydEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMnRleHRhdHRhY2slMkZhbGJlcnQtYmFzZS12Mi1pbWRiJTIyKSUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplciglMjJIZWxsbyUyQyUyMG15JTIwZG9nJTIwaXMlMjBjdXRlJTIyJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJwdCUyMiklMEElMEF3aXRoJTIwdG9yY2gubm9fZ3JhZCgpJTNBJTBBJTIwJTIwJTIwJTIwbG9naXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpLmxvZ2l0cyUwQSUwQXByZWRpY3RlZF9jbGFzc19pZCUyMCUzRCUyMGxvZ2l0cy5hcmdtYXgoKS5pdGVtKCklMEFtb2RlbC5jb25maWcuaWQybGFiZWwlNUJwcmVkaWN0ZWRfY2xhc3NfaWQlNUQlMEElMEElMjMlMjBUbyUyMHRyYWluJTIwYSUyMG1vZGVsJTIwb24lMjAlNjBudW1fbGFiZWxzJTYwJTIwY2xhc3NlcyUyQyUyMHlvdSUyMGNhbiUyMHBhc3MlMjAlNjBudW1fbGFiZWxzJTNEbnVtX2xhYmVscyU2MCUyMHRvJTIwJTYwLmZyb21fcHJldHJhaW5lZCguLi4pJTYwJTBBbnVtX2xhYmVscyUyMCUzRCUyMGxlbihtb2RlbC5jb25maWcuaWQybGFiZWwpJTBBbW9kZWwlMjAlM0QlMjBBbGJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMjJ0ZXh0YXR0YWNrJTJGYWxiZXJ0LWJhc2UtdjItaW1kYiUyMiUyQyUyMG51bV9sYWJlbHMlM0RudW1fbGFiZWxzKSUwQSUwQWxhYmVscyUyMCUzRCUyMHRvcmNoLnRlbnNvciglNUIxJTVEKSUwQWxvc3MlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscykubG9zcyUwQXJvdW5kKGxvc3MuaXRlbSgpJTJDJTIwMik=",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, AlbertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;textattack/albert-base-v2-imdb&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;textattack/albert-base-v2-imdb&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = logits.argmax().item()
<span class="hljs-meta">&gt;&gt;&gt; </span>model.config.id2label[predicted_class_id]
<span class="hljs-string">&#x27;LABEL_1&#x27;</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 = AlbertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;textattack/albert-base-v2-imdb&quot;</span>, num_labels=num_labels)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.tensor([<span class="hljs-number">1</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">0.12</span>`}}),{c(){d=n("p"),y=a("Example of single-label classification:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example of single-label classification:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function vJ(E){let d,y,m,f,b;return f=new qe({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMEFsYmVydEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24lMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJ0ZXh0YXR0YWNrJTJGYWxiZXJ0LWJhc2UtdjItaW1kYiUyMiklMEFtb2RlbCUyMCUzRCUyMEFsYmVydEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMnRleHRhdHRhY2slMkZhbGJlcnQtYmFzZS12Mi1pbWRiJTIyJTJDJTIwcHJvYmxlbV90eXBlJTNEJTIybXVsdGlfbGFiZWxfY2xhc3NpZmljYXRpb24lMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBsb2dpdHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cykubG9naXRzJTBBJTBBcHJlZGljdGVkX2NsYXNzX2lkcyUyMCUzRCUyMHRvcmNoLmFyYW5nZSgwJTJDJTIwbG9naXRzLnNoYXBlJTVCLTElNUQpJTVCdG9yY2guc2lnbW9pZChsb2dpdHMpLnNxdWVlemUoZGltJTNEMCklMjAlM0UlMjAwLjUlNUQlMEElMEElMjMlMjBUbyUyMHRyYWluJTIwYSUyMG1vZGVsJTIwb24lMjAlNjBudW1fbGFiZWxzJTYwJTIwY2xhc3NlcyUyQyUyMHlvdSUyMGNhbiUyMHBhc3MlMjAlNjBudW1fbGFiZWxzJTNEbnVtX2xhYmVscyU2MCUyMHRvJTIwJTYwLmZyb21fcHJldHJhaW5lZCguLi4pJTYwJTBBbnVtX2xhYmVscyUyMCUzRCUyMGxlbihtb2RlbC5jb25maWcuaWQybGFiZWwpJTBBbW9kZWwlMjAlM0QlMjBBbGJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMEElMjAlMjAlMjAlMjAlMjJ0ZXh0YXR0YWNrJTJGYWxiZXJ0LWJhc2UtdjItaW1kYiUyMiUyQyUyMG51bV9sYWJlbHMlM0RudW1fbGFiZWxzJTJDJTIwcHJvYmxlbV90eXBlJTNEJTIybXVsdGlfbGFiZWxfY2xhc3NpZmljYXRpb24lMjIlMEEpJTBBJTBBbGFiZWxzJTIwJTNEJTIwdG9yY2guc3VtKCUwQSUyMCUyMCUyMCUyMHRvcmNoLm5uLmZ1bmN0aW9uYWwub25lX2hvdChwcmVkaWN0ZWRfY2xhc3NfaWRzJTVCTm9uZSUyQyUyMCUzQSU1RC5jbG9uZSgpJTJDJTIwbnVtX2NsYXNzZXMlM0RudW1fbGFiZWxzKSUyQyUyMGRpbSUzRDElMEEpLnRvKHRvcmNoLmZsb2F0KSUwQWxvc3MlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscykubG9zcw==",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, AlbertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;textattack/albert-base-v2-imdb&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;textattack/albert-base-v2-imdb&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 = AlbertForSequenceClassification.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;textattack/albert-base-v2-imdb&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=a("Example of multi-label classification:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example of multi-label classification:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function MJ(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function $J(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBBbGJlcnRGb3JNdWx0aXBsZUNob2ljZSUwQWltcG9ydCUyMHRvcmNoJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBbW9kZWwlMjAlM0QlMjBBbGJlcnRGb3JNdWx0aXBsZUNob2ljZS5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBcHJvbXB0JTIwJTNEJTIwJTIySW4lMjBJdGFseSUyQyUyMHBpenphJTIwc2VydmVkJTIwaW4lMjBmb3JtYWwlMjBzZXR0aW5ncyUyQyUyMHN1Y2glMjBhcyUyMGF0JTIwYSUyMHJlc3RhdXJhbnQlMkMlMjBpcyUyMHByZXNlbnRlZCUyMHVuc2xpY2VkLiUyMiUwQWNob2ljZTAlMjAlM0QlMjAlMjJJdCUyMGlzJTIwZWF0ZW4lMjB3aXRoJTIwYSUyMGZvcmslMjBhbmQlMjBhJTIwa25pZmUuJTIyJTBBY2hvaWNlMSUyMCUzRCUyMCUyMkl0JTIwaXMlMjBlYXRlbiUyMHdoaWxlJTIwaGVsZCUyMGluJTIwdGhlJTIwaGFuZC4lMjIlMEFsYWJlbHMlMjAlM0QlMjB0b3JjaC50ZW5zb3IoMCkudW5zcXVlZXplKDApJTIwJTIwJTIzJTIwY2hvaWNlMCUyMGlzJTIwY29ycmVjdCUyMChhY2NvcmRpbmclMjB0byUyMFdpa2lwZWRpYSUyMCUzQikpJTJDJTIwYmF0Y2glMjBzaXplJTIwMSUwQSUwQWVuY29kaW5nJTIwJTNEJTIwdG9rZW5pemVyKCU1QnByb21wdCUyQyUyMHByb21wdCU1RCUyQyUyMCU1QmNob2ljZTAlMkMlMjBjaG9pY2UxJTVEJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJwdCUyMiUyQyUyMHBhZGRpbmclM0RUcnVlKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKiU3QmslM0ElMjB2LnVuc3F1ZWV6ZSgwKSUyMGZvciUyMGslMkMlMjB2JTIwaW4lMjBlbmNvZGluZy5pdGVtcygpJTdEJTJDJTIwbGFiZWxzJTNEbGFiZWxzKSUyMCUyMCUyMyUyMGJhdGNoJTIwc2l6ZSUyMGlzJTIwMSUwQSUwQSUyMyUyMHRoZSUyMGxpbmVhciUyMGNsYXNzaWZpZXIlMjBzdGlsbCUyMG5lZWRzJTIwdG8lMjBiZSUyMHRyYWluZWQlMEFsb3NzJTIwJTNEJTIwb3V0cHV0cy5sb3NzJTBBbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5sb2dpdHM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, AlbertForMultipleChoice
<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;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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, prompt], [choice0, 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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function FJ(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function AJ(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBBbGJlcnRGb3JUb2tlbkNsYXNzaWZpY2F0aW9uJTBBaW1wb3J0JTIwdG9yY2glMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJhbGJlcnQtYmFzZS12MiUyMiklMEFtb2RlbCUyMCUzRCUyMEFsYmVydEZvclRva2VuQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMmFsYmVydC1iYXNlLXYyJTIyKSUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplciglMEElMjAlMjAlMjAlMjAlMjJIdWdnaW5nRmFjZSUyMGlzJTIwYSUyMGNvbXBhbnklMjBiYXNlZCUyMGluJTIwUGFyaXMlMjBhbmQlMjBOZXclMjBZb3JrJTIyJTJDJTIwYWRkX3NwZWNpYWxfdG9rZW5zJTNERmFsc2UlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyJTBBKSUwQSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBsb2dpdHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cykubG9naXRzJTBBJTBBcHJlZGljdGVkX3Rva2VuX2NsYXNzX2lkcyUyMCUzRCUyMGxvZ2l0cy5hcmdtYXgoLTEpJTBBJTBBJTIzJTIwTm90ZSUyMHRoYXQlMjB0b2tlbnMlMjBhcmUlMjBjbGFzc2lmaWVkJTIwcmF0aGVyJTIwdGhlbiUyMGlucHV0JTIwd29yZHMlMjB3aGljaCUyMG1lYW5zJTIwdGhhdCUwQSUyMyUyMHRoZXJlJTIwbWlnaHQlMjBiZSUyMG1vcmUlMjBwcmVkaWN0ZWQlMjB0b2tlbiUyMGNsYXNzZXMlMjB0aGFuJTIwd29yZHMuJTBBJTIzJTIwTXVsdGlwbGUlMjB0b2tlbiUyMGNsYXNzZXMlMjBtaWdodCUyMGFjY291bnQlMjBmb3IlMjB0aGUlMjBzYW1lJTIwd29yZCUwQXByZWRpY3RlZF90b2tlbnNfY2xhc3NlcyUyMCUzRCUyMCU1Qm1vZGVsLmNvbmZpZy5pZDJsYWJlbCU1QnQuaXRlbSgpJTVEJTIwZm9yJTIwdCUyMGluJTIwcHJlZGljdGVkX3Rva2VuX2NsYXNzX2lkcyU1QjAlNUQlNUQlMEElMEFsYWJlbHMlMjAlM0QlMjBwcmVkaWN0ZWRfdG9rZW5fY2xhc3NfaWRzJTBBbG9zcyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzJTJDJTIwbGFiZWxzJTNEbGFiZWxzKS5sb3Nz",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, AlbertForTokenClassification
<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;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForTokenClassification.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function EJ(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function jJ(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBBbGJlcnRGb3JRdWVzdGlvbkFuc3dlcmluZyUwQWltcG9ydCUyMHRvcmNoJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIydHdta245JTJGYWxiZXJ0LWJhc2UtdjItc3F1YWQyJTIyKSUwQW1vZGVsJTIwJTNEJTIwQWxiZXJ0Rm9yUXVlc3Rpb25BbnN3ZXJpbmcuZnJvbV9wcmV0cmFpbmVkKCUyMnR3bWtuOSUyRmFsYmVydC1iYXNlLXYyLXNxdWFkMiUyMiklMEElMEFxdWVzdGlvbiUyQyUyMHRleHQlMjAlM0QlMjAlMjJXaG8lMjB3YXMlMjBKaW0lMjBIZW5zb24lM0YlMjIlMkMlMjAlMjJKaW0lMjBIZW5zb24lMjB3YXMlMjBhJTIwbmljZSUyMHB1cHBldCUyMiUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplcihxdWVzdGlvbiUyQyUyMHRleHQlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBJTBBYW5zd2VyX3N0YXJ0X2luZGV4JTIwJTNEJTIwb3V0cHV0cy5zdGFydF9sb2dpdHMuYXJnbWF4KCklMEFhbnN3ZXJfZW5kX2luZGV4JTIwJTNEJTIwb3V0cHV0cy5lbmRfbG9naXRzLmFyZ21heCgpJTBBJTBBcHJlZGljdF9hbnN3ZXJfdG9rZW5zJTIwJTNEJTIwaW5wdXRzLmlucHV0X2lkcyU1QjAlMkMlMjBhbnN3ZXJfc3RhcnRfaW5kZXglMjAlM0ElMjBhbnN3ZXJfZW5kX2luZGV4JTIwJTJCJTIwMSU1RCUwQXRva2VuaXplci5kZWNvZGUocHJlZGljdF9hbnN3ZXJfdG9rZW5zJTJDJTIwc2tpcF9zcGVjaWFsX3Rva2VucyUzRFRydWUpJTBBJTBBJTIzJTIwdGFyZ2V0JTIwaXMlMjAlMjJuaWNlJTIwcHVwcGV0JTIyJTBBdGFyZ2V0X3N0YXJ0X2luZGV4JTIwJTNEJTIwdG9yY2gudGVuc29yKCU1QjEyJTVEKSUwQXRhcmdldF9lbmRfaW5kZXglMjAlM0QlMjB0b3JjaC50ZW5zb3IoJTVCMTMlNUQpJTBBJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzJTJDJTIwc3RhcnRfcG9zaXRpb25zJTNEdGFyZ2V0X3N0YXJ0X2luZGV4JTJDJTIwZW5kX3Bvc2l0aW9ucyUzRHRhcmdldF9lbmRfaW5kZXgpJTBBbG9zcyUyMCUzRCUyMG91dHB1dHMubG9zcyUwQXJvdW5kKGxvc3MuaXRlbSgpJTJDJTIwMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, AlbertForQuestionAnswering
<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;twmkn9/albert-base-v2-squad2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;twmkn9/albert-base-v2-squad2&quot;</span>)

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

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

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

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFAlbertForPreTraining.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>input_ids = tf.constant(tokenizer.encode(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, add_special_tokens=<span class="hljs-literal">True</span>))[<span class="hljs-literal">None</span>, :]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Batch size 1</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(input_ids)

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFAlbertForMaskedLM.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = <span class="hljs-built_in">int</span>(tf.math.argmax(logits, axis=-<span class="hljs-number">1</span>)[<span class="hljs-number">0</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>model.config.id2label[predicted_class_id]
<span class="hljs-string">&#x27;LABEL_1&#x27;</span>`}}),{c(){d=n("p"),y=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function RJ(E){let d,y;return d=new qe({props:{code:"JTIzJTIwVG8lMjB0cmFpbiUyMGElMjBtb2RlbCUyMG9uJTIwJTYwbnVtX2xhYmVscyU2MCUyMGNsYXNzZXMlMkMlMjB5b3UlMjBjYW4lMjBwYXNzJTIwJTYwbnVtX2xhYmVscyUzRG51bV9sYWJlbHMlNjAlMjB0byUyMCU2MC5mcm9tX3ByZXRyYWluZWQoLi4uKSU2MCUwQW51bV9sYWJlbHMlMjAlM0QlMjBsZW4obW9kZWwuY29uZmlnLmlkMmxhYmVsKSUwQW1vZGVsJTIwJTNEJTIwVEZBbGJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMjJ2dW1pY2hpZW4lMkZhbGJlcnQtYmFzZS12Mi1pbWRiJTIyJTJDJTIwbnVtX2xhYmVscyUzRG51bV9sYWJlbHMpJTBBJTBBbGFiZWxzJTIwJTNEJTIwdGYuY29uc3RhbnQoMSklMEFsb3NzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMlMkMlMjBsYWJlbHMlM0RsYWJlbHMpLmxvc3MlMEFyb3VuZChmbG9hdChsb3NzKSUyQyUyMDIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFAlbertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;vumichien/albert-base-v2-imdb&quot;</span>, num_labels=num_labels)

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

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predict_answer_tokens = inputs.input_ids[<span class="hljs-number">0</span>, answer_start_index : answer_end_index + <span class="hljs-number">1</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predict_answer_tokens)
<span class="hljs-string">&#x27;a nice puppet&#x27;</span>`}}),{c(){d=n("p"),y=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function ez(E){let d,y;return d=new qe({props:{code:"JTIzJTIwdGFyZ2V0JTIwaXMlMjAlMjJuaWNlJTIwcHVwcGV0JTIyJTBBdGFyZ2V0X3N0YXJ0X2luZGV4JTIwJTNEJTIwdGYuY29uc3RhbnQoJTVCMTIlNUQpJTBBdGFyZ2V0X2VuZF9pbmRleCUyMCUzRCUyMHRmLmNvbnN0YW50KCU1QjEzJTVEKSUwQSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMHN0YXJ0X3Bvc2l0aW9ucyUzRHRhcmdldF9zdGFydF9pbmRleCUyQyUyMGVuZF9wb3NpdGlvbnMlM0R0YXJnZXRfZW5kX2luZGV4KSUwQWxvc3MlMjAlM0QlMjB0Zi5tYXRoLnJlZHVjZV9tZWFuKG91dHB1dHMubG9zcyklMEFyb3VuZChmbG9hdChsb3NzKSUyQyUyMDIp",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">12</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>target_end_index = tf.constant([<span class="hljs-number">13</span>])

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(outputs.loss)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(<span class="hljs-built_in">float</span>(loss), <span class="hljs-number">2</span>)
<span class="hljs-number">7.36</span>`}}),{c(){k(d.$$.fragment)},l(m){w(d.$$.fragment,m)},m(m,f){v(d,m,f),y=!0},p:We,i(m){y||(M(d.$$.fragment,m),y=!0)},o(m){$(d.$$.fragment,m),y=!1},d(m){F(d,m)}}}function tz(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function oz(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4QWxiZXJ0TW9kZWwlMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJhbGJlcnQtYmFzZS12MiUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhBbGJlcnRNb2RlbC5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMmpheCUyMiklMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBJTBBbGFzdF9oaWRkZW5fc3RhdGVzJTIwJTNEJTIwb3V0cHV0cy5sYXN0X2hpZGRlbl9zdGF0ZQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxAlbertModel

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxAlbertModel.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function nz(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function sz(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4QWxiZXJ0Rm9yUHJlVHJhaW5pbmclMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJhbGJlcnQtYmFzZS12MiUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhBbGJlcnRGb3JQcmVUcmFpbmluZy5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMm5wJTIyKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyklMEElMEFwcmVkaWN0aW9uX2xvZ2l0cyUyMCUzRCUyMG91dHB1dHMucHJlZGljdGlvbl9sb2dpdHMlMEFzZXFfcmVsYXRpb25zaGlwX2xvZ2l0cyUyMCUzRCUyMG91dHB1dHMuc29wX2xvZ2l0cw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxAlbertForPreTraining

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxAlbertForPreTraining.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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;np&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>prediction_logits = outputs.prediction_logits
<span class="hljs-meta">&gt;&gt;&gt; </span>seq_relationship_logits = outputs.sop_logits`}}),{c(){d=n("p"),y=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function az(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function rz(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4QWxiZXJ0Rm9yTWFza2VkTE0lMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJhbGJlcnQtYmFzZS12MiUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhBbGJlcnRGb3JNYXNrZWRMTS5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMlRoZSUyMGNhcGl0YWwlMjBvZiUyMEZyYW5jZSUyMGlzJTIwJTVCTUFTSyU1RC4lMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMmpheCUyMiklMEElMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5sb2dpdHM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxAlbertForMaskedLM

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxAlbertForMaskedLM.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function lz(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function iz(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4QWxiZXJ0Rm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbiUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMmFsYmVydC1iYXNlLXYyJTIyKSUwQW1vZGVsJTIwJTNEJTIwRmxheEFsYmVydEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMmFsYmVydC1iYXNlLXYyJTIyKSUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplciglMjJIZWxsbyUyQyUyMG15JTIwZG9nJTIwaXMlMjBjdXRlJTIyJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJqYXglMjIpJTBBJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKSUwQWxvZ2l0cyUyMCUzRCUyMG91dHB1dHMubG9naXRz",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxAlbertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxAlbertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function dz(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function cz(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4QWxiZXJ0Rm9yTXVsdGlwbGVDaG9pY2UlMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJhbGJlcnQtYmFzZS12MiUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhBbGJlcnRGb3JNdWx0aXBsZUNob2ljZS5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBcHJvbXB0JTIwJTNEJTIwJTIySW4lMjBJdGFseSUyQyUyMHBpenphJTIwc2VydmVkJTIwaW4lMjBmb3JtYWwlMjBzZXR0aW5ncyUyQyUyMHN1Y2glMjBhcyUyMGF0JTIwYSUyMHJlc3RhdXJhbnQlMkMlMjBpcyUyMHByZXNlbnRlZCUyMHVuc2xpY2VkLiUyMiUwQWNob2ljZTAlMjAlM0QlMjAlMjJJdCUyMGlzJTIwZWF0ZW4lMjB3aXRoJTIwYSUyMGZvcmslMjBhbmQlMjBhJTIwa25pZmUuJTIyJTBBY2hvaWNlMSUyMCUzRCUyMCUyMkl0JTIwaXMlMjBlYXRlbiUyMHdoaWxlJTIwaGVsZCUyMGluJTIwdGhlJTIwaGFuZC4lMjIlMEElMEFlbmNvZGluZyUyMCUzRCUyMHRva2VuaXplciglNUJwcm9tcHQlMkMlMjBwcm9tcHQlNUQlMkMlMjAlNUJjaG9pY2UwJTJDJTIwY2hvaWNlMSU1RCUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIyamF4JTIyJTJDJTIwcGFkZGluZyUzRFRydWUpJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqJTdCayUzQSUyMHYlNUJOb25lJTJDJTIwJTNBJTVEJTIwZm9yJTIwayUyQyUyMHYlMjBpbiUyMGVuY29kaW5nLml0ZW1zKCklN0QpJTBBJTBBbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5sb2dpdHM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxAlbertForMultipleChoice

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxAlbertForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function pz(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function hz(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4QWxiZXJ0Rm9yVG9rZW5DbGFzc2lmaWNhdGlvbiUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMmFsYmVydC1iYXNlLXYyJTIyKSUwQW1vZGVsJTIwJTNEJTIwRmxheEFsYmVydEZvclRva2VuQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMmFsYmVydC1iYXNlLXYyJTIyKSUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplciglMjJIZWxsbyUyQyUyMG15JTIwZG9nJTIwaXMlMjBjdXRlJTIyJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJqYXglMjIpJTBBJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKSUwQWxvZ2l0cyUyMCUzRCUyMG91dHB1dHMubG9naXRz",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxAlbertForTokenClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxAlbertForTokenClassification.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function mz(E){let d,y,m,f,b;return{c(){d=n("p"),y=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=n("code"),f=a("Module"),b=a(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s(h,"CODE",{});var j=l(m);f=r(j,"Module"),j.forEach(t),b=r(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(t)},m(i,h){g(i,d,h),e(d,y),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function uz(E){let d,y,m,f,b;return f=new qe({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4QWxiZXJ0Rm9yUXVlc3Rpb25BbnN3ZXJpbmclMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJhbGJlcnQtYmFzZS12MiUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhBbGJlcnRGb3JRdWVzdGlvbkFuc3dlcmluZy5mcm9tX3ByZXRyYWluZWQoJTIyYWxiZXJ0LWJhc2UtdjIlMjIpJTBBJTBBcXVlc3Rpb24lMkMlMjB0ZXh0JTIwJTNEJTIwJTIyV2hvJTIwd2FzJTIwSmltJTIwSGVuc29uJTNGJTIyJTJDJTIwJTIySmltJTIwSGVuc29uJTIwd2FzJTIwYSUyMG5pY2UlMjBwdXBwZXQlMjIlMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIocXVlc3Rpb24lMkMlMjB0ZXh0JTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJqYXglMjIpJTBBJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKSUwQXN0YXJ0X3Njb3JlcyUyMCUzRCUyMG91dHB1dHMuc3RhcnRfbG9naXRzJTBBZW5kX3Njb3JlcyUyMCUzRCUyMG91dHB1dHMuZW5kX2xvZ2l0cw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxAlbertForQuestionAnswering

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxAlbertForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&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=a("Example:"),m=c(),k(f.$$.fragment)},l(i){d=s(i,"P",{});var h=l(d);y=r(h,"Example:"),h.forEach(t),m=p(i),w(f.$$.fragment,i)},m(i,h){g(i,d,h),e(d,y),g(i,m,h),v(f,i,h),b=!0},p:We,i(i){b||(M(f.$$.fragment,i),b=!0)},o(i){$(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),F(f,i)}}}function fz(E){let d,y,m,f,b,i,h,j,Me,ye,B,de,K,A,$e,V,ce,Ue,O,se,ae,X,le,Fe,S,Ae,Te,G,Ee,ie,ee,z,U,re,L,je,xe,D,Je,ke,C,ze,Q,pe,me,Y,we,he,P,ve,W,ue,te,I,fe,N,Ce,ge,T,x,Xe,oe,Le,_e,J,Ze,De,Oe,Be,Qe,Z,R,He,Ye,H,Ie,Pe,be,Ge,ne,Se,n_,Cu,kt,Lc,bd,s_,a_,Dc,yd,r_,l_,Oc,Td,i_,d_,Qc,kd,c_,p_,Hc,wd,h_,Uu,qo,Gn,Yc,Va,m_,Kc,u_,Iu,Nt,Xa,f_,co,g_,vd,__,b_,Md,y_,T_,Sa,k_,w_,v_,Po,M_,$d,$_,F_,Fd,A_,E_,j_,Rn,Nu,Zo,Vn,ep,La,x_,tp,J_,Wu,Ke,Da,z_,Oa,C_,Qa,U_,I_,N_,Ha,W_,Ad,q_,P_,Z_,vo,Ya,B_,op,G_,R_,Ka,Ed,V_,np,X_,S_,jd,L_,sp,D_,O_,Xn,er,Q_,tr,H_,ap,Y_,K_,eb,Pt,or,tb,rp,ob,nb,Sn,sb,Bo,ab,lp,rb,lb,ip,ib,db,cb,xd,nr,qu,Go,Ln,dp,sr,pb,cp,hb,Pu,Wt,ar,mb,po,ub,pp,fb,gb,rr,_b,bb,Jd,yb,Tb,kb,Mo,lr,wb,hp,vb,Mb,ir,zd,$b,mp,Fb,Ab,Cd,Eb,up,jb,xb,Zt,dr,Jb,fp,zb,Cb,Dn,Ub,gp,Ib,Zu,Ro,On,_p,cr,Nb,bp,Wb,Bu,Vo,pr,qb,hr,Pb,Ud,Zb,Bb,Gu,Xo,mr,Gb,ur,Rb,Id,Vb,Xb,Ru,So,Qn,yp,fr,Sb,Tp,Lb,Vu,ut,gr,Db,kp,Ob,Qb,_r,Hb,Nd,Yb,Kb,ey,br,ty,yr,oy,ny,sy,Bt,Tr,ay,Lo,ry,Wd,ly,iy,wp,dy,cy,py,Hn,hy,Yn,Xu,Do,Kn,vp,kr,my,Mp,uy,Su,ft,wr,fy,Oo,gy,$p,_y,by,Fp,yy,Ty,ky,vr,wy,qd,vy,My,$y,Mr,Fy,$r,Ay,Ey,jy,Gt,Fr,xy,Qo,Jy,Pd,zy,Cy,Ap,Uy,Iy,Ny,es,Wy,ts,Lu,Ho,os,Ep,Ar,qy,jp,Py,Du,gt,Er,Zy,jr,By,xp,Gy,Ry,Vy,xr,Xy,Zd,Sy,Ly,Dy,Jr,Oy,zr,Qy,Hy,Yy,wt,Cr,Ky,Yo,eT,Bd,tT,oT,Jp,nT,sT,aT,ns,rT,ss,lT,as,Ou,Ko,rs,zp,Ur,iT,Cp,dT,Qu,_t,Ir,cT,Up,pT,hT,Nr,mT,Gd,uT,fT,gT,Wr,_T,qr,bT,yT,TT,vt,Pr,kT,en,wT,Rd,vT,MT,Ip,$T,FT,AT,ls,ET,is,jT,ds,Hu,tn,cs,Np,Zr,xT,Wp,JT,Yu,bt,Br,zT,qp,CT,UT,Gr,IT,Vd,NT,WT,qT,Rr,PT,Vr,ZT,BT,GT,Rt,Xr,RT,on,VT,Xd,XT,ST,Pp,LT,DT,OT,ps,QT,hs,Ku,nn,ms,Zp,Sr,HT,Bp,YT,ef,yt,Lr,KT,Gp,ek,tk,Dr,ok,Sd,nk,sk,ak,Or,rk,Qr,lk,ik,dk,Vt,Hr,ck,sn,pk,Ld,hk,mk,Rp,uk,fk,gk,us,_k,fs,tf,an,gs,Vp,Yr,bk,Xp,yk,of,Tt,Kr,Tk,rn,kk,Sp,wk,vk,Lp,Mk,$k,Fk,el,Ak,Dd,Ek,jk,xk,tl,Jk,ol,zk,Ck,Uk,Xt,nl,Ik,ln,Nk,Od,Wk,qk,Dp,Pk,Zk,Bk,_s,Gk,bs,nf,dn,ys,Op,sl,Rk,Qp,Vk,sf,lt,al,Xk,Hp,Sk,Lk,rl,Dk,Qd,Ok,Qk,Hk,ll,Yk,il,Kk,ew,tw,Ts,ow,St,dl,nw,cn,sw,Hd,aw,rw,Yp,lw,iw,dw,ks,cw,ws,af,pn,vs,Kp,cl,pw,eh,hw,rf,it,pl,mw,hn,uw,th,fw,gw,oh,_w,bw,yw,hl,Tw,Yd,kw,ww,vw,ml,Mw,ul,$w,Fw,Aw,Ms,Ew,Lt,fl,jw,mn,xw,Kd,Jw,zw,nh,Cw,Uw,Iw,$s,Nw,Fs,lf,un,As,sh,gl,Ww,ah,qw,df,dt,_l,Pw,bl,Zw,rh,Bw,Gw,Rw,yl,Vw,ec,Xw,Sw,Lw,Tl,Dw,kl,Ow,Qw,Hw,Es,Yw,Mt,wl,Kw,fn,ev,tc,tv,ov,lh,nv,sv,av,js,rv,xs,lv,Js,cf,gn,zs,ih,vl,iv,dh,dv,pf,ct,Ml,cv,ch,pv,hv,$l,mv,oc,uv,fv,gv,Fl,_v,Al,bv,yv,Tv,Cs,kv,$t,El,wv,_n,vv,nc,Mv,$v,ph,Fv,Av,Ev,Us,jv,Is,xv,Ns,hf,bn,Ws,hh,jl,Jv,mh,zv,mf,pt,xl,Cv,uh,Uv,Iv,Jl,Nv,sc,Wv,qv,Pv,zl,Zv,Cl,Bv,Gv,Rv,qs,Vv,Dt,Ul,Xv,yn,Sv,ac,Lv,Dv,fh,Ov,Qv,Hv,Ps,Yv,Zs,uf,Tn,Bs,gh,Il,Kv,_h,eM,ff,ht,Nl,tM,bh,oM,nM,Wl,sM,rc,aM,rM,lM,ql,iM,Pl,dM,cM,pM,Gs,hM,Ft,Zl,mM,kn,uM,lc,fM,gM,yh,_M,bM,yM,Rs,TM,Vs,kM,Xs,gf,wn,Ss,Th,Bl,wM,kh,vM,_f,mt,Gl,MM,vn,$M,wh,FM,AM,vh,EM,jM,xM,Rl,JM,ic,zM,CM,UM,Vl,IM,Xl,NM,WM,qM,Ls,PM,At,Sl,ZM,Mn,BM,dc,GM,RM,Mh,VM,XM,SM,Ds,LM,Os,DM,Qs,bf,$n,Hs,$h,Ll,OM,Fh,QM,yf,et,Dl,HM,Ah,YM,KM,Ol,e2,cc,t2,o2,n2,Ql,s2,Hl,a2,r2,l2,Eh,i2,d2,ho,jh,Yl,c2,p2,xh,Kl,h2,m2,Jh,ei,u2,f2,zh,ti,g2,_2,Ot,oi,b2,Fn,y2,Ch,T2,k2,Uh,w2,v2,M2,Ys,$2,Ks,Tf,An,ea,Ih,ni,F2,Nh,A2,kf,tt,si,E2,En,j2,Wh,x2,J2,qh,z2,C2,U2,ai,I2,pc,N2,W2,q2,ri,P2,li,Z2,B2,G2,Ph,R2,V2,mo,Zh,ii,X2,S2,Bh,di,L2,D2,Gh,ci,O2,Q2,Rh,pi,H2,Y2,Qt,hi,K2,jn,e1,Vh,t1,o1,Xh,n1,s1,a1,ta,r1,oa,wf,xn,na,Sh,mi,l1,Lh,i1,vf,ot,ui,d1,fi,c1,Dh,p1,h1,m1,gi,u1,hc,f1,g1,_1,_i,b1,bi,y1,T1,k1,Oh,w1,v1,uo,Qh,yi,M1,$1,Hh,Ti,F1,A1,Yh,ki,E1,j1,Kh,wi,x1,J1,Ht,vi,z1,Jn,C1,em,U1,I1,tm,N1,W1,q1,sa,P1,aa,Mf,zn,ra,om,Mi,Z1,nm,B1,$f,nt,$i,G1,sm,R1,V1,Fi,X1,mc,S1,L1,D1,Ai,O1,Ei,Q1,H1,Y1,am,K1,e$,fo,rm,ji,t$,o$,lm,xi,n$,s$,im,Ji,a$,r$,dm,zi,l$,i$,Yt,Ci,d$,Cn,c$,cm,p$,h$,pm,m$,u$,f$,la,g$,ia,Ff,Un,da,hm,Ui,_$,mm,b$,Af,st,Ii,y$,um,T$,k$,Ni,w$,uc,v$,M$,$$,Wi,F$,qi,A$,E$,j$,fm,x$,J$,go,gm,Pi,z$,C$,_m,Zi,U$,I$,bm,Bi,N$,W$,ym,Gi,q$,P$,Kt,Ri,Z$,In,B$,Tm,G$,R$,km,V$,X$,S$,ca,L$,pa,Ef,Nn,ha,wm,Vi,D$,vm,O$,jf,at,Xi,Q$,Mm,H$,Y$,Si,K$,fc,e0,t0,o0,Li,n0,Di,s0,a0,r0,$m,l0,i0,_o,Fm,Oi,d0,c0,Am,Qi,p0,h0,Em,Hi,m0,u0,jm,Yi,f0,g0,eo,Ki,_0,Wn,b0,xm,y0,T0,Jm,k0,w0,v0,ma,M0,ua,xf,qn,fa,zm,ed,$0,Cm,F0,Jf,rt,td,A0,Pn,E0,Um,j0,x0,Im,J0,z0,C0,od,U0,gc,I0,N0,W0,nd,q0,sd,P0,Z0,B0,Nm,G0,R0,bo,Wm,ad,V0,X0,qm,rd,S0,L0,Pm,ld,D0,O0,Zm,id,Q0,H0,to,dd,Y0,Zn,K0,Bm,eF,tF,Gm,oF,nF,sF,ga,aF,_a,zf;return i=new Ve({}),le=new Ve({}),Ge=new Ve({}),Va=new Ve({}),Xa=new q({props:{name:"class transformers.AlbertConfig",anchor:"transformers.AlbertConfig",parameters:[{name:"vocab_size",val:" = 30000"},{name:"embedding_size",val:" = 128"},{name:"hidden_size",val:" = 4096"},{name:"num_hidden_layers",val:" = 12"},{name:"num_hidden_groups",val:" = 1"},{name:"num_attention_heads",val:" = 64"},{name:"intermediate_size",val:" = 16384"},{name:"inner_group_num",val:" = 1"},{name:"hidden_act",val:" = 'gelu_new'"},{name:"hidden_dropout_prob",val:" = 0"},{name:"attention_probs_dropout_prob",val:" = 0"},{name:"max_position_embeddings",val:" = 512"},{name:"type_vocab_size",val:" = 2"},{name:"initializer_range",val:" = 0.02"},{name:"layer_norm_eps",val:" = 1e-12"},{name:"classifier_dropout_prob",val:" = 0.1"},{name:"position_embedding_type",val:" = 'absolute'"},{name:"pad_token_id",val:" = 0"},{name:"bos_token_id",val:" = 2"},{name:"eos_token_id",val:" = 3"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.AlbertConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 30000) &#x2014;
Vocabulary size of the ALBERT 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/albert#transformers.AlbertModel">AlbertModel</a> or <a href="/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertModel">TFAlbertModel</a>.`,name:"vocab_size"},{anchor:"transformers.AlbertConfig.embedding_size",description:`<strong>embedding_size</strong> (<code>int</code>, <em>optional</em>, defaults to 128) &#x2014;
Dimensionality of vocabulary embeddings.`,name:"embedding_size"},{anchor:"transformers.AlbertConfig.hidden_size",description:`<strong>hidden_size</strong> (<code>int</code>, <em>optional</em>, defaults to 4096) &#x2014;
Dimensionality of the encoder layers and the pooler layer.`,name:"hidden_size"},{anchor:"transformers.AlbertConfig.num_hidden_layers",description:`<strong>num_hidden_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of hidden layers in the Transformer encoder.`,name:"num_hidden_layers"},{anchor:"transformers.AlbertConfig.num_hidden_groups",description:`<strong>num_hidden_groups</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
Number of groups for the hidden layers, parameters in the same group are shared.`,name:"num_hidden_groups"},{anchor:"transformers.AlbertConfig.num_attention_heads",description:`<strong>num_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 64) &#x2014;
Number of attention heads for each attention layer in the Transformer encoder.`,name:"num_attention_heads"},{anchor:"transformers.AlbertConfig.intermediate_size",description:`<strong>intermediate_size</strong> (<code>int</code>, <em>optional</em>, defaults to 16384) &#x2014;
The dimensionality of the &#x201C;intermediate&#x201D; (often named feed-forward) layer in the Transformer encoder.`,name:"intermediate_size"},{anchor:"transformers.AlbertConfig.inner_group_num",description:`<strong>inner_group_num</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
The number of inner repetition of attention and ffn.`,name:"inner_group_num"},{anchor:"transformers.AlbertConfig.hidden_act",description:`<strong>hidden_act</strong> (<code>str</code> or <code>Callable</code>, <em>optional</em>, defaults to <code>&quot;gelu_new&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:"hidden_act"},{anchor:"transformers.AlbertConfig.hidden_dropout_prob",description:`<strong>hidden_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0) &#x2014;
The dropout probability for all fully connected layers in the embeddings, encoder, and pooler.`,name:"hidden_dropout_prob"},{anchor:"transformers.AlbertConfig.attention_probs_dropout_prob",description:`<strong>attention_probs_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_probs_dropout_prob"},{anchor:"transformers.AlbertConfig.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
(e.g., 512 or 1024 or 2048).`,name:"max_position_embeddings"},{anchor:"transformers.AlbertConfig.type_vocab_size",description:`<strong>type_vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 2) &#x2014;
The vocabulary size of the <code>token_type_ids</code> passed when calling <a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertModel">AlbertModel</a> or <a href="/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertModel">TFAlbertModel</a>.`,name:"type_vocab_size"},{anchor:"transformers.AlbertConfig.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.AlbertConfig.layer_norm_eps",description:`<strong>layer_norm_eps</strong> (<code>float</code>, <em>optional</em>, defaults to 1e-12) &#x2014;
The epsilon used by the layer normalization layers.`,name:"layer_norm_eps"},{anchor:"transformers.AlbertConfig.classifier_dropout_prob",description:`<strong>classifier_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout ratio for attached classifiers.`,name:"classifier_dropout_prob"},{anchor:"transformers.AlbertConfig.position_embedding_type",description:`<strong>position_embedding_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;absolute&quot;</code>) &#x2014;
Type of position embedding. Choose one of <code>&quot;absolute&quot;</code>, <code>&quot;relative_key&quot;</code>, <code>&quot;relative_key_query&quot;</code>. For
positional embeddings use <code>&quot;absolute&quot;</code>. For more information on <code>&quot;relative_key&quot;</code>, please refer to
<a href="https://arxiv.org/abs/1803.02155" rel="nofollow">Self-Attention with Relative Position Representations (Shaw et al.)</a>.
For more information on <code>&quot;relative_key_query&quot;</code>, please refer to <em>Method 4</em> in <a href="https://arxiv.org/abs/2009.13658" rel="nofollow">Improve Transformer Models
with Better Relative Position Embeddings (Huang et al.)</a>.`,name:"position_embedding_type"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/configuration_albert.py#L36"}}),Rn=new Ne({props:{anchor:"transformers.AlbertConfig.example",$$slots:{default:[pJ]},$$scope:{ctx:E}}}),La=new Ve({}),Da=new q({props:{name:"class transformers.AlbertTokenizer",anchor:"transformers.AlbertTokenizer",parameters:[{name:"vocab_file",val:""},{name:"do_lower_case",val:" = True"},{name:"remove_space",val:" = True"},{name:"keep_accents",val:" = False"},{name:"bos_token",val:" = '[CLS]'"},{name:"eos_token",val:" = '[SEP]'"},{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:"sp_model_kwargs",val:": typing.Union[typing.Dict[str, typing.Any], NoneType] = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.AlbertTokenizer.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
<a href="https://github.com/google/sentencepiece" rel="nofollow">SentencePiece</a> file (generally has a <em>.spm</em> extension) that
contains the vocabulary necessary to instantiate a tokenizer.`,name:"vocab_file"},{anchor:"transformers.AlbertTokenizer.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.AlbertTokenizer.remove_space",description:`<strong>remove_space</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to strip the text when tokenizing (removing excess spaces before and after the string).`,name:"remove_space"},{anchor:"transformers.AlbertTokenizer.keep_accents",description:`<strong>keep_accents</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to keep accents when tokenizing.`,name:"keep_accents"},{anchor:"transformers.AlbertTokenizer.bos_token",description:`<strong>bos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
The beginning of sequence token that was used during pretraining. Can be used a sequence classifier token.</p>
<div class="course-tip  bg-gradient-to-br dark:bg-gradient-to-r before:border-green-500 dark:before:border-green-800 from-green-50 dark:from-gray-900 to-white dark:to-gray-950 border border-green-50 text-green-700 dark:text-gray-400">
						
<p>When building a sequence using special tokens, this is not the token that is used for the beginning of
sequence. The token used is the <code>cls_token</code>.</p>

					</div>`,name:"bos_token"},{anchor:"transformers.AlbertTokenizer.eos_token",description:`<strong>eos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
The end of sequence token.</p>
<div class="course-tip  bg-gradient-to-br dark:bg-gradient-to-r before:border-green-500 dark:before:border-green-800 from-green-50 dark:from-gray-900 to-white dark:to-gray-950 border border-green-50 text-green-700 dark:text-gray-400">
						
<p>When building a sequence using special tokens, this is not the token that is used for the end of sequence.
The token used is the <code>sep_token</code>.</p>

					</div>`,name:"eos_token"},{anchor:"transformers.AlbertTokenizer.unk_token",description:`<strong>unk_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;unk&gt;&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.AlbertTokenizer.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.AlbertTokenizer.pad_token",description:`<strong>pad_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;pad&gt;&quot;</code>) &#x2014;
The token used for padding, for example when batching sequences of different lengths.`,name:"pad_token"},{anchor:"transformers.AlbertTokenizer.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.AlbertTokenizer.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.AlbertTokenizer.sp_model_kwargs",description:`<strong>sp_model_kwargs</strong> (<code>dict</code>, <em>optional</em>) &#x2014;
Will be passed to the <code>SentencePieceProcessor.__init__()</code> method. The <a href="https://github.com/google/sentencepiece/tree/master/python" rel="nofollow">Python wrapper for
SentencePiece</a> can be used, among other things,
to set:</p>
<ul>
<li>
<p><code>enable_sampling</code>: Enable subword regularization.</p>
</li>
<li>
<p><code>nbest_size</code>: Sampling parameters for unigram. Invalid for BPE-Dropout.</p>
<ul>
<li><code>nbest_size = {0,1}</code>: No sampling is performed.</li>
<li><code>nbest_size &gt; 1</code>: samples from the nbest_size results.</li>
<li><code>nbest_size &lt; 0</code>: assuming that nbest_size is infinite and samples from the all hypothesis (lattice)
using forward-filtering-and-backward-sampling algorithm.</li>
</ul>
</li>
<li>
<p><code>alpha</code>: Smoothing parameter for unigram sampling, and dropout probability of merge operations for
BPE-dropout.</p>
</li>
</ul>`,name:"sp_model_kwargs"},{anchor:"transformers.AlbertTokenizer.sp_model",description:`<strong>sp_model</strong> (<code>SentencePieceProcessor</code>) &#x2014;
The <em>SentencePiece</em> processor that is used for every conversion (string, tokens and IDs).`,name:"sp_model"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/tokenization_albert.py#L59"}}),Ya=new q({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.AlbertTokenizer.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.AlbertTokenizer.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.AlbertTokenizer.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/albert/tokenization_albert.py#L271",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>
`}}),er=new q({props:{name:"get_special_tokens_mask",anchor:"transformers.AlbertTokenizer.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.AlbertTokenizer.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.AlbertTokenizer.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.AlbertTokenizer.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/albert/tokenization_albert.py#L296",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>
`}}),or=new q({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.AlbertTokenizer.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.AlbertTokenizer.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.AlbertTokenizer.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/albert/tokenization_albert.py#L324",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>
`}}),Sn=new Ne({props:{anchor:"transformers.AlbertTokenizer.create_token_type_ids_from_sequences.example",$$slots:{default:[hJ]},$$scope:{ctx:E}}}),nr=new q({props:{name:"save_vocabulary",anchor:"transformers.AlbertTokenizer.save_vocabulary",parameters:[{name:"save_directory",val:": str"},{name:"filename_prefix",val:": typing.Optional[str] = None"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/tokenization_albert.py#L354"}}),sr=new Ve({}),ar=new q({props:{name:"class transformers.AlbertTokenizerFast",anchor:"transformers.AlbertTokenizerFast",parameters:[{name:"vocab_file",val:" = None"},{name:"tokenizer_file",val:" = None"},{name:"do_lower_case",val:" = True"},{name:"remove_space",val:" = True"},{name:"keep_accents",val:" = False"},{name:"bos_token",val:" = '[CLS]'"},{name:"eos_token",val:" = '[SEP]'"},{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:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.AlbertTokenizerFast.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
<a href="https://github.com/google/sentencepiece" rel="nofollow">SentencePiece</a> file (generally has a <em>.spm</em> extension) that
contains the vocabulary necessary to instantiate a tokenizer.`,name:"vocab_file"},{anchor:"transformers.AlbertTokenizerFast.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.AlbertTokenizerFast.remove_space",description:`<strong>remove_space</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to strip the text when tokenizing (removing excess spaces before and after the string).`,name:"remove_space"},{anchor:"transformers.AlbertTokenizerFast.keep_accents",description:`<strong>keep_accents</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to keep accents when tokenizing.`,name:"keep_accents"},{anchor:"transformers.AlbertTokenizerFast.bos_token",description:`<strong>bos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[CLS]&quot;</code>) &#x2014;
The beginning of sequence token that was used during pretraining. Can be used a sequence classifier token.</p>
<div class="course-tip  bg-gradient-to-br dark:bg-gradient-to-r before:border-green-500 dark:before:border-green-800 from-green-50 dark:from-gray-900 to-white dark:to-gray-950 border border-green-50 text-green-700 dark:text-gray-400">
						
<p>When building a sequence using special tokens, this is not the token that is used for the beginning of
sequence. The token used is the <code>cls_token</code>.</p>

					</div>`,name:"bos_token"},{anchor:"transformers.AlbertTokenizerFast.eos_token",description:`<strong>eos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;[SEP]&quot;</code>) &#x2014;
The end of sequence token. .. note:: When building a sequence using special tokens, this is not the token
that is used for the end of sequence. The token used is the <code>sep_token</code>.`,name:"eos_token"},{anchor:"transformers.AlbertTokenizerFast.unk_token",description:`<strong>unk_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;unk&gt;&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.AlbertTokenizerFast.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.AlbertTokenizerFast.pad_token",description:`<strong>pad_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;pad&gt;&quot;</code>) &#x2014;
The token used for padding, for example when batching sequences of different lengths.`,name:"pad_token"},{anchor:"transformers.AlbertTokenizerFast.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.AlbertTokenizerFast.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"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/tokenization_albert_fast.py#L72"}}),lr=new q({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.AlbertTokenizerFast.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.AlbertTokenizerFast.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.AlbertTokenizerFast.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/albert/tokenization_albert_fast.py#L173",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>
`}}),dr=new q({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.AlbertTokenizerFast.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.AlbertTokenizerFast.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.AlbertTokenizerFast.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/albert/tokenization_albert_fast.py#L198",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>
`}}),Dn=new Ne({props:{anchor:"transformers.AlbertTokenizerFast.create_token_type_ids_from_sequences.example",$$slots:{default:[mJ]},$$scope:{ctx:E}}}),cr=new Ve({}),pr=new q({props:{name:"class transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput",anchor:"transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput",parameters:[{name:"loss",val:": typing.Optional[torch.FloatTensor] = None"},{name:"prediction_logits",val:": FloatTensor = None"},{name:"sop_logits",val:": FloatTensor = None"},{name:"hidden_states",val:": typing.Optional[typing.Tuple[torch.FloatTensor]] = None"},{name:"attentions",val:": typing.Optional[typing.Tuple[torch.FloatTensor]] = None"}],parametersDescription:[{anchor:"transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput.loss",description:`<strong>loss</strong> (<em>optional</em>, returned when <code>labels</code> is provided, <code>torch.FloatTensor</code> of shape <code>(1,)</code>) &#x2014;
Total loss as the sum of the masked language modeling loss and the next sequence prediction
(classification) loss.`,name:"loss"},{anchor:"transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput.prediction_logits",description:`<strong>prediction_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) &#x2014;
Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).`,name:"prediction_logits"},{anchor:"transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput.sop_logits",description:`<strong>sop_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, 2)</code>) &#x2014;
Prediction scores of the next sequence prediction (classification) head (scores of True/False continuation
before SoftMax).`,name:"sop_logits"},{anchor:"transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput.hidden_states",description:`<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>) &#x2014;
Tuple of <code>torch.FloatTensor</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.`,name:"hidden_states"},{anchor:"transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput.attentions",description:`<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>) &#x2014;
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.`,name:"attentions"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_albert.py#L531"}}),mr=new q({props:{name:"class transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput",anchor:"transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput",parameters:[{name:"loss",val:": tf.Tensor = None"},{name:"prediction_logits",val:": tf.Tensor = None"},{name:"sop_logits",val:": tf.Tensor = None"},{name:"hidden_states",val:": Tuple[tf.Tensor] | None = None"},{name:"attentions",val:": Tuple[tf.Tensor] | None = None"}],parametersDescription:[{anchor:"transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput.prediction_logits",description:`<strong>prediction_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) &#x2014;
Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).`,name:"prediction_logits"},{anchor:"transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput.sop_logits",description:`<strong>sop_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, 2)</code>) &#x2014;
Prediction scores of the next sequence prediction (classification) head (scores of True/False continuation
before SoftMax).`,name:"sop_logits"},{anchor:"transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput.hidden_states",description:`<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>) &#x2014;
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.`,name:"hidden_states"},{anchor:"transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput.attentions",description:`<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>) &#x2014;
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.`,name:"attentions"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_tf_albert.py#L655"}}),fr=new Ve({}),gr=new q({props:{name:"class transformers.AlbertModel",anchor:"transformers.AlbertModel",parameters:[{name:"config",val:": AlbertConfig"},{name:"add_pooling_layer",val:": bool = True"}],parametersDescription:[{anchor:"transformers.AlbertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_albert.py#L634"}}),Tr=new q({props:{name:"forward",anchor:"transformers.AlbertModel.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = 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.AlbertModel.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.AlbertModel.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.AlbertModel.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.AlbertModel.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.AlbertModel.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.AlbertModel.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.AlbertModel.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.AlbertModel.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.AlbertModel.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/albert/modeling_albert.py#L677",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPooling"
>transformers.modeling_outputs.BaseModelOutputWithPooling</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/albert#transformers.AlbertConfig"
>AlbertConfig</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>pooler_output</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) after further processing
through the layers used for the auxiliary pretraining task. E.g. for BERT-family of models, this returns
the classification token after processing through a linear layer and a tanh activation function. The linear
layer weights are trained from the next sentence prediction (classification) objective during pretraining.</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.BaseModelOutputWithPooling"
>transformers.modeling_outputs.BaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Hn=new Re({props:{$$slots:{default:[uJ]},$$scope:{ctx:E}}}),Yn=new Ne({props:{anchor:"transformers.AlbertModel.forward.example",$$slots:{default:[fJ]},$$scope:{ctx:E}}}),kr=new Ve({}),wr=new q({props:{name:"class transformers.AlbertForPreTraining",anchor:"transformers.AlbertForPreTraining",parameters:[{name:"config",val:": AlbertConfig"}],parametersDescription:[{anchor:"transformers.AlbertForPreTraining.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_albert.py#L763"}}),Fr=new q({props:{name:"forward",anchor:"transformers.AlbertForPreTraining.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"sentence_order_label",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.AlbertForPreTraining.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.AlbertForPreTraining.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.AlbertForPreTraining.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.AlbertForPreTraining.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.AlbertForPreTraining.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.AlbertForPreTraining.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.AlbertForPreTraining.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.AlbertForPreTraining.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.AlbertForPreTraining.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.AlbertForPreTraining.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"},{anchor:"transformers.AlbertForPreTraining.forward.sentence_order_label",description:`<strong>sentence_order_label</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the next sequence prediction (classification) loss. Input should be a sequence pair
(see <code>input_ids</code> docstring) Indices should be in <code>[0, 1]</code>. <code>0</code> indicates original order (sequence A, then
sequence B), <code>1</code> indicates switched order (sequence B, then sequence A).`,name:"sentence_order_label"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_albert.py#L785",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/model_doc/albert#transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput"
>transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput</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/albert#transformers.AlbertConfig"
>AlbertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<em>optional</em>, returned when <code>labels</code> is provided, <code>torch.FloatTensor</code> of shape <code>(1,)</code>) \u2014 Total loss as the sum of the masked language modeling loss and the next sequence prediction
(classification) loss.</p>
</li>
<li>
<p><strong>prediction_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>sop_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, 2)</code>) \u2014 Prediction scores of the next sequence prediction (classification) head (scores of True/False continuation
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 + 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(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/model_doc/albert#transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput"
>transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),es=new Re({props:{$$slots:{default:[gJ]},$$scope:{ctx:E}}}),ts=new Ne({props:{anchor:"transformers.AlbertForPreTraining.forward.example",$$slots:{default:[_J]},$$scope:{ctx:E}}}),Ar=new Ve({}),Er=new q({props:{name:"class transformers.AlbertForMaskedLM",anchor:"transformers.AlbertForMaskedLM",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.AlbertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_albert.py#L911"}}),Cr=new q({props:{name:"forward",anchor:"transformers.AlbertForMaskedLM.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = 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.AlbertForMaskedLM.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.AlbertForMaskedLM.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.AlbertForMaskedLM.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.AlbertForMaskedLM.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.AlbertForMaskedLM.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.AlbertForMaskedLM.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.AlbertForMaskedLM.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.AlbertForMaskedLM.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.AlbertForMaskedLM.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.AlbertForMaskedLM.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/albert/modeling_albert.py#L932",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),ns=new Re({props:{$$slots:{default:[bJ]},$$scope:{ctx:E}}}),ss=new Ne({props:{anchor:"transformers.AlbertForMaskedLM.forward.example",$$slots:{default:[yJ]},$$scope:{ctx:E}}}),as=new Ne({props:{anchor:"transformers.AlbertForMaskedLM.forward.example-2",$$slots:{default:[TJ]},$$scope:{ctx:E}}}),Ur=new Ve({}),Ir=new q({props:{name:"class transformers.AlbertForSequenceClassification",anchor:"transformers.AlbertForSequenceClassification",parameters:[{name:"config",val:": AlbertConfig"}],parametersDescription:[{anchor:"transformers.AlbertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_albert.py#L1025"}}),Pr=new q({props:{name:"forward",anchor:"transformers.AlbertForSequenceClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = 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.AlbertForSequenceClassification.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.AlbertForSequenceClassification.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.AlbertForSequenceClassification.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.AlbertForSequenceClassification.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.AlbertForSequenceClassification.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.AlbertForSequenceClassification.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.AlbertForSequenceClassification.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.AlbertForSequenceClassification.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.AlbertForSequenceClassification.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.AlbertForSequenceClassification.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/albert/modeling_albert.py#L1038",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),ls=new Re({props:{$$slots:{default:[kJ]},$$scope:{ctx:E}}}),is=new Ne({props:{anchor:"transformers.AlbertForSequenceClassification.forward.example",$$slots:{default:[wJ]},$$scope:{ctx:E}}}),ds=new Ne({props:{anchor:"transformers.AlbertForSequenceClassification.forward.example-2",$$slots:{default:[vJ]},$$scope:{ctx:E}}}),Zr=new Ve({}),Br=new q({props:{name:"class transformers.AlbertForMultipleChoice",anchor:"transformers.AlbertForMultipleChoice",parameters:[{name:"config",val:": AlbertConfig"}],parametersDescription:[{anchor:"transformers.AlbertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_albert.py#L1312"}}),Xr=new q({props:{name:"forward",anchor:"transformers.AlbertForMultipleChoice.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = 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.AlbertForMultipleChoice.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.AlbertForMultipleChoice.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.AlbertForMultipleChoice.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.AlbertForMultipleChoice.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.AlbertForMultipleChoice.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.AlbertForMultipleChoice.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.AlbertForMultipleChoice.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.AlbertForMultipleChoice.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.AlbertForMultipleChoice.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.AlbertForMultipleChoice.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 <em>num_choices</em> is the size of the second dimension of the input tensors. (see
<em>input_ids</em> above)`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_albert.py#L1323",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),ps=new Re({props:{$$slots:{default:[MJ]},$$scope:{ctx:E}}}),hs=new Ne({props:{anchor:"transformers.AlbertForMultipleChoice.forward.example",$$slots:{default:[$J]},$$scope:{ctx:E}}}),Sr=new Ve({}),Lr=new q({props:{name:"class transformers.AlbertForTokenClassification",anchor:"transformers.AlbertForTokenClassification",parameters:[{name:"config",val:": AlbertConfig"}],parametersDescription:[{anchor:"transformers.AlbertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_albert.py#L1126"}}),Hr=new q({props:{name:"forward",anchor:"transformers.AlbertForTokenClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = 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.AlbertForTokenClassification.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.AlbertForTokenClassification.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.AlbertForTokenClassification.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.AlbertForTokenClassification.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.AlbertForTokenClassification.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.AlbertForTokenClassification.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.AlbertForTokenClassification.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.AlbertForTokenClassification.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.AlbertForTokenClassification.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.AlbertForTokenClassification.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/albert/modeling_albert.py#L1143",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),us=new Re({props:{$$slots:{default:[FJ]},$$scope:{ctx:E}}}),fs=new Ne({props:{anchor:"transformers.AlbertForTokenClassification.forward.example",$$slots:{default:[AJ]},$$scope:{ctx:E}}}),Yr=new Ve({}),Kr=new q({props:{name:"class transformers.AlbertForQuestionAnswering",anchor:"transformers.AlbertForQuestionAnswering",parameters:[{name:"config",val:": AlbertConfig"}],parametersDescription:[{anchor:"transformers.AlbertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_albert.py#L1209"}}),nl=new q({props:{name:"forward",anchor:"transformers.AlbertForQuestionAnswering.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"start_positions",val:": typing.Optional[torch.LongTensor] = None"},{name:"end_positions",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.AlbertForQuestionAnswering.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.AlbertForQuestionAnswering.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.AlbertForQuestionAnswering.forward.token_type_ids",description:`<strong>token_type_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.AlbertForQuestionAnswering.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.AlbertForQuestionAnswering.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.AlbertForQuestionAnswering.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.AlbertForQuestionAnswering.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.AlbertForQuestionAnswering.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.AlbertForQuestionAnswering.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.AlbertForQuestionAnswering.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.AlbertForQuestionAnswering.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/albert/modeling_albert.py#L1220",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),_s=new Re({props:{$$slots:{default:[EJ]},$$scope:{ctx:E}}}),bs=new Ne({props:{anchor:"transformers.AlbertForQuestionAnswering.forward.example",$$slots:{default:[jJ]},$$scope:{ctx:E}}}),sl=new Ve({}),al=new q({props:{name:"class transformers.TFAlbertModel",anchor:"transformers.TFAlbertModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFAlbertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_tf_albert.py#L787"}}),Ts=new Re({props:{$$slots:{default:[xJ]},$$scope:{ctx:E}}}),dl=new q({props:{name:"call",anchor:"transformers.TFAlbertModel.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",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.TFAlbertModel.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFAlbertModel.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.TFAlbertModel.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFAlbertModel.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFAlbertModel.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.TFAlbertModel.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.TFAlbertModel.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.TFAlbertModel.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.TFAlbertModel.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.TFAlbertModel.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/albert/modeling_tf_albert.py#L793",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutputWithPooling"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPooling</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/albert#transformers.AlbertConfig"
>AlbertConfig</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>pooler_output</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) further processed by a
Linear layer and a Tanh activation function. The Linear layer weights are trained from the next sentence
prediction (classification) objective during pretraining.</p>
<p>This output is usually <em>not</em> a good summary of the semantic content of the input, you\u2019re often better with
averaging or pooling the sequence of hidden-states for the whole input sequence.</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.TFBaseModelOutputWithPooling"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPooling</a> or <code>tuple(tf.Tensor)</code></p>
`}}),ks=new Re({props:{$$slots:{default:[JJ]},$$scope:{ctx:E}}}),ws=new Ne({props:{anchor:"transformers.TFAlbertModel.call.example",$$slots:{default:[zJ]},$$scope:{ctx:E}}}),cl=new Ve({}),pl=new q({props:{name:"class transformers.TFAlbertForPreTraining",anchor:"transformers.TFAlbertForPreTraining",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFAlbertForPreTraining.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_tf_albert.py#L836"}}),Ms=new Re({props:{$$slots:{default:[CJ]},$$scope:{ctx:E}}}),fl=new q({props:{name:"call",anchor:"transformers.TFAlbertForPreTraining.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",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:"sentence_order_label",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFAlbertForPreTraining.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFAlbertForPreTraining.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.TFAlbertForPreTraining.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFAlbertForPreTraining.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFAlbertForPreTraining.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.TFAlbertForPreTraining.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.TFAlbertForPreTraining.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.TFAlbertForPreTraining.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.TFAlbertForPreTraining.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.TFAlbertForPreTraining.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/albert/modeling_tf_albert.py#L852",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/model_doc/albert#transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput"
>transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput</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/albert#transformers.AlbertConfig"
>AlbertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>prediction_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>sop_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, 2)</code>) \u2014 Prediction scores of the next sequence prediction (classification) head (scores of True/False continuation
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/model_doc/albert#transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput"
>transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),$s=new Re({props:{$$slots:{default:[UJ]},$$scope:{ctx:E}}}),Fs=new Ne({props:{anchor:"transformers.TFAlbertForPreTraining.call.example",$$slots:{default:[IJ]},$$scope:{ctx:E}}}),gl=new Ve({}),_l=new q({props:{name:"class transformers.TFAlbertForMaskedLM",anchor:"transformers.TFAlbertForMaskedLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFAlbertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_tf_albert.py#L944"}}),Es=new Re({props:{$$slots:{default:[NJ]},$$scope:{ctx:E}}}),wl=new q({props:{name:"call",anchor:"transformers.TFAlbertForMaskedLM.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",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.TFAlbertForMaskedLM.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFAlbertForMaskedLM.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.TFAlbertForMaskedLM.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFAlbertForMaskedLM.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFAlbertForMaskedLM.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.TFAlbertForMaskedLM.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.TFAlbertForMaskedLM.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.TFAlbertForMaskedLM.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.TFAlbertForMaskedLM.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.TFAlbertForMaskedLM.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.TFAlbertForMaskedLM.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/albert/modeling_tf_albert.py#L957",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),js=new Re({props:{$$slots:{default:[WJ]},$$scope:{ctx:E}}}),xs=new Ne({props:{anchor:"transformers.TFAlbertForMaskedLM.call.example",$$slots:{default:[qJ]},$$scope:{ctx:E}}}),Js=new Ne({props:{anchor:"transformers.TFAlbertForMaskedLM.call.example-2",$$slots:{default:[PJ]},$$scope:{ctx:E}}}),vl=new Ve({}),Ml=new q({props:{name:"class transformers.TFAlbertForSequenceClassification",anchor:"transformers.TFAlbertForSequenceClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFAlbertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_tf_albert.py#L1046"}}),Cs=new Re({props:{$$slots:{default:[ZJ]},$$scope:{ctx:E}}}),El=new q({props:{name:"call",anchor:"transformers.TFAlbertForSequenceClassification.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",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.TFAlbertForSequenceClassification.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFAlbertForSequenceClassification.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.TFAlbertForSequenceClassification.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFAlbertForSequenceClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFAlbertForSequenceClassification.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.TFAlbertForSequenceClassification.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.TFAlbertForSequenceClassification.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.TFAlbertForSequenceClassification.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.TFAlbertForSequenceClassification.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.TFAlbertForSequenceClassification.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.TFAlbertForSequenceClassification.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/albert/modeling_tf_albert.py#L1062",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),Us=new Re({props:{$$slots:{default:[BJ]},$$scope:{ctx:E}}}),Is=new Ne({props:{anchor:"transformers.TFAlbertForSequenceClassification.call.example",$$slots:{default:[GJ]},$$scope:{ctx:E}}}),Ns=new Ne({props:{anchor:"transformers.TFAlbertForSequenceClassification.call.example-2",$$slots:{default:[RJ]},$$scope:{ctx:E}}}),jl=new Ve({}),xl=new q({props:{name:"class transformers.TFAlbertForMultipleChoice",anchor:"transformers.TFAlbertForMultipleChoice",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFAlbertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_tf_albert.py#L1306"}}),qs=new Re({props:{$$slots:{default:[VJ]},$$scope:{ctx:E}}}),Ul=new q({props:{name:"call",anchor:"transformers.TFAlbertForMultipleChoice.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",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.TFAlbertForMultipleChoice.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFAlbertForMultipleChoice.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.TFAlbertForMultipleChoice.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFAlbertForMultipleChoice.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFAlbertForMultipleChoice.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.TFAlbertForMultipleChoice.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.TFAlbertForMultipleChoice.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.TFAlbertForMultipleChoice.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.TFAlbertForMultipleChoice.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.TFAlbertForMultipleChoice.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.TFAlbertForMultipleChoice.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/albert/modeling_tf_albert.py#L1320",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),Ps=new Re({props:{$$slots:{default:[XJ]},$$scope:{ctx:E}}}),Zs=new Ne({props:{anchor:"transformers.TFAlbertForMultipleChoice.call.example",$$slots:{default:[SJ]},$$scope:{ctx:E}}}),Il=new Ve({}),Nl=new q({props:{name:"class transformers.TFAlbertForTokenClassification",anchor:"transformers.TFAlbertForTokenClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFAlbertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_tf_albert.py#L1128"}}),Gs=new Re({props:{$$slots:{default:[LJ]},$$scope:{ctx:E}}}),Zl=new q({props:{name:"call",anchor:"transformers.TFAlbertForTokenClassification.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",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.TFAlbertForTokenClassification.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFAlbertForTokenClassification.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.TFAlbertForTokenClassification.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFAlbertForTokenClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFAlbertForTokenClassification.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.TFAlbertForTokenClassification.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.TFAlbertForTokenClassification.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.TFAlbertForTokenClassification.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.TFAlbertForTokenClassification.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.TFAlbertForTokenClassification.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.TFAlbertForTokenClassification.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/albert/modeling_tf_albert.py#L1149",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),Rs=new Re({props:{$$slots:{default:[DJ]},$$scope:{ctx:E}}}),Vs=new Ne({props:{anchor:"transformers.TFAlbertForTokenClassification.call.example",$$slots:{default:[OJ]},$$scope:{ctx:E}}}),Xs=new Ne({props:{anchor:"transformers.TFAlbertForTokenClassification.call.example-2",$$slots:{default:[QJ]},$$scope:{ctx:E}}}),Bl=new Ve({}),Gl=new q({props:{name:"class transformers.TFAlbertForQuestionAnswering",anchor:"transformers.TFAlbertForQuestionAnswering",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFAlbertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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/albert/modeling_tf_albert.py#L1211"}}),Ls=new Re({props:{$$slots:{default:[HJ]},$$scope:{ctx:E}}}),Sl=new q({props:{name:"call",anchor:"transformers.TFAlbertForQuestionAnswering.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",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.TFAlbertForQuestionAnswering.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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFAlbertForQuestionAnswering.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.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.TFAlbertForQuestionAnswering.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/albert/modeling_tf_albert.py#L1225",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),Ds=new Re({props:{$$slots:{default:[YJ]},$$scope:{ctx:E}}}),Os=new Ne({props:{anchor:"transformers.TFAlbertForQuestionAnswering.call.example",$$slots:{default:[KJ]},$$scope:{ctx:E}}}),Qs=new Ne({props:{anchor:"transformers.TFAlbertForQuestionAnswering.call.example-2",$$slots:{default:[ez]},$$scope:{ctx:E}}}),Ll=new Ve({}),Dl=new q({props:{name:"class transformers.FlaxAlbertModel",anchor:"transformers.FlaxAlbertModel",parameters:[{name:"config",val:": AlbertConfig"},{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.FlaxAlbertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxAlbertModel.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_flax_albert.py#L676"}}),oi=new q({props:{name:"__call__",anchor:"transformers.FlaxAlbertModel.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",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.FlaxAlbertModel.__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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertModel.__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.FlaxAlbertModel.__call__.token_type_ids",description:`<strong>token_type_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.FlaxAlbertModel.__call__.position_ids",description:`<strong>position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"position_ids"},{anchor:"transformers.FlaxAlbertModel.__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/albert/modeling_flax_albert.py#L553",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</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/albert#transformers.AlbertConfig"
>AlbertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>jnp.ndarray</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>pooler_output</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) further processed by a
Linear layer and a Tanh activation function. The Linear layer weights are trained from the next sentence
prediction (classification) objective during pretraining.</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.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ys=new Re({props:{$$slots:{default:[tz]},$$scope:{ctx:E}}}),Ks=new Ne({props:{anchor:"transformers.FlaxAlbertModel.__call__.example",$$slots:{default:[oz]},$$scope:{ctx:E}}}),ni=new Ve({}),si=new q({props:{name:"class transformers.FlaxAlbertForPreTraining",anchor:"transformers.FlaxAlbertForPreTraining",parameters:[{name:"config",val:": AlbertConfig"},{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.FlaxAlbertForPreTraining.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxAlbertForPreTraining.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_flax_albert.py#L744"}}),hi=new q({props:{name:"__call__",anchor:"transformers.FlaxAlbertForPreTraining.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",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.FlaxAlbertForPreTraining.__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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertForPreTraining.__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.FlaxAlbertForPreTraining.__call__.token_type_ids",description:`<strong>token_type_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.FlaxAlbertForPreTraining.__call__.position_ids",description:`<strong>position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"position_ids"},{anchor:"transformers.FlaxAlbertForPreTraining.__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/albert/modeling_flax_albert.py#L553",returnDescription:`
<p>A <code>transformers.models.albert.modeling_flax_albert.FlaxAlbertForPreTrainingOutput</code> 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/albert#transformers.AlbertConfig"
>AlbertConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>prediction_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>sop_logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, 2)</code>) \u2014 Prediction scores of the next sequence prediction (classification) head (scores of True/False continuation
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><code>transformers.models.albert.modeling_flax_albert.FlaxAlbertForPreTrainingOutput</code> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ta=new Re({props:{$$slots:{default:[nz]},$$scope:{ctx:E}}}),oa=new Ne({props:{anchor:"transformers.FlaxAlbertForPreTraining.__call__.example",$$slots:{default:[sz]},$$scope:{ctx:E}}}),mi=new Ve({}),ui=new q({props:{name:"class transformers.FlaxAlbertForMaskedLM",anchor:"transformers.FlaxAlbertForMaskedLM",parameters:[{name:"config",val:": AlbertConfig"},{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.FlaxAlbertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxAlbertForMaskedLM.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_flax_albert.py#L827"}}),vi=new q({props:{name:"__call__",anchor:"transformers.FlaxAlbertForMaskedLM.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",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.FlaxAlbertForMaskedLM.__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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertForMaskedLM.__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.FlaxAlbertForMaskedLM.__call__.token_type_ids",description:`<strong>token_type_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.FlaxAlbertForMaskedLM.__call__.position_ids",description:`<strong>position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"position_ids"},{anchor:"transformers.FlaxAlbertForMaskedLM.__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/albert/modeling_flax_albert.py#L553",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),sa=new Re({props:{$$slots:{default:[az]},$$scope:{ctx:E}}}),aa=new Ne({props:{anchor:"transformers.FlaxAlbertForMaskedLM.__call__.example",$$slots:{default:[rz]},$$scope:{ctx:E}}}),Mi=new Ve({}),$i=new q({props:{name:"class transformers.FlaxAlbertForSequenceClassification",anchor:"transformers.FlaxAlbertForSequenceClassification",parameters:[{name:"config",val:": AlbertConfig"},{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.FlaxAlbertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxAlbertForSequenceClassification.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_flax_albert.py#L895"}}),Ci=new q({props:{name:"__call__",anchor:"transformers.FlaxAlbertForSequenceClassification.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",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.FlaxAlbertForSequenceClassification.__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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertForSequenceClassification.__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.FlaxAlbertForSequenceClassification.__call__.token_type_ids",description:`<strong>token_type_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.FlaxAlbertForSequenceClassification.__call__.position_ids",description:`<strong>position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"position_ids"},{anchor:"transformers.FlaxAlbertForSequenceClassification.__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/albert/modeling_flax_albert.py#L553",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),la=new Re({props:{$$slots:{default:[lz]},$$scope:{ctx:E}}}),ia=new Ne({props:{anchor:"transformers.FlaxAlbertForSequenceClassification.__call__.example",$$slots:{default:[iz]},$$scope:{ctx:E}}}),Ui=new Ve({}),Ii=new q({props:{name:"class transformers.FlaxAlbertForMultipleChoice",anchor:"transformers.FlaxAlbertForMultipleChoice",parameters:[{name:"config",val:": AlbertConfig"},{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.FlaxAlbertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxAlbertForMultipleChoice.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_flax_albert.py#L968"}}),Ri=new q({props:{name:"__call__",anchor:"transformers.FlaxAlbertForMultipleChoice.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",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.FlaxAlbertForMultipleChoice.__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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertForMultipleChoice.__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.FlaxAlbertForMultipleChoice.__call__.token_type_ids",description:`<strong>token_type_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.FlaxAlbertForMultipleChoice.__call__.position_ids",description:`<strong>position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"position_ids"},{anchor:"transformers.FlaxAlbertForMultipleChoice.__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/albert/modeling_flax_albert.py#L553",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),ca=new Re({props:{$$slots:{default:[dz]},$$scope:{ctx:E}}}),pa=new Ne({props:{anchor:"transformers.FlaxAlbertForMultipleChoice.__call__.example",$$slots:{default:[cz]},$$scope:{ctx:E}}}),Vi=new Ve({}),Xi=new q({props:{name:"class transformers.FlaxAlbertForTokenClassification",anchor:"transformers.FlaxAlbertForTokenClassification",parameters:[{name:"config",val:": AlbertConfig"},{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.FlaxAlbertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxAlbertForTokenClassification.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_flax_albert.py#L1041"}}),Ki=new q({props:{name:"__call__",anchor:"transformers.FlaxAlbertForTokenClassification.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",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.FlaxAlbertForTokenClassification.__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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertForTokenClassification.__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.FlaxAlbertForTokenClassification.__call__.token_type_ids",description:`<strong>token_type_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.FlaxAlbertForTokenClassification.__call__.position_ids",description:`<strong>position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"position_ids"},{anchor:"transformers.FlaxAlbertForTokenClassification.__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/albert/modeling_flax_albert.py#L553",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),ma=new Re({props:{$$slots:{default:[pz]},$$scope:{ctx:E}}}),ua=new Ne({props:{anchor:"transformers.FlaxAlbertForTokenClassification.__call__.example",$$slots:{default:[hz]},$$scope:{ctx:E}}}),ed=new Ve({}),td=new q({props:{name:"class transformers.FlaxAlbertForQuestionAnswering",anchor:"transformers.FlaxAlbertForQuestionAnswering",parameters:[{name:"config",val:": AlbertConfig"},{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.FlaxAlbertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/albert#transformers.AlbertConfig">AlbertConfig</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.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxAlbertForQuestionAnswering.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/albert/modeling_flax_albert.py#L1109"}}),dd=new q({props:{name:"__call__",anchor:"transformers.FlaxAlbertForQuestionAnswering.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",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.FlaxAlbertForQuestionAnswering.__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/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertForQuestionAnswering.__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.FlaxAlbertForQuestionAnswering.__call__.token_type_ids",description:`<strong>token_type_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.FlaxAlbertForQuestionAnswering.__call__.position_ids",description:`<strong>position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"position_ids"},{anchor:"transformers.FlaxAlbertForQuestionAnswering.__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/albert/modeling_flax_albert.py#L553",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/albert#transformers.AlbertConfig"
>AlbertConfig</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>
`}}),ga=new Re({props:{$$slots:{default:[mz]},$$scope:{ctx:E}}}),_a=new Ne({props:{anchor:"transformers.FlaxAlbertForQuestionAnswering.__call__.example",$$slots:{default:[uz]},$$scope:{ctx:E}}}),{c(){d=n("meta"),y=c(),m=n("h1"),f=n("a"),b=n("span"),k(i.$$.fragment),h=c(),j=n("span"),Me=a("ALBERT"),ye=c(),B=n("div"),de=n("a"),K=n("img"),$e=c(),V=n("a"),ce=n("img"),O=c(),se=n("h2"),ae=n("a"),X=n("span"),k(le.$$.fragment),Fe=c(),S=n("span"),Ae=a("Overview"),Te=c(),G=n("p"),Ee=a("The ALBERT model was proposed in "),ie=n("a"),ee=a("ALBERT: A Lite BERT for Self-supervised Learning of Language Representations"),z=a(` by Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma,
Radu Soricut. It presents two parameter-reduction techniques to lower memory consumption and increase the training
speed of BERT:`),U=c(),re=n("ul"),L=n("li"),je=a("Splitting the embedding matrix into two smaller matrices."),xe=c(),D=n("li"),Je=a("Using repeating layers split among groups."),ke=c(),C=n("p"),ze=a("The abstract from the paper is the following:"),Q=c(),pe=n("p"),me=n("em"),Y=a(`Increasing model size when pretraining natural language representations often results in improved performance on
downstream tasks. However, at some point further model increases become harder due to GPU/TPU memory limitations,
longer training times, and unexpected model degradation. To address these problems, we present two parameter-reduction
techniques to lower memory consumption and increase the training speed of BERT. Comprehensive empirical evidence shows
that our proposed methods lead to models that scale much better compared to the original BERT. We also use a
self-supervised loss that focuses on modeling inter-sentence coherence, and show it consistently helps downstream tasks
with multi-sentence inputs. As a result, our best model establishes new state-of-the-art results on the GLUE, RACE, and
SQuAD benchmarks while having fewer parameters compared to BERT-large.`),we=c(),he=n("p"),P=a("Tips:"),ve=c(),W=n("ul"),ue=n("li"),te=a(`ALBERT is a model with absolute position embeddings so it\u2019s usually advised to pad the inputs on the right rather
than the left.`),I=c(),fe=n("li"),N=a(`ALBERT uses repeating layers which results in a small memory footprint, however the computational cost remains
similar to a BERT-like architecture with the same number of hidden layers as it has to iterate through the same
number of (repeating) layers.`),Ce=c(),ge=n("li"),T=a("Embedding size E is different from hidden size H justified because the embeddings are context independent (one embedding vector represents one token), whereas hidden states are context dependent (one hidden state represents a sequence of tokens) so it\u2019s more logical to have H >> E. Also, the embedding matrix is large since it\u2019s V x E (V being the vocab size). If E < H, it has less parameters."),x=c(),Xe=n("li"),oe=a(`Layers are split in groups that share parameters (to save memory).
Next sentence prediction is replaced by a sentence ordering prediction: in the inputs, we have two sentences A and B (that are consecutive) and we either feed A followed by B or B followed by A. The model must predict if they have been swapped or not.`),Le=c(),_e=n("p"),J=a("This model was contributed by "),Ze=n("a"),De=a("lysandre"),Oe=a(`. This model jax version was contributed by
`),Be=n("a"),Qe=a("kamalkraj"),Z=a(". The original code can be found "),R=n("a"),He=a("here"),Ye=a("."),H=c(),Ie=n("h2"),Pe=n("a"),be=n("span"),k(Ge.$$.fragment),ne=c(),Se=n("span"),n_=a("Documentation resources"),Cu=c(),kt=n("ul"),Lc=n("li"),bd=n("a"),s_=a("Text classification task guide"),a_=c(),Dc=n("li"),yd=n("a"),r_=a("Token classification task guide"),l_=c(),Oc=n("li"),Td=n("a"),i_=a("Question answering task guide"),d_=c(),Qc=n("li"),kd=n("a"),c_=a("Masked language modeling task guide"),p_=c(),Hc=n("li"),wd=n("a"),h_=a("Multiple choice task guide"),Uu=c(),qo=n("h2"),Gn=n("a"),Yc=n("span"),k(Va.$$.fragment),m_=c(),Kc=n("span"),u_=a("AlbertConfig"),Iu=c(),Nt=n("div"),k(Xa.$$.fragment),f_=c(),co=n("p"),g_=a("This is the configuration class to store the configuration of a "),vd=n("a"),__=a("AlbertModel"),b_=a(" or a "),Md=n("a"),y_=a("TFAlbertModel"),T_=a(`. It is used
to instantiate an ALBERT 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 ALBERT
`),Sa=n("a"),k_=a("albert-xxlarge-v2"),w_=a(" architecture."),v_=c(),Po=n("p"),M_=a("Configuration objects inherit from "),$d=n("a"),$_=a("PretrainedConfig"),F_=a(` and can be used to control the model outputs. Read the
documentation from `),Fd=n("a"),A_=a("PretrainedConfig"),E_=a(" for more information."),j_=c(),k(Rn.$$.fragment),Nu=c(),Zo=n("h2"),Vn=n("a"),ep=n("span"),k(La.$$.fragment),x_=c(),tp=n("span"),J_=a("AlbertTokenizer"),Wu=c(),Ke=n("div"),k(Da.$$.fragment),z_=c(),Oa=n("p"),C_=a("Construct an ALBERT tokenizer. Based on "),Qa=n("a"),U_=a("SentencePiece"),I_=a("."),N_=c(),Ha=n("p"),W_=a("This tokenizer inherits from "),Ad=n("a"),q_=a("PreTrainedTokenizer"),P_=a(` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Z_=c(),vo=n("div"),k(Ya.$$.fragment),B_=c(),op=n("p"),G_=a(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An ALBERT sequence has the following format:`),R_=c(),Ka=n("ul"),Ed=n("li"),V_=a("single sequence: "),np=n("code"),X_=a("[CLS] X [SEP]"),S_=c(),jd=n("li"),L_=a("pair of sequences: "),sp=n("code"),D_=a("[CLS] A [SEP] B [SEP]"),O_=c(),Xn=n("div"),k(er.$$.fragment),Q_=c(),tr=n("p"),H_=a(`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),ap=n("code"),Y_=a("prepare_for_model"),K_=a(" method."),eb=c(),Pt=n("div"),k(or.$$.fragment),tb=c(),rp=n("p"),ob=a("Create a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT"),nb=c(),k(Sn.$$.fragment),sb=c(),Bo=n("p"),ab=a("If "),lp=n("code"),rb=a("token_ids_1"),lb=a(" is "),ip=n("code"),ib=a("None"),db=a(", this method only returns the first portion of the mask (0s)."),cb=c(),xd=n("div"),k(nr.$$.fragment),qu=c(),Go=n("h2"),Ln=n("a"),dp=n("span"),k(sr.$$.fragment),pb=c(),cp=n("span"),hb=a("AlbertTokenizerFast"),Pu=c(),Wt=n("div"),k(ar.$$.fragment),mb=c(),po=n("p"),ub=a("Construct a \u201Cfast\u201D ALBERT tokenizer (backed by HuggingFace\u2019s "),pp=n("em"),fb=a("tokenizers"),gb=a(` library). Based on
`),rr=n("a"),_b=a("Unigram"),bb=a(`. This
tokenizer inherits from `),Jd=n("a"),yb=a("PreTrainedTokenizerFast"),Tb=a(` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods`),kb=c(),Mo=n("div"),k(lr.$$.fragment),wb=c(),hp=n("p"),vb=a(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An ALBERT sequence has the following format:`),Mb=c(),ir=n("ul"),zd=n("li"),$b=a("single sequence: "),mp=n("code"),Fb=a("[CLS] X [SEP]"),Ab=c(),Cd=n("li"),Eb=a("pair of sequences: "),up=n("code"),jb=a("[CLS] A [SEP] B [SEP]"),xb=c(),Zt=n("div"),k(dr.$$.fragment),Jb=c(),fp=n("p"),zb=a("Creates a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT"),Cb=c(),k(Dn.$$.fragment),Ub=c(),gp=n("p"),Ib=a("if token_ids_1 is None, only returns the first portion of the mask (0s)."),Zu=c(),Ro=n("h2"),On=n("a"),_p=n("span"),k(cr.$$.fragment),Nb=c(),bp=n("span"),Wb=a("Albert specific outputs"),Bu=c(),Vo=n("div"),k(pr.$$.fragment),qb=c(),hr=n("p"),Pb=a("Output type of "),Ud=n("a"),Zb=a("AlbertForPreTraining"),Bb=a("."),Gu=c(),Xo=n("div"),k(mr.$$.fragment),Gb=c(),ur=n("p"),Rb=a("Output type of "),Id=n("a"),Vb=a("TFAlbertForPreTraining"),Xb=a("."),Ru=c(),So=n("h2"),Qn=n("a"),yp=n("span"),k(fr.$$.fragment),Sb=c(),Tp=n("span"),Lb=a("AlbertModel"),Vu=c(),ut=n("div"),k(gr.$$.fragment),Db=c(),kp=n("p"),Ob=a("The bare ALBERT Model transformer outputting raw hidden-states without any specific head on top."),Qb=c(),_r=n("p"),Hb=a("This model inherits from "),Nd=n("a"),Yb=a("PreTrainedModel"),Kb=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ey=c(),br=n("p"),ty=a("This model is also a PyTorch "),yr=n("a"),oy=a("torch.nn.Module"),ny=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),sy=c(),Bt=n("div"),k(Tr.$$.fragment),ay=c(),Lo=n("p"),ry=a("The "),Wd=n("a"),ly=a("AlbertModel"),iy=a(" forward method, overrides the "),wp=n("code"),dy=a("__call__"),cy=a(" special method."),py=c(),k(Hn.$$.fragment),hy=c(),k(Yn.$$.fragment),Xu=c(),Do=n("h2"),Kn=n("a"),vp=n("span"),k(kr.$$.fragment),my=c(),Mp=n("span"),uy=a("AlbertForPreTraining"),Su=c(),ft=n("div"),k(wr.$$.fragment),fy=c(),Oo=n("p"),gy=a("Albert Model with two heads on top as done during the pretraining: a "),$p=n("code"),_y=a("masked language modeling"),by=a(` head and a
`),Fp=n("code"),yy=a("sentence order prediction (classification)"),Ty=a(" head."),ky=c(),vr=n("p"),wy=a("This model inherits from "),qd=n("a"),vy=a("PreTrainedModel"),My=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),$y=c(),Mr=n("p"),Fy=a("This model is also a PyTorch "),$r=n("a"),Ay=a("torch.nn.Module"),Ey=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),jy=c(),Gt=n("div"),k(Fr.$$.fragment),xy=c(),Qo=n("p"),Jy=a("The "),Pd=n("a"),zy=a("AlbertForPreTraining"),Cy=a(" forward method, overrides the "),Ap=n("code"),Uy=a("__call__"),Iy=a(" special method."),Ny=c(),k(es.$$.fragment),Wy=c(),k(ts.$$.fragment),Lu=c(),Ho=n("h2"),os=n("a"),Ep=n("span"),k(Ar.$$.fragment),qy=c(),jp=n("span"),Py=a("AlbertForMaskedLM"),Du=c(),gt=n("div"),k(Er.$$.fragment),Zy=c(),jr=n("p"),By=a("Albert Model with a "),xp=n("code"),Gy=a("language modeling"),Ry=a(" head on top."),Vy=c(),xr=n("p"),Xy=a("This model inherits from "),Zd=n("a"),Sy=a("PreTrainedModel"),Ly=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Dy=c(),Jr=n("p"),Oy=a("This model is also a PyTorch "),zr=n("a"),Qy=a("torch.nn.Module"),Hy=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Yy=c(),wt=n("div"),k(Cr.$$.fragment),Ky=c(),Yo=n("p"),eT=a("The "),Bd=n("a"),tT=a("AlbertForMaskedLM"),oT=a(" forward method, overrides the "),Jp=n("code"),nT=a("__call__"),sT=a(" special method."),aT=c(),k(ns.$$.fragment),rT=c(),k(ss.$$.fragment),lT=c(),k(as.$$.fragment),Ou=c(),Ko=n("h2"),rs=n("a"),zp=n("span"),k(Ur.$$.fragment),iT=c(),Cp=n("span"),dT=a("AlbertForSequenceClassification"),Qu=c(),_t=n("div"),k(Ir.$$.fragment),cT=c(),Up=n("p"),pT=a(`Albert Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),hT=c(),Nr=n("p"),mT=a("This model inherits from "),Gd=n("a"),uT=a("PreTrainedModel"),fT=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),gT=c(),Wr=n("p"),_T=a("This model is also a PyTorch "),qr=n("a"),bT=a("torch.nn.Module"),yT=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),TT=c(),vt=n("div"),k(Pr.$$.fragment),kT=c(),en=n("p"),wT=a("The "),Rd=n("a"),vT=a("AlbertForSequenceClassification"),MT=a(" forward method, overrides the "),Ip=n("code"),$T=a("__call__"),FT=a(" special method."),AT=c(),k(ls.$$.fragment),ET=c(),k(is.$$.fragment),jT=c(),k(ds.$$.fragment),Hu=c(),tn=n("h2"),cs=n("a"),Np=n("span"),k(Zr.$$.fragment),xT=c(),Wp=n("span"),JT=a("AlbertForMultipleChoice"),Yu=c(),bt=n("div"),k(Br.$$.fragment),zT=c(),qp=n("p"),CT=a(`Albert 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.`),UT=c(),Gr=n("p"),IT=a("This model inherits from "),Vd=n("a"),NT=a("PreTrainedModel"),WT=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),qT=c(),Rr=n("p"),PT=a("This model is also a PyTorch "),Vr=n("a"),ZT=a("torch.nn.Module"),BT=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),GT=c(),Rt=n("div"),k(Xr.$$.fragment),RT=c(),on=n("p"),VT=a("The "),Xd=n("a"),XT=a("AlbertForMultipleChoice"),ST=a(" forward method, overrides the "),Pp=n("code"),LT=a("__call__"),DT=a(" special method."),OT=c(),k(ps.$$.fragment),QT=c(),k(hs.$$.fragment),Ku=c(),nn=n("h2"),ms=n("a"),Zp=n("span"),k(Sr.$$.fragment),HT=c(),Bp=n("span"),YT=a("AlbertForTokenClassification"),ef=c(),yt=n("div"),k(Lr.$$.fragment),KT=c(),Gp=n("p"),ek=a(`Albert 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.`),tk=c(),Dr=n("p"),ok=a("This model inherits from "),Sd=n("a"),nk=a("PreTrainedModel"),sk=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ak=c(),Or=n("p"),rk=a("This model is also a PyTorch "),Qr=n("a"),lk=a("torch.nn.Module"),ik=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),dk=c(),Vt=n("div"),k(Hr.$$.fragment),ck=c(),sn=n("p"),pk=a("The "),Ld=n("a"),hk=a("AlbertForTokenClassification"),mk=a(" forward method, overrides the "),Rp=n("code"),uk=a("__call__"),fk=a(" special method."),gk=c(),k(us.$$.fragment),_k=c(),k(fs.$$.fragment),tf=c(),an=n("h2"),gs=n("a"),Vp=n("span"),k(Yr.$$.fragment),bk=c(),Xp=n("span"),yk=a("AlbertForQuestionAnswering"),of=c(),Tt=n("div"),k(Kr.$$.fragment),Tk=c(),rn=n("p"),kk=a(`Albert 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 `),Sp=n("code"),wk=a("span start logits"),vk=a(" and "),Lp=n("code"),Mk=a("span end logits"),$k=a(")."),Fk=c(),el=n("p"),Ak=a("This model inherits from "),Dd=n("a"),Ek=a("PreTrainedModel"),jk=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),xk=c(),tl=n("p"),Jk=a("This model is also a PyTorch "),ol=n("a"),zk=a("torch.nn.Module"),Ck=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Uk=c(),Xt=n("div"),k(nl.$$.fragment),Ik=c(),ln=n("p"),Nk=a("The "),Od=n("a"),Wk=a("AlbertForQuestionAnswering"),qk=a(" forward method, overrides the "),Dp=n("code"),Pk=a("__call__"),Zk=a(" special method."),Bk=c(),k(_s.$$.fragment),Gk=c(),k(bs.$$.fragment),nf=c(),dn=n("h2"),ys=n("a"),Op=n("span"),k(sl.$$.fragment),Rk=c(),Qp=n("span"),Vk=a("TFAlbertModel"),sf=c(),lt=n("div"),k(al.$$.fragment),Xk=c(),Hp=n("p"),Sk=a("The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),Lk=c(),rl=n("p"),Dk=a("This model inherits from "),Qd=n("a"),Ok=a("TFPreTrainedModel"),Qk=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Hk=c(),ll=n("p"),Yk=a("This model is also a "),il=n("a"),Kk=a("tf.keras.Model"),ew=a(` 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.`),tw=c(),k(Ts.$$.fragment),ow=c(),St=n("div"),k(dl.$$.fragment),nw=c(),cn=n("p"),sw=a("The "),Hd=n("a"),aw=a("TFAlbertModel"),rw=a(" forward method, overrides the "),Yp=n("code"),lw=a("__call__"),iw=a(" special method."),dw=c(),k(ks.$$.fragment),cw=c(),k(ws.$$.fragment),af=c(),pn=n("h2"),vs=n("a"),Kp=n("span"),k(cl.$$.fragment),pw=c(),eh=n("span"),hw=a("TFAlbertForPreTraining"),rf=c(),it=n("div"),k(pl.$$.fragment),mw=c(),hn=n("p"),uw=a("Albert Model with two heads on top for pretraining: a "),th=n("code"),fw=a("masked language modeling"),gw=a(" head and a "),oh=n("code"),_w=a("sentence order prediction"),bw=a(" (classification) head."),yw=c(),hl=n("p"),Tw=a("This model inherits from "),Yd=n("a"),kw=a("TFPreTrainedModel"),ww=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),vw=c(),ml=n("p"),Mw=a("This model is also a "),ul=n("a"),$w=a("tf.keras.Model"),Fw=a(` 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.`),Aw=c(),k(Ms.$$.fragment),Ew=c(),Lt=n("div"),k(fl.$$.fragment),jw=c(),mn=n("p"),xw=a("The "),Kd=n("a"),Jw=a("TFAlbertForPreTraining"),zw=a(" forward method, overrides the "),nh=n("code"),Cw=a("__call__"),Uw=a(" special method."),Iw=c(),k($s.$$.fragment),Nw=c(),k(Fs.$$.fragment),lf=c(),un=n("h2"),As=n("a"),sh=n("span"),k(gl.$$.fragment),Ww=c(),ah=n("span"),qw=a("TFAlbertForMaskedLM"),df=c(),dt=n("div"),k(_l.$$.fragment),Pw=c(),bl=n("p"),Zw=a("Albert Model with a "),rh=n("code"),Bw=a("language modeling"),Gw=a(" head on top."),Rw=c(),yl=n("p"),Vw=a("This model inherits from "),ec=n("a"),Xw=a("TFPreTrainedModel"),Sw=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Lw=c(),Tl=n("p"),Dw=a("This model is also a "),kl=n("a"),Ow=a("tf.keras.Model"),Qw=a(` 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.`),Hw=c(),k(Es.$$.fragment),Yw=c(),Mt=n("div"),k(wl.$$.fragment),Kw=c(),fn=n("p"),ev=a("The "),tc=n("a"),tv=a("TFAlbertForMaskedLM"),ov=a(" forward method, overrides the "),lh=n("code"),nv=a("__call__"),sv=a(" special method."),av=c(),k(js.$$.fragment),rv=c(),k(xs.$$.fragment),lv=c(),k(Js.$$.fragment),cf=c(),gn=n("h2"),zs=n("a"),ih=n("span"),k(vl.$$.fragment),iv=c(),dh=n("span"),dv=a("TFAlbertForSequenceClassification"),pf=c(),ct=n("div"),k(Ml.$$.fragment),cv=c(),ch=n("p"),pv=a(`Albert Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),hv=c(),$l=n("p"),mv=a("This model inherits from "),oc=n("a"),uv=a("TFPreTrainedModel"),fv=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),gv=c(),Fl=n("p"),_v=a("This model is also a "),Al=n("a"),bv=a("tf.keras.Model"),yv=a(` 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.`),Tv=c(),k(Cs.$$.fragment),kv=c(),$t=n("div"),k(El.$$.fragment),wv=c(),_n=n("p"),vv=a("The "),nc=n("a"),Mv=a("TFAlbertForSequenceClassification"),$v=a(" forward method, overrides the "),ph=n("code"),Fv=a("__call__"),Av=a(" special method."),Ev=c(),k(Us.$$.fragment),jv=c(),k(Is.$$.fragment),xv=c(),k(Ns.$$.fragment),hf=c(),bn=n("h2"),Ws=n("a"),hh=n("span"),k(jl.$$.fragment),Jv=c(),mh=n("span"),zv=a("TFAlbertForMultipleChoice"),mf=c(),pt=n("div"),k(xl.$$.fragment),Cv=c(),uh=n("p"),Uv=a(`Albert 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.`),Iv=c(),Jl=n("p"),Nv=a("This model inherits from "),sc=n("a"),Wv=a("TFPreTrainedModel"),qv=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Pv=c(),zl=n("p"),Zv=a("This model is also a "),Cl=n("a"),Bv=a("tf.keras.Model"),Gv=a(` 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.`),Rv=c(),k(qs.$$.fragment),Vv=c(),Dt=n("div"),k(Ul.$$.fragment),Xv=c(),yn=n("p"),Sv=a("The "),ac=n("a"),Lv=a("TFAlbertForMultipleChoice"),Dv=a(" forward method, overrides the "),fh=n("code"),Ov=a("__call__"),Qv=a(" special method."),Hv=c(),k(Ps.$$.fragment),Yv=c(),k(Zs.$$.fragment),uf=c(),Tn=n("h2"),Bs=n("a"),gh=n("span"),k(Il.$$.fragment),Kv=c(),_h=n("span"),eM=a("TFAlbertForTokenClassification"),ff=c(),ht=n("div"),k(Nl.$$.fragment),tM=c(),bh=n("p"),oM=a(`Albert 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.`),nM=c(),Wl=n("p"),sM=a("This model inherits from "),rc=n("a"),aM=a("TFPreTrainedModel"),rM=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),lM=c(),ql=n("p"),iM=a("This model is also a "),Pl=n("a"),dM=a("tf.keras.Model"),cM=a(` 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.`),pM=c(),k(Gs.$$.fragment),hM=c(),Ft=n("div"),k(Zl.$$.fragment),mM=c(),kn=n("p"),uM=a("The "),lc=n("a"),fM=a("TFAlbertForTokenClassification"),gM=a(" forward method, overrides the "),yh=n("code"),_M=a("__call__"),bM=a(" special method."),yM=c(),k(Rs.$$.fragment),TM=c(),k(Vs.$$.fragment),kM=c(),k(Xs.$$.fragment),gf=c(),wn=n("h2"),Ss=n("a"),Th=n("span"),k(Bl.$$.fragment),wM=c(),kh=n("span"),vM=a("TFAlbertForQuestionAnswering"),_f=c(),mt=n("div"),k(Gl.$$.fragment),MM=c(),vn=n("p"),$M=a(`Albert 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 `),wh=n("code"),FM=a("span start logits"),AM=a(" and "),vh=n("code"),EM=a("span end logits"),jM=a(")."),xM=c(),Rl=n("p"),JM=a("This model inherits from "),ic=n("a"),zM=a("TFPreTrainedModel"),CM=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),UM=c(),Vl=n("p"),IM=a("This model is also a "),Xl=n("a"),NM=a("tf.keras.Model"),WM=a(` 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.`),qM=c(),k(Ls.$$.fragment),PM=c(),At=n("div"),k(Sl.$$.fragment),ZM=c(),Mn=n("p"),BM=a("The "),dc=n("a"),GM=a("TFAlbertForQuestionAnswering"),RM=a(" forward method, overrides the "),Mh=n("code"),VM=a("__call__"),XM=a(" special method."),SM=c(),k(Ds.$$.fragment),LM=c(),k(Os.$$.fragment),DM=c(),k(Qs.$$.fragment),bf=c(),$n=n("h2"),Hs=n("a"),$h=n("span"),k(Ll.$$.fragment),OM=c(),Fh=n("span"),QM=a("FlaxAlbertModel"),yf=c(),et=n("div"),k(Dl.$$.fragment),HM=c(),Ah=n("p"),YM=a("The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),KM=c(),Ol=n("p"),e2=a("This model inherits from "),cc=n("a"),t2=a("FlaxPreTrainedModel"),o2=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)`),n2=c(),Ql=n("p"),s2=a("This model is also a Flax Linen "),Hl=n("a"),a2=a("flax.linen.Module"),r2=a(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),l2=c(),Eh=n("p"),i2=a("Finally, this model supports inherent JAX features such as:"),d2=c(),ho=n("ul"),jh=n("li"),Yl=n("a"),c2=a("Just-In-Time (JIT) compilation"),p2=c(),xh=n("li"),Kl=n("a"),h2=a("Automatic Differentiation"),m2=c(),Jh=n("li"),ei=n("a"),u2=a("Vectorization"),f2=c(),zh=n("li"),ti=n("a"),g2=a("Parallelization"),_2=c(),Ot=n("div"),k(oi.$$.fragment),b2=c(),Fn=n("p"),y2=a("The "),Ch=n("code"),T2=a("FlaxAlbertPreTrainedModel"),k2=a(" forward method, overrides the "),Uh=n("code"),w2=a("__call__"),v2=a(" special method."),M2=c(),k(Ys.$$.fragment),$2=c(),k(Ks.$$.fragment),Tf=c(),An=n("h2"),ea=n("a"),Ih=n("span"),k(ni.$$.fragment),F2=c(),Nh=n("span"),A2=a("FlaxAlbertForPreTraining"),kf=c(),tt=n("div"),k(si.$$.fragment),E2=c(),En=n("p"),j2=a("Albert Model with two heads on top as done during the pretraining: a "),Wh=n("code"),x2=a("masked language modeling"),J2=a(` head and a
`),qh=n("code"),z2=a("sentence order prediction (classification)"),C2=a(" head."),U2=c(),ai=n("p"),I2=a("This model inherits from "),pc=n("a"),N2=a("FlaxPreTrainedModel"),W2=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)`),q2=c(),ri=n("p"),P2=a("This model is also a Flax Linen "),li=n("a"),Z2=a("flax.linen.Module"),B2=a(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),G2=c(),Ph=n("p"),R2=a("Finally, this model supports inherent JAX features such as:"),V2=c(),mo=n("ul"),Zh=n("li"),ii=n("a"),X2=a("Just-In-Time (JIT) compilation"),S2=c(),Bh=n("li"),di=n("a"),L2=a("Automatic Differentiation"),D2=c(),Gh=n("li"),ci=n("a"),O2=a("Vectorization"),Q2=c(),Rh=n("li"),pi=n("a"),H2=a("Parallelization"),Y2=c(),Qt=n("div"),k(hi.$$.fragment),K2=c(),jn=n("p"),e1=a("The "),Vh=n("code"),t1=a("FlaxAlbertPreTrainedModel"),o1=a(" forward method, overrides the "),Xh=n("code"),n1=a("__call__"),s1=a(" special method."),a1=c(),k(ta.$$.fragment),r1=c(),k(oa.$$.fragment),wf=c(),xn=n("h2"),na=n("a"),Sh=n("span"),k(mi.$$.fragment),l1=c(),Lh=n("span"),i1=a("FlaxAlbertForMaskedLM"),vf=c(),ot=n("div"),k(ui.$$.fragment),d1=c(),fi=n("p"),c1=a("Albert Model with a "),Dh=n("code"),p1=a("language modeling"),h1=a(" head on top."),m1=c(),gi=n("p"),u1=a("This model inherits from "),hc=n("a"),f1=a("FlaxPreTrainedModel"),g1=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)`),_1=c(),_i=n("p"),b1=a("This model is also a Flax Linen "),bi=n("a"),y1=a("flax.linen.Module"),T1=a(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),k1=c(),Oh=n("p"),w1=a("Finally, this model supports inherent JAX features such as:"),v1=c(),uo=n("ul"),Qh=n("li"),yi=n("a"),M1=a("Just-In-Time (JIT) compilation"),$1=c(),Hh=n("li"),Ti=n("a"),F1=a("Automatic Differentiation"),A1=c(),Yh=n("li"),ki=n("a"),E1=a("Vectorization"),j1=c(),Kh=n("li"),wi=n("a"),x1=a("Parallelization"),J1=c(),Ht=n("div"),k(vi.$$.fragment),z1=c(),Jn=n("p"),C1=a("The "),em=n("code"),U1=a("FlaxAlbertPreTrainedModel"),I1=a(" forward method, overrides the "),tm=n("code"),N1=a("__call__"),W1=a(" special method."),q1=c(),k(sa.$$.fragment),P1=c(),k(aa.$$.fragment),Mf=c(),zn=n("h2"),ra=n("a"),om=n("span"),k(Mi.$$.fragment),Z1=c(),nm=n("span"),B1=a("FlaxAlbertForSequenceClassification"),$f=c(),nt=n("div"),k($i.$$.fragment),G1=c(),sm=n("p"),R1=a(`Albert Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),V1=c(),Fi=n("p"),X1=a("This model inherits from "),mc=n("a"),S1=a("FlaxPreTrainedModel"),L1=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)`),D1=c(),Ai=n("p"),O1=a("This model is also a Flax Linen "),Ei=n("a"),Q1=a("flax.linen.Module"),H1=a(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Y1=c(),am=n("p"),K1=a("Finally, this model supports inherent JAX features such as:"),e$=c(),fo=n("ul"),rm=n("li"),ji=n("a"),t$=a("Just-In-Time (JIT) compilation"),o$=c(),lm=n("li"),xi=n("a"),n$=a("Automatic Differentiation"),s$=c(),im=n("li"),Ji=n("a"),a$=a("Vectorization"),r$=c(),dm=n("li"),zi=n("a"),l$=a("Parallelization"),i$=c(),Yt=n("div"),k(Ci.$$.fragment),d$=c(),Cn=n("p"),c$=a("The "),cm=n("code"),p$=a("FlaxAlbertPreTrainedModel"),h$=a(" forward method, overrides the "),pm=n("code"),m$=a("__call__"),u$=a(" special method."),f$=c(),k(la.$$.fragment),g$=c(),k(ia.$$.fragment),Ff=c(),Un=n("h2"),da=n("a"),hm=n("span"),k(Ui.$$.fragment),_$=c(),mm=n("span"),b$=a("FlaxAlbertForMultipleChoice"),Af=c(),st=n("div"),k(Ii.$$.fragment),y$=c(),um=n("p"),T$=a(`Albert 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.`),k$=c(),Ni=n("p"),w$=a("This model inherits from "),uc=n("a"),v$=a("FlaxPreTrainedModel"),M$=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)`),$$=c(),Wi=n("p"),F$=a("This model is also a Flax Linen "),qi=n("a"),A$=a("flax.linen.Module"),E$=a(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),j$=c(),fm=n("p"),x$=a("Finally, this model supports inherent JAX features such as:"),J$=c(),go=n("ul"),gm=n("li"),Pi=n("a"),z$=a("Just-In-Time (JIT) compilation"),C$=c(),_m=n("li"),Zi=n("a"),U$=a("Automatic Differentiation"),I$=c(),bm=n("li"),Bi=n("a"),N$=a("Vectorization"),W$=c(),ym=n("li"),Gi=n("a"),q$=a("Parallelization"),P$=c(),Kt=n("div"),k(Ri.$$.fragment),Z$=c(),In=n("p"),B$=a("The "),Tm=n("code"),G$=a("FlaxAlbertPreTrainedModel"),R$=a(" forward method, overrides the "),km=n("code"),V$=a("__call__"),X$=a(" special method."),S$=c(),k(ca.$$.fragment),L$=c(),k(pa.$$.fragment),Ef=c(),Nn=n("h2"),ha=n("a"),wm=n("span"),k(Vi.$$.fragment),D$=c(),vm=n("span"),O$=a("FlaxAlbertForTokenClassification"),jf=c(),at=n("div"),k(Xi.$$.fragment),Q$=c(),Mm=n("p"),H$=a(`Albert 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.`),Y$=c(),Si=n("p"),K$=a("This model inherits from "),fc=n("a"),e0=a("FlaxPreTrainedModel"),t0=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)`),o0=c(),Li=n("p"),n0=a("This model is also a Flax Linen "),Di=n("a"),s0=a("flax.linen.Module"),a0=a(`
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=c(),$m=n("p"),l0=a("Finally, this model supports inherent JAX features such as:"),i0=c(),_o=n("ul"),Fm=n("li"),Oi=n("a"),d0=a("Just-In-Time (JIT) compilation"),c0=c(),Am=n("li"),Qi=n("a"),p0=a("Automatic Differentiation"),h0=c(),Em=n("li"),Hi=n("a"),m0=a("Vectorization"),u0=c(),jm=n("li"),Yi=n("a"),f0=a("Parallelization"),g0=c(),eo=n("div"),k(Ki.$$.fragment),_0=c(),Wn=n("p"),b0=a("The "),xm=n("code"),y0=a("FlaxAlbertPreTrainedModel"),T0=a(" forward method, overrides the "),Jm=n("code"),k0=a("__call__"),w0=a(" special method."),v0=c(),k(ma.$$.fragment),M0=c(),k(ua.$$.fragment),xf=c(),qn=n("h2"),fa=n("a"),zm=n("span"),k(ed.$$.fragment),$0=c(),Cm=n("span"),F0=a("FlaxAlbertForQuestionAnswering"),Jf=c(),rt=n("div"),k(td.$$.fragment),A0=c(),Pn=n("p"),E0=a(`Albert 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 `),Um=n("code"),j0=a("span start logits"),x0=a(" and "),Im=n("code"),J0=a("span end logits"),z0=a(")."),C0=c(),od=n("p"),U0=a("This model inherits from "),gc=n("a"),I0=a("FlaxPreTrainedModel"),N0=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)`),W0=c(),nd=n("p"),q0=a("This model is also a Flax Linen "),sd=n("a"),P0=a("flax.linen.Module"),Z0=a(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),B0=c(),Nm=n("p"),G0=a("Finally, this model supports inherent JAX features such as:"),R0=c(),bo=n("ul"),Wm=n("li"),ad=n("a"),V0=a("Just-In-Time (JIT) compilation"),X0=c(),qm=n("li"),rd=n("a"),S0=a("Automatic Differentiation"),L0=c(),Pm=n("li"),ld=n("a"),D0=a("Vectorization"),O0=c(),Zm=n("li"),id=n("a"),Q0=a("Parallelization"),H0=c(),to=n("div"),k(dd.$$.fragment),Y0=c(),Zn=n("p"),K0=a("The "),Bm=n("code"),eF=a("FlaxAlbertPreTrainedModel"),tF=a(" forward method, overrides the "),Gm=n("code"),oF=a("__call__"),nF=a(" special method."),sF=c(),k(ga.$$.fragment),aF=c(),k(_a.$$.fragment),this.h()},l(o){const _=dJ('[data-svelte="svelte-1phssyn"]',document.head);d=s(_,"META",{name:!0,content:!0}),_.forEach(t),y=p(o),m=s(o,"H1",{class:!0});var cd=l(m);f=s(cd,"A",{id:!0,class:!0,href:!0});var Rm=l(f);b=s(Rm,"SPAN",{});var Vm=l(b);w(i.$$.fragment,Vm),Vm.forEach(t),Rm.forEach(t),h=p(cd),j=s(cd,"SPAN",{});var Xm=l(j);Me=r(Xm,"ALBERT"),Xm.forEach(t),cd.forEach(t),ye=p(o),B=s(o,"DIV",{class:!0});var pd=l(B);de=s(pd,"A",{href:!0});var Sm=l(de);K=s(Sm,"IMG",{alt:!0,src:!0}),Sm.forEach(t),$e=p(pd),V=s(pd,"A",{href:!0});var Lm=l(V);ce=s(Lm,"IMG",{alt:!0,src:!0}),Lm.forEach(t),pd.forEach(t),O=p(o),se=s(o,"H2",{class:!0});var hd=l(se);ae=s(hd,"A",{id:!0,class:!0,href:!0});var Dm=l(ae);X=s(Dm,"SPAN",{});var Om=l(X);w(le.$$.fragment,Om),Om.forEach(t),Dm.forEach(t),Fe=p(hd),S=s(hd,"SPAN",{});var Qm=l(S);Ae=r(Qm,"Overview"),Qm.forEach(t),hd.forEach(t),Te=p(o),G=s(o,"P",{});var md=l(G);Ee=r(md,"The ALBERT model was proposed in "),ie=s(md,"A",{href:!0,rel:!0});var Hm=l(ie);ee=r(Hm,"ALBERT: A Lite BERT for Self-supervised Learning of Language Representations"),Hm.forEach(t),z=r(md,` by Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma,
Radu Soricut. It presents two parameter-reduction techniques to lower memory consumption and increase the training
speed of BERT:`),md.forEach(t),U=p(o),re=s(o,"UL",{});var ud=l(re);L=s(ud,"LI",{});var Ym=l(L);je=r(Ym,"Splitting the embedding matrix into two smaller matrices."),Ym.forEach(t),xe=p(ud),D=s(ud,"LI",{});var Km=l(D);Je=r(Km,"Using repeating layers split among groups."),Km.forEach(t),ud.forEach(t),ke=p(o),C=s(o,"P",{});var eu=l(C);ze=r(eu,"The abstract from the paper is the following:"),eu.forEach(t),Q=p(o),pe=s(o,"P",{});var tu=l(pe);me=s(tu,"EM",{});var ou=l(me);Y=r(ou,`Increasing model size when pretraining natural language representations often results in improved performance on
downstream tasks. However, at some point further model increases become harder due to GPU/TPU memory limitations,
longer training times, and unexpected model degradation. To address these problems, we present two parameter-reduction
techniques to lower memory consumption and increase the training speed of BERT. Comprehensive empirical evidence shows
that our proposed methods lead to models that scale much better compared to the original BERT. We also use a
self-supervised loss that focuses on modeling inter-sentence coherence, and show it consistently helps downstream tasks
with multi-sentence inputs. As a result, our best model establishes new state-of-the-art results on the GLUE, RACE, and
SQuAD benchmarks while having fewer parameters compared to BERT-large.`),ou.forEach(t),tu.forEach(t),we=p(o),he=s(o,"P",{});var nu=l(he);P=r(nu,"Tips:"),nu.forEach(t),ve=p(o),W=s(o,"UL",{});var yo=l(W);ue=s(yo,"LI",{});var su=l(ue);te=r(su,`ALBERT is a model with absolute position embeddings so it\u2019s usually advised to pad the inputs on the right rather
than the left.`),su.forEach(t),I=p(yo),fe=s(yo,"LI",{});var au=l(fe);N=r(au,`ALBERT uses repeating layers which results in a small memory footprint, however the computational cost remains
similar to a BERT-like architecture with the same number of hidden layers as it has to iterate through the same
number of (repeating) layers.`),au.forEach(t),Ce=p(yo),ge=s(yo,"LI",{});var ru=l(ge);T=r(ru,"Embedding size E is different from hidden size H justified because the embeddings are context independent (one embedding vector represents one token), whereas hidden states are context dependent (one hidden state represents a sequence of tokens) so it\u2019s more logical to have H >> E. Also, the embedding matrix is large since it\u2019s V x E (V being the vocab size). If E < H, it has less parameters."),ru.forEach(t),x=p(yo),Xe=s(yo,"LI",{});var lu=l(Xe);oe=r(lu,`Layers are split in groups that share parameters (to save memory).
Next sentence prediction is replaced by a sentence ordering prediction: in the inputs, we have two sentences A and B (that are consecutive) and we either feed A followed by B or B followed by A. The model must predict if they have been swapped or not.`),lu.forEach(t),yo.forEach(t),Le=p(o),_e=s(o,"P",{});var To=l(_e);J=r(To,"This model was contributed by "),Ze=s(To,"A",{href:!0,rel:!0});var iu=l(Ze);De=r(iu,"lysandre"),iu.forEach(t),Oe=r(To,`. This model jax version was contributed by
`),Be=s(To,"A",{href:!0,rel:!0});var du=l(Be);Qe=r(du,"kamalkraj"),du.forEach(t),Z=r(To,". The original code can be found "),R=s(To,"A",{href:!0,rel:!0});var cu=l(R);He=r(cu,"here"),cu.forEach(t),Ye=r(To,"."),To.forEach(t),H=p(o),Ie=s(o,"H2",{class:!0});var fd=l(Ie);Pe=s(fd,"A",{id:!0,class:!0,href:!0});var pu=l(Pe);be=s(pu,"SPAN",{});var hu=l(be);w(Ge.$$.fragment,hu),hu.forEach(t),pu.forEach(t),ne=p(fd),Se=s(fd,"SPAN",{});var mu=l(Se);n_=r(mu,"Documentation resources"),mu.forEach(t),fd.forEach(t),Cu=p(o),kt=s(o,"UL",{});var qt=l(kt);Lc=s(qt,"LI",{});var uu=l(Lc);bd=s(uu,"A",{href:!0});var fu=l(bd);s_=r(fu,"Text classification task guide"),fu.forEach(t),uu.forEach(t),a_=p(qt),Dc=s(qt,"LI",{});var gu=l(Dc);yd=s(gu,"A",{href:!0});var _u=l(yd);r_=r(_u,"Token classification task guide"),_u.forEach(t),gu.forEach(t),l_=p(qt),Oc=s(qt,"LI",{});var bu=l(Oc);Td=s(bu,"A",{href:!0});var yu=l(Td);i_=r(yu,"Question answering task guide"),yu.forEach(t),bu.forEach(t),d_=p(qt),Qc=s(qt,"LI",{});var Tu=l(Qc);kd=s(Tu,"A",{href:!0});var ku=l(kd);c_=r(ku,"Masked language modeling task guide"),ku.forEach(t),Tu.forEach(t),p_=p(qt),Hc=s(qt,"LI",{});var wu=l(Hc);wd=s(wu,"A",{href:!0});var vu=l(wd);h_=r(vu,"Multiple choice task guide"),vu.forEach(t),wu.forEach(t),qt.forEach(t),Uu=p(o),qo=s(o,"H2",{class:!0});var gd=l(qo);Gn=s(gd,"A",{id:!0,class:!0,href:!0});var Mu=l(Gn);Yc=s(Mu,"SPAN",{});var $u=l(Yc);w(Va.$$.fragment,$u),$u.forEach(t),Mu.forEach(t),m_=p(gd),Kc=s(gd,"SPAN",{});var Fu=l(Kc);u_=r(Fu,"AlbertConfig"),Fu.forEach(t),gd.forEach(t),Iu=p(o),Nt=s(o,"DIV",{class:!0});var ko=l(Nt);w(Xa.$$.fragment,ko),f_=p(ko),co=s(ko,"P",{});var wo=l(co);g_=r(wo,"This is the configuration class to store the configuration of a "),vd=s(wo,"A",{href:!0});var Au=l(vd);__=r(Au,"AlbertModel"),Au.forEach(t),b_=r(wo," or a "),Md=s(wo,"A",{href:!0});var Eu=l(Md);y_=r(Eu,"TFAlbertModel"),Eu.forEach(t),T_=r(wo,`. It is used
to instantiate an ALBERT 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 ALBERT
`),Sa=s(wo,"A",{href:!0,rel:!0});var ju=l(Sa);k_=r(ju,"albert-xxlarge-v2"),ju.forEach(t),w_=r(wo," architecture."),wo.forEach(t),v_=p(ko),Po=s(ko,"P",{});var Bn=l(Po);M_=r(Bn,"Configuration objects inherit from "),$d=s(Bn,"A",{href:!0});var xu=l($d);$_=r(xu,"PretrainedConfig"),xu.forEach(t),F_=r(Bn,` and can be used to control the model outputs. Read the
documentation from `),Fd=s(Bn,"A",{href:!0});var Ju=l(Fd);A_=r(Ju,"PretrainedConfig"),Ju.forEach(t),E_=r(Bn," for more information."),Bn.forEach(t),j_=p(ko),w(Rn.$$.fragment,ko),ko.forEach(t),Nu=p(o),Zo=s(o,"H2",{class:!0});var _d=l(Zo);Vn=s(_d,"A",{id:!0,class:!0,href:!0});var zu=l(Vn);ep=s(zu,"SPAN",{});var cF=l(ep);w(La.$$.fragment,cF),cF.forEach(t),zu.forEach(t),x_=p(_d),tp=s(_d,"SPAN",{});var pF=l(tp);J_=r(pF,"AlbertTokenizer"),pF.forEach(t),_d.forEach(t),Wu=p(o),Ke=s(o,"DIV",{class:!0});var Et=l(Ke);w(Da.$$.fragment,Et),z_=p(Et),Oa=s(Et,"P",{});var Cf=l(Oa);C_=r(Cf,"Construct an ALBERT tokenizer. Based on "),Qa=s(Cf,"A",{href:!0,rel:!0});var hF=l(Qa);U_=r(hF,"SentencePiece"),hF.forEach(t),I_=r(Cf,"."),Cf.forEach(t),N_=p(Et),Ha=s(Et,"P",{});var Uf=l(Ha);W_=r(Uf,"This tokenizer inherits from "),Ad=s(Uf,"A",{href:!0});var mF=l(Ad);q_=r(mF,"PreTrainedTokenizer"),mF.forEach(t),P_=r(Uf,` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Uf.forEach(t),Z_=p(Et),vo=s(Et,"DIV",{class:!0});var _c=l(vo);w(Ya.$$.fragment,_c),B_=p(_c),op=s(_c,"P",{});var uF=l(op);G_=r(uF,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An ALBERT sequence has the following format:`),uF.forEach(t),R_=p(_c),Ka=s(_c,"UL",{});var If=l(Ka);Ed=s(If,"LI",{});var rF=l(Ed);V_=r(rF,"single sequence: "),np=s(rF,"CODE",{});var fF=l(np);X_=r(fF,"[CLS] X [SEP]"),fF.forEach(t),rF.forEach(t),S_=p(If),jd=s(If,"LI",{});var lF=l(jd);L_=r(lF,"pair of sequences: "),sp=s(lF,"CODE",{});var gF=l(sp);D_=r(gF,"[CLS] A [SEP] B [SEP]"),gF.forEach(t),lF.forEach(t),If.forEach(t),_c.forEach(t),O_=p(Et),Xn=s(Et,"DIV",{class:!0});var Nf=l(Xn);w(er.$$.fragment,Nf),Q_=p(Nf),tr=s(Nf,"P",{});var Wf=l(tr);H_=r(Wf,`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),ap=s(Wf,"CODE",{});var _F=l(ap);Y_=r(_F,"prepare_for_model"),_F.forEach(t),K_=r(Wf," method."),Wf.forEach(t),Nf.forEach(t),eb=p(Et),Pt=s(Et,"DIV",{class:!0});var ba=l(Pt);w(or.$$.fragment,ba),tb=p(ba),rp=s(ba,"P",{});var bF=l(rp);ob=r(bF,"Create a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT"),bF.forEach(t),nb=p(ba),w(Sn.$$.fragment,ba),sb=p(ba),Bo=s(ba,"P",{});var bc=l(Bo);ab=r(bc,"If "),lp=s(bc,"CODE",{});var yF=l(lp);rb=r(yF,"token_ids_1"),yF.forEach(t),lb=r(bc," is "),ip=s(bc,"CODE",{});var TF=l(ip);ib=r(TF,"None"),TF.forEach(t),db=r(bc,", this method only returns the first portion of the mask (0s)."),bc.forEach(t),ba.forEach(t),cb=p(Et),xd=s(Et,"DIV",{class:!0});var kF=l(xd);w(nr.$$.fragment,kF),kF.forEach(t),Et.forEach(t),qu=p(o),Go=s(o,"H2",{class:!0});var qf=l(Go);Ln=s(qf,"A",{id:!0,class:!0,href:!0});var wF=l(Ln);dp=s(wF,"SPAN",{});var vF=l(dp);w(sr.$$.fragment,vF),vF.forEach(t),wF.forEach(t),pb=p(qf),cp=s(qf,"SPAN",{});var MF=l(cp);hb=r(MF,"AlbertTokenizerFast"),MF.forEach(t),qf.forEach(t),Pu=p(o),Wt=s(o,"DIV",{class:!0});var ya=l(Wt);w(ar.$$.fragment,ya),mb=p(ya),po=s(ya,"P",{});var Ta=l(po);ub=r(Ta,"Construct a \u201Cfast\u201D ALBERT tokenizer (backed by HuggingFace\u2019s "),pp=s(Ta,"EM",{});var $F=l(pp);fb=r($F,"tokenizers"),$F.forEach(t),gb=r(Ta,` library). Based on
`),rr=s(Ta,"A",{href:!0,rel:!0});var FF=l(rr);_b=r(FF,"Unigram"),FF.forEach(t),bb=r(Ta,`. This
tokenizer inherits from `),Jd=s(Ta,"A",{href:!0});var AF=l(Jd);yb=r(AF,"PreTrainedTokenizerFast"),AF.forEach(t),Tb=r(Ta,` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods`),Ta.forEach(t),kb=p(ya),Mo=s(ya,"DIV",{class:!0});var yc=l(Mo);w(lr.$$.fragment,yc),wb=p(yc),hp=s(yc,"P",{});var EF=l(hp);vb=r(EF,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An ALBERT sequence has the following format:`),EF.forEach(t),Mb=p(yc),ir=s(yc,"UL",{});var Pf=l(ir);zd=s(Pf,"LI",{});var iF=l(zd);$b=r(iF,"single sequence: "),mp=s(iF,"CODE",{});var jF=l(mp);Fb=r(jF,"[CLS] X [SEP]"),jF.forEach(t),iF.forEach(t),Ab=p(Pf),Cd=s(Pf,"LI",{});var dF=l(Cd);Eb=r(dF,"pair of sequences: "),up=s(dF,"CODE",{});var xF=l(up);jb=r(xF,"[CLS] A [SEP] B [SEP]"),xF.forEach(t),dF.forEach(t),Pf.forEach(t),yc.forEach(t),xb=p(ya),Zt=s(ya,"DIV",{class:!0});var ka=l(Zt);w(dr.$$.fragment,ka),Jb=p(ka),fp=s(ka,"P",{});var JF=l(fp);zb=r(JF,"Creates a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT"),JF.forEach(t),Cb=p(ka),w(Dn.$$.fragment,ka),Ub=p(ka),gp=s(ka,"P",{});var zF=l(gp);Ib=r(zF,"if token_ids_1 is None, only returns the first portion of the mask (0s)."),zF.forEach(t),ka.forEach(t),ya.forEach(t),Zu=p(o),Ro=s(o,"H2",{class:!0});var Zf=l(Ro);On=s(Zf,"A",{id:!0,class:!0,href:!0});var CF=l(On);_p=s(CF,"SPAN",{});var UF=l(_p);w(cr.$$.fragment,UF),UF.forEach(t),CF.forEach(t),Nb=p(Zf),bp=s(Zf,"SPAN",{});var IF=l(bp);Wb=r(IF,"Albert specific outputs"),IF.forEach(t),Zf.forEach(t),Bu=p(o),Vo=s(o,"DIV",{class:!0});var Bf=l(Vo);w(pr.$$.fragment,Bf),qb=p(Bf),hr=s(Bf,"P",{});var Gf=l(hr);Pb=r(Gf,"Output type of "),Ud=s(Gf,"A",{href:!0});var NF=l(Ud);Zb=r(NF,"AlbertForPreTraining"),NF.forEach(t),Bb=r(Gf,"."),Gf.forEach(t),Bf.forEach(t),Gu=p(o),Xo=s(o,"DIV",{class:!0});var Rf=l(Xo);w(mr.$$.fragment,Rf),Gb=p(Rf),ur=s(Rf,"P",{});var Vf=l(ur);Rb=r(Vf,"Output type of "),Id=s(Vf,"A",{href:!0});var WF=l(Id);Vb=r(WF,"TFAlbertForPreTraining"),WF.forEach(t),Xb=r(Vf,"."),Vf.forEach(t),Rf.forEach(t),Ru=p(o),So=s(o,"H2",{class:!0});var Xf=l(So);Qn=s(Xf,"A",{id:!0,class:!0,href:!0});var qF=l(Qn);yp=s(qF,"SPAN",{});var PF=l(yp);w(fr.$$.fragment,PF),PF.forEach(t),qF.forEach(t),Sb=p(Xf),Tp=s(Xf,"SPAN",{});var ZF=l(Tp);Lb=r(ZF,"AlbertModel"),ZF.forEach(t),Xf.forEach(t),Vu=p(o),ut=s(o,"DIV",{class:!0});var $o=l(ut);w(gr.$$.fragment,$o),Db=p($o),kp=s($o,"P",{});var BF=l(kp);Ob=r(BF,"The bare ALBERT Model transformer outputting raw hidden-states without any specific head on top."),BF.forEach(t),Qb=p($o),_r=s($o,"P",{});var Sf=l(_r);Hb=r(Sf,"This model inherits from "),Nd=s(Sf,"A",{href:!0});var GF=l(Nd);Yb=r(GF,"PreTrainedModel"),GF.forEach(t),Kb=r(Sf,`. 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.)`),Sf.forEach(t),ey=p($o),br=s($o,"P",{});var Lf=l(br);ty=r(Lf,"This model is also a PyTorch "),yr=s(Lf,"A",{href:!0,rel:!0});var RF=l(yr);oy=r(RF,"torch.nn.Module"),RF.forEach(t),ny=r(Lf,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Lf.forEach(t),sy=p($o),Bt=s($o,"DIV",{class:!0});var wa=l(Bt);w(Tr.$$.fragment,wa),ay=p(wa),Lo=s(wa,"P",{});var Tc=l(Lo);ry=r(Tc,"The "),Wd=s(Tc,"A",{href:!0});var VF=l(Wd);ly=r(VF,"AlbertModel"),VF.forEach(t),iy=r(Tc," forward method, overrides the "),wp=s(Tc,"CODE",{});var XF=l(wp);dy=r(XF,"__call__"),XF.forEach(t),cy=r(Tc," special method."),Tc.forEach(t),py=p(wa),w(Hn.$$.fragment,wa),hy=p(wa),w(Yn.$$.fragment,wa),wa.forEach(t),$o.forEach(t),Xu=p(o),Do=s(o,"H2",{class:!0});var Df=l(Do);Kn=s(Df,"A",{id:!0,class:!0,href:!0});var SF=l(Kn);vp=s(SF,"SPAN",{});var LF=l(vp);w(kr.$$.fragment,LF),LF.forEach(t),SF.forEach(t),my=p(Df),Mp=s(Df,"SPAN",{});var DF=l(Mp);uy=r(DF,"AlbertForPreTraining"),DF.forEach(t),Df.forEach(t),Su=p(o),ft=s(o,"DIV",{class:!0});var Fo=l(ft);w(wr.$$.fragment,Fo),fy=p(Fo),Oo=s(Fo,"P",{});var kc=l(Oo);gy=r(kc,"Albert Model with two heads on top as done during the pretraining: a "),$p=s(kc,"CODE",{});var OF=l($p);_y=r(OF,"masked language modeling"),OF.forEach(t),by=r(kc,` head and a
`),Fp=s(kc,"CODE",{});var QF=l(Fp);yy=r(QF,"sentence order prediction (classification)"),QF.forEach(t),Ty=r(kc," head."),kc.forEach(t),ky=p(Fo),vr=s(Fo,"P",{});var Of=l(vr);wy=r(Of,"This model inherits from "),qd=s(Of,"A",{href:!0});var HF=l(qd);vy=r(HF,"PreTrainedModel"),HF.forEach(t),My=r(Of,`. 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.)`),Of.forEach(t),$y=p(Fo),Mr=s(Fo,"P",{});var Qf=l(Mr);Fy=r(Qf,"This model is also a PyTorch "),$r=s(Qf,"A",{href:!0,rel:!0});var YF=l($r);Ay=r(YF,"torch.nn.Module"),YF.forEach(t),Ey=r(Qf,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Qf.forEach(t),jy=p(Fo),Gt=s(Fo,"DIV",{class:!0});var va=l(Gt);w(Fr.$$.fragment,va),xy=p(va),Qo=s(va,"P",{});var wc=l(Qo);Jy=r(wc,"The "),Pd=s(wc,"A",{href:!0});var KF=l(Pd);zy=r(KF,"AlbertForPreTraining"),KF.forEach(t),Cy=r(wc," forward method, overrides the "),Ap=s(wc,"CODE",{});var eA=l(Ap);Uy=r(eA,"__call__"),eA.forEach(t),Iy=r(wc," special method."),wc.forEach(t),Ny=p(va),w(es.$$.fragment,va),Wy=p(va),w(ts.$$.fragment,va),va.forEach(t),Fo.forEach(t),Lu=p(o),Ho=s(o,"H2",{class:!0});var Hf=l(Ho);os=s(Hf,"A",{id:!0,class:!0,href:!0});var tA=l(os);Ep=s(tA,"SPAN",{});var oA=l(Ep);w(Ar.$$.fragment,oA),oA.forEach(t),tA.forEach(t),qy=p(Hf),jp=s(Hf,"SPAN",{});var nA=l(jp);Py=r(nA,"AlbertForMaskedLM"),nA.forEach(t),Hf.forEach(t),Du=p(o),gt=s(o,"DIV",{class:!0});var Ao=l(gt);w(Er.$$.fragment,Ao),Zy=p(Ao),jr=s(Ao,"P",{});var Yf=l(jr);By=r(Yf,"Albert Model with a "),xp=s(Yf,"CODE",{});var sA=l(xp);Gy=r(sA,"language modeling"),sA.forEach(t),Ry=r(Yf," head on top."),Yf.forEach(t),Vy=p(Ao),xr=s(Ao,"P",{});var Kf=l(xr);Xy=r(Kf,"This model inherits from "),Zd=s(Kf,"A",{href:!0});var aA=l(Zd);Sy=r(aA,"PreTrainedModel"),aA.forEach(t),Ly=r(Kf,`. 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.)`),Kf.forEach(t),Dy=p(Ao),Jr=s(Ao,"P",{});var eg=l(Jr);Oy=r(eg,"This model is also a PyTorch "),zr=s(eg,"A",{href:!0,rel:!0});var rA=l(zr);Qy=r(rA,"torch.nn.Module"),rA.forEach(t),Hy=r(eg,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),eg.forEach(t),Yy=p(Ao),wt=s(Ao,"DIV",{class:!0});var Eo=l(wt);w(Cr.$$.fragment,Eo),Ky=p(Eo),Yo=s(Eo,"P",{});var vc=l(Yo);eT=r(vc,"The "),Bd=s(vc,"A",{href:!0});var lA=l(Bd);tT=r(lA,"AlbertForMaskedLM"),lA.forEach(t),oT=r(vc," forward method, overrides the "),Jp=s(vc,"CODE",{});var iA=l(Jp);nT=r(iA,"__call__"),iA.forEach(t),sT=r(vc," special method."),vc.forEach(t),aT=p(Eo),w(ns.$$.fragment,Eo),rT=p(Eo),w(ss.$$.fragment,Eo),lT=p(Eo),w(as.$$.fragment,Eo),Eo.forEach(t),Ao.forEach(t),Ou=p(o),Ko=s(o,"H2",{class:!0});var tg=l(Ko);rs=s(tg,"A",{id:!0,class:!0,href:!0});var dA=l(rs);zp=s(dA,"SPAN",{});var cA=l(zp);w(Ur.$$.fragment,cA),cA.forEach(t),dA.forEach(t),iT=p(tg),Cp=s(tg,"SPAN",{});var pA=l(Cp);dT=r(pA,"AlbertForSequenceClassification"),pA.forEach(t),tg.forEach(t),Qu=p(o),_t=s(o,"DIV",{class:!0});var jo=l(_t);w(Ir.$$.fragment,jo),cT=p(jo),Up=s(jo,"P",{});var hA=l(Up);pT=r(hA,`Albert Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),hA.forEach(t),hT=p(jo),Nr=s(jo,"P",{});var og=l(Nr);mT=r(og,"This model inherits from "),Gd=s(og,"A",{href:!0});var mA=l(Gd);uT=r(mA,"PreTrainedModel"),mA.forEach(t),fT=r(og,`. 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.)`),og.forEach(t),gT=p(jo),Wr=s(jo,"P",{});var ng=l(Wr);_T=r(ng,"This model is also a PyTorch "),qr=s(ng,"A",{href:!0,rel:!0});var uA=l(qr);bT=r(uA,"torch.nn.Module"),uA.forEach(t),yT=r(ng,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),ng.forEach(t),TT=p(jo),vt=s(jo,"DIV",{class:!0});var xo=l(vt);w(Pr.$$.fragment,xo),kT=p(xo),en=s(xo,"P",{});var Mc=l(en);wT=r(Mc,"The "),Rd=s(Mc,"A",{href:!0});var fA=l(Rd);vT=r(fA,"AlbertForSequenceClassification"),fA.forEach(t),MT=r(Mc," forward method, overrides the "),Ip=s(Mc,"CODE",{});var gA=l(Ip);$T=r(gA,"__call__"),gA.forEach(t),FT=r(Mc," special method."),Mc.forEach(t),AT=p(xo),w(ls.$$.fragment,xo),ET=p(xo),w(is.$$.fragment,xo),jT=p(xo),w(ds.$$.fragment,xo),xo.forEach(t),jo.forEach(t),Hu=p(o),tn=s(o,"H2",{class:!0});var sg=l(tn);cs=s(sg,"A",{id:!0,class:!0,href:!0});var _A=l(cs);Np=s(_A,"SPAN",{});var bA=l(Np);w(Zr.$$.fragment,bA),bA.forEach(t),_A.forEach(t),xT=p(sg),Wp=s(sg,"SPAN",{});var yA=l(Wp);JT=r(yA,"AlbertForMultipleChoice"),yA.forEach(t),sg.forEach(t),Yu=p(o),bt=s(o,"DIV",{class:!0});var Jo=l(bt);w(Br.$$.fragment,Jo),zT=p(Jo),qp=s(Jo,"P",{});var TA=l(qp);CT=r(TA,`Albert 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.`),TA.forEach(t),UT=p(Jo),Gr=s(Jo,"P",{});var ag=l(Gr);IT=r(ag,"This model inherits from "),Vd=s(ag,"A",{href:!0});var kA=l(Vd);NT=r(kA,"PreTrainedModel"),kA.forEach(t),WT=r(ag,`. 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.)`),ag.forEach(t),qT=p(Jo),Rr=s(Jo,"P",{});var rg=l(Rr);PT=r(rg,"This model is also a PyTorch "),Vr=s(rg,"A",{href:!0,rel:!0});var wA=l(Vr);ZT=r(wA,"torch.nn.Module"),wA.forEach(t),BT=r(rg,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),rg.forEach(t),GT=p(Jo),Rt=s(Jo,"DIV",{class:!0});var Ma=l(Rt);w(Xr.$$.fragment,Ma),RT=p(Ma),on=s(Ma,"P",{});var $c=l(on);VT=r($c,"The "),Xd=s($c,"A",{href:!0});var vA=l(Xd);XT=r(vA,"AlbertForMultipleChoice"),vA.forEach(t),ST=r($c," forward method, overrides the "),Pp=s($c,"CODE",{});var MA=l(Pp);LT=r(MA,"__call__"),MA.forEach(t),DT=r($c," special method."),$c.forEach(t),OT=p(Ma),w(ps.$$.fragment,Ma),QT=p(Ma),w(hs.$$.fragment,Ma),Ma.forEach(t),Jo.forEach(t),Ku=p(o),nn=s(o,"H2",{class:!0});var lg=l(nn);ms=s(lg,"A",{id:!0,class:!0,href:!0});var $A=l(ms);Zp=s($A,"SPAN",{});var FA=l(Zp);w(Sr.$$.fragment,FA),FA.forEach(t),$A.forEach(t),HT=p(lg),Bp=s(lg,"SPAN",{});var AA=l(Bp);YT=r(AA,"AlbertForTokenClassification"),AA.forEach(t),lg.forEach(t),ef=p(o),yt=s(o,"DIV",{class:!0});var zo=l(yt);w(Lr.$$.fragment,zo),KT=p(zo),Gp=s(zo,"P",{});var EA=l(Gp);ek=r(EA,`Albert 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.`),EA.forEach(t),tk=p(zo),Dr=s(zo,"P",{});var ig=l(Dr);ok=r(ig,"This model inherits from "),Sd=s(ig,"A",{href:!0});var jA=l(Sd);nk=r(jA,"PreTrainedModel"),jA.forEach(t),sk=r(ig,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ig.forEach(t),ak=p(zo),Or=s(zo,"P",{});var dg=l(Or);rk=r(dg,"This model is also a PyTorch "),Qr=s(dg,"A",{href:!0,rel:!0});var xA=l(Qr);lk=r(xA,"torch.nn.Module"),xA.forEach(t),ik=r(dg,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),dg.forEach(t),dk=p(zo),Vt=s(zo,"DIV",{class:!0});var $a=l(Vt);w(Hr.$$.fragment,$a),ck=p($a),sn=s($a,"P",{});var Fc=l(sn);pk=r(Fc,"The "),Ld=s(Fc,"A",{href:!0});var JA=l(Ld);hk=r(JA,"AlbertForTokenClassification"),JA.forEach(t),mk=r(Fc," forward method, overrides the "),Rp=s(Fc,"CODE",{});var zA=l(Rp);uk=r(zA,"__call__"),zA.forEach(t),fk=r(Fc," special method."),Fc.forEach(t),gk=p($a),w(us.$$.fragment,$a),_k=p($a),w(fs.$$.fragment,$a),$a.forEach(t),zo.forEach(t),tf=p(o),an=s(o,"H2",{class:!0});var cg=l(an);gs=s(cg,"A",{id:!0,class:!0,href:!0});var CA=l(gs);Vp=s(CA,"SPAN",{});var UA=l(Vp);w(Yr.$$.fragment,UA),UA.forEach(t),CA.forEach(t),bk=p(cg),Xp=s(cg,"SPAN",{});var IA=l(Xp);yk=r(IA,"AlbertForQuestionAnswering"),IA.forEach(t),cg.forEach(t),of=p(o),Tt=s(o,"DIV",{class:!0});var Co=l(Tt);w(Kr.$$.fragment,Co),Tk=p(Co),rn=s(Co,"P",{});var Ac=l(rn);kk=r(Ac,`Albert 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 `),Sp=s(Ac,"CODE",{});var NA=l(Sp);wk=r(NA,"span start logits"),NA.forEach(t),vk=r(Ac," and "),Lp=s(Ac,"CODE",{});var WA=l(Lp);Mk=r(WA,"span end logits"),WA.forEach(t),$k=r(Ac,")."),Ac.forEach(t),Fk=p(Co),el=s(Co,"P",{});var pg=l(el);Ak=r(pg,"This model inherits from "),Dd=s(pg,"A",{href:!0});var qA=l(Dd);Ek=r(qA,"PreTrainedModel"),qA.forEach(t),jk=r(pg,`. 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.)`),pg.forEach(t),xk=p(Co),tl=s(Co,"P",{});var hg=l(tl);Jk=r(hg,"This model is also a PyTorch "),ol=s(hg,"A",{href:!0,rel:!0});var PA=l(ol);zk=r(PA,"torch.nn.Module"),PA.forEach(t),Ck=r(hg,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),hg.forEach(t),Uk=p(Co),Xt=s(Co,"DIV",{class:!0});var Fa=l(Xt);w(nl.$$.fragment,Fa),Ik=p(Fa),ln=s(Fa,"P",{});var Ec=l(ln);Nk=r(Ec,"The "),Od=s(Ec,"A",{href:!0});var ZA=l(Od);Wk=r(ZA,"AlbertForQuestionAnswering"),ZA.forEach(t),qk=r(Ec," forward method, overrides the "),Dp=s(Ec,"CODE",{});var BA=l(Dp);Pk=r(BA,"__call__"),BA.forEach(t),Zk=r(Ec," special method."),Ec.forEach(t),Bk=p(Fa),w(_s.$$.fragment,Fa),Gk=p(Fa),w(bs.$$.fragment,Fa),Fa.forEach(t),Co.forEach(t),nf=p(o),dn=s(o,"H2",{class:!0});var mg=l(dn);ys=s(mg,"A",{id:!0,class:!0,href:!0});var GA=l(ys);Op=s(GA,"SPAN",{});var RA=l(Op);w(sl.$$.fragment,RA),RA.forEach(t),GA.forEach(t),Rk=p(mg),Qp=s(mg,"SPAN",{});var VA=l(Qp);Vk=r(VA,"TFAlbertModel"),VA.forEach(t),mg.forEach(t),sf=p(o),lt=s(o,"DIV",{class:!0});var oo=l(lt);w(al.$$.fragment,oo),Xk=p(oo),Hp=s(oo,"P",{});var XA=l(Hp);Sk=r(XA,"The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),XA.forEach(t),Lk=p(oo),rl=s(oo,"P",{});var ug=l(rl);Dk=r(ug,"This model inherits from "),Qd=s(ug,"A",{href:!0});var SA=l(Qd);Ok=r(SA,"TFPreTrainedModel"),SA.forEach(t),Qk=r(ug,`. 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.)`),ug.forEach(t),Hk=p(oo),ll=s(oo,"P",{});var fg=l(ll);Yk=r(fg,"This model is also a "),il=s(fg,"A",{href:!0,rel:!0});var LA=l(il);Kk=r(LA,"tf.keras.Model"),LA.forEach(t),ew=r(fg,` 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.`),fg.forEach(t),tw=p(oo),w(Ts.$$.fragment,oo),ow=p(oo),St=s(oo,"DIV",{class:!0});var Aa=l(St);w(dl.$$.fragment,Aa),nw=p(Aa),cn=s(Aa,"P",{});var jc=l(cn);sw=r(jc,"The "),Hd=s(jc,"A",{href:!0});var DA=l(Hd);aw=r(DA,"TFAlbertModel"),DA.forEach(t),rw=r(jc," forward method, overrides the "),Yp=s(jc,"CODE",{});var OA=l(Yp);lw=r(OA,"__call__"),OA.forEach(t),iw=r(jc," special method."),jc.forEach(t),dw=p(Aa),w(ks.$$.fragment,Aa),cw=p(Aa),w(ws.$$.fragment,Aa),Aa.forEach(t),oo.forEach(t),af=p(o),pn=s(o,"H2",{class:!0});var gg=l(pn);vs=s(gg,"A",{id:!0,class:!0,href:!0});var QA=l(vs);Kp=s(QA,"SPAN",{});var HA=l(Kp);w(cl.$$.fragment,HA),HA.forEach(t),QA.forEach(t),pw=p(gg),eh=s(gg,"SPAN",{});var YA=l(eh);hw=r(YA,"TFAlbertForPreTraining"),YA.forEach(t),gg.forEach(t),rf=p(o),it=s(o,"DIV",{class:!0});var no=l(it);w(pl.$$.fragment,no),mw=p(no),hn=s(no,"P",{});var xc=l(hn);uw=r(xc,"Albert Model with two heads on top for pretraining: a "),th=s(xc,"CODE",{});var KA=l(th);fw=r(KA,"masked language modeling"),KA.forEach(t),gw=r(xc," head and a "),oh=s(xc,"CODE",{});var eE=l(oh);_w=r(eE,"sentence order prediction"),eE.forEach(t),bw=r(xc," (classification) head."),xc.forEach(t),yw=p(no),hl=s(no,"P",{});var _g=l(hl);Tw=r(_g,"This model inherits from "),Yd=s(_g,"A",{href:!0});var tE=l(Yd);kw=r(tE,"TFPreTrainedModel"),tE.forEach(t),ww=r(_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),vw=p(no),ml=s(no,"P",{});var bg=l(ml);Mw=r(bg,"This model is also a "),ul=s(bg,"A",{href:!0,rel:!0});var oE=l(ul);$w=r(oE,"tf.keras.Model"),oE.forEach(t),Fw=r(bg,` 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.`),bg.forEach(t),Aw=p(no),w(Ms.$$.fragment,no),Ew=p(no),Lt=s(no,"DIV",{class:!0});var Ea=l(Lt);w(fl.$$.fragment,Ea),jw=p(Ea),mn=s(Ea,"P",{});var Jc=l(mn);xw=r(Jc,"The "),Kd=s(Jc,"A",{href:!0});var nE=l(Kd);Jw=r(nE,"TFAlbertForPreTraining"),nE.forEach(t),zw=r(Jc," forward method, overrides the "),nh=s(Jc,"CODE",{});var sE=l(nh);Cw=r(sE,"__call__"),sE.forEach(t),Uw=r(Jc," special method."),Jc.forEach(t),Iw=p(Ea),w($s.$$.fragment,Ea),Nw=p(Ea),w(Fs.$$.fragment,Ea),Ea.forEach(t),no.forEach(t),lf=p(o),un=s(o,"H2",{class:!0});var yg=l(un);As=s(yg,"A",{id:!0,class:!0,href:!0});var aE=l(As);sh=s(aE,"SPAN",{});var rE=l(sh);w(gl.$$.fragment,rE),rE.forEach(t),aE.forEach(t),Ww=p(yg),ah=s(yg,"SPAN",{});var lE=l(ah);qw=r(lE,"TFAlbertForMaskedLM"),lE.forEach(t),yg.forEach(t),df=p(o),dt=s(o,"DIV",{class:!0});var so=l(dt);w(_l.$$.fragment,so),Pw=p(so),bl=s(so,"P",{});var Tg=l(bl);Zw=r(Tg,"Albert Model with a "),rh=s(Tg,"CODE",{});var iE=l(rh);Bw=r(iE,"language modeling"),iE.forEach(t),Gw=r(Tg," head on top."),Tg.forEach(t),Rw=p(so),yl=s(so,"P",{});var kg=l(yl);Vw=r(kg,"This model inherits from "),ec=s(kg,"A",{href:!0});var dE=l(ec);Xw=r(dE,"TFPreTrainedModel"),dE.forEach(t),Sw=r(kg,`. 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.)`),kg.forEach(t),Lw=p(so),Tl=s(so,"P",{});var wg=l(Tl);Dw=r(wg,"This model is also a "),kl=s(wg,"A",{href:!0,rel:!0});var cE=l(kl);Ow=r(cE,"tf.keras.Model"),cE.forEach(t),Qw=r(wg,` 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.`),wg.forEach(t),Hw=p(so),w(Es.$$.fragment,so),Yw=p(so),Mt=s(so,"DIV",{class:!0});var Uo=l(Mt);w(wl.$$.fragment,Uo),Kw=p(Uo),fn=s(Uo,"P",{});var zc=l(fn);ev=r(zc,"The "),tc=s(zc,"A",{href:!0});var pE=l(tc);tv=r(pE,"TFAlbertForMaskedLM"),pE.forEach(t),ov=r(zc," forward method, overrides the "),lh=s(zc,"CODE",{});var hE=l(lh);nv=r(hE,"__call__"),hE.forEach(t),sv=r(zc," special method."),zc.forEach(t),av=p(Uo),w(js.$$.fragment,Uo),rv=p(Uo),w(xs.$$.fragment,Uo),lv=p(Uo),w(Js.$$.fragment,Uo),Uo.forEach(t),so.forEach(t),cf=p(o),gn=s(o,"H2",{class:!0});var vg=l(gn);zs=s(vg,"A",{id:!0,class:!0,href:!0});var mE=l(zs);ih=s(mE,"SPAN",{});var uE=l(ih);w(vl.$$.fragment,uE),uE.forEach(t),mE.forEach(t),iv=p(vg),dh=s(vg,"SPAN",{});var fE=l(dh);dv=r(fE,"TFAlbertForSequenceClassification"),fE.forEach(t),vg.forEach(t),pf=p(o),ct=s(o,"DIV",{class:!0});var ao=l(ct);w(Ml.$$.fragment,ao),cv=p(ao),ch=s(ao,"P",{});var gE=l(ch);pv=r(gE,`Albert Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),gE.forEach(t),hv=p(ao),$l=s(ao,"P",{});var Mg=l($l);mv=r(Mg,"This model inherits from "),oc=s(Mg,"A",{href:!0});var _E=l(oc);uv=r(_E,"TFPreTrainedModel"),_E.forEach(t),fv=r(Mg,`. 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.)`),Mg.forEach(t),gv=p(ao),Fl=s(ao,"P",{});var $g=l(Fl);_v=r($g,"This model is also a "),Al=s($g,"A",{href:!0,rel:!0});var bE=l(Al);bv=r(bE,"tf.keras.Model"),bE.forEach(t),yv=r($g,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),$g.forEach(t),Tv=p(ao),w(Cs.$$.fragment,ao),kv=p(ao),$t=s(ao,"DIV",{class:!0});var Io=l($t);w(El.$$.fragment,Io),wv=p(Io),_n=s(Io,"P",{});var Cc=l(_n);vv=r(Cc,"The "),nc=s(Cc,"A",{href:!0});var yE=l(nc);Mv=r(yE,"TFAlbertForSequenceClassification"),yE.forEach(t),$v=r(Cc," forward method, overrides the "),ph=s(Cc,"CODE",{});var TE=l(ph);Fv=r(TE,"__call__"),TE.forEach(t),Av=r(Cc," special method."),Cc.forEach(t),Ev=p(Io),w(Us.$$.fragment,Io),jv=p(Io),w(Is.$$.fragment,Io),xv=p(Io),w(Ns.$$.fragment,Io),Io.forEach(t),ao.forEach(t),hf=p(o),bn=s(o,"H2",{class:!0});var Fg=l(bn);Ws=s(Fg,"A",{id:!0,class:!0,href:!0});var kE=l(Ws);hh=s(kE,"SPAN",{});var wE=l(hh);w(jl.$$.fragment,wE),wE.forEach(t),kE.forEach(t),Jv=p(Fg),mh=s(Fg,"SPAN",{});var vE=l(mh);zv=r(vE,"TFAlbertForMultipleChoice"),vE.forEach(t),Fg.forEach(t),mf=p(o),pt=s(o,"DIV",{class:!0});var ro=l(pt);w(xl.$$.fragment,ro),Cv=p(ro),uh=s(ro,"P",{});var ME=l(uh);Uv=r(ME,`Albert 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.`),ME.forEach(t),Iv=p(ro),Jl=s(ro,"P",{});var Ag=l(Jl);Nv=r(Ag,"This model inherits from "),sc=s(Ag,"A",{href:!0});var $E=l(sc);Wv=r($E,"TFPreTrainedModel"),$E.forEach(t),qv=r(Ag,`. 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.)`),Ag.forEach(t),Pv=p(ro),zl=s(ro,"P",{});var Eg=l(zl);Zv=r(Eg,"This model is also a "),Cl=s(Eg,"A",{href:!0,rel:!0});var FE=l(Cl);Bv=r(FE,"tf.keras.Model"),FE.forEach(t),Gv=r(Eg,` 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.`),Eg.forEach(t),Rv=p(ro),w(qs.$$.fragment,ro),Vv=p(ro),Dt=s(ro,"DIV",{class:!0});var ja=l(Dt);w(Ul.$$.fragment,ja),Xv=p(ja),yn=s(ja,"P",{});var Uc=l(yn);Sv=r(Uc,"The "),ac=s(Uc,"A",{href:!0});var AE=l(ac);Lv=r(AE,"TFAlbertForMultipleChoice"),AE.forEach(t),Dv=r(Uc," forward method, overrides the "),fh=s(Uc,"CODE",{});var EE=l(fh);Ov=r(EE,"__call__"),EE.forEach(t),Qv=r(Uc," special method."),Uc.forEach(t),Hv=p(ja),w(Ps.$$.fragment,ja),Yv=p(ja),w(Zs.$$.fragment,ja),ja.forEach(t),ro.forEach(t),uf=p(o),Tn=s(o,"H2",{class:!0});var jg=l(Tn);Bs=s(jg,"A",{id:!0,class:!0,href:!0});var jE=l(Bs);gh=s(jE,"SPAN",{});var xE=l(gh);w(Il.$$.fragment,xE),xE.forEach(t),jE.forEach(t),Kv=p(jg),_h=s(jg,"SPAN",{});var JE=l(_h);eM=r(JE,"TFAlbertForTokenClassification"),JE.forEach(t),jg.forEach(t),ff=p(o),ht=s(o,"DIV",{class:!0});var lo=l(ht);w(Nl.$$.fragment,lo),tM=p(lo),bh=s(lo,"P",{});var zE=l(bh);oM=r(zE,`Albert 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.`),zE.forEach(t),nM=p(lo),Wl=s(lo,"P",{});var xg=l(Wl);sM=r(xg,"This model inherits from "),rc=s(xg,"A",{href:!0});var CE=l(rc);aM=r(CE,"TFPreTrainedModel"),CE.forEach(t),rM=r(xg,`. 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.)`),xg.forEach(t),lM=p(lo),ql=s(lo,"P",{});var Jg=l(ql);iM=r(Jg,"This model is also a "),Pl=s(Jg,"A",{href:!0,rel:!0});var UE=l(Pl);dM=r(UE,"tf.keras.Model"),UE.forEach(t),cM=r(Jg,` 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.`),Jg.forEach(t),pM=p(lo),w(Gs.$$.fragment,lo),hM=p(lo),Ft=s(lo,"DIV",{class:!0});var No=l(Ft);w(Zl.$$.fragment,No),mM=p(No),kn=s(No,"P",{});var Ic=l(kn);uM=r(Ic,"The "),lc=s(Ic,"A",{href:!0});var IE=l(lc);fM=r(IE,"TFAlbertForTokenClassification"),IE.forEach(t),gM=r(Ic," forward method, overrides the "),yh=s(Ic,"CODE",{});var NE=l(yh);_M=r(NE,"__call__"),NE.forEach(t),bM=r(Ic," special method."),Ic.forEach(t),yM=p(No),w(Rs.$$.fragment,No),TM=p(No),w(Vs.$$.fragment,No),kM=p(No),w(Xs.$$.fragment,No),No.forEach(t),lo.forEach(t),gf=p(o),wn=s(o,"H2",{class:!0});var zg=l(wn);Ss=s(zg,"A",{id:!0,class:!0,href:!0});var WE=l(Ss);Th=s(WE,"SPAN",{});var qE=l(Th);w(Bl.$$.fragment,qE),qE.forEach(t),WE.forEach(t),wM=p(zg),kh=s(zg,"SPAN",{});var PE=l(kh);vM=r(PE,"TFAlbertForQuestionAnswering"),PE.forEach(t),zg.forEach(t),_f=p(o),mt=s(o,"DIV",{class:!0});var io=l(mt);w(Gl.$$.fragment,io),MM=p(io),vn=s(io,"P",{});var Nc=l(vn);$M=r(Nc,`Albert 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 `),wh=s(Nc,"CODE",{});var ZE=l(wh);FM=r(ZE,"span start logits"),ZE.forEach(t),AM=r(Nc," and "),vh=s(Nc,"CODE",{});var BE=l(vh);EM=r(BE,"span end logits"),BE.forEach(t),jM=r(Nc,")."),Nc.forEach(t),xM=p(io),Rl=s(io,"P",{});var Cg=l(Rl);JM=r(Cg,"This model inherits from "),ic=s(Cg,"A",{href:!0});var GE=l(ic);zM=r(GE,"TFPreTrainedModel"),GE.forEach(t),CM=r(Cg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Cg.forEach(t),UM=p(io),Vl=s(io,"P",{});var Ug=l(Vl);IM=r(Ug,"This model is also a "),Xl=s(Ug,"A",{href:!0,rel:!0});var RE=l(Xl);NM=r(RE,"tf.keras.Model"),RE.forEach(t),WM=r(Ug,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Ug.forEach(t),qM=p(io),w(Ls.$$.fragment,io),PM=p(io),At=s(io,"DIV",{class:!0});var Wo=l(At);w(Sl.$$.fragment,Wo),ZM=p(Wo),Mn=s(Wo,"P",{});var Wc=l(Mn);BM=r(Wc,"The "),dc=s(Wc,"A",{href:!0});var VE=l(dc);GM=r(VE,"TFAlbertForQuestionAnswering"),VE.forEach(t),RM=r(Wc," forward method, overrides the "),Mh=s(Wc,"CODE",{});var XE=l(Mh);VM=r(XE,"__call__"),XE.forEach(t),XM=r(Wc," special method."),Wc.forEach(t),SM=p(Wo),w(Ds.$$.fragment,Wo),LM=p(Wo),w(Os.$$.fragment,Wo),DM=p(Wo),w(Qs.$$.fragment,Wo),Wo.forEach(t),io.forEach(t),bf=p(o),$n=s(o,"H2",{class:!0});var Ig=l($n);Hs=s(Ig,"A",{id:!0,class:!0,href:!0});var SE=l(Hs);$h=s(SE,"SPAN",{});var LE=l($h);w(Ll.$$.fragment,LE),LE.forEach(t),SE.forEach(t),OM=p(Ig),Fh=s(Ig,"SPAN",{});var DE=l(Fh);QM=r(DE,"FlaxAlbertModel"),DE.forEach(t),Ig.forEach(t),yf=p(o),et=s(o,"DIV",{class:!0});var jt=l(et);w(Dl.$$.fragment,jt),HM=p(jt),Ah=s(jt,"P",{});var OE=l(Ah);YM=r(OE,"The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),OE.forEach(t),KM=p(jt),Ol=s(jt,"P",{});var Ng=l(Ol);e2=r(Ng,"This model inherits from "),cc=s(Ng,"A",{href:!0});var QE=l(cc);t2=r(QE,"FlaxPreTrainedModel"),QE.forEach(t),o2=r(Ng,`. 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)`),Ng.forEach(t),n2=p(jt),Ql=s(jt,"P",{});var Wg=l(Ql);s2=r(Wg,"This model is also a Flax Linen "),Hl=s(Wg,"A",{href:!0,rel:!0});var HE=l(Hl);a2=r(HE,"flax.linen.Module"),HE.forEach(t),r2=r(Wg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Wg.forEach(t),l2=p(jt),Eh=s(jt,"P",{});var YE=l(Eh);i2=r(YE,"Finally, this model supports inherent JAX features such as:"),YE.forEach(t),d2=p(jt),ho=s(jt,"UL",{});var xa=l(ho);jh=s(xa,"LI",{});var KE=l(jh);Yl=s(KE,"A",{href:!0,rel:!0});var ej=l(Yl);c2=r(ej,"Just-In-Time (JIT) compilation"),ej.forEach(t),KE.forEach(t),p2=p(xa),xh=s(xa,"LI",{});var tj=l(xh);Kl=s(tj,"A",{href:!0,rel:!0});var oj=l(Kl);h2=r(oj,"Automatic Differentiation"),oj.forEach(t),tj.forEach(t),m2=p(xa),Jh=s(xa,"LI",{});var nj=l(Jh);ei=s(nj,"A",{href:!0,rel:!0});var sj=l(ei);u2=r(sj,"Vectorization"),sj.forEach(t),nj.forEach(t),f2=p(xa),zh=s(xa,"LI",{});var aj=l(zh);ti=s(aj,"A",{href:!0,rel:!0});var rj=l(ti);g2=r(rj,"Parallelization"),rj.forEach(t),aj.forEach(t),xa.forEach(t),_2=p(jt),Ot=s(jt,"DIV",{class:!0});var Ja=l(Ot);w(oi.$$.fragment,Ja),b2=p(Ja),Fn=s(Ja,"P",{});var qc=l(Fn);y2=r(qc,"The "),Ch=s(qc,"CODE",{});var lj=l(Ch);T2=r(lj,"FlaxAlbertPreTrainedModel"),lj.forEach(t),k2=r(qc," forward method, overrides the "),Uh=s(qc,"CODE",{});var ij=l(Uh);w2=r(ij,"__call__"),ij.forEach(t),v2=r(qc," special method."),qc.forEach(t),M2=p(Ja),w(Ys.$$.fragment,Ja),$2=p(Ja),w(Ks.$$.fragment,Ja),Ja.forEach(t),jt.forEach(t),Tf=p(o),An=s(o,"H2",{class:!0});var qg=l(An);ea=s(qg,"A",{id:!0,class:!0,href:!0});var dj=l(ea);Ih=s(dj,"SPAN",{});var cj=l(Ih);w(ni.$$.fragment,cj),cj.forEach(t),dj.forEach(t),F2=p(qg),Nh=s(qg,"SPAN",{});var pj=l(Nh);A2=r(pj,"FlaxAlbertForPreTraining"),pj.forEach(t),qg.forEach(t),kf=p(o),tt=s(o,"DIV",{class:!0});var xt=l(tt);w(si.$$.fragment,xt),E2=p(xt),En=s(xt,"P",{});var Pc=l(En);j2=r(Pc,"Albert Model with two heads on top as done during the pretraining: a "),Wh=s(Pc,"CODE",{});var hj=l(Wh);x2=r(hj,"masked language modeling"),hj.forEach(t),J2=r(Pc,` head and a
`),qh=s(Pc,"CODE",{});var mj=l(qh);z2=r(mj,"sentence order prediction (classification)"),mj.forEach(t),C2=r(Pc," head."),Pc.forEach(t),U2=p(xt),ai=s(xt,"P",{});var Pg=l(ai);I2=r(Pg,"This model inherits from "),pc=s(Pg,"A",{href:!0});var uj=l(pc);N2=r(uj,"FlaxPreTrainedModel"),uj.forEach(t),W2=r(Pg,`. 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)`),Pg.forEach(t),q2=p(xt),ri=s(xt,"P",{});var Zg=l(ri);P2=r(Zg,"This model is also a Flax Linen "),li=s(Zg,"A",{href:!0,rel:!0});var fj=l(li);Z2=r(fj,"flax.linen.Module"),fj.forEach(t),B2=r(Zg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Zg.forEach(t),G2=p(xt),Ph=s(xt,"P",{});var gj=l(Ph);R2=r(gj,"Finally, this model supports inherent JAX features such as:"),gj.forEach(t),V2=p(xt),mo=s(xt,"UL",{});var za=l(mo);Zh=s(za,"LI",{});var _j=l(Zh);ii=s(_j,"A",{href:!0,rel:!0});var bj=l(ii);X2=r(bj,"Just-In-Time (JIT) compilation"),bj.forEach(t),_j.forEach(t),S2=p(za),Bh=s(za,"LI",{});var yj=l(Bh);di=s(yj,"A",{href:!0,rel:!0});var Tj=l(di);L2=r(Tj,"Automatic Differentiation"),Tj.forEach(t),yj.forEach(t),D2=p(za),Gh=s(za,"LI",{});var kj=l(Gh);ci=s(kj,"A",{href:!0,rel:!0});var wj=l(ci);O2=r(wj,"Vectorization"),wj.forEach(t),kj.forEach(t),Q2=p(za),Rh=s(za,"LI",{});var vj=l(Rh);pi=s(vj,"A",{href:!0,rel:!0});var Mj=l(pi);H2=r(Mj,"Parallelization"),Mj.forEach(t),vj.forEach(t),za.forEach(t),Y2=p(xt),Qt=s(xt,"DIV",{class:!0});var Ca=l(Qt);w(hi.$$.fragment,Ca),K2=p(Ca),jn=s(Ca,"P",{});var Zc=l(jn);e1=r(Zc,"The "),Vh=s(Zc,"CODE",{});var $j=l(Vh);t1=r($j,"FlaxAlbertPreTrainedModel"),$j.forEach(t),o1=r(Zc," forward method, overrides the "),Xh=s(Zc,"CODE",{});var Fj=l(Xh);n1=r(Fj,"__call__"),Fj.forEach(t),s1=r(Zc," special method."),Zc.forEach(t),a1=p(Ca),w(ta.$$.fragment,Ca),r1=p(Ca),w(oa.$$.fragment,Ca),Ca.forEach(t),xt.forEach(t),wf=p(o),xn=s(o,"H2",{class:!0});var Bg=l(xn);na=s(Bg,"A",{id:!0,class:!0,href:!0});var Aj=l(na);Sh=s(Aj,"SPAN",{});var Ej=l(Sh);w(mi.$$.fragment,Ej),Ej.forEach(t),Aj.forEach(t),l1=p(Bg),Lh=s(Bg,"SPAN",{});var jj=l(Lh);i1=r(jj,"FlaxAlbertForMaskedLM"),jj.forEach(t),Bg.forEach(t),vf=p(o),ot=s(o,"DIV",{class:!0});var Jt=l(ot);w(ui.$$.fragment,Jt),d1=p(Jt),fi=s(Jt,"P",{});var Gg=l(fi);c1=r(Gg,"Albert Model with a "),Dh=s(Gg,"CODE",{});var xj=l(Dh);p1=r(xj,"language modeling"),xj.forEach(t),h1=r(Gg," head on top."),Gg.forEach(t),m1=p(Jt),gi=s(Jt,"P",{});var Rg=l(gi);u1=r(Rg,"This model inherits from "),hc=s(Rg,"A",{href:!0});var Jj=l(hc);f1=r(Jj,"FlaxPreTrainedModel"),Jj.forEach(t),g1=r(Rg,`. 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)`),Rg.forEach(t),_1=p(Jt),_i=s(Jt,"P",{});var Vg=l(_i);b1=r(Vg,"This model is also a Flax Linen "),bi=s(Vg,"A",{href:!0,rel:!0});var zj=l(bi);y1=r(zj,"flax.linen.Module"),zj.forEach(t),T1=r(Vg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Vg.forEach(t),k1=p(Jt),Oh=s(Jt,"P",{});var Cj=l(Oh);w1=r(Cj,"Finally, this model supports inherent JAX features such as:"),Cj.forEach(t),v1=p(Jt),uo=s(Jt,"UL",{});var Ua=l(uo);Qh=s(Ua,"LI",{});var Uj=l(Qh);yi=s(Uj,"A",{href:!0,rel:!0});var Ij=l(yi);M1=r(Ij,"Just-In-Time (JIT) compilation"),Ij.forEach(t),Uj.forEach(t),$1=p(Ua),Hh=s(Ua,"LI",{});var Nj=l(Hh);Ti=s(Nj,"A",{href:!0,rel:!0});var Wj=l(Ti);F1=r(Wj,"Automatic Differentiation"),Wj.forEach(t),Nj.forEach(t),A1=p(Ua),Yh=s(Ua,"LI",{});var qj=l(Yh);ki=s(qj,"A",{href:!0,rel:!0});var Pj=l(ki);E1=r(Pj,"Vectorization"),Pj.forEach(t),qj.forEach(t),j1=p(Ua),Kh=s(Ua,"LI",{});var Zj=l(Kh);wi=s(Zj,"A",{href:!0,rel:!0});var Bj=l(wi);x1=r(Bj,"Parallelization"),Bj.forEach(t),Zj.forEach(t),Ua.forEach(t),J1=p(Jt),Ht=s(Jt,"DIV",{class:!0});var Ia=l(Ht);w(vi.$$.fragment,Ia),z1=p(Ia),Jn=s(Ia,"P",{});var Bc=l(Jn);C1=r(Bc,"The "),em=s(Bc,"CODE",{});var Gj=l(em);U1=r(Gj,"FlaxAlbertPreTrainedModel"),Gj.forEach(t),I1=r(Bc," forward method, overrides the "),tm=s(Bc,"CODE",{});var Rj=l(tm);N1=r(Rj,"__call__"),Rj.forEach(t),W1=r(Bc," special method."),Bc.forEach(t),q1=p(Ia),w(sa.$$.fragment,Ia),P1=p(Ia),w(aa.$$.fragment,Ia),Ia.forEach(t),Jt.forEach(t),Mf=p(o),zn=s(o,"H2",{class:!0});var Xg=l(zn);ra=s(Xg,"A",{id:!0,class:!0,href:!0});var Vj=l(ra);om=s(Vj,"SPAN",{});var Xj=l(om);w(Mi.$$.fragment,Xj),Xj.forEach(t),Vj.forEach(t),Z1=p(Xg),nm=s(Xg,"SPAN",{});var Sj=l(nm);B1=r(Sj,"FlaxAlbertForSequenceClassification"),Sj.forEach(t),Xg.forEach(t),$f=p(o),nt=s(o,"DIV",{class:!0});var zt=l(nt);w($i.$$.fragment,zt),G1=p(zt),sm=s(zt,"P",{});var Lj=l(sm);R1=r(Lj,`Albert Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),Lj.forEach(t),V1=p(zt),Fi=s(zt,"P",{});var Sg=l(Fi);X1=r(Sg,"This model inherits from "),mc=s(Sg,"A",{href:!0});var Dj=l(mc);S1=r(Dj,"FlaxPreTrainedModel"),Dj.forEach(t),L1=r(Sg,`. 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)`),Sg.forEach(t),D1=p(zt),Ai=s(zt,"P",{});var Lg=l(Ai);O1=r(Lg,"This model is also a Flax Linen "),Ei=s(Lg,"A",{href:!0,rel:!0});var Oj=l(Ei);Q1=r(Oj,"flax.linen.Module"),Oj.forEach(t),H1=r(Lg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Lg.forEach(t),Y1=p(zt),am=s(zt,"P",{});var Qj=l(am);K1=r(Qj,"Finally, this model supports inherent JAX features such as:"),Qj.forEach(t),e$=p(zt),fo=s(zt,"UL",{});var Na=l(fo);rm=s(Na,"LI",{});var Hj=l(rm);ji=s(Hj,"A",{href:!0,rel:!0});var Yj=l(ji);t$=r(Yj,"Just-In-Time (JIT) compilation"),Yj.forEach(t),Hj.forEach(t),o$=p(Na),lm=s(Na,"LI",{});var Kj=l(lm);xi=s(Kj,"A",{href:!0,rel:!0});var ex=l(xi);n$=r(ex,"Automatic Differentiation"),ex.forEach(t),Kj.forEach(t),s$=p(Na),im=s(Na,"LI",{});var tx=l(im);Ji=s(tx,"A",{href:!0,rel:!0});var ox=l(Ji);a$=r(ox,"Vectorization"),ox.forEach(t),tx.forEach(t),r$=p(Na),dm=s(Na,"LI",{});var nx=l(dm);zi=s(nx,"A",{href:!0,rel:!0});var sx=l(zi);l$=r(sx,"Parallelization"),sx.forEach(t),nx.forEach(t),Na.forEach(t),i$=p(zt),Yt=s(zt,"DIV",{class:!0});var Wa=l(Yt);w(Ci.$$.fragment,Wa),d$=p(Wa),Cn=s(Wa,"P",{});var Gc=l(Cn);c$=r(Gc,"The "),cm=s(Gc,"CODE",{});var ax=l(cm);p$=r(ax,"FlaxAlbertPreTrainedModel"),ax.forEach(t),h$=r(Gc," forward method, overrides the "),pm=s(Gc,"CODE",{});var rx=l(pm);m$=r(rx,"__call__"),rx.forEach(t),u$=r(Gc," special method."),Gc.forEach(t),f$=p(Wa),w(la.$$.fragment,Wa),g$=p(Wa),w(ia.$$.fragment,Wa),Wa.forEach(t),zt.forEach(t),Ff=p(o),Un=s(o,"H2",{class:!0});var Dg=l(Un);da=s(Dg,"A",{id:!0,class:!0,href:!0});var lx=l(da);hm=s(lx,"SPAN",{});var ix=l(hm);w(Ui.$$.fragment,ix),ix.forEach(t),lx.forEach(t),_$=p(Dg),mm=s(Dg,"SPAN",{});var dx=l(mm);b$=r(dx,"FlaxAlbertForMultipleChoice"),dx.forEach(t),Dg.forEach(t),Af=p(o),st=s(o,"DIV",{class:!0});var Ct=l(st);w(Ii.$$.fragment,Ct),y$=p(Ct),um=s(Ct,"P",{});var cx=l(um);T$=r(cx,`Albert 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.`),cx.forEach(t),k$=p(Ct),Ni=s(Ct,"P",{});var Og=l(Ni);w$=r(Og,"This model inherits from "),uc=s(Og,"A",{href:!0});var px=l(uc);v$=r(px,"FlaxPreTrainedModel"),px.forEach(t),M$=r(Og,`. 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)`),Og.forEach(t),$$=p(Ct),Wi=s(Ct,"P",{});var Qg=l(Wi);F$=r(Qg,"This model is also a Flax Linen "),qi=s(Qg,"A",{href:!0,rel:!0});var hx=l(qi);A$=r(hx,"flax.linen.Module"),hx.forEach(t),E$=r(Qg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Qg.forEach(t),j$=p(Ct),fm=s(Ct,"P",{});var mx=l(fm);x$=r(mx,"Finally, this model supports inherent JAX features such as:"),mx.forEach(t),J$=p(Ct),go=s(Ct,"UL",{});var qa=l(go);gm=s(qa,"LI",{});var ux=l(gm);Pi=s(ux,"A",{href:!0,rel:!0});var fx=l(Pi);z$=r(fx,"Just-In-Time (JIT) compilation"),fx.forEach(t),ux.forEach(t),C$=p(qa),_m=s(qa,"LI",{});var gx=l(_m);Zi=s(gx,"A",{href:!0,rel:!0});var _x=l(Zi);U$=r(_x,"Automatic Differentiation"),_x.forEach(t),gx.forEach(t),I$=p(qa),bm=s(qa,"LI",{});var bx=l(bm);Bi=s(bx,"A",{href:!0,rel:!0});var yx=l(Bi);N$=r(yx,"Vectorization"),yx.forEach(t),bx.forEach(t),W$=p(qa),ym=s(qa,"LI",{});var Tx=l(ym);Gi=s(Tx,"A",{href:!0,rel:!0});var kx=l(Gi);q$=r(kx,"Parallelization"),kx.forEach(t),Tx.forEach(t),qa.forEach(t),P$=p(Ct),Kt=s(Ct,"DIV",{class:!0});var Pa=l(Kt);w(Ri.$$.fragment,Pa),Z$=p(Pa),In=s(Pa,"P",{});var Rc=l(In);B$=r(Rc,"The "),Tm=s(Rc,"CODE",{});var wx=l(Tm);G$=r(wx,"FlaxAlbertPreTrainedModel"),wx.forEach(t),R$=r(Rc," forward method, overrides the "),km=s(Rc,"CODE",{});var vx=l(km);V$=r(vx,"__call__"),vx.forEach(t),X$=r(Rc," special method."),Rc.forEach(t),S$=p(Pa),w(ca.$$.fragment,Pa),L$=p(Pa),w(pa.$$.fragment,Pa),Pa.forEach(t),Ct.forEach(t),Ef=p(o),Nn=s(o,"H2",{class:!0});var Hg=l(Nn);ha=s(Hg,"A",{id:!0,class:!0,href:!0});var Mx=l(ha);wm=s(Mx,"SPAN",{});var $x=l(wm);w(Vi.$$.fragment,$x),$x.forEach(t),Mx.forEach(t),D$=p(Hg),vm=s(Hg,"SPAN",{});var Fx=l(vm);O$=r(Fx,"FlaxAlbertForTokenClassification"),Fx.forEach(t),Hg.forEach(t),jf=p(o),at=s(o,"DIV",{class:!0});var Ut=l(at);w(Xi.$$.fragment,Ut),Q$=p(Ut),Mm=s(Ut,"P",{});var Ax=l(Mm);H$=r(Ax,`Albert 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.`),Ax.forEach(t),Y$=p(Ut),Si=s(Ut,"P",{});var Yg=l(Si);K$=r(Yg,"This model inherits from "),fc=s(Yg,"A",{href:!0});var Ex=l(fc);e0=r(Ex,"FlaxPreTrainedModel"),Ex.forEach(t),t0=r(Yg,`. 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)`),Yg.forEach(t),o0=p(Ut),Li=s(Ut,"P",{});var Kg=l(Li);n0=r(Kg,"This model is also a Flax Linen "),Di=s(Kg,"A",{href:!0,rel:!0});var jx=l(Di);s0=r(jx,"flax.linen.Module"),jx.forEach(t),a0=r(Kg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Kg.forEach(t),r0=p(Ut),$m=s(Ut,"P",{});var xx=l($m);l0=r(xx,"Finally, this model supports inherent JAX features such as:"),xx.forEach(t),i0=p(Ut),_o=s(Ut,"UL",{});var Za=l(_o);Fm=s(Za,"LI",{});var Jx=l(Fm);Oi=s(Jx,"A",{href:!0,rel:!0});var zx=l(Oi);d0=r(zx,"Just-In-Time (JIT) compilation"),zx.forEach(t),Jx.forEach(t),c0=p(Za),Am=s(Za,"LI",{});var Cx=l(Am);Qi=s(Cx,"A",{href:!0,rel:!0});var Ux=l(Qi);p0=r(Ux,"Automatic Differentiation"),Ux.forEach(t),Cx.forEach(t),h0=p(Za),Em=s(Za,"LI",{});var Ix=l(Em);Hi=s(Ix,"A",{href:!0,rel:!0});var Nx=l(Hi);m0=r(Nx,"Vectorization"),Nx.forEach(t),Ix.forEach(t),u0=p(Za),jm=s(Za,"LI",{});var Wx=l(jm);Yi=s(Wx,"A",{href:!0,rel:!0});var qx=l(Yi);f0=r(qx,"Parallelization"),qx.forEach(t),Wx.forEach(t),Za.forEach(t),g0=p(Ut),eo=s(Ut,"DIV",{class:!0});var Ba=l(eo);w(Ki.$$.fragment,Ba),_0=p(Ba),Wn=s(Ba,"P",{});var Vc=l(Wn);b0=r(Vc,"The "),xm=s(Vc,"CODE",{});var Px=l(xm);y0=r(Px,"FlaxAlbertPreTrainedModel"),Px.forEach(t),T0=r(Vc," forward method, overrides the "),Jm=s(Vc,"CODE",{});var Zx=l(Jm);k0=r(Zx,"__call__"),Zx.forEach(t),w0=r(Vc," special method."),Vc.forEach(t),v0=p(Ba),w(ma.$$.fragment,Ba),M0=p(Ba),w(ua.$$.fragment,Ba),Ba.forEach(t),Ut.forEach(t),xf=p(o),qn=s(o,"H2",{class:!0});var e_=l(qn);fa=s(e_,"A",{id:!0,class:!0,href:!0});var Bx=l(fa);zm=s(Bx,"SPAN",{});var Gx=l(zm);w(ed.$$.fragment,Gx),Gx.forEach(t),Bx.forEach(t),$0=p(e_),Cm=s(e_,"SPAN",{});var Rx=l(Cm);F0=r(Rx,"FlaxAlbertForQuestionAnswering"),Rx.forEach(t),e_.forEach(t),Jf=p(o),rt=s(o,"DIV",{class:!0});var It=l(rt);w(td.$$.fragment,It),A0=p(It),Pn=s(It,"P",{});var Xc=l(Pn);E0=r(Xc,`Albert 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 `),Um=s(Xc,"CODE",{});var Vx=l(Um);j0=r(Vx,"span start logits"),Vx.forEach(t),x0=r(Xc," and "),Im=s(Xc,"CODE",{});var Xx=l(Im);J0=r(Xx,"span end logits"),Xx.forEach(t),z0=r(Xc,")."),Xc.forEach(t),C0=p(It),od=s(It,"P",{});var t_=l(od);U0=r(t_,"This model inherits from "),gc=s(t_,"A",{href:!0});var Sx=l(gc);I0=r(Sx,"FlaxPreTrainedModel"),Sx.forEach(t),N0=r(t_,`. 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)`),t_.forEach(t),W0=p(It),nd=s(It,"P",{});var o_=l(nd);q0=r(o_,"This model is also a Flax Linen "),sd=s(o_,"A",{href:!0,rel:!0});var Lx=l(sd);P0=r(Lx,"flax.linen.Module"),Lx.forEach(t),Z0=r(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.`),o_.forEach(t),B0=p(It),Nm=s(It,"P",{});var Dx=l(Nm);G0=r(Dx,"Finally, this model supports inherent JAX features such as:"),Dx.forEach(t),R0=p(It),bo=s(It,"UL",{});var Ga=l(bo);Wm=s(Ga,"LI",{});var Ox=l(Wm);ad=s(Ox,"A",{href:!0,rel:!0});var Qx=l(ad);V0=r(Qx,"Just-In-Time (JIT) compilation"),Qx.forEach(t),Ox.forEach(t),X0=p(Ga),qm=s(Ga,"LI",{});var Hx=l(qm);rd=s(Hx,"A",{href:!0,rel:!0});var Yx=l(rd);S0=r(Yx,"Automatic Differentiation"),Yx.forEach(t),Hx.forEach(t),L0=p(Ga),Pm=s(Ga,"LI",{});var Kx=l(Pm);ld=s(Kx,"A",{href:!0,rel:!0});var eJ=l(ld);D0=r(eJ,"Vectorization"),eJ.forEach(t),Kx.forEach(t),O0=p(Ga),Zm=s(Ga,"LI",{});var tJ=l(Zm);id=s(tJ,"A",{href:!0,rel:!0});var oJ=l(id);Q0=r(oJ,"Parallelization"),oJ.forEach(t),tJ.forEach(t),Ga.forEach(t),H0=p(It),to=s(It,"DIV",{class:!0});var Ra=l(to);w(dd.$$.fragment,Ra),Y0=p(Ra),Zn=s(Ra,"P",{});var Sc=l(Zn);K0=r(Sc,"The "),Bm=s(Sc,"CODE",{});var nJ=l(Bm);eF=r(nJ,"FlaxAlbertPreTrainedModel"),nJ.forEach(t),tF=r(Sc," forward method, overrides the "),Gm=s(Sc,"CODE",{});var sJ=l(Gm);oF=r(sJ,"__call__"),sJ.forEach(t),nF=r(Sc," special method."),Sc.forEach(t),sF=p(Ra),w(ga.$$.fragment,Ra),aF=p(Ra),w(_a.$$.fragment,Ra),Ra.forEach(t),It.forEach(t),this.h()},h(){u(d,"name","hf:doc:metadata"),u(d,"content",JSON.stringify(gz)),u(f,"id","albert"),u(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"),u(f,"href","#albert"),u(m,"class","relative group"),u(K,"alt","Models"),aJ(K.src,A="https://img.shields.io/badge/All_model_pages-albert-blueviolet")||u(K,"src",A),u(de,"href","https://huggingface.co/models?filter=albert"),u(ce,"alt","Spaces"),aJ(ce.src,Ue="https://img.shields.io/badge/%F0%9F%A4%97%20Hugging%20Face-Spaces-blue")||u(ce,"src",Ue),u(V,"href","https://huggingface.co/spaces/docs-demos/albert-base-v2"),u(B,"class","flex flex-wrap space-x-1"),u(ae,"id","overview"),u(ae,"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"),u(ae,"href","#overview"),u(se,"class","relative group"),u(ie,"href","https://arxiv.org/abs/1909.11942"),u(ie,"rel","nofollow"),u(Ze,"href","https://huggingface.co/lysandre"),u(Ze,"rel","nofollow"),u(Be,"href","https://huggingface.co/kamalkraj"),u(Be,"rel","nofollow"),u(R,"href","https://github.com/google-research/ALBERT"),u(R,"rel","nofollow"),u(Pe,"id","documentation-resources"),u(Pe,"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"),u(Pe,"href","#documentation-resources"),u(Ie,"class","relative group"),u(bd,"href","../tasks/sequence_classification"),u(yd,"href","../tasks/token_classification"),u(Td,"href","../tasks/question_answering"),u(kd,"href","../tasks/masked_language_modeling"),u(wd,"href","../tasks/multiple_choice"),u(Gn,"id","transformers.AlbertConfig"),u(Gn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(Gn,"href","#transformers.AlbertConfig"),u(qo,"class","relative group"),u(vd,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertModel"),u(Md,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertModel"),u(Sa,"href","https://huggingface.co/albert-xxlarge-v2"),u(Sa,"rel","nofollow"),u($d,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),u(Fd,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),u(Nt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Vn,"id","transformers.AlbertTokenizer"),u(Vn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(Vn,"href","#transformers.AlbertTokenizer"),u(Zo,"class","relative group"),u(Qa,"href","https://github.com/google/sentencepiece"),u(Qa,"rel","nofollow"),u(Ad,"href","/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizer"),u(vo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Xn,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(xd,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Ke,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Ln,"id","transformers.AlbertTokenizerFast"),u(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"),u(Ln,"href","#transformers.AlbertTokenizerFast"),u(Go,"class","relative group"),u(rr,"href","https://huggingface.co/docs/tokenizers/python/latest/components.html?highlight=unigram#models"),u(rr,"rel","nofollow"),u(Jd,"href","/docs/transformers/main/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast"),u(Mo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Zt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Wt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(On,"id","transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput"),u(On,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(On,"href","#transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput"),u(Ro,"class","relative group"),u(Ud,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertForPreTraining"),u(Vo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Id,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertForPreTraining"),u(Xo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Qn,"id","transformers.AlbertModel"),u(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"),u(Qn,"href","#transformers.AlbertModel"),u(So,"class","relative group"),u(Nd,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),u(yr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(yr,"rel","nofollow"),u(Wd,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertModel"),u(Bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Kn,"id","transformers.AlbertForPreTraining"),u(Kn,"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"),u(Kn,"href","#transformers.AlbertForPreTraining"),u(Do,"class","relative group"),u(qd,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),u($r,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u($r,"rel","nofollow"),u(Pd,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertForPreTraining"),u(Gt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(os,"id","transformers.AlbertForMaskedLM"),u(os,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(os,"href","#transformers.AlbertForMaskedLM"),u(Ho,"class","relative group"),u(Zd,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),u(zr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(zr,"rel","nofollow"),u(Bd,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertForMaskedLM"),u(wt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(gt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(rs,"id","transformers.AlbertForSequenceClassification"),u(rs,"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"),u(rs,"href","#transformers.AlbertForSequenceClassification"),u(Ko,"class","relative group"),u(Gd,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),u(qr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(qr,"rel","nofollow"),u(Rd,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertForSequenceClassification"),u(vt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(_t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(cs,"id","transformers.AlbertForMultipleChoice"),u(cs,"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"),u(cs,"href","#transformers.AlbertForMultipleChoice"),u(tn,"class","relative group"),u(Vd,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),u(Vr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(Vr,"rel","nofollow"),u(Xd,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertForMultipleChoice"),u(Rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ms,"id","transformers.AlbertForTokenClassification"),u(ms,"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"),u(ms,"href","#transformers.AlbertForTokenClassification"),u(nn,"class","relative group"),u(Sd,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),u(Qr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(Qr,"rel","nofollow"),u(Ld,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertForTokenClassification"),u(Vt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(yt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(gs,"id","transformers.AlbertForQuestionAnswering"),u(gs,"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"),u(gs,"href","#transformers.AlbertForQuestionAnswering"),u(an,"class","relative group"),u(Dd,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),u(ol,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(ol,"rel","nofollow"),u(Od,"href","/docs/transformers/main/en/model_doc/albert#transformers.AlbertForQuestionAnswering"),u(Xt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ys,"id","transformers.TFAlbertModel"),u(ys,"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"),u(ys,"href","#transformers.TFAlbertModel"),u(dn,"class","relative group"),u(Qd,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),u(il,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(il,"rel","nofollow"),u(Hd,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertModel"),u(St,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(lt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(vs,"id","transformers.TFAlbertForPreTraining"),u(vs,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(vs,"href","#transformers.TFAlbertForPreTraining"),u(pn,"class","relative group"),u(Yd,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),u(ul,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(ul,"rel","nofollow"),u(Kd,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertForPreTraining"),u(Lt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(it,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(As,"id","transformers.TFAlbertForMaskedLM"),u(As,"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"),u(As,"href","#transformers.TFAlbertForMaskedLM"),u(un,"class","relative group"),u(ec,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),u(kl,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(kl,"rel","nofollow"),u(tc,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertForMaskedLM"),u(Mt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(zs,"id","transformers.TFAlbertForSequenceClassification"),u(zs,"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"),u(zs,"href","#transformers.TFAlbertForSequenceClassification"),u(gn,"class","relative group"),u(oc,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),u(Al,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(Al,"rel","nofollow"),u(nc,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertForSequenceClassification"),u($t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ct,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Ws,"id","transformers.TFAlbertForMultipleChoice"),u(Ws,"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"),u(Ws,"href","#transformers.TFAlbertForMultipleChoice"),u(bn,"class","relative group"),u(sc,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),u(Cl,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(Cl,"rel","nofollow"),u(ac,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertForMultipleChoice"),u(Dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Bs,"id","transformers.TFAlbertForTokenClassification"),u(Bs,"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"),u(Bs,"href","#transformers.TFAlbertForTokenClassification"),u(Tn,"class","relative group"),u(rc,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),u(Pl,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(Pl,"rel","nofollow"),u(lc,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertForTokenClassification"),u(Ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Ss,"id","transformers.TFAlbertForQuestionAnswering"),u(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"),u(Ss,"href","#transformers.TFAlbertForQuestionAnswering"),u(wn,"class","relative group"),u(ic,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),u(Xl,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(Xl,"rel","nofollow"),u(dc,"href","/docs/transformers/main/en/model_doc/albert#transformers.TFAlbertForQuestionAnswering"),u(At,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(mt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Hs,"id","transformers.FlaxAlbertModel"),u(Hs,"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"),u(Hs,"href","#transformers.FlaxAlbertModel"),u($n,"class","relative group"),u(cc,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(Hl,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),u(Hl,"rel","nofollow"),u(Yl,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(Yl,"rel","nofollow"),u(Kl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(Kl,"rel","nofollow"),u(ei,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(ei,"rel","nofollow"),u(ti,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(ti,"rel","nofollow"),u(Ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(et,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ea,"id","transformers.FlaxAlbertForPreTraining"),u(ea,"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"),u(ea,"href","#transformers.FlaxAlbertForPreTraining"),u(An,"class","relative group"),u(pc,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(li,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),u(li,"rel","nofollow"),u(ii,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(ii,"rel","nofollow"),u(di,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(di,"rel","nofollow"),u(ci,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(ci,"rel","nofollow"),u(pi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(pi,"rel","nofollow"),u(Qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(na,"id","transformers.FlaxAlbertForMaskedLM"),u(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"),u(na,"href","#transformers.FlaxAlbertForMaskedLM"),u(xn,"class","relative group"),u(hc,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(bi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),u(bi,"rel","nofollow"),u(yi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(yi,"rel","nofollow"),u(Ti,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(Ti,"rel","nofollow"),u(ki,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(ki,"rel","nofollow"),u(wi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(wi,"rel","nofollow"),u(Ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ra,"id","transformers.FlaxAlbertForSequenceClassification"),u(ra,"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"),u(ra,"href","#transformers.FlaxAlbertForSequenceClassification"),u(zn,"class","relative group"),u(mc,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(Ei,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),u(Ei,"rel","nofollow"),u(ji,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(ji,"rel","nofollow"),u(xi,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(xi,"rel","nofollow"),u(Ji,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(Ji,"rel","nofollow"),u(zi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(zi,"rel","nofollow"),u(Yt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(nt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(da,"id","transformers.FlaxAlbertForMultipleChoice"),u(da,"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"),u(da,"href","#transformers.FlaxAlbertForMultipleChoice"),u(Un,"class","relative group"),u(uc,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(qi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),u(qi,"rel","nofollow"),u(Pi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(Pi,"rel","nofollow"),u(Zi,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(Zi,"rel","nofollow"),u(Bi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(Bi,"rel","nofollow"),u(Gi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(Gi,"rel","nofollow"),u(Kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(st,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ha,"id","transformers.FlaxAlbertForTokenClassification"),u(ha,"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"),u(ha,"href","#transformers.FlaxAlbertForTokenClassification"),u(Nn,"class","relative group"),u(fc,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(Di,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),u(Di,"rel","nofollow"),u(Oi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(Oi,"rel","nofollow"),u(Qi,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(Qi,"rel","nofollow"),u(Hi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(Hi,"rel","nofollow"),u(Yi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(Yi,"rel","nofollow"),u(eo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(at,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(fa,"id","transformers.FlaxAlbertForQuestionAnswering"),u(fa,"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"),u(fa,"href","#transformers.FlaxAlbertForQuestionAnswering"),u(qn,"class","relative group"),u(gc,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(sd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),u(sd,"rel","nofollow"),u(ad,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(ad,"rel","nofollow"),u(rd,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(rd,"rel","nofollow"),u(ld,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(ld,"rel","nofollow"),u(id,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(id,"rel","nofollow"),u(to,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(o,_){e(document.head,d),g(o,y,_),g(o,m,_),e(m,f),e(f,b),v(i,b,null),e(m,h),e(m,j),e(j,Me),g(o,ye,_),g(o,B,_),e(B,de),e(de,K),e(B,$e),e(B,V),e(V,ce),g(o,O,_),g(o,se,_),e(se,ae),e(ae,X),v(le,X,null),e(se,Fe),e(se,S),e(S,Ae),g(o,Te,_),g(o,G,_),e(G,Ee),e(G,ie),e(ie,ee),e(G,z),g(o,U,_),g(o,re,_),e(re,L),e(L,je),e(re,xe),e(re,D),e(D,Je),g(o,ke,_),g(o,C,_),e(C,ze),g(o,Q,_),g(o,pe,_),e(pe,me),e(me,Y),g(o,we,_),g(o,he,_),e(he,P),g(o,ve,_),g(o,W,_),e(W,ue),e(ue,te),e(W,I),e(W,fe),e(fe,N),e(W,Ce),e(W,ge),e(ge,T),e(W,x),e(W,Xe),e(Xe,oe),g(o,Le,_),g(o,_e,_),e(_e,J),e(_e,Ze),e(Ze,De),e(_e,Oe),e(_e,Be),e(Be,Qe),e(_e,Z),e(_e,R),e(R,He),e(_e,Ye),g(o,H,_),g(o,Ie,_),e(Ie,Pe),e(Pe,be),v(Ge,be,null),e(Ie,ne),e(Ie,Se),e(Se,n_),g(o,Cu,_),g(o,kt,_),e(kt,Lc),e(Lc,bd),e(bd,s_),e(kt,a_),e(kt,Dc),e(Dc,yd),e(yd,r_),e(kt,l_),e(kt,Oc),e(Oc,Td),e(Td,i_),e(kt,d_),e(kt,Qc),e(Qc,kd),e(kd,c_),e(kt,p_),e(kt,Hc),e(Hc,wd),e(wd,h_),g(o,Uu,_),g(o,qo,_),e(qo,Gn),e(Gn,Yc),v(Va,Yc,null),e(qo,m_),e(qo,Kc),e(Kc,u_),g(o,Iu,_),g(o,Nt,_),v(Xa,Nt,null),e(Nt,f_),e(Nt,co),e(co,g_),e(co,vd),e(vd,__),e(co,b_),e(co,Md),e(Md,y_),e(co,T_),e(co,Sa),e(Sa,k_),e(co,w_),e(Nt,v_),e(Nt,Po),e(Po,M_),e(Po,$d),e($d,$_),e(Po,F_),e(Po,Fd),e(Fd,A_),e(Po,E_),e(Nt,j_),v(Rn,Nt,null),g(o,Nu,_),g(o,Zo,_),e(Zo,Vn),e(Vn,ep),v(La,ep,null),e(Zo,x_),e(Zo,tp),e(tp,J_),g(o,Wu,_),g(o,Ke,_),v(Da,Ke,null),e(Ke,z_),e(Ke,Oa),e(Oa,C_),e(Oa,Qa),e(Qa,U_),e(Oa,I_),e(Ke,N_),e(Ke,Ha),e(Ha,W_),e(Ha,Ad),e(Ad,q_),e(Ha,P_),e(Ke,Z_),e(Ke,vo),v(Ya,vo,null),e(vo,B_),e(vo,op),e(op,G_),e(vo,R_),e(vo,Ka),e(Ka,Ed),e(Ed,V_),e(Ed,np),e(np,X_),e(Ka,S_),e(Ka,jd),e(jd,L_),e(jd,sp),e(sp,D_),e(Ke,O_),e(Ke,Xn),v(er,Xn,null),e(Xn,Q_),e(Xn,tr),e(tr,H_),e(tr,ap),e(ap,Y_),e(tr,K_),e(Ke,eb),e(Ke,Pt),v(or,Pt,null),e(Pt,tb),e(Pt,rp),e(rp,ob),e(Pt,nb),v(Sn,Pt,null),e(Pt,sb),e(Pt,Bo),e(Bo,ab),e(Bo,lp),e(lp,rb),e(Bo,lb),e(Bo,ip),e(ip,ib),e(Bo,db),e(Ke,cb),e(Ke,xd),v(nr,xd,null),g(o,qu,_),g(o,Go,_),e(Go,Ln),e(Ln,dp),v(sr,dp,null),e(Go,pb),e(Go,cp),e(cp,hb),g(o,Pu,_),g(o,Wt,_),v(ar,Wt,null),e(Wt,mb),e(Wt,po),e(po,ub),e(po,pp),e(pp,fb),e(po,gb),e(po,rr),e(rr,_b),e(po,bb),e(po,Jd),e(Jd,yb),e(po,Tb),e(Wt,kb),e(Wt,Mo),v(lr,Mo,null),e(Mo,wb),e(Mo,hp),e(hp,vb),e(Mo,Mb),e(Mo,ir),e(ir,zd),e(zd,$b),e(zd,mp),e(mp,Fb),e(ir,Ab),e(ir,Cd),e(Cd,Eb),e(Cd,up),e(up,jb),e(Wt,xb),e(Wt,Zt),v(dr,Zt,null),e(Zt,Jb),e(Zt,fp),e(fp,zb),e(Zt,Cb),v(Dn,Zt,null),e(Zt,Ub),e(Zt,gp),e(gp,Ib),g(o,Zu,_),g(o,Ro,_),e(Ro,On),e(On,_p),v(cr,_p,null),e(Ro,Nb),e(Ro,bp),e(bp,Wb),g(o,Bu,_),g(o,Vo,_),v(pr,Vo,null),e(Vo,qb),e(Vo,hr),e(hr,Pb),e(hr,Ud),e(Ud,Zb),e(hr,Bb),g(o,Gu,_),g(o,Xo,_),v(mr,Xo,null),e(Xo,Gb),e(Xo,ur),e(ur,Rb),e(ur,Id),e(Id,Vb),e(ur,Xb),g(o,Ru,_),g(o,So,_),e(So,Qn),e(Qn,yp),v(fr,yp,null),e(So,Sb),e(So,Tp),e(Tp,Lb),g(o,Vu,_),g(o,ut,_),v(gr,ut,null),e(ut,Db),e(ut,kp),e(kp,Ob),e(ut,Qb),e(ut,_r),e(_r,Hb),e(_r,Nd),e(Nd,Yb),e(_r,Kb),e(ut,ey),e(ut,br),e(br,ty),e(br,yr),e(yr,oy),e(br,ny),e(ut,sy),e(ut,Bt),v(Tr,Bt,null),e(Bt,ay),e(Bt,Lo),e(Lo,ry),e(Lo,Wd),e(Wd,ly),e(Lo,iy),e(Lo,wp),e(wp,dy),e(Lo,cy),e(Bt,py),v(Hn,Bt,null),e(Bt,hy),v(Yn,Bt,null),g(o,Xu,_),g(o,Do,_),e(Do,Kn),e(Kn,vp),v(kr,vp,null),e(Do,my),e(Do,Mp),e(Mp,uy),g(o,Su,_),g(o,ft,_),v(wr,ft,null),e(ft,fy),e(ft,Oo),e(Oo,gy),e(Oo,$p),e($p,_y),e(Oo,by),e(Oo,Fp),e(Fp,yy),e(Oo,Ty),e(ft,ky),e(ft,vr),e(vr,wy),e(vr,qd),e(qd,vy),e(vr,My),e(ft,$y),e(ft,Mr),e(Mr,Fy),e(Mr,$r),e($r,Ay),e(Mr,Ey),e(ft,jy),e(ft,Gt),v(Fr,Gt,null),e(Gt,xy),e(Gt,Qo),e(Qo,Jy),e(Qo,Pd),e(Pd,zy),e(Qo,Cy),e(Qo,Ap),e(Ap,Uy),e(Qo,Iy),e(Gt,Ny),v(es,Gt,null),e(Gt,Wy),v(ts,Gt,null),g(o,Lu,_),g(o,Ho,_),e(Ho,os),e(os,Ep),v(Ar,Ep,null),e(Ho,qy),e(Ho,jp),e(jp,Py),g(o,Du,_),g(o,gt,_),v(Er,gt,null),e(gt,Zy),e(gt,jr),e(jr,By),e(jr,xp),e(xp,Gy),e(jr,Ry),e(gt,Vy),e(gt,xr),e(xr,Xy),e(xr,Zd),e(Zd,Sy),e(xr,Ly),e(gt,Dy),e(gt,Jr),e(Jr,Oy),e(Jr,zr),e(zr,Qy),e(Jr,Hy),e(gt,Yy),e(gt,wt),v(Cr,wt,null),e(wt,Ky),e(wt,Yo),e(Yo,eT),e(Yo,Bd),e(Bd,tT),e(Yo,oT),e(Yo,Jp),e(Jp,nT),e(Yo,sT),e(wt,aT),v(ns,wt,null),e(wt,rT),v(ss,wt,null),e(wt,lT),v(as,wt,null),g(o,Ou,_),g(o,Ko,_),e(Ko,rs),e(rs,zp),v(Ur,zp,null),e(Ko,iT),e(Ko,Cp),e(Cp,dT),g(o,Qu,_),g(o,_t,_),v(Ir,_t,null),e(_t,cT),e(_t,Up),e(Up,pT),e(_t,hT),e(_t,Nr),e(Nr,mT),e(Nr,Gd),e(Gd,uT),e(Nr,fT),e(_t,gT),e(_t,Wr),e(Wr,_T),e(Wr,qr),e(qr,bT),e(Wr,yT),e(_t,TT),e(_t,vt),v(Pr,vt,null),e(vt,kT),e(vt,en),e(en,wT),e(en,Rd),e(Rd,vT),e(en,MT),e(en,Ip),e(Ip,$T),e(en,FT),e(vt,AT),v(ls,vt,null),e(vt,ET),v(is,vt,null),e(vt,jT),v(ds,vt,null),g(o,Hu,_),g(o,tn,_),e(tn,cs),e(cs,Np),v(Zr,Np,null),e(tn,xT),e(tn,Wp),e(Wp,JT),g(o,Yu,_),g(o,bt,_),v(Br,bt,null),e(bt,zT),e(bt,qp),e(qp,CT),e(bt,UT),e(bt,Gr),e(Gr,IT),e(Gr,Vd),e(Vd,NT),e(Gr,WT),e(bt,qT),e(bt,Rr),e(Rr,PT),e(Rr,Vr),e(Vr,ZT),e(Rr,BT),e(bt,GT),e(bt,Rt),v(Xr,Rt,null),e(Rt,RT),e(Rt,on),e(on,VT),e(on,Xd),e(Xd,XT),e(on,ST),e(on,Pp),e(Pp,LT),e(on,DT),e(Rt,OT),v(ps,Rt,null),e(Rt,QT),v(hs,Rt,null),g(o,Ku,_),g(o,nn,_),e(nn,ms),e(ms,Zp),v(Sr,Zp,null),e(nn,HT),e(nn,Bp),e(Bp,YT),g(o,ef,_),g(o,yt,_),v(Lr,yt,null),e(yt,KT),e(yt,Gp),e(Gp,ek),e(yt,tk),e(yt,Dr),e(Dr,ok),e(Dr,Sd),e(Sd,nk),e(Dr,sk),e(yt,ak),e(yt,Or),e(Or,rk),e(Or,Qr),e(Qr,lk),e(Or,ik),e(yt,dk),e(yt,Vt),v(Hr,Vt,null),e(Vt,ck),e(Vt,sn),e(sn,pk),e(sn,Ld),e(Ld,hk),e(sn,mk),e(sn,Rp),e(Rp,uk),e(sn,fk),e(Vt,gk),v(us,Vt,null),e(Vt,_k),v(fs,Vt,null),g(o,tf,_),g(o,an,_),e(an,gs),e(gs,Vp),v(Yr,Vp,null),e(an,bk),e(an,Xp),e(Xp,yk),g(o,of,_),g(o,Tt,_),v(Kr,Tt,null),e(Tt,Tk),e(Tt,rn),e(rn,kk),e(rn,Sp),e(Sp,wk),e(rn,vk),e(rn,Lp),e(Lp,Mk),e(rn,$k),e(Tt,Fk),e(Tt,el),e(el,Ak),e(el,Dd),e(Dd,Ek),e(el,jk),e(Tt,xk),e(Tt,tl),e(tl,Jk),e(tl,ol),e(ol,zk),e(tl,Ck),e(Tt,Uk),e(Tt,Xt),v(nl,Xt,null),e(Xt,Ik),e(Xt,ln),e(ln,Nk),e(ln,Od),e(Od,Wk),e(ln,qk),e(ln,Dp),e(Dp,Pk),e(ln,Zk),e(Xt,Bk),v(_s,Xt,null),e(Xt,Gk),v(bs,Xt,null),g(o,nf,_),g(o,dn,_),e(dn,ys),e(ys,Op),v(sl,Op,null),e(dn,Rk),e(dn,Qp),e(Qp,Vk),g(o,sf,_),g(o,lt,_),v(al,lt,null),e(lt,Xk),e(lt,Hp),e(Hp,Sk),e(lt,Lk),e(lt,rl),e(rl,Dk),e(rl,Qd),e(Qd,Ok),e(rl,Qk),e(lt,Hk),e(lt,ll),e(ll,Yk),e(ll,il),e(il,Kk),e(ll,ew),e(lt,tw),v(Ts,lt,null),e(lt,ow),e(lt,St),v(dl,St,null),e(St,nw),e(St,cn),e(cn,sw),e(cn,Hd),e(Hd,aw),e(cn,rw),e(cn,Yp),e(Yp,lw),e(cn,iw),e(St,dw),v(ks,St,null),e(St,cw),v(ws,St,null),g(o,af,_),g(o,pn,_),e(pn,vs),e(vs,Kp),v(cl,Kp,null),e(pn,pw),e(pn,eh),e(eh,hw),g(o,rf,_),g(o,it,_),v(pl,it,null),e(it,mw),e(it,hn),e(hn,uw),e(hn,th),e(th,fw),e(hn,gw),e(hn,oh),e(oh,_w),e(hn,bw),e(it,yw),e(it,hl),e(hl,Tw),e(hl,Yd),e(Yd,kw),e(hl,ww),e(it,vw),e(it,ml),e(ml,Mw),e(ml,ul),e(ul,$w),e(ml,Fw),e(it,Aw),v(Ms,it,null),e(it,Ew),e(it,Lt),v(fl,Lt,null),e(Lt,jw),e(Lt,mn),e(mn,xw),e(mn,Kd),e(Kd,Jw),e(mn,zw),e(mn,nh),e(nh,Cw),e(mn,Uw),e(Lt,Iw),v($s,Lt,null),e(Lt,Nw),v(Fs,Lt,null),g(o,lf,_),g(o,un,_),e(un,As),e(As,sh),v(gl,sh,null),e(un,Ww),e(un,ah),e(ah,qw),g(o,df,_),g(o,dt,_),v(_l,dt,null),e(dt,Pw),e(dt,bl),e(bl,Zw),e(bl,rh),e(rh,Bw),e(bl,Gw),e(dt,Rw),e(dt,yl),e(yl,Vw),e(yl,ec),e(ec,Xw),e(yl,Sw),e(dt,Lw),e(dt,Tl),e(Tl,Dw),e(Tl,kl),e(kl,Ow),e(Tl,Qw),e(dt,Hw),v(Es,dt,null),e(dt,Yw),e(dt,Mt),v(wl,Mt,null),e(Mt,Kw),e(Mt,fn),e(fn,ev),e(fn,tc),e(tc,tv),e(fn,ov),e(fn,lh),e(lh,nv),e(fn,sv),e(Mt,av),v(js,Mt,null),e(Mt,rv),v(xs,Mt,null),e(Mt,lv),v(Js,Mt,null),g(o,cf,_),g(o,gn,_),e(gn,zs),e(zs,ih),v(vl,ih,null),e(gn,iv),e(gn,dh),e(dh,dv),g(o,pf,_),g(o,ct,_),v(Ml,ct,null),e(ct,cv),e(ct,ch),e(ch,pv),e(ct,hv),e(ct,$l),e($l,mv),e($l,oc),e(oc,uv),e($l,fv),e(ct,gv),e(ct,Fl),e(Fl,_v),e(Fl,Al),e(Al,bv),e(Fl,yv),e(ct,Tv),v(Cs,ct,null),e(ct,kv),e(ct,$t),v(El,$t,null),e($t,wv),e($t,_n),e(_n,vv),e(_n,nc),e(nc,Mv),e(_n,$v),e(_n,ph),e(ph,Fv),e(_n,Av),e($t,Ev),v(Us,$t,null),e($t,jv),v(Is,$t,null),e($t,xv),v(Ns,$t,null),g(o,hf,_),g(o,bn,_),e(bn,Ws),e(Ws,hh),v(jl,hh,null),e(bn,Jv),e(bn,mh),e(mh,zv),g(o,mf,_),g(o,pt,_),v(xl,pt,null),e(pt,Cv),e(pt,uh),e(uh,Uv),e(pt,Iv),e(pt,Jl),e(Jl,Nv),e(Jl,sc),e(sc,Wv),e(Jl,qv),e(pt,Pv),e(pt,zl),e(zl,Zv),e(zl,Cl),e(Cl,Bv),e(zl,Gv),e(pt,Rv),v(qs,pt,null),e(pt,Vv),e(pt,Dt),v(Ul,Dt,null),e(Dt,Xv),e(Dt,yn),e(yn,Sv),e(yn,ac),e(ac,Lv),e(yn,Dv),e(yn,fh),e(fh,Ov),e(yn,Qv),e(Dt,Hv),v(Ps,Dt,null),e(Dt,Yv),v(Zs,Dt,null),g(o,uf,_),g(o,Tn,_),e(Tn,Bs),e(Bs,gh),v(Il,gh,null),e(Tn,Kv),e(Tn,_h),e(_h,eM),g(o,ff,_),g(o,ht,_),v(Nl,ht,null),e(ht,tM),e(ht,bh),e(bh,oM),e(ht,nM),e(ht,Wl),e(Wl,sM),e(Wl,rc),e(rc,aM),e(Wl,rM),e(ht,lM),e(ht,ql),e(ql,iM),e(ql,Pl),e(Pl,dM),e(ql,cM),e(ht,pM),v(Gs,ht,null),e(ht,hM),e(ht,Ft),v(Zl,Ft,null),e(Ft,mM),e(Ft,kn),e(kn,uM),e(kn,lc),e(lc,fM),e(kn,gM),e(kn,yh),e(yh,_M),e(kn,bM),e(Ft,yM),v(Rs,Ft,null),e(Ft,TM),v(Vs,Ft,null),e(Ft,kM),v(Xs,Ft,null),g(o,gf,_),g(o,wn,_),e(wn,Ss),e(Ss,Th),v(Bl,Th,null),e(wn,wM),e(wn,kh),e(kh,vM),g(o,_f,_),g(o,mt,_),v(Gl,mt,null),e(mt,MM),e(mt,vn),e(vn,$M),e(vn,wh),e(wh,FM),e(vn,AM),e(vn,vh),e(vh,EM),e(vn,jM),e(mt,xM),e(mt,Rl),e(Rl,JM),e(Rl,ic),e(ic,zM),e(Rl,CM),e(mt,UM),e(mt,Vl),e(Vl,IM),e(Vl,Xl),e(Xl,NM),e(Vl,WM),e(mt,qM),v(Ls,mt,null),e(mt,PM),e(mt,At),v(Sl,At,null),e(At,ZM),e(At,Mn),e(Mn,BM),e(Mn,dc),e(dc,GM),e(Mn,RM),e(Mn,Mh),e(Mh,VM),e(Mn,XM),e(At,SM),v(Ds,At,null),e(At,LM),v(Os,At,null),e(At,DM),v(Qs,At,null),g(o,bf,_),g(o,$n,_),e($n,Hs),e(Hs,$h),v(Ll,$h,null),e($n,OM),e($n,Fh),e(Fh,QM),g(o,yf,_),g(o,et,_),v(Dl,et,null),e(et,HM),e(et,Ah),e(Ah,YM),e(et,KM),e(et,Ol),e(Ol,e2),e(Ol,cc),e(cc,t2),e(Ol,o2),e(et,n2),e(et,Ql),e(Ql,s2),e(Ql,Hl),e(Hl,a2),e(Ql,r2),e(et,l2),e(et,Eh),e(Eh,i2),e(et,d2),e(et,ho),e(ho,jh),e(jh,Yl),e(Yl,c2),e(ho,p2),e(ho,xh),e(xh,Kl),e(Kl,h2),e(ho,m2),e(ho,Jh),e(Jh,ei),e(ei,u2),e(ho,f2),e(ho,zh),e(zh,ti),e(ti,g2),e(et,_2),e(et,Ot),v(oi,Ot,null),e(Ot,b2),e(Ot,Fn),e(Fn,y2),e(Fn,Ch),e(Ch,T2),e(Fn,k2),e(Fn,Uh),e(Uh,w2),e(Fn,v2),e(Ot,M2),v(Ys,Ot,null),e(Ot,$2),v(Ks,Ot,null),g(o,Tf,_),g(o,An,_),e(An,ea),e(ea,Ih),v(ni,Ih,null),e(An,F2),e(An,Nh),e(Nh,A2),g(o,kf,_),g(o,tt,_),v(si,tt,null),e(tt,E2),e(tt,En),e(En,j2),e(En,Wh),e(Wh,x2),e(En,J2),e(En,qh),e(qh,z2),e(En,C2),e(tt,U2),e(tt,ai),e(ai,I2),e(ai,pc),e(pc,N2),e(ai,W2),e(tt,q2),e(tt,ri),e(ri,P2),e(ri,li),e(li,Z2),e(ri,B2),e(tt,G2),e(tt,Ph),e(Ph,R2),e(tt,V2),e(tt,mo),e(mo,Zh),e(Zh,ii),e(ii,X2),e(mo,S2),e(mo,Bh),e(Bh,di),e(di,L2),e(mo,D2),e(mo,Gh),e(Gh,ci),e(ci,O2),e(mo,Q2),e(mo,Rh),e(Rh,pi),e(pi,H2),e(tt,Y2),e(tt,Qt),v(hi,Qt,null),e(Qt,K2),e(Qt,jn),e(jn,e1),e(jn,Vh),e(Vh,t1),e(jn,o1),e(jn,Xh),e(Xh,n1),e(jn,s1),e(Qt,a1),v(ta,Qt,null),e(Qt,r1),v(oa,Qt,null),g(o,wf,_),g(o,xn,_),e(xn,na),e(na,Sh),v(mi,Sh,null),e(xn,l1),e(xn,Lh),e(Lh,i1),g(o,vf,_),g(o,ot,_),v(ui,ot,null),e(ot,d1),e(ot,fi),e(fi,c1),e(fi,Dh),e(Dh,p1),e(fi,h1),e(ot,m1),e(ot,gi),e(gi,u1),e(gi,hc),e(hc,f1),e(gi,g1),e(ot,_1),e(ot,_i),e(_i,b1),e(_i,bi),e(bi,y1),e(_i,T1),e(ot,k1),e(ot,Oh),e(Oh,w1),e(ot,v1),e(ot,uo),e(uo,Qh),e(Qh,yi),e(yi,M1),e(uo,$1),e(uo,Hh),e(Hh,Ti),e(Ti,F1),e(uo,A1),e(uo,Yh),e(Yh,ki),e(ki,E1),e(uo,j1),e(uo,Kh),e(Kh,wi),e(wi,x1),e(ot,J1),e(ot,Ht),v(vi,Ht,null),e(Ht,z1),e(Ht,Jn),e(Jn,C1),e(Jn,em),e(em,U1),e(Jn,I1),e(Jn,tm),e(tm,N1),e(Jn,W1),e(Ht,q1),v(sa,Ht,null),e(Ht,P1),v(aa,Ht,null),g(o,Mf,_),g(o,zn,_),e(zn,ra),e(ra,om),v(Mi,om,null),e(zn,Z1),e(zn,nm),e(nm,B1),g(o,$f,_),g(o,nt,_),v($i,nt,null),e(nt,G1),e(nt,sm),e(sm,R1),e(nt,V1),e(nt,Fi),e(Fi,X1),e(Fi,mc),e(mc,S1),e(Fi,L1),e(nt,D1),e(nt,Ai),e(Ai,O1),e(Ai,Ei),e(Ei,Q1),e(Ai,H1),e(nt,Y1),e(nt,am),e(am,K1),e(nt,e$),e(nt,fo),e(fo,rm),e(rm,ji),e(ji,t$),e(fo,o$),e(fo,lm),e(lm,xi),e(xi,n$),e(fo,s$),e(fo,im),e(im,Ji),e(Ji,a$),e(fo,r$),e(fo,dm),e(dm,zi),e(zi,l$),e(nt,i$),e(nt,Yt),v(Ci,Yt,null),e(Yt,d$),e(Yt,Cn),e(Cn,c$),e(Cn,cm),e(cm,p$),e(Cn,h$),e(Cn,pm),e(pm,m$),e(Cn,u$),e(Yt,f$),v(la,Yt,null),e(Yt,g$),v(ia,Yt,null),g(o,Ff,_),g(o,Un,_),e(Un,da),e(da,hm),v(Ui,hm,null),e(Un,_$),e(Un,mm),e(mm,b$),g(o,Af,_),g(o,st,_),v(Ii,st,null),e(st,y$),e(st,um),e(um,T$),e(st,k$),e(st,Ni),e(Ni,w$),e(Ni,uc),e(uc,v$),e(Ni,M$),e(st,$$),e(st,Wi),e(Wi,F$),e(Wi,qi),e(qi,A$),e(Wi,E$),e(st,j$),e(st,fm),e(fm,x$),e(st,J$),e(st,go),e(go,gm),e(gm,Pi),e(Pi,z$),e(go,C$),e(go,_m),e(_m,Zi),e(Zi,U$),e(go,I$),e(go,bm),e(bm,Bi),e(Bi,N$),e(go,W$),e(go,ym),e(ym,Gi),e(Gi,q$),e(st,P$),e(st,Kt),v(Ri,Kt,null),e(Kt,Z$),e(Kt,In),e(In,B$),e(In,Tm),e(Tm,G$),e(In,R$),e(In,km),e(km,V$),e(In,X$),e(Kt,S$),v(ca,Kt,null),e(Kt,L$),v(pa,Kt,null),g(o,Ef,_),g(o,Nn,_),e(Nn,ha),e(ha,wm),v(Vi,wm,null),e(Nn,D$),e(Nn,vm),e(vm,O$),g(o,jf,_),g(o,at,_),v(Xi,at,null),e(at,Q$),e(at,Mm),e(Mm,H$),e(at,Y$),e(at,Si),e(Si,K$),e(Si,fc),e(fc,e0),e(Si,t0),e(at,o0),e(at,Li),e(Li,n0),e(Li,Di),e(Di,s0),e(Li,a0),e(at,r0),e(at,$m),e($m,l0),e(at,i0),e(at,_o),e(_o,Fm),e(Fm,Oi),e(Oi,d0),e(_o,c0),e(_o,Am),e(Am,Qi),e(Qi,p0),e(_o,h0),e(_o,Em),e(Em,Hi),e(Hi,m0),e(_o,u0),e(_o,jm),e(jm,Yi),e(Yi,f0),e(at,g0),e(at,eo),v(Ki,eo,null),e(eo,_0),e(eo,Wn),e(Wn,b0),e(Wn,xm),e(xm,y0),e(Wn,T0),e(Wn,Jm),e(Jm,k0),e(Wn,w0),e(eo,v0),v(ma,eo,null),e(eo,M0),v(ua,eo,null),g(o,xf,_),g(o,qn,_),e(qn,fa),e(fa,zm),v(ed,zm,null),e(qn,$0),e(qn,Cm),e(Cm,F0),g(o,Jf,_),g(o,rt,_),v(td,rt,null),e(rt,A0),e(rt,Pn),e(Pn,E0),e(Pn,Um),e(Um,j0),e(Pn,x0),e(Pn,Im),e(Im,J0),e(Pn,z0),e(rt,C0),e(rt,od),e(od,U0),e(od,gc),e(gc,I0),e(od,N0),e(rt,W0),e(rt,nd),e(nd,q0),e(nd,sd),e(sd,P0),e(nd,Z0),e(rt,B0),e(rt,Nm),e(Nm,G0),e(rt,R0),e(rt,bo),e(bo,Wm),e(Wm,ad),e(ad,V0),e(bo,X0),e(bo,qm),e(qm,rd),e(rd,S0),e(bo,L0),e(bo,Pm),e(Pm,ld),e(ld,D0),e(bo,O0),e(bo,Zm),e(Zm,id),e(id,Q0),e(rt,H0),e(rt,to),v(dd,to,null),e(to,Y0),e(to,Zn),e(Zn,K0),e(Zn,Bm),e(Bm,eF),e(Zn,tF),e(Zn,Gm),e(Gm,oF),e(Zn,nF),e(to,sF),v(ga,to,null),e(to,aF),v(_a,to,null),zf=!0},p(o,[_]){const cd={};_&2&&(cd.$$scope={dirty:_,ctx:o}),Rn.$set(cd);const Rm={};_&2&&(Rm.$$scope={dirty:_,ctx:o}),Sn.$set(Rm);const Vm={};_&2&&(Vm.$$scope={dirty:_,ctx:o}),Dn.$set(Vm);const Xm={};_&2&&(Xm.$$scope={dirty:_,ctx:o}),Hn.$set(Xm);const pd={};_&2&&(pd.$$scope={dirty:_,ctx:o}),Yn.$set(pd);const Sm={};_&2&&(Sm.$$scope={dirty:_,ctx:o}),es.$set(Sm);const Lm={};_&2&&(Lm.$$scope={dirty:_,ctx:o}),ts.$set(Lm);const hd={};_&2&&(hd.$$scope={dirty:_,ctx:o}),ns.$set(hd);const Dm={};_&2&&(Dm.$$scope={dirty:_,ctx:o}),ss.$set(Dm);const Om={};_&2&&(Om.$$scope={dirty:_,ctx:o}),as.$set(Om);const Qm={};_&2&&(Qm.$$scope={dirty:_,ctx:o}),ls.$set(Qm);const md={};_&2&&(md.$$scope={dirty:_,ctx:o}),is.$set(md);const Hm={};_&2&&(Hm.$$scope={dirty:_,ctx:o}),ds.$set(Hm);const ud={};_&2&&(ud.$$scope={dirty:_,ctx:o}),ps.$set(ud);const Ym={};_&2&&(Ym.$$scope={dirty:_,ctx:o}),hs.$set(Ym);const Km={};_&2&&(Km.$$scope={dirty:_,ctx:o}),us.$set(Km);const eu={};_&2&&(eu.$$scope={dirty:_,ctx:o}),fs.$set(eu);const tu={};_&2&&(tu.$$scope={dirty:_,ctx:o}),_s.$set(tu);const ou={};_&2&&(ou.$$scope={dirty:_,ctx:o}),bs.$set(ou);const nu={};_&2&&(nu.$$scope={dirty:_,ctx:o}),Ts.$set(nu);const yo={};_&2&&(yo.$$scope={dirty:_,ctx:o}),ks.$set(yo);const su={};_&2&&(su.$$scope={dirty:_,ctx:o}),ws.$set(su);const au={};_&2&&(au.$$scope={dirty:_,ctx:o}),Ms.$set(au);const ru={};_&2&&(ru.$$scope={dirty:_,ctx:o}),$s.$set(ru);const lu={};_&2&&(lu.$$scope={dirty:_,ctx:o}),Fs.$set(lu);const To={};_&2&&(To.$$scope={dirty:_,ctx:o}),Es.$set(To);const iu={};_&2&&(iu.$$scope={dirty:_,ctx:o}),js.$set(iu);const du={};_&2&&(du.$$scope={dirty:_,ctx:o}),xs.$set(du);const cu={};_&2&&(cu.$$scope={dirty:_,ctx:o}),Js.$set(cu);const fd={};_&2&&(fd.$$scope={dirty:_,ctx:o}),Cs.$set(fd);const pu={};_&2&&(pu.$$scope={dirty:_,ctx:o}),Us.$set(pu);const hu={};_&2&&(hu.$$scope={dirty:_,ctx:o}),Is.$set(hu);const mu={};_&2&&(mu.$$scope={dirty:_,ctx:o}),Ns.$set(mu);const qt={};_&2&&(qt.$$scope={dirty:_,ctx:o}),qs.$set(qt);const uu={};_&2&&(uu.$$scope={dirty:_,ctx:o}),Ps.$set(uu);const fu={};_&2&&(fu.$$scope={dirty:_,ctx:o}),Zs.$set(fu);const gu={};_&2&&(gu.$$scope={dirty:_,ctx:o}),Gs.$set(gu);const _u={};_&2&&(_u.$$scope={dirty:_,ctx:o}),Rs.$set(_u);const bu={};_&2&&(bu.$$scope={dirty:_,ctx:o}),Vs.$set(bu);const yu={};_&2&&(yu.$$scope={dirty:_,ctx:o}),Xs.$set(yu);const Tu={};_&2&&(Tu.$$scope={dirty:_,ctx:o}),Ls.$set(Tu);const ku={};_&2&&(ku.$$scope={dirty:_,ctx:o}),Ds.$set(ku);const wu={};_&2&&(wu.$$scope={dirty:_,ctx:o}),Os.$set(wu);const vu={};_&2&&(vu.$$scope={dirty:_,ctx:o}),Qs.$set(vu);const gd={};_&2&&(gd.$$scope={dirty:_,ctx:o}),Ys.$set(gd);const Mu={};_&2&&(Mu.$$scope={dirty:_,ctx:o}),Ks.$set(Mu);const $u={};_&2&&($u.$$scope={dirty:_,ctx:o}),ta.$set($u);const Fu={};_&2&&(Fu.$$scope={dirty:_,ctx:o}),oa.$set(Fu);const ko={};_&2&&(ko.$$scope={dirty:_,ctx:o}),sa.$set(ko);const wo={};_&2&&(wo.$$scope={dirty:_,ctx:o}),aa.$set(wo);const Au={};_&2&&(Au.$$scope={dirty:_,ctx:o}),la.$set(Au);const Eu={};_&2&&(Eu.$$scope={dirty:_,ctx:o}),ia.$set(Eu);const ju={};_&2&&(ju.$$scope={dirty:_,ctx:o}),ca.$set(ju);const Bn={};_&2&&(Bn.$$scope={dirty:_,ctx:o}),pa.$set(Bn);const xu={};_&2&&(xu.$$scope={dirty:_,ctx:o}),ma.$set(xu);const Ju={};_&2&&(Ju.$$scope={dirty:_,ctx:o}),ua.$set(Ju);const _d={};_&2&&(_d.$$scope={dirty:_,ctx:o}),ga.$set(_d);const zu={};_&2&&(zu.$$scope={dirty:_,ctx:o}),_a.$set(zu)},i(o){zf||(M(i.$$.fragment,o),M(le.$$.fragment,o),M(Ge.$$.fragment,o),M(Va.$$.fragment,o),M(Xa.$$.fragment,o),M(Rn.$$.fragment,o),M(La.$$.fragment,o),M(Da.$$.fragment,o),M(Ya.$$.fragment,o),M(er.$$.fragment,o),M(or.$$.fragment,o),M(Sn.$$.fragment,o),M(nr.$$.fragment,o),M(sr.$$.fragment,o),M(ar.$$.fragment,o),M(lr.$$.fragment,o),M(dr.$$.fragment,o),M(Dn.$$.fragment,o),M(cr.$$.fragment,o),M(pr.$$.fragment,o),M(mr.$$.fragment,o),M(fr.$$.fragment,o),M(gr.$$.fragment,o),M(Tr.$$.fragment,o),M(Hn.$$.fragment,o),M(Yn.$$.fragment,o),M(kr.$$.fragment,o),M(wr.$$.fragment,o),M(Fr.$$.fragment,o),M(es.$$.fragment,o),M(ts.$$.fragment,o),M(Ar.$$.fragment,o),M(Er.$$.fragment,o),M(Cr.$$.fragment,o),M(ns.$$.fragment,o),M(ss.$$.fragment,o),M(as.$$.fragment,o),M(Ur.$$.fragment,o),M(Ir.$$.fragment,o),M(Pr.$$.fragment,o),M(ls.$$.fragment,o),M(is.$$.fragment,o),M(ds.$$.fragment,o),M(Zr.$$.fragment,o),M(Br.$$.fragment,o),M(Xr.$$.fragment,o),M(ps.$$.fragment,o),M(hs.$$.fragment,o),M(Sr.$$.fragment,o),M(Lr.$$.fragment,o),M(Hr.$$.fragment,o),M(us.$$.fragment,o),M(fs.$$.fragment,o),M(Yr.$$.fragment,o),M(Kr.$$.fragment,o),M(nl.$$.fragment,o),M(_s.$$.fragment,o),M(bs.$$.fragment,o),M(sl.$$.fragment,o),M(al.$$.fragment,o),M(Ts.$$.fragment,o),M(dl.$$.fragment,o),M(ks.$$.fragment,o),M(ws.$$.fragment,o),M(cl.$$.fragment,o),M(pl.$$.fragment,o),M(Ms.$$.fragment,o),M(fl.$$.fragment,o),M($s.$$.fragment,o),M(Fs.$$.fragment,o),M(gl.$$.fragment,o),M(_l.$$.fragment,o),M(Es.$$.fragment,o),M(wl.$$.fragment,o),M(js.$$.fragment,o),M(xs.$$.fragment,o),M(Js.$$.fragment,o),M(vl.$$.fragment,o),M(Ml.$$.fragment,o),M(Cs.$$.fragment,o),M(El.$$.fragment,o),M(Us.$$.fragment,o),M(Is.$$.fragment,o),M(Ns.$$.fragment,o),M(jl.$$.fragment,o),M(xl.$$.fragment,o),M(qs.$$.fragment,o),M(Ul.$$.fragment,o),M(Ps.$$.fragment,o),M(Zs.$$.fragment,o),M(Il.$$.fragment,o),M(Nl.$$.fragment,o),M(Gs.$$.fragment,o),M(Zl.$$.fragment,o),M(Rs.$$.fragment,o),M(Vs.$$.fragment,o),M(Xs.$$.fragment,o),M(Bl.$$.fragment,o),M(Gl.$$.fragment,o),M(Ls.$$.fragment,o),M(Sl.$$.fragment,o),M(Ds.$$.fragment,o),M(Os.$$.fragment,o),M(Qs.$$.fragment,o),M(Ll.$$.fragment,o),M(Dl.$$.fragment,o),M(oi.$$.fragment,o),M(Ys.$$.fragment,o),M(Ks.$$.fragment,o),M(ni.$$.fragment,o),M(si.$$.fragment,o),M(hi.$$.fragment,o),M(ta.$$.fragment,o),M(oa.$$.fragment,o),M(mi.$$.fragment,o),M(ui.$$.fragment,o),M(vi.$$.fragment,o),M(sa.$$.fragment,o),M(aa.$$.fragment,o),M(Mi.$$.fragment,o),M($i.$$.fragment,o),M(Ci.$$.fragment,o),M(la.$$.fragment,o),M(ia.$$.fragment,o),M(Ui.$$.fragment,o),M(Ii.$$.fragment,o),M(Ri.$$.fragment,o),M(ca.$$.fragment,o),M(pa.$$.fragment,o),M(Vi.$$.fragment,o),M(Xi.$$.fragment,o),M(Ki.$$.fragment,o),M(ma.$$.fragment,o),M(ua.$$.fragment,o),M(ed.$$.fragment,o),M(td.$$.fragment,o),M(dd.$$.fragment,o),M(ga.$$.fragment,o),M(_a.$$.fragment,o),zf=!0)},o(o){$(i.$$.fragment,o),$(le.$$.fragment,o),$(Ge.$$.fragment,o),$(Va.$$.fragment,o),$(Xa.$$.fragment,o),$(Rn.$$.fragment,o),$(La.$$.fragment,o),$(Da.$$.fragment,o),$(Ya.$$.fragment,o),$(er.$$.fragment,o),$(or.$$.fragment,o),$(Sn.$$.fragment,o),$(nr.$$.fragment,o),$(sr.$$.fragment,o),$(ar.$$.fragment,o),$(lr.$$.fragment,o),$(dr.$$.fragment,o),$(Dn.$$.fragment,o),$(cr.$$.fragment,o),$(pr.$$.fragment,o),$(mr.$$.fragment,o),$(fr.$$.fragment,o),$(gr.$$.fragment,o),$(Tr.$$.fragment,o),$(Hn.$$.fragment,o),$(Yn.$$.fragment,o),$(kr.$$.fragment,o),$(wr.$$.fragment,o),$(Fr.$$.fragment,o),$(es.$$.fragment,o),$(ts.$$.fragment,o),$(Ar.$$.fragment,o),$(Er.$$.fragment,o),$(Cr.$$.fragment,o),$(ns.$$.fragment,o),$(ss.$$.fragment,o),$(as.$$.fragment,o),$(Ur.$$.fragment,o),$(Ir.$$.fragment,o),$(Pr.$$.fragment,o),$(ls.$$.fragment,o),$(is.$$.fragment,o),$(ds.$$.fragment,o),$(Zr.$$.fragment,o),$(Br.$$.fragment,o),$(Xr.$$.fragment,o),$(ps.$$.fragment,o),$(hs.$$.fragment,o),$(Sr.$$.fragment,o),$(Lr.$$.fragment,o),$(Hr.$$.fragment,o),$(us.$$.fragment,o),$(fs.$$.fragment,o),$(Yr.$$.fragment,o),$(Kr.$$.fragment,o),$(nl.$$.fragment,o),$(_s.$$.fragment,o),$(bs.$$.fragment,o),$(sl.$$.fragment,o),$(al.$$.fragment,o),$(Ts.$$.fragment,o),$(dl.$$.fragment,o),$(ks.$$.fragment,o),$(ws.$$.fragment,o),$(cl.$$.fragment,o),$(pl.$$.fragment,o),$(Ms.$$.fragment,o),$(fl.$$.fragment,o),$($s.$$.fragment,o),$(Fs.$$.fragment,o),$(gl.$$.fragment,o),$(_l.$$.fragment,o),$(Es.$$.fragment,o),$(wl.$$.fragment,o),$(js.$$.fragment,o),$(xs.$$.fragment,o),$(Js.$$.fragment,o),$(vl.$$.fragment,o),$(Ml.$$.fragment,o),$(Cs.$$.fragment,o),$(El.$$.fragment,o),$(Us.$$.fragment,o),$(Is.$$.fragment,o),$(Ns.$$.fragment,o),$(jl.$$.fragment,o),$(xl.$$.fragment,o),$(qs.$$.fragment,o),$(Ul.$$.fragment,o),$(Ps.$$.fragment,o),$(Zs.$$.fragment,o),$(Il.$$.fragment,o),$(Nl.$$.fragment,o),$(Gs.$$.fragment,o),$(Zl.$$.fragment,o),$(Rs.$$.fragment,o),$(Vs.$$.fragment,o),$(Xs.$$.fragment,o),$(Bl.$$.fragment,o),$(Gl.$$.fragment,o),$(Ls.$$.fragment,o),$(Sl.$$.fragment,o),$(Ds.$$.fragment,o),$(Os.$$.fragment,o),$(Qs.$$.fragment,o),$(Ll.$$.fragment,o),$(Dl.$$.fragment,o),$(oi.$$.fragment,o),$(Ys.$$.fragment,o),$(Ks.$$.fragment,o),$(ni.$$.fragment,o),$(si.$$.fragment,o),$(hi.$$.fragment,o),$(ta.$$.fragment,o),$(oa.$$.fragment,o),$(mi.$$.fragment,o),$(ui.$$.fragment,o),$(vi.$$.fragment,o),$(sa.$$.fragment,o),$(aa.$$.fragment,o),$(Mi.$$.fragment,o),$($i.$$.fragment,o),$(Ci.$$.fragment,o),$(la.$$.fragment,o),$(ia.$$.fragment,o),$(Ui.$$.fragment,o),$(Ii.$$.fragment,o),$(Ri.$$.fragment,o),$(ca.$$.fragment,o),$(pa.$$.fragment,o),$(Vi.$$.fragment,o),$(Xi.$$.fragment,o),$(Ki.$$.fragment,o),$(ma.$$.fragment,o),$(ua.$$.fragment,o),$(ed.$$.fragment,o),$(td.$$.fragment,o),$(dd.$$.fragment,o),$(ga.$$.fragment,o),$(_a.$$.fragment,o),zf=!1},d(o){t(d),o&&t(y),o&&t(m),F(i),o&&t(ye),o&&t(B),o&&t(O),o&&t(se),F(le),o&&t(Te),o&&t(G),o&&t(U),o&&t(re),o&&t(ke),o&&t(C),o&&t(Q),o&&t(pe),o&&t(we),o&&t(he),o&&t(ve),o&&t(W),o&&t(Le),o&&t(_e),o&&t(H),o&&t(Ie),F(Ge),o&&t(Cu),o&&t(kt),o&&t(Uu),o&&t(qo),F(Va),o&&t(Iu),o&&t(Nt),F(Xa),F(Rn),o&&t(Nu),o&&t(Zo),F(La),o&&t(Wu),o&&t(Ke),F(Da),F(Ya),F(er),F(or),F(Sn),F(nr),o&&t(qu),o&&t(Go),F(sr),o&&t(Pu),o&&t(Wt),F(ar),F(lr),F(dr),F(Dn),o&&t(Zu),o&&t(Ro),F(cr),o&&t(Bu),o&&t(Vo),F(pr),o&&t(Gu),o&&t(Xo),F(mr),o&&t(Ru),o&&t(So),F(fr),o&&t(Vu),o&&t(ut),F(gr),F(Tr),F(Hn),F(Yn),o&&t(Xu),o&&t(Do),F(kr),o&&t(Su),o&&t(ft),F(wr),F(Fr),F(es),F(ts),o&&t(Lu),o&&t(Ho),F(Ar),o&&t(Du),o&&t(gt),F(Er),F(Cr),F(ns),F(ss),F(as),o&&t(Ou),o&&t(Ko),F(Ur),o&&t(Qu),o&&t(_t),F(Ir),F(Pr),F(ls),F(is),F(ds),o&&t(Hu),o&&t(tn),F(Zr),o&&t(Yu),o&&t(bt),F(Br),F(Xr),F(ps),F(hs),o&&t(Ku),o&&t(nn),F(Sr),o&&t(ef),o&&t(yt),F(Lr),F(Hr),F(us),F(fs),o&&t(tf),o&&t(an),F(Yr),o&&t(of),o&&t(Tt),F(Kr),F(nl),F(_s),F(bs),o&&t(nf),o&&t(dn),F(sl),o&&t(sf),o&&t(lt),F(al),F(Ts),F(dl),F(ks),F(ws),o&&t(af),o&&t(pn),F(cl),o&&t(rf),o&&t(it),F(pl),F(Ms),F(fl),F($s),F(Fs),o&&t(lf),o&&t(un),F(gl),o&&t(df),o&&t(dt),F(_l),F(Es),F(wl),F(js),F(xs),F(Js),o&&t(cf),o&&t(gn),F(vl),o&&t(pf),o&&t(ct),F(Ml),F(Cs),F(El),F(Us),F(Is),F(Ns),o&&t(hf),o&&t(bn),F(jl),o&&t(mf),o&&t(pt),F(xl),F(qs),F(Ul),F(Ps),F(Zs),o&&t(uf),o&&t(Tn),F(Il),o&&t(ff),o&&t(ht),F(Nl),F(Gs),F(Zl),F(Rs),F(Vs),F(Xs),o&&t(gf),o&&t(wn),F(Bl),o&&t(_f),o&&t(mt),F(Gl),F(Ls),F(Sl),F(Ds),F(Os),F(Qs),o&&t(bf),o&&t($n),F(Ll),o&&t(yf),o&&t(et),F(Dl),F(oi),F(Ys),F(Ks),o&&t(Tf),o&&t(An),F(ni),o&&t(kf),o&&t(tt),F(si),F(hi),F(ta),F(oa),o&&t(wf),o&&t(xn),F(mi),o&&t(vf),o&&t(ot),F(ui),F(vi),F(sa),F(aa),o&&t(Mf),o&&t(zn),F(Mi),o&&t($f),o&&t(nt),F($i),F(Ci),F(la),F(ia),o&&t(Ff),o&&t(Un),F(Ui),o&&t(Af),o&&t(st),F(Ii),F(Ri),F(ca),F(pa),o&&t(Ef),o&&t(Nn),F(Vi),o&&t(jf),o&&t(at),F(Xi),F(Ki),F(ma),F(ua),o&&t(xf),o&&t(qn),F(ed),o&&t(Jf),o&&t(rt),F(td),F(dd),F(ga),F(_a)}}}const gz={local:"albert",sections:[{local:"overview",title:"Overview"},{local:"documentation-resources",title:"Documentation resources"},{local:"transformers.AlbertConfig",title:"AlbertConfig"},{local:"transformers.AlbertTokenizer",title:"AlbertTokenizer"},{local:"transformers.AlbertTokenizerFast",title:"AlbertTokenizerFast"},{local:"transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput",title:"Albert specific outputs"},{local:"transformers.AlbertModel",title:"AlbertModel"},{local:"transformers.AlbertForPreTraining",title:"AlbertForPreTraining"},{local:"transformers.AlbertForMaskedLM",title:"AlbertForMaskedLM"},{local:"transformers.AlbertForSequenceClassification",title:"AlbertForSequenceClassification"},{local:"transformers.AlbertForMultipleChoice",title:"AlbertForMultipleChoice"},{local:"transformers.AlbertForTokenClassification",title:"AlbertForTokenClassification"},{local:"transformers.AlbertForQuestionAnswering",title:"AlbertForQuestionAnswering"},{local:"transformers.TFAlbertModel",title:"TFAlbertModel"},{local:"transformers.TFAlbertForPreTraining",title:"TFAlbertForPreTraining"},{local:"transformers.TFAlbertForMaskedLM",title:"TFAlbertForMaskedLM"},{local:"transformers.TFAlbertForSequenceClassification",title:"TFAlbertForSequenceClassification"},{local:"transformers.TFAlbertForMultipleChoice",title:"TFAlbertForMultipleChoice"},{local:"transformers.TFAlbertForTokenClassification",title:"TFAlbertForTokenClassification"},{local:"transformers.TFAlbertForQuestionAnswering",title:"TFAlbertForQuestionAnswering"},{local:"transformers.FlaxAlbertModel",title:"FlaxAlbertModel"},{local:"transformers.FlaxAlbertForPreTraining",title:"FlaxAlbertForPreTraining"},{local:"transformers.FlaxAlbertForMaskedLM",title:"FlaxAlbertForMaskedLM"},{local:"transformers.FlaxAlbertForSequenceClassification",title:"FlaxAlbertForSequenceClassification"},{local:"transformers.FlaxAlbertForMultipleChoice",title:"FlaxAlbertForMultipleChoice"},{local:"transformers.FlaxAlbertForTokenClassification",title:"FlaxAlbertForTokenClassification"},{local:"transformers.FlaxAlbertForQuestionAnswering",title:"FlaxAlbertForQuestionAnswering"}],title:"ALBERT"};function _z(E){return cJ(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Mz extends rJ{constructor(d){super();lJ(this,d,_z,fz,iJ,{})}}export{Mz as default,gz as metadata};
