import{S as Tz,i as yz,s as wz,e as n,k as l,w as k,t as a,M as Az,c as s,d as t,m as d,a as r,x as v,h as i,b as c,F as e,g as f,y as T,q as y,o as w,B as A}from"../../chunks/vendor-4833417e.js";import{T as ve}from"../../chunks/Tip-fffd6df1.js";import{D as I}from"../../chunks/Docstring-4f315ed9.js";import{C as we}from"../../chunks/CodeBlock-6a3d1b46.js";import{I as Te}from"../../chunks/IconCopyLink-4b81c553.js";import"../../chunks/CopyButton-dacfbfaf.js";function $z(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Fz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function xz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Ez(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Mz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function zz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function qz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Pz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re;return{c(){p=n("p"),F=a("TF 2.0 models accepts two formats as inputs:"),g=l(),b=n("ul"),$=n("li"),_=a("having all inputs as keyword arguments (like PyTorch models), or"),u=l(),x=n("li"),pe=a("having all inputs as a list, tuple or dict in the first positional arguments."),G=l(),M=n("p"),Z=a("This second option is useful when using "),U=n("code"),ee=a("tf.keras.Model.fit"),he=a(` method which currently requires having all the
tensors in the first argument of the model call function: `),B=n("code"),fe=a("model(inputs)"),ae=a("."),J=l(),L=n("p"),te=a(`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),X=l(),z=n("ul"),P=n("li"),Y=a("a single Tensor with "),R=n("code"),me=a("input_ids"),ue=a(" only and nothing else: "),H=n("code"),ge=a("model(inputs_ids)"),ie=l(),q=n("li"),_e=a(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=n("code"),oe=a("model([input_ids, attention_mask])"),se=a(" or "),V=n("code"),le=a("model([input_ids, attention_mask, token_type_ids])"),ne=l(),N=n("li"),de=a(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=n("code"),re=a('model({"input_ids": input_ids, "token_type_ids": token_type_ids})')},l(h){p=s(h,"P",{});var E=r(p);F=i(E,"TF 2.0 models accepts two formats as inputs:"),E.forEach(t),g=d(h),b=s(h,"UL",{});var K=r(b);$=s(K,"LI",{});var Ae=r($);_=i(Ae,"having all inputs as keyword arguments (like PyTorch models), or"),Ae.forEach(t),u=d(K),x=s(K,"LI",{});var ye=r(x);pe=i(ye,"having all inputs as a list, tuple or dict in the first positional arguments."),ye.forEach(t),K.forEach(t),G=d(h),M=s(h,"P",{});var j=r(M);Z=i(j,"This second option is useful when using "),U=s(j,"CODE",{});var $e=r(U);ee=i($e,"tf.keras.Model.fit"),$e.forEach(t),he=i(j,` method which currently requires having all the
tensors in the first argument of the model call function: `),B=s(j,"CODE",{});var ke=r(B);fe=i(ke,"model(inputs)"),ke.forEach(t),ae=i(j,"."),j.forEach(t),J=d(h),L=s(h,"P",{});var Fe=r(L);te=i(Fe,`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),Fe.forEach(t),X=d(h),z=s(h,"UL",{});var D=r(z);P=s(D,"LI",{});var S=r(P);Y=i(S,"a single Tensor with "),R=s(S,"CODE",{});var xe=r(R);me=i(xe,"input_ids"),xe.forEach(t),ue=i(S," only and nothing else: "),H=s(S,"CODE",{});var Ee=r(H);ge=i(Ee,"model(inputs_ids)"),Ee.forEach(t),S.forEach(t),ie=d(D),q=s(D,"LI",{});var W=r(q);_e=i(W,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=s(W,"CODE",{});var Me=r(Q);oe=i(Me,"model([input_ids, attention_mask])"),Me.forEach(t),se=i(W," or "),V=s(W,"CODE",{});var ze=r(V);le=i(ze,"model([input_ids, attention_mask, token_type_ids])"),ze.forEach(t),W.forEach(t),ne=d(D),N=s(D,"LI",{});var ce=r(N);de=i(ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=s(ce,"CODE",{});var be=r(O);re=i(be,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),be.forEach(t),ce.forEach(t),D.forEach(t)},m(h,E){f(h,p,E),e(p,F),f(h,g,E),f(h,b,E),e(b,$),e($,_),e(b,u),e(b,x),e(x,pe),f(h,G,E),f(h,M,E),e(M,Z),e(M,U),e(U,ee),e(M,he),e(M,B),e(B,fe),e(M,ae),f(h,J,E),f(h,L,E),e(L,te),f(h,X,E),f(h,z,E),e(z,P),e(P,Y),e(P,R),e(R,me),e(P,ue),e(P,H),e(H,ge),e(z,ie),e(z,q),e(q,_e),e(q,Q),e(Q,oe),e(q,se),e(q,V),e(V,le),e(z,ne),e(z,N),e(N,de),e(N,O),e(O,re)},d(h){h&&t(p),h&&t(g),h&&t(b),h&&t(G),h&&t(M),h&&t(J),h&&t(L),h&&t(X),h&&t(z)}}}function jz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Cz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re;return{c(){p=n("p"),F=a("TF 2.0 models accepts two formats as inputs:"),g=l(),b=n("ul"),$=n("li"),_=a("having all inputs as keyword arguments (like PyTorch models), or"),u=l(),x=n("li"),pe=a("having all inputs as a list, tuple or dict in the first positional arguments."),G=l(),M=n("p"),Z=a("This second option is useful when using "),U=n("code"),ee=a("tf.keras.Model.fit"),he=a(` method which currently requires having all the
tensors in the first argument of the model call function: `),B=n("code"),fe=a("model(inputs)"),ae=a("."),J=l(),L=n("p"),te=a(`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),X=l(),z=n("ul"),P=n("li"),Y=a("a single Tensor with "),R=n("code"),me=a("input_ids"),ue=a(" only and nothing else: "),H=n("code"),ge=a("model(inputs_ids)"),ie=l(),q=n("li"),_e=a(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=n("code"),oe=a("model([input_ids, attention_mask])"),se=a(" or "),V=n("code"),le=a("model([input_ids, attention_mask, token_type_ids])"),ne=l(),N=n("li"),de=a(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=n("code"),re=a('model({"input_ids": input_ids, "token_type_ids": token_type_ids})')},l(h){p=s(h,"P",{});var E=r(p);F=i(E,"TF 2.0 models accepts two formats as inputs:"),E.forEach(t),g=d(h),b=s(h,"UL",{});var K=r(b);$=s(K,"LI",{});var Ae=r($);_=i(Ae,"having all inputs as keyword arguments (like PyTorch models), or"),Ae.forEach(t),u=d(K),x=s(K,"LI",{});var ye=r(x);pe=i(ye,"having all inputs as a list, tuple or dict in the first positional arguments."),ye.forEach(t),K.forEach(t),G=d(h),M=s(h,"P",{});var j=r(M);Z=i(j,"This second option is useful when using "),U=s(j,"CODE",{});var $e=r(U);ee=i($e,"tf.keras.Model.fit"),$e.forEach(t),he=i(j,` method which currently requires having all the
tensors in the first argument of the model call function: `),B=s(j,"CODE",{});var ke=r(B);fe=i(ke,"model(inputs)"),ke.forEach(t),ae=i(j,"."),j.forEach(t),J=d(h),L=s(h,"P",{});var Fe=r(L);te=i(Fe,`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),Fe.forEach(t),X=d(h),z=s(h,"UL",{});var D=r(z);P=s(D,"LI",{});var S=r(P);Y=i(S,"a single Tensor with "),R=s(S,"CODE",{});var xe=r(R);me=i(xe,"input_ids"),xe.forEach(t),ue=i(S," only and nothing else: "),H=s(S,"CODE",{});var Ee=r(H);ge=i(Ee,"model(inputs_ids)"),Ee.forEach(t),S.forEach(t),ie=d(D),q=s(D,"LI",{});var W=r(q);_e=i(W,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=s(W,"CODE",{});var Me=r(Q);oe=i(Me,"model([input_ids, attention_mask])"),Me.forEach(t),se=i(W," or "),V=s(W,"CODE",{});var ze=r(V);le=i(ze,"model([input_ids, attention_mask, token_type_ids])"),ze.forEach(t),W.forEach(t),ne=d(D),N=s(D,"LI",{});var ce=r(N);de=i(ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=s(ce,"CODE",{});var be=r(O);re=i(be,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),be.forEach(t),ce.forEach(t),D.forEach(t)},m(h,E){f(h,p,E),e(p,F),f(h,g,E),f(h,b,E),e(b,$),e($,_),e(b,u),e(b,x),e(x,pe),f(h,G,E),f(h,M,E),e(M,Z),e(M,U),e(U,ee),e(M,he),e(M,B),e(B,fe),e(M,ae),f(h,J,E),f(h,L,E),e(L,te),f(h,X,E),f(h,z,E),e(z,P),e(P,Y),e(P,R),e(R,me),e(P,ue),e(P,H),e(H,ge),e(z,ie),e(z,q),e(q,_e),e(q,Q),e(Q,oe),e(q,se),e(q,V),e(V,le),e(z,ne),e(z,N),e(N,de),e(N,O),e(O,re)},d(h){h&&t(p),h&&t(g),h&&t(b),h&&t(G),h&&t(M),h&&t(J),h&&t(L),h&&t(X),h&&t(z)}}}function Iz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Lz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re;return{c(){p=n("p"),F=a("TF 2.0 models accepts two formats as inputs:"),g=l(),b=n("ul"),$=n("li"),_=a("having all inputs as keyword arguments (like PyTorch models), or"),u=l(),x=n("li"),pe=a("having all inputs as a list, tuple or dict in the first positional arguments."),G=l(),M=n("p"),Z=a("This second option is useful when using "),U=n("code"),ee=a("tf.keras.Model.fit"),he=a(` method which currently requires having all the
tensors in the first argument of the model call function: `),B=n("code"),fe=a("model(inputs)"),ae=a("."),J=l(),L=n("p"),te=a(`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),X=l(),z=n("ul"),P=n("li"),Y=a("a single Tensor with "),R=n("code"),me=a("input_ids"),ue=a(" only and nothing else: "),H=n("code"),ge=a("model(inputs_ids)"),ie=l(),q=n("li"),_e=a(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=n("code"),oe=a("model([input_ids, attention_mask])"),se=a(" or "),V=n("code"),le=a("model([input_ids, attention_mask, token_type_ids])"),ne=l(),N=n("li"),de=a(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=n("code"),re=a('model({"input_ids": input_ids, "token_type_ids": token_type_ids})')},l(h){p=s(h,"P",{});var E=r(p);F=i(E,"TF 2.0 models accepts two formats as inputs:"),E.forEach(t),g=d(h),b=s(h,"UL",{});var K=r(b);$=s(K,"LI",{});var Ae=r($);_=i(Ae,"having all inputs as keyword arguments (like PyTorch models), or"),Ae.forEach(t),u=d(K),x=s(K,"LI",{});var ye=r(x);pe=i(ye,"having all inputs as a list, tuple or dict in the first positional arguments."),ye.forEach(t),K.forEach(t),G=d(h),M=s(h,"P",{});var j=r(M);Z=i(j,"This second option is useful when using "),U=s(j,"CODE",{});var $e=r(U);ee=i($e,"tf.keras.Model.fit"),$e.forEach(t),he=i(j,` method which currently requires having all the
tensors in the first argument of the model call function: `),B=s(j,"CODE",{});var ke=r(B);fe=i(ke,"model(inputs)"),ke.forEach(t),ae=i(j,"."),j.forEach(t),J=d(h),L=s(h,"P",{});var Fe=r(L);te=i(Fe,`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),Fe.forEach(t),X=d(h),z=s(h,"UL",{});var D=r(z);P=s(D,"LI",{});var S=r(P);Y=i(S,"a single Tensor with "),R=s(S,"CODE",{});var xe=r(R);me=i(xe,"input_ids"),xe.forEach(t),ue=i(S," only and nothing else: "),H=s(S,"CODE",{});var Ee=r(H);ge=i(Ee,"model(inputs_ids)"),Ee.forEach(t),S.forEach(t),ie=d(D),q=s(D,"LI",{});var W=r(q);_e=i(W,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=s(W,"CODE",{});var Me=r(Q);oe=i(Me,"model([input_ids, attention_mask])"),Me.forEach(t),se=i(W," or "),V=s(W,"CODE",{});var ze=r(V);le=i(ze,"model([input_ids, attention_mask, token_type_ids])"),ze.forEach(t),W.forEach(t),ne=d(D),N=s(D,"LI",{});var ce=r(N);de=i(ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=s(ce,"CODE",{});var be=r(O);re=i(be,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),be.forEach(t),ce.forEach(t),D.forEach(t)},m(h,E){f(h,p,E),e(p,F),f(h,g,E),f(h,b,E),e(b,$),e($,_),e(b,u),e(b,x),e(x,pe),f(h,G,E),f(h,M,E),e(M,Z),e(M,U),e(U,ee),e(M,he),e(M,B),e(B,fe),e(M,ae),f(h,J,E),f(h,L,E),e(L,te),f(h,X,E),f(h,z,E),e(z,P),e(P,Y),e(P,R),e(R,me),e(P,ue),e(P,H),e(H,ge),e(z,ie),e(z,q),e(q,_e),e(q,Q),e(Q,oe),e(q,se),e(q,V),e(V,le),e(z,ne),e(z,N),e(N,de),e(N,O),e(O,re)},d(h){h&&t(p),h&&t(g),h&&t(b),h&&t(G),h&&t(M),h&&t(J),h&&t(L),h&&t(X),h&&t(z)}}}function Nz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Dz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re;return{c(){p=n("p"),F=a("TF 2.0 models accepts two formats as inputs:"),g=l(),b=n("ul"),$=n("li"),_=a("having all inputs as keyword arguments (like PyTorch models), or"),u=l(),x=n("li"),pe=a("having all inputs as a list, tuple or dict in the first positional arguments."),G=l(),M=n("p"),Z=a("This second option is useful when using "),U=n("code"),ee=a("tf.keras.Model.fit"),he=a(` method which currently requires having all the
tensors in the first argument of the model call function: `),B=n("code"),fe=a("model(inputs)"),ae=a("."),J=l(),L=n("p"),te=a(`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),X=l(),z=n("ul"),P=n("li"),Y=a("a single Tensor with "),R=n("code"),me=a("input_ids"),ue=a(" only and nothing else: "),H=n("code"),ge=a("model(inputs_ids)"),ie=l(),q=n("li"),_e=a(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=n("code"),oe=a("model([input_ids, attention_mask])"),se=a(" or "),V=n("code"),le=a("model([input_ids, attention_mask, token_type_ids])"),ne=l(),N=n("li"),de=a(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=n("code"),re=a('model({"input_ids": input_ids, "token_type_ids": token_type_ids})')},l(h){p=s(h,"P",{});var E=r(p);F=i(E,"TF 2.0 models accepts two formats as inputs:"),E.forEach(t),g=d(h),b=s(h,"UL",{});var K=r(b);$=s(K,"LI",{});var Ae=r($);_=i(Ae,"having all inputs as keyword arguments (like PyTorch models), or"),Ae.forEach(t),u=d(K),x=s(K,"LI",{});var ye=r(x);pe=i(ye,"having all inputs as a list, tuple or dict in the first positional arguments."),ye.forEach(t),K.forEach(t),G=d(h),M=s(h,"P",{});var j=r(M);Z=i(j,"This second option is useful when using "),U=s(j,"CODE",{});var $e=r(U);ee=i($e,"tf.keras.Model.fit"),$e.forEach(t),he=i(j,` method which currently requires having all the
tensors in the first argument of the model call function: `),B=s(j,"CODE",{});var ke=r(B);fe=i(ke,"model(inputs)"),ke.forEach(t),ae=i(j,"."),j.forEach(t),J=d(h),L=s(h,"P",{});var Fe=r(L);te=i(Fe,`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),Fe.forEach(t),X=d(h),z=s(h,"UL",{});var D=r(z);P=s(D,"LI",{});var S=r(P);Y=i(S,"a single Tensor with "),R=s(S,"CODE",{});var xe=r(R);me=i(xe,"input_ids"),xe.forEach(t),ue=i(S," only and nothing else: "),H=s(S,"CODE",{});var Ee=r(H);ge=i(Ee,"model(inputs_ids)"),Ee.forEach(t),S.forEach(t),ie=d(D),q=s(D,"LI",{});var W=r(q);_e=i(W,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=s(W,"CODE",{});var Me=r(Q);oe=i(Me,"model([input_ids, attention_mask])"),Me.forEach(t),se=i(W," or "),V=s(W,"CODE",{});var ze=r(V);le=i(ze,"model([input_ids, attention_mask, token_type_ids])"),ze.forEach(t),W.forEach(t),ne=d(D),N=s(D,"LI",{});var ce=r(N);de=i(ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=s(ce,"CODE",{});var be=r(O);re=i(be,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),be.forEach(t),ce.forEach(t),D.forEach(t)},m(h,E){f(h,p,E),e(p,F),f(h,g,E),f(h,b,E),e(b,$),e($,_),e(b,u),e(b,x),e(x,pe),f(h,G,E),f(h,M,E),e(M,Z),e(M,U),e(U,ee),e(M,he),e(M,B),e(B,fe),e(M,ae),f(h,J,E),f(h,L,E),e(L,te),f(h,X,E),f(h,z,E),e(z,P),e(P,Y),e(P,R),e(R,me),e(P,ue),e(P,H),e(H,ge),e(z,ie),e(z,q),e(q,_e),e(q,Q),e(Q,oe),e(q,se),e(q,V),e(V,le),e(z,ne),e(z,N),e(N,de),e(N,O),e(O,re)},d(h){h&&t(p),h&&t(g),h&&t(b),h&&t(G),h&&t(M),h&&t(J),h&&t(L),h&&t(X),h&&t(z)}}}function Oz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Sz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re;return{c(){p=n("p"),F=a("TF 2.0 models accepts two formats as inputs:"),g=l(),b=n("ul"),$=n("li"),_=a("having all inputs as keyword arguments (like PyTorch models), or"),u=l(),x=n("li"),pe=a("having all inputs as a list, tuple or dict in the first positional arguments."),G=l(),M=n("p"),Z=a("This second option is useful when using "),U=n("code"),ee=a("tf.keras.Model.fit"),he=a(` method which currently requires having all the
tensors in the first argument of the model call function: `),B=n("code"),fe=a("model(inputs)"),ae=a("."),J=l(),L=n("p"),te=a(`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),X=l(),z=n("ul"),P=n("li"),Y=a("a single Tensor with "),R=n("code"),me=a("input_ids"),ue=a(" only and nothing else: "),H=n("code"),ge=a("model(inputs_ids)"),ie=l(),q=n("li"),_e=a(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=n("code"),oe=a("model([input_ids, attention_mask])"),se=a(" or "),V=n("code"),le=a("model([input_ids, attention_mask, token_type_ids])"),ne=l(),N=n("li"),de=a(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=n("code"),re=a('model({"input_ids": input_ids, "token_type_ids": token_type_ids})')},l(h){p=s(h,"P",{});var E=r(p);F=i(E,"TF 2.0 models accepts two formats as inputs:"),E.forEach(t),g=d(h),b=s(h,"UL",{});var K=r(b);$=s(K,"LI",{});var Ae=r($);_=i(Ae,"having all inputs as keyword arguments (like PyTorch models), or"),Ae.forEach(t),u=d(K),x=s(K,"LI",{});var ye=r(x);pe=i(ye,"having all inputs as a list, tuple or dict in the first positional arguments."),ye.forEach(t),K.forEach(t),G=d(h),M=s(h,"P",{});var j=r(M);Z=i(j,"This second option is useful when using "),U=s(j,"CODE",{});var $e=r(U);ee=i($e,"tf.keras.Model.fit"),$e.forEach(t),he=i(j,` method which currently requires having all the
tensors in the first argument of the model call function: `),B=s(j,"CODE",{});var ke=r(B);fe=i(ke,"model(inputs)"),ke.forEach(t),ae=i(j,"."),j.forEach(t),J=d(h),L=s(h,"P",{});var Fe=r(L);te=i(Fe,`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),Fe.forEach(t),X=d(h),z=s(h,"UL",{});var D=r(z);P=s(D,"LI",{});var S=r(P);Y=i(S,"a single Tensor with "),R=s(S,"CODE",{});var xe=r(R);me=i(xe,"input_ids"),xe.forEach(t),ue=i(S," only and nothing else: "),H=s(S,"CODE",{});var Ee=r(H);ge=i(Ee,"model(inputs_ids)"),Ee.forEach(t),S.forEach(t),ie=d(D),q=s(D,"LI",{});var W=r(q);_e=i(W,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=s(W,"CODE",{});var Me=r(Q);oe=i(Me,"model([input_ids, attention_mask])"),Me.forEach(t),se=i(W," or "),V=s(W,"CODE",{});var ze=r(V);le=i(ze,"model([input_ids, attention_mask, token_type_ids])"),ze.forEach(t),W.forEach(t),ne=d(D),N=s(D,"LI",{});var ce=r(N);de=i(ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=s(ce,"CODE",{});var be=r(O);re=i(be,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),be.forEach(t),ce.forEach(t),D.forEach(t)},m(h,E){f(h,p,E),e(p,F),f(h,g,E),f(h,b,E),e(b,$),e($,_),e(b,u),e(b,x),e(x,pe),f(h,G,E),f(h,M,E),e(M,Z),e(M,U),e(U,ee),e(M,he),e(M,B),e(B,fe),e(M,ae),f(h,J,E),f(h,L,E),e(L,te),f(h,X,E),f(h,z,E),e(z,P),e(P,Y),e(P,R),e(R,me),e(P,ue),e(P,H),e(H,ge),e(z,ie),e(z,q),e(q,_e),e(q,Q),e(Q,oe),e(q,se),e(q,V),e(V,le),e(z,ne),e(z,N),e(N,de),e(N,O),e(O,re)},d(h){h&&t(p),h&&t(g),h&&t(b),h&&t(G),h&&t(M),h&&t(J),h&&t(L),h&&t(X),h&&t(z)}}}function Wz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Uz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re;return{c(){p=n("p"),F=a("TF 2.0 models accepts two formats as inputs:"),g=l(),b=n("ul"),$=n("li"),_=a("having all inputs as keyword arguments (like PyTorch models), or"),u=l(),x=n("li"),pe=a("having all inputs as a list, tuple or dict in the first positional arguments."),G=l(),M=n("p"),Z=a("This second option is useful when using "),U=n("code"),ee=a("tf.keras.Model.fit"),he=a(` method which currently requires having all the
tensors in the first argument of the model call function: `),B=n("code"),fe=a("model(inputs)"),ae=a("."),J=l(),L=n("p"),te=a(`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),X=l(),z=n("ul"),P=n("li"),Y=a("a single Tensor with "),R=n("code"),me=a("input_ids"),ue=a(" only and nothing else: "),H=n("code"),ge=a("model(inputs_ids)"),ie=l(),q=n("li"),_e=a(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=n("code"),oe=a("model([input_ids, attention_mask])"),se=a(" or "),V=n("code"),le=a("model([input_ids, attention_mask, token_type_ids])"),ne=l(),N=n("li"),de=a(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=n("code"),re=a('model({"input_ids": input_ids, "token_type_ids": token_type_ids})')},l(h){p=s(h,"P",{});var E=r(p);F=i(E,"TF 2.0 models accepts two formats as inputs:"),E.forEach(t),g=d(h),b=s(h,"UL",{});var K=r(b);$=s(K,"LI",{});var Ae=r($);_=i(Ae,"having all inputs as keyword arguments (like PyTorch models), or"),Ae.forEach(t),u=d(K),x=s(K,"LI",{});var ye=r(x);pe=i(ye,"having all inputs as a list, tuple or dict in the first positional arguments."),ye.forEach(t),K.forEach(t),G=d(h),M=s(h,"P",{});var j=r(M);Z=i(j,"This second option is useful when using "),U=s(j,"CODE",{});var $e=r(U);ee=i($e,"tf.keras.Model.fit"),$e.forEach(t),he=i(j,` method which currently requires having all the
tensors in the first argument of the model call function: `),B=s(j,"CODE",{});var ke=r(B);fe=i(ke,"model(inputs)"),ke.forEach(t),ae=i(j,"."),j.forEach(t),J=d(h),L=s(h,"P",{});var Fe=r(L);te=i(Fe,`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),Fe.forEach(t),X=d(h),z=s(h,"UL",{});var D=r(z);P=s(D,"LI",{});var S=r(P);Y=i(S,"a single Tensor with "),R=s(S,"CODE",{});var xe=r(R);me=i(xe,"input_ids"),xe.forEach(t),ue=i(S," only and nothing else: "),H=s(S,"CODE",{});var Ee=r(H);ge=i(Ee,"model(inputs_ids)"),Ee.forEach(t),S.forEach(t),ie=d(D),q=s(D,"LI",{});var W=r(q);_e=i(W,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=s(W,"CODE",{});var Me=r(Q);oe=i(Me,"model([input_ids, attention_mask])"),Me.forEach(t),se=i(W," or "),V=s(W,"CODE",{});var ze=r(V);le=i(ze,"model([input_ids, attention_mask, token_type_ids])"),ze.forEach(t),W.forEach(t),ne=d(D),N=s(D,"LI",{});var ce=r(N);de=i(ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=s(ce,"CODE",{});var be=r(O);re=i(be,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),be.forEach(t),ce.forEach(t),D.forEach(t)},m(h,E){f(h,p,E),e(p,F),f(h,g,E),f(h,b,E),e(b,$),e($,_),e(b,u),e(b,x),e(x,pe),f(h,G,E),f(h,M,E),e(M,Z),e(M,U),e(U,ee),e(M,he),e(M,B),e(B,fe),e(M,ae),f(h,J,E),f(h,L,E),e(L,te),f(h,X,E),f(h,z,E),e(z,P),e(P,Y),e(P,R),e(R,me),e(P,ue),e(P,H),e(H,ge),e(z,ie),e(z,q),e(q,_e),e(q,Q),e(Q,oe),e(q,se),e(q,V),e(V,le),e(z,ne),e(z,N),e(N,de),e(N,O),e(O,re)},d(h){h&&t(p),h&&t(g),h&&t(b),h&&t(G),h&&t(M),h&&t(J),h&&t(L),h&&t(X),h&&t(z)}}}function Bz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Rz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re;return{c(){p=n("p"),F=a("TF 2.0 models accepts two formats as inputs:"),g=l(),b=n("ul"),$=n("li"),_=a("having all inputs as keyword arguments (like PyTorch models), or"),u=l(),x=n("li"),pe=a("having all inputs as a list, tuple or dict in the first positional arguments."),G=l(),M=n("p"),Z=a("This second option is useful when using "),U=n("code"),ee=a("tf.keras.Model.fit"),he=a(` method which currently requires having all the
tensors in the first argument of the model call function: `),B=n("code"),fe=a("model(inputs)"),ae=a("."),J=l(),L=n("p"),te=a(`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),X=l(),z=n("ul"),P=n("li"),Y=a("a single Tensor with "),R=n("code"),me=a("input_ids"),ue=a(" only and nothing else: "),H=n("code"),ge=a("model(inputs_ids)"),ie=l(),q=n("li"),_e=a(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=n("code"),oe=a("model([input_ids, attention_mask])"),se=a(" or "),V=n("code"),le=a("model([input_ids, attention_mask, token_type_ids])"),ne=l(),N=n("li"),de=a(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=n("code"),re=a('model({"input_ids": input_ids, "token_type_ids": token_type_ids})')},l(h){p=s(h,"P",{});var E=r(p);F=i(E,"TF 2.0 models accepts two formats as inputs:"),E.forEach(t),g=d(h),b=s(h,"UL",{});var K=r(b);$=s(K,"LI",{});var Ae=r($);_=i(Ae,"having all inputs as keyword arguments (like PyTorch models), or"),Ae.forEach(t),u=d(K),x=s(K,"LI",{});var ye=r(x);pe=i(ye,"having all inputs as a list, tuple or dict in the first positional arguments."),ye.forEach(t),K.forEach(t),G=d(h),M=s(h,"P",{});var j=r(M);Z=i(j,"This second option is useful when using "),U=s(j,"CODE",{});var $e=r(U);ee=i($e,"tf.keras.Model.fit"),$e.forEach(t),he=i(j,` method which currently requires having all the
tensors in the first argument of the model call function: `),B=s(j,"CODE",{});var ke=r(B);fe=i(ke,"model(inputs)"),ke.forEach(t),ae=i(j,"."),j.forEach(t),J=d(h),L=s(h,"P",{});var Fe=r(L);te=i(Fe,`If you choose this second option, there are three possibilities you can use to gather all the input Tensors in the
first positional argument :`),Fe.forEach(t),X=d(h),z=s(h,"UL",{});var D=r(z);P=s(D,"LI",{});var S=r(P);Y=i(S,"a single Tensor with "),R=s(S,"CODE",{});var xe=r(R);me=i(xe,"input_ids"),xe.forEach(t),ue=i(S," only and nothing else: "),H=s(S,"CODE",{});var Ee=r(H);ge=i(Ee,"model(inputs_ids)"),Ee.forEach(t),S.forEach(t),ie=d(D),q=s(D,"LI",{});var W=r(q);_e=i(W,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),Q=s(W,"CODE",{});var Me=r(Q);oe=i(Me,"model([input_ids, attention_mask])"),Me.forEach(t),se=i(W," or "),V=s(W,"CODE",{});var ze=r(V);le=i(ze,"model([input_ids, attention_mask, token_type_ids])"),ze.forEach(t),W.forEach(t),ne=d(D),N=s(D,"LI",{});var ce=r(N);de=i(ce,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),O=s(ce,"CODE",{});var be=r(O);re=i(be,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),be.forEach(t),ce.forEach(t),D.forEach(t)},m(h,E){f(h,p,E),e(p,F),f(h,g,E),f(h,b,E),e(b,$),e($,_),e(b,u),e(b,x),e(x,pe),f(h,G,E),f(h,M,E),e(M,Z),e(M,U),e(U,ee),e(M,he),e(M,B),e(B,fe),e(M,ae),f(h,J,E),f(h,L,E),e(L,te),f(h,X,E),f(h,z,E),e(z,P),e(P,Y),e(P,R),e(R,me),e(P,ue),e(P,H),e(H,ge),e(z,ie),e(z,q),e(q,_e),e(q,Q),e(Q,oe),e(q,se),e(q,V),e(V,le),e(z,ne),e(z,N),e(N,de),e(N,O),e(O,re)},d(h){h&&t(p),h&&t(g),h&&t(b),h&&t(G),h&&t(M),h&&t(J),h&&t(L),h&&t(X),h&&t(z)}}}function Hz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Qz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Vz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Jz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Kz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Gz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Xz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Zz(C){let p,F,g,b,$;return{c(){p=n("p"),F=a("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),b=a("Module"),$=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(_){p=s(_,"P",{});var u=r(p);F=i(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=s(u,"CODE",{});var x=r(g);b=i(x,"Module"),x.forEach(t),$=i(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(_,u){f(_,p,u),e(p,F),e(p,g),e(g,b),e(p,$)},d(_){_&&t(p)}}}function Yz(C){let p,F,g,b,$,_,u,x,pe,G,M,Z,U,ee,he,B,fe,ae,J,L,te,X,z,P,Y,R,me,ue,H,ge,ie,q,_e,Q,oe,se,V,le,ne,N,de,O,re,h,E,K,Ae,ye,j,$e,ke,Fe,D,S,xe,Ee,W,Me,ze,ce,be,Mn,dc,Ws,fg,cc,mg,Hf,Ve,Us,ug,St,gg,Dl,_g,bg,Ol,kg,vg,Bs,Tg,yg,wg,xo,Ag,Sl,$g,Fg,Wl,xg,Eg,Mg,pc,zg,qg,Rs,Qf,Eo,zn,hc,Hs,Pg,fc,jg,Vf,qe,Qs,Cg,Vs,Ig,Js,Lg,Ng,Dg,Ks,Og,Ul,Sg,Wg,Ug,Gt,Gs,Bg,mc,Rg,Hg,Xs,Bl,Qg,uc,Vg,Jg,Rl,Kg,gc,Gg,Xg,qn,Zs,Zg,Ys,Yg,_c,e_,t_,o_,qt,er,n_,bc,s_,r_,tr,a_,Mo,i_,kc,l_,d_,vc,c_,p_,h_,Hl,or,Jf,zo,Pn,Tc,nr,f_,yc,m_,Kf,zt,sr,u_,Wt,g_,wc,__,b_,rr,k_,v_,Ql,T_,y_,w_,Xt,ar,A_,Ac,$_,F_,ir,Vl,x_,$c,E_,M_,Jl,z_,Fc,q_,P_,Pt,lr,j_,xc,C_,I_,dr,L_,Ec,N_,Gf,qo,jn,Mc,cr,D_,zc,O_,Xf,Po,pr,S_,hr,W_,Kl,U_,B_,Zf,jo,fr,R_,mr,H_,Gl,Q_,V_,Yf,Co,Cn,qc,ur,J_,Pc,K_,em,Je,gr,G_,jc,X_,Z_,_r,Y_,Xl,eb,tb,ob,br,nb,kr,sb,rb,ab,tt,vr,ib,Io,lb,Zl,db,cb,Cc,pb,hb,fb,In,mb,Ic,ub,gb,Tr,tm,Lo,Ln,Lc,yr,_b,Nc,bb,om,Ke,wr,kb,No,vb,Dc,Tb,yb,Oc,wb,Ab,$b,Ar,Fb,Yl,xb,Eb,Mb,$r,zb,Fr,qb,Pb,jb,ot,xr,Cb,Do,Ib,ed,Lb,Nb,Sc,Db,Ob,Sb,Nn,Wb,Wc,Ub,Bb,Er,nm,Oo,Dn,Uc,Mr,Rb,Bc,Hb,sm,Ge,zr,Qb,qr,Vb,Rc,Jb,Kb,Gb,Pr,Xb,td,Zb,Yb,ek,jr,tk,Cr,ok,nk,sk,nt,Ir,rk,So,ak,od,ik,lk,Hc,dk,ck,pk,On,hk,Qc,fk,mk,Lr,rm,Wo,Sn,Vc,Nr,uk,Jc,gk,am,Xe,Dr,_k,Kc,bk,kk,Or,vk,nd,Tk,yk,wk,Sr,Ak,Wr,$k,Fk,xk,Oe,Ur,Ek,Uo,Mk,sd,zk,qk,Gc,Pk,jk,Ck,Wn,Ik,Xc,Lk,Nk,Br,Dk,Zc,Ok,Sk,Rr,im,Bo,Un,Yc,Hr,Wk,ep,Uk,lm,Ze,Qr,Bk,tp,Rk,Hk,Vr,Qk,rd,Vk,Jk,Kk,Jr,Gk,Kr,Xk,Zk,Yk,st,Gr,ev,Ro,tv,ad,ov,nv,op,sv,rv,av,Bn,iv,np,lv,dv,Xr,dm,Ho,Rn,sp,Zr,cv,rp,pv,cm,Ye,Yr,hv,ap,fv,mv,ea,uv,id,gv,_v,bv,ta,kv,oa,vv,Tv,yv,rt,na,wv,Qo,Av,ld,$v,Fv,ip,xv,Ev,Mv,Hn,zv,lp,qv,Pv,sa,pm,Vo,Qn,dp,ra,jv,cp,Cv,hm,et,aa,Iv,Jo,Lv,pp,Nv,Dv,hp,Ov,Sv,Wv,ia,Uv,dd,Bv,Rv,Hv,la,Qv,da,Vv,Jv,Kv,at,ca,Gv,Ko,Xv,cd,Zv,Yv,fp,eT,tT,oT,Vn,nT,mp,sT,rT,pa,fm,Go,Jn,up,ha,aT,gp,iT,mm,Se,fa,lT,_p,dT,cT,ma,pT,pd,hT,fT,mT,ua,uT,ga,gT,_T,bT,Kn,kT,it,_a,vT,Xo,TT,hd,yT,wT,bp,AT,$T,FT,Gn,xT,kp,ET,MT,ba,um,Zo,Xn,vp,ka,zT,Tp,qT,gm,We,va,PT,Yo,jT,yp,CT,IT,wp,LT,NT,DT,Ta,OT,fd,ST,WT,UT,ya,BT,wa,RT,HT,QT,Zn,VT,lt,Aa,JT,en,KT,md,GT,XT,Ap,ZT,YT,e1,Yn,t1,$p,o1,n1,$a,_m,tn,es,Fp,Fa,s1,xp,r1,bm,Ue,xa,a1,Ea,i1,Ep,l1,d1,c1,Ma,p1,ud,h1,f1,m1,za,u1,qa,g1,_1,b1,ts,k1,dt,Pa,v1,on,T1,gd,y1,w1,Mp,A1,$1,F1,os,x1,zp,E1,M1,ja,km,nn,ns,qp,Ca,z1,Pp,q1,vm,Be,Ia,P1,jp,j1,C1,La,I1,_d,L1,N1,D1,Na,O1,Da,S1,W1,U1,ss,B1,ct,Oa,R1,sn,H1,bd,Q1,V1,Cp,J1,K1,G1,rs,X1,Ip,Z1,Y1,Sa,Tm,rn,as,Lp,Wa,ey,Np,ty,ym,Re,Ua,oy,Dp,ny,sy,Ba,ry,kd,ay,iy,ly,Ra,dy,Ha,cy,py,hy,is,fy,pt,Qa,my,an,uy,vd,gy,_y,Op,by,ky,vy,ls,Ty,Sp,yy,wy,Va,wm,ln,ds,Wp,Ja,Ay,Up,$y,Am,He,Ka,Fy,Bp,xy,Ey,Ga,My,Td,zy,qy,Py,Xa,jy,Za,Cy,Iy,Ly,cs,Ny,ht,Ya,Dy,dn,Oy,yd,Sy,Wy,Rp,Uy,By,Ry,ps,Hy,Hp,Qy,Vy,ei,$m,cn,hs,Qp,ti,Jy,Vp,Ky,Fm,Qe,oi,Gy,pn,Xy,Jp,Zy,Yy,Kp,ew,tw,ow,ni,nw,wd,sw,rw,aw,si,iw,ri,lw,dw,cw,fs,pw,ft,ai,hw,hn,fw,Ad,mw,uw,Gp,gw,_w,bw,ms,kw,Xp,vw,Tw,ii,xm,fn,us,Zp,li,yw,Yp,ww,Em,Pe,di,Aw,eh,$w,Fw,ci,xw,$d,Ew,Mw,zw,pi,qw,hi,Pw,jw,Cw,th,Iw,Lw,Ut,oh,fi,Nw,Dw,nh,mi,Ow,Sw,sh,ui,Ww,Uw,rh,gi,Bw,Rw,mt,_i,Hw,mn,Qw,ah,Vw,Jw,ih,Kw,Gw,Xw,gs,Zw,lh,Yw,eA,bi,Mm,un,_s,dh,ki,tA,ch,oA,zm,je,vi,nA,gn,sA,ph,rA,aA,hh,iA,lA,dA,Ti,cA,Fd,pA,hA,fA,yi,mA,wi,uA,gA,_A,fh,bA,kA,Bt,mh,Ai,vA,TA,uh,$i,yA,wA,gh,Fi,AA,$A,_h,xi,FA,xA,ut,Ei,EA,_n,MA,bh,zA,qA,kh,PA,jA,CA,bs,IA,vh,LA,NA,Mi,qm,bn,ks,Th,zi,DA,yh,OA,Pm,Ce,qi,SA,Pi,WA,wh,UA,BA,RA,ji,HA,xd,QA,VA,JA,Ci,KA,Ii,GA,XA,ZA,Ah,YA,e2,Rt,$h,Li,t2,o2,Fh,Ni,n2,s2,xh,Di,r2,a2,Eh,Oi,i2,l2,gt,Si,d2,kn,c2,Mh,p2,h2,zh,f2,m2,u2,vs,g2,qh,_2,b2,Wi,jm,vn,Ts,Ph,Ui,k2,jh,v2,Cm,Ie,Bi,T2,Ch,y2,w2,Ri,A2,Ed,$2,F2,x2,Hi,E2,Qi,M2,z2,q2,Ih,P2,j2,Ht,Lh,Vi,C2,I2,Nh,Ji,L2,N2,Dh,Ki,D2,O2,Oh,Gi,S2,W2,_t,Xi,U2,Tn,B2,Sh,R2,H2,Wh,Q2,V2,J2,ys,K2,Uh,G2,X2,Zi,Im,yn,ws,Bh,Yi,Z2,Rh,Y2,Lm,Le,el,e$,Hh,t$,o$,tl,n$,Md,s$,r$,a$,ol,i$,nl,l$,d$,c$,Qh,p$,h$,Qt,Vh,sl,f$,m$,Jh,rl,u$,g$,Kh,al,_$,b$,Gh,il,k$,v$,bt,ll,T$,wn,y$,Xh,w$,A$,Zh,$$,F$,x$,As,E$,Yh,M$,z$,dl,Nm,An,$s,ef,cl,q$,tf,P$,Dm,Ne,pl,j$,of,C$,I$,hl,L$,zd,N$,D$,O$,fl,S$,ml,W$,U$,B$,nf,R$,H$,Vt,sf,ul,Q$,V$,rf,gl,J$,K$,af,_l,G$,X$,lf,bl,Z$,Y$,kt,kl,eF,$n,tF,df,oF,nF,cf,sF,rF,aF,Fs,iF,pf,lF,dF,vl,Om,Fn,xs,hf,Tl,cF,ff,pF,Sm,De,yl,hF,xn,fF,mf,mF,uF,uf,gF,_F,bF,wl,kF,qd,vF,TF,yF,Al,wF,$l,AF,$F,FF,gf,xF,EF,Jt,_f,Fl,MF,zF,bf,xl,qF,PF,kf,El,jF,CF,vf,Ml,IF,LF,vt,zl,NF,En,DF,Tf,OF,SF,yf,WF,UF,BF,Es,RF,wf,HF,QF,ql,Wm;return _=new Te({}),ee=new Te({}),Ws=new Te({}),Us=new I({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:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/configuration_albert.py#L36",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/pr_15839/en/model_doc/albert#transformers.AlbertModel">AlbertModel</a> or <a href="/docs/transformers/pr_15839/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/pr_15839/en/model_doc/albert#transformers.AlbertModel">AlbertModel</a> or <a href="/docs/transformers/pr_15839/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"}]}}),Rs=new we({props:{code:`from transformers import AlbertConfig, AlbertModel

# Initializing an ALBERT-xxlarge style configuration
albert_xxlarge_configuration = AlbertConfig()

# Initializing an ALBERT-base style configuration
albert_base_configuration = AlbertConfig(
    hidden_size=768,
    num_attention_heads=12,
    intermediate_size=3072,
)

# Initializing a model from the ALBERT-base style configuration
model = AlbertModel(albert_xxlarge_configuration)

# Accessing the model configuration
configuration = model.config`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> 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 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`}}),Hs=new Te({}),Qs=new I({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:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/tokenization_albert.py#L59",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"}]}}),Gs=new I({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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/tokenization_albert.py#L255",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"}],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>
`}}),Zs=new I({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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/tokenization_albert.py#L280",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"}],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>
`}}),er=new I({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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/tokenization_albert.py#L308",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"}],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>
`}}),tr=new we({props:{code:`0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1
| first sequence    | second sequence |`,highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence    | second sequence |`}}),or=new I({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/pr_15839/src/transformers/models/albert/tokenization_albert.py#L338"}}),nr=new Te({}),sr=new I({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:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/tokenization_albert_fast.py#L73",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"}]}}),ar=new I({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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/tokenization_albert_fast.py#L171",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"}],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>
`}}),lr=new I({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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/tokenization_albert_fast.py#L196",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"}],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>
`}}),dr=new we({props:{code:`0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1
| first sequence    | second sequence |`,highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence    | second sequence |`}}),cr=new Te({}),pr=new I({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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L518",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"}]}}),fr=new I({props:{name:"class transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput",anchor:"transformers.models.albert.modeling_tf_albert.TFAlbertForPreTrainingOutput",parameters:[{name:"loss",val:": Tensor = None"},{name:"prediction_logits",val:": Tensor = None"},{name:"sop_logits",val:": Tensor = None"},{name:"hidden_states",val:": typing.Optional[typing.Tuple[tensorflow.python.framework.ops.Tensor]] = None"},{name:"attentions",val:": typing.Optional[typing.Tuple[tensorflow.python.framework.ops.Tensor]] = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L649",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"}]}}),ur=new Te({}),gr=new I({props:{name:"class transformers.AlbertModel",anchor:"transformers.AlbertModel",parameters:[{name:"config",val:""},{name:"add_pooling_layer",val:" = True"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L621",parametersDescription:[{anchor:"transformers.AlbertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),vr=new I({props:{name:"forward",anchor:"transformers.AlbertModel.forward",parameters:[{name:"input_ids",val:" = None"},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"inputs_embeds",val:" = None"},{name:"output_attentions",val:" = None"},{name:"output_hidden_states",val:" = None"},{name:"return_dict",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L665",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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 + 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/pr_15839/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPooling"
>transformers.modeling_outputs.BaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),In=new ve({props:{$$slots:{default:[$z]},$$scope:{ctx:C}}}),Tr=new we({props:{code:`from transformers import AlbertTokenizer, AlbertModel
import torch

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertModel.from_pretrained("albert-base-v2")

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

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.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`}}),yr=new Te({}),wr=new I({props:{name:"class transformers.AlbertForPreTraining",anchor:"transformers.AlbertForPreTraining",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L751",parametersDescription:[{anchor:"transformers.AlbertForPreTraining.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),xr=new I({props:{name:"forward",anchor:"transformers.AlbertForPreTraining.forward",parameters:[{name:"input_ids",val:" = None"},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"inputs_embeds",val:" = None"},{name:"labels",val:" = None"},{name:"sentence_order_label",val:" = None"},{name:"output_attentions",val:" = None"},{name:"output_hidden_states",val:" = None"},{name:"return_dict",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L771",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/model_doc/albert#transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput"
>transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Nn=new ve({props:{$$slots:{default:[Fz]},$$scope:{ctx:C}}}),Er=new we({props:{code:`from transformers import AlbertTokenizer, AlbertForPreTraining
import torch

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertForPreTraining.from_pretrained("albert-base-v2")

input_ids = torch.tensor(tokenizer.encode("Hello, my dog is cute", add_special_tokens=True)).unsqueeze(
    0
)  # Batch size 1
outputs = model(input_ids)

prediction_logits = outputs.prediction_logits
sop_logits = outputs.sop_logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.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-meta">... </span>    <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`}}),Mr=new Te({}),zr=new I({props:{name:"class transformers.AlbertForMaskedLM",anchor:"transformers.AlbertForMaskedLM",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L898",parametersDescription:[{anchor:"transformers.AlbertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),Ir=new I({props:{name:"forward",anchor:"transformers.AlbertForMaskedLM.forward",parameters:[{name:"input_ids",val:" = None"},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"inputs_embeds",val:" = None"},{name:"labels",val:" = None"},{name:"output_attentions",val:" = None"},{name:"output_hidden_states",val:" = None"},{name:"return_dict",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L920",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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 + 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/pr_15839/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),On=new ve({props:{$$slots:{default:[xz]},$$scope:{ctx:C}}}),Lr=new we({props:{code:`from transformers import AlbertTokenizer, AlbertForMaskedLM
import torch

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertForMaskedLM.from_pretrained("albert-base-v2")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is [MASK].&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>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>outputs = model(**inputs, labels=labels)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),Nr=new Te({}),Dr=new I({props:{name:"class transformers.AlbertForSequenceClassification",anchor:"transformers.AlbertForSequenceClassification",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L987",parametersDescription:[{anchor:"transformers.AlbertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),Ur=new I({props:{name:"forward",anchor:"transformers.AlbertForSequenceClassification.forward",parameters:[{name:"input_ids",val:" = None"},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"inputs_embeds",val:" = None"},{name:"labels",val:" = None"},{name:"output_attentions",val:" = None"},{name:"output_hidden_states",val:" = None"},{name:"return_dict",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L1000",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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 + 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/pr_15839/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Wn=new ve({props:{$$slots:{default:[Ez]},$$scope:{ctx:C}}}),Br=new we({props:{code:`import torch
from transformers import AlbertTokenizer, AlbertForSequenceClassification

torch.manual_seed(0)
tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertForSequenceClassification.from_pretrained("albert-base-v2", num_labels=2)

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
labels = torch.tensor([1]).unsqueeze(0)  # Batch size 1
outputs = model(**inputs, labels=labels)
loss = outputs.loss
logits = outputs.logits
list(logits.shape)
`,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> AlbertTokenizer, AlbertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>torch.manual_seed(<span class="hljs-number">0</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>, num_labels=<span class="hljs-number">2</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>labels = torch.tensor([<span class="hljs-number">1</span>]).unsqueeze(<span class="hljs-number">0</span>)  <span class="hljs-comment"># Batch size 1</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">list</span>(logits.shape)
`}}),Rr=new we({props:{code:`import torch
from transformers import AlbertTokenizer, AlbertForSequenceClassification

torch.manual_seed(0)
tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertForSequenceClassification.from_pretrained("albert-base-v2", problem_type="multi_label_classification", num_labels=2)

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
labels = torch.tensor([[1, 1]], dtype=torch.float)  # need dtype=float for BCEWithLogitsLoss
outputs = model(**inputs, labels=labels)
loss = outputs.loss
list(logits.shape)
`,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> AlbertTokenizer, AlbertForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>torch.manual_seed(<span class="hljs-number">0</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>, problem_type=<span class="hljs-string">&quot;multi_label_classification&quot;</span>, num_labels=<span class="hljs-number">2</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>labels = torch.tensor([[<span class="hljs-number">1</span>, <span class="hljs-number">1</span>]], dtype=torch.<span class="hljs-built_in">float</span>)  <span class="hljs-comment"># need dtype=float for BCEWithLogitsLoss</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">list</span>(logits.shape)
`}}),Hr=new Te({}),Qr=new I({props:{name:"class transformers.AlbertForMultipleChoice",anchor:"transformers.AlbertForMultipleChoice",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L1277",parametersDescription:[{anchor:"transformers.AlbertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),Gr=new I({props:{name:"forward",anchor:"transformers.AlbertForMultipleChoice.forward",parameters:[{name:"input_ids",val:" = None"},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"inputs_embeds",val:" = None"},{name:"labels",val:" = None"},{name:"output_attentions",val:" = None"},{name:"output_hidden_states",val:" = None"},{name:"return_dict",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L1288",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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 + 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/pr_15839/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Bn=new ve({props:{$$slots:{default:[Mz]},$$scope:{ctx:C}}}),Xr=new we({props:{code:`from transformers import AlbertTokenizer, AlbertForMultipleChoice
import torch

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertForMultipleChoice.from_pretrained("albert-base-v2")

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

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

# the linear classifier still needs to be trained
loss = outputs.loss
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.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`}}),Zr=new Te({}),Yr=new I({props:{name:"class transformers.AlbertForTokenClassification",anchor:"transformers.AlbertForTokenClassification",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L1087",parametersDescription:[{anchor:"transformers.AlbertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),na=new I({props:{name:"forward",anchor:"transformers.AlbertForTokenClassification.forward",parameters:[{name:"input_ids",val:" = None"},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"inputs_embeds",val:" = None"},{name:"labels",val:" = None"},{name:"output_attentions",val:" = None"},{name:"output_hidden_states",val:" = None"},{name:"return_dict",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L1107",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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 + 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/pr_15839/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Hn=new ve({props:{$$slots:{default:[zz]},$$scope:{ctx:C}}}),sa=new we({props:{code:`from transformers import AlbertTokenizer, AlbertForTokenClassification
import torch

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertForTokenClassification.from_pretrained("albert-base-v2")

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
labels = torch.tensor([1] * inputs["input_ids"].size(1)).unsqueeze(0)  # Batch size 1

outputs = model(**inputs, labels=labels)
loss = outputs.loss
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.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-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>labels = torch.tensor([<span class="hljs-number">1</span>] * inputs[<span class="hljs-string">&quot;input_ids&quot;</span>].size(<span class="hljs-number">1</span>)).unsqueeze(<span class="hljs-number">0</span>)  <span class="hljs-comment"># Batch size 1</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),ra=new Te({}),aa=new I({props:{name:"class transformers.AlbertForQuestionAnswering",anchor:"transformers.AlbertForQuestionAnswering",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L1174",parametersDescription:[{anchor:"transformers.AlbertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),ca=new I({props:{name:"forward",anchor:"transformers.AlbertForQuestionAnswering.forward",parameters:[{name:"input_ids",val:" = None"},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"inputs_embeds",val:" = None"},{name:"start_positions",val:" = None"},{name:"end_positions",val:" = None"},{name:"output_attentions",val:" = None"},{name:"output_hidden_states",val:" = None"},{name:"return_dict",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_albert.py#L1188",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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 + 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/pr_15839/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Vn=new ve({props:{$$slots:{default:[qz]},$$scope:{ctx:C}}}),pa=new we({props:{code:`from transformers import AlbertTokenizer, AlbertForQuestionAnswering
import torch

torch.manual_seed(0)
tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = AlbertForQuestionAnswering.from_pretrained("albert-base-v2")

question, text = "Who was Jim Henson?", "Jim Henson was a nice puppet"
inputs = tokenizer(question, text, return_tensors="pt")
start_positions = torch.tensor([1])
end_positions = torch.tensor([3])

outputs = model(**inputs, start_positions=start_positions, end_positions=end_positions)
loss = outputs.loss
round(loss.item(), 2)


start_scores = outputs.start_logits
list(start_scores.shape)


end_scores = outputs.end_logits
list(end_scores.shape)
`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, AlbertForQuestionAnswering
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>torch.manual_seed(<span class="hljs-number">0</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = AlbertForQuestionAnswering.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;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>start_positions = torch.tensor([<span class="hljs-number">1</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>end_positions = torch.tensor([<span class="hljs-number">3</span>])

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, start_positions=start_positions, end_positions=end_positions)
<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-meta">&gt;&gt;&gt; </span>start_scores = outputs.start_logits
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">list</span>(start_scores.shape)


<span class="hljs-meta">&gt;&gt;&gt; </span>end_scores = outputs.end_logits
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">list</span>(end_scores.shape)
`}}),ha=new Te({}),fa=new I({props:{name:"class transformers.TFAlbertModel",anchor:"transformers.TFAlbertModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L776",parametersDescription:[{anchor:"transformers.TFAlbertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),Kn=new ve({props:{$$slots:{default:[Pz]},$$scope:{ctx:C}}}),_a=new I({props:{name:"call",anchor:"transformers.TFAlbertModel.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": typing.Optional[bool] = False"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L782",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutputWithPooling"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPooling</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Gn=new ve({props:{$$slots:{default:[jz]},$$scope:{ctx:C}}}),ba=new we({props:{code:`from transformers import AlbertTokenizer, TFAlbertModel
import tensorflow as tf

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = TFAlbertModel.from_pretrained("albert-base-v2")

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

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.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`}}),ka=new Te({}),va=new I({props:{name:"class transformers.TFAlbertForPreTraining",anchor:"transformers.TFAlbertForPreTraining",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L852",parametersDescription:[{anchor:"transformers.TFAlbertForPreTraining.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),Zn=new ve({props:{$$slots:{default:[Cz]},$$scope:{ctx:C}}}),Aa=new I({props:{name:"call",anchor:"transformers.TFAlbertForPreTraining.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"sentence_order_label",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L868",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/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>
`}}),Yn=new ve({props:{$$slots:{default:[Iz]},$$scope:{ctx:C}}}),$a=new we({props:{code:`import tensorflow as tf
from transformers import AlbertTokenizer, TFAlbertForPreTraining

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = TFAlbertForPreTraining.from_pretrained("albert-base-v2")

input_ids = tf.constant(tokenizer.encode("Hello, my dog is cute", add_special_tokens=True))[
    None, :
]  # Batch size 1
outputs = model(input_ids)

prediction_logits = outputs.prediction_logits
sop_logits = outputs.sop_logits`,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> AlbertTokenizer, TFAlbertForPreTraining

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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-meta">... </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`}}),Fa=new Te({}),xa=new I({props:{name:"class transformers.TFAlbertForMaskedLM",anchor:"transformers.TFAlbertForMaskedLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L989",parametersDescription:[{anchor:"transformers.TFAlbertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),ts=new ve({props:{$$slots:{default:[Lz]},$$scope:{ctx:C}}}),Pa=new I({props:{name:"call",anchor:"transformers.TFAlbertForMaskedLM.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1002",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),os=new ve({props:{$$slots:{default:[Nz]},$$scope:{ctx:C}}}),ja=new we({props:{code:`from transformers import AlbertTokenizer, TFAlbertForMaskedLM
import tensorflow as tf

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = TFAlbertForMaskedLM.from_pretrained("albert-base-v2")

inputs = tokenizer("The capital of France is [MASK].", return_tensors="tf")
inputs["labels"] = tokenizer("The capital of France is Paris.", return_tensors="tf")["input_ids"]

outputs = model(inputs)
loss = outputs.loss
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, TFAlbertForMaskedLM
<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 = AlbertTokenizer.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>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is [MASK].&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs[<span class="hljs-string">&quot;labels&quot;</span>] = 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>outputs = model(inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),Ca=new Te({}),Ia=new I({props:{name:"class transformers.TFAlbertForSequenceClassification",anchor:"transformers.TFAlbertForSequenceClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1093",parametersDescription:[{anchor:"transformers.TFAlbertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),ss=new ve({props:{$$slots:{default:[Dz]},$$scope:{ctx:C}}}),Oa=new I({props:{name:"call",anchor:"transformers.TFAlbertForSequenceClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1109",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),rs=new ve({props:{$$slots:{default:[Oz]},$$scope:{ctx:C}}}),Sa=new we({props:{code:`from transformers import AlbertTokenizer, TFAlbertForSequenceClassification
import tensorflow as tf

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = TFAlbertForSequenceClassification.from_pretrained("albert-base-v2")

inputs = tokenizer("Hello, my dog is cute", return_tensors="tf")
inputs["labels"] = tf.reshape(tf.constant(1), (-1, 1))  # Batch size 1

outputs = model(inputs)
loss = outputs.loss
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFAlbertForSequenceClassification.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>inputs[<span class="hljs-string">&quot;labels&quot;</span>] = tf.reshape(tf.constant(<span class="hljs-number">1</span>), (-<span class="hljs-number">1</span>, <span class="hljs-number">1</span>))  <span class="hljs-comment"># Batch size 1</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),Wa=new Te({}),Ua=new I({props:{name:"class transformers.TFAlbertForMultipleChoice",anchor:"transformers.TFAlbertForMultipleChoice",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1422",parametersDescription:[{anchor:"transformers.TFAlbertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),is=new ve({props:{$$slots:{default:[Sz]},$$scope:{ctx:C}}}),Qa=new I({props:{name:"call",anchor:"transformers.TFAlbertForMultipleChoice.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1446",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),ls=new ve({props:{$$slots:{default:[Wz]},$$scope:{ctx:C}}}),Va=new we({props:{code:`from transformers import AlbertTokenizer, TFAlbertForMultipleChoice
import tensorflow as tf

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = TFAlbertForMultipleChoice.from_pretrained("albert-base-v2")

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

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

# the linear classifier still needs to be trained
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.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`}}),Ja=new Te({}),Ka=new I({props:{name:"class transformers.TFAlbertForTokenClassification",anchor:"transformers.TFAlbertForTokenClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1197",parametersDescription:[{anchor:"transformers.TFAlbertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),cs=new ve({props:{$$slots:{default:[Uz]},$$scope:{ctx:C}}}),Ya=new I({props:{name:"call",anchor:"transformers.TFAlbertForTokenClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1218",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),ps=new ve({props:{$$slots:{default:[Bz]},$$scope:{ctx:C}}}),ei=new we({props:{code:`from transformers import AlbertTokenizer, TFAlbertForTokenClassification
import tensorflow as tf

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = TFAlbertForTokenClassification.from_pretrained("albert-base-v2")

inputs = tokenizer("Hello, my dog is cute", return_tensors="tf")
input_ids = inputs["input_ids"]
inputs["labels"] = tf.reshape(
    tf.constant([1] * tf.size(input_ids).numpy()), (-1, tf.size(input_ids))
)  # Batch size 1

outputs = model(inputs)
loss = outputs.loss
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.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-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>input_ids = inputs[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs[<span class="hljs-string">&quot;labels&quot;</span>] = tf.reshape(
<span class="hljs-meta">... </span>    tf.constant([<span class="hljs-number">1</span>] * tf.size(input_ids).numpy()), (-<span class="hljs-number">1</span>, tf.size(input_ids))
<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(inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),ti=new Te({}),oi=new I({props:{name:"class transformers.TFAlbertForQuestionAnswering",anchor:"transformers.TFAlbertForQuestionAnswering",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1304",parametersDescription:[{anchor:"transformers.TFAlbertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}]}}),fs=new ve({props:{$$slots:{default:[Rz]},$$scope:{ctx:C}}}),ai=new I({props:{name:"call",anchor:"transformers.TFAlbertForQuestionAnswering.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[tensorflow.python.keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, tensorflow.python.keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, tensorflow.python.keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"start_positions",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"end_positions",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_tf_albert.py#L1318",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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.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/pr_15839/en/main_classes/output#transformers.file_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"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),ms=new ve({props:{$$slots:{default:[Hz]},$$scope:{ctx:C}}}),ii=new we({props:{code:`from transformers import AlbertTokenizer, TFAlbertForQuestionAnswering
import tensorflow as tf

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = TFAlbertForQuestionAnswering.from_pretrained("albert-base-v2")

question, text = "Who was Jim Henson?", "Jim Henson was a nice puppet"
input_dict = tokenizer(question, text, return_tensors="tf")
outputs = model(input_dict)
start_logits = outputs.start_logits
end_logits = outputs.end_logits

all_tokens = tokenizer.convert_ids_to_tokens(input_dict["input_ids"].numpy()[0])
answer = " ".join(all_tokens[tf.math.argmax(start_logits, 1)[0] : tf.math.argmax(end_logits, 1)[0] + 1])`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, 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 = AlbertTokenizer.from_pretrained(<span class="hljs-string">&quot;albert-base-v2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFAlbertForQuestionAnswering.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>input_dict = tokenizer(question, text, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(input_dict)
<span class="hljs-meta">&gt;&gt;&gt; </span>start_logits = outputs.start_logits
<span class="hljs-meta">&gt;&gt;&gt; </span>end_logits = outputs.end_logits

<span class="hljs-meta">&gt;&gt;&gt; </span>all_tokens = tokenizer.convert_ids_to_tokens(input_dict[<span class="hljs-string">&quot;input_ids&quot;</span>].numpy()[<span class="hljs-number">0</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>answer = <span class="hljs-string">&quot; &quot;</span>.join(all_tokens[tf.math.argmax(start_logits, <span class="hljs-number">1</span>)[<span class="hljs-number">0</span>] : tf.math.argmax(end_logits, <span class="hljs-number">1</span>)[<span class="hljs-number">0</span>] + <span class="hljs-number">1</span>])`}}),li=new Te({}),di=new I({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._src.numpy.lax_numpy.float32'>"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L668",parametersDescription:[{anchor:"transformers.FlaxAlbertModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}]}}),_i=new I({props:{name:"__call__",anchor:"transformers.FlaxAlbertPreTrainedModel.__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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L545",parametersDescription:[{anchor:"transformers.FlaxAlbertPreTrainedModel.__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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),gs=new ve({props:{$$slots:{default:[Qz]},$$scope:{ctx:C}}}),bi=new we({props:{code:`from transformers import AlbertTokenizer, FlaxAlbertModel

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = FlaxAlbertModel.from_pretrained("albert-base-v2")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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`}}),ki=new Te({}),vi=new I({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._src.numpy.lax_numpy.float32'>"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L739",parametersDescription:[{anchor:"transformers.FlaxAlbertForPreTraining.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}]}}),Ei=new I({props:{name:"__call__",anchor:"transformers.FlaxAlbertPreTrainedModel.__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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L545",parametersDescription:[{anchor:"transformers.FlaxAlbertPreTrainedModel.__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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],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/pr_15839/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>
`}}),bs=new ve({props:{$$slots:{default:[Vz]},$$scope:{ctx:C}}}),Mi=new we({props:{code:`from transformers import AlbertTokenizer, FlaxAlbertForPreTraining

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = FlaxAlbertForPreTraining.from_pretrained("albert-base-v2")

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

prediction_logits = outputs.prediction_logits
seq_relationship_logits = outputs.sop_logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AlbertTokenizer, FlaxAlbertForPreTraining

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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`}}),zi=new Te({}),qi=new I({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._src.numpy.lax_numpy.float32'>"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L822",parametersDescription:[{anchor:"transformers.FlaxAlbertForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}]}}),Si=new I({props:{name:"__call__",anchor:"transformers.FlaxAlbertPreTrainedModel.__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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L545",parametersDescription:[{anchor:"transformers.FlaxAlbertPreTrainedModel.__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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMaskedLMOutput"
>transformers.modeling_flax_outputs.FlaxMaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),vs=new ve({props:{$$slots:{default:[Jz]},$$scope:{ctx:C}}}),Wi=new we({props:{code:`from transformers import AlbertTokenizer, FlaxAlbertForMaskedLM

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = FlaxAlbertForMaskedLM.from_pretrained("albert-base-v2")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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`}}),Ui=new Te({}),Bi=new I({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._src.numpy.lax_numpy.float32'>"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L892",parametersDescription:[{anchor:"transformers.FlaxAlbertForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}]}}),Xi=new I({props:{name:"__call__",anchor:"transformers.FlaxAlbertPreTrainedModel.__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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L545",parametersDescription:[{anchor:"transformers.FlaxAlbertPreTrainedModel.__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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ys=new ve({props:{$$slots:{default:[Kz]},$$scope:{ctx:C}}}),Zi=new we({props:{code:`from transformers import AlbertTokenizer, FlaxAlbertForSequenceClassification

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = FlaxAlbertForSequenceClassification.from_pretrained("albert-base-v2")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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`}}),Yi=new Te({}),el=new I({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._src.numpy.lax_numpy.float32'>"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L966",parametersDescription:[{anchor:"transformers.FlaxAlbertForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}]}}),ll=new I({props:{name:"__call__",anchor:"transformers.FlaxAlbertPreTrainedModel.__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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L545",parametersDescription:[{anchor:"transformers.FlaxAlbertPreTrainedModel.__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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),As=new ve({props:{$$slots:{default:[Gz]},$$scope:{ctx:C}}}),dl=new we({props:{code:`from transformers import AlbertTokenizer, FlaxAlbertForMultipleChoice

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = FlaxAlbertForMultipleChoice.from_pretrained("albert-base-v2")

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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`}}),cl=new Te({}),pl=new I({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._src.numpy.lax_numpy.float32'>"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L1040",parametersDescription:[{anchor:"transformers.FlaxAlbertForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}]}}),kl=new I({props:{name:"__call__",anchor:"transformers.FlaxAlbertPreTrainedModel.__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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L545",parametersDescription:[{anchor:"transformers.FlaxAlbertPreTrainedModel.__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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Fs=new ve({props:{$$slots:{default:[Xz]},$$scope:{ctx:C}}}),vl=new we({props:{code:`from transformers import AlbertTokenizer, FlaxAlbertForTokenClassification

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = FlaxAlbertForTokenClassification.from_pretrained("albert-base-v2")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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`}}),Tl=new Te({}),yl=new I({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._src.numpy.lax_numpy.float32'>"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L1109",parametersDescription:[{anchor:"transformers.FlaxAlbertForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}]}}),zl=new I({props:{name:"__call__",anchor:"transformers.FlaxAlbertPreTrainedModel.__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"}],source:"https://github.com/huggingface/transformers/blob/pr_15839/src/transformers/models/albert/modeling_flax_albert.py#L545",parametersDescription:[{anchor:"transformers.FlaxAlbertPreTrainedModel.__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/pr_15839/en/model_doc/albert#transformers.AlbertTokenizer">AlbertTokenizer</a>. See <a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_15839/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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.FlaxAlbertPreTrainedModel.__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/pr_15839/en/main_classes/output#transformers.file_utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],returnDescription:`
<p>A <a
  href="/docs/transformers/pr_15839/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/pr_15839/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/pr_15839/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Es=new ve({props:{$$slots:{default:[Zz]},$$scope:{ctx:C}}}),ql=new we({props:{code:`from transformers import AlbertTokenizer, FlaxAlbertForQuestionAnswering

tokenizer = AlbertTokenizer.from_pretrained("albert-base-v2")
model = FlaxAlbertForQuestionAnswering.from_pretrained("albert-base-v2")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AlbertTokenizer.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(){p=n("meta"),F=l(),g=n("h1"),b=n("a"),$=n("span"),k(_.$$.fragment),u=l(),x=n("span"),pe=a("ALBERT"),G=l(),M=n("h2"),Z=n("a"),U=n("span"),k(ee.$$.fragment),he=l(),B=n("span"),fe=a("Overview"),ae=l(),J=n("p"),L=a("The ALBERT model was proposed in "),te=n("a"),X=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:`),P=l(),Y=n("ul"),R=n("li"),me=a("Splitting the embedding matrix into two smaller matrices."),ue=l(),H=n("li"),ge=a("Using repeating layers split among groups."),ie=l(),q=n("p"),_e=a("The abstract from the paper is the following:"),Q=l(),oe=n("p"),se=n("em"),V=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.`),le=l(),ne=n("p"),N=a("Tips:"),de=l(),O=n("ul"),re=n("li"),h=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.`),E=l(),K=n("li"),Ae=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.`),ye=l(),j=n("p"),$e=a("This model was contributed by "),ke=n("a"),Fe=a("lysandre"),D=a(`. This model jax version was contributed by
`),S=n("a"),xe=a("kamalkraj"),Ee=a(". The original code can be found "),W=n("a"),Me=a("here"),ze=a("."),ce=l(),be=n("h2"),Mn=n("a"),dc=n("span"),k(Ws.$$.fragment),fg=l(),cc=n("span"),mg=a("AlbertConfig"),Hf=l(),Ve=n("div"),k(Us.$$.fragment),ug=l(),St=n("p"),gg=a("This is the configuration class to store the configuration of a "),Dl=n("a"),_g=a("AlbertModel"),bg=a(" or a "),Ol=n("a"),kg=a("TFAlbertModel"),vg=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
`),Bs=n("a"),Tg=a("xxlarge"),yg=a(" architecture."),wg=l(),xo=n("p"),Ag=a("Configuration objects inherit from "),Sl=n("a"),$g=a("PretrainedConfig"),Fg=a(` and can be used to control the model outputs. Read the
documentation from `),Wl=n("a"),xg=a("PretrainedConfig"),Eg=a(" for more information."),Mg=l(),pc=n("p"),zg=a("Examples:"),qg=l(),k(Rs.$$.fragment),Qf=l(),Eo=n("h2"),zn=n("a"),hc=n("span"),k(Hs.$$.fragment),Pg=l(),fc=n("span"),jg=a("AlbertTokenizer"),Vf=l(),qe=n("div"),k(Qs.$$.fragment),Cg=l(),Vs=n("p"),Ig=a("Construct an ALBERT tokenizer. Based on "),Js=n("a"),Lg=a("SentencePiece"),Ng=a("."),Dg=l(),Ks=n("p"),Og=a("This tokenizer inherits from "),Ul=n("a"),Sg=a("PreTrainedTokenizer"),Wg=a(` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Ug=l(),Gt=n("div"),k(Gs.$$.fragment),Bg=l(),mc=n("p"),Rg=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:`),Hg=l(),Xs=n("ul"),Bl=n("li"),Qg=a("single sequence: "),uc=n("code"),Vg=a("[CLS] X [SEP]"),Jg=l(),Rl=n("li"),Kg=a("pair of sequences: "),gc=n("code"),Gg=a("[CLS] A [SEP] B [SEP]"),Xg=l(),qn=n("div"),k(Zs.$$.fragment),Zg=l(),Ys=n("p"),Yg=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 `),_c=n("code"),e_=a("prepare_for_model"),t_=a(" method."),o_=l(),qt=n("div"),k(er.$$.fragment),n_=l(),bc=n("p"),s_=a(`Create a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT
sequence pair mask has the following format:`),r_=l(),k(tr.$$.fragment),a_=l(),Mo=n("p"),i_=a("If "),kc=n("code"),l_=a("token_ids_1"),d_=a(" is "),vc=n("code"),c_=a("None"),p_=a(", this method only returns the first portion of the mask (0s)."),h_=l(),Hl=n("div"),k(or.$$.fragment),Jf=l(),zo=n("h2"),Pn=n("a"),Tc=n("span"),k(nr.$$.fragment),f_=l(),yc=n("span"),m_=a("AlbertTokenizerFast"),Kf=l(),zt=n("div"),k(sr.$$.fragment),u_=l(),Wt=n("p"),g_=a("Construct a \u201Cfast\u201D ALBERT tokenizer (backed by HuggingFace\u2019s "),wc=n("em"),__=a("tokenizers"),b_=a(` library). Based on
`),rr=n("a"),k_=a("Unigram"),v_=a(`. This
tokenizer inherits from `),Ql=n("a"),T_=a("PreTrainedTokenizerFast"),y_=a(` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods`),w_=l(),Xt=n("div"),k(ar.$$.fragment),A_=l(),Ac=n("p"),$_=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:`),F_=l(),ir=n("ul"),Vl=n("li"),x_=a("single sequence: "),$c=n("code"),E_=a("[CLS] X [SEP]"),M_=l(),Jl=n("li"),z_=a("pair of sequences: "),Fc=n("code"),q_=a("[CLS] A [SEP] B [SEP]"),P_=l(),Pt=n("div"),k(lr.$$.fragment),j_=l(),xc=n("p"),C_=a(`Creates a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT
sequence pair mask has the following format:`),I_=l(),k(dr.$$.fragment),L_=l(),Ec=n("p"),N_=a("if token_ids_1 is None, only returns the first portion of the mask (0s)."),Gf=l(),qo=n("h2"),jn=n("a"),Mc=n("span"),k(cr.$$.fragment),D_=l(),zc=n("span"),O_=a("Albert specific outputs"),Xf=l(),Po=n("div"),k(pr.$$.fragment),S_=l(),hr=n("p"),W_=a("Output type of "),Kl=n("a"),U_=a("AlbertForPreTraining"),B_=a("."),Zf=l(),jo=n("div"),k(fr.$$.fragment),R_=l(),mr=n("p"),H_=a("Output type of "),Gl=n("a"),Q_=a("TFAlbertForPreTraining"),V_=a("."),Yf=l(),Co=n("h2"),Cn=n("a"),qc=n("span"),k(ur.$$.fragment),J_=l(),Pc=n("span"),K_=a("AlbertModel"),em=l(),Je=n("div"),k(gr.$$.fragment),G_=l(),jc=n("p"),X_=a("The bare ALBERT Model transformer outputting raw hidden-states without any specific head on top."),Z_=l(),_r=n("p"),Y_=a("This model inherits from "),Xl=n("a"),eb=a("PreTrainedModel"),tb=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.)`),ob=l(),br=n("p"),nb=a("This model is also a PyTorch "),kr=n("a"),sb=a("torch.nn.Module"),rb=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),ab=l(),tt=n("div"),k(vr.$$.fragment),ib=l(),Io=n("p"),lb=a("The "),Zl=n("a"),db=a("AlbertModel"),cb=a(" forward method, overrides the "),Cc=n("code"),pb=a("__call__"),hb=a(" special method."),fb=l(),k(In.$$.fragment),mb=l(),Ic=n("p"),ub=a("Example:"),gb=l(),k(Tr.$$.fragment),tm=l(),Lo=n("h2"),Ln=n("a"),Lc=n("span"),k(yr.$$.fragment),_b=l(),Nc=n("span"),bb=a("AlbertForPreTraining"),om=l(),Ke=n("div"),k(wr.$$.fragment),kb=l(),No=n("p"),vb=a("Albert Model with two heads on top as done during the pretraining: a "),Dc=n("code"),Tb=a("masked language modeling"),yb=a(` head and a
`),Oc=n("code"),wb=a("sentence order prediction (classification)"),Ab=a(" head."),$b=l(),Ar=n("p"),Fb=a("This model inherits from "),Yl=n("a"),xb=a("PreTrainedModel"),Eb=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.)`),Mb=l(),$r=n("p"),zb=a("This model is also a PyTorch "),Fr=n("a"),qb=a("torch.nn.Module"),Pb=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),jb=l(),ot=n("div"),k(xr.$$.fragment),Cb=l(),Do=n("p"),Ib=a("The "),ed=n("a"),Lb=a("AlbertForPreTraining"),Nb=a(" forward method, overrides the "),Sc=n("code"),Db=a("__call__"),Ob=a(" special method."),Sb=l(),k(Nn.$$.fragment),Wb=l(),Wc=n("p"),Ub=a("Example:"),Bb=l(),k(Er.$$.fragment),nm=l(),Oo=n("h2"),Dn=n("a"),Uc=n("span"),k(Mr.$$.fragment),Rb=l(),Bc=n("span"),Hb=a("AlbertForMaskedLM"),sm=l(),Ge=n("div"),k(zr.$$.fragment),Qb=l(),qr=n("p"),Vb=a("Albert Model with a "),Rc=n("code"),Jb=a("language modeling"),Kb=a(" head on top."),Gb=l(),Pr=n("p"),Xb=a("This model inherits from "),td=n("a"),Zb=a("PreTrainedModel"),Yb=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.)`),ek=l(),jr=n("p"),tk=a("This model is also a PyTorch "),Cr=n("a"),ok=a("torch.nn.Module"),nk=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),sk=l(),nt=n("div"),k(Ir.$$.fragment),rk=l(),So=n("p"),ak=a("The "),od=n("a"),ik=a("AlbertForMaskedLM"),lk=a(" forward method, overrides the "),Hc=n("code"),dk=a("__call__"),ck=a(" special method."),pk=l(),k(On.$$.fragment),hk=l(),Qc=n("p"),fk=a("Example:"),mk=l(),k(Lr.$$.fragment),rm=l(),Wo=n("h2"),Sn=n("a"),Vc=n("span"),k(Nr.$$.fragment),uk=l(),Jc=n("span"),gk=a("AlbertForSequenceClassification"),am=l(),Xe=n("div"),k(Dr.$$.fragment),_k=l(),Kc=n("p"),bk=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.`),kk=l(),Or=n("p"),vk=a("This model inherits from "),nd=n("a"),Tk=a("PreTrainedModel"),yk=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.)`),wk=l(),Sr=n("p"),Ak=a("This model is also a PyTorch "),Wr=n("a"),$k=a("torch.nn.Module"),Fk=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),xk=l(),Oe=n("div"),k(Ur.$$.fragment),Ek=l(),Uo=n("p"),Mk=a("The "),sd=n("a"),zk=a("AlbertForSequenceClassification"),qk=a(" forward method, overrides the "),Gc=n("code"),Pk=a("__call__"),jk=a(" special method."),Ck=l(),k(Wn.$$.fragment),Ik=l(),Xc=n("p"),Lk=a("Example of single-label classification:"),Nk=l(),k(Br.$$.fragment),Dk=l(),Zc=n("p"),Ok=a("Example of multi-label classification:"),Sk=l(),k(Rr.$$.fragment),im=l(),Bo=n("h2"),Un=n("a"),Yc=n("span"),k(Hr.$$.fragment),Wk=l(),ep=n("span"),Uk=a("AlbertForMultipleChoice"),lm=l(),Ze=n("div"),k(Qr.$$.fragment),Bk=l(),tp=n("p"),Rk=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.`),Hk=l(),Vr=n("p"),Qk=a("This model inherits from "),rd=n("a"),Vk=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.)`),Kk=l(),Jr=n("p"),Gk=a("This model is also a PyTorch "),Kr=n("a"),Xk=a("torch.nn.Module"),Zk=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Yk=l(),st=n("div"),k(Gr.$$.fragment),ev=l(),Ro=n("p"),tv=a("The "),ad=n("a"),ov=a("AlbertForMultipleChoice"),nv=a(" forward method, overrides the "),op=n("code"),sv=a("__call__"),rv=a(" special method."),av=l(),k(Bn.$$.fragment),iv=l(),np=n("p"),lv=a("Example:"),dv=l(),k(Xr.$$.fragment),dm=l(),Ho=n("h2"),Rn=n("a"),sp=n("span"),k(Zr.$$.fragment),cv=l(),rp=n("span"),pv=a("AlbertForTokenClassification"),cm=l(),Ye=n("div"),k(Yr.$$.fragment),hv=l(),ap=n("p"),fv=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.`),mv=l(),ea=n("p"),uv=a("This model inherits from "),id=n("a"),gv=a("PreTrainedModel"),_v=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.)`),bv=l(),ta=n("p"),kv=a("This model is also a PyTorch "),oa=n("a"),vv=a("torch.nn.Module"),Tv=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),yv=l(),rt=n("div"),k(na.$$.fragment),wv=l(),Qo=n("p"),Av=a("The "),ld=n("a"),$v=a("AlbertForTokenClassification"),Fv=a(" forward method, overrides the "),ip=n("code"),xv=a("__call__"),Ev=a(" special method."),Mv=l(),k(Hn.$$.fragment),zv=l(),lp=n("p"),qv=a("Example:"),Pv=l(),k(sa.$$.fragment),pm=l(),Vo=n("h2"),Qn=n("a"),dp=n("span"),k(ra.$$.fragment),jv=l(),cp=n("span"),Cv=a("AlbertForQuestionAnswering"),hm=l(),et=n("div"),k(aa.$$.fragment),Iv=l(),Jo=n("p"),Lv=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 `),pp=n("code"),Nv=a("span start logits"),Dv=a(" and "),hp=n("code"),Ov=a("span end logits"),Sv=a(")."),Wv=l(),ia=n("p"),Uv=a("This model inherits from "),dd=n("a"),Bv=a("PreTrainedModel"),Rv=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.)`),Hv=l(),la=n("p"),Qv=a("This model is also a PyTorch "),da=n("a"),Vv=a("torch.nn.Module"),Jv=a(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Kv=l(),at=n("div"),k(ca.$$.fragment),Gv=l(),Ko=n("p"),Xv=a("The "),cd=n("a"),Zv=a("AlbertForQuestionAnswering"),Yv=a(" forward method, overrides the "),fp=n("code"),eT=a("__call__"),tT=a(" special method."),oT=l(),k(Vn.$$.fragment),nT=l(),mp=n("p"),sT=a("Example:"),rT=l(),k(pa.$$.fragment),fm=l(),Go=n("h2"),Jn=n("a"),up=n("span"),k(ha.$$.fragment),aT=l(),gp=n("span"),iT=a("TFAlbertModel"),mm=l(),Se=n("div"),k(fa.$$.fragment),lT=l(),_p=n("p"),dT=a("The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),cT=l(),ma=n("p"),pT=a("This model inherits from "),pd=n("a"),hT=a("TFPreTrainedModel"),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.)`),mT=l(),ua=n("p"),uT=a("This model is also a "),ga=n("a"),gT=a("tf.keras.Model"),_T=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.`),bT=l(),k(Kn.$$.fragment),kT=l(),it=n("div"),k(_a.$$.fragment),vT=l(),Xo=n("p"),TT=a("The "),hd=n("a"),yT=a("TFAlbertModel"),wT=a(" forward method, overrides the "),bp=n("code"),AT=a("__call__"),$T=a(" special method."),FT=l(),k(Gn.$$.fragment),xT=l(),kp=n("p"),ET=a("Example:"),MT=l(),k(ba.$$.fragment),um=l(),Zo=n("h2"),Xn=n("a"),vp=n("span"),k(ka.$$.fragment),zT=l(),Tp=n("span"),qT=a("TFAlbertForPreTraining"),gm=l(),We=n("div"),k(va.$$.fragment),PT=l(),Yo=n("p"),jT=a("Albert Model with two heads on top for pretraining: a "),yp=n("code"),CT=a("masked language modeling"),IT=a(" head and a "),wp=n("code"),LT=a("sentence order prediction"),NT=a(" (classification) head."),DT=l(),Ta=n("p"),OT=a("This model inherits from "),fd=n("a"),ST=a("TFPreTrainedModel"),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.)`),UT=l(),ya=n("p"),BT=a("This model is also a "),wa=n("a"),RT=a("tf.keras.Model"),HT=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.`),QT=l(),k(Zn.$$.fragment),VT=l(),lt=n("div"),k(Aa.$$.fragment),JT=l(),en=n("p"),KT=a("The "),md=n("a"),GT=a("TFAlbertForPreTraining"),XT=a(" forward method, overrides the "),Ap=n("code"),ZT=a("__call__"),YT=a(" special method."),e1=l(),k(Yn.$$.fragment),t1=l(),$p=n("p"),o1=a("Example:"),n1=l(),k($a.$$.fragment),_m=l(),tn=n("h2"),es=n("a"),Fp=n("span"),k(Fa.$$.fragment),s1=l(),xp=n("span"),r1=a("TFAlbertForMaskedLM"),bm=l(),Ue=n("div"),k(xa.$$.fragment),a1=l(),Ea=n("p"),i1=a("Albert Model with a "),Ep=n("code"),l1=a("language modeling"),d1=a(" head on top."),c1=l(),Ma=n("p"),p1=a("This model inherits from "),ud=n("a"),h1=a("TFPreTrainedModel"),f1=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.)`),m1=l(),za=n("p"),u1=a("This model is also a "),qa=n("a"),g1=a("tf.keras.Model"),_1=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.`),b1=l(),k(ts.$$.fragment),k1=l(),dt=n("div"),k(Pa.$$.fragment),v1=l(),on=n("p"),T1=a("The "),gd=n("a"),y1=a("TFAlbertForMaskedLM"),w1=a(" forward method, overrides the "),Mp=n("code"),A1=a("__call__"),$1=a(" special method."),F1=l(),k(os.$$.fragment),x1=l(),zp=n("p"),E1=a("Example:"),M1=l(),k(ja.$$.fragment),km=l(),nn=n("h2"),ns=n("a"),qp=n("span"),k(Ca.$$.fragment),z1=l(),Pp=n("span"),q1=a("TFAlbertForSequenceClassification"),vm=l(),Be=n("div"),k(Ia.$$.fragment),P1=l(),jp=n("p"),j1=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.`),C1=l(),La=n("p"),I1=a("This model inherits from "),_d=n("a"),L1=a("TFPreTrainedModel"),N1=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.)`),D1=l(),Na=n("p"),O1=a("This model is also a "),Da=n("a"),S1=a("tf.keras.Model"),W1=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.`),U1=l(),k(ss.$$.fragment),B1=l(),ct=n("div"),k(Oa.$$.fragment),R1=l(),sn=n("p"),H1=a("The "),bd=n("a"),Q1=a("TFAlbertForSequenceClassification"),V1=a(" forward method, overrides the "),Cp=n("code"),J1=a("__call__"),K1=a(" special method."),G1=l(),k(rs.$$.fragment),X1=l(),Ip=n("p"),Z1=a("Example:"),Y1=l(),k(Sa.$$.fragment),Tm=l(),rn=n("h2"),as=n("a"),Lp=n("span"),k(Wa.$$.fragment),ey=l(),Np=n("span"),ty=a("TFAlbertForMultipleChoice"),ym=l(),Re=n("div"),k(Ua.$$.fragment),oy=l(),Dp=n("p"),ny=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.`),sy=l(),Ba=n("p"),ry=a("This model inherits from "),kd=n("a"),ay=a("TFPreTrainedModel"),iy=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.)`),ly=l(),Ra=n("p"),dy=a("This model is also a "),Ha=n("a"),cy=a("tf.keras.Model"),py=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.`),hy=l(),k(is.$$.fragment),fy=l(),pt=n("div"),k(Qa.$$.fragment),my=l(),an=n("p"),uy=a("The "),vd=n("a"),gy=a("TFAlbertForMultipleChoice"),_y=a(" forward method, overrides the "),Op=n("code"),by=a("__call__"),ky=a(" special method."),vy=l(),k(ls.$$.fragment),Ty=l(),Sp=n("p"),yy=a("Example:"),wy=l(),k(Va.$$.fragment),wm=l(),ln=n("h2"),ds=n("a"),Wp=n("span"),k(Ja.$$.fragment),Ay=l(),Up=n("span"),$y=a("TFAlbertForTokenClassification"),Am=l(),He=n("div"),k(Ka.$$.fragment),Fy=l(),Bp=n("p"),xy=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.`),Ey=l(),Ga=n("p"),My=a("This model inherits from "),Td=n("a"),zy=a("TFPreTrainedModel"),qy=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.)`),Py=l(),Xa=n("p"),jy=a("This model is also a "),Za=n("a"),Cy=a("tf.keras.Model"),Iy=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.`),Ly=l(),k(cs.$$.fragment),Ny=l(),ht=n("div"),k(Ya.$$.fragment),Dy=l(),dn=n("p"),Oy=a("The "),yd=n("a"),Sy=a("TFAlbertForTokenClassification"),Wy=a(" forward method, overrides the "),Rp=n("code"),Uy=a("__call__"),By=a(" special method."),Ry=l(),k(ps.$$.fragment),Hy=l(),Hp=n("p"),Qy=a("Example:"),Vy=l(),k(ei.$$.fragment),$m=l(),cn=n("h2"),hs=n("a"),Qp=n("span"),k(ti.$$.fragment),Jy=l(),Vp=n("span"),Ky=a("TFAlbertForQuestionAnswering"),Fm=l(),Qe=n("div"),k(oi.$$.fragment),Gy=l(),pn=n("p"),Xy=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 `),Jp=n("code"),Zy=a("span start logits"),Yy=a(" and "),Kp=n("code"),ew=a("span end logits"),tw=a(")."),ow=l(),ni=n("p"),nw=a("This model inherits from "),wd=n("a"),sw=a("TFPreTrainedModel"),rw=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.)`),aw=l(),si=n("p"),iw=a("This model is also a "),ri=n("a"),lw=a("tf.keras.Model"),dw=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.`),cw=l(),k(fs.$$.fragment),pw=l(),ft=n("div"),k(ai.$$.fragment),hw=l(),hn=n("p"),fw=a("The "),Ad=n("a"),mw=a("TFAlbertForQuestionAnswering"),uw=a(" forward method, overrides the "),Gp=n("code"),gw=a("__call__"),_w=a(" special method."),bw=l(),k(ms.$$.fragment),kw=l(),Xp=n("p"),vw=a("Example:"),Tw=l(),k(ii.$$.fragment),xm=l(),fn=n("h2"),us=n("a"),Zp=n("span"),k(li.$$.fragment),yw=l(),Yp=n("span"),ww=a("FlaxAlbertModel"),Em=l(),Pe=n("div"),k(di.$$.fragment),Aw=l(),eh=n("p"),$w=a("The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),Fw=l(),ci=n("p"),xw=a("This model inherits from "),$d=n("a"),Ew=a("FlaxPreTrainedModel"),Mw=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)`),zw=l(),pi=n("p"),qw=a("This model is also a Flax Linen "),hi=n("a"),Pw=a("flax.linen.Module"),jw=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.`),Cw=l(),th=n("p"),Iw=a("Finally, this model supports inherent JAX features such as:"),Lw=l(),Ut=n("ul"),oh=n("li"),fi=n("a"),Nw=a("Just-In-Time (JIT) compilation"),Dw=l(),nh=n("li"),mi=n("a"),Ow=a("Automatic Differentiation"),Sw=l(),sh=n("li"),ui=n("a"),Ww=a("Vectorization"),Uw=l(),rh=n("li"),gi=n("a"),Bw=a("Parallelization"),Rw=l(),mt=n("div"),k(_i.$$.fragment),Hw=l(),mn=n("p"),Qw=a("The "),ah=n("code"),Vw=a("FlaxAlbertPreTrainedModel"),Jw=a("forward method, overrides the "),ih=n("code"),Kw=a("__call__"),Gw=a(" special method."),Xw=l(),k(gs.$$.fragment),Zw=l(),lh=n("p"),Yw=a("Example:"),eA=l(),k(bi.$$.fragment),Mm=l(),un=n("h2"),_s=n("a"),dh=n("span"),k(ki.$$.fragment),tA=l(),ch=n("span"),oA=a("FlaxAlbertForPreTraining"),zm=l(),je=n("div"),k(vi.$$.fragment),nA=l(),gn=n("p"),sA=a("Albert Model with two heads on top as done during the pretraining: a "),ph=n("code"),rA=a("masked language modeling"),aA=a(` head and a
`),hh=n("code"),iA=a("sentence order prediction (classification)"),lA=a(" head."),dA=l(),Ti=n("p"),cA=a("This model inherits from "),Fd=n("a"),pA=a("FlaxPreTrainedModel"),hA=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)`),fA=l(),yi=n("p"),mA=a("This model is also a Flax Linen "),wi=n("a"),uA=a("flax.linen.Module"),gA=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.`),_A=l(),fh=n("p"),bA=a("Finally, this model supports inherent JAX features such as:"),kA=l(),Bt=n("ul"),mh=n("li"),Ai=n("a"),vA=a("Just-In-Time (JIT) compilation"),TA=l(),uh=n("li"),$i=n("a"),yA=a("Automatic Differentiation"),wA=l(),gh=n("li"),Fi=n("a"),AA=a("Vectorization"),$A=l(),_h=n("li"),xi=n("a"),FA=a("Parallelization"),xA=l(),ut=n("div"),k(Ei.$$.fragment),EA=l(),_n=n("p"),MA=a("The "),bh=n("code"),zA=a("FlaxAlbertPreTrainedModel"),qA=a("forward method, overrides the "),kh=n("code"),PA=a("__call__"),jA=a(" special method."),CA=l(),k(bs.$$.fragment),IA=l(),vh=n("p"),LA=a("Example:"),NA=l(),k(Mi.$$.fragment),qm=l(),bn=n("h2"),ks=n("a"),Th=n("span"),k(zi.$$.fragment),DA=l(),yh=n("span"),OA=a("FlaxAlbertForMaskedLM"),Pm=l(),Ce=n("div"),k(qi.$$.fragment),SA=l(),Pi=n("p"),WA=a("Albert Model with a "),wh=n("code"),UA=a("language modeling"),BA=a(" head on top."),RA=l(),ji=n("p"),HA=a("This model inherits from "),xd=n("a"),QA=a("FlaxPreTrainedModel"),VA=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)`),JA=l(),Ci=n("p"),KA=a("This model is also a Flax Linen "),Ii=n("a"),GA=a("flax.linen.Module"),XA=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.`),ZA=l(),Ah=n("p"),YA=a("Finally, this model supports inherent JAX features such as:"),e2=l(),Rt=n("ul"),$h=n("li"),Li=n("a"),t2=a("Just-In-Time (JIT) compilation"),o2=l(),Fh=n("li"),Ni=n("a"),n2=a("Automatic Differentiation"),s2=l(),xh=n("li"),Di=n("a"),r2=a("Vectorization"),a2=l(),Eh=n("li"),Oi=n("a"),i2=a("Parallelization"),l2=l(),gt=n("div"),k(Si.$$.fragment),d2=l(),kn=n("p"),c2=a("The "),Mh=n("code"),p2=a("FlaxAlbertPreTrainedModel"),h2=a("forward method, overrides the "),zh=n("code"),f2=a("__call__"),m2=a(" special method."),u2=l(),k(vs.$$.fragment),g2=l(),qh=n("p"),_2=a("Example:"),b2=l(),k(Wi.$$.fragment),jm=l(),vn=n("h2"),Ts=n("a"),Ph=n("span"),k(Ui.$$.fragment),k2=l(),jh=n("span"),v2=a("FlaxAlbertForSequenceClassification"),Cm=l(),Ie=n("div"),k(Bi.$$.fragment),T2=l(),Ch=n("p"),y2=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.`),w2=l(),Ri=n("p"),A2=a("This model inherits from "),Ed=n("a"),$2=a("FlaxPreTrainedModel"),F2=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)`),x2=l(),Hi=n("p"),E2=a("This model is also a Flax Linen "),Qi=n("a"),M2=a("flax.linen.Module"),z2=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.`),q2=l(),Ih=n("p"),P2=a("Finally, this model supports inherent JAX features such as:"),j2=l(),Ht=n("ul"),Lh=n("li"),Vi=n("a"),C2=a("Just-In-Time (JIT) compilation"),I2=l(),Nh=n("li"),Ji=n("a"),L2=a("Automatic Differentiation"),N2=l(),Dh=n("li"),Ki=n("a"),D2=a("Vectorization"),O2=l(),Oh=n("li"),Gi=n("a"),S2=a("Parallelization"),W2=l(),_t=n("div"),k(Xi.$$.fragment),U2=l(),Tn=n("p"),B2=a("The "),Sh=n("code"),R2=a("FlaxAlbertPreTrainedModel"),H2=a("forward method, overrides the "),Wh=n("code"),Q2=a("__call__"),V2=a(" special method."),J2=l(),k(ys.$$.fragment),K2=l(),Uh=n("p"),G2=a("Example:"),X2=l(),k(Zi.$$.fragment),Im=l(),yn=n("h2"),ws=n("a"),Bh=n("span"),k(Yi.$$.fragment),Z2=l(),Rh=n("span"),Y2=a("FlaxAlbertForMultipleChoice"),Lm=l(),Le=n("div"),k(el.$$.fragment),e$=l(),Hh=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.`),o$=l(),tl=n("p"),n$=a("This model inherits from "),Md=n("a"),s$=a("FlaxPreTrainedModel"),r$=a(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),a$=l(),ol=n("p"),i$=a("This model is also a Flax Linen "),nl=n("a"),l$=a("flax.linen.Module"),d$=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.`),c$=l(),Qh=n("p"),p$=a("Finally, this model supports inherent JAX features such as:"),h$=l(),Qt=n("ul"),Vh=n("li"),sl=n("a"),f$=a("Just-In-Time (JIT) compilation"),m$=l(),Jh=n("li"),rl=n("a"),u$=a("Automatic Differentiation"),g$=l(),Kh=n("li"),al=n("a"),_$=a("Vectorization"),b$=l(),Gh=n("li"),il=n("a"),k$=a("Parallelization"),v$=l(),bt=n("div"),k(ll.$$.fragment),T$=l(),wn=n("p"),y$=a("The "),Xh=n("code"),w$=a("FlaxAlbertPreTrainedModel"),A$=a("forward method, overrides the "),Zh=n("code"),$$=a("__call__"),F$=a(" special method."),x$=l(),k(As.$$.fragment),E$=l(),Yh=n("p"),M$=a("Example:"),z$=l(),k(dl.$$.fragment),Nm=l(),An=n("h2"),$s=n("a"),ef=n("span"),k(cl.$$.fragment),q$=l(),tf=n("span"),P$=a("FlaxAlbertForTokenClassification"),Dm=l(),Ne=n("div"),k(pl.$$.fragment),j$=l(),of=n("p"),C$=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.`),I$=l(),hl=n("p"),L$=a("This model inherits from "),zd=n("a"),N$=a("FlaxPreTrainedModel"),D$=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)`),O$=l(),fl=n("p"),S$=a("This model is also a Flax Linen "),ml=n("a"),W$=a("flax.linen.Module"),U$=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.`),B$=l(),nf=n("p"),R$=a("Finally, this model supports inherent JAX features such as:"),H$=l(),Vt=n("ul"),sf=n("li"),ul=n("a"),Q$=a("Just-In-Time (JIT) compilation"),V$=l(),rf=n("li"),gl=n("a"),J$=a("Automatic Differentiation"),K$=l(),af=n("li"),_l=n("a"),G$=a("Vectorization"),X$=l(),lf=n("li"),bl=n("a"),Z$=a("Parallelization"),Y$=l(),kt=n("div"),k(kl.$$.fragment),eF=l(),$n=n("p"),tF=a("The "),df=n("code"),oF=a("FlaxAlbertPreTrainedModel"),nF=a("forward method, overrides the "),cf=n("code"),sF=a("__call__"),rF=a(" special method."),aF=l(),k(Fs.$$.fragment),iF=l(),pf=n("p"),lF=a("Example:"),dF=l(),k(vl.$$.fragment),Om=l(),Fn=n("h2"),xs=n("a"),hf=n("span"),k(Tl.$$.fragment),cF=l(),ff=n("span"),pF=a("FlaxAlbertForQuestionAnswering"),Sm=l(),De=n("div"),k(yl.$$.fragment),hF=l(),xn=n("p"),fF=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 `),mf=n("code"),mF=a("span start logits"),uF=a(" and "),uf=n("code"),gF=a("span end logits"),_F=a(")."),bF=l(),wl=n("p"),kF=a("This model inherits from "),qd=n("a"),vF=a("FlaxPreTrainedModel"),TF=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)`),yF=l(),Al=n("p"),wF=a("This model is also a Flax Linen "),$l=n("a"),AF=a("flax.linen.Module"),$F=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.`),FF=l(),gf=n("p"),xF=a("Finally, this model supports inherent JAX features such as:"),EF=l(),Jt=n("ul"),_f=n("li"),Fl=n("a"),MF=a("Just-In-Time (JIT) compilation"),zF=l(),bf=n("li"),xl=n("a"),qF=a("Automatic Differentiation"),PF=l(),kf=n("li"),El=n("a"),jF=a("Vectorization"),CF=l(),vf=n("li"),Ml=n("a"),IF=a("Parallelization"),LF=l(),vt=n("div"),k(zl.$$.fragment),NF=l(),En=n("p"),DF=a("The "),Tf=n("code"),OF=a("FlaxAlbertPreTrainedModel"),SF=a("forward method, overrides the "),yf=n("code"),WF=a("__call__"),UF=a(" special method."),BF=l(),k(Es.$$.fragment),RF=l(),wf=n("p"),HF=a("Example:"),QF=l(),k(ql.$$.fragment),this.h()},l(o){const m=Az('[data-svelte="svelte-1phssyn"]',document.head);p=s(m,"META",{name:!0,content:!0}),m.forEach(t),F=d(o),g=s(o,"H1",{class:!0});var Pl=r(g);b=s(Pl,"A",{id:!0,class:!0,href:!0});var Af=r(b);$=s(Af,"SPAN",{});var $f=r($);v(_.$$.fragment,$f),$f.forEach(t),Af.forEach(t),u=d(Pl),x=s(Pl,"SPAN",{});var Ff=r(x);pe=i(Ff,"ALBERT"),Ff.forEach(t),Pl.forEach(t),G=d(o),M=s(o,"H2",{class:!0});var jl=r(M);Z=s(jl,"A",{id:!0,class:!0,href:!0});var xf=r(Z);U=s(xf,"SPAN",{});var Ef=r(U);v(ee.$$.fragment,Ef),Ef.forEach(t),xf.forEach(t),he=d(jl),B=s(jl,"SPAN",{});var Mf=r(B);fe=i(Mf,"Overview"),Mf.forEach(t),jl.forEach(t),ae=d(o),J=s(o,"P",{});var Cl=r(J);L=i(Cl,"The ALBERT model was proposed in "),te=s(Cl,"A",{href:!0,rel:!0});var zf=r(te);X=i(zf,"ALBERT: A Lite BERT for Self-supervised Learning of Language Representations"),zf.forEach(t),z=i(Cl,` 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:`),Cl.forEach(t),P=d(o),Y=s(o,"UL",{});var Il=r(Y);R=s(Il,"LI",{});var qf=r(R);me=i(qf,"Splitting the embedding matrix into two smaller matrices."),qf.forEach(t),ue=d(Il),H=s(Il,"LI",{});var Pf=r(H);ge=i(Pf,"Using repeating layers split among groups."),Pf.forEach(t),Il.forEach(t),ie=d(o),q=s(o,"P",{});var jf=r(q);_e=i(jf,"The abstract from the paper is the following:"),jf.forEach(t),Q=d(o),oe=s(o,"P",{});var Cf=r(oe);se=s(Cf,"EM",{});var If=r(se);V=i(If,`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.`),If.forEach(t),Cf.forEach(t),le=d(o),ne=s(o,"P",{});var Lf=r(ne);N=i(Lf,"Tips:"),Lf.forEach(t),de=d(o),O=s(o,"UL",{});var Ll=r(O);re=s(Ll,"LI",{});var Nf=r(re);h=i(Nf,`ALBERT is a model with absolute position embeddings so it\u2019s usually advised to pad the inputs on the right rather
than the left.`),Nf.forEach(t),E=d(Ll),K=s(Ll,"LI",{});var Df=r(K);Ae=i(Df,`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.`),Df.forEach(t),Ll.forEach(t),ye=d(o),j=s(o,"P",{});var Kt=r(j);$e=i(Kt,"This model was contributed by "),ke=s(Kt,"A",{href:!0,rel:!0});var Of=r(ke);Fe=i(Of,"lysandre"),Of.forEach(t),D=i(Kt,`. This model jax version was contributed by
`),S=s(Kt,"A",{href:!0,rel:!0});var Sf=r(S);xe=i(Sf,"kamalkraj"),Sf.forEach(t),Ee=i(Kt,". The original code can be found "),W=s(Kt,"A",{href:!0,rel:!0});var Wf=r(W);Me=i(Wf,"here"),Wf.forEach(t),ze=i(Kt,"."),Kt.forEach(t),ce=d(o),be=s(o,"H2",{class:!0});var Nl=r(be);Mn=s(Nl,"A",{id:!0,class:!0,href:!0});var Uf=r(Mn);dc=s(Uf,"SPAN",{});var Bf=r(dc);v(Ws.$$.fragment,Bf),Bf.forEach(t),Uf.forEach(t),fg=d(Nl),cc=s(Nl,"SPAN",{});var Rf=r(cc);mg=i(Rf,"AlbertConfig"),Rf.forEach(t),Nl.forEach(t),Hf=d(o),Ve=s(o,"DIV",{class:!0});var Zt=r(Ve);v(Us.$$.fragment,Zt),ug=d(Zt),St=s(Zt,"P",{});var Ms=r(St);gg=i(Ms,"This is the configuration class to store the configuration of a "),Dl=s(Ms,"A",{href:!0});var XF=r(Dl);_g=i(XF,"AlbertModel"),XF.forEach(t),bg=i(Ms," or a "),Ol=s(Ms,"A",{href:!0});var ZF=r(Ol);kg=i(ZF,"TFAlbertModel"),ZF.forEach(t),vg=i(Ms,`. 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
`),Bs=s(Ms,"A",{href:!0,rel:!0});var YF=r(Bs);Tg=i(YF,"xxlarge"),YF.forEach(t),yg=i(Ms," architecture."),Ms.forEach(t),wg=d(Zt),xo=s(Zt,"P",{});var Pd=r(xo);Ag=i(Pd,"Configuration objects inherit from "),Sl=s(Pd,"A",{href:!0});var e0=r(Sl);$g=i(e0,"PretrainedConfig"),e0.forEach(t),Fg=i(Pd,` and can be used to control the model outputs. Read the
documentation from `),Wl=s(Pd,"A",{href:!0});var t0=r(Wl);xg=i(t0,"PretrainedConfig"),t0.forEach(t),Eg=i(Pd," for more information."),Pd.forEach(t),Mg=d(Zt),pc=s(Zt,"P",{});var o0=r(pc);zg=i(o0,"Examples:"),o0.forEach(t),qg=d(Zt),v(Rs.$$.fragment,Zt),Zt.forEach(t),Qf=d(o),Eo=s(o,"H2",{class:!0});var Um=r(Eo);zn=s(Um,"A",{id:!0,class:!0,href:!0});var n0=r(zn);hc=s(n0,"SPAN",{});var s0=r(hc);v(Hs.$$.fragment,s0),s0.forEach(t),n0.forEach(t),Pg=d(Um),fc=s(Um,"SPAN",{});var r0=r(fc);jg=i(r0,"AlbertTokenizer"),r0.forEach(t),Um.forEach(t),Vf=d(o),qe=s(o,"DIV",{class:!0});var Tt=r(qe);v(Qs.$$.fragment,Tt),Cg=d(Tt),Vs=s(Tt,"P",{});var Bm=r(Vs);Ig=i(Bm,"Construct an ALBERT tokenizer. Based on "),Js=s(Bm,"A",{href:!0,rel:!0});var a0=r(Js);Lg=i(a0,"SentencePiece"),a0.forEach(t),Ng=i(Bm,"."),Bm.forEach(t),Dg=d(Tt),Ks=s(Tt,"P",{});var Rm=r(Ks);Og=i(Rm,"This tokenizer inherits from "),Ul=s(Rm,"A",{href:!0});var i0=r(Ul);Sg=i(i0,"PreTrainedTokenizer"),i0.forEach(t),Wg=i(Rm,` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Rm.forEach(t),Ug=d(Tt),Gt=s(Tt,"DIV",{class:!0});var jd=r(Gt);v(Gs.$$.fragment,jd),Bg=d(jd),mc=s(jd,"P",{});var l0=r(mc);Rg=i(l0,`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:`),l0.forEach(t),Hg=d(jd),Xs=s(jd,"UL",{});var Hm=r(Xs);Bl=s(Hm,"LI",{});var VF=r(Bl);Qg=i(VF,"single sequence: "),uc=s(VF,"CODE",{});var d0=r(uc);Vg=i(d0,"[CLS] X [SEP]"),d0.forEach(t),VF.forEach(t),Jg=d(Hm),Rl=s(Hm,"LI",{});var JF=r(Rl);Kg=i(JF,"pair of sequences: "),gc=s(JF,"CODE",{});var c0=r(gc);Gg=i(c0,"[CLS] A [SEP] B [SEP]"),c0.forEach(t),JF.forEach(t),Hm.forEach(t),jd.forEach(t),Xg=d(Tt),qn=s(Tt,"DIV",{class:!0});var Qm=r(qn);v(Zs.$$.fragment,Qm),Zg=d(Qm),Ys=s(Qm,"P",{});var Vm=r(Ys);Yg=i(Vm,`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),_c=s(Vm,"CODE",{});var p0=r(_c);e_=i(p0,"prepare_for_model"),p0.forEach(t),t_=i(Vm," method."),Vm.forEach(t),Qm.forEach(t),o_=d(Tt),qt=s(Tt,"DIV",{class:!0});var zs=r(qt);v(er.$$.fragment,zs),n_=d(zs),bc=s(zs,"P",{});var h0=r(bc);s_=i(h0,`Create a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT
sequence pair mask has the following format:`),h0.forEach(t),r_=d(zs),v(tr.$$.fragment,zs),a_=d(zs),Mo=s(zs,"P",{});var Cd=r(Mo);i_=i(Cd,"If "),kc=s(Cd,"CODE",{});var f0=r(kc);l_=i(f0,"token_ids_1"),f0.forEach(t),d_=i(Cd," is "),vc=s(Cd,"CODE",{});var m0=r(vc);c_=i(m0,"None"),m0.forEach(t),p_=i(Cd,", this method only returns the first portion of the mask (0s)."),Cd.forEach(t),zs.forEach(t),h_=d(Tt),Hl=s(Tt,"DIV",{class:!0});var u0=r(Hl);v(or.$$.fragment,u0),u0.forEach(t),Tt.forEach(t),Jf=d(o),zo=s(o,"H2",{class:!0});var Jm=r(zo);Pn=s(Jm,"A",{id:!0,class:!0,href:!0});var g0=r(Pn);Tc=s(g0,"SPAN",{});var _0=r(Tc);v(nr.$$.fragment,_0),_0.forEach(t),g0.forEach(t),f_=d(Jm),yc=s(Jm,"SPAN",{});var b0=r(yc);m_=i(b0,"AlbertTokenizerFast"),b0.forEach(t),Jm.forEach(t),Kf=d(o),zt=s(o,"DIV",{class:!0});var qs=r(zt);v(sr.$$.fragment,qs),u_=d(qs),Wt=s(qs,"P",{});var Ps=r(Wt);g_=i(Ps,"Construct a \u201Cfast\u201D ALBERT tokenizer (backed by HuggingFace\u2019s "),wc=s(Ps,"EM",{});var k0=r(wc);__=i(k0,"tokenizers"),k0.forEach(t),b_=i(Ps,` library). Based on
`),rr=s(Ps,"A",{href:!0,rel:!0});var v0=r(rr);k_=i(v0,"Unigram"),v0.forEach(t),v_=i(Ps,`. This
tokenizer inherits from `),Ql=s(Ps,"A",{href:!0});var T0=r(Ql);T_=i(T0,"PreTrainedTokenizerFast"),T0.forEach(t),y_=i(Ps,` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods`),Ps.forEach(t),w_=d(qs),Xt=s(qs,"DIV",{class:!0});var Id=r(Xt);v(ar.$$.fragment,Id),A_=d(Id),Ac=s(Id,"P",{});var y0=r(Ac);$_=i(y0,`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:`),y0.forEach(t),F_=d(Id),ir=s(Id,"UL",{});var Km=r(ir);Vl=s(Km,"LI",{});var KF=r(Vl);x_=i(KF,"single sequence: "),$c=s(KF,"CODE",{});var w0=r($c);E_=i(w0,"[CLS] X [SEP]"),w0.forEach(t),KF.forEach(t),M_=d(Km),Jl=s(Km,"LI",{});var GF=r(Jl);z_=i(GF,"pair of sequences: "),Fc=s(GF,"CODE",{});var A0=r(Fc);q_=i(A0,"[CLS] A [SEP] B [SEP]"),A0.forEach(t),GF.forEach(t),Km.forEach(t),Id.forEach(t),P_=d(qs),Pt=s(qs,"DIV",{class:!0});var js=r(Pt);v(lr.$$.fragment,js),j_=d(js),xc=s(js,"P",{});var $0=r(xc);C_=i($0,`Creates a mask from the two sequences passed to be used in a sequence-pair classification task. An ALBERT
sequence pair mask has the following format:`),$0.forEach(t),I_=d(js),v(dr.$$.fragment,js),L_=d(js),Ec=s(js,"P",{});var F0=r(Ec);N_=i(F0,"if token_ids_1 is None, only returns the first portion of the mask (0s)."),F0.forEach(t),js.forEach(t),qs.forEach(t),Gf=d(o),qo=s(o,"H2",{class:!0});var Gm=r(qo);jn=s(Gm,"A",{id:!0,class:!0,href:!0});var x0=r(jn);Mc=s(x0,"SPAN",{});var E0=r(Mc);v(cr.$$.fragment,E0),E0.forEach(t),x0.forEach(t),D_=d(Gm),zc=s(Gm,"SPAN",{});var M0=r(zc);O_=i(M0,"Albert specific outputs"),M0.forEach(t),Gm.forEach(t),Xf=d(o),Po=s(o,"DIV",{class:!0});var Xm=r(Po);v(pr.$$.fragment,Xm),S_=d(Xm),hr=s(Xm,"P",{});var Zm=r(hr);W_=i(Zm,"Output type of "),Kl=s(Zm,"A",{href:!0});var z0=r(Kl);U_=i(z0,"AlbertForPreTraining"),z0.forEach(t),B_=i(Zm,"."),Zm.forEach(t),Xm.forEach(t),Zf=d(o),jo=s(o,"DIV",{class:!0});var Ym=r(jo);v(fr.$$.fragment,Ym),R_=d(Ym),mr=s(Ym,"P",{});var eu=r(mr);H_=i(eu,"Output type of "),Gl=s(eu,"A",{href:!0});var q0=r(Gl);Q_=i(q0,"TFAlbertForPreTraining"),q0.forEach(t),V_=i(eu,"."),eu.forEach(t),Ym.forEach(t),Yf=d(o),Co=s(o,"H2",{class:!0});var tu=r(Co);Cn=s(tu,"A",{id:!0,class:!0,href:!0});var P0=r(Cn);qc=s(P0,"SPAN",{});var j0=r(qc);v(ur.$$.fragment,j0),j0.forEach(t),P0.forEach(t),J_=d(tu),Pc=s(tu,"SPAN",{});var C0=r(Pc);K_=i(C0,"AlbertModel"),C0.forEach(t),tu.forEach(t),em=d(o),Je=s(o,"DIV",{class:!0});var Yt=r(Je);v(gr.$$.fragment,Yt),G_=d(Yt),jc=s(Yt,"P",{});var I0=r(jc);X_=i(I0,"The bare ALBERT Model transformer outputting raw hidden-states without any specific head on top."),I0.forEach(t),Z_=d(Yt),_r=s(Yt,"P",{});var ou=r(_r);Y_=i(ou,"This model inherits from "),Xl=s(ou,"A",{href:!0});var L0=r(Xl);eb=i(L0,"PreTrainedModel"),L0.forEach(t),tb=i(ou,`. 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.)`),ou.forEach(t),ob=d(Yt),br=s(Yt,"P",{});var nu=r(br);nb=i(nu,"This model is also a PyTorch "),kr=s(nu,"A",{href:!0,rel:!0});var N0=r(kr);sb=i(N0,"torch.nn.Module"),N0.forEach(t),rb=i(nu,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),nu.forEach(t),ab=d(Yt),tt=s(Yt,"DIV",{class:!0});var eo=r(tt);v(vr.$$.fragment,eo),ib=d(eo),Io=s(eo,"P",{});var Ld=r(Io);lb=i(Ld,"The "),Zl=s(Ld,"A",{href:!0});var D0=r(Zl);db=i(D0,"AlbertModel"),D0.forEach(t),cb=i(Ld," forward method, overrides the "),Cc=s(Ld,"CODE",{});var O0=r(Cc);pb=i(O0,"__call__"),O0.forEach(t),hb=i(Ld," special method."),Ld.forEach(t),fb=d(eo),v(In.$$.fragment,eo),mb=d(eo),Ic=s(eo,"P",{});var S0=r(Ic);ub=i(S0,"Example:"),S0.forEach(t),gb=d(eo),v(Tr.$$.fragment,eo),eo.forEach(t),Yt.forEach(t),tm=d(o),Lo=s(o,"H2",{class:!0});var su=r(Lo);Ln=s(su,"A",{id:!0,class:!0,href:!0});var W0=r(Ln);Lc=s(W0,"SPAN",{});var U0=r(Lc);v(yr.$$.fragment,U0),U0.forEach(t),W0.forEach(t),_b=d(su),Nc=s(su,"SPAN",{});var B0=r(Nc);bb=i(B0,"AlbertForPreTraining"),B0.forEach(t),su.forEach(t),om=d(o),Ke=s(o,"DIV",{class:!0});var to=r(Ke);v(wr.$$.fragment,to),kb=d(to),No=s(to,"P",{});var Nd=r(No);vb=i(Nd,"Albert Model with two heads on top as done during the pretraining: a "),Dc=s(Nd,"CODE",{});var R0=r(Dc);Tb=i(R0,"masked language modeling"),R0.forEach(t),yb=i(Nd,` head and a
`),Oc=s(Nd,"CODE",{});var H0=r(Oc);wb=i(H0,"sentence order prediction (classification)"),H0.forEach(t),Ab=i(Nd," head."),Nd.forEach(t),$b=d(to),Ar=s(to,"P",{});var ru=r(Ar);Fb=i(ru,"This model inherits from "),Yl=s(ru,"A",{href:!0});var Q0=r(Yl);xb=i(Q0,"PreTrainedModel"),Q0.forEach(t),Eb=i(ru,`. 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.)`),ru.forEach(t),Mb=d(to),$r=s(to,"P",{});var au=r($r);zb=i(au,"This model is also a PyTorch "),Fr=s(au,"A",{href:!0,rel:!0});var V0=r(Fr);qb=i(V0,"torch.nn.Module"),V0.forEach(t),Pb=i(au,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),au.forEach(t),jb=d(to),ot=s(to,"DIV",{class:!0});var oo=r(ot);v(xr.$$.fragment,oo),Cb=d(oo),Do=s(oo,"P",{});var Dd=r(Do);Ib=i(Dd,"The "),ed=s(Dd,"A",{href:!0});var J0=r(ed);Lb=i(J0,"AlbertForPreTraining"),J0.forEach(t),Nb=i(Dd," forward method, overrides the "),Sc=s(Dd,"CODE",{});var K0=r(Sc);Db=i(K0,"__call__"),K0.forEach(t),Ob=i(Dd," special method."),Dd.forEach(t),Sb=d(oo),v(Nn.$$.fragment,oo),Wb=d(oo),Wc=s(oo,"P",{});var G0=r(Wc);Ub=i(G0,"Example:"),G0.forEach(t),Bb=d(oo),v(Er.$$.fragment,oo),oo.forEach(t),to.forEach(t),nm=d(o),Oo=s(o,"H2",{class:!0});var iu=r(Oo);Dn=s(iu,"A",{id:!0,class:!0,href:!0});var X0=r(Dn);Uc=s(X0,"SPAN",{});var Z0=r(Uc);v(Mr.$$.fragment,Z0),Z0.forEach(t),X0.forEach(t),Rb=d(iu),Bc=s(iu,"SPAN",{});var Y0=r(Bc);Hb=i(Y0,"AlbertForMaskedLM"),Y0.forEach(t),iu.forEach(t),sm=d(o),Ge=s(o,"DIV",{class:!0});var no=r(Ge);v(zr.$$.fragment,no),Qb=d(no),qr=s(no,"P",{});var lu=r(qr);Vb=i(lu,"Albert Model with a "),Rc=s(lu,"CODE",{});var ex=r(Rc);Jb=i(ex,"language modeling"),ex.forEach(t),Kb=i(lu," head on top."),lu.forEach(t),Gb=d(no),Pr=s(no,"P",{});var du=r(Pr);Xb=i(du,"This model inherits from "),td=s(du,"A",{href:!0});var tx=r(td);Zb=i(tx,"PreTrainedModel"),tx.forEach(t),Yb=i(du,`. 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.)`),du.forEach(t),ek=d(no),jr=s(no,"P",{});var cu=r(jr);tk=i(cu,"This model is also a PyTorch "),Cr=s(cu,"A",{href:!0,rel:!0});var ox=r(Cr);ok=i(ox,"torch.nn.Module"),ox.forEach(t),nk=i(cu,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),cu.forEach(t),sk=d(no),nt=s(no,"DIV",{class:!0});var so=r(nt);v(Ir.$$.fragment,so),rk=d(so),So=s(so,"P",{});var Od=r(So);ak=i(Od,"The "),od=s(Od,"A",{href:!0});var nx=r(od);ik=i(nx,"AlbertForMaskedLM"),nx.forEach(t),lk=i(Od," forward method, overrides the "),Hc=s(Od,"CODE",{});var sx=r(Hc);dk=i(sx,"__call__"),sx.forEach(t),ck=i(Od," special method."),Od.forEach(t),pk=d(so),v(On.$$.fragment,so),hk=d(so),Qc=s(so,"P",{});var rx=r(Qc);fk=i(rx,"Example:"),rx.forEach(t),mk=d(so),v(Lr.$$.fragment,so),so.forEach(t),no.forEach(t),rm=d(o),Wo=s(o,"H2",{class:!0});var pu=r(Wo);Sn=s(pu,"A",{id:!0,class:!0,href:!0});var ax=r(Sn);Vc=s(ax,"SPAN",{});var ix=r(Vc);v(Nr.$$.fragment,ix),ix.forEach(t),ax.forEach(t),uk=d(pu),Jc=s(pu,"SPAN",{});var lx=r(Jc);gk=i(lx,"AlbertForSequenceClassification"),lx.forEach(t),pu.forEach(t),am=d(o),Xe=s(o,"DIV",{class:!0});var ro=r(Xe);v(Dr.$$.fragment,ro),_k=d(ro),Kc=s(ro,"P",{});var dx=r(Kc);bk=i(dx,`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.`),dx.forEach(t),kk=d(ro),Or=s(ro,"P",{});var hu=r(Or);vk=i(hu,"This model inherits from "),nd=s(hu,"A",{href:!0});var cx=r(nd);Tk=i(cx,"PreTrainedModel"),cx.forEach(t),yk=i(hu,`. 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.)`),hu.forEach(t),wk=d(ro),Sr=s(ro,"P",{});var fu=r(Sr);Ak=i(fu,"This model is also a PyTorch "),Wr=s(fu,"A",{href:!0,rel:!0});var px=r(Wr);$k=i(px,"torch.nn.Module"),px.forEach(t),Fk=i(fu,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),fu.forEach(t),xk=d(ro),Oe=s(ro,"DIV",{class:!0});var yt=r(Oe);v(Ur.$$.fragment,yt),Ek=d(yt),Uo=s(yt,"P",{});var Sd=r(Uo);Mk=i(Sd,"The "),sd=s(Sd,"A",{href:!0});var hx=r(sd);zk=i(hx,"AlbertForSequenceClassification"),hx.forEach(t),qk=i(Sd," forward method, overrides the "),Gc=s(Sd,"CODE",{});var fx=r(Gc);Pk=i(fx,"__call__"),fx.forEach(t),jk=i(Sd," special method."),Sd.forEach(t),Ck=d(yt),v(Wn.$$.fragment,yt),Ik=d(yt),Xc=s(yt,"P",{});var mx=r(Xc);Lk=i(mx,"Example of single-label classification:"),mx.forEach(t),Nk=d(yt),v(Br.$$.fragment,yt),Dk=d(yt),Zc=s(yt,"P",{});var ux=r(Zc);Ok=i(ux,"Example of multi-label classification:"),ux.forEach(t),Sk=d(yt),v(Rr.$$.fragment,yt),yt.forEach(t),ro.forEach(t),im=d(o),Bo=s(o,"H2",{class:!0});var mu=r(Bo);Un=s(mu,"A",{id:!0,class:!0,href:!0});var gx=r(Un);Yc=s(gx,"SPAN",{});var _x=r(Yc);v(Hr.$$.fragment,_x),_x.forEach(t),gx.forEach(t),Wk=d(mu),ep=s(mu,"SPAN",{});var bx=r(ep);Uk=i(bx,"AlbertForMultipleChoice"),bx.forEach(t),mu.forEach(t),lm=d(o),Ze=s(o,"DIV",{class:!0});var ao=r(Ze);v(Qr.$$.fragment,ao),Bk=d(ao),tp=s(ao,"P",{});var kx=r(tp);Rk=i(kx,`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.`),kx.forEach(t),Hk=d(ao),Vr=s(ao,"P",{});var uu=r(Vr);Qk=i(uu,"This model inherits from "),rd=s(uu,"A",{href:!0});var vx=r(rd);Vk=i(vx,"PreTrainedModel"),vx.forEach(t),Jk=i(uu,`. 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.)`),uu.forEach(t),Kk=d(ao),Jr=s(ao,"P",{});var gu=r(Jr);Gk=i(gu,"This model is also a PyTorch "),Kr=s(gu,"A",{href:!0,rel:!0});var Tx=r(Kr);Xk=i(Tx,"torch.nn.Module"),Tx.forEach(t),Zk=i(gu,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),gu.forEach(t),Yk=d(ao),st=s(ao,"DIV",{class:!0});var io=r(st);v(Gr.$$.fragment,io),ev=d(io),Ro=s(io,"P",{});var Wd=r(Ro);tv=i(Wd,"The "),ad=s(Wd,"A",{href:!0});var yx=r(ad);ov=i(yx,"AlbertForMultipleChoice"),yx.forEach(t),nv=i(Wd," forward method, overrides the "),op=s(Wd,"CODE",{});var wx=r(op);sv=i(wx,"__call__"),wx.forEach(t),rv=i(Wd," special method."),Wd.forEach(t),av=d(io),v(Bn.$$.fragment,io),iv=d(io),np=s(io,"P",{});var Ax=r(np);lv=i(Ax,"Example:"),Ax.forEach(t),dv=d(io),v(Xr.$$.fragment,io),io.forEach(t),ao.forEach(t),dm=d(o),Ho=s(o,"H2",{class:!0});var _u=r(Ho);Rn=s(_u,"A",{id:!0,class:!0,href:!0});var $x=r(Rn);sp=s($x,"SPAN",{});var Fx=r(sp);v(Zr.$$.fragment,Fx),Fx.forEach(t),$x.forEach(t),cv=d(_u),rp=s(_u,"SPAN",{});var xx=r(rp);pv=i(xx,"AlbertForTokenClassification"),xx.forEach(t),_u.forEach(t),cm=d(o),Ye=s(o,"DIV",{class:!0});var lo=r(Ye);v(Yr.$$.fragment,lo),hv=d(lo),ap=s(lo,"P",{});var Ex=r(ap);fv=i(Ex,`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.`),Ex.forEach(t),mv=d(lo),ea=s(lo,"P",{});var bu=r(ea);uv=i(bu,"This model inherits from "),id=s(bu,"A",{href:!0});var Mx=r(id);gv=i(Mx,"PreTrainedModel"),Mx.forEach(t),_v=i(bu,`. 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.)`),bu.forEach(t),bv=d(lo),ta=s(lo,"P",{});var ku=r(ta);kv=i(ku,"This model is also a PyTorch "),oa=s(ku,"A",{href:!0,rel:!0});var zx=r(oa);vv=i(zx,"torch.nn.Module"),zx.forEach(t),Tv=i(ku,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),ku.forEach(t),yv=d(lo),rt=s(lo,"DIV",{class:!0});var co=r(rt);v(na.$$.fragment,co),wv=d(co),Qo=s(co,"P",{});var Ud=r(Qo);Av=i(Ud,"The "),ld=s(Ud,"A",{href:!0});var qx=r(ld);$v=i(qx,"AlbertForTokenClassification"),qx.forEach(t),Fv=i(Ud," forward method, overrides the "),ip=s(Ud,"CODE",{});var Px=r(ip);xv=i(Px,"__call__"),Px.forEach(t),Ev=i(Ud," special method."),Ud.forEach(t),Mv=d(co),v(Hn.$$.fragment,co),zv=d(co),lp=s(co,"P",{});var jx=r(lp);qv=i(jx,"Example:"),jx.forEach(t),Pv=d(co),v(sa.$$.fragment,co),co.forEach(t),lo.forEach(t),pm=d(o),Vo=s(o,"H2",{class:!0});var vu=r(Vo);Qn=s(vu,"A",{id:!0,class:!0,href:!0});var Cx=r(Qn);dp=s(Cx,"SPAN",{});var Ix=r(dp);v(ra.$$.fragment,Ix),Ix.forEach(t),Cx.forEach(t),jv=d(vu),cp=s(vu,"SPAN",{});var Lx=r(cp);Cv=i(Lx,"AlbertForQuestionAnswering"),Lx.forEach(t),vu.forEach(t),hm=d(o),et=s(o,"DIV",{class:!0});var po=r(et);v(aa.$$.fragment,po),Iv=d(po),Jo=s(po,"P",{});var Bd=r(Jo);Lv=i(Bd,`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 `),pp=s(Bd,"CODE",{});var Nx=r(pp);Nv=i(Nx,"span start logits"),Nx.forEach(t),Dv=i(Bd," and "),hp=s(Bd,"CODE",{});var Dx=r(hp);Ov=i(Dx,"span end logits"),Dx.forEach(t),Sv=i(Bd,")."),Bd.forEach(t),Wv=d(po),ia=s(po,"P",{});var Tu=r(ia);Uv=i(Tu,"This model inherits from "),dd=s(Tu,"A",{href:!0});var Ox=r(dd);Bv=i(Ox,"PreTrainedModel"),Ox.forEach(t),Rv=i(Tu,`. 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.)`),Tu.forEach(t),Hv=d(po),la=s(po,"P",{});var yu=r(la);Qv=i(yu,"This model is also a PyTorch "),da=s(yu,"A",{href:!0,rel:!0});var Sx=r(da);Vv=i(Sx,"torch.nn.Module"),Sx.forEach(t),Jv=i(yu,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),yu.forEach(t),Kv=d(po),at=s(po,"DIV",{class:!0});var ho=r(at);v(ca.$$.fragment,ho),Gv=d(ho),Ko=s(ho,"P",{});var Rd=r(Ko);Xv=i(Rd,"The "),cd=s(Rd,"A",{href:!0});var Wx=r(cd);Zv=i(Wx,"AlbertForQuestionAnswering"),Wx.forEach(t),Yv=i(Rd," forward method, overrides the "),fp=s(Rd,"CODE",{});var Ux=r(fp);eT=i(Ux,"__call__"),Ux.forEach(t),tT=i(Rd," special method."),Rd.forEach(t),oT=d(ho),v(Vn.$$.fragment,ho),nT=d(ho),mp=s(ho,"P",{});var Bx=r(mp);sT=i(Bx,"Example:"),Bx.forEach(t),rT=d(ho),v(pa.$$.fragment,ho),ho.forEach(t),po.forEach(t),fm=d(o),Go=s(o,"H2",{class:!0});var wu=r(Go);Jn=s(wu,"A",{id:!0,class:!0,href:!0});var Rx=r(Jn);up=s(Rx,"SPAN",{});var Hx=r(up);v(ha.$$.fragment,Hx),Hx.forEach(t),Rx.forEach(t),aT=d(wu),gp=s(wu,"SPAN",{});var Qx=r(gp);iT=i(Qx,"TFAlbertModel"),Qx.forEach(t),wu.forEach(t),mm=d(o),Se=s(o,"DIV",{class:!0});var jt=r(Se);v(fa.$$.fragment,jt),lT=d(jt),_p=s(jt,"P",{});var Vx=r(_p);dT=i(Vx,"The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),Vx.forEach(t),cT=d(jt),ma=s(jt,"P",{});var Au=r(ma);pT=i(Au,"This model inherits from "),pd=s(Au,"A",{href:!0});var Jx=r(pd);hT=i(Jx,"TFPreTrainedModel"),Jx.forEach(t),fT=i(Au,`. 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.)`),Au.forEach(t),mT=d(jt),ua=s(jt,"P",{});var $u=r(ua);uT=i($u,"This model is also a "),ga=s($u,"A",{href:!0,rel:!0});var Kx=r(ga);gT=i(Kx,"tf.keras.Model"),Kx.forEach(t),_T=i($u,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),$u.forEach(t),bT=d(jt),v(Kn.$$.fragment,jt),kT=d(jt),it=s(jt,"DIV",{class:!0});var fo=r(it);v(_a.$$.fragment,fo),vT=d(fo),Xo=s(fo,"P",{});var Hd=r(Xo);TT=i(Hd,"The "),hd=s(Hd,"A",{href:!0});var Gx=r(hd);yT=i(Gx,"TFAlbertModel"),Gx.forEach(t),wT=i(Hd," forward method, overrides the "),bp=s(Hd,"CODE",{});var Xx=r(bp);AT=i(Xx,"__call__"),Xx.forEach(t),$T=i(Hd," special method."),Hd.forEach(t),FT=d(fo),v(Gn.$$.fragment,fo),xT=d(fo),kp=s(fo,"P",{});var Zx=r(kp);ET=i(Zx,"Example:"),Zx.forEach(t),MT=d(fo),v(ba.$$.fragment,fo),fo.forEach(t),jt.forEach(t),um=d(o),Zo=s(o,"H2",{class:!0});var Fu=r(Zo);Xn=s(Fu,"A",{id:!0,class:!0,href:!0});var Yx=r(Xn);vp=s(Yx,"SPAN",{});var eE=r(vp);v(ka.$$.fragment,eE),eE.forEach(t),Yx.forEach(t),zT=d(Fu),Tp=s(Fu,"SPAN",{});var tE=r(Tp);qT=i(tE,"TFAlbertForPreTraining"),tE.forEach(t),Fu.forEach(t),gm=d(o),We=s(o,"DIV",{class:!0});var Ct=r(We);v(va.$$.fragment,Ct),PT=d(Ct),Yo=s(Ct,"P",{});var Qd=r(Yo);jT=i(Qd,"Albert Model with two heads on top for pretraining: a "),yp=s(Qd,"CODE",{});var oE=r(yp);CT=i(oE,"masked language modeling"),oE.forEach(t),IT=i(Qd," head and a "),wp=s(Qd,"CODE",{});var nE=r(wp);LT=i(nE,"sentence order prediction"),nE.forEach(t),NT=i(Qd," (classification) head."),Qd.forEach(t),DT=d(Ct),Ta=s(Ct,"P",{});var xu=r(Ta);OT=i(xu,"This model inherits from "),fd=s(xu,"A",{href:!0});var sE=r(fd);ST=i(sE,"TFPreTrainedModel"),sE.forEach(t),WT=i(xu,`. 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.)`),xu.forEach(t),UT=d(Ct),ya=s(Ct,"P",{});var Eu=r(ya);BT=i(Eu,"This model is also a "),wa=s(Eu,"A",{href:!0,rel:!0});var rE=r(wa);RT=i(rE,"tf.keras.Model"),rE.forEach(t),HT=i(Eu,` 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.`),Eu.forEach(t),QT=d(Ct),v(Zn.$$.fragment,Ct),VT=d(Ct),lt=s(Ct,"DIV",{class:!0});var mo=r(lt);v(Aa.$$.fragment,mo),JT=d(mo),en=s(mo,"P",{});var Vd=r(en);KT=i(Vd,"The "),md=s(Vd,"A",{href:!0});var aE=r(md);GT=i(aE,"TFAlbertForPreTraining"),aE.forEach(t),XT=i(Vd," forward method, overrides the "),Ap=s(Vd,"CODE",{});var iE=r(Ap);ZT=i(iE,"__call__"),iE.forEach(t),YT=i(Vd," special method."),Vd.forEach(t),e1=d(mo),v(Yn.$$.fragment,mo),t1=d(mo),$p=s(mo,"P",{});var lE=r($p);o1=i(lE,"Example:"),lE.forEach(t),n1=d(mo),v($a.$$.fragment,mo),mo.forEach(t),Ct.forEach(t),_m=d(o),tn=s(o,"H2",{class:!0});var Mu=r(tn);es=s(Mu,"A",{id:!0,class:!0,href:!0});var dE=r(es);Fp=s(dE,"SPAN",{});var cE=r(Fp);v(Fa.$$.fragment,cE),cE.forEach(t),dE.forEach(t),s1=d(Mu),xp=s(Mu,"SPAN",{});var pE=r(xp);r1=i(pE,"TFAlbertForMaskedLM"),pE.forEach(t),Mu.forEach(t),bm=d(o),Ue=s(o,"DIV",{class:!0});var It=r(Ue);v(xa.$$.fragment,It),a1=d(It),Ea=s(It,"P",{});var zu=r(Ea);i1=i(zu,"Albert Model with a "),Ep=s(zu,"CODE",{});var hE=r(Ep);l1=i(hE,"language modeling"),hE.forEach(t),d1=i(zu," head on top."),zu.forEach(t),c1=d(It),Ma=s(It,"P",{});var qu=r(Ma);p1=i(qu,"This model inherits from "),ud=s(qu,"A",{href:!0});var fE=r(ud);h1=i(fE,"TFPreTrainedModel"),fE.forEach(t),f1=i(qu,`. 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.)`),qu.forEach(t),m1=d(It),za=s(It,"P",{});var Pu=r(za);u1=i(Pu,"This model is also a "),qa=s(Pu,"A",{href:!0,rel:!0});var mE=r(qa);g1=i(mE,"tf.keras.Model"),mE.forEach(t),_1=i(Pu,` 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.`),Pu.forEach(t),b1=d(It),v(ts.$$.fragment,It),k1=d(It),dt=s(It,"DIV",{class:!0});var uo=r(dt);v(Pa.$$.fragment,uo),v1=d(uo),on=s(uo,"P",{});var Jd=r(on);T1=i(Jd,"The "),gd=s(Jd,"A",{href:!0});var uE=r(gd);y1=i(uE,"TFAlbertForMaskedLM"),uE.forEach(t),w1=i(Jd," forward method, overrides the "),Mp=s(Jd,"CODE",{});var gE=r(Mp);A1=i(gE,"__call__"),gE.forEach(t),$1=i(Jd," special method."),Jd.forEach(t),F1=d(uo),v(os.$$.fragment,uo),x1=d(uo),zp=s(uo,"P",{});var _E=r(zp);E1=i(_E,"Example:"),_E.forEach(t),M1=d(uo),v(ja.$$.fragment,uo),uo.forEach(t),It.forEach(t),km=d(o),nn=s(o,"H2",{class:!0});var ju=r(nn);ns=s(ju,"A",{id:!0,class:!0,href:!0});var bE=r(ns);qp=s(bE,"SPAN",{});var kE=r(qp);v(Ca.$$.fragment,kE),kE.forEach(t),bE.forEach(t),z1=d(ju),Pp=s(ju,"SPAN",{});var vE=r(Pp);q1=i(vE,"TFAlbertForSequenceClassification"),vE.forEach(t),ju.forEach(t),vm=d(o),Be=s(o,"DIV",{class:!0});var Lt=r(Be);v(Ia.$$.fragment,Lt),P1=d(Lt),jp=s(Lt,"P",{});var TE=r(jp);j1=i(TE,`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.`),TE.forEach(t),C1=d(Lt),La=s(Lt,"P",{});var Cu=r(La);I1=i(Cu,"This model inherits from "),_d=s(Cu,"A",{href:!0});var yE=r(_d);L1=i(yE,"TFPreTrainedModel"),yE.forEach(t),N1=i(Cu,`. 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.)`),Cu.forEach(t),D1=d(Lt),Na=s(Lt,"P",{});var Iu=r(Na);O1=i(Iu,"This model is also a "),Da=s(Iu,"A",{href:!0,rel:!0});var wE=r(Da);S1=i(wE,"tf.keras.Model"),wE.forEach(t),W1=i(Iu,` 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.`),Iu.forEach(t),U1=d(Lt),v(ss.$$.fragment,Lt),B1=d(Lt),ct=s(Lt,"DIV",{class:!0});var go=r(ct);v(Oa.$$.fragment,go),R1=d(go),sn=s(go,"P",{});var Kd=r(sn);H1=i(Kd,"The "),bd=s(Kd,"A",{href:!0});var AE=r(bd);Q1=i(AE,"TFAlbertForSequenceClassification"),AE.forEach(t),V1=i(Kd," forward method, overrides the "),Cp=s(Kd,"CODE",{});var $E=r(Cp);J1=i($E,"__call__"),$E.forEach(t),K1=i(Kd," special method."),Kd.forEach(t),G1=d(go),v(rs.$$.fragment,go),X1=d(go),Ip=s(go,"P",{});var FE=r(Ip);Z1=i(FE,"Example:"),FE.forEach(t),Y1=d(go),v(Sa.$$.fragment,go),go.forEach(t),Lt.forEach(t),Tm=d(o),rn=s(o,"H2",{class:!0});var Lu=r(rn);as=s(Lu,"A",{id:!0,class:!0,href:!0});var xE=r(as);Lp=s(xE,"SPAN",{});var EE=r(Lp);v(Wa.$$.fragment,EE),EE.forEach(t),xE.forEach(t),ey=d(Lu),Np=s(Lu,"SPAN",{});var ME=r(Np);ty=i(ME,"TFAlbertForMultipleChoice"),ME.forEach(t),Lu.forEach(t),ym=d(o),Re=s(o,"DIV",{class:!0});var Nt=r(Re);v(Ua.$$.fragment,Nt),oy=d(Nt),Dp=s(Nt,"P",{});var zE=r(Dp);ny=i(zE,`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.`),zE.forEach(t),sy=d(Nt),Ba=s(Nt,"P",{});var Nu=r(Ba);ry=i(Nu,"This model inherits from "),kd=s(Nu,"A",{href:!0});var qE=r(kd);ay=i(qE,"TFPreTrainedModel"),qE.forEach(t),iy=i(Nu,`. 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.)`),Nu.forEach(t),ly=d(Nt),Ra=s(Nt,"P",{});var Du=r(Ra);dy=i(Du,"This model is also a "),Ha=s(Du,"A",{href:!0,rel:!0});var PE=r(Ha);cy=i(PE,"tf.keras.Model"),PE.forEach(t),py=i(Du,` 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.`),Du.forEach(t),hy=d(Nt),v(is.$$.fragment,Nt),fy=d(Nt),pt=s(Nt,"DIV",{class:!0});var _o=r(pt);v(Qa.$$.fragment,_o),my=d(_o),an=s(_o,"P",{});var Gd=r(an);uy=i(Gd,"The "),vd=s(Gd,"A",{href:!0});var jE=r(vd);gy=i(jE,"TFAlbertForMultipleChoice"),jE.forEach(t),_y=i(Gd," forward method, overrides the "),Op=s(Gd,"CODE",{});var CE=r(Op);by=i(CE,"__call__"),CE.forEach(t),ky=i(Gd," special method."),Gd.forEach(t),vy=d(_o),v(ls.$$.fragment,_o),Ty=d(_o),Sp=s(_o,"P",{});var IE=r(Sp);yy=i(IE,"Example:"),IE.forEach(t),wy=d(_o),v(Va.$$.fragment,_o),_o.forEach(t),Nt.forEach(t),wm=d(o),ln=s(o,"H2",{class:!0});var Ou=r(ln);ds=s(Ou,"A",{id:!0,class:!0,href:!0});var LE=r(ds);Wp=s(LE,"SPAN",{});var NE=r(Wp);v(Ja.$$.fragment,NE),NE.forEach(t),LE.forEach(t),Ay=d(Ou),Up=s(Ou,"SPAN",{});var DE=r(Up);$y=i(DE,"TFAlbertForTokenClassification"),DE.forEach(t),Ou.forEach(t),Am=d(o),He=s(o,"DIV",{class:!0});var Dt=r(He);v(Ka.$$.fragment,Dt),Fy=d(Dt),Bp=s(Dt,"P",{});var OE=r(Bp);xy=i(OE,`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.`),OE.forEach(t),Ey=d(Dt),Ga=s(Dt,"P",{});var Su=r(Ga);My=i(Su,"This model inherits from "),Td=s(Su,"A",{href:!0});var SE=r(Td);zy=i(SE,"TFPreTrainedModel"),SE.forEach(t),qy=i(Su,`. 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.)`),Su.forEach(t),Py=d(Dt),Xa=s(Dt,"P",{});var Wu=r(Xa);jy=i(Wu,"This model is also a "),Za=s(Wu,"A",{href:!0,rel:!0});var WE=r(Za);Cy=i(WE,"tf.keras.Model"),WE.forEach(t),Iy=i(Wu,` 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.`),Wu.forEach(t),Ly=d(Dt),v(cs.$$.fragment,Dt),Ny=d(Dt),ht=s(Dt,"DIV",{class:!0});var bo=r(ht);v(Ya.$$.fragment,bo),Dy=d(bo),dn=s(bo,"P",{});var Xd=r(dn);Oy=i(Xd,"The "),yd=s(Xd,"A",{href:!0});var UE=r(yd);Sy=i(UE,"TFAlbertForTokenClassification"),UE.forEach(t),Wy=i(Xd," forward method, overrides the "),Rp=s(Xd,"CODE",{});var BE=r(Rp);Uy=i(BE,"__call__"),BE.forEach(t),By=i(Xd," special method."),Xd.forEach(t),Ry=d(bo),v(ps.$$.fragment,bo),Hy=d(bo),Hp=s(bo,"P",{});var RE=r(Hp);Qy=i(RE,"Example:"),RE.forEach(t),Vy=d(bo),v(ei.$$.fragment,bo),bo.forEach(t),Dt.forEach(t),$m=d(o),cn=s(o,"H2",{class:!0});var Uu=r(cn);hs=s(Uu,"A",{id:!0,class:!0,href:!0});var HE=r(hs);Qp=s(HE,"SPAN",{});var QE=r(Qp);v(ti.$$.fragment,QE),QE.forEach(t),HE.forEach(t),Jy=d(Uu),Vp=s(Uu,"SPAN",{});var VE=r(Vp);Ky=i(VE,"TFAlbertForQuestionAnswering"),VE.forEach(t),Uu.forEach(t),Fm=d(o),Qe=s(o,"DIV",{class:!0});var Ot=r(Qe);v(oi.$$.fragment,Ot),Gy=d(Ot),pn=s(Ot,"P",{});var Zd=r(pn);Xy=i(Zd,`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 `),Jp=s(Zd,"CODE",{});var JE=r(Jp);Zy=i(JE,"span start logits"),JE.forEach(t),Yy=i(Zd," and "),Kp=s(Zd,"CODE",{});var KE=r(Kp);ew=i(KE,"span end logits"),KE.forEach(t),tw=i(Zd,")."),Zd.forEach(t),ow=d(Ot),ni=s(Ot,"P",{});var Bu=r(ni);nw=i(Bu,"This model inherits from "),wd=s(Bu,"A",{href:!0});var GE=r(wd);sw=i(GE,"TFPreTrainedModel"),GE.forEach(t),rw=i(Bu,`. 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.)`),Bu.forEach(t),aw=d(Ot),si=s(Ot,"P",{});var Ru=r(si);iw=i(Ru,"This model is also a "),ri=s(Ru,"A",{href:!0,rel:!0});var XE=r(ri);lw=i(XE,"tf.keras.Model"),XE.forEach(t),dw=i(Ru,` 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.`),Ru.forEach(t),cw=d(Ot),v(fs.$$.fragment,Ot),pw=d(Ot),ft=s(Ot,"DIV",{class:!0});var ko=r(ft);v(ai.$$.fragment,ko),hw=d(ko),hn=s(ko,"P",{});var Yd=r(hn);fw=i(Yd,"The "),Ad=s(Yd,"A",{href:!0});var ZE=r(Ad);mw=i(ZE,"TFAlbertForQuestionAnswering"),ZE.forEach(t),uw=i(Yd," forward method, overrides the "),Gp=s(Yd,"CODE",{});var YE=r(Gp);gw=i(YE,"__call__"),YE.forEach(t),_w=i(Yd," special method."),Yd.forEach(t),bw=d(ko),v(ms.$$.fragment,ko),kw=d(ko),Xp=s(ko,"P",{});var eM=r(Xp);vw=i(eM,"Example:"),eM.forEach(t),Tw=d(ko),v(ii.$$.fragment,ko),ko.forEach(t),Ot.forEach(t),xm=d(o),fn=s(o,"H2",{class:!0});var Hu=r(fn);us=s(Hu,"A",{id:!0,class:!0,href:!0});var tM=r(us);Zp=s(tM,"SPAN",{});var oM=r(Zp);v(li.$$.fragment,oM),oM.forEach(t),tM.forEach(t),yw=d(Hu),Yp=s(Hu,"SPAN",{});var nM=r(Yp);ww=i(nM,"FlaxAlbertModel"),nM.forEach(t),Hu.forEach(t),Em=d(o),Pe=s(o,"DIV",{class:!0});var wt=r(Pe);v(di.$$.fragment,wt),Aw=d(wt),eh=s(wt,"P",{});var sM=r(eh);$w=i(sM,"The bare Albert Model transformer outputting raw hidden-states without any specific head on top."),sM.forEach(t),Fw=d(wt),ci=s(wt,"P",{});var Qu=r(ci);xw=i(Qu,"This model inherits from "),$d=s(Qu,"A",{href:!0});var rM=r($d);Ew=i(rM,"FlaxPreTrainedModel"),rM.forEach(t),Mw=i(Qu,`. 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)`),Qu.forEach(t),zw=d(wt),pi=s(wt,"P",{});var Vu=r(pi);qw=i(Vu,"This model is also a Flax Linen "),hi=s(Vu,"A",{href:!0,rel:!0});var aM=r(hi);Pw=i(aM,"flax.linen.Module"),aM.forEach(t),jw=i(Vu,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Vu.forEach(t),Cw=d(wt),th=s(wt,"P",{});var iM=r(th);Iw=i(iM,"Finally, this model supports inherent JAX features such as:"),iM.forEach(t),Lw=d(wt),Ut=s(wt,"UL",{});var Cs=r(Ut);oh=s(Cs,"LI",{});var lM=r(oh);fi=s(lM,"A",{href:!0,rel:!0});var dM=r(fi);Nw=i(dM,"Just-In-Time (JIT) compilation"),dM.forEach(t),lM.forEach(t),Dw=d(Cs),nh=s(Cs,"LI",{});var cM=r(nh);mi=s(cM,"A",{href:!0,rel:!0});var pM=r(mi);Ow=i(pM,"Automatic Differentiation"),pM.forEach(t),cM.forEach(t),Sw=d(Cs),sh=s(Cs,"LI",{});var hM=r(sh);ui=s(hM,"A",{href:!0,rel:!0});var fM=r(ui);Ww=i(fM,"Vectorization"),fM.forEach(t),hM.forEach(t),Uw=d(Cs),rh=s(Cs,"LI",{});var mM=r(rh);gi=s(mM,"A",{href:!0,rel:!0});var uM=r(gi);Bw=i(uM,"Parallelization"),uM.forEach(t),mM.forEach(t),Cs.forEach(t),Rw=d(wt),mt=s(wt,"DIV",{class:!0});var vo=r(mt);v(_i.$$.fragment,vo),Hw=d(vo),mn=s(vo,"P",{});var ec=r(mn);Qw=i(ec,"The "),ah=s(ec,"CODE",{});var gM=r(ah);Vw=i(gM,"FlaxAlbertPreTrainedModel"),gM.forEach(t),Jw=i(ec,"forward method, overrides the "),ih=s(ec,"CODE",{});var _M=r(ih);Kw=i(_M,"__call__"),_M.forEach(t),Gw=i(ec," special method."),ec.forEach(t),Xw=d(vo),v(gs.$$.fragment,vo),Zw=d(vo),lh=s(vo,"P",{});var bM=r(lh);Yw=i(bM,"Example:"),bM.forEach(t),eA=d(vo),v(bi.$$.fragment,vo),vo.forEach(t),wt.forEach(t),Mm=d(o),un=s(o,"H2",{class:!0});var Ju=r(un);_s=s(Ju,"A",{id:!0,class:!0,href:!0});var kM=r(_s);dh=s(kM,"SPAN",{});var vM=r(dh);v(ki.$$.fragment,vM),vM.forEach(t),kM.forEach(t),tA=d(Ju),ch=s(Ju,"SPAN",{});var TM=r(ch);oA=i(TM,"FlaxAlbertForPreTraining"),TM.forEach(t),Ju.forEach(t),zm=d(o),je=s(o,"DIV",{class:!0});var At=r(je);v(vi.$$.fragment,At),nA=d(At),gn=s(At,"P",{});var tc=r(gn);sA=i(tc,"Albert Model with two heads on top as done during the pretraining: a "),ph=s(tc,"CODE",{});var yM=r(ph);rA=i(yM,"masked language modeling"),yM.forEach(t),aA=i(tc,` head and a
`),hh=s(tc,"CODE",{});var wM=r(hh);iA=i(wM,"sentence order prediction (classification)"),wM.forEach(t),lA=i(tc," head."),tc.forEach(t),dA=d(At),Ti=s(At,"P",{});var Ku=r(Ti);cA=i(Ku,"This model inherits from "),Fd=s(Ku,"A",{href:!0});var AM=r(Fd);pA=i(AM,"FlaxPreTrainedModel"),AM.forEach(t),hA=i(Ku,`. 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)`),Ku.forEach(t),fA=d(At),yi=s(At,"P",{});var Gu=r(yi);mA=i(Gu,"This model is also a Flax Linen "),wi=s(Gu,"A",{href:!0,rel:!0});var $M=r(wi);uA=i($M,"flax.linen.Module"),$M.forEach(t),gA=i(Gu,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Gu.forEach(t),_A=d(At),fh=s(At,"P",{});var FM=r(fh);bA=i(FM,"Finally, this model supports inherent JAX features such as:"),FM.forEach(t),kA=d(At),Bt=s(At,"UL",{});var Is=r(Bt);mh=s(Is,"LI",{});var xM=r(mh);Ai=s(xM,"A",{href:!0,rel:!0});var EM=r(Ai);vA=i(EM,"Just-In-Time (JIT) compilation"),EM.forEach(t),xM.forEach(t),TA=d(Is),uh=s(Is,"LI",{});var MM=r(uh);$i=s(MM,"A",{href:!0,rel:!0});var zM=r($i);yA=i(zM,"Automatic Differentiation"),zM.forEach(t),MM.forEach(t),wA=d(Is),gh=s(Is,"LI",{});var qM=r(gh);Fi=s(qM,"A",{href:!0,rel:!0});var PM=r(Fi);AA=i(PM,"Vectorization"),PM.forEach(t),qM.forEach(t),$A=d(Is),_h=s(Is,"LI",{});var jM=r(_h);xi=s(jM,"A",{href:!0,rel:!0});var CM=r(xi);FA=i(CM,"Parallelization"),CM.forEach(t),jM.forEach(t),Is.forEach(t),xA=d(At),ut=s(At,"DIV",{class:!0});var To=r(ut);v(Ei.$$.fragment,To),EA=d(To),_n=s(To,"P",{});var oc=r(_n);MA=i(oc,"The "),bh=s(oc,"CODE",{});var IM=r(bh);zA=i(IM,"FlaxAlbertPreTrainedModel"),IM.forEach(t),qA=i(oc,"forward method, overrides the "),kh=s(oc,"CODE",{});var LM=r(kh);PA=i(LM,"__call__"),LM.forEach(t),jA=i(oc," special method."),oc.forEach(t),CA=d(To),v(bs.$$.fragment,To),IA=d(To),vh=s(To,"P",{});var NM=r(vh);LA=i(NM,"Example:"),NM.forEach(t),NA=d(To),v(Mi.$$.fragment,To),To.forEach(t),At.forEach(t),qm=d(o),bn=s(o,"H2",{class:!0});var Xu=r(bn);ks=s(Xu,"A",{id:!0,class:!0,href:!0});var DM=r(ks);Th=s(DM,"SPAN",{});var OM=r(Th);v(zi.$$.fragment,OM),OM.forEach(t),DM.forEach(t),DA=d(Xu),yh=s(Xu,"SPAN",{});var SM=r(yh);OA=i(SM,"FlaxAlbertForMaskedLM"),SM.forEach(t),Xu.forEach(t),Pm=d(o),Ce=s(o,"DIV",{class:!0});var $t=r(Ce);v(qi.$$.fragment,$t),SA=d($t),Pi=s($t,"P",{});var Zu=r(Pi);WA=i(Zu,"Albert Model with a "),wh=s(Zu,"CODE",{});var WM=r(wh);UA=i(WM,"language modeling"),WM.forEach(t),BA=i(Zu," head on top."),Zu.forEach(t),RA=d($t),ji=s($t,"P",{});var Yu=r(ji);HA=i(Yu,"This model inherits from "),xd=s(Yu,"A",{href:!0});var UM=r(xd);QA=i(UM,"FlaxPreTrainedModel"),UM.forEach(t),VA=i(Yu,`. 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)`),Yu.forEach(t),JA=d($t),Ci=s($t,"P",{});var eg=r(Ci);KA=i(eg,"This model is also a Flax Linen "),Ii=s(eg,"A",{href:!0,rel:!0});var BM=r(Ii);GA=i(BM,"flax.linen.Module"),BM.forEach(t),XA=i(eg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),eg.forEach(t),ZA=d($t),Ah=s($t,"P",{});var RM=r(Ah);YA=i(RM,"Finally, this model supports inherent JAX features such as:"),RM.forEach(t),e2=d($t),Rt=s($t,"UL",{});var Ls=r(Rt);$h=s(Ls,"LI",{});var HM=r($h);Li=s(HM,"A",{href:!0,rel:!0});var QM=r(Li);t2=i(QM,"Just-In-Time (JIT) compilation"),QM.forEach(t),HM.forEach(t),o2=d(Ls),Fh=s(Ls,"LI",{});var VM=r(Fh);Ni=s(VM,"A",{href:!0,rel:!0});var JM=r(Ni);n2=i(JM,"Automatic Differentiation"),JM.forEach(t),VM.forEach(t),s2=d(Ls),xh=s(Ls,"LI",{});var KM=r(xh);Di=s(KM,"A",{href:!0,rel:!0});var GM=r(Di);r2=i(GM,"Vectorization"),GM.forEach(t),KM.forEach(t),a2=d(Ls),Eh=s(Ls,"LI",{});var XM=r(Eh);Oi=s(XM,"A",{href:!0,rel:!0});var ZM=r(Oi);i2=i(ZM,"Parallelization"),ZM.forEach(t),XM.forEach(t),Ls.forEach(t),l2=d($t),gt=s($t,"DIV",{class:!0});var yo=r(gt);v(Si.$$.fragment,yo),d2=d(yo),kn=s(yo,"P",{});var nc=r(kn);c2=i(nc,"The "),Mh=s(nc,"CODE",{});var YM=r(Mh);p2=i(YM,"FlaxAlbertPreTrainedModel"),YM.forEach(t),h2=i(nc,"forward method, overrides the "),zh=s(nc,"CODE",{});var e3=r(zh);f2=i(e3,"__call__"),e3.forEach(t),m2=i(nc," special method."),nc.forEach(t),u2=d(yo),v(vs.$$.fragment,yo),g2=d(yo),qh=s(yo,"P",{});var t3=r(qh);_2=i(t3,"Example:"),t3.forEach(t),b2=d(yo),v(Wi.$$.fragment,yo),yo.forEach(t),$t.forEach(t),jm=d(o),vn=s(o,"H2",{class:!0});var tg=r(vn);Ts=s(tg,"A",{id:!0,class:!0,href:!0});var o3=r(Ts);Ph=s(o3,"SPAN",{});var n3=r(Ph);v(Ui.$$.fragment,n3),n3.forEach(t),o3.forEach(t),k2=d(tg),jh=s(tg,"SPAN",{});var s3=r(jh);v2=i(s3,"FlaxAlbertForSequenceClassification"),s3.forEach(t),tg.forEach(t),Cm=d(o),Ie=s(o,"DIV",{class:!0});var Ft=r(Ie);v(Bi.$$.fragment,Ft),T2=d(Ft),Ch=s(Ft,"P",{});var r3=r(Ch);y2=i(r3,`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.`),r3.forEach(t),w2=d(Ft),Ri=s(Ft,"P",{});var og=r(Ri);A2=i(og,"This model inherits from "),Ed=s(og,"A",{href:!0});var a3=r(Ed);$2=i(a3,"FlaxPreTrainedModel"),a3.forEach(t),F2=i(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),x2=d(Ft),Hi=s(Ft,"P",{});var ng=r(Hi);E2=i(ng,"This model is also a Flax Linen "),Qi=s(ng,"A",{href:!0,rel:!0});var i3=r(Qi);M2=i(i3,"flax.linen.Module"),i3.forEach(t),z2=i(ng,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),ng.forEach(t),q2=d(Ft),Ih=s(Ft,"P",{});var l3=r(Ih);P2=i(l3,"Finally, this model supports inherent JAX features such as:"),l3.forEach(t),j2=d(Ft),Ht=s(Ft,"UL",{});var Ns=r(Ht);Lh=s(Ns,"LI",{});var d3=r(Lh);Vi=s(d3,"A",{href:!0,rel:!0});var c3=r(Vi);C2=i(c3,"Just-In-Time (JIT) compilation"),c3.forEach(t),d3.forEach(t),I2=d(Ns),Nh=s(Ns,"LI",{});var p3=r(Nh);Ji=s(p3,"A",{href:!0,rel:!0});var h3=r(Ji);L2=i(h3,"Automatic Differentiation"),h3.forEach(t),p3.forEach(t),N2=d(Ns),Dh=s(Ns,"LI",{});var f3=r(Dh);Ki=s(f3,"A",{href:!0,rel:!0});var m3=r(Ki);D2=i(m3,"Vectorization"),m3.forEach(t),f3.forEach(t),O2=d(Ns),Oh=s(Ns,"LI",{});var u3=r(Oh);Gi=s(u3,"A",{href:!0,rel:!0});var g3=r(Gi);S2=i(g3,"Parallelization"),g3.forEach(t),u3.forEach(t),Ns.forEach(t),W2=d(Ft),_t=s(Ft,"DIV",{class:!0});var wo=r(_t);v(Xi.$$.fragment,wo),U2=d(wo),Tn=s(wo,"P",{});var sc=r(Tn);B2=i(sc,"The "),Sh=s(sc,"CODE",{});var _3=r(Sh);R2=i(_3,"FlaxAlbertPreTrainedModel"),_3.forEach(t),H2=i(sc,"forward method, overrides the "),Wh=s(sc,"CODE",{});var b3=r(Wh);Q2=i(b3,"__call__"),b3.forEach(t),V2=i(sc," special method."),sc.forEach(t),J2=d(wo),v(ys.$$.fragment,wo),K2=d(wo),Uh=s(wo,"P",{});var k3=r(Uh);G2=i(k3,"Example:"),k3.forEach(t),X2=d(wo),v(Zi.$$.fragment,wo),wo.forEach(t),Ft.forEach(t),Im=d(o),yn=s(o,"H2",{class:!0});var sg=r(yn);ws=s(sg,"A",{id:!0,class:!0,href:!0});var v3=r(ws);Bh=s(v3,"SPAN",{});var T3=r(Bh);v(Yi.$$.fragment,T3),T3.forEach(t),v3.forEach(t),Z2=d(sg),Rh=s(sg,"SPAN",{});var y3=r(Rh);Y2=i(y3,"FlaxAlbertForMultipleChoice"),y3.forEach(t),sg.forEach(t),Lm=d(o),Le=s(o,"DIV",{class:!0});var xt=r(Le);v(el.$$.fragment,xt),e$=d(xt),Hh=s(xt,"P",{});var w3=r(Hh);t$=i(w3,`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.`),w3.forEach(t),o$=d(xt),tl=s(xt,"P",{});var rg=r(tl);n$=i(rg,"This model inherits from "),Md=s(rg,"A",{href:!0});var A3=r(Md);s$=i(A3,"FlaxPreTrainedModel"),A3.forEach(t),r$=i(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),a$=d(xt),ol=s(xt,"P",{});var ag=r(ol);i$=i(ag,"This model is also a Flax Linen "),nl=s(ag,"A",{href:!0,rel:!0});var $3=r(nl);l$=i($3,"flax.linen.Module"),$3.forEach(t),d$=i(ag,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),ag.forEach(t),c$=d(xt),Qh=s(xt,"P",{});var F3=r(Qh);p$=i(F3,"Finally, this model supports inherent JAX features such as:"),F3.forEach(t),h$=d(xt),Qt=s(xt,"UL",{});var Ds=r(Qt);Vh=s(Ds,"LI",{});var x3=r(Vh);sl=s(x3,"A",{href:!0,rel:!0});var E3=r(sl);f$=i(E3,"Just-In-Time (JIT) compilation"),E3.forEach(t),x3.forEach(t),m$=d(Ds),Jh=s(Ds,"LI",{});var M3=r(Jh);rl=s(M3,"A",{href:!0,rel:!0});var z3=r(rl);u$=i(z3,"Automatic Differentiation"),z3.forEach(t),M3.forEach(t),g$=d(Ds),Kh=s(Ds,"LI",{});var q3=r(Kh);al=s(q3,"A",{href:!0,rel:!0});var P3=r(al);_$=i(P3,"Vectorization"),P3.forEach(t),q3.forEach(t),b$=d(Ds),Gh=s(Ds,"LI",{});var j3=r(Gh);il=s(j3,"A",{href:!0,rel:!0});var C3=r(il);k$=i(C3,"Parallelization"),C3.forEach(t),j3.forEach(t),Ds.forEach(t),v$=d(xt),bt=s(xt,"DIV",{class:!0});var Ao=r(bt);v(ll.$$.fragment,Ao),T$=d(Ao),wn=s(Ao,"P",{});var rc=r(wn);y$=i(rc,"The "),Xh=s(rc,"CODE",{});var I3=r(Xh);w$=i(I3,"FlaxAlbertPreTrainedModel"),I3.forEach(t),A$=i(rc,"forward method, overrides the "),Zh=s(rc,"CODE",{});var L3=r(Zh);$$=i(L3,"__call__"),L3.forEach(t),F$=i(rc," special method."),rc.forEach(t),x$=d(Ao),v(As.$$.fragment,Ao),E$=d(Ao),Yh=s(Ao,"P",{});var N3=r(Yh);M$=i(N3,"Example:"),N3.forEach(t),z$=d(Ao),v(dl.$$.fragment,Ao),Ao.forEach(t),xt.forEach(t),Nm=d(o),An=s(o,"H2",{class:!0});var ig=r(An);$s=s(ig,"A",{id:!0,class:!0,href:!0});var D3=r($s);ef=s(D3,"SPAN",{});var O3=r(ef);v(cl.$$.fragment,O3),O3.forEach(t),D3.forEach(t),q$=d(ig),tf=s(ig,"SPAN",{});var S3=r(tf);P$=i(S3,"FlaxAlbertForTokenClassification"),S3.forEach(t),ig.forEach(t),Dm=d(o),Ne=s(o,"DIV",{class:!0});var Et=r(Ne);v(pl.$$.fragment,Et),j$=d(Et),of=s(Et,"P",{});var W3=r(of);C$=i(W3,`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.`),W3.forEach(t),I$=d(Et),hl=s(Et,"P",{});var lg=r(hl);L$=i(lg,"This model inherits from "),zd=s(lg,"A",{href:!0});var U3=r(zd);N$=i(U3,"FlaxPreTrainedModel"),U3.forEach(t),D$=i(lg,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),lg.forEach(t),O$=d(Et),fl=s(Et,"P",{});var dg=r(fl);S$=i(dg,"This model is also a Flax Linen "),ml=s(dg,"A",{href:!0,rel:!0});var B3=r(ml);W$=i(B3,"flax.linen.Module"),B3.forEach(t),U$=i(dg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),dg.forEach(t),B$=d(Et),nf=s(Et,"P",{});var R3=r(nf);R$=i(R3,"Finally, this model supports inherent JAX features such as:"),R3.forEach(t),H$=d(Et),Vt=s(Et,"UL",{});var Os=r(Vt);sf=s(Os,"LI",{});var H3=r(sf);ul=s(H3,"A",{href:!0,rel:!0});var Q3=r(ul);Q$=i(Q3,"Just-In-Time (JIT) compilation"),Q3.forEach(t),H3.forEach(t),V$=d(Os),rf=s(Os,"LI",{});var V3=r(rf);gl=s(V3,"A",{href:!0,rel:!0});var J3=r(gl);J$=i(J3,"Automatic Differentiation"),J3.forEach(t),V3.forEach(t),K$=d(Os),af=s(Os,"LI",{});var K3=r(af);_l=s(K3,"A",{href:!0,rel:!0});var G3=r(_l);G$=i(G3,"Vectorization"),G3.forEach(t),K3.forEach(t),X$=d(Os),lf=s(Os,"LI",{});var X3=r(lf);bl=s(X3,"A",{href:!0,rel:!0});var Z3=r(bl);Z$=i(Z3,"Parallelization"),Z3.forEach(t),X3.forEach(t),Os.forEach(t),Y$=d(Et),kt=s(Et,"DIV",{class:!0});var $o=r(kt);v(kl.$$.fragment,$o),eF=d($o),$n=s($o,"P",{});var ac=r($n);tF=i(ac,"The "),df=s(ac,"CODE",{});var Y3=r(df);oF=i(Y3,"FlaxAlbertPreTrainedModel"),Y3.forEach(t),nF=i(ac,"forward method, overrides the "),cf=s(ac,"CODE",{});var ez=r(cf);sF=i(ez,"__call__"),ez.forEach(t),rF=i(ac," special method."),ac.forEach(t),aF=d($o),v(Fs.$$.fragment,$o),iF=d($o),pf=s($o,"P",{});var tz=r(pf);lF=i(tz,"Example:"),tz.forEach(t),dF=d($o),v(vl.$$.fragment,$o),$o.forEach(t),Et.forEach(t),Om=d(o),Fn=s(o,"H2",{class:!0});var cg=r(Fn);xs=s(cg,"A",{id:!0,class:!0,href:!0});var oz=r(xs);hf=s(oz,"SPAN",{});var nz=r(hf);v(Tl.$$.fragment,nz),nz.forEach(t),oz.forEach(t),cF=d(cg),ff=s(cg,"SPAN",{});var sz=r(ff);pF=i(sz,"FlaxAlbertForQuestionAnswering"),sz.forEach(t),cg.forEach(t),Sm=d(o),De=s(o,"DIV",{class:!0});var Mt=r(De);v(yl.$$.fragment,Mt),hF=d(Mt),xn=s(Mt,"P",{});var ic=r(xn);fF=i(ic,`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 `),mf=s(ic,"CODE",{});var rz=r(mf);mF=i(rz,"span start logits"),rz.forEach(t),uF=i(ic," and "),uf=s(ic,"CODE",{});var az=r(uf);gF=i(az,"span end logits"),az.forEach(t),_F=i(ic,")."),ic.forEach(t),bF=d(Mt),wl=s(Mt,"P",{});var pg=r(wl);kF=i(pg,"This model inherits from "),qd=s(pg,"A",{href:!0});var iz=r(qd);vF=i(iz,"FlaxPreTrainedModel"),iz.forEach(t),TF=i(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),yF=d(Mt),Al=s(Mt,"P",{});var hg=r(Al);wF=i(hg,"This model is also a Flax Linen "),$l=s(hg,"A",{href:!0,rel:!0});var lz=r($l);AF=i(lz,"flax.linen.Module"),lz.forEach(t),$F=i(hg,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),hg.forEach(t),FF=d(Mt),gf=s(Mt,"P",{});var dz=r(gf);xF=i(dz,"Finally, this model supports inherent JAX features such as:"),dz.forEach(t),EF=d(Mt),Jt=s(Mt,"UL",{});var Ss=r(Jt);_f=s(Ss,"LI",{});var cz=r(_f);Fl=s(cz,"A",{href:!0,rel:!0});var pz=r(Fl);MF=i(pz,"Just-In-Time (JIT) compilation"),pz.forEach(t),cz.forEach(t),zF=d(Ss),bf=s(Ss,"LI",{});var hz=r(bf);xl=s(hz,"A",{href:!0,rel:!0});var fz=r(xl);qF=i(fz,"Automatic Differentiation"),fz.forEach(t),hz.forEach(t),PF=d(Ss),kf=s(Ss,"LI",{});var mz=r(kf);El=s(mz,"A",{href:!0,rel:!0});var uz=r(El);jF=i(uz,"Vectorization"),uz.forEach(t),mz.forEach(t),CF=d(Ss),vf=s(Ss,"LI",{});var gz=r(vf);Ml=s(gz,"A",{href:!0,rel:!0});var _z=r(Ml);IF=i(_z,"Parallelization"),_z.forEach(t),gz.forEach(t),Ss.forEach(t),LF=d(Mt),vt=s(Mt,"DIV",{class:!0});var Fo=r(vt);v(zl.$$.fragment,Fo),NF=d(Fo),En=s(Fo,"P",{});var lc=r(En);DF=i(lc,"The "),Tf=s(lc,"CODE",{});var bz=r(Tf);OF=i(bz,"FlaxAlbertPreTrainedModel"),bz.forEach(t),SF=i(lc,"forward method, overrides the "),yf=s(lc,"CODE",{});var kz=r(yf);WF=i(kz,"__call__"),kz.forEach(t),UF=i(lc," special method."),lc.forEach(t),BF=d(Fo),v(Es.$$.fragment,Fo),RF=d(Fo),wf=s(Fo,"P",{});var vz=r(wf);HF=i(vz,"Example:"),vz.forEach(t),QF=d(Fo),v(ql.$$.fragment,Fo),Fo.forEach(t),Mt.forEach(t),this.h()},h(){c(p,"name","hf:doc:metadata"),c(p,"content",JSON.stringify(e5)),c(b,"id","albert"),c(b,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(b,"href","#albert"),c(g,"class","relative group"),c(Z,"id","overview"),c(Z,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Z,"href","#overview"),c(M,"class","relative group"),c(te,"href","https://arxiv.org/abs/1909.11942"),c(te,"rel","nofollow"),c(ke,"href","https://huggingface.co/lysandre"),c(ke,"rel","nofollow"),c(S,"href","https://huggingface.co/kamalkraj"),c(S,"rel","nofollow"),c(W,"href","https://github.com/google-research/ALBERT"),c(W,"rel","nofollow"),c(Mn,"id","transformers.AlbertConfig"),c(Mn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Mn,"href","#transformers.AlbertConfig"),c(be,"class","relative group"),c(Dl,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertModel"),c(Ol,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertModel"),c(Bs,"href","https://huggingface.co/albert-xxlarge-v2"),c(Bs,"rel","nofollow"),c(Sl,"href","/docs/transformers/pr_15839/en/main_classes/configuration#transformers.PretrainedConfig"),c(Wl,"href","/docs/transformers/pr_15839/en/main_classes/configuration#transformers.PretrainedConfig"),c(Ve,"class","docstring"),c(zn,"id","transformers.AlbertTokenizer"),c(zn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(zn,"href","#transformers.AlbertTokenizer"),c(Eo,"class","relative group"),c(Js,"href","https://github.com/google/sentencepiece"),c(Js,"rel","nofollow"),c(Ul,"href","/docs/transformers/pr_15839/en/main_classes/tokenizer#transformers.PreTrainedTokenizer"),c(Gt,"class","docstring"),c(qn,"class","docstring"),c(qt,"class","docstring"),c(Hl,"class","docstring"),c(qe,"class","docstring"),c(Pn,"id","transformers.AlbertTokenizerFast"),c(Pn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Pn,"href","#transformers.AlbertTokenizerFast"),c(zo,"class","relative group"),c(rr,"href","https://huggingface.co/docs/tokenizers/python/latest/components.html?highlight=unigram#models"),c(rr,"rel","nofollow"),c(Ql,"href","/docs/transformers/pr_15839/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast"),c(Xt,"class","docstring"),c(Pt,"class","docstring"),c(zt,"class","docstring"),c(jn,"id","transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput"),c(jn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(jn,"href","#transformers.models.albert.modeling_albert.AlbertForPreTrainingOutput"),c(qo,"class","relative group"),c(Kl,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertForPreTraining"),c(Po,"class","docstring"),c(Gl,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertForPreTraining"),c(jo,"class","docstring"),c(Cn,"id","transformers.AlbertModel"),c(Cn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Cn,"href","#transformers.AlbertModel"),c(Co,"class","relative group"),c(Xl,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.PreTrainedModel"),c(kr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(kr,"rel","nofollow"),c(Zl,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertModel"),c(tt,"class","docstring"),c(Je,"class","docstring"),c(Ln,"id","transformers.AlbertForPreTraining"),c(Ln,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Ln,"href","#transformers.AlbertForPreTraining"),c(Lo,"class","relative group"),c(Yl,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.PreTrainedModel"),c(Fr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Fr,"rel","nofollow"),c(ed,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertForPreTraining"),c(ot,"class","docstring"),c(Ke,"class","docstring"),c(Dn,"id","transformers.AlbertForMaskedLM"),c(Dn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Dn,"href","#transformers.AlbertForMaskedLM"),c(Oo,"class","relative group"),c(td,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.PreTrainedModel"),c(Cr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Cr,"rel","nofollow"),c(od,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertForMaskedLM"),c(nt,"class","docstring"),c(Ge,"class","docstring"),c(Sn,"id","transformers.AlbertForSequenceClassification"),c(Sn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Sn,"href","#transformers.AlbertForSequenceClassification"),c(Wo,"class","relative group"),c(nd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.PreTrainedModel"),c(Wr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Wr,"rel","nofollow"),c(sd,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertForSequenceClassification"),c(Oe,"class","docstring"),c(Xe,"class","docstring"),c(Un,"id","transformers.AlbertForMultipleChoice"),c(Un,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Un,"href","#transformers.AlbertForMultipleChoice"),c(Bo,"class","relative group"),c(rd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.PreTrainedModel"),c(Kr,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Kr,"rel","nofollow"),c(ad,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertForMultipleChoice"),c(st,"class","docstring"),c(Ze,"class","docstring"),c(Rn,"id","transformers.AlbertForTokenClassification"),c(Rn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Rn,"href","#transformers.AlbertForTokenClassification"),c(Ho,"class","relative group"),c(id,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.PreTrainedModel"),c(oa,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(oa,"rel","nofollow"),c(ld,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertForTokenClassification"),c(rt,"class","docstring"),c(Ye,"class","docstring"),c(Qn,"id","transformers.AlbertForQuestionAnswering"),c(Qn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Qn,"href","#transformers.AlbertForQuestionAnswering"),c(Vo,"class","relative group"),c(dd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.PreTrainedModel"),c(da,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(da,"rel","nofollow"),c(cd,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.AlbertForQuestionAnswering"),c(at,"class","docstring"),c(et,"class","docstring"),c(Jn,"id","transformers.TFAlbertModel"),c(Jn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Jn,"href","#transformers.TFAlbertModel"),c(Go,"class","relative group"),c(pd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.TFPreTrainedModel"),c(ga,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(ga,"rel","nofollow"),c(hd,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertModel"),c(it,"class","docstring"),c(Se,"class","docstring"),c(Xn,"id","transformers.TFAlbertForPreTraining"),c(Xn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Xn,"href","#transformers.TFAlbertForPreTraining"),c(Zo,"class","relative group"),c(fd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.TFPreTrainedModel"),c(wa,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(wa,"rel","nofollow"),c(md,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertForPreTraining"),c(lt,"class","docstring"),c(We,"class","docstring"),c(es,"id","transformers.TFAlbertForMaskedLM"),c(es,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(es,"href","#transformers.TFAlbertForMaskedLM"),c(tn,"class","relative group"),c(ud,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.TFPreTrainedModel"),c(qa,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(qa,"rel","nofollow"),c(gd,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertForMaskedLM"),c(dt,"class","docstring"),c(Ue,"class","docstring"),c(ns,"id","transformers.TFAlbertForSequenceClassification"),c(ns,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ns,"href","#transformers.TFAlbertForSequenceClassification"),c(nn,"class","relative group"),c(_d,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.TFPreTrainedModel"),c(Da,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Da,"rel","nofollow"),c(bd,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertForSequenceClassification"),c(ct,"class","docstring"),c(Be,"class","docstring"),c(as,"id","transformers.TFAlbertForMultipleChoice"),c(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"),c(as,"href","#transformers.TFAlbertForMultipleChoice"),c(rn,"class","relative group"),c(kd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.TFPreTrainedModel"),c(Ha,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Ha,"rel","nofollow"),c(vd,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertForMultipleChoice"),c(pt,"class","docstring"),c(Re,"class","docstring"),c(ds,"id","transformers.TFAlbertForTokenClassification"),c(ds,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ds,"href","#transformers.TFAlbertForTokenClassification"),c(ln,"class","relative group"),c(Td,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.TFPreTrainedModel"),c(Za,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Za,"rel","nofollow"),c(yd,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertForTokenClassification"),c(ht,"class","docstring"),c(He,"class","docstring"),c(hs,"id","transformers.TFAlbertForQuestionAnswering"),c(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"),c(hs,"href","#transformers.TFAlbertForQuestionAnswering"),c(cn,"class","relative group"),c(wd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.TFPreTrainedModel"),c(ri,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(ri,"rel","nofollow"),c(Ad,"href","/docs/transformers/pr_15839/en/model_doc/albert#transformers.TFAlbertForQuestionAnswering"),c(ft,"class","docstring"),c(Qe,"class","docstring"),c(us,"id","transformers.FlaxAlbertModel"),c(us,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(us,"href","#transformers.FlaxAlbertModel"),c(fn,"class","relative group"),c($d,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(hi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(hi,"rel","nofollow"),c(fi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(fi,"rel","nofollow"),c(mi,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(mi,"rel","nofollow"),c(ui,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(ui,"rel","nofollow"),c(gi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(gi,"rel","nofollow"),c(mt,"class","docstring"),c(Pe,"class","docstring"),c(_s,"id","transformers.FlaxAlbertForPreTraining"),c(_s,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(_s,"href","#transformers.FlaxAlbertForPreTraining"),c(un,"class","relative group"),c(Fd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(wi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(wi,"rel","nofollow"),c(Ai,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Ai,"rel","nofollow"),c($i,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c($i,"rel","nofollow"),c(Fi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Fi,"rel","nofollow"),c(xi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(xi,"rel","nofollow"),c(ut,"class","docstring"),c(je,"class","docstring"),c(ks,"id","transformers.FlaxAlbertForMaskedLM"),c(ks,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ks,"href","#transformers.FlaxAlbertForMaskedLM"),c(bn,"class","relative group"),c(xd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Ii,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Ii,"rel","nofollow"),c(Li,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Li,"rel","nofollow"),c(Ni,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Ni,"rel","nofollow"),c(Di,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Di,"rel","nofollow"),c(Oi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Oi,"rel","nofollow"),c(gt,"class","docstring"),c(Ce,"class","docstring"),c(Ts,"id","transformers.FlaxAlbertForSequenceClassification"),c(Ts,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Ts,"href","#transformers.FlaxAlbertForSequenceClassification"),c(vn,"class","relative group"),c(Ed,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Qi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Qi,"rel","nofollow"),c(Vi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Vi,"rel","nofollow"),c(Ji,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Ji,"rel","nofollow"),c(Ki,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Ki,"rel","nofollow"),c(Gi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Gi,"rel","nofollow"),c(_t,"class","docstring"),c(Ie,"class","docstring"),c(ws,"id","transformers.FlaxAlbertForMultipleChoice"),c(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"),c(ws,"href","#transformers.FlaxAlbertForMultipleChoice"),c(yn,"class","relative group"),c(Md,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(nl,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(nl,"rel","nofollow"),c(sl,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(sl,"rel","nofollow"),c(rl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(rl,"rel","nofollow"),c(al,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(al,"rel","nofollow"),c(il,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(il,"rel","nofollow"),c(bt,"class","docstring"),c(Le,"class","docstring"),c($s,"id","transformers.FlaxAlbertForTokenClassification"),c($s,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c($s,"href","#transformers.FlaxAlbertForTokenClassification"),c(An,"class","relative group"),c(zd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(ml,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(ml,"rel","nofollow"),c(ul,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(ul,"rel","nofollow"),c(gl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(gl,"rel","nofollow"),c(_l,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(_l,"rel","nofollow"),c(bl,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(bl,"rel","nofollow"),c(kt,"class","docstring"),c(Ne,"class","docstring"),c(xs,"id","transformers.FlaxAlbertForQuestionAnswering"),c(xs,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(xs,"href","#transformers.FlaxAlbertForQuestionAnswering"),c(Fn,"class","relative group"),c(qd,"href","/docs/transformers/pr_15839/en/main_classes/model#transformers.FlaxPreTrainedModel"),c($l,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c($l,"rel","nofollow"),c(Fl,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Fl,"rel","nofollow"),c(xl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(xl,"rel","nofollow"),c(El,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(El,"rel","nofollow"),c(Ml,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Ml,"rel","nofollow"),c(vt,"class","docstring"),c(De,"class","docstring")},m(o,m){e(document.head,p),f(o,F,m),f(o,g,m),e(g,b),e(b,$),T(_,$,null),e(g,u),e(g,x),e(x,pe),f(o,G,m),f(o,M,m),e(M,Z),e(Z,U),T(ee,U,null),e(M,he),e(M,B),e(B,fe),f(o,ae,m),f(o,J,m),e(J,L),e(J,te),e(te,X),e(J,z),f(o,P,m),f(o,Y,m),e(Y,R),e(R,me),e(Y,ue),e(Y,H),e(H,ge),f(o,ie,m),f(o,q,m),e(q,_e),f(o,Q,m),f(o,oe,m),e(oe,se),e(se,V),f(o,le,m),f(o,ne,m),e(ne,N),f(o,de,m),f(o,O,m),e(O,re),e(re,h),e(O,E),e(O,K),e(K,Ae),f(o,ye,m),f(o,j,m),e(j,$e),e(j,ke),e(ke,Fe),e(j,D),e(j,S),e(S,xe),e(j,Ee),e(j,W),e(W,Me),e(j,ze),f(o,ce,m),f(o,be,m),e(be,Mn),e(Mn,dc),T(Ws,dc,null),e(be,fg),e(be,cc),e(cc,mg),f(o,Hf,m),f(o,Ve,m),T(Us,Ve,null),e(Ve,ug),e(Ve,St),e(St,gg),e(St,Dl),e(Dl,_g),e(St,bg),e(St,Ol),e(Ol,kg),e(St,vg),e(St,Bs),e(Bs,Tg),e(St,yg),e(Ve,wg),e(Ve,xo),e(xo,Ag),e(xo,Sl),e(Sl,$g),e(xo,Fg),e(xo,Wl),e(Wl,xg),e(xo,Eg),e(Ve,Mg),e(Ve,pc),e(pc,zg),e(Ve,qg),T(Rs,Ve,null),f(o,Qf,m),f(o,Eo,m),e(Eo,zn),e(zn,hc),T(Hs,hc,null),e(Eo,Pg),e(Eo,fc),e(fc,jg),f(o,Vf,m),f(o,qe,m),T(Qs,qe,null),e(qe,Cg),e(qe,Vs),e(Vs,Ig),e(Vs,Js),e(Js,Lg),e(Vs,Ng),e(qe,Dg),e(qe,Ks),e(Ks,Og),e(Ks,Ul),e(Ul,Sg),e(Ks,Wg),e(qe,Ug),e(qe,Gt),T(Gs,Gt,null),e(Gt,Bg),e(Gt,mc),e(mc,Rg),e(Gt,Hg),e(Gt,Xs),e(Xs,Bl),e(Bl,Qg),e(Bl,uc),e(uc,Vg),e(Xs,Jg),e(Xs,Rl),e(Rl,Kg),e(Rl,gc),e(gc,Gg),e(qe,Xg),e(qe,qn),T(Zs,qn,null),e(qn,Zg),e(qn,Ys),e(Ys,Yg),e(Ys,_c),e(_c,e_),e(Ys,t_),e(qe,o_),e(qe,qt),T(er,qt,null),e(qt,n_),e(qt,bc),e(bc,s_),e(qt,r_),T(tr,qt,null),e(qt,a_),e(qt,Mo),e(Mo,i_),e(Mo,kc),e(kc,l_),e(Mo,d_),e(Mo,vc),e(vc,c_),e(Mo,p_),e(qe,h_),e(qe,Hl),T(or,Hl,null),f(o,Jf,m),f(o,zo,m),e(zo,Pn),e(Pn,Tc),T(nr,Tc,null),e(zo,f_),e(zo,yc),e(yc,m_),f(o,Kf,m),f(o,zt,m),T(sr,zt,null),e(zt,u_),e(zt,Wt),e(Wt,g_),e(Wt,wc),e(wc,__),e(Wt,b_),e(Wt,rr),e(rr,k_),e(Wt,v_),e(Wt,Ql),e(Ql,T_),e(Wt,y_),e(zt,w_),e(zt,Xt),T(ar,Xt,null),e(Xt,A_),e(Xt,Ac),e(Ac,$_),e(Xt,F_),e(Xt,ir),e(ir,Vl),e(Vl,x_),e(Vl,$c),e($c,E_),e(ir,M_),e(ir,Jl),e(Jl,z_),e(Jl,Fc),e(Fc,q_),e(zt,P_),e(zt,Pt),T(lr,Pt,null),e(Pt,j_),e(Pt,xc),e(xc,C_),e(Pt,I_),T(dr,Pt,null),e(Pt,L_),e(Pt,Ec),e(Ec,N_),f(o,Gf,m),f(o,qo,m),e(qo,jn),e(jn,Mc),T(cr,Mc,null),e(qo,D_),e(qo,zc),e(zc,O_),f(o,Xf,m),f(o,Po,m),T(pr,Po,null),e(Po,S_),e(Po,hr),e(hr,W_),e(hr,Kl),e(Kl,U_),e(hr,B_),f(o,Zf,m),f(o,jo,m),T(fr,jo,null),e(jo,R_),e(jo,mr),e(mr,H_),e(mr,Gl),e(Gl,Q_),e(mr,V_),f(o,Yf,m),f(o,Co,m),e(Co,Cn),e(Cn,qc),T(ur,qc,null),e(Co,J_),e(Co,Pc),e(Pc,K_),f(o,em,m),f(o,Je,m),T(gr,Je,null),e(Je,G_),e(Je,jc),e(jc,X_),e(Je,Z_),e(Je,_r),e(_r,Y_),e(_r,Xl),e(Xl,eb),e(_r,tb),e(Je,ob),e(Je,br),e(br,nb),e(br,kr),e(kr,sb),e(br,rb),e(Je,ab),e(Je,tt),T(vr,tt,null),e(tt,ib),e(tt,Io),e(Io,lb),e(Io,Zl),e(Zl,db),e(Io,cb),e(Io,Cc),e(Cc,pb),e(Io,hb),e(tt,fb),T(In,tt,null),e(tt,mb),e(tt,Ic),e(Ic,ub),e(tt,gb),T(Tr,tt,null),f(o,tm,m),f(o,Lo,m),e(Lo,Ln),e(Ln,Lc),T(yr,Lc,null),e(Lo,_b),e(Lo,Nc),e(Nc,bb),f(o,om,m),f(o,Ke,m),T(wr,Ke,null),e(Ke,kb),e(Ke,No),e(No,vb),e(No,Dc),e(Dc,Tb),e(No,yb),e(No,Oc),e(Oc,wb),e(No,Ab),e(Ke,$b),e(Ke,Ar),e(Ar,Fb),e(Ar,Yl),e(Yl,xb),e(Ar,Eb),e(Ke,Mb),e(Ke,$r),e($r,zb),e($r,Fr),e(Fr,qb),e($r,Pb),e(Ke,jb),e(Ke,ot),T(xr,ot,null),e(ot,Cb),e(ot,Do),e(Do,Ib),e(Do,ed),e(ed,Lb),e(Do,Nb),e(Do,Sc),e(Sc,Db),e(Do,Ob),e(ot,Sb),T(Nn,ot,null),e(ot,Wb),e(ot,Wc),e(Wc,Ub),e(ot,Bb),T(Er,ot,null),f(o,nm,m),f(o,Oo,m),e(Oo,Dn),e(Dn,Uc),T(Mr,Uc,null),e(Oo,Rb),e(Oo,Bc),e(Bc,Hb),f(o,sm,m),f(o,Ge,m),T(zr,Ge,null),e(Ge,Qb),e(Ge,qr),e(qr,Vb),e(qr,Rc),e(Rc,Jb),e(qr,Kb),e(Ge,Gb),e(Ge,Pr),e(Pr,Xb),e(Pr,td),e(td,Zb),e(Pr,Yb),e(Ge,ek),e(Ge,jr),e(jr,tk),e(jr,Cr),e(Cr,ok),e(jr,nk),e(Ge,sk),e(Ge,nt),T(Ir,nt,null),e(nt,rk),e(nt,So),e(So,ak),e(So,od),e(od,ik),e(So,lk),e(So,Hc),e(Hc,dk),e(So,ck),e(nt,pk),T(On,nt,null),e(nt,hk),e(nt,Qc),e(Qc,fk),e(nt,mk),T(Lr,nt,null),f(o,rm,m),f(o,Wo,m),e(Wo,Sn),e(Sn,Vc),T(Nr,Vc,null),e(Wo,uk),e(Wo,Jc),e(Jc,gk),f(o,am,m),f(o,Xe,m),T(Dr,Xe,null),e(Xe,_k),e(Xe,Kc),e(Kc,bk),e(Xe,kk),e(Xe,Or),e(Or,vk),e(Or,nd),e(nd,Tk),e(Or,yk),e(Xe,wk),e(Xe,Sr),e(Sr,Ak),e(Sr,Wr),e(Wr,$k),e(Sr,Fk),e(Xe,xk),e(Xe,Oe),T(Ur,Oe,null),e(Oe,Ek),e(Oe,Uo),e(Uo,Mk),e(Uo,sd),e(sd,zk),e(Uo,qk),e(Uo,Gc),e(Gc,Pk),e(Uo,jk),e(Oe,Ck),T(Wn,Oe,null),e(Oe,Ik),e(Oe,Xc),e(Xc,Lk),e(Oe,Nk),T(Br,Oe,null),e(Oe,Dk),e(Oe,Zc),e(Zc,Ok),e(Oe,Sk),T(Rr,Oe,null),f(o,im,m),f(o,Bo,m),e(Bo,Un),e(Un,Yc),T(Hr,Yc,null),e(Bo,Wk),e(Bo,ep),e(ep,Uk),f(o,lm,m),f(o,Ze,m),T(Qr,Ze,null),e(Ze,Bk),e(Ze,tp),e(tp,Rk),e(Ze,Hk),e(Ze,Vr),e(Vr,Qk),e(Vr,rd),e(rd,Vk),e(Vr,Jk),e(Ze,Kk),e(Ze,Jr),e(Jr,Gk),e(Jr,Kr),e(Kr,Xk),e(Jr,Zk),e(Ze,Yk),e(Ze,st),T(Gr,st,null),e(st,ev),e(st,Ro),e(Ro,tv),e(Ro,ad),e(ad,ov),e(Ro,nv),e(Ro,op),e(op,sv),e(Ro,rv),e(st,av),T(Bn,st,null),e(st,iv),e(st,np),e(np,lv),e(st,dv),T(Xr,st,null),f(o,dm,m),f(o,Ho,m),e(Ho,Rn),e(Rn,sp),T(Zr,sp,null),e(Ho,cv),e(Ho,rp),e(rp,pv),f(o,cm,m),f(o,Ye,m),T(Yr,Ye,null),e(Ye,hv),e(Ye,ap),e(ap,fv),e(Ye,mv),e(Ye,ea),e(ea,uv),e(ea,id),e(id,gv),e(ea,_v),e(Ye,bv),e(Ye,ta),e(ta,kv),e(ta,oa),e(oa,vv),e(ta,Tv),e(Ye,yv),e(Ye,rt),T(na,rt,null),e(rt,wv),e(rt,Qo),e(Qo,Av),e(Qo,ld),e(ld,$v),e(Qo,Fv),e(Qo,ip),e(ip,xv),e(Qo,Ev),e(rt,Mv),T(Hn,rt,null),e(rt,zv),e(rt,lp),e(lp,qv),e(rt,Pv),T(sa,rt,null),f(o,pm,m),f(o,Vo,m),e(Vo,Qn),e(Qn,dp),T(ra,dp,null),e(Vo,jv),e(Vo,cp),e(cp,Cv),f(o,hm,m),f(o,et,m),T(aa,et,null),e(et,Iv),e(et,Jo),e(Jo,Lv),e(Jo,pp),e(pp,Nv),e(Jo,Dv),e(Jo,hp),e(hp,Ov),e(Jo,Sv),e(et,Wv),e(et,ia),e(ia,Uv),e(ia,dd),e(dd,Bv),e(ia,Rv),e(et,Hv),e(et,la),e(la,Qv),e(la,da),e(da,Vv),e(la,Jv),e(et,Kv),e(et,at),T(ca,at,null),e(at,Gv),e(at,Ko),e(Ko,Xv),e(Ko,cd),e(cd,Zv),e(Ko,Yv),e(Ko,fp),e(fp,eT),e(Ko,tT),e(at,oT),T(Vn,at,null),e(at,nT),e(at,mp),e(mp,sT),e(at,rT),T(pa,at,null),f(o,fm,m),f(o,Go,m),e(Go,Jn),e(Jn,up),T(ha,up,null),e(Go,aT),e(Go,gp),e(gp,iT),f(o,mm,m),f(o,Se,m),T(fa,Se,null),e(Se,lT),e(Se,_p),e(_p,dT),e(Se,cT),e(Se,ma),e(ma,pT),e(ma,pd),e(pd,hT),e(ma,fT),e(Se,mT),e(Se,ua),e(ua,uT),e(ua,ga),e(ga,gT),e(ua,_T),e(Se,bT),T(Kn,Se,null),e(Se,kT),e(Se,it),T(_a,it,null),e(it,vT),e(it,Xo),e(Xo,TT),e(Xo,hd),e(hd,yT),e(Xo,wT),e(Xo,bp),e(bp,AT),e(Xo,$T),e(it,FT),T(Gn,it,null),e(it,xT),e(it,kp),e(kp,ET),e(it,MT),T(ba,it,null),f(o,um,m),f(o,Zo,m),e(Zo,Xn),e(Xn,vp),T(ka,vp,null),e(Zo,zT),e(Zo,Tp),e(Tp,qT),f(o,gm,m),f(o,We,m),T(va,We,null),e(We,PT),e(We,Yo),e(Yo,jT),e(Yo,yp),e(yp,CT),e(Yo,IT),e(Yo,wp),e(wp,LT),e(Yo,NT),e(We,DT),e(We,Ta),e(Ta,OT),e(Ta,fd),e(fd,ST),e(Ta,WT),e(We,UT),e(We,ya),e(ya,BT),e(ya,wa),e(wa,RT),e(ya,HT),e(We,QT),T(Zn,We,null),e(We,VT),e(We,lt),T(Aa,lt,null),e(lt,JT),e(lt,en),e(en,KT),e(en,md),e(md,GT),e(en,XT),e(en,Ap),e(Ap,ZT),e(en,YT),e(lt,e1),T(Yn,lt,null),e(lt,t1),e(lt,$p),e($p,o1),e(lt,n1),T($a,lt,null),f(o,_m,m),f(o,tn,m),e(tn,es),e(es,Fp),T(Fa,Fp,null),e(tn,s1),e(tn,xp),e(xp,r1),f(o,bm,m),f(o,Ue,m),T(xa,Ue,null),e(Ue,a1),e(Ue,Ea),e(Ea,i1),e(Ea,Ep),e(Ep,l1),e(Ea,d1),e(Ue,c1),e(Ue,Ma),e(Ma,p1),e(Ma,ud),e(ud,h1),e(Ma,f1),e(Ue,m1),e(Ue,za),e(za,u1),e(za,qa),e(qa,g1),e(za,_1),e(Ue,b1),T(ts,Ue,null),e(Ue,k1),e(Ue,dt),T(Pa,dt,null),e(dt,v1),e(dt,on),e(on,T1),e(on,gd),e(gd,y1),e(on,w1),e(on,Mp),e(Mp,A1),e(on,$1),e(dt,F1),T(os,dt,null),e(dt,x1),e(dt,zp),e(zp,E1),e(dt,M1),T(ja,dt,null),f(o,km,m),f(o,nn,m),e(nn,ns),e(ns,qp),T(Ca,qp,null),e(nn,z1),e(nn,Pp),e(Pp,q1),f(o,vm,m),f(o,Be,m),T(Ia,Be,null),e(Be,P1),e(Be,jp),e(jp,j1),e(Be,C1),e(Be,La),e(La,I1),e(La,_d),e(_d,L1),e(La,N1),e(Be,D1),e(Be,Na),e(Na,O1),e(Na,Da),e(Da,S1),e(Na,W1),e(Be,U1),T(ss,Be,null),e(Be,B1),e(Be,ct),T(Oa,ct,null),e(ct,R1),e(ct,sn),e(sn,H1),e(sn,bd),e(bd,Q1),e(sn,V1),e(sn,Cp),e(Cp,J1),e(sn,K1),e(ct,G1),T(rs,ct,null),e(ct,X1),e(ct,Ip),e(Ip,Z1),e(ct,Y1),T(Sa,ct,null),f(o,Tm,m),f(o,rn,m),e(rn,as),e(as,Lp),T(Wa,Lp,null),e(rn,ey),e(rn,Np),e(Np,ty),f(o,ym,m),f(o,Re,m),T(Ua,Re,null),e(Re,oy),e(Re,Dp),e(Dp,ny),e(Re,sy),e(Re,Ba),e(Ba,ry),e(Ba,kd),e(kd,ay),e(Ba,iy),e(Re,ly),e(Re,Ra),e(Ra,dy),e(Ra,Ha),e(Ha,cy),e(Ra,py),e(Re,hy),T(is,Re,null),e(Re,fy),e(Re,pt),T(Qa,pt,null),e(pt,my),e(pt,an),e(an,uy),e(an,vd),e(vd,gy),e(an,_y),e(an,Op),e(Op,by),e(an,ky),e(pt,vy),T(ls,pt,null),e(pt,Ty),e(pt,Sp),e(Sp,yy),e(pt,wy),T(Va,pt,null),f(o,wm,m),f(o,ln,m),e(ln,ds),e(ds,Wp),T(Ja,Wp,null),e(ln,Ay),e(ln,Up),e(Up,$y),f(o,Am,m),f(o,He,m),T(Ka,He,null),e(He,Fy),e(He,Bp),e(Bp,xy),e(He,Ey),e(He,Ga),e(Ga,My),e(Ga,Td),e(Td,zy),e(Ga,qy),e(He,Py),e(He,Xa),e(Xa,jy),e(Xa,Za),e(Za,Cy),e(Xa,Iy),e(He,Ly),T(cs,He,null),e(He,Ny),e(He,ht),T(Ya,ht,null),e(ht,Dy),e(ht,dn),e(dn,Oy),e(dn,yd),e(yd,Sy),e(dn,Wy),e(dn,Rp),e(Rp,Uy),e(dn,By),e(ht,Ry),T(ps,ht,null),e(ht,Hy),e(ht,Hp),e(Hp,Qy),e(ht,Vy),T(ei,ht,null),f(o,$m,m),f(o,cn,m),e(cn,hs),e(hs,Qp),T(ti,Qp,null),e(cn,Jy),e(cn,Vp),e(Vp,Ky),f(o,Fm,m),f(o,Qe,m),T(oi,Qe,null),e(Qe,Gy),e(Qe,pn),e(pn,Xy),e(pn,Jp),e(Jp,Zy),e(pn,Yy),e(pn,Kp),e(Kp,ew),e(pn,tw),e(Qe,ow),e(Qe,ni),e(ni,nw),e(ni,wd),e(wd,sw),e(ni,rw),e(Qe,aw),e(Qe,si),e(si,iw),e(si,ri),e(ri,lw),e(si,dw),e(Qe,cw),T(fs,Qe,null),e(Qe,pw),e(Qe,ft),T(ai,ft,null),e(ft,hw),e(ft,hn),e(hn,fw),e(hn,Ad),e(Ad,mw),e(hn,uw),e(hn,Gp),e(Gp,gw),e(hn,_w),e(ft,bw),T(ms,ft,null),e(ft,kw),e(ft,Xp),e(Xp,vw),e(ft,Tw),T(ii,ft,null),f(o,xm,m),f(o,fn,m),e(fn,us),e(us,Zp),T(li,Zp,null),e(fn,yw),e(fn,Yp),e(Yp,ww),f(o,Em,m),f(o,Pe,m),T(di,Pe,null),e(Pe,Aw),e(Pe,eh),e(eh,$w),e(Pe,Fw),e(Pe,ci),e(ci,xw),e(ci,$d),e($d,Ew),e(ci,Mw),e(Pe,zw),e(Pe,pi),e(pi,qw),e(pi,hi),e(hi,Pw),e(pi,jw),e(Pe,Cw),e(Pe,th),e(th,Iw),e(Pe,Lw),e(Pe,Ut),e(Ut,oh),e(oh,fi),e(fi,Nw),e(Ut,Dw),e(Ut,nh),e(nh,mi),e(mi,Ow),e(Ut,Sw),e(Ut,sh),e(sh,ui),e(ui,Ww),e(Ut,Uw),e(Ut,rh),e(rh,gi),e(gi,Bw),e(Pe,Rw),e(Pe,mt),T(_i,mt,null),e(mt,Hw),e(mt,mn),e(mn,Qw),e(mn,ah),e(ah,Vw),e(mn,Jw),e(mn,ih),e(ih,Kw),e(mn,Gw),e(mt,Xw),T(gs,mt,null),e(mt,Zw),e(mt,lh),e(lh,Yw),e(mt,eA),T(bi,mt,null),f(o,Mm,m),f(o,un,m),e(un,_s),e(_s,dh),T(ki,dh,null),e(un,tA),e(un,ch),e(ch,oA),f(o,zm,m),f(o,je,m),T(vi,je,null),e(je,nA),e(je,gn),e(gn,sA),e(gn,ph),e(ph,rA),e(gn,aA),e(gn,hh),e(hh,iA),e(gn,lA),e(je,dA),e(je,Ti),e(Ti,cA),e(Ti,Fd),e(Fd,pA),e(Ti,hA),e(je,fA),e(je,yi),e(yi,mA),e(yi,wi),e(wi,uA),e(yi,gA),e(je,_A),e(je,fh),e(fh,bA),e(je,kA),e(je,Bt),e(Bt,mh),e(mh,Ai),e(Ai,vA),e(Bt,TA),e(Bt,uh),e(uh,$i),e($i,yA),e(Bt,wA),e(Bt,gh),e(gh,Fi),e(Fi,AA),e(Bt,$A),e(Bt,_h),e(_h,xi),e(xi,FA),e(je,xA),e(je,ut),T(Ei,ut,null),e(ut,EA),e(ut,_n),e(_n,MA),e(_n,bh),e(bh,zA),e(_n,qA),e(_n,kh),e(kh,PA),e(_n,jA),e(ut,CA),T(bs,ut,null),e(ut,IA),e(ut,vh),e(vh,LA),e(ut,NA),T(Mi,ut,null),f(o,qm,m),f(o,bn,m),e(bn,ks),e(ks,Th),T(zi,Th,null),e(bn,DA),e(bn,yh),e(yh,OA),f(o,Pm,m),f(o,Ce,m),T(qi,Ce,null),e(Ce,SA),e(Ce,Pi),e(Pi,WA),e(Pi,wh),e(wh,UA),e(Pi,BA),e(Ce,RA),e(Ce,ji),e(ji,HA),e(ji,xd),e(xd,QA),e(ji,VA),e(Ce,JA),e(Ce,Ci),e(Ci,KA),e(Ci,Ii),e(Ii,GA),e(Ci,XA),e(Ce,ZA),e(Ce,Ah),e(Ah,YA),e(Ce,e2),e(Ce,Rt),e(Rt,$h),e($h,Li),e(Li,t2),e(Rt,o2),e(Rt,Fh),e(Fh,Ni),e(Ni,n2),e(Rt,s2),e(Rt,xh),e(xh,Di),e(Di,r2),e(Rt,a2),e(Rt,Eh),e(Eh,Oi),e(Oi,i2),e(Ce,l2),e(Ce,gt),T(Si,gt,null),e(gt,d2),e(gt,kn),e(kn,c2),e(kn,Mh),e(Mh,p2),e(kn,h2),e(kn,zh),e(zh,f2),e(kn,m2),e(gt,u2),T(vs,gt,null),e(gt,g2),e(gt,qh),e(qh,_2),e(gt,b2),T(Wi,gt,null),f(o,jm,m),f(o,vn,m),e(vn,Ts),e(Ts,Ph),T(Ui,Ph,null),e(vn,k2),e(vn,jh),e(jh,v2),f(o,Cm,m),f(o,Ie,m),T(Bi,Ie,null),e(Ie,T2),e(Ie,Ch),e(Ch,y2),e(Ie,w2),e(Ie,Ri),e(Ri,A2),e(Ri,Ed),e(Ed,$2),e(Ri,F2),e(Ie,x2),e(Ie,Hi),e(Hi,E2),e(Hi,Qi),e(Qi,M2),e(Hi,z2),e(Ie,q2),e(Ie,Ih),e(Ih,P2),e(Ie,j2),e(Ie,Ht),e(Ht,Lh),e(Lh,Vi),e(Vi,C2),e(Ht,I2),e(Ht,Nh),e(Nh,Ji),e(Ji,L2),e(Ht,N2),e(Ht,Dh),e(Dh,Ki),e(Ki,D2),e(Ht,O2),e(Ht,Oh),e(Oh,Gi),e(Gi,S2),e(Ie,W2),e(Ie,_t),T(Xi,_t,null),e(_t,U2),e(_t,Tn),e(Tn,B2),e(Tn,Sh),e(Sh,R2),e(Tn,H2),e(Tn,Wh),e(Wh,Q2),e(Tn,V2),e(_t,J2),T(ys,_t,null),e(_t,K2),e(_t,Uh),e(Uh,G2),e(_t,X2),T(Zi,_t,null),f(o,Im,m),f(o,yn,m),e(yn,ws),e(ws,Bh),T(Yi,Bh,null),e(yn,Z2),e(yn,Rh),e(Rh,Y2),f(o,Lm,m),f(o,Le,m),T(el,Le,null),e(Le,e$),e(Le,Hh),e(Hh,t$),e(Le,o$),e(Le,tl),e(tl,n$),e(tl,Md),e(Md,s$),e(tl,r$),e(Le,a$),e(Le,ol),e(ol,i$),e(ol,nl),e(nl,l$),e(ol,d$),e(Le,c$),e(Le,Qh),e(Qh,p$),e(Le,h$),e(Le,Qt),e(Qt,Vh),e(Vh,sl),e(sl,f$),e(Qt,m$),e(Qt,Jh),e(Jh,rl),e(rl,u$),e(Qt,g$),e(Qt,Kh),e(Kh,al),e(al,_$),e(Qt,b$),e(Qt,Gh),e(Gh,il),e(il,k$),e(Le,v$),e(Le,bt),T(ll,bt,null),e(bt,T$),e(bt,wn),e(wn,y$),e(wn,Xh),e(Xh,w$),e(wn,A$),e(wn,Zh),e(Zh,$$),e(wn,F$),e(bt,x$),T(As,bt,null),e(bt,E$),e(bt,Yh),e(Yh,M$),e(bt,z$),T(dl,bt,null),f(o,Nm,m),f(o,An,m),e(An,$s),e($s,ef),T(cl,ef,null),e(An,q$),e(An,tf),e(tf,P$),f(o,Dm,m),f(o,Ne,m),T(pl,Ne,null),e(Ne,j$),e(Ne,of),e(of,C$),e(Ne,I$),e(Ne,hl),e(hl,L$),e(hl,zd),e(zd,N$),e(hl,D$),e(Ne,O$),e(Ne,fl),e(fl,S$),e(fl,ml),e(ml,W$),e(fl,U$),e(Ne,B$),e(Ne,nf),e(nf,R$),e(Ne,H$),e(Ne,Vt),e(Vt,sf),e(sf,ul),e(ul,Q$),e(Vt,V$),e(Vt,rf),e(rf,gl),e(gl,J$),e(Vt,K$),e(Vt,af),e(af,_l),e(_l,G$),e(Vt,X$),e(Vt,lf),e(lf,bl),e(bl,Z$),e(Ne,Y$),e(Ne,kt),T(kl,kt,null),e(kt,eF),e(kt,$n),e($n,tF),e($n,df),e(df,oF),e($n,nF),e($n,cf),e(cf,sF),e($n,rF),e(kt,aF),T(Fs,kt,null),e(kt,iF),e(kt,pf),e(pf,lF),e(kt,dF),T(vl,kt,null),f(o,Om,m),f(o,Fn,m),e(Fn,xs),e(xs,hf),T(Tl,hf,null),e(Fn,cF),e(Fn,ff),e(ff,pF),f(o,Sm,m),f(o,De,m),T(yl,De,null),e(De,hF),e(De,xn),e(xn,fF),e(xn,mf),e(mf,mF),e(xn,uF),e(xn,uf),e(uf,gF),e(xn,_F),e(De,bF),e(De,wl),e(wl,kF),e(wl,qd),e(qd,vF),e(wl,TF),e(De,yF),e(De,Al),e(Al,wF),e(Al,$l),e($l,AF),e(Al,$F),e(De,FF),e(De,gf),e(gf,xF),e(De,EF),e(De,Jt),e(Jt,_f),e(_f,Fl),e(Fl,MF),e(Jt,zF),e(Jt,bf),e(bf,xl),e(xl,qF),e(Jt,PF),e(Jt,kf),e(kf,El),e(El,jF),e(Jt,CF),e(Jt,vf),e(vf,Ml),e(Ml,IF),e(De,LF),e(De,vt),T(zl,vt,null),e(vt,NF),e(vt,En),e(En,DF),e(En,Tf),e(Tf,OF),e(En,SF),e(En,yf),e(yf,WF),e(En,UF),e(vt,BF),T(Es,vt,null),e(vt,RF),e(vt,wf),e(wf,HF),e(vt,QF),T(ql,vt,null),Wm=!0},p(o,[m]){const Pl={};m&2&&(Pl.$$scope={dirty:m,ctx:o}),In.$set(Pl);const Af={};m&2&&(Af.$$scope={dirty:m,ctx:o}),Nn.$set(Af);const $f={};m&2&&($f.$$scope={dirty:m,ctx:o}),On.$set($f);const Ff={};m&2&&(Ff.$$scope={dirty:m,ctx:o}),Wn.$set(Ff);const jl={};m&2&&(jl.$$scope={dirty:m,ctx:o}),Bn.$set(jl);const xf={};m&2&&(xf.$$scope={dirty:m,ctx:o}),Hn.$set(xf);const Ef={};m&2&&(Ef.$$scope={dirty:m,ctx:o}),Vn.$set(Ef);const Mf={};m&2&&(Mf.$$scope={dirty:m,ctx:o}),Kn.$set(Mf);const Cl={};m&2&&(Cl.$$scope={dirty:m,ctx:o}),Gn.$set(Cl);const zf={};m&2&&(zf.$$scope={dirty:m,ctx:o}),Zn.$set(zf);const Il={};m&2&&(Il.$$scope={dirty:m,ctx:o}),Yn.$set(Il);const qf={};m&2&&(qf.$$scope={dirty:m,ctx:o}),ts.$set(qf);const Pf={};m&2&&(Pf.$$scope={dirty:m,ctx:o}),os.$set(Pf);const jf={};m&2&&(jf.$$scope={dirty:m,ctx:o}),ss.$set(jf);const Cf={};m&2&&(Cf.$$scope={dirty:m,ctx:o}),rs.$set(Cf);const If={};m&2&&(If.$$scope={dirty:m,ctx:o}),is.$set(If);const Lf={};m&2&&(Lf.$$scope={dirty:m,ctx:o}),ls.$set(Lf);const Ll={};m&2&&(Ll.$$scope={dirty:m,ctx:o}),cs.$set(Ll);const Nf={};m&2&&(Nf.$$scope={dirty:m,ctx:o}),ps.$set(Nf);const Df={};m&2&&(Df.$$scope={dirty:m,ctx:o}),fs.$set(Df);const Kt={};m&2&&(Kt.$$scope={dirty:m,ctx:o}),ms.$set(Kt);const Of={};m&2&&(Of.$$scope={dirty:m,ctx:o}),gs.$set(Of);const Sf={};m&2&&(Sf.$$scope={dirty:m,ctx:o}),bs.$set(Sf);const Wf={};m&2&&(Wf.$$scope={dirty:m,ctx:o}),vs.$set(Wf);const Nl={};m&2&&(Nl.$$scope={dirty:m,ctx:o}),ys.$set(Nl);const Uf={};m&2&&(Uf.$$scope={dirty:m,ctx:o}),As.$set(Uf);const Bf={};m&2&&(Bf.$$scope={dirty:m,ctx:o}),Fs.$set(Bf);const Rf={};m&2&&(Rf.$$scope={dirty:m,ctx:o}),Es.$set(Rf)},i(o){Wm||(y(_.$$.fragment,o),y(ee.$$.fragment,o),y(Ws.$$.fragment,o),y(Us.$$.fragment,o),y(Rs.$$.fragment,o),y(Hs.$$.fragment,o),y(Qs.$$.fragment,o),y(Gs.$$.fragment,o),y(Zs.$$.fragment,o),y(er.$$.fragment,o),y(tr.$$.fragment,o),y(or.$$.fragment,o),y(nr.$$.fragment,o),y(sr.$$.fragment,o),y(ar.$$.fragment,o),y(lr.$$.fragment,o),y(dr.$$.fragment,o),y(cr.$$.fragment,o),y(pr.$$.fragment,o),y(fr.$$.fragment,o),y(ur.$$.fragment,o),y(gr.$$.fragment,o),y(vr.$$.fragment,o),y(In.$$.fragment,o),y(Tr.$$.fragment,o),y(yr.$$.fragment,o),y(wr.$$.fragment,o),y(xr.$$.fragment,o),y(Nn.$$.fragment,o),y(Er.$$.fragment,o),y(Mr.$$.fragment,o),y(zr.$$.fragment,o),y(Ir.$$.fragment,o),y(On.$$.fragment,o),y(Lr.$$.fragment,o),y(Nr.$$.fragment,o),y(Dr.$$.fragment,o),y(Ur.$$.fragment,o),y(Wn.$$.fragment,o),y(Br.$$.fragment,o),y(Rr.$$.fragment,o),y(Hr.$$.fragment,o),y(Qr.$$.fragment,o),y(Gr.$$.fragment,o),y(Bn.$$.fragment,o),y(Xr.$$.fragment,o),y(Zr.$$.fragment,o),y(Yr.$$.fragment,o),y(na.$$.fragment,o),y(Hn.$$.fragment,o),y(sa.$$.fragment,o),y(ra.$$.fragment,o),y(aa.$$.fragment,o),y(ca.$$.fragment,o),y(Vn.$$.fragment,o),y(pa.$$.fragment,o),y(ha.$$.fragment,o),y(fa.$$.fragment,o),y(Kn.$$.fragment,o),y(_a.$$.fragment,o),y(Gn.$$.fragment,o),y(ba.$$.fragment,o),y(ka.$$.fragment,o),y(va.$$.fragment,o),y(Zn.$$.fragment,o),y(Aa.$$.fragment,o),y(Yn.$$.fragment,o),y($a.$$.fragment,o),y(Fa.$$.fragment,o),y(xa.$$.fragment,o),y(ts.$$.fragment,o),y(Pa.$$.fragment,o),y(os.$$.fragment,o),y(ja.$$.fragment,o),y(Ca.$$.fragment,o),y(Ia.$$.fragment,o),y(ss.$$.fragment,o),y(Oa.$$.fragment,o),y(rs.$$.fragment,o),y(Sa.$$.fragment,o),y(Wa.$$.fragment,o),y(Ua.$$.fragment,o),y(is.$$.fragment,o),y(Qa.$$.fragment,o),y(ls.$$.fragment,o),y(Va.$$.fragment,o),y(Ja.$$.fragment,o),y(Ka.$$.fragment,o),y(cs.$$.fragment,o),y(Ya.$$.fragment,o),y(ps.$$.fragment,o),y(ei.$$.fragment,o),y(ti.$$.fragment,o),y(oi.$$.fragment,o),y(fs.$$.fragment,o),y(ai.$$.fragment,o),y(ms.$$.fragment,o),y(ii.$$.fragment,o),y(li.$$.fragment,o),y(di.$$.fragment,o),y(_i.$$.fragment,o),y(gs.$$.fragment,o),y(bi.$$.fragment,o),y(ki.$$.fragment,o),y(vi.$$.fragment,o),y(Ei.$$.fragment,o),y(bs.$$.fragment,o),y(Mi.$$.fragment,o),y(zi.$$.fragment,o),y(qi.$$.fragment,o),y(Si.$$.fragment,o),y(vs.$$.fragment,o),y(Wi.$$.fragment,o),y(Ui.$$.fragment,o),y(Bi.$$.fragment,o),y(Xi.$$.fragment,o),y(ys.$$.fragment,o),y(Zi.$$.fragment,o),y(Yi.$$.fragment,o),y(el.$$.fragment,o),y(ll.$$.fragment,o),y(As.$$.fragment,o),y(dl.$$.fragment,o),y(cl.$$.fragment,o),y(pl.$$.fragment,o),y(kl.$$.fragment,o),y(Fs.$$.fragment,o),y(vl.$$.fragment,o),y(Tl.$$.fragment,o),y(yl.$$.fragment,o),y(zl.$$.fragment,o),y(Es.$$.fragment,o),y(ql.$$.fragment,o),Wm=!0)},o(o){w(_.$$.fragment,o),w(ee.$$.fragment,o),w(Ws.$$.fragment,o),w(Us.$$.fragment,o),w(Rs.$$.fragment,o),w(Hs.$$.fragment,o),w(Qs.$$.fragment,o),w(Gs.$$.fragment,o),w(Zs.$$.fragment,o),w(er.$$.fragment,o),w(tr.$$.fragment,o),w(or.$$.fragment,o),w(nr.$$.fragment,o),w(sr.$$.fragment,o),w(ar.$$.fragment,o),w(lr.$$.fragment,o),w(dr.$$.fragment,o),w(cr.$$.fragment,o),w(pr.$$.fragment,o),w(fr.$$.fragment,o),w(ur.$$.fragment,o),w(gr.$$.fragment,o),w(vr.$$.fragment,o),w(In.$$.fragment,o),w(Tr.$$.fragment,o),w(yr.$$.fragment,o),w(wr.$$.fragment,o),w(xr.$$.fragment,o),w(Nn.$$.fragment,o),w(Er.$$.fragment,o),w(Mr.$$.fragment,o),w(zr.$$.fragment,o),w(Ir.$$.fragment,o),w(On.$$.fragment,o),w(Lr.$$.fragment,o),w(Nr.$$.fragment,o),w(Dr.$$.fragment,o),w(Ur.$$.fragment,o),w(Wn.$$.fragment,o),w(Br.$$.fragment,o),w(Rr.$$.fragment,o),w(Hr.$$.fragment,o),w(Qr.$$.fragment,o),w(Gr.$$.fragment,o),w(Bn.$$.fragment,o),w(Xr.$$.fragment,o),w(Zr.$$.fragment,o),w(Yr.$$.fragment,o),w(na.$$.fragment,o),w(Hn.$$.fragment,o),w(sa.$$.fragment,o),w(ra.$$.fragment,o),w(aa.$$.fragment,o),w(ca.$$.fragment,o),w(Vn.$$.fragment,o),w(pa.$$.fragment,o),w(ha.$$.fragment,o),w(fa.$$.fragment,o),w(Kn.$$.fragment,o),w(_a.$$.fragment,o),w(Gn.$$.fragment,o),w(ba.$$.fragment,o),w(ka.$$.fragment,o),w(va.$$.fragment,o),w(Zn.$$.fragment,o),w(Aa.$$.fragment,o),w(Yn.$$.fragment,o),w($a.$$.fragment,o),w(Fa.$$.fragment,o),w(xa.$$.fragment,o),w(ts.$$.fragment,o),w(Pa.$$.fragment,o),w(os.$$.fragment,o),w(ja.$$.fragment,o),w(Ca.$$.fragment,o),w(Ia.$$.fragment,o),w(ss.$$.fragment,o),w(Oa.$$.fragment,o),w(rs.$$.fragment,o),w(Sa.$$.fragment,o),w(Wa.$$.fragment,o),w(Ua.$$.fragment,o),w(is.$$.fragment,o),w(Qa.$$.fragment,o),w(ls.$$.fragment,o),w(Va.$$.fragment,o),w(Ja.$$.fragment,o),w(Ka.$$.fragment,o),w(cs.$$.fragment,o),w(Ya.$$.fragment,o),w(ps.$$.fragment,o),w(ei.$$.fragment,o),w(ti.$$.fragment,o),w(oi.$$.fragment,o),w(fs.$$.fragment,o),w(ai.$$.fragment,o),w(ms.$$.fragment,o),w(ii.$$.fragment,o),w(li.$$.fragment,o),w(di.$$.fragment,o),w(_i.$$.fragment,o),w(gs.$$.fragment,o),w(bi.$$.fragment,o),w(ki.$$.fragment,o),w(vi.$$.fragment,o),w(Ei.$$.fragment,o),w(bs.$$.fragment,o),w(Mi.$$.fragment,o),w(zi.$$.fragment,o),w(qi.$$.fragment,o),w(Si.$$.fragment,o),w(vs.$$.fragment,o),w(Wi.$$.fragment,o),w(Ui.$$.fragment,o),w(Bi.$$.fragment,o),w(Xi.$$.fragment,o),w(ys.$$.fragment,o),w(Zi.$$.fragment,o),w(Yi.$$.fragment,o),w(el.$$.fragment,o),w(ll.$$.fragment,o),w(As.$$.fragment,o),w(dl.$$.fragment,o),w(cl.$$.fragment,o),w(pl.$$.fragment,o),w(kl.$$.fragment,o),w(Fs.$$.fragment,o),w(vl.$$.fragment,o),w(Tl.$$.fragment,o),w(yl.$$.fragment,o),w(zl.$$.fragment,o),w(Es.$$.fragment,o),w(ql.$$.fragment,o),Wm=!1},d(o){t(p),o&&t(F),o&&t(g),A(_),o&&t(G),o&&t(M),A(ee),o&&t(ae),o&&t(J),o&&t(P),o&&t(Y),o&&t(ie),o&&t(q),o&&t(Q),o&&t(oe),o&&t(le),o&&t(ne),o&&t(de),o&&t(O),o&&t(ye),o&&t(j),o&&t(ce),o&&t(be),A(Ws),o&&t(Hf),o&&t(Ve),A(Us),A(Rs),o&&t(Qf),o&&t(Eo),A(Hs),o&&t(Vf),o&&t(qe),A(Qs),A(Gs),A(Zs),A(er),A(tr),A(or),o&&t(Jf),o&&t(zo),A(nr),o&&t(Kf),o&&t(zt),A(sr),A(ar),A(lr),A(dr),o&&t(Gf),o&&t(qo),A(cr),o&&t(Xf),o&&t(Po),A(pr),o&&t(Zf),o&&t(jo),A(fr),o&&t(Yf),o&&t(Co),A(ur),o&&t(em),o&&t(Je),A(gr),A(vr),A(In),A(Tr),o&&t(tm),o&&t(Lo),A(yr),o&&t(om),o&&t(Ke),A(wr),A(xr),A(Nn),A(Er),o&&t(nm),o&&t(Oo),A(Mr),o&&t(sm),o&&t(Ge),A(zr),A(Ir),A(On),A(Lr),o&&t(rm),o&&t(Wo),A(Nr),o&&t(am),o&&t(Xe),A(Dr),A(Ur),A(Wn),A(Br),A(Rr),o&&t(im),o&&t(Bo),A(Hr),o&&t(lm),o&&t(Ze),A(Qr),A(Gr),A(Bn),A(Xr),o&&t(dm),o&&t(Ho),A(Zr),o&&t(cm),o&&t(Ye),A(Yr),A(na),A(Hn),A(sa),o&&t(pm),o&&t(Vo),A(ra),o&&t(hm),o&&t(et),A(aa),A(ca),A(Vn),A(pa),o&&t(fm),o&&t(Go),A(ha),o&&t(mm),o&&t(Se),A(fa),A(Kn),A(_a),A(Gn),A(ba),o&&t(um),o&&t(Zo),A(ka),o&&t(gm),o&&t(We),A(va),A(Zn),A(Aa),A(Yn),A($a),o&&t(_m),o&&t(tn),A(Fa),o&&t(bm),o&&t(Ue),A(xa),A(ts),A(Pa),A(os),A(ja),o&&t(km),o&&t(nn),A(Ca),o&&t(vm),o&&t(Be),A(Ia),A(ss),A(Oa),A(rs),A(Sa),o&&t(Tm),o&&t(rn),A(Wa),o&&t(ym),o&&t(Re),A(Ua),A(is),A(Qa),A(ls),A(Va),o&&t(wm),o&&t(ln),A(Ja),o&&t(Am),o&&t(He),A(Ka),A(cs),A(Ya),A(ps),A(ei),o&&t($m),o&&t(cn),A(ti),o&&t(Fm),o&&t(Qe),A(oi),A(fs),A(ai),A(ms),A(ii),o&&t(xm),o&&t(fn),A(li),o&&t(Em),o&&t(Pe),A(di),A(_i),A(gs),A(bi),o&&t(Mm),o&&t(un),A(ki),o&&t(zm),o&&t(je),A(vi),A(Ei),A(bs),A(Mi),o&&t(qm),o&&t(bn),A(zi),o&&t(Pm),o&&t(Ce),A(qi),A(Si),A(vs),A(Wi),o&&t(jm),o&&t(vn),A(Ui),o&&t(Cm),o&&t(Ie),A(Bi),A(Xi),A(ys),A(Zi),o&&t(Im),o&&t(yn),A(Yi),o&&t(Lm),o&&t(Le),A(el),A(ll),A(As),A(dl),o&&t(Nm),o&&t(An),A(cl),o&&t(Dm),o&&t(Ne),A(pl),A(kl),A(Fs),A(vl),o&&t(Om),o&&t(Fn),A(Tl),o&&t(Sm),o&&t(De),A(yl),A(zl),A(Es),A(ql)}}}const e5={local:"albert",sections:[{local:"overview",title:"Overview"},{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 t5(C,p,F){let{fw:g}=p;return C.$$set=b=>{"fw"in b&&F(0,g=b.fw)},[g]}class l5 extends Tz{constructor(p){super();yz(this,p,t5,Yz,wz,{fw:0})}}export{l5 as default,e5 as metadata};
