import{S as LJ,i as XJ,s as EJ,e as s,k as p,w as v,t as o,M as jJ,c as a,d as t,m as h,a as r,x as k,h as n,b as c,N as xJ,G as e,g,y as T,q as w,o as F,B as $,v as CJ,L as We}from"../../chunks/vendor-hf-doc-builder.js";import{T as Ue}from"../../chunks/Tip-hf-doc-builder.js";import{D as W}from"../../chunks/Docstring-hf-doc-builder.js";import{C as Be}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ne}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as qe}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";import{P as bg}from"../../chunks/PipelineTag-hf-doc-builder.js";function JJ(L){let d,M,m,f,b;return f=new Be({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFhMTVJvYmVydGFDb25maWclMkMlMjBYTE1Sb2JlcnRhTW9kZWwlMEElMEElMjMlMjBJbml0aWFsaXppbmclMjBhJTIwWExNLVJvQkVSVGElMjB4bG0tcm9iZXJ0YS1iYXNlJTIwc3R5bGUlMjBjb25maWd1cmF0aW9uJTBBY29uZmlndXJhdGlvbiUyMCUzRCUyMFhMTVJvYmVydGFDb25maWcoKSUwQSUwQSUyMyUyMEluaXRpYWxpemluZyUyMGElMjBtb2RlbCUyMCh3aXRoJTIwcmFuZG9tJTIwd2VpZ2h0cyklMjBmcm9tJTIwdGhlJTIweGxtLXJvYmVydGEtYmFzZSUyMHN0eWxlJTIwY29uZmlndXJhdGlvbiUwQW1vZGVsJTIwJTNEJTIwWExNUm9iZXJ0YU1vZGVsKGNvbmZpZ3VyYXRpb24pJTBBJTBBJTIzJTIwQWNjZXNzaW5nJTIwdGhlJTIwbW9kZWwlMjBjb25maWd1cmF0aW9uJTBBY29uZmlndXJhdGlvbiUyMCUzRCUyMG1vZGVsLmNvbmZpZw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> XLMRobertaConfig, XLMRobertaModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a XLM-RoBERTa xlm-roberta-base style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = XLMRobertaConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the xlm-roberta-base style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaModel(configuration)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Accessing the model configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = model.config`}}),{c(){d=s("p"),M=o("Examples:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Examples:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function zJ(L){let d,M,m,f,b;return{c(){d=s("p"),M=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s("code"),f=o("Module"),b=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a(u,"CODE",{});var X=r(m);f=n(X,"Module"),X.forEach(t),b=n(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(i,u){g(i,d,u),e(d,M),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function UJ(L){let d,M,m,f,b;return f=new Be({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBYTE1Sb2JlcnRhTW9kZWwlMEFpbXBvcnQlMjB0b3JjaCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMnhsbS1yb2JlcnRhLWJhc2UlMjIpJTBBbW9kZWwlMjAlM0QlMjBYTE1Sb2JlcnRhTW9kZWwuZnJvbV9wcmV0cmFpbmVkKCUyMnhsbS1yb2JlcnRhLWJhc2UlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyklMEElMEFsYXN0X2hpZGRlbl9zdGF0ZXMlMjAlM0QlMjBvdXRwdXRzLmxhc3RfaGlkZGVuX3N0YXRl",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, XLMRobertaModel
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaModel.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>config = AutoConfig.from_pretrained(<span class="hljs-string">&quot;roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>config.is_decoder = <span class="hljs-literal">True</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForCausalLM.from_pretrained(<span class="hljs-string">&quot;roberta-base&quot;</span>, config=config)

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForMaskedLM.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is &lt;mask&gt;.&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

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

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># retrieve index of &lt;mask&gt;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>mask_token_index = (inputs.input_ids == tokenizer.mask_token_id)[<span class="hljs-number">0</span>].nonzero(as_tuple=<span class="hljs-literal">True</span>)[<span class="hljs-number">0</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_id = logits[<span class="hljs-number">0</span>, mask_token_index].argmax(axis=-<span class="hljs-number">1</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predicted_token_id)
<span class="hljs-string">&#x27; Paris&#x27;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># mask labels of non-&lt;mask&gt; tokens</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(outputs.loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">0.1</span>`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function BJ(L){let d,M,m,f,b;return{c(){d=s("p"),M=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s("code"),f=o("Module"),b=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a(u,"CODE",{});var X=r(m);f=n(X,"Module"),X.forEach(t),b=n(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(i,u){g(i,d,u),e(d,M),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function ZJ(L){let d,M,m,f,b;return f=new Be({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMFhMTVJvYmVydGFGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyY2FyZGlmZm5scCUyRnR3aXR0ZXItcm9iZXJ0YS1iYXNlLWVtb3Rpb24lMjIpJTBBbW9kZWwlMjAlM0QlMjBYTE1Sb2JlcnRhRm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyY2FyZGlmZm5scCUyRnR3aXR0ZXItcm9iZXJ0YS1iYXNlLWVtb3Rpb24lMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMkhlbGxvJTJDJTIwbXklMjBkb2clMjBpcyUyMGN1dGUlMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBsb2dpdHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cykubG9naXRzJTBBJTBBcHJlZGljdGVkX2NsYXNzX2lkJTIwJTNEJTIwbG9naXRzLmFyZ21heCgpLml0ZW0oKSUwQW1vZGVsLmNvbmZpZy5pZDJsYWJlbCU1QnByZWRpY3RlZF9jbGFzc19pZCU1RCUwQSUwQSUyMyUyMFRvJTIwdHJhaW4lMjBhJTIwbW9kZWwlMjBvbiUyMCU2MG51bV9sYWJlbHMlNjAlMjBjbGFzc2VzJTJDJTIweW91JTIwY2FuJTIwcGFzcyUyMCU2MG51bV9sYWJlbHMlM0RudW1fbGFiZWxzJTYwJTIwdG8lMjAlNjAuZnJvbV9wcmV0cmFpbmVkKC4uLiklNjAlMEFudW1fbGFiZWxzJTIwJTNEJTIwbGVuKG1vZGVsLmNvbmZpZy5pZDJsYWJlbCklMEFtb2RlbCUyMCUzRCUyMFhMTVJvYmVydGFGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMjJjYXJkaWZmbmxwJTJGdHdpdHRlci1yb2JlcnRhLWJhc2UtZW1vdGlvbiUyMiUyQyUyMG51bV9sYWJlbHMlM0RudW1fbGFiZWxzKSUwQSUwQWxhYmVscyUyMCUzRCUyMHRvcmNoLnRlbnNvciglNUIxJTVEKSUwQWxvc3MlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscykubG9zcyUwQXJvdW5kKGxvc3MuaXRlbSgpJTJDJTIwMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, XLMRobertaForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = logits.argmax().item()
<span class="hljs-meta">&gt;&gt;&gt; </span>model.config.id2label[predicted_class_id]
<span class="hljs-string">&#x27;optimism&#x27;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>, num_labels=num_labels)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.tensor([<span class="hljs-number">1</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">0.08</span>`}}),{c(){d=s("p"),M=o("Example of single-label classification:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example of single-label classification:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function AJ(L){let d,M,m,f,b;return f=new Be({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMFhMTVJvYmVydGFGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyY2FyZGlmZm5scCUyRnR3aXR0ZXItcm9iZXJ0YS1iYXNlLWVtb3Rpb24lMjIpJTBBbW9kZWwlMjAlM0QlMjBYTE1Sb2JlcnRhRm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIyY2FyZGlmZm5scCUyRnR3aXR0ZXItcm9iZXJ0YS1iYXNlLWVtb3Rpb24lMjIlMkMlMjBwcm9ibGVtX3R5cGUlM0QlMjJtdWx0aV9sYWJlbF9jbGFzc2lmaWNhdGlvbiUyMiklMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIoJTIySGVsbG8lMkMlMjBteSUyMGRvZyUyMGlzJTIwY3V0ZSUyMiUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIpJTBBJTBBd2l0aCUyMHRvcmNoLm5vX2dyYWQoKSUzQSUwQSUyMCUyMCUyMCUyMGxvZ2l0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKS5sb2dpdHMlMEElMEFwcmVkaWN0ZWRfY2xhc3NfaWRzJTIwJTNEJTIwdG9yY2guYXJhbmdlKDAlMkMlMjBsb2dpdHMuc2hhcGUlNUItMSU1RCklNUJ0b3JjaC5zaWdtb2lkKGxvZ2l0cykuc3F1ZWV6ZShkaW0lM0QwKSUyMCUzRSUyMDAuNSU1RCUwQSUwQSUyMyUyMFRvJTIwdHJhaW4lMjBhJTIwbW9kZWwlMjBvbiUyMCU2MG51bV9sYWJlbHMlNjAlMjBjbGFzc2VzJTJDJTIweW91JTIwY2FuJTIwcGFzcyUyMCU2MG51bV9sYWJlbHMlM0RudW1fbGFiZWxzJTYwJTIwdG8lMjAlNjAuZnJvbV9wcmV0cmFpbmVkKC4uLiklNjAlMEFudW1fbGFiZWxzJTIwJTNEJTIwbGVuKG1vZGVsLmNvbmZpZy5pZDJsYWJlbCklMEFtb2RlbCUyMCUzRCUyMFhMTVJvYmVydGFGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMEElMjAlMjAlMjAlMjAlMjJjYXJkaWZmbmxwJTJGdHdpdHRlci1yb2JlcnRhLWJhc2UtZW1vdGlvbiUyMiUyQyUyMG51bV9sYWJlbHMlM0RudW1fbGFiZWxzJTJDJTIwcHJvYmxlbV90eXBlJTNEJTIybXVsdGlfbGFiZWxfY2xhc3NpZmljYXRpb24lMjIlMEEpJTBBJTBBbGFiZWxzJTIwJTNEJTIwdG9yY2guc3VtKCUwQSUyMCUyMCUyMCUyMHRvcmNoLm5uLmZ1bmN0aW9uYWwub25lX2hvdChwcmVkaWN0ZWRfY2xhc3NfaWRzJTVCTm9uZSUyQyUyMCUzQSU1RC5jbG9uZSgpJTJDJTIwbnVtX2NsYXNzZXMlM0RudW1fbGFiZWxzKSUyQyUyMGRpbSUzRDElMEEpLnRvKHRvcmNoLmZsb2F0KSUwQWxvc3MlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMGxhYmVscyUzRGxhYmVscykubG9zcw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, XLMRobertaForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>, problem_type=<span class="hljs-string">&quot;multi_label_classification&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_ids = torch.arange(<span class="hljs-number">0</span>, logits.shape[-<span class="hljs-number">1</span>])[torch.sigmoid(logits).squeeze(dim=<span class="hljs-number">0</span>) &gt; <span class="hljs-number">0.5</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForSequenceClassification.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>, num_labels=num_labels, problem_type=<span class="hljs-string">&quot;multi_label_classification&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.<span class="hljs-built_in">sum</span>(
<span class="hljs-meta">... </span>    torch.nn.functional.one_hot(predicted_class_ids[<span class="hljs-literal">None</span>, :].clone(), num_classes=num_labels), dim=<span class="hljs-number">1</span>
<span class="hljs-meta">... </span>).to(torch.<span class="hljs-built_in">float</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=s("p"),M=o("Example of multi-label classification:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example of multi-label classification:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function GJ(L){let d,M,m,f,b;return{c(){d=s("p"),M=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s("code"),f=o("Module"),b=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a(u,"CODE",{});var X=r(m);f=n(X,"Module"),X.forEach(t),b=n(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(i,u){g(i,d,u),e(d,M),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function VJ(L){let d,M,m,f,b;return f=new Be({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBYTE1Sb2JlcnRhRm9yTXVsdGlwbGVDaG9pY2UlMEFpbXBvcnQlMjB0b3JjaCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMnhsbS1yb2JlcnRhLWJhc2UlMjIpJTBBbW9kZWwlMjAlM0QlMjBYTE1Sb2JlcnRhRm9yTXVsdGlwbGVDaG9pY2UuZnJvbV9wcmV0cmFpbmVkKCUyMnhsbS1yb2JlcnRhLWJhc2UlMjIpJTBBJTBBcHJvbXB0JTIwJTNEJTIwJTIySW4lMjBJdGFseSUyQyUyMHBpenphJTIwc2VydmVkJTIwaW4lMjBmb3JtYWwlMjBzZXR0aW5ncyUyQyUyMHN1Y2glMjBhcyUyMGF0JTIwYSUyMHJlc3RhdXJhbnQlMkMlMjBpcyUyMHByZXNlbnRlZCUyMHVuc2xpY2VkLiUyMiUwQWNob2ljZTAlMjAlM0QlMjAlMjJJdCUyMGlzJTIwZWF0ZW4lMjB3aXRoJTIwYSUyMGZvcmslMjBhbmQlMjBhJTIwa25pZmUuJTIyJTBBY2hvaWNlMSUyMCUzRCUyMCUyMkl0JTIwaXMlMjBlYXRlbiUyMHdoaWxlJTIwaGVsZCUyMGluJTIwdGhlJTIwaGFuZC4lMjIlMEFsYWJlbHMlMjAlM0QlMjB0b3JjaC50ZW5zb3IoMCkudW5zcXVlZXplKDApJTIwJTIwJTIzJTIwY2hvaWNlMCUyMGlzJTIwY29ycmVjdCUyMChhY2NvcmRpbmclMjB0byUyMFdpa2lwZWRpYSUyMCUzQikpJTJDJTIwYmF0Y2glMjBzaXplJTIwMSUwQSUwQWVuY29kaW5nJTIwJTNEJTIwdG9rZW5pemVyKCU1QnByb21wdCUyQyUyMHByb21wdCU1RCUyQyUyMCU1QmNob2ljZTAlMkMlMjBjaG9pY2UxJTVEJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJwdCUyMiUyQyUyMHBhZGRpbmclM0RUcnVlKSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKiU3QmslM0ElMjB2LnVuc3F1ZWV6ZSgwKSUyMGZvciUyMGslMkMlMjB2JTIwaW4lMjBlbmNvZGluZy5pdGVtcygpJTdEJTJDJTIwbGFiZWxzJTNEbGFiZWxzKSUyMCUyMCUyMyUyMGJhdGNoJTIwc2l6ZSUyMGlzJTIwMSUwQSUwQSUyMyUyMHRoZSUyMGxpbmVhciUyMGNsYXNzaWZpZXIlMjBzdGlsbCUyMG5lZWRzJTIwdG8lMjBiZSUyMHRyYWluZWQlMEFsb3NzJTIwJTNEJTIwb3V0cHV0cy5sb3NzJTBBbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5sb2dpdHM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, XLMRobertaForMultipleChoice
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># the linear classifier still needs to be trained</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = outputs.loss
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function SJ(L){let d,M,m,f,b;return{c(){d=s("p"),M=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s("code"),f=o("Module"),b=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a(u,"CODE",{});var X=r(m);f=n(X,"Module"),X.forEach(t),b=n(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(i,u){g(i,d,u),e(d,M),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function PJ(L){let d,M,m,f,b;return f=new Be({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBYTE1Sb2JlcnRhRm9yVG9rZW5DbGFzc2lmaWNhdGlvbiUwQWltcG9ydCUyMHRvcmNoJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIySmVhbi1CYXB0aXN0ZSUyRnJvYmVydGEtbGFyZ2UtbmVyLWVuZ2xpc2glMjIpJTBBbW9kZWwlMjAlM0QlMjBYTE1Sb2JlcnRhRm9yVG9rZW5DbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIySmVhbi1CYXB0aXN0ZSUyRnJvYmVydGEtbGFyZ2UtbmVyLWVuZ2xpc2glMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUwQSUyMCUyMCUyMCUyMCUyMkh1Z2dpbmdGYWNlJTIwaXMlMjBhJTIwY29tcGFueSUyMGJhc2VkJTIwaW4lMjBQYXJpcyUyMGFuZCUyME5ldyUyMFlvcmslMjIlMkMlMjBhZGRfc3BlY2lhbF90b2tlbnMlM0RGYWxzZSUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIlMEEpJTBBJTBBd2l0aCUyMHRvcmNoLm5vX2dyYWQoKSUzQSUwQSUyMCUyMCUyMCUyMGxvZ2l0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzKS5sb2dpdHMlMEElMEFwcmVkaWN0ZWRfdG9rZW5fY2xhc3NfaWRzJTIwJTNEJTIwbG9naXRzLmFyZ21heCgtMSklMEElMEElMjMlMjBOb3RlJTIwdGhhdCUyMHRva2VucyUyMGFyZSUyMGNsYXNzaWZpZWQlMjByYXRoZXIlMjB0aGVuJTIwaW5wdXQlMjB3b3JkcyUyMHdoaWNoJTIwbWVhbnMlMjB0aGF0JTBBJTIzJTIwdGhlcmUlMjBtaWdodCUyMGJlJTIwbW9yZSUyMHByZWRpY3RlZCUyMHRva2VuJTIwY2xhc3NlcyUyMHRoYW4lMjB3b3Jkcy4lMEElMjMlMjBNdWx0aXBsZSUyMHRva2VuJTIwY2xhc3NlcyUyMG1pZ2h0JTIwYWNjb3VudCUyMGZvciUyMHRoZSUyMHNhbWUlMjB3b3JkJTBBcHJlZGljdGVkX3Rva2Vuc19jbGFzc2VzJTIwJTNEJTIwJTVCbW9kZWwuY29uZmlnLmlkMmxhYmVsJTVCdC5pdGVtKCklNUQlMjBmb3IlMjB0JTIwaW4lMjBwcmVkaWN0ZWRfdG9rZW5fY2xhc3NfaWRzJTVCMCU1RCU1RCUwQXByZWRpY3RlZF90b2tlbnNfY2xhc3NlcyUwQSUwQWxhYmVscyUyMCUzRCUyMHByZWRpY3RlZF90b2tlbl9jbGFzc19pZHMlMEFsb3NzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMlMkMlMjBsYWJlbHMlM0RsYWJlbHMpLmxvc3MlMEFyb3VuZChsb3NzLml0ZW0oKSUyQyUyMDIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, XLMRobertaForTokenClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;Jean-Baptiste/roberta-large-ner-english&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForTokenClassification.from_pretrained(<span class="hljs-string">&quot;Jean-Baptiste/roberta-large-ner-english&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;HuggingFace is a company based in Paris and New York&quot;</span>, add_special_tokens=<span class="hljs-literal">False</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>
<span class="hljs-meta">... </span>)

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_class_ids = logits.argmax(-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Note that tokens are classified rather then input words which means that</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># there might be more predicted token classes than words.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Multiple token classes might account for the same word</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes = [model.config.id2label[t.item()] <span class="hljs-keyword">for</span> t <span class="hljs-keyword">in</span> predicted_token_class_ids[<span class="hljs-number">0</span>]]
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes
[<span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;ORG&#x27;</span>, <span class="hljs-string">&#x27;ORG&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;LOC&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;LOC&#x27;</span>, <span class="hljs-string">&#x27;LOC&#x27;</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">0.01</span>`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function OJ(L){let d,M,m,f,b;return{c(){d=s("p"),M=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s("code"),f=o("Module"),b=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a(u,"CODE",{});var X=r(m);f=n(X,"Module"),X.forEach(t),b=n(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(i,u){g(i,d,u),e(d,M),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function DJ(L){let d,M,m,f,b;return f=new Be({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBYTE1Sb2JlcnRhRm9yUXVlc3Rpb25BbnN3ZXJpbmclMEFpbXBvcnQlMjB0b3JjaCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMmRlZXBzZXQlMkZyb2JlcnRhLWJhc2Utc3F1YWQyJTIyKSUwQW1vZGVsJTIwJTNEJTIwWExNUm9iZXJ0YUZvclF1ZXN0aW9uQW5zd2VyaW5nLmZyb21fcHJldHJhaW5lZCglMjJkZWVwc2V0JTJGcm9iZXJ0YS1iYXNlLXNxdWFkMiUyMiklMEElMEFxdWVzdGlvbiUyQyUyMHRleHQlMjAlM0QlMjAlMjJXaG8lMjB3YXMlMjBKaW0lMjBIZW5zb24lM0YlMjIlMkMlMjAlMjJKaW0lMjBIZW5zb24lMjB3YXMlMjBhJTIwbmljZSUyMHB1cHBldCUyMiUwQSUwQWlucHV0cyUyMCUzRCUyMHRva2VuaXplcihxdWVzdGlvbiUyQyUyMHRleHQlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMnB0JTIyKSUwQXdpdGglMjB0b3JjaC5ub19ncmFkKCklM0ElMEElMjAlMjAlMjAlMjBvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBJTBBYW5zd2VyX3N0YXJ0X2luZGV4JTIwJTNEJTIwb3V0cHV0cy5zdGFydF9sb2dpdHMuYXJnbWF4KCklMEFhbnN3ZXJfZW5kX2luZGV4JTIwJTNEJTIwb3V0cHV0cy5lbmRfbG9naXRzLmFyZ21heCgpJTBBJTBBcHJlZGljdF9hbnN3ZXJfdG9rZW5zJTIwJTNEJTIwaW5wdXRzLmlucHV0X2lkcyU1QjAlMkMlMjBhbnN3ZXJfc3RhcnRfaW5kZXglMjAlM0ElMjBhbnN3ZXJfZW5kX2luZGV4JTIwJTJCJTIwMSU1RCUwQXRva2VuaXplci5kZWNvZGUocHJlZGljdF9hbnN3ZXJfdG9rZW5zJTJDJTIwc2tpcF9zcGVjaWFsX3Rva2VucyUzRFRydWUpJTBBJTBBJTIzJTIwdGFyZ2V0JTIwaXMlMjAlMjJuaWNlJTIwcHVwcGV0JTIyJTBBdGFyZ2V0X3N0YXJ0X2luZGV4JTIwJTNEJTIwdG9yY2gudGVuc29yKCU1QjE0JTVEKSUwQXRhcmdldF9lbmRfaW5kZXglMjAlM0QlMjB0b3JjaC50ZW5zb3IoJTVCMTUlNUQpJTBBJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzJTJDJTIwc3RhcnRfcG9zaXRpb25zJTNEdGFyZ2V0X3N0YXJ0X2luZGV4JTJDJTIwZW5kX3Bvc2l0aW9ucyUzRHRhcmdldF9lbmRfaW5kZXgpJTBBbG9zcyUyMCUzRCUyMG91dHB1dHMubG9zcyUwQXJvdW5kKGxvc3MuaXRlbSgpJTJDJTIwMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, XLMRobertaForQuestionAnswering
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;deepset/roberta-base-squad2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = XLMRobertaForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;deepset/roberta-base-squad2&quot;</span>)

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

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

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

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFXLMRobertaModel.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFXLMRobertaForMaskedLM.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is &lt;mask&gt;.&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># retrieve index of &lt;mask&gt;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>mask_token_index = tf.where((inputs.input_ids == tokenizer.mask_token_id)[<span class="hljs-number">0</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>selected_logits = tf.gather_nd(logits[<span class="hljs-number">0</span>], indices=mask_token_index)

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_id = tf.math.argmax(selected_logits, axis=-<span class="hljs-number">1</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predicted_token_id)
<span class="hljs-string">&#x27; Paris&#x27;</span>`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function az(L){let d,M;return d=new Be({props:{code:"bGFiZWxzJTIwJTNEJTIwdG9rZW5pemVyKCUyMlRoZSUyMGNhcGl0YWwlMjBvZiUyMEZyYW5jZSUyMGlzJTIwUGFyaXMuJTIyJTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJ0ZiUyMiklNUIlMjJpbnB1dF9pZHMlMjIlNUQlMEElMjMlMjBtYXNrJTIwbGFiZWxzJTIwb2YlMjBub24tJTNDbWFzayUzRSUyMHRva2VucyUwQWxhYmVscyUyMCUzRCUyMHRmLndoZXJlKGlucHV0cy5pbnB1dF9pZHMlMjAlM0QlM0QlMjB0b2tlbml6ZXIubWFza190b2tlbl9pZCUyQyUyMGxhYmVscyUyQyUyMC0xMDApJTBBJTBBb3V0cHV0cyUyMCUzRCUyMG1vZGVsKCoqaW5wdXRzJTJDJTIwbGFiZWxzJTNEbGFiZWxzKSUwQXJvdW5kKGZsb2F0KG91dHB1dHMubG9zcyklMkMlMjAyKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># mask labels of non-&lt;mask&gt; tokens</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tf.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFXLMRobertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;cardiffnlp/twitter-roberta-base-emotion&quot;</span>)

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

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFXLMRobertaForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;ydshieh/roberta-large-ner-english&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFXLMRobertaForTokenClassification.from_pretrained(<span class="hljs-string">&quot;ydshieh/roberta-large-ner-english&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;HuggingFace is a company based in Paris and New York&quot;</span>, add_special_tokens=<span class="hljs-literal">False</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_class_ids = tf.math.argmax(logits, axis=-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Note that tokens are classified rather then input words which means that</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># there might be more predicted token classes than words.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Multiple token classes might account for the same word</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes = [model.config.id2label[t] <span class="hljs-keyword">for</span> t <span class="hljs-keyword">in</span> predicted_token_class_ids[<span class="hljs-number">0</span>].numpy().tolist()]
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes
[<span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;ORG&#x27;</span>, <span class="hljs-string">&#x27;ORG&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;LOC&#x27;</span>, <span class="hljs-string">&#x27;O&#x27;</span>, <span class="hljs-string">&#x27;LOC&#x27;</span>, <span class="hljs-string">&#x27;LOC&#x27;</span>]`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function gz(L){let d,M;return d=new Be({props:{code:"bGFiZWxzJTIwJTNEJTIwcHJlZGljdGVkX3Rva2VuX2NsYXNzX2lkcyUwQWxvc3MlMjAlM0QlMjB0Zi5tYXRoLnJlZHVjZV9tZWFuKG1vZGVsKCoqaW5wdXRzJTJDJTIwbGFiZWxzJTNEbGFiZWxzKS5sb3NzKSUwQXJvdW5kKGZsb2F0KGxvc3MpJTJDJTIwMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(model(**inputs, labels=labels).loss)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(<span class="hljs-built_in">float</span>(loss), <span class="hljs-number">2</span>)
<span class="hljs-number">0.01</span>`}}),{c(){v(d.$$.fragment)},l(m){k(d.$$.fragment,m)},m(m,f){T(d,m,f),M=!0},p:We,i(m){M||(w(d.$$.fragment,m),M=!0)},o(m){F(d.$$.fragment,m),M=!1},d(m){$(d,m)}}}function _z(L){let d,M,m,f,b,i,u,X,Me,fe,q,ce,te,R,ye,A,pe,Ce,O,ae,re,G,le,ve,V,ke,ge,B,Te,ie,oe,j,z,he,Q,_e,ue,S,we,be,J,Fe,D,ne,de,Y,me,$e,N,Re,P,xe,se,C,Le,U,Xe,Ee;return{c(){d=s("p"),M=o("TensorFlow models and layers in "),m=s("code"),f=o("transformers"),b=o(" accept two formats as input:"),i=p(),u=s("ul"),X=s("li"),Me=o("having all inputs as keyword arguments (like PyTorch models), or"),fe=p(),q=s("li"),ce=o("having all inputs as a list, tuple or dict in the first positional argument."),te=p(),R=s("p"),ye=o(`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),A=s("code"),pe=o("model.fit()"),Ce=o(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),O=s("code"),ae=o("model.fit()"),re=o(` supports! If, however, you want to use the second
format outside of Keras methods like `),G=s("code"),le=o("fit()"),ve=o(" and "),V=s("code"),ke=o("predict()"),ge=o(`, such as when creating your own layers or models with
the Keras `),B=s("code"),Te=o("Functional"),ie=o(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),oe=p(),j=s("ul"),z=s("li"),he=o("a single Tensor with "),Q=s("code"),_e=o("input_ids"),ue=o(" only and nothing else: "),S=s("code"),we=o("model(input_ids)"),be=p(),J=s("li"),Fe=o(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),D=s("code"),ne=o("model([input_ids, attention_mask])"),de=o(" or "),Y=s("code"),me=o("model([input_ids, attention_mask, token_type_ids])"),$e=p(),N=s("li"),Re=o(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),P=s("code"),xe=o('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),se=p(),C=s("p"),Le=o(`Note that when creating models and layers with
`),U=s("a"),Xe=o("subclassing"),Ee=o(` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),this.h()},l(y){d=a(y,"P",{});var x=r(d);M=n(x,"TensorFlow models and layers in "),m=a(x,"CODE",{});var Pe=r(m);f=n(Pe,"transformers"),Pe.forEach(t),b=n(x," accept two formats as input:"),x.forEach(t),i=h(y),u=a(y,"UL",{});var K=r(u);X=a(K,"LI",{});var Oe=r(X);Me=n(Oe,"having all inputs as keyword arguments (like PyTorch models), or"),Oe.forEach(t),fe=h(K),q=a(K,"LI",{});var De=r(q);ce=n(De,"having all inputs as a list, tuple or dict in the first positional argument."),De.forEach(t),K.forEach(t),te=h(y),R=a(y,"P",{});var E=r(R);ye=n(E,`The reason the second format is supported is that Keras methods prefer this format when passing inputs to models
and layers. Because of this support, when using methods like `),A=a(E,"CODE",{});var Qe=r(A);pe=n(Qe,"model.fit()"),Qe.forEach(t),Ce=n(E,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),O=a(E,"CODE",{});var Ye=r(O);ae=n(Ye,"model.fit()"),Ye.forEach(t),re=n(E,` supports! If, however, you want to use the second
format outside of Keras methods like `),G=a(E,"CODE",{});var Ae=r(G);le=n(Ae,"fit()"),Ae.forEach(t),ve=n(E," and "),V=a(E,"CODE",{});var Je=r(V);ke=n(Je,"predict()"),Je.forEach(t),ge=n(E,`, such as when creating your own layers or models with
the Keras `),B=a(E,"CODE",{});var ze=r(B);Te=n(ze,"Functional"),ze.forEach(t),ie=n(E,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),E.forEach(t),oe=h(y),j=a(y,"UL",{});var I=r(j);z=a(I,"LI",{});var Z=r(z);he=n(Z,"a single Tensor with "),Q=a(Z,"CODE",{});var He=r(Q);_e=n(He,"input_ids"),He.forEach(t),ue=n(Z," only and nothing else: "),S=a(Z,"CODE",{});var Ze=r(S);we=n(Ze,"model(input_ids)"),Ze.forEach(t),Z.forEach(t),be=h(I),J=a(I,"LI",{});var H=r(J);Fe=n(H,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),D=a(H,"CODE",{});var Ge=r(D);ne=n(Ge,"model([input_ids, attention_mask])"),Ge.forEach(t),de=n(H," or "),Y=a(H,"CODE",{});var Ie=r(Y);me=n(Ie,"model([input_ids, attention_mask, token_type_ids])"),Ie.forEach(t),H.forEach(t),$e=h(I),N=a(I,"LI",{});var je=r(N);Re=n(je,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),P=a(je,"CODE",{});var Ve=r(P);xe=n(Ve,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Ve.forEach(t),je.forEach(t),I.forEach(t),se=h(y),C=a(y,"P",{});var ee=r(C);Le=n(ee,`Note that when creating models and layers with
`),U=a(ee,"A",{href:!0,rel:!0});var Se=r(U);Xe=n(Se,"subclassing"),Se.forEach(t),Ee=n(ee,` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),ee.forEach(t),this.h()},h(){c(U,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),c(U,"rel","nofollow")},m(y,x){g(y,d,x),e(d,M),e(d,m),e(m,f),e(d,b),g(y,i,x),g(y,u,x),e(u,X),e(X,Me),e(u,fe),e(u,q),e(q,ce),g(y,te,x),g(y,R,x),e(R,ye),e(R,A),e(A,pe),e(R,Ce),e(R,O),e(O,ae),e(R,re),e(R,G),e(G,le),e(R,ve),e(R,V),e(V,ke),e(R,ge),e(R,B),e(B,Te),e(R,ie),g(y,oe,x),g(y,j,x),e(j,z),e(z,he),e(z,Q),e(Q,_e),e(z,ue),e(z,S),e(S,we),e(j,be),e(j,J),e(J,Fe),e(J,D),e(D,ne),e(J,de),e(J,Y),e(Y,me),e(j,$e),e(j,N),e(N,Re),e(N,P),e(P,xe),g(y,se,x),g(y,C,x),e(C,Le),e(C,U),e(U,Xe),e(C,Ee)},d(y){y&&t(d),y&&t(i),y&&t(u),y&&t(te),y&&t(R),y&&t(oe),y&&t(j),y&&t(se),y&&t(C)}}}function bz(L){let d,M,m,f,b;return{c(){d=s("p"),M=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s("code"),f=o("Module"),b=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a(u,"CODE",{});var X=r(m);f=n(X,"Module"),X.forEach(t),b=n(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(i,u){g(i,d,u),e(d,M),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function Mz(L){let d,M,m,f,b;return f=new Be({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURlhMTVJvYmVydGFGb3JRdWVzdGlvbkFuc3dlcmluZyUwQWltcG9ydCUyMHRlbnNvcmZsb3clMjBhcyUyMHRmJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyeWRzaGllaCUyRnJvYmVydGEtYmFzZS1zcXVhZDIlMjIpJTBBbW9kZWwlMjAlM0QlMjBURlhMTVJvYmVydGFGb3JRdWVzdGlvbkFuc3dlcmluZy5mcm9tX3ByZXRyYWluZWQoJTIyeWRzaGllaCUyRnJvYmVydGEtYmFzZS1zcXVhZDIlMjIpJTBBJTBBcXVlc3Rpb24lMkMlMjB0ZXh0JTIwJTNEJTIwJTIyV2hvJTIwd2FzJTIwSmltJTIwSGVuc29uJTNGJTIyJTJDJTIwJTIySmltJTIwSGVuc29uJTIwd2FzJTIwYSUyMG5pY2UlMjBwdXBwZXQlMjIlMEElMEFpbnB1dHMlMjAlM0QlMjB0b2tlbml6ZXIocXVlc3Rpb24lMkMlMjB0ZXh0JTJDJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJ0ZiUyMiklMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBJTBBYW5zd2VyX3N0YXJ0X2luZGV4JTIwJTNEJTIwaW50KHRmLm1hdGguYXJnbWF4KG91dHB1dHMuc3RhcnRfbG9naXRzJTJDJTIwYXhpcyUzRC0xKSU1QjAlNUQpJTBBYW5zd2VyX2VuZF9pbmRleCUyMCUzRCUyMGludCh0Zi5tYXRoLmFyZ21heChvdXRwdXRzLmVuZF9sb2dpdHMlMkMlMjBheGlzJTNELTEpJTVCMCU1RCklMEElMEFwcmVkaWN0X2Fuc3dlcl90b2tlbnMlMjAlM0QlMjBpbnB1dHMuaW5wdXRfaWRzJTVCMCUyQyUyMGFuc3dlcl9zdGFydF9pbmRleCUyMCUzQSUyMGFuc3dlcl9lbmRfaW5kZXglMjAlMkIlMjAxJTVEJTBBdG9rZW5pemVyLmRlY29kZShwcmVkaWN0X2Fuc3dlcl90b2tlbnMp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFXLMRobertaForQuestionAnswering
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;ydshieh/roberta-base-squad2&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFXLMRobertaForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;ydshieh/roberta-base-squad2&quot;</span>)

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predict_answer_tokens = inputs.input_ids[<span class="hljs-number">0</span>, answer_start_index : answer_end_index + <span class="hljs-number">1</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.decode(predict_answer_tokens)
<span class="hljs-string">&#x27; puppet&#x27;</span>`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function yz(L){let d,M;return d=new Be({props:{code:"JTIzJTIwdGFyZ2V0JTIwaXMlMjAlMjJuaWNlJTIwcHVwcGV0JTIyJTBBdGFyZ2V0X3N0YXJ0X2luZGV4JTIwJTNEJTIwdGYuY29uc3RhbnQoJTVCMTQlNUQpJTBBdGFyZ2V0X2VuZF9pbmRleCUyMCUzRCUyMHRmLmNvbnN0YW50KCU1QjE1JTVEKSUwQSUwQW91dHB1dHMlMjAlM0QlMjBtb2RlbCgqKmlucHV0cyUyQyUyMHN0YXJ0X3Bvc2l0aW9ucyUzRHRhcmdldF9zdGFydF9pbmRleCUyQyUyMGVuZF9wb3NpdGlvbnMlM0R0YXJnZXRfZW5kX2luZGV4KSUwQWxvc3MlMjAlM0QlMjB0Zi5tYXRoLnJlZHVjZV9tZWFuKG91dHB1dHMubG9zcyklMEFyb3VuZChmbG9hdChsb3NzKSUyQyUyMDIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># target is &quot;nice puppet&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>target_start_index = tf.constant([<span class="hljs-number">14</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>target_end_index = tf.constant([<span class="hljs-number">15</span>])

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxXLMRobertaModel.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxXLMRobertaForCausalLM.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&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><span class="hljs-comment"># retrieve logts for next token</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>next_token_logits = outputs.logits[:, -<span class="hljs-number">1</span>]`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function Fz(L){let d,M,m,f,b;return{c(){d=s("p"),M=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),m=s("code"),f=o("Module"),b=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Although the recipe for forward pass needs to be defined within this function, one should call the "),m=a(u,"CODE",{});var X=r(m);f=n(X,"Module"),X.forEach(t),b=n(u,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),u.forEach(t)},m(i,u){g(i,d,u),e(d,M),e(d,m),e(m,f),e(d,b)},d(i){i&&t(d)}}}function $z(L){let d,M,m,f,b;return f=new Be({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBGbGF4WExNUm9iZXJ0YUZvck1hc2tlZExNJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoJTIyeGxtLXJvYmVydGEtYmFzZSUyMiklMEFtb2RlbCUyMCUzRCUyMEZsYXhYTE1Sb2JlcnRhRm9yTWFza2VkTE0uZnJvbV9wcmV0cmFpbmVkKCUyMnhsbS1yb2JlcnRhLWJhc2UlMjIpJTBBJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKCUyMlRoZSUyMGNhcGl0YWwlMjBvZiUyMEZyYW5jZSUyMGlzJTIwJTVCTUFTSyU1RC4lMjIlMkMlMjByZXR1cm5fdGVuc29ycyUzRCUyMmpheCUyMiklMEElMEFvdXRwdXRzJTIwJTNEJTIwbW9kZWwoKippbnB1dHMpJTBBbG9naXRzJTIwJTNEJTIwb3V0cHV0cy5sb2dpdHM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxXLMRobertaForMaskedLM

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxXLMRobertaForMaskedLM.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is [MASK].&quot;</span>, return_tensors=<span class="hljs-string">&quot;jax&quot;</span>)

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxXLMRobertaForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxXLMRobertaForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxXLMRobertaForTokenClassification.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxXLMRobertaForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;xlm-roberta-base&quot;</span>)

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

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>start_scores = outputs.start_logits
<span class="hljs-meta">&gt;&gt;&gt; </span>end_scores = outputs.end_logits`}}),{c(){d=s("p"),M=o("Example:"),m=p(),v(f.$$.fragment)},l(i){d=a(i,"P",{});var u=r(d);M=n(u,"Example:"),u.forEach(t),m=h(i),k(f.$$.fragment,i)},m(i,u){g(i,d,u),e(d,M),g(i,m,u),T(f,i,u),b=!0},p:We,i(i){b||(w(f.$$.fragment,i),b=!0)},o(i){F(f.$$.fragment,i),b=!1},d(i){i&&t(d),i&&t(m),$(f,i)}}}function zz(L){let d,M,m,f,b,i,u,X,Me,fe,q,ce,te,R,ye,A,pe,Ce,O,ae,re,G,le,ve,V,ke,ge,B,Te,ie,oe,j,z,he,Q,_e,ue,S,we,be,J,Fe,D,ne,de,Y,me,$e,N,Re,P,xe,se,C,Le,U,Xe,Ee,y,x,Pe,K,Oe,De,E,Qe,Ye,Ae,Je,ze,I,Z,He,Ze,H,Ge,Ie,je,Ve,ee,Se,gt,Lc,Kb,ir,eM,tM,Fo,Xc,oM,nM,dr,sM,aM,cr,rM,lM,iM,$o,Ec,dM,cM,pr,pM,hM,hr,uM,mM,fM,Ro,jc,gM,_M,ur,bM,MM,mr,yM,vM,kM,Cc,fr,TM,wM,FM,jh,Jc,$M,Mg,gr,yg,$t,xo,zc,RM,xM,_r,LM,XM,br,EM,jM,CM,Lo,Uc,JM,zM,Mr,UM,IM,yr,NM,qM,WM,as,Ic,BM,ZM,vr,AM,GM,VM,Nc,kr,SM,PM,OM,Ch,qc,DM,vg,Tr,kg,Xo,Eo,Wc,QM,YM,wr,HM,KM,Fr,ey,ty,oy,Bc,$r,ny,sy,ay,Jh,Zc,ry,Tg,Rr,wg,Rt,jo,Ac,ly,iy,xr,dy,cy,Lr,py,hy,uy,Co,Gc,my,fy,Xr,gy,_y,Er,by,My,yy,Jo,Vc,vy,ky,jr,Ty,wy,Cr,Fy,$y,Ry,Sc,Jr,xy,Ly,Xy,zh,Pc,Ey,Fg,zr,$g,xt,zo,Oc,jy,Cy,Ur,Jy,zy,Ir,Uy,Iy,Ny,Uo,Dc,qy,Wy,Nr,By,Zy,qr,Ay,Gy,Vy,rs,Qc,Sy,Py,Wr,Oy,Dy,Qy,Yc,Br,Yy,Hy,Ky,Uh,Hc,ev,Rg,Kc,Ih,tv,xg,Io,No,ep,ov,nv,Zr,sv,av,Ar,rv,lv,iv,qo,tp,dv,cv,Gr,pv,hv,Vr,uv,mv,fv,Nh,op,gv,Lg,np,_v,Xg,sp,Sr,bv,Pr,Mv,yv,Eg,ln,ls,qh,Or,vv,Wh,kv,jg,At,Dr,Tv,go,wv,ap,Fv,$v,rp,Rv,xv,Qr,Lv,Xv,Ev,dn,jv,lp,Cv,Jv,ip,zv,Uv,Iv,is,Cg,cn,ds,Bh,Yr,Nv,Zh,qv,Jg,et,Hr,Wv,_o,Bv,dp,Zv,Av,cp,Gv,Vv,Kr,Sv,Pv,Ov,el,Dv,pp,Qv,Yv,Hv,Wo,tl,Kv,Ah,ek,tk,ol,hp,ok,Gh,nk,sk,up,ak,Vh,rk,lk,cs,nl,ik,sl,dk,Sh,ck,pk,hk,ps,al,uk,Ph,mk,fk,mp,rl,zg,pn,hs,Oh,ll,gk,Dh,_k,Ug,bt,il,bk,Gt,Mk,Qh,yk,vk,fp,kk,Tk,gp,wk,Fk,dl,$k,Rk,xk,cl,Lk,_p,Xk,Ek,jk,Bo,pl,Ck,Yh,Jk,zk,hl,bp,Uk,Hh,Ik,Nk,Mp,qk,Kh,Wk,Bk,us,ul,Zk,eu,Ak,Ig,hn,ms,tu,ml,Gk,ou,Vk,Ng,Ke,fl,Sk,nu,Pk,Ok,gl,Dk,yp,Qk,Yk,Hk,_l,Kk,bl,eT,tT,oT,Ml,nT,su,sT,aT,rT,it,lT,au,iT,dT,ru,cT,pT,lu,hT,uT,iu,mT,fT,du,gT,_T,cu,bT,MT,yT,fs,vT,pu,kT,TT,yl,wT,FT,St,vl,$T,un,RT,vp,xT,LT,hu,XT,ET,jT,gs,CT,_s,qg,mn,bs,uu,kl,JT,mu,zT,Wg,Mt,Tl,UT,wl,IT,fu,NT,qT,WT,Fl,BT,kp,ZT,AT,GT,$l,VT,Rl,ST,PT,OT,Pt,xl,DT,fn,QT,Tp,YT,HT,gu,KT,ew,tw,Ms,ow,ys,Bg,gn,vs,_u,Ll,nw,bu,sw,Zg,yt,Xl,aw,El,rw,Mu,lw,iw,dw,jl,cw,wp,pw,hw,uw,Cl,mw,Jl,fw,gw,_w,Ot,zl,bw,_n,Mw,Fp,yw,vw,yu,kw,Tw,ww,ks,Fw,Ts,Ag,bn,ws,vu,Ul,$w,ku,Rw,Gg,vt,Il,xw,Tu,Lw,Xw,Nl,Ew,$p,jw,Cw,Jw,ql,zw,Wl,Uw,Iw,Nw,Lt,Bl,qw,Mn,Ww,Rp,Bw,Zw,wu,Aw,Gw,Vw,Fs,Sw,$s,Pw,Rs,Vg,yn,xs,Fu,Zl,Ow,$u,Dw,Sg,kt,Al,Qw,Ru,Yw,Hw,Gl,Kw,xp,e2,t2,o2,Vl,n2,Sl,s2,a2,r2,Dt,Pl,l2,vn,i2,Lp,d2,c2,xu,p2,h2,u2,Ls,m2,Xs,Pg,kn,Es,Lu,Ol,f2,Xu,g2,Og,Tt,Dl,_2,Eu,b2,M2,Ql,y2,Xp,v2,k2,T2,Yl,w2,Hl,F2,$2,R2,Qt,Kl,x2,Tn,L2,Ep,X2,E2,ju,j2,C2,J2,js,z2,Cs,Dg,wn,Js,Cu,ei,U2,Ju,I2,Qg,wt,ti,N2,Fn,q2,zu,W2,B2,Uu,Z2,A2,G2,oi,V2,jp,S2,P2,O2,ni,D2,si,Q2,Y2,H2,Yt,ai,K2,$n,e1,Cp,t1,o1,Iu,n1,s1,a1,zs,r1,Us,Yg,Rn,Is,Nu,ri,l1,qu,i1,Hg,dt,li,d1,Wu,c1,p1,ii,h1,Jp,u1,m1,f1,di,g1,ci,_1,b1,M1,Ns,y1,Ht,pi,v1,xn,k1,zp,T1,w1,Bu,F1,$1,R1,qs,x1,Ws,Kg,Ln,Bs,Zu,hi,L1,Au,X1,e_,ct,ui,E1,mi,j1,Gu,C1,J1,z1,fi,U1,Up,I1,N1,q1,gi,W1,_i,B1,Z1,A1,Zs,G1,Kt,bi,V1,Xn,S1,Ip,P1,O1,Vu,D1,Q1,Y1,As,H1,Gs,t_,En,Vs,Su,Mi,K1,Pu,e0,o_,pt,yi,t0,vi,o0,Ou,n0,s0,a0,ki,r0,Np,l0,i0,d0,Ti,c0,wi,p0,h0,u0,Ss,m0,Xt,Fi,f0,jn,g0,qp,_0,b0,Du,M0,y0,v0,Ps,k0,Os,T0,Ds,n_,Cn,Qs,Qu,$i,w0,Yu,F0,s_,ht,Ri,$0,Hu,R0,x0,xi,L0,Wp,X0,E0,j0,Li,C0,Xi,J0,z0,U0,Ys,I0,Et,Ei,N0,Jn,q0,Bp,W0,B0,Ku,Z0,A0,G0,Hs,V0,Ks,S0,ea,a_,zn,ta,em,ji,P0,tm,O0,r_,ut,Ci,D0,om,Q0,Y0,Ji,H0,Zp,K0,eF,tF,zi,oF,Ui,nF,sF,aF,oa,rF,eo,Ii,lF,Un,iF,Ap,dF,cF,nm,pF,hF,uF,na,mF,sa,l_,In,aa,sm,Ni,fF,am,gF,i_,mt,qi,_F,rm,bF,MF,Wi,yF,Gp,vF,kF,TF,Bi,wF,Zi,FF,$F,RF,ra,xF,jt,Ai,LF,Nn,XF,Vp,EF,jF,lm,CF,JF,zF,la,UF,ia,IF,da,d_,qn,ca,im,Gi,NF,dm,qF,c_,ft,Vi,WF,Wn,BF,cm,ZF,AF,pm,GF,VF,SF,Si,PF,Sp,OF,DF,QF,Pi,YF,Oi,HF,KF,e$,pa,t$,Ct,Di,o$,Bn,n$,Pp,s$,a$,hm,r$,l$,i$,ha,d$,ua,c$,ma,p_,Zn,fa,um,Qi,p$,mm,h$,h_,tt,Yi,u$,fm,m$,f$,Hi,g$,Op,_$,b$,M$,Ki,y$,ed,v$,k$,T$,gm,w$,F$,bo,_m,td,$$,R$,bm,od,x$,L$,Mm,nd,X$,E$,ym,sd,j$,C$,to,ad,J$,An,z$,vm,U$,I$,km,N$,q$,W$,ga,B$,_a,u_,Gn,ba,Tm,rd,Z$,wm,A$,m_,ot,ld,G$,Fm,V$,S$,id,P$,Dp,O$,D$,Q$,dd,Y$,cd,H$,K$,eR,$m,tR,oR,Mo,Rm,pd,nR,sR,xm,hd,aR,rR,Lm,ud,lR,iR,Xm,md,dR,cR,oo,fd,pR,Vn,hR,Em,uR,mR,jm,fR,gR,_R,Ma,bR,ya,f_,Sn,va,Cm,gd,MR,Jm,yR,g_,nt,_d,vR,bd,kR,zm,TR,wR,FR,Md,$R,Qp,RR,xR,LR,yd,XR,vd,ER,jR,CR,Um,JR,zR,yo,Im,kd,UR,IR,Nm,Td,NR,qR,qm,wd,WR,BR,Wm,Fd,ZR,AR,no,$d,GR,Pn,VR,Bm,SR,PR,Zm,OR,DR,QR,ka,YR,Ta,__,On,wa,Am,Rd,HR,Gm,KR,b_,st,xd,ex,Vm,tx,ox,Ld,nx,Yp,sx,ax,rx,Xd,lx,Ed,ix,dx,cx,Sm,px,hx,vo,Pm,jd,ux,mx,Om,Cd,fx,gx,Dm,Jd,_x,bx,Qm,zd,Mx,yx,so,Ud,vx,Dn,kx,Ym,Tx,wx,Hm,Fx,$x,Rx,Fa,xx,$a,M_,Qn,Ra,Km,Id,Lx,ef,Xx,y_,at,Nd,Ex,tf,jx,Cx,qd,Jx,Hp,zx,Ux,Ix,Wd,Nx,Bd,qx,Wx,Bx,of,Zx,Ax,ko,nf,Zd,Gx,Vx,sf,Ad,Sx,Px,af,Gd,Ox,Dx,rf,Vd,Qx,Yx,ao,Sd,Hx,Yn,Kx,lf,eL,tL,df,oL,nL,sL,xa,aL,La,v_,Hn,Xa,cf,Pd,rL,pf,lL,k_,rt,Od,iL,hf,dL,cL,Dd,pL,Kp,hL,uL,mL,Qd,fL,Yd,gL,_L,bL,uf,ML,yL,To,mf,Hd,vL,kL,ff,Kd,TL,wL,gf,ec,FL,$L,_f,tc,RL,xL,ro,oc,LL,Kn,XL,bf,EL,jL,Mf,CL,JL,zL,Ea,UL,ja,T_,es,Ca,yf,nc,IL,vf,NL,w_,lt,sc,qL,ts,WL,kf,BL,ZL,Tf,AL,GL,VL,ac,SL,eh,PL,OL,DL,rc,QL,lc,YL,HL,KL,wf,eX,tX,wo,Ff,ic,oX,nX,$f,dc,sX,aX,Rf,cc,rX,lX,xf,pc,iX,dX,lo,hc,cX,os,pX,Lf,hX,uX,Xf,mX,fX,gX,Ja,_X,za,F_;return i=new Ne({}),le=new Ne({}),Z=new Ne({}),ee=new bg({props:{pipeline:"text-classification"}}),gr=new bg({props:{pipeline:"token-classification"}}),Tr=new bg({props:{pipeline:"text-generation"}}),Rr=new bg({props:{pipeline:"fill-mask"}}),zr=new bg({props:{pipeline:"question-answering"}}),Or=new Ne({}),Dr=new W({props:{name:"class transformers.XLMRobertaConfig",anchor:"transformers.XLMRobertaConfig",parameters:[{name:"vocab_size",val:" = 30522"},{name:"hidden_size",val:" = 768"},{name:"num_hidden_layers",val:" = 12"},{name:"num_attention_heads",val:" = 12"},{name:"intermediate_size",val:" = 3072"},{name:"hidden_act",val:" = 'gelu'"},{name:"hidden_dropout_prob",val:" = 0.1"},{name:"attention_probs_dropout_prob",val:" = 0.1"},{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:"pad_token_id",val:" = 1"},{name:"bos_token_id",val:" = 0"},{name:"eos_token_id",val:" = 2"},{name:"position_embedding_type",val:" = 'absolute'"},{name:"use_cache",val:" = True"},{name:"classifier_dropout",val:" = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 30522) &#x2014;
Vocabulary size of the XLM-RoBERTa model. Defines the number of different tokens that can be represented by
the <code>inputs_ids</code> passed when calling <a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaModel">XLMRobertaModel</a> or <a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaModel">TFXLMRobertaModel</a>.`,name:"vocab_size"},{anchor:"transformers.XLMRobertaConfig.hidden_size",description:`<strong>hidden_size</strong> (<code>int</code>, <em>optional</em>, defaults to 768) &#x2014;
Dimensionality of the encoder layers and the pooler layer.`,name:"hidden_size"},{anchor:"transformers.XLMRobertaConfig.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.XLMRobertaConfig.num_attention_heads",description:`<strong>num_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of attention heads for each attention layer in the Transformer encoder.`,name:"num_attention_heads"},{anchor:"transformers.XLMRobertaConfig.intermediate_size",description:`<strong>intermediate_size</strong> (<code>int</code>, <em>optional</em>, defaults to 3072) &#x2014;
Dimensionality of the &#x201C;intermediate&#x201D; (often named feed-forward) layer in the Transformer encoder.`,name:"intermediate_size"},{anchor:"transformers.XLMRobertaConfig.hidden_act",description:`<strong>hidden_act</strong> (<code>str</code> or <code>Callable</code>, <em>optional</em>, defaults to <code>&quot;gelu&quot;</code>) &#x2014;
The non-linear activation function (function or string) in the encoder and pooler. If string, <code>&quot;gelu&quot;</code>,
<code>&quot;relu&quot;</code>, <code>&quot;silu&quot;</code> and <code>&quot;gelu_new&quot;</code> are supported.`,name:"hidden_act"},{anchor:"transformers.XLMRobertaConfig.hidden_dropout_prob",description:`<strong>hidden_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout probability for all fully connected layers in the embeddings, encoder, and pooler.`,name:"hidden_dropout_prob"},{anchor:"transformers.XLMRobertaConfig.attention_probs_dropout_prob",description:`<strong>attention_probs_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_probs_dropout_prob"},{anchor:"transformers.XLMRobertaConfig.max_position_embeddings",description:`<strong>max_position_embeddings</strong> (<code>int</code>, <em>optional</em>, defaults to 512) &#x2014;
The maximum sequence length that this model might ever be used with. Typically set this to something large
just in case (e.g., 512 or 1024 or 2048).`,name:"max_position_embeddings"},{anchor:"transformers.XLMRobertaConfig.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/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaModel">XLMRobertaModel</a> or
<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaModel">TFXLMRobertaModel</a>.`,name:"type_vocab_size"},{anchor:"transformers.XLMRobertaConfig.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.XLMRobertaConfig.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.XLMRobertaConfig.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"},{anchor:"transformers.XLMRobertaConfig.is_decoder",description:`<strong>is_decoder</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether the model is used as a decoder or not. If <code>False</code>, the model is used as an encoder.`,name:"is_decoder"},{anchor:"transformers.XLMRobertaConfig.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not the model should return the last key/values attentions (not used by all models). Only
relevant if <code>config.is_decoder=True</code>.`,name:"use_cache"},{anchor:"transformers.XLMRobertaConfig.classifier_dropout",description:`<strong>classifier_dropout</strong> (<code>float</code>, <em>optional</em>) &#x2014;
The dropout ratio for the classification head.`,name:"classifier_dropout"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/configuration_xlm_roberta.py#L45"}}),is=new qe({props:{anchor:"transformers.XLMRobertaConfig.example",$$slots:{default:[JJ]},$$scope:{ctx:L}}}),Yr=new Ne({}),Hr=new W({props:{name:"class transformers.XLMRobertaTokenizer",anchor:"transformers.XLMRobertaTokenizer",parameters:[{name:"vocab_file",val:""},{name:"bos_token",val:" = '<s>'"},{name:"eos_token",val:" = '</s>'"},{name:"sep_token",val:" = '</s>'"},{name:"cls_token",val:" = '<s>'"},{name:"unk_token",val:" = '<unk>'"},{name:"pad_token",val:" = '<pad>'"},{name:"mask_token",val:" = '<mask>'"},{name:"sp_model_kwargs",val:": typing.Union[typing.Dict[str, typing.Any], NoneType] = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaTokenizer.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
Path to the vocabulary file.`,name:"vocab_file"},{anchor:"transformers.XLMRobertaTokenizer.bos_token",description:`<strong>bos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;s&gt;&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.XLMRobertaTokenizer.eos_token",description:`<strong>eos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;/s&gt;&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.XLMRobertaTokenizer.sep_token",description:`<strong>sep_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;/s&gt;&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.XLMRobertaTokenizer.cls_token",description:`<strong>cls_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;s&gt;&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.XLMRobertaTokenizer.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.XLMRobertaTokenizer.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.XLMRobertaTokenizer.mask_token",description:`<strong>mask_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;mask&gt;&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.XLMRobertaTokenizer.additional_special_tokens",description:`<strong>additional_special_tokens</strong> (<code>List[str]</code>, <em>optional</em>, defaults to <code>[&quot;&lt;s&gt;NOTUSED&quot;, &quot;&lt;/s&gt;NOTUSED&quot;]</code>) &#x2014;
Additional special tokens used by the tokenizer.`,name:"additional_special_tokens"},{anchor:"transformers.XLMRobertaTokenizer.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.XLMRobertaTokenizer.sp_model",description:`<strong>sp_model</strong> (<code>SentencePieceProcessor</code>) &#x2014;
The <em>SentencePiece</em> processor that is used for every conversion (string, tokens and IDs).`,name:"sp_model"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py#L63"}}),tl=new W({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.XLMRobertaTokenizer.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaTokenizer.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.XLMRobertaTokenizer.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py#L202",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>
`}}),nl=new W({props:{name:"get_special_tokens_mask",anchor:"transformers.XLMRobertaTokenizer.get_special_tokens_mask",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"},{name:"already_has_special_tokens",val:": bool = False"}],parametersDescription:[{anchor:"transformers.XLMRobertaTokenizer.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.XLMRobertaTokenizer.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.XLMRobertaTokenizer.get_special_tokens_mask.already_has_special_tokens",description:`<strong>already_has_special_tokens</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the token list is already formatted with special tokens for the model.`,name:"already_has_special_tokens"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py#L228",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>
`}}),al=new W({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.XLMRobertaTokenizer.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaTokenizer.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.XLMRobertaTokenizer.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py#L256",returnDescription:`
<p>List of zeros.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),rl=new W({props:{name:"save_vocabulary",anchor:"transformers.XLMRobertaTokenizer.save_vocabulary",parameters:[{name:"save_directory",val:": str"},{name:"filename_prefix",val:": typing.Optional[str] = None"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py#L313"}}),ll=new Ne({}),il=new W({props:{name:"class transformers.XLMRobertaTokenizerFast",anchor:"transformers.XLMRobertaTokenizerFast",parameters:[{name:"vocab_file",val:" = None"},{name:"tokenizer_file",val:" = None"},{name:"bos_token",val:" = '<s>'"},{name:"eos_token",val:" = '</s>'"},{name:"sep_token",val:" = '</s>'"},{name:"cls_token",val:" = '<s>'"},{name:"unk_token",val:" = '<unk>'"},{name:"pad_token",val:" = '<pad>'"},{name:"mask_token",val:" = '<mask>'"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaTokenizerFast.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
Path to the vocabulary file.`,name:"vocab_file"},{anchor:"transformers.XLMRobertaTokenizerFast.bos_token",description:`<strong>bos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;s&gt;&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.XLMRobertaTokenizerFast.eos_token",description:`<strong>eos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;/s&gt;&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.XLMRobertaTokenizerFast.sep_token",description:`<strong>sep_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;/s&gt;&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.XLMRobertaTokenizerFast.cls_token",description:`<strong>cls_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;s&gt;&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.XLMRobertaTokenizerFast.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.XLMRobertaTokenizerFast.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.XLMRobertaTokenizerFast.mask_token",description:`<strong>mask_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&lt;mask&gt;&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.XLMRobertaTokenizerFast.additional_special_tokens",description:`<strong>additional_special_tokens</strong> (<code>List[str]</code>, <em>optional</em>, defaults to <code>[&quot;&lt;s&gt;NOTUSED&quot;, &quot;&lt;/s&gt;NOTUSED&quot;]</code>) &#x2014;
Additional special tokens used by the tokenizer.`,name:"additional_special_tokens"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta_fast.py#L82"}}),pl=new W({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.XLMRobertaTokenizerFast.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaTokenizerFast.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.XLMRobertaTokenizerFast.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta_fast.py#L171",returnDescription:`
<p>List of <a href="../glossary#input-ids">input IDs</a> with the appropriate special tokens.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),ul=new W({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.XLMRobertaTokenizerFast.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaTokenizerFast.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.XLMRobertaTokenizerFast.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/tokenization_xlm_roberta_fast.py#L197",returnDescription:`
<p>List of zeros.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),ml=new Ne({}),fl=new W({props:{name:"class transformers.XLMRobertaModel",anchor:"transformers.XLMRobertaModel",parameters:[{name:"config",val:""},{name:"add_pooling_layer",val:" = True"}],parametersDescription:[{anchor:"transformers.XLMRobertaModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L693"}}),vl=new W({props:{name:"forward",anchor:"transformers.XLMRobertaModel.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"encoder_hidden_states",val:": typing.Optional[torch.Tensor] = None"},{name:"encoder_attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[torch.FloatTensor]] = None"},{name:"use_cache",val:": typing.Optional[bool] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaModel.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.XLMRobertaModel.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.XLMRobertaModel.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.XLMRobertaModel.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.XLMRobertaModel.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.XLMRobertaModel.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.XLMRobertaModel.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.XLMRobertaModel.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.XLMRobertaModel.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.XLMRobertaModel.forward.encoder_hidden_states",description:`<strong>encoder_hidden_states</strong>  (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
the model is configured as a decoder.`,name:"encoder_hidden_states"},{anchor:"transformers.XLMRobertaModel.forward.encoder_attention_mask",description:`<strong>encoder_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 the padding token indices of the encoder input. This mask is used in
the cross-attention if the model is configured as a decoder. 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>`,name:"encoder_attention_mask"},{anchor:"transformers.XLMRobertaModel.forward.past_key_values",description:`<strong>past_key_values</strong> (<code>tuple(tuple(torch.FloatTensor))</code> of length <code>config.n_layers</code> with each tuple having 4 tensors of shape <code>(batch_size, num_heads, sequence_length - 1, embed_size_per_head)</code>) &#x2014;
Contains precomputed key and value hidden states of the attention blocks. Can be used to speed up decoding.</p>
<p>If <code>past_key_values</code> are used, the user can optionally input only the last <code>decoder_input_ids</code> (those that
don&#x2019;t have their past key value states given to this model) of shape <code>(batch_size, 1)</code> instead of all
<code>decoder_input_ids</code> of shape <code>(batch_size, sequence_length)</code>.`,name:"past_key_values"},{anchor:"transformers.XLMRobertaModel.forward.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
If set to <code>True</code>, <code>past_key_values</code> key value states are returned and can be used to speed up decoding (see
<code>past_key_values</code>).`,name:"use_cache"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L736",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>pooler_output</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) after further processing
through the layers used for the auxiliary pretraining task. E.g. for BERT-family of models, this returns
the classification token after processing through a linear layer and a tanh activation function. The linear
layer weights are trained from the next sentence prediction (classification) objective during pretraining.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
<li>
<p><strong>cross_attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> and <code>config.add_cross_attention=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 of the decoder\u2019s cross-attention layer, after the attention softmax, used to compute the
weighted average in the cross-attention heads.</p>
</li>
<li>
<p><strong>past_key_values</strong> (<code>tuple(tuple(torch.FloatTensor))</code>, <em>optional</em>, returned when <code>use_cache=True</code> is passed or when <code>config.use_cache=True</code>) \u2014 Tuple of <code>tuple(torch.FloatTensor)</code> of length <code>config.n_layers</code>, with each tuple having 2 tensors of shape
<code>(batch_size, num_heads, sequence_length, embed_size_per_head)</code>) and optionally if
<code>config.is_encoder_decoder=True</code> 2 additional tensors of shape <code>(batch_size, num_heads, encoder_sequence_length, embed_size_per_head)</code>.</p>
<p>Contains pre-computed hidden-states (key and values in the self-attention blocks and optionally if
<code>config.is_encoder_decoder=True</code> in the cross-attention blocks) that can be used (see <code>past_key_values</code>
input) to speed up sequential decoding.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),gs=new Ue({props:{$$slots:{default:[zJ]},$$scope:{ctx:L}}}),_s=new qe({props:{anchor:"transformers.XLMRobertaModel.forward.example",$$slots:{default:[UJ]},$$scope:{ctx:L}}}),kl=new Ne({}),Tl=new W({props:{name:"class transformers.XLMRobertaForCausalLM",anchor:"transformers.XLMRobertaForCausalLM",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaForCausalLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L879"}}),xl=new W({props:{name:"forward",anchor:"transformers.XLMRobertaForCausalLM.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"encoder_hidden_states",val:": typing.Optional[torch.FloatTensor] = None"},{name:"encoder_attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"past_key_values",val:": typing.Tuple[typing.Tuple[torch.FloatTensor]] = None"},{name:"use_cache",val:": typing.Optional[bool] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaForCausalLM.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.XLMRobertaForCausalLM.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.XLMRobertaForCausalLM.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.XLMRobertaForCausalLM.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.XLMRobertaForCausalLM.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.XLMRobertaForCausalLM.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.XLMRobertaForCausalLM.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.XLMRobertaForCausalLM.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.XLMRobertaForCausalLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.XLMRobertaForCausalLM.forward.encoder_hidden_states",description:`<strong>encoder_hidden_states</strong>  (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
the model is configured as a decoder.`,name:"encoder_hidden_states"},{anchor:"transformers.XLMRobertaForCausalLM.forward.encoder_attention_mask",description:`<strong>encoder_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 the padding token indices of the encoder input. This mask is used in
the cross-attention if the model is configured as a decoder. 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>`,name:"encoder_attention_mask"},{anchor:"transformers.XLMRobertaForCausalLM.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 left-to-right language modeling loss (next word prediction). 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.XLMRobertaForCausalLM.forward.past_key_values",description:`<strong>past_key_values</strong> (<code>tuple(tuple(torch.FloatTensor))</code> of length <code>config.n_layers</code> with each tuple having 4 tensors of shape <code>(batch_size, num_heads, sequence_length - 1, embed_size_per_head)</code>) &#x2014;
Contains precomputed key and value hidden states of the attention blocks. Can be used to speed up decoding.</p>
<p>If <code>past_key_values</code> are used, the user can optionally input only the last <code>decoder_input_ids</code> (those that
don&#x2019;t have their past key value states given to this model) of shape <code>(batch_size, 1)</code> instead of all
<code>decoder_input_ids</code> of shape <code>(batch_size, sequence_length)</code>.`,name:"past_key_values"},{anchor:"transformers.XLMRobertaForCausalLM.forward.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
If set to <code>True</code>, <code>past_key_values</code> key value states are returned and can be used to speed up decoding (see
<code>past_key_values</code>).`,name:"use_cache"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L900",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.CausalLMOutputWithCrossAttentions"
>transformers.modeling_outputs.CausalLMOutputWithCrossAttentions</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</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 Language modeling loss (for next-token prediction).</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
<li>
<p><strong>cross_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>Cross attentions weights after the attention softmax, used to compute the weighted average in the
cross-attention heads.</p>
</li>
<li>
<p><strong>past_key_values</strong> (<code>tuple(tuple(torch.FloatTensor))</code>, <em>optional</em>, returned when <code>use_cache=True</code> is passed or when <code>config.use_cache=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> tuples of length <code>config.n_layers</code>, with each tuple containing the cached key,
value states of the self-attention and the cross-attention layers if model is used in encoder-decoder
setting. Only relevant if <code>config.is_decoder = True</code>.</p>
<p>Contains pre-computed hidden-states (key and values in the attention blocks) that can be used (see
<code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.CausalLMOutputWithCrossAttentions"
>transformers.modeling_outputs.CausalLMOutputWithCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ms=new Ue({props:{$$slots:{default:[IJ]},$$scope:{ctx:L}}}),ys=new qe({props:{anchor:"transformers.XLMRobertaForCausalLM.forward.example",$$slots:{default:[NJ]},$$scope:{ctx:L}}}),Ll=new Ne({}),Xl=new W({props:{name:"class transformers.XLMRobertaForMaskedLM",anchor:"transformers.XLMRobertaForMaskedLM",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1032"}}),zl=new W({props:{name:"forward",anchor:"transformers.XLMRobertaForMaskedLM.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"encoder_hidden_states",val:": typing.Optional[torch.FloatTensor] = None"},{name:"encoder_attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaForMaskedLM.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.XLMRobertaForMaskedLM.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.XLMRobertaForMaskedLM.forward.kwargs",description:`<strong>kwargs</strong> (<code>Dict[str, any]</code>, optional, defaults to <em>{}</em>) &#x2014;
Used to hide legacy arguments that have been deprecated.`,name:"kwargs"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1056",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ks=new Ue({props:{$$slots:{default:[qJ]},$$scope:{ctx:L}}}),Ts=new qe({props:{anchor:"transformers.XLMRobertaForMaskedLM.forward.example",$$slots:{default:[WJ]},$$scope:{ctx:L}}}),Ul=new Ne({}),Il=new W({props:{name:"class transformers.XLMRobertaForSequenceClassification",anchor:"transformers.XLMRobertaForSequenceClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1165"}}),Bl=new W({props:{name:"forward",anchor:"transformers.XLMRobertaForSequenceClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaForSequenceClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.XLMRobertaForSequenceClassification.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.XLMRobertaForSequenceClassification.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.XLMRobertaForSequenceClassification.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.XLMRobertaForSequenceClassification.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.XLMRobertaForSequenceClassification.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.XLMRobertaForSequenceClassification.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.XLMRobertaForSequenceClassification.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.XLMRobertaForSequenceClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.XLMRobertaForSequenceClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1177",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Fs=new Ue({props:{$$slots:{default:[BJ]},$$scope:{ctx:L}}}),$s=new qe({props:{anchor:"transformers.XLMRobertaForSequenceClassification.forward.example",$$slots:{default:[ZJ]},$$scope:{ctx:L}}}),Rs=new qe({props:{anchor:"transformers.XLMRobertaForSequenceClassification.forward.example-2",$$slots:{default:[AJ]},$$scope:{ctx:L}}}),Zl=new Ne({}),Al=new W({props:{name:"class transformers.XLMRobertaForMultipleChoice",anchor:"transformers.XLMRobertaForMultipleChoice",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1265"}}),Pl=new W({props:{name:"forward",anchor:"transformers.XLMRobertaForMultipleChoice.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaForMultipleChoice.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.XLMRobertaForMultipleChoice.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.XLMRobertaForMultipleChoice.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.XLMRobertaForMultipleChoice.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.XLMRobertaForMultipleChoice.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.XLMRobertaForMultipleChoice.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.XLMRobertaForMultipleChoice.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.XLMRobertaForMultipleChoice.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.XLMRobertaForMultipleChoice.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.XLMRobertaForMultipleChoice.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the multiple choice classification loss. Indices should be in <code>[0, ..., num_choices-1]</code> where <code>num_choices</code> is the size of the second dimension of the input tensors. (See
<code>input_ids</code> above)`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1276",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <em>(1,)</em>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ls=new Ue({props:{$$slots:{default:[GJ]},$$scope:{ctx:L}}}),Xs=new qe({props:{anchor:"transformers.XLMRobertaForMultipleChoice.forward.example",$$slots:{default:[VJ]},$$scope:{ctx:L}}}),Ol=new Ne({}),Dl=new W({props:{name:"class transformers.XLMRobertaForTokenClassification",anchor:"transformers.XLMRobertaForTokenClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1360"}}),Kl=new W({props:{name:"forward",anchor:"transformers.XLMRobertaForTokenClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaForTokenClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.XLMRobertaForTokenClassification.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.XLMRobertaForTokenClassification.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.XLMRobertaForTokenClassification.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.XLMRobertaForTokenClassification.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.XLMRobertaForTokenClassification.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.XLMRobertaForTokenClassification.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.XLMRobertaForTokenClassification.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.XLMRobertaForTokenClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.XLMRobertaForTokenClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1375",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),js=new Ue({props:{$$slots:{default:[SJ]},$$scope:{ctx:L}}}),Cs=new qe({props:{anchor:"transformers.XLMRobertaForTokenClassification.forward.example",$$slots:{default:[PJ]},$$scope:{ctx:L}}}),ei=new Ne({}),ti=new W({props:{name:"class transformers.XLMRobertaForQuestionAnswering",anchor:"transformers.XLMRobertaForQuestionAnswering",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.XLMRobertaForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1469"}}),ai=new W({props:{name:"forward",anchor:"transformers.XLMRobertaForQuestionAnswering.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"token_type_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"start_positions",val:": typing.Optional[torch.LongTensor] = None"},{name:"end_positions",val:": typing.Optional[torch.LongTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.XLMRobertaForQuestionAnswering.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.XLMRobertaForQuestionAnswering.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.XLMRobertaForQuestionAnswering.forward.end_positions",description:`<strong>end_positions</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the end of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"end_positions"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_xlm_roberta.py#L1480",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Total span extraction loss is the sum of a Cross-Entropy for the start and end positions.</p>
</li>
<li>
<p><strong>start_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),zs=new Ue({props:{$$slots:{default:[OJ]},$$scope:{ctx:L}}}),Us=new qe({props:{anchor:"transformers.XLMRobertaForQuestionAnswering.forward.example",$$slots:{default:[DJ]},$$scope:{ctx:L}}}),ri=new Ne({}),li=new W({props:{name:"class transformers.TFXLMRobertaModel",anchor:"transformers.TFXLMRobertaModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFXLMRobertaModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L875"}}),Ns=new Ue({props:{$$slots:{default:[QJ]},$$scope:{ctx:L}}}),pi=new W({props:{name:"call",anchor:"transformers.TFXLMRobertaModel.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"encoder_hidden_states",val:": np.ndarray | tf.Tensor | None = None"},{name:"encoder_attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"past_key_values",val:": Optional[Tuple[Tuple[Union[np.ndarray, tf.Tensor]]]] = None"},{name:"use_cache",val:": Optional[bool] = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFXLMRobertaModel.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. Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details. <a href="../glossary#input-ids">What are input
IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFXLMRobertaModel.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>.
<a href="../glossary#attention-mask">What are attention masks?</a></li>
</ul>`,name:"attention_mask"},{anchor:"transformers.TFXLMRobertaModel.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.
<a href="../glossary#token-type-ids">What are token type IDs?</a></li>
</ul>`,name:"token_type_ids"},{anchor:"transformers.TFXLMRobertaModel.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>. <a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFXLMRobertaModel.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.TFXLMRobertaModel.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.TFXLMRobertaModel.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.TFXLMRobertaModel.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.TFXLMRobertaModel.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFXLMRobertaModel.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.TFXLMRobertaModel.call.encoder_hidden_states",description:`<strong>encoder_hidden_states</strong>  (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
the model is configured as a decoder.`,name:"encoder_hidden_states"},{anchor:"transformers.TFXLMRobertaModel.call.encoder_attention_mask",description:`<strong>encoder_attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on the padding token indices of the encoder input. This mask is used in
the cross-attention if the model is configured as a decoder. 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>`,name:"encoder_attention_mask"},{anchor:"transformers.TFXLMRobertaModel.call.past_key_values",description:`<strong>past_key_values</strong> (<code>Tuple[Tuple[tf.Tensor]]</code> of length <code>config.n_layers</code>) &#x2014;
contains precomputed key and value hidden states of the attention blocks. Can be used to speed up decoding.
If <code>past_key_values</code> are used, the user can optionally input only the last <code>decoder_input_ids</code> (those that
don&#x2019;t have their past key value states given to this model) of shape <code>(batch_size, 1)</code> instead of all
<code>decoder_input_ids</code> of shape <code>(batch_size, sequence_length)</code>.`,name:"past_key_values"},{anchor:"transformers.TFXLMRobertaModel.call.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
If set to <code>True</code>, <code>past_key_values</code> key value states are returned and can be used to speed up decoding (see
<code>past_key_values</code>). Set to <code>False</code> during training, <code>True</code> during generation`,name:"use_cache"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L880",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</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>past_key_values</strong> (<code>List[tf.Tensor]</code>, <em>optional</em>, returned when <code>use_cache=True</code> is passed or when <code>config.use_cache=True</code>) \u2014 List of <code>tf.Tensor</code> of length <code>config.n_layers</code>, with each tensor of shape <code>(2, batch_size, num_heads, sequence_length, embed_size_per_head)</code>).</p>
<p>Contains pre-computed hidden-states (key and values in the attention blocks) that can be used (see
<code>past_key_values</code> input) to speed up sequential decoding.</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>
<li>
<p><strong>cross_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 of the decoder\u2019s cross-attention layer, after the attention softmax, used to compute the
weighted average in the cross-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions</a> or <code>tuple(tf.Tensor)</code></p>
`}}),qs=new Ue({props:{$$slots:{default:[YJ]},$$scope:{ctx:L}}}),Ws=new qe({props:{anchor:"transformers.TFXLMRobertaModel.call.example",$$slots:{default:[HJ]},$$scope:{ctx:L}}}),hi=new Ne({}),ui=new W({props:{name:"class transformers.TFXLMRobertaForCausalLM",anchor:"transformers.TFXLMRobertaForCausalLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForCausalLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1081"}}),Zs=new Ue({props:{$$slots:{default:[KJ]},$$scope:{ctx:L}}}),bi=new W({props:{name:"call",anchor:"transformers.TFXLMRobertaForCausalLM.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"encoder_hidden_states",val:": np.ndarray | tf.Tensor | None = None"},{name:"encoder_attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"past_key_values",val:": Optional[Tuple[Tuple[Union[np.ndarray, tf.Tensor]]]] = None"},{name:"use_cache",val:": Optional[bool] = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForCausalLM.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. Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details. <a href="../glossary#input-ids">What are input
IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFXLMRobertaForCausalLM.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>.
<a href="../glossary#attention-mask">What are attention masks?</a></li>
</ul>`,name:"attention_mask"},{anchor:"transformers.TFXLMRobertaForCausalLM.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.
<a href="../glossary#token-type-ids">What are token type IDs?</a></li>
</ul>`,name:"token_type_ids"},{anchor:"transformers.TFXLMRobertaForCausalLM.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>. <a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFXLMRobertaForCausalLM.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.TFXLMRobertaForCausalLM.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.TFXLMRobertaForCausalLM.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.TFXLMRobertaForCausalLM.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.TFXLMRobertaForCausalLM.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFXLMRobertaForCausalLM.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.TFXLMRobertaForCausalLM.call.encoder_hidden_states",description:`<strong>encoder_hidden_states</strong>  (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
the model is configured as a decoder.`,name:"encoder_hidden_states"},{anchor:"transformers.TFXLMRobertaForCausalLM.call.encoder_attention_mask",description:`<strong>encoder_attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on the padding token indices of the encoder input. This mask is used in
the cross-attention if the model is configured as a decoder. 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>`,name:"encoder_attention_mask"},{anchor:"transformers.TFXLMRobertaForCausalLM.call.past_key_values",description:`<strong>past_key_values</strong> (<code>Tuple[Tuple[tf.Tensor]]</code> of length <code>config.n_layers</code>) &#x2014;
contains precomputed key and value hidden states of the attention blocks. Can be used to speed up decoding.
If <code>past_key_values</code> are used, the user can optionally input only the last <code>decoder_input_ids</code> (those that
don&#x2019;t have their past key value states given to this model) of shape <code>(batch_size, 1)</code> instead of all
<code>decoder_input_ids</code> of shape <code>(batch_size, sequence_length)</code>.`,name:"past_key_values"},{anchor:"transformers.TFXLMRobertaForCausalLM.call.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
If set to <code>True</code>, <code>past_key_values</code> key value states are returned and can be used to speed up decoding (see
<code>past_key_values</code>). Set to <code>False</code> during training, <code>True</code> during generation`,name:"use_cache"},{anchor:"transformers.TFXLMRobertaForCausalLM.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> or <code>np.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the cross entropy classification loss. Indices should be in <code>[0, ..., config.vocab_size - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1114",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFCausalLMOutputWithCrossAttentions"
>transformers.modeling_tf_outputs.TFCausalLMOutputWithCrossAttentions</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</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 Language modeling loss (for next-token prediction).</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>
<li>
<p><strong>cross_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 of the decoder\u2019s cross-attention layer, after the attention softmax, used to compute the
weighted average in the cross-attention heads.</p>
</li>
<li>
<p><strong>past_key_values</strong> (<code>List[tf.Tensor]</code>, <em>optional</em>, returned when <code>use_cache=True</code> is passed or when <code>config.use_cache=True</code>) \u2014 List of <code>tf.Tensor</code> of length <code>config.n_layers</code>, with each tensor of shape <code>(2, batch_size, num_heads, sequence_length, embed_size_per_head)</code>).</p>
<p>Contains pre-computed hidden-states (key and values in the attention blocks) that can be used (see
<code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFCausalLMOutputWithCrossAttentions"
>transformers.modeling_tf_outputs.TFCausalLMOutputWithCrossAttentions</a> or <code>tuple(tf.Tensor)</code></p>
`}}),As=new Ue({props:{$$slots:{default:[ez]},$$scope:{ctx:L}}}),Gs=new qe({props:{anchor:"transformers.TFXLMRobertaForCausalLM.call.example",$$slots:{default:[tz]},$$scope:{ctx:L}}}),Mi=new Ne({}),yi=new W({props:{name:"class transformers.TFXLMRobertaForMaskedLM",anchor:"transformers.TFXLMRobertaForMaskedLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L999"}}),Ss=new Ue({props:{$$slots:{default:[oz]},$$scope:{ctx:L}}}),Fi=new W({props:{name:"call",anchor:"transformers.TFXLMRobertaForMaskedLM.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForMaskedLM.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. Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details. <a href="../glossary#input-ids">What are input
IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFXLMRobertaForMaskedLM.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>.
<a href="../glossary#attention-mask">What are attention masks?</a></li>
</ul>`,name:"attention_mask"},{anchor:"transformers.TFXLMRobertaForMaskedLM.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.
<a href="../glossary#token-type-ids">What are token type IDs?</a></li>
</ul>`,name:"token_type_ids"},{anchor:"transformers.TFXLMRobertaForMaskedLM.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>. <a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFXLMRobertaForMaskedLM.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.TFXLMRobertaForMaskedLM.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.TFXLMRobertaForMaskedLM.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.TFXLMRobertaForMaskedLM.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.TFXLMRobertaForMaskedLM.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFXLMRobertaForMaskedLM.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.TFXLMRobertaForMaskedLM.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the masked language modeling loss. Indices should be in <code>[-100, 0, ..., config.vocab_size]</code> (see <code>input_ids</code> docstring) Tokens with indices set to <code>-100</code> are ignored (masked), the
loss is only computed for the tokens with labels in <code>[0, ..., config.vocab_size]</code>`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1016",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of non-masked labels, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Ps=new Ue({props:{$$slots:{default:[nz]},$$scope:{ctx:L}}}),Os=new qe({props:{anchor:"transformers.TFXLMRobertaForMaskedLM.call.example",$$slots:{default:[sz]},$$scope:{ctx:L}}}),Ds=new qe({props:{anchor:"transformers.TFXLMRobertaForMaskedLM.call.example-2",$$slots:{default:[az]},$$scope:{ctx:L}}}),$i=new Ne({}),Ri=new W({props:{name:"class transformers.TFXLMRobertaForSequenceClassification",anchor:"transformers.TFXLMRobertaForSequenceClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1240"}}),Ys=new Ue({props:{$$slots:{default:[rz]},$$scope:{ctx:L}}}),Ei=new W({props:{name:"call",anchor:"transformers.TFXLMRobertaForSequenceClassification.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForSequenceClassification.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. Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details. <a href="../glossary#input-ids">What are input
IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFXLMRobertaForSequenceClassification.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>.
<a href="../glossary#attention-mask">What are attention masks?</a></li>
</ul>`,name:"attention_mask"},{anchor:"transformers.TFXLMRobertaForSequenceClassification.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.
<a href="../glossary#token-type-ids">What are token type IDs?</a></li>
</ul>`,name:"token_type_ids"},{anchor:"transformers.TFXLMRobertaForSequenceClassification.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>. <a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFXLMRobertaForSequenceClassification.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.TFXLMRobertaForSequenceClassification.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.TFXLMRobertaForSequenceClassification.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.TFXLMRobertaForSequenceClassification.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.TFXLMRobertaForSequenceClassification.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFXLMRobertaForSequenceClassification.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.TFXLMRobertaForSequenceClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1251",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, )</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Hs=new Ue({props:{$$slots:{default:[lz]},$$scope:{ctx:L}}}),Ks=new qe({props:{anchor:"transformers.TFXLMRobertaForSequenceClassification.call.example",$$slots:{default:[iz]},$$scope:{ctx:L}}}),ea=new qe({props:{anchor:"transformers.TFXLMRobertaForSequenceClassification.call.example-2",$$slots:{default:[dz]},$$scope:{ctx:L}}}),ji=new Ne({}),Ci=new W({props:{name:"class transformers.TFXLMRobertaForMultipleChoice",anchor:"transformers.TFXLMRobertaForMultipleChoice",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1317"}}),oa=new Ue({props:{$$slots:{default:[cz]},$$scope:{ctx:L}}}),Ii=new W({props:{name:"call",anchor:"transformers.TFXLMRobertaForMultipleChoice.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForMultipleChoice.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. Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details. <a href="../glossary#input-ids">What are input
IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFXLMRobertaForMultipleChoice.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>.
<a href="../glossary#attention-mask">What are attention masks?</a></li>
</ul>`,name:"attention_mask"},{anchor:"transformers.TFXLMRobertaForMultipleChoice.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.
<a href="../glossary#token-type-ids">What are token type IDs?</a></li>
</ul>`,name:"token_type_ids"},{anchor:"transformers.TFXLMRobertaForMultipleChoice.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>. <a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFXLMRobertaForMultipleChoice.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.TFXLMRobertaForMultipleChoice.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.TFXLMRobertaForMultipleChoice.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.TFXLMRobertaForMultipleChoice.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.TFXLMRobertaForMultipleChoice.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFXLMRobertaForMultipleChoice.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.TFXLMRobertaForMultipleChoice.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the multiple choice classification loss. Indices should be in <code>[0, ..., num_choices]</code>
where <code>num_choices</code> is the size of the second dimension of the input tensors. (See <code>input_ids</code> above)`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1331",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <em>(batch_size, )</em>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),na=new Ue({props:{$$slots:{default:[pz]},$$scope:{ctx:L}}}),sa=new qe({props:{anchor:"transformers.TFXLMRobertaForMultipleChoice.call.example",$$slots:{default:[hz]},$$scope:{ctx:L}}}),Ni=new Ne({}),qi=new W({props:{name:"class transformers.TFXLMRobertaForTokenClassification",anchor:"transformers.TFXLMRobertaForTokenClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1410"}}),ra=new Ue({props:{$$slots:{default:[uz]},$$scope:{ctx:L}}}),Ai=new W({props:{name:"call",anchor:"transformers.TFXLMRobertaForTokenClassification.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"labels",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForTokenClassification.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. Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details. <a href="../glossary#input-ids">What are input
IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFXLMRobertaForTokenClassification.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>.
<a href="../glossary#attention-mask">What are attention masks?</a></li>
</ul>`,name:"attention_mask"},{anchor:"transformers.TFXLMRobertaForTokenClassification.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.
<a href="../glossary#token-type-ids">What are token type IDs?</a></li>
</ul>`,name:"token_type_ids"},{anchor:"transformers.TFXLMRobertaForTokenClassification.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>. <a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFXLMRobertaForTokenClassification.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.TFXLMRobertaForTokenClassification.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.TFXLMRobertaForTokenClassification.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.TFXLMRobertaForTokenClassification.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.TFXLMRobertaForTokenClassification.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFXLMRobertaForTokenClassification.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.TFXLMRobertaForTokenClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1428",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of unmasked labels, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),la=new Ue({props:{$$slots:{default:[mz]},$$scope:{ctx:L}}}),ia=new qe({props:{anchor:"transformers.TFXLMRobertaForTokenClassification.call.example",$$slots:{default:[fz]},$$scope:{ctx:L}}}),da=new qe({props:{anchor:"transformers.TFXLMRobertaForTokenClassification.call.example-2",$$slots:{default:[gz]},$$scope:{ctx:L}}}),Gi=new Ne({}),Vi=new W({props:{name:"class transformers.TFXLMRobertaForQuestionAnswering",anchor:"transformers.TFXLMRobertaForQuestionAnswering",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1494"}}),pa=new Ue({props:{$$slots:{default:[_z]},$$scope:{ctx:L}}}),Di=new W({props:{name:"call",anchor:"transformers.TFXLMRobertaForQuestionAnswering.call",parameters:[{name:"input_ids",val:": TFModelInputType | None = None"},{name:"attention_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"token_type_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"position_ids",val:": np.ndarray | tf.Tensor | None = None"},{name:"head_mask",val:": np.ndarray | tf.Tensor | None = None"},{name:"inputs_embeds",val:": np.ndarray | tf.Tensor | None = None"},{name:"output_attentions",val:": Optional[bool] = None"},{name:"output_hidden_states",val:": Optional[bool] = None"},{name:"return_dict",val:": Optional[bool] = None"},{name:"start_positions",val:": np.ndarray | tf.Tensor | None = None"},{name:"end_positions",val:": np.ndarray | tf.Tensor | None = None"},{name:"training",val:": Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFXLMRobertaForQuestionAnswering.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. Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details. <a href="../glossary#input-ids">What are input
IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFXLMRobertaForQuestionAnswering.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>.
<a href="../glossary#attention-mask">What are attention masks?</a></li>
</ul>`,name:"attention_mask"},{anchor:"transformers.TFXLMRobertaForQuestionAnswering.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.
<a href="../glossary#token-type-ids">What are token type IDs?</a></li>
</ul>`,name:"token_type_ids"},{anchor:"transformers.TFXLMRobertaForQuestionAnswering.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>. <a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFXLMRobertaForQuestionAnswering.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.TFXLMRobertaForQuestionAnswering.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.TFXLMRobertaForQuestionAnswering.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.TFXLMRobertaForQuestionAnswering.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.TFXLMRobertaForQuestionAnswering.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFXLMRobertaForQuestionAnswering.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.TFXLMRobertaForQuestionAnswering.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.TFXLMRobertaForQuestionAnswering.call.end_positions",description:`<strong>end_positions</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the end of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"end_positions"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_tf_xlm_roberta.py#L1507",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, )</code>, <em>optional</em>, returned when <code>start_positions</code> and <code>end_positions</code> are provided) \u2014 Total span extraction loss is the sum of a Cross-Entropy for the start and end positions.</p>
</li>
<li>
<p><strong>start_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),ha=new Ue({props:{$$slots:{default:[bz]},$$scope:{ctx:L}}}),ua=new qe({props:{anchor:"transformers.TFXLMRobertaForQuestionAnswering.call.example",$$slots:{default:[Mz]},$$scope:{ctx:L}}}),ma=new qe({props:{anchor:"transformers.TFXLMRobertaForQuestionAnswering.call.example-2",$$slots:{default:[yz]},$$scope:{ctx:L}}}),Qi=new Ne({}),Yi=new W({props:{name:"class transformers.FlaxXLMRobertaModel",anchor:"transformers.FlaxXLMRobertaModel",parameters:[{name:"config",val:": XLMRobertaConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"gradient_checkpointing",val:": bool = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L1003"}}),ad=new W({props:{name:"__call__",anchor:"transformers.FlaxXLMRobertaModel.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"encoder_hidden_states",val:" = None"},{name:"encoder_attention_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"past_key_values",val:": dict = None"}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaModel.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxXLMRobertaModel.__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.FlaxXLMRobertaModel.__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.FlaxXLMRobertaModel.__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.FlaxXLMRobertaModel.__call__.head_mask",description:`<strong>head_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <code>optional) -- Mask to nullify selected heads of the attention modules. Mask values selected in </code>[0, 1]\`:</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.FlaxXLMRobertaModel.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L829",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</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/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ga=new Ue({props:{$$slots:{default:[vz]},$$scope:{ctx:L}}}),_a=new qe({props:{anchor:"transformers.FlaxXLMRobertaModel.__call__.example",$$slots:{default:[kz]},$$scope:{ctx:L}}}),rd=new Ne({}),ld=new W({props:{name:"class transformers.FlaxXLMRobertaForCausalLM",anchor:"transformers.FlaxXLMRobertaForCausalLM",parameters:[{name:"config",val:": XLMRobertaConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"gradient_checkpointing",val:": bool = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForCausalLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L1469"}}),fd=new W({props:{name:"__call__",anchor:"transformers.FlaxXLMRobertaForCausalLM.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"encoder_hidden_states",val:" = None"},{name:"encoder_attention_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"past_key_values",val:": dict = None"}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForCausalLM.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxXLMRobertaForCausalLM.__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.FlaxXLMRobertaForCausalLM.__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.FlaxXLMRobertaForCausalLM.__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.FlaxXLMRobertaForCausalLM.__call__.head_mask",description:`<strong>head_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <code>optional) -- Mask to nullify selected heads of the attention modules. Mask values selected in </code>[0, 1]\`:</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.FlaxXLMRobertaForCausalLM.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L829",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions"
>transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</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>
<li>
<p><strong>cross_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>Cross attentions weights after the attention softmax, used to compute the weighted average in the
cross-attention heads.</p>
</li>
<li>
<p><strong>past_key_values</strong> (<code>tuple(tuple(jnp.ndarray))</code>, <em>optional</em>, returned when <code>use_cache=True</code> is passed or when <code>config.use_cache=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> tuples of length <code>config.n_layers</code>, with each tuple containing the cached key, value
states of the self-attention and the cross-attention layers if model is used in encoder-decoder setting.
Only relevant if <code>config.is_decoder = True</code>.</p>
<p>Contains pre-computed hidden-states (key and values in the attention blocks) that can be used (see
<code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions"
>transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ma=new Ue({props:{$$slots:{default:[Tz]},$$scope:{ctx:L}}}),ya=new qe({props:{anchor:"transformers.FlaxXLMRobertaForCausalLM.__call__.example",$$slots:{default:[wz]},$$scope:{ctx:L}}}),gd=new Ne({}),_d=new W({props:{name:"class transformers.FlaxXLMRobertaForMaskedLM",anchor:"transformers.FlaxXLMRobertaForMaskedLM",parameters:[{name:"config",val:": XLMRobertaConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"gradient_checkpointing",val:": bool = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L1070"}}),$d=new W({props:{name:"__call__",anchor:"transformers.FlaxXLMRobertaForMaskedLM.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"encoder_hidden_states",val:" = None"},{name:"encoder_attention_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"past_key_values",val:": dict = None"}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForMaskedLM.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxXLMRobertaForMaskedLM.__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.FlaxXLMRobertaForMaskedLM.__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.FlaxXLMRobertaForMaskedLM.__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.FlaxXLMRobertaForMaskedLM.__call__.head_mask",description:`<strong>head_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <code>optional) -- Mask to nullify selected heads of the attention modules. Mask values selected in </code>[0, 1]\`:</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.FlaxXLMRobertaForMaskedLM.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L829",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/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/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</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/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ka=new Ue({props:{$$slots:{default:[Fz]},$$scope:{ctx:L}}}),Ta=new qe({props:{anchor:"transformers.FlaxXLMRobertaForMaskedLM.__call__.example",$$slots:{default:[$z]},$$scope:{ctx:L}}}),Rd=new Ne({}),xd=new W({props:{name:"class transformers.FlaxXLMRobertaForSequenceClassification",anchor:"transformers.FlaxXLMRobertaForSequenceClassification",parameters:[{name:"config",val:": XLMRobertaConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"gradient_checkpointing",val:": bool = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L1143"}}),Ud=new W({props:{name:"__call__",anchor:"transformers.FlaxXLMRobertaForSequenceClassification.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"encoder_hidden_states",val:" = None"},{name:"encoder_attention_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"past_key_values",val:": dict = None"}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForSequenceClassification.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxXLMRobertaForSequenceClassification.__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.FlaxXLMRobertaForSequenceClassification.__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.FlaxXLMRobertaForSequenceClassification.__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.FlaxXLMRobertaForSequenceClassification.__call__.head_mask",description:`<strong>head_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <code>optional) -- Mask to nullify selected heads of the attention modules. Mask values selected in </code>[0, 1]\`:</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.FlaxXLMRobertaForSequenceClassification.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L829",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Fa=new Ue({props:{$$slots:{default:[Rz]},$$scope:{ctx:L}}}),$a=new qe({props:{anchor:"transformers.FlaxXLMRobertaForSequenceClassification.__call__.example",$$slots:{default:[xz]},$$scope:{ctx:L}}}),Id=new Ne({}),Nd=new W({props:{name:"class transformers.FlaxXLMRobertaForMultipleChoice",anchor:"transformers.FlaxXLMRobertaForMultipleChoice",parameters:[{name:"config",val:": XLMRobertaConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"gradient_checkpointing",val:": bool = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L1224"}}),Sd=new W({props:{name:"__call__",anchor:"transformers.FlaxXLMRobertaForMultipleChoice.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"encoder_hidden_states",val:" = None"},{name:"encoder_attention_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"past_key_values",val:": dict = None"}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForMultipleChoice.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxXLMRobertaForMultipleChoice.__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.FlaxXLMRobertaForMultipleChoice.__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.FlaxXLMRobertaForMultipleChoice.__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.FlaxXLMRobertaForMultipleChoice.__call__.head_mask",description:`<strong>head_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <code>optional) -- Mask to nullify selected heads of the attention modules. Mask values selected in </code>[0, 1]\`:</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.FlaxXLMRobertaForMultipleChoice.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L829",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),xa=new Ue({props:{$$slots:{default:[Lz]},$$scope:{ctx:L}}}),La=new qe({props:{anchor:"transformers.FlaxXLMRobertaForMultipleChoice.__call__.example",$$slots:{default:[Xz]},$$scope:{ctx:L}}}),Pd=new Ne({}),Od=new W({props:{name:"class transformers.FlaxXLMRobertaForTokenClassification",anchor:"transformers.FlaxXLMRobertaForTokenClassification",parameters:[{name:"config",val:": XLMRobertaConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"gradient_checkpointing",val:": bool = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L1306"}}),oc=new W({props:{name:"__call__",anchor:"transformers.FlaxXLMRobertaForTokenClassification.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"encoder_hidden_states",val:" = None"},{name:"encoder_attention_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"past_key_values",val:": dict = None"}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForTokenClassification.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxXLMRobertaForTokenClassification.__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.FlaxXLMRobertaForTokenClassification.__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.FlaxXLMRobertaForTokenClassification.__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.FlaxXLMRobertaForTokenClassification.__call__.head_mask",description:`<strong>head_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <code>optional) -- Mask to nullify selected heads of the attention modules. Mask values selected in </code>[0, 1]\`:</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.FlaxXLMRobertaForTokenClassification.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L829",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ea=new Ue({props:{$$slots:{default:[Ez]},$$scope:{ctx:L}}}),ja=new qe({props:{anchor:"transformers.FlaxXLMRobertaForTokenClassification.__call__.example",$$slots:{default:[jz]},$$scope:{ctx:L}}}),nc=new Ne({}),sc=new W({props:{name:"class transformers.FlaxXLMRobertaForQuestionAnswering",anchor:"transformers.FlaxXLMRobertaForQuestionAnswering",parameters:[{name:"config",val:": XLMRobertaConfig"},{name:"input_shape",val:": typing.Tuple = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"gradient_checkpointing",val:": bool = False"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig">XLMRobertaConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L1383"}}),hc=new W({props:{name:"__call__",anchor:"transformers.FlaxXLMRobertaForQuestionAnswering.__call__",parameters:[{name:"input_ids",val:""},{name:"attention_mask",val:" = None"},{name:"token_type_ids",val:" = None"},{name:"position_ids",val:" = None"},{name:"head_mask",val:" = None"},{name:"encoder_hidden_states",val:" = None"},{name:"encoder_attention_mask",val:" = None"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"},{name:"train",val:": bool = False"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"past_key_values",val:": dict = None"}],parametersDescription:[{anchor:"transformers.FlaxXLMRobertaForQuestionAnswering.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.32.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.32.0/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxXLMRobertaForQuestionAnswering.__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.FlaxXLMRobertaForQuestionAnswering.__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.FlaxXLMRobertaForQuestionAnswering.__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.FlaxXLMRobertaForQuestionAnswering.__call__.head_mask",description:`<strong>head_mask</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <code>optional) -- Mask to nullify selected heads of the attention modules. Mask values selected in </code>[0, 1]\`:</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.FlaxXLMRobertaForQuestionAnswering.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.32.0/src/transformers/models/xlm_roberta/modeling_flax_xlm_roberta.py#L829",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaConfig"
>XLMRobertaConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>start_logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.32.0/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ja=new Ue({props:{$$slots:{default:[Cz]},$$scope:{ctx:L}}}),za=new qe({props:{anchor:"transformers.FlaxXLMRobertaForQuestionAnswering.__call__.example",$$slots:{default:[Jz]},$$scope:{ctx:L}}}),{c(){d=s("meta"),M=p(),m=s("h1"),f=s("a"),b=s("span"),v(i.$$.fragment),u=p(),X=s("span"),Me=o("XLM-RoBERTa"),fe=p(),q=s("div"),ce=s("a"),te=s("img"),ye=p(),A=s("a"),pe=s("img"),O=p(),ae=s("h2"),re=s("a"),G=s("span"),v(le.$$.fragment),ve=p(),V=s("span"),ke=o("Overview"),ge=p(),B=s("p"),Te=o("The XLM-RoBERTa model was proposed in "),ie=s("a"),oe=o("Unsupervised Cross-lingual Representation Learning at Scale"),j=o(` by Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume
Wenzek, Francisco Guzm\xE1n, Edouard Grave, Myle Ott, Luke Zettlemoyer and Veselin Stoyanov. It is based on Facebook\u2019s
RoBERTa model released in 2019. It is a large multi-lingual language model, trained on 2.5TB of filtered CommonCrawl
data.`),z=p(),he=s("p"),Q=o("The abstract from the paper is the following:"),_e=p(),ue=s("p"),S=s("em"),we=o(`This paper shows that pretraining multilingual language models at scale leads to significant performance gains for a
wide range of cross-lingual transfer tasks. We train a Transformer-based masked language model on one hundred
languages, using more than two terabytes of filtered CommonCrawl data. Our model, dubbed XLM-R, significantly
outperforms multilingual BERT (mBERT) on a variety of cross-lingual benchmarks, including +13.8% average accuracy on
XNLI, +12.3% average F1 score on MLQA, and +2.1% average F1 score on NER. XLM-R performs particularly well on
low-resource languages, improving 11.8% in XNLI accuracy for Swahili and 9.2% for Urdu over the previous XLM model. We
also present a detailed empirical evaluation of the key factors that are required to achieve these gains, including the
trade-offs between (1) positive transfer and capacity dilution and (2) the performance of high and low resource
languages at scale. Finally, we show, for the first time, the possibility of multilingual modeling without sacrificing
per-language performance; XLM-Ris very competitive with strong monolingual models on the GLUE and XNLI benchmarks. We
will make XLM-R code, data, and models publicly available.`),be=p(),J=s("p"),Fe=o("Tips:"),D=p(),ne=s("ul"),de=s("li"),Y=o(`XLM-RoBERTa is a multilingual model trained on 100 different languages. Unlike some XLM multilingual models, it does
not require `),me=s("code"),$e=o("lang"),N=o(` tensors to understand which language is used, and should be able to determine the correct
language from the input ids.`),Re=p(),P=s("li"),xe=o("Uses RoBERTa tricks on the XLM approach, but does not use the translation language modeling objective. It only uses masked language modeling on sentences coming from one language."),se=p(),C=s("li"),Le=o("This implementation is the same as RoBERTa. Refer to the "),U=s("a"),Xe=o("documentation of RoBERTa"),Ee=o(` for usage examples
as well as the information relative to the inputs and outputs.`),y=p(),x=s("p"),Pe=o("This model was contributed by "),K=s("a"),Oe=o("stefan-it"),De=o(". The original code can be found "),E=s("a"),Qe=o("here"),Ye=o("."),Ae=p(),Je=s("h2"),ze=s("a"),I=s("span"),v(Z.$$.fragment),He=p(),Ze=s("span"),H=o("Resources"),Ge=p(),Ie=s("p"),je=o("A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with XLM-RoBERTa. If you\u2019re interested in submitting a resource to be included here, please feel free to open a Pull Request and we\u2019ll review it! The resource should ideally demonstrate something new instead of duplicating an existing resource."),Ve=p(),v(ee.$$.fragment),Se=p(),gt=s("ul"),Lc=s("li"),Kb=o("A blog post on how to "),ir=s("a"),eM=o("finetune XLM RoBERTa for multiclass classification with Habana Gaudi on AWS"),tM=p(),Fo=s("li"),Xc=s("a"),oM=o("XLMRobertaForSequenceClassification"),nM=o(" is supported by this "),dr=s("a"),sM=o("example script"),aM=o(" and "),cr=s("a"),rM=o("notebook"),lM=o("."),iM=p(),$o=s("li"),Ec=s("a"),dM=o("TFXLMRobertaForSequenceClassification"),cM=o(" is supported by this "),pr=s("a"),pM=o("example script"),hM=o(" and "),hr=s("a"),uM=o("notebook"),mM=o("."),fM=p(),Ro=s("li"),jc=s("a"),gM=o("FlaxXLMRobertaForSequenceClassification"),_M=o(" is supported by this "),ur=s("a"),bM=o("example script"),MM=o(" and "),mr=s("a"),yM=o("notebook"),vM=o("."),kM=p(),Cc=s("li"),fr=s("a"),TM=o("Text classification"),wM=o(" chapter of the \u{1F917} Hugging Face Task Guides."),FM=p(),jh=s("li"),Jc=s("a"),$M=o("Text classification task guide"),Mg=p(),v(gr.$$.fragment),yg=p(),$t=s("ul"),xo=s("li"),zc=s("a"),RM=o("XLMRobertaForTokenClassification"),xM=o(" is supported by this "),_r=s("a"),LM=o("example script"),XM=o(" and "),br=s("a"),EM=o("notebook"),jM=o("."),CM=p(),Lo=s("li"),Uc=s("a"),JM=o("TFXLMRobertaForTokenClassification"),zM=o(" is supported by this "),Mr=s("a"),UM=o("example script"),IM=o(" and "),yr=s("a"),NM=o("notebook"),qM=o("."),WM=p(),as=s("li"),Ic=s("a"),BM=o("FlaxXLMRobertaForTokenClassification"),ZM=o(" is supported by this "),vr=s("a"),AM=o("example script"),GM=o("."),VM=p(),Nc=s("li"),kr=s("a"),SM=o("Token classification"),PM=o(" chapter of the \u{1F917} Hugging Face Course."),OM=p(),Ch=s("li"),qc=s("a"),DM=o("Token classification task guide"),vg=p(),v(Tr.$$.fragment),kg=p(),Xo=s("ul"),Eo=s("li"),Wc=s("a"),QM=o("XLMRobertaForCausalLM"),YM=o(" is supported by this "),wr=s("a"),HM=o("example script"),KM=o(" and "),Fr=s("a"),ey=o("notebook"),ty=o("."),oy=p(),Bc=s("li"),$r=s("a"),ny=o("Causal language modeling"),sy=o(" chapter of the \u{1F917} Hugging Face Task Guides."),ay=p(),Jh=s("li"),Zc=s("a"),ry=o("Causal language modeling task guide"),Tg=p(),v(Rr.$$.fragment),wg=p(),Rt=s("ul"),jo=s("li"),Ac=s("a"),ly=o("XLMRobertaForMaskedLM"),iy=o(" is supported by this "),xr=s("a"),dy=o("example script"),cy=o(" and "),Lr=s("a"),py=o("notebook"),hy=o("."),uy=p(),Co=s("li"),Gc=s("a"),my=o("TFXLMRobertaForMaskedLM"),fy=o(" is supported by this "),Xr=s("a"),gy=o("example script"),_y=o(" and "),Er=s("a"),by=o("notebook"),My=o("."),yy=p(),Jo=s("li"),Vc=s("a"),vy=o("FlaxXLMRobertaForMaskedLM"),ky=o(" is supported by this "),jr=s("a"),Ty=o("example script"),wy=o(" and "),Cr=s("a"),Fy=o("notebook"),$y=o("."),Ry=p(),Sc=s("li"),Jr=s("a"),xy=o("Masked language modeling"),Ly=o(" chapter of the \u{1F917} Hugging Face Course."),Xy=p(),zh=s("li"),Pc=s("a"),Ey=o("Masked language modeling"),Fg=p(),v(zr.$$.fragment),$g=p(),xt=s("ul"),zo=s("li"),Oc=s("a"),jy=o("XLMRobertaForQuestionAnswering"),Cy=o(" is supported by this "),Ur=s("a"),Jy=o("example script"),zy=o(" and "),Ir=s("a"),Uy=o("notebook"),Iy=o("."),Ny=p(),Uo=s("li"),Dc=s("a"),qy=o("TFXLMRobertaForQuestionAnswering"),Wy=o(" is supported by this "),Nr=s("a"),By=o("example script"),Zy=o(" and "),qr=s("a"),Ay=o("notebook"),Gy=o("."),Vy=p(),rs=s("li"),Qc=s("a"),Sy=o("FlaxXLMRobertaForQuestionAnswering"),Py=o(" is supported by this "),Wr=s("a"),Oy=o("example script"),Dy=o("."),Qy=p(),Yc=s("li"),Br=s("a"),Yy=o("Question answering"),Hy=o(" chapter of the \u{1F917} Hugging Face Course."),Ky=p(),Uh=s("li"),Hc=s("a"),ev=o("Question answering task guide"),Rg=p(),Kc=s("p"),Ih=s("strong"),tv=o("Multiple choice"),xg=p(),Io=s("ul"),No=s("li"),ep=s("a"),ov=o("XLMRobertaForMultipleChoice"),nv=o(" is supported by this "),Zr=s("a"),sv=o("example script"),av=o(" and "),Ar=s("a"),rv=o("notebook"),lv=o("."),iv=p(),qo=s("li"),tp=s("a"),dv=o("TFXLMRobertaForMultipleChoice"),cv=o(" is supported by this "),Gr=s("a"),pv=o("example script"),hv=o(" and "),Vr=s("a"),uv=o("notebook"),mv=o("."),fv=p(),Nh=s("li"),op=s("a"),gv=o("Multiple choice task guide"),Lg=p(),np=s("p"),_v=o("\u{1F680} Deploy"),Xg=p(),sp=s("ul"),Sr=s("li"),bv=o("A blog post on how to "),Pr=s("a"),Mv=o("Deploy Serverless XLM RoBERTa on AWS Lambda"),yv=o("."),Eg=p(),ln=s("h2"),ls=s("a"),qh=s("span"),v(Or.$$.fragment),vv=p(),Wh=s("span"),kv=o("XLMRobertaConfig"),jg=p(),At=s("div"),v(Dr.$$.fragment),Tv=p(),go=s("p"),wv=o("This is the configuration class to store the configuration of a "),ap=s("a"),Fv=o("XLMRobertaModel"),$v=o(" or a "),rp=s("a"),Rv=o("TFXLMRobertaModel"),xv=o(`. It
is used to instantiate a XLM-RoBERTa 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 XLMRoBERTa
`),Qr=s("a"),Lv=o("xlm-roberta-base"),Xv=o(" architecture."),Ev=p(),dn=s("p"),jv=o("Configuration objects inherit from "),lp=s("a"),Cv=o("PretrainedConfig"),Jv=o(` and can be used to control the model outputs. Read the
documentation from `),ip=s("a"),zv=o("PretrainedConfig"),Uv=o(" for more information."),Iv=p(),v(is.$$.fragment),Cg=p(),cn=s("h2"),ds=s("a"),Bh=s("span"),v(Yr.$$.fragment),Nv=p(),Zh=s("span"),qv=o("XLMRobertaTokenizer"),Jg=p(),et=s("div"),v(Hr.$$.fragment),Wv=p(),_o=s("p"),Bv=o("Adapted from "),dp=s("a"),Zv=o("RobertaTokenizer"),Av=o(" and "),cp=s("a"),Gv=o("XLNetTokenizer"),Vv=o(`. Based on
`),Kr=s("a"),Sv=o("SentencePiece"),Pv=o("."),Ov=p(),el=s("p"),Dv=o("This tokenizer inherits from "),pp=s("a"),Qv=o("PreTrainedTokenizer"),Yv=o(` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),Hv=p(),Wo=s("div"),v(tl.$$.fragment),Kv=p(),Ah=s("p"),ek=o(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An XLM-RoBERTa sequence has the following format:`),tk=p(),ol=s("ul"),hp=s("li"),ok=o("single sequence: "),Gh=s("code"),nk=o("<s> X </s>"),sk=p(),up=s("li"),ak=o("pair of sequences: "),Vh=s("code"),rk=o("<s> A </s></s> B </s>"),lk=p(),cs=s("div"),v(nl.$$.fragment),ik=p(),sl=s("p"),dk=o(`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),Sh=s("code"),ck=o("prepare_for_model"),pk=o(" method."),hk=p(),ps=s("div"),v(al.$$.fragment),uk=p(),Ph=s("p"),mk=o(`Create a mask from the two sequences passed to be used in a sequence-pair classification task. XLM-RoBERTa does
not make use of token type ids, therefore a list of zeros is returned.`),fk=p(),mp=s("div"),v(rl.$$.fragment),zg=p(),pn=s("h2"),hs=s("a"),Oh=s("span"),v(ll.$$.fragment),gk=p(),Dh=s("span"),_k=o("XLMRobertaTokenizerFast"),Ug=p(),bt=s("div"),v(il.$$.fragment),bk=p(),Gt=s("p"),Mk=o("Construct a \u201Cfast\u201D XLM-RoBERTa tokenizer (backed by HuggingFace\u2019s "),Qh=s("em"),yk=o("tokenizers"),vk=o(` library). Adapted from
`),fp=s("a"),kk=o("RobertaTokenizer"),Tk=o(" and "),gp=s("a"),wk=o("XLNetTokenizer"),Fk=o(`. Based on
`),dl=s("a"),$k=o("BPE"),Rk=o("."),xk=p(),cl=s("p"),Lk=o("This tokenizer inherits from "),_p=s("a"),Xk=o("PreTrainedTokenizerFast"),Ek=o(` which contains most of the main methods. Users should
refer to this superclass for more information regarding those methods.`),jk=p(),Bo=s("div"),v(pl.$$.fragment),Ck=p(),Yh=s("p"),Jk=o(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An XLM-RoBERTa sequence has the following format:`),zk=p(),hl=s("ul"),bp=s("li"),Uk=o("single sequence: "),Hh=s("code"),Ik=o("<s> X </s>"),Nk=p(),Mp=s("li"),qk=o("pair of sequences: "),Kh=s("code"),Wk=o("<s> A </s></s> B </s>"),Bk=p(),us=s("div"),v(ul.$$.fragment),Zk=p(),eu=s("p"),Ak=o(`Create a mask from the two sequences passed to be used in a sequence-pair classification task. XLM-RoBERTa does
not make use of token type ids, therefore a list of zeros is returned.`),Ig=p(),hn=s("h2"),ms=s("a"),tu=s("span"),v(ml.$$.fragment),Gk=p(),ou=s("span"),Vk=o("XLMRobertaModel"),Ng=p(),Ke=s("div"),v(fl.$$.fragment),Sk=p(),nu=s("p"),Pk=o("The bare XLM-RoBERTa Model transformer outputting raw hidden-states without any specific head on top."),Ok=p(),gl=s("p"),Dk=o("This model inherits from "),yp=s("a"),Qk=o("PreTrainedModel"),Yk=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Hk=p(),_l=s("p"),Kk=o("This model is also a PyTorch "),bl=s("a"),eT=o("torch.nn.Module"),tT=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),oT=p(),Ml=s("p"),nT=o(`The model can behave as an encoder (with only self-attention) as well as a decoder, in which case a layer of
cross-attention is added between the self-attention layers, following the architecture described in `),su=s("em"),sT=o(`Attention is
all you need`),aT=o(`_ by Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz
Kaiser and Illia Polosukhin.`),rT=p(),it=s("p"),lT=o("To behave as an decoder the model needs to be initialized with the "),au=s("code"),iT=o("is_decoder"),dT=o(` argument of the configuration set
to `),ru=s("code"),cT=o("True"),pT=o(". To be used in a Seq2Seq model, the model needs to initialized with both "),lu=s("code"),hT=o("is_decoder"),uT=o(` argument and
`),iu=s("code"),mT=o("add_cross_attention"),fT=o(" set to "),du=s("code"),gT=o("True"),_T=o("; an "),cu=s("code"),bT=o("encoder_hidden_states"),MT=o(" is then expected as an input to the forward pass."),yT=p(),fs=s("p"),vT=o(".. _"),pu=s("em"),kT=o("Attention is all you need"),TT=o(": "),yl=s("a"),wT=o("https://arxiv.org/abs/1706.03762"),FT=p(),St=s("div"),v(vl.$$.fragment),$T=p(),un=s("p"),RT=o("The "),vp=s("a"),xT=o("XLMRobertaModel"),LT=o(" forward method, overrides the "),hu=s("code"),XT=o("__call__"),ET=o(" special method."),jT=p(),v(gs.$$.fragment),CT=p(),v(_s.$$.fragment),qg=p(),mn=s("h2"),bs=s("a"),uu=s("span"),v(kl.$$.fragment),JT=p(),mu=s("span"),zT=o("XLMRobertaForCausalLM"),Wg=p(),Mt=s("div"),v(Tl.$$.fragment),UT=p(),wl=s("p"),IT=o("XLM-RoBERTa Model with a "),fu=s("code"),NT=o("language modeling"),qT=o(" head on top for CLM fine-tuning."),WT=p(),Fl=s("p"),BT=o("This model inherits from "),kp=s("a"),ZT=o("PreTrainedModel"),AT=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),GT=p(),$l=s("p"),VT=o("This model is also a PyTorch "),Rl=s("a"),ST=o("torch.nn.Module"),PT=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),OT=p(),Pt=s("div"),v(xl.$$.fragment),DT=p(),fn=s("p"),QT=o("The "),Tp=s("a"),YT=o("XLMRobertaForCausalLM"),HT=o(" forward method, overrides the "),gu=s("code"),KT=o("__call__"),ew=o(" special method."),tw=p(),v(Ms.$$.fragment),ow=p(),v(ys.$$.fragment),Bg=p(),gn=s("h2"),vs=s("a"),_u=s("span"),v(Ll.$$.fragment),nw=p(),bu=s("span"),sw=o("XLMRobertaForMaskedLM"),Zg=p(),yt=s("div"),v(Xl.$$.fragment),aw=p(),El=s("p"),rw=o("XLM-RoBERTa Model with a "),Mu=s("code"),lw=o("language modeling"),iw=o(" head on top."),dw=p(),jl=s("p"),cw=o("This model inherits from "),wp=s("a"),pw=o("PreTrainedModel"),hw=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),uw=p(),Cl=s("p"),mw=o("This model is also a PyTorch "),Jl=s("a"),fw=o("torch.nn.Module"),gw=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),_w=p(),Ot=s("div"),v(zl.$$.fragment),bw=p(),_n=s("p"),Mw=o("The "),Fp=s("a"),yw=o("XLMRobertaForMaskedLM"),vw=o(" forward method, overrides the "),yu=s("code"),kw=o("__call__"),Tw=o(" special method."),ww=p(),v(ks.$$.fragment),Fw=p(),v(Ts.$$.fragment),Ag=p(),bn=s("h2"),ws=s("a"),vu=s("span"),v(Ul.$$.fragment),$w=p(),ku=s("span"),Rw=o("XLMRobertaForSequenceClassification"),Gg=p(),vt=s("div"),v(Il.$$.fragment),xw=p(),Tu=s("p"),Lw=o(`XLM-RoBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),Xw=p(),Nl=s("p"),Ew=o("This model inherits from "),$p=s("a"),jw=o("PreTrainedModel"),Cw=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Jw=p(),ql=s("p"),zw=o("This model is also a PyTorch "),Wl=s("a"),Uw=o("torch.nn.Module"),Iw=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Nw=p(),Lt=s("div"),v(Bl.$$.fragment),qw=p(),Mn=s("p"),Ww=o("The "),Rp=s("a"),Bw=o("XLMRobertaForSequenceClassification"),Zw=o(" forward method, overrides the "),wu=s("code"),Aw=o("__call__"),Gw=o(" special method."),Vw=p(),v(Fs.$$.fragment),Sw=p(),v($s.$$.fragment),Pw=p(),v(Rs.$$.fragment),Vg=p(),yn=s("h2"),xs=s("a"),Fu=s("span"),v(Zl.$$.fragment),Ow=p(),$u=s("span"),Dw=o("XLMRobertaForMultipleChoice"),Sg=p(),kt=s("div"),v(Al.$$.fragment),Qw=p(),Ru=s("p"),Yw=o(`XLM-RoBERTa 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.`),Hw=p(),Gl=s("p"),Kw=o("This model inherits from "),xp=s("a"),e2=o("PreTrainedModel"),t2=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),o2=p(),Vl=s("p"),n2=o("This model is also a PyTorch "),Sl=s("a"),s2=o("torch.nn.Module"),a2=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),r2=p(),Dt=s("div"),v(Pl.$$.fragment),l2=p(),vn=s("p"),i2=o("The "),Lp=s("a"),d2=o("XLMRobertaForMultipleChoice"),c2=o(" forward method, overrides the "),xu=s("code"),p2=o("__call__"),h2=o(" special method."),u2=p(),v(Ls.$$.fragment),m2=p(),v(Xs.$$.fragment),Pg=p(),kn=s("h2"),Es=s("a"),Lu=s("span"),v(Ol.$$.fragment),f2=p(),Xu=s("span"),g2=o("XLMRobertaForTokenClassification"),Og=p(),Tt=s("div"),v(Dl.$$.fragment),_2=p(),Eu=s("p"),b2=o(`XLM-RoBERTa 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.`),M2=p(),Ql=s("p"),y2=o("This model inherits from "),Xp=s("a"),v2=o("PreTrainedModel"),k2=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),T2=p(),Yl=s("p"),w2=o("This model is also a PyTorch "),Hl=s("a"),F2=o("torch.nn.Module"),$2=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),R2=p(),Qt=s("div"),v(Kl.$$.fragment),x2=p(),Tn=s("p"),L2=o("The "),Ep=s("a"),X2=o("XLMRobertaForTokenClassification"),E2=o(" forward method, overrides the "),ju=s("code"),j2=o("__call__"),C2=o(" special method."),J2=p(),v(js.$$.fragment),z2=p(),v(Cs.$$.fragment),Dg=p(),wn=s("h2"),Js=s("a"),Cu=s("span"),v(ei.$$.fragment),U2=p(),Ju=s("span"),I2=o("XLMRobertaForQuestionAnswering"),Qg=p(),wt=s("div"),v(ti.$$.fragment),N2=p(),Fn=s("p"),q2=o(`XLM-RoBERTa 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 `),zu=s("code"),W2=o("span start logits"),B2=o(" and "),Uu=s("code"),Z2=o("span end logits"),A2=o(")."),G2=p(),oi=s("p"),V2=o("This model inherits from "),jp=s("a"),S2=o("PreTrainedModel"),P2=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),O2=p(),ni=s("p"),D2=o("This model is also a PyTorch "),si=s("a"),Q2=o("torch.nn.Module"),Y2=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),H2=p(),Yt=s("div"),v(ai.$$.fragment),K2=p(),$n=s("p"),e1=o("The "),Cp=s("a"),t1=o("XLMRobertaForQuestionAnswering"),o1=o(" forward method, overrides the "),Iu=s("code"),n1=o("__call__"),s1=o(" special method."),a1=p(),v(zs.$$.fragment),r1=p(),v(Us.$$.fragment),Yg=p(),Rn=s("h2"),Is=s("a"),Nu=s("span"),v(ri.$$.fragment),l1=p(),qu=s("span"),i1=o("TFXLMRobertaModel"),Hg=p(),dt=s("div"),v(li.$$.fragment),d1=p(),Wu=s("p"),c1=o("The bare XLM RoBERTa Model transformer outputting raw hidden-states without any specific head on top."),p1=p(),ii=s("p"),h1=o("This model inherits from "),Jp=s("a"),u1=o("TFPreTrainedModel"),m1=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),f1=p(),di=s("p"),g1=o("This model is also a "),ci=s("a"),_1=o("tf.keras.Model"),b1=o(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),M1=p(),v(Ns.$$.fragment),y1=p(),Ht=s("div"),v(pi.$$.fragment),v1=p(),xn=s("p"),k1=o("The "),zp=s("a"),T1=o("TFXLMRobertaModel"),w1=o(" forward method, overrides the "),Bu=s("code"),F1=o("__call__"),$1=o(" special method."),R1=p(),v(qs.$$.fragment),x1=p(),v(Ws.$$.fragment),Kg=p(),Ln=s("h2"),Bs=s("a"),Zu=s("span"),v(hi.$$.fragment),L1=p(),Au=s("span"),X1=o("TFXLMRobertaForCausalLM"),e_=p(),ct=s("div"),v(ui.$$.fragment),E1=p(),mi=s("p"),j1=o("XLM-RoBERTa Model with a "),Gu=s("code"),C1=o("language modeling"),J1=o(" head on top for CLM fine-tuning."),z1=p(),fi=s("p"),U1=o("This model inherits from "),Up=s("a"),I1=o("TFPreTrainedModel"),N1=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),q1=p(),gi=s("p"),W1=o("This model is also a "),_i=s("a"),B1=o("tf.keras.Model"),Z1=o(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),A1=p(),v(Zs.$$.fragment),G1=p(),Kt=s("div"),v(bi.$$.fragment),V1=p(),Xn=s("p"),S1=o("The "),Ip=s("a"),P1=o("TFXLMRobertaForCausalLM"),O1=o(" forward method, overrides the "),Vu=s("code"),D1=o("__call__"),Q1=o(" special method."),Y1=p(),v(As.$$.fragment),H1=p(),v(Gs.$$.fragment),t_=p(),En=s("h2"),Vs=s("a"),Su=s("span"),v(Mi.$$.fragment),K1=p(),Pu=s("span"),e0=o("TFXLMRobertaForMaskedLM"),o_=p(),pt=s("div"),v(yi.$$.fragment),t0=p(),vi=s("p"),o0=o("XLM RoBERTa Model with a "),Ou=s("code"),n0=o("language modeling"),s0=o(" head on top."),a0=p(),ki=s("p"),r0=o("This model inherits from "),Np=s("a"),l0=o("TFPreTrainedModel"),i0=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),d0=p(),Ti=s("p"),c0=o("This model is also a "),wi=s("a"),p0=o("tf.keras.Model"),h0=o(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),u0=p(),v(Ss.$$.fragment),m0=p(),Xt=s("div"),v(Fi.$$.fragment),f0=p(),jn=s("p"),g0=o("The "),qp=s("a"),_0=o("TFXLMRobertaForMaskedLM"),b0=o(" forward method, overrides the "),Du=s("code"),M0=o("__call__"),y0=o(" special method."),v0=p(),v(Ps.$$.fragment),k0=p(),v(Os.$$.fragment),T0=p(),v(Ds.$$.fragment),n_=p(),Cn=s("h2"),Qs=s("a"),Qu=s("span"),v($i.$$.fragment),w0=p(),Yu=s("span"),F0=o("TFXLMRobertaForSequenceClassification"),s_=p(),ht=s("div"),v(Ri.$$.fragment),$0=p(),Hu=s("p"),R0=o(`XLM RoBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),x0=p(),xi=s("p"),L0=o("This model inherits from "),Wp=s("a"),X0=o("TFPreTrainedModel"),E0=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),j0=p(),Li=s("p"),C0=o("This model is also a "),Xi=s("a"),J0=o("tf.keras.Model"),z0=o(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),U0=p(),v(Ys.$$.fragment),I0=p(),Et=s("div"),v(Ei.$$.fragment),N0=p(),Jn=s("p"),q0=o("The "),Bp=s("a"),W0=o("TFXLMRobertaForSequenceClassification"),B0=o(" forward method, overrides the "),Ku=s("code"),Z0=o("__call__"),A0=o(" special method."),G0=p(),v(Hs.$$.fragment),V0=p(),v(Ks.$$.fragment),S0=p(),v(ea.$$.fragment),a_=p(),zn=s("h2"),ta=s("a"),em=s("span"),v(ji.$$.fragment),P0=p(),tm=s("span"),O0=o("TFXLMRobertaForMultipleChoice"),r_=p(),ut=s("div"),v(Ci.$$.fragment),D0=p(),om=s("p"),Q0=o(`XLM Roberta 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.`),Y0=p(),Ji=s("p"),H0=o("This model inherits from "),Zp=s("a"),K0=o("TFPreTrainedModel"),eF=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),tF=p(),zi=s("p"),oF=o("This model is also a "),Ui=s("a"),nF=o("tf.keras.Model"),sF=o(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),aF=p(),v(oa.$$.fragment),rF=p(),eo=s("div"),v(Ii.$$.fragment),lF=p(),Un=s("p"),iF=o("The "),Ap=s("a"),dF=o("TFXLMRobertaForMultipleChoice"),cF=o(" forward method, overrides the "),nm=s("code"),pF=o("__call__"),hF=o(" special method."),uF=p(),v(na.$$.fragment),mF=p(),v(sa.$$.fragment),l_=p(),In=s("h2"),aa=s("a"),sm=s("span"),v(Ni.$$.fragment),fF=p(),am=s("span"),gF=o("TFXLMRobertaForTokenClassification"),i_=p(),mt=s("div"),v(qi.$$.fragment),_F=p(),rm=s("p"),bF=o(`XLM RoBERTa 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.`),MF=p(),Wi=s("p"),yF=o("This model inherits from "),Gp=s("a"),vF=o("TFPreTrainedModel"),kF=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),TF=p(),Bi=s("p"),wF=o("This model is also a "),Zi=s("a"),FF=o("tf.keras.Model"),$F=o(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),RF=p(),v(ra.$$.fragment),xF=p(),jt=s("div"),v(Ai.$$.fragment),LF=p(),Nn=s("p"),XF=o("The "),Vp=s("a"),EF=o("TFXLMRobertaForTokenClassification"),jF=o(" forward method, overrides the "),lm=s("code"),CF=o("__call__"),JF=o(" special method."),zF=p(),v(la.$$.fragment),UF=p(),v(ia.$$.fragment),IF=p(),v(da.$$.fragment),d_=p(),qn=s("h2"),ca=s("a"),im=s("span"),v(Gi.$$.fragment),NF=p(),dm=s("span"),qF=o("TFXLMRobertaForQuestionAnswering"),c_=p(),ft=s("div"),v(Vi.$$.fragment),WF=p(),Wn=s("p"),BF=o(`XLM RoBERTa 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 `),cm=s("code"),ZF=o("span start logits"),AF=o(" and "),pm=s("code"),GF=o("span end logits"),VF=o(")."),SF=p(),Si=s("p"),PF=o("This model inherits from "),Sp=s("a"),OF=o("TFPreTrainedModel"),DF=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),QF=p(),Pi=s("p"),YF=o("This model is also a "),Oi=s("a"),HF=o("tf.keras.Model"),KF=o(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),e$=p(),v(pa.$$.fragment),t$=p(),Ct=s("div"),v(Di.$$.fragment),o$=p(),Bn=s("p"),n$=o("The "),Pp=s("a"),s$=o("TFXLMRobertaForQuestionAnswering"),a$=o(" forward method, overrides the "),hm=s("code"),r$=o("__call__"),l$=o(" special method."),i$=p(),v(ha.$$.fragment),d$=p(),v(ua.$$.fragment),c$=p(),v(ma.$$.fragment),p_=p(),Zn=s("h2"),fa=s("a"),um=s("span"),v(Qi.$$.fragment),p$=p(),mm=s("span"),h$=o("FlaxXLMRobertaModel"),h_=p(),tt=s("div"),v(Yi.$$.fragment),u$=p(),fm=s("p"),m$=o("The bare XLM RoBERTa Model transformer outputting raw hidden-states without any specific head on top."),f$=p(),Hi=s("p"),g$=o("This model inherits from "),Op=s("a"),_$=o("FlaxPreTrainedModel"),b$=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),M$=p(),Ki=s("p"),y$=o("This model is also a Flax Linen "),ed=s("a"),v$=o("flax.linen.Module"),k$=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),T$=p(),gm=s("p"),w$=o("Finally, this model supports inherent JAX features such as:"),F$=p(),bo=s("ul"),_m=s("li"),td=s("a"),$$=o("Just-In-Time (JIT) compilation"),R$=p(),bm=s("li"),od=s("a"),x$=o("Automatic Differentiation"),L$=p(),Mm=s("li"),nd=s("a"),X$=o("Vectorization"),E$=p(),ym=s("li"),sd=s("a"),j$=o("Parallelization"),C$=p(),to=s("div"),v(ad.$$.fragment),J$=p(),An=s("p"),z$=o("The "),vm=s("code"),U$=o("FlaxXLMRobertaPreTrainedModel"),I$=o(" forward method, overrides the "),km=s("code"),N$=o("__call__"),q$=o(" special method."),W$=p(),v(ga.$$.fragment),B$=p(),v(_a.$$.fragment),u_=p(),Gn=s("h2"),ba=s("a"),Tm=s("span"),v(rd.$$.fragment),Z$=p(),wm=s("span"),A$=o("FlaxXLMRobertaForCausalLM"),m_=p(),ot=s("div"),v(ld.$$.fragment),G$=p(),Fm=s("p"),V$=o(`XLM Roberta Model with a language modeling head on top (a linear layer on top of the hidden-states output) e.g for
autoregressive tasks.`),S$=p(),id=s("p"),P$=o("This model inherits from "),Dp=s("a"),O$=o("FlaxPreTrainedModel"),D$=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),Q$=p(),dd=s("p"),Y$=o("This model is also a Flax Linen "),cd=s("a"),H$=o("flax.linen.Module"),K$=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),eR=p(),$m=s("p"),tR=o("Finally, this model supports inherent JAX features such as:"),oR=p(),Mo=s("ul"),Rm=s("li"),pd=s("a"),nR=o("Just-In-Time (JIT) compilation"),sR=p(),xm=s("li"),hd=s("a"),aR=o("Automatic Differentiation"),rR=p(),Lm=s("li"),ud=s("a"),lR=o("Vectorization"),iR=p(),Xm=s("li"),md=s("a"),dR=o("Parallelization"),cR=p(),oo=s("div"),v(fd.$$.fragment),pR=p(),Vn=s("p"),hR=o("The "),Em=s("code"),uR=o("FlaxXLMRobertaPreTrainedModel"),mR=o(" forward method, overrides the "),jm=s("code"),fR=o("__call__"),gR=o(" special method."),_R=p(),v(Ma.$$.fragment),bR=p(),v(ya.$$.fragment),f_=p(),Sn=s("h2"),va=s("a"),Cm=s("span"),v(gd.$$.fragment),MR=p(),Jm=s("span"),yR=o("FlaxXLMRobertaForMaskedLM"),g_=p(),nt=s("div"),v(_d.$$.fragment),vR=p(),bd=s("p"),kR=o("XLM RoBERTa Model with a "),zm=s("code"),TR=o("language modeling"),wR=o(" head on top."),FR=p(),Md=s("p"),$R=o("This model inherits from "),Qp=s("a"),RR=o("FlaxPreTrainedModel"),xR=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),LR=p(),yd=s("p"),XR=o("This model is also a Flax Linen "),vd=s("a"),ER=o("flax.linen.Module"),jR=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),CR=p(),Um=s("p"),JR=o("Finally, this model supports inherent JAX features such as:"),zR=p(),yo=s("ul"),Im=s("li"),kd=s("a"),UR=o("Just-In-Time (JIT) compilation"),IR=p(),Nm=s("li"),Td=s("a"),NR=o("Automatic Differentiation"),qR=p(),qm=s("li"),wd=s("a"),WR=o("Vectorization"),BR=p(),Wm=s("li"),Fd=s("a"),ZR=o("Parallelization"),AR=p(),no=s("div"),v($d.$$.fragment),GR=p(),Pn=s("p"),VR=o("The "),Bm=s("code"),SR=o("FlaxXLMRobertaPreTrainedModel"),PR=o(" forward method, overrides the "),Zm=s("code"),OR=o("__call__"),DR=o(" special method."),QR=p(),v(ka.$$.fragment),YR=p(),v(Ta.$$.fragment),__=p(),On=s("h2"),wa=s("a"),Am=s("span"),v(Rd.$$.fragment),HR=p(),Gm=s("span"),KR=o("FlaxXLMRobertaForSequenceClassification"),b_=p(),st=s("div"),v(xd.$$.fragment),ex=p(),Vm=s("p"),tx=o(`XLM Roberta Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),ox=p(),Ld=s("p"),nx=o("This model inherits from "),Yp=s("a"),sx=o("FlaxPreTrainedModel"),ax=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),rx=p(),Xd=s("p"),lx=o("This model is also a Flax Linen "),Ed=s("a"),ix=o("flax.linen.Module"),dx=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),cx=p(),Sm=s("p"),px=o("Finally, this model supports inherent JAX features such as:"),hx=p(),vo=s("ul"),Pm=s("li"),jd=s("a"),ux=o("Just-In-Time (JIT) compilation"),mx=p(),Om=s("li"),Cd=s("a"),fx=o("Automatic Differentiation"),gx=p(),Dm=s("li"),Jd=s("a"),_x=o("Vectorization"),bx=p(),Qm=s("li"),zd=s("a"),Mx=o("Parallelization"),yx=p(),so=s("div"),v(Ud.$$.fragment),vx=p(),Dn=s("p"),kx=o("The "),Ym=s("code"),Tx=o("FlaxXLMRobertaPreTrainedModel"),wx=o(" forward method, overrides the "),Hm=s("code"),Fx=o("__call__"),$x=o(" special method."),Rx=p(),v(Fa.$$.fragment),xx=p(),v($a.$$.fragment),M_=p(),Qn=s("h2"),Ra=s("a"),Km=s("span"),v(Id.$$.fragment),Lx=p(),ef=s("span"),Xx=o("FlaxXLMRobertaForMultipleChoice"),y_=p(),at=s("div"),v(Nd.$$.fragment),Ex=p(),tf=s("p"),jx=o(`XLM Roberta Model with a multiple choice classification head on top (a linear layer on top of the pooled output and
a softmax) e.g. for RocStories/SWAG tasks.`),Cx=p(),qd=s("p"),Jx=o("This model inherits from "),Hp=s("a"),zx=o("FlaxPreTrainedModel"),Ux=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),Ix=p(),Wd=s("p"),Nx=o("This model is also a Flax Linen "),Bd=s("a"),qx=o("flax.linen.Module"),Wx=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Bx=p(),of=s("p"),Zx=o("Finally, this model supports inherent JAX features such as:"),Ax=p(),ko=s("ul"),nf=s("li"),Zd=s("a"),Gx=o("Just-In-Time (JIT) compilation"),Vx=p(),sf=s("li"),Ad=s("a"),Sx=o("Automatic Differentiation"),Px=p(),af=s("li"),Gd=s("a"),Ox=o("Vectorization"),Dx=p(),rf=s("li"),Vd=s("a"),Qx=o("Parallelization"),Yx=p(),ao=s("div"),v(Sd.$$.fragment),Hx=p(),Yn=s("p"),Kx=o("The "),lf=s("code"),eL=o("FlaxXLMRobertaPreTrainedModel"),tL=o(" forward method, overrides the "),df=s("code"),oL=o("__call__"),nL=o(" special method."),sL=p(),v(xa.$$.fragment),aL=p(),v(La.$$.fragment),v_=p(),Hn=s("h2"),Xa=s("a"),cf=s("span"),v(Pd.$$.fragment),rL=p(),pf=s("span"),lL=o("FlaxXLMRobertaForTokenClassification"),k_=p(),rt=s("div"),v(Od.$$.fragment),iL=p(),hf=s("p"),dL=o(`XLM Roberta 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.`),cL=p(),Dd=s("p"),pL=o("This model inherits from "),Kp=s("a"),hL=o("FlaxPreTrainedModel"),uL=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),mL=p(),Qd=s("p"),fL=o("This model is also a Flax Linen "),Yd=s("a"),gL=o("flax.linen.Module"),_L=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),bL=p(),uf=s("p"),ML=o("Finally, this model supports inherent JAX features such as:"),yL=p(),To=s("ul"),mf=s("li"),Hd=s("a"),vL=o("Just-In-Time (JIT) compilation"),kL=p(),ff=s("li"),Kd=s("a"),TL=o("Automatic Differentiation"),wL=p(),gf=s("li"),ec=s("a"),FL=o("Vectorization"),$L=p(),_f=s("li"),tc=s("a"),RL=o("Parallelization"),xL=p(),ro=s("div"),v(oc.$$.fragment),LL=p(),Kn=s("p"),XL=o("The "),bf=s("code"),EL=o("FlaxXLMRobertaPreTrainedModel"),jL=o(" forward method, overrides the "),Mf=s("code"),CL=o("__call__"),JL=o(" special method."),zL=p(),v(Ea.$$.fragment),UL=p(),v(ja.$$.fragment),T_=p(),es=s("h2"),Ca=s("a"),yf=s("span"),v(nc.$$.fragment),IL=p(),vf=s("span"),NL=o("FlaxXLMRobertaForQuestionAnswering"),w_=p(),lt=s("div"),v(sc.$$.fragment),qL=p(),ts=s("p"),WL=o(`XLM Roberta 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 `),kf=s("code"),BL=o("span start logits"),ZL=o(" and "),Tf=s("code"),AL=o("span end logits"),GL=o(")."),VL=p(),ac=s("p"),SL=o("This model inherits from "),eh=s("a"),PL=o("FlaxPreTrainedModel"),OL=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),DL=p(),rc=s("p"),QL=o("This model is also a Flax Linen "),lc=s("a"),YL=o("flax.linen.Module"),HL=o(`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),KL=p(),wf=s("p"),eX=o("Finally, this model supports inherent JAX features such as:"),tX=p(),wo=s("ul"),Ff=s("li"),ic=s("a"),oX=o("Just-In-Time (JIT) compilation"),nX=p(),$f=s("li"),dc=s("a"),sX=o("Automatic Differentiation"),aX=p(),Rf=s("li"),cc=s("a"),rX=o("Vectorization"),lX=p(),xf=s("li"),pc=s("a"),iX=o("Parallelization"),dX=p(),lo=s("div"),v(hc.$$.fragment),cX=p(),os=s("p"),pX=o("The "),Lf=s("code"),hX=o("FlaxXLMRobertaPreTrainedModel"),uX=o(" forward method, overrides the "),Xf=s("code"),mX=o("__call__"),fX=o(" special method."),gX=p(),v(Ja.$$.fragment),_X=p(),v(za.$$.fragment),this.h()},l(l){const _=jJ('[data-svelte="svelte-1phssyn"]',document.head);d=a(_,"META",{name:!0,content:!0}),_.forEach(t),M=h(l),m=a(l,"H1",{class:!0});var uc=r(m);f=a(uc,"A",{id:!0,class:!0,href:!0});var Ef=r(f);b=a(Ef,"SPAN",{});var jf=r(b);k(i.$$.fragment,jf),jf.forEach(t),Ef.forEach(t),u=h(uc),X=a(uc,"SPAN",{});var Cf=r(X);Me=n(Cf,"XLM-RoBERTa"),Cf.forEach(t),uc.forEach(t),fe=h(l),q=a(l,"DIV",{class:!0});var mc=r(q);ce=a(mc,"A",{href:!0});var Jf=r(ce);te=a(Jf,"IMG",{alt:!0,src:!0}),Jf.forEach(t),ye=h(mc),A=a(mc,"A",{href:!0});var zf=r(A);pe=a(zf,"IMG",{alt:!0,src:!0}),zf.forEach(t),mc.forEach(t),O=h(l),ae=a(l,"H2",{class:!0});var fc=r(ae);re=a(fc,"A",{id:!0,class:!0,href:!0});var Uf=r(re);G=a(Uf,"SPAN",{});var If=r(G);k(le.$$.fragment,If),If.forEach(t),Uf.forEach(t),ve=h(fc),V=a(fc,"SPAN",{});var Nf=r(V);ke=n(Nf,"Overview"),Nf.forEach(t),fc.forEach(t),ge=h(l),B=a(l,"P",{});var gc=r(B);Te=n(gc,"The XLM-RoBERTa model was proposed in "),ie=a(gc,"A",{href:!0,rel:!0});var qf=r(ie);oe=n(qf,"Unsupervised Cross-lingual Representation Learning at Scale"),qf.forEach(t),j=n(gc,` by Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume
Wenzek, Francisco Guzm\xE1n, Edouard Grave, Myle Ott, Luke Zettlemoyer and Veselin Stoyanov. It is based on Facebook\u2019s
RoBERTa model released in 2019. It is a large multi-lingual language model, trained on 2.5TB of filtered CommonCrawl
data.`),gc.forEach(t),z=h(l),he=a(l,"P",{});var Wf=r(he);Q=n(Wf,"The abstract from the paper is the following:"),Wf.forEach(t),_e=h(l),ue=a(l,"P",{});var Bf=r(ue);S=a(Bf,"EM",{});var Zf=r(S);we=n(Zf,`This paper shows that pretraining multilingual language models at scale leads to significant performance gains for a
wide range of cross-lingual transfer tasks. We train a Transformer-based masked language model on one hundred
languages, using more than two terabytes of filtered CommonCrawl data. Our model, dubbed XLM-R, significantly
outperforms multilingual BERT (mBERT) on a variety of cross-lingual benchmarks, including +13.8% average accuracy on
XNLI, +12.3% average F1 score on MLQA, and +2.1% average F1 score on NER. XLM-R performs particularly well on
low-resource languages, improving 11.8% in XNLI accuracy for Swahili and 9.2% for Urdu over the previous XLM model. We
also present a detailed empirical evaluation of the key factors that are required to achieve these gains, including the
trade-offs between (1) positive transfer and capacity dilution and (2) the performance of high and low resource
languages at scale. Finally, we show, for the first time, the possibility of multilingual modeling without sacrificing
per-language performance; XLM-Ris very competitive with strong monolingual models on the GLUE and XNLI benchmarks. We
will make XLM-R code, data, and models publicly available.`),Zf.forEach(t),Bf.forEach(t),be=h(l),J=a(l,"P",{});var Af=r(J);Fe=n(Af,"Tips:"),Af.forEach(t),D=h(l),ne=a(l,"UL",{});var ns=r(ne);de=a(ns,"LI",{});var _c=r(de);Y=n(_c,`XLM-RoBERTa is a multilingual model trained on 100 different languages. Unlike some XLM multilingual models, it does
not require `),me=a(_c,"CODE",{});var Gf=r(me);$e=n(Gf,"lang"),Gf.forEach(t),N=n(_c,` tensors to understand which language is used, and should be able to determine the correct
language from the input ids.`),_c.forEach(t),Re=h(ns),P=a(ns,"LI",{});var Vf=r(P);xe=n(Vf,"Uses RoBERTa tricks on the XLM approach, but does not use the translation language modeling objective. It only uses masked language modeling on sentences coming from one language."),Vf.forEach(t),se=h(ns),C=a(ns,"LI",{});var bc=r(C);Le=n(bc,"This implementation is the same as RoBERTa. Refer to the "),U=a(bc,"A",{href:!0});var Sf=r(U);Xe=n(Sf,"documentation of RoBERTa"),Sf.forEach(t),Ee=n(bc,` for usage examples
as well as the information relative to the inputs and outputs.`),bc.forEach(t),ns.forEach(t),y=h(l),x=a(l,"P",{});var ss=r(x);Pe=n(ss,"This model was contributed by "),K=a(ss,"A",{href:!0,rel:!0});var Pf=r(K);Oe=n(Pf,"stefan-it"),Pf.forEach(t),De=n(ss,". The original code can be found "),E=a(ss,"A",{href:!0,rel:!0});var Of=r(E);Qe=n(Of,"here"),Of.forEach(t),Ye=n(ss,"."),ss.forEach(t),Ae=h(l),Je=a(l,"H2",{class:!0});var Mc=r(Je);ze=a(Mc,"A",{id:!0,class:!0,href:!0});var Df=r(ze);I=a(Df,"SPAN",{});var Qf=r(I);k(Z.$$.fragment,Qf),Qf.forEach(t),Df.forEach(t),He=h(Mc),Ze=a(Mc,"SPAN",{});var Yf=r(Ze);H=n(Yf,"Resources"),Yf.forEach(t),Mc.forEach(t),Ge=h(l),Ie=a(l,"P",{});var Hf=r(Ie);je=n(Hf,"A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with XLM-RoBERTa. If you\u2019re interested in submitting a resource to be included here, please feel free to open a Pull Request and we\u2019ll review it! The resource should ideally demonstrate something new instead of duplicating an existing resource."),Hf.forEach(t),Ve=h(l),k(ee.$$.fragment,l),Se=h(l),gt=a(l,"UL",{});var Ft=r(gt);Lc=a(Ft,"LI",{});var th=r(Lc);Kb=n(th,"A blog post on how to "),ir=a(th,"A",{href:!0,rel:!0});var Kf=r(ir);eM=n(Kf,"finetune XLM RoBERTa for multiclass classification with Habana Gaudi on AWS"),Kf.forEach(t),th.forEach(t),tM=h(Ft),Fo=a(Ft,"LI",{});var Zo=r(Fo);Xc=a(Zo,"A",{href:!0});var eg=r(Xc);oM=n(eg,"XLMRobertaForSequenceClassification"),eg.forEach(t),nM=n(Zo," is supported by this "),dr=a(Zo,"A",{href:!0,rel:!0});var tg=r(dr);sM=n(tg,"example script"),tg.forEach(t),aM=n(Zo," and "),cr=a(Zo,"A",{href:!0,rel:!0});var og=r(cr);rM=n(og,"notebook"),og.forEach(t),lM=n(Zo,"."),Zo.forEach(t),iM=h(Ft),$o=a(Ft,"LI",{});var Ao=r($o);Ec=a(Ao,"A",{href:!0});var ng=r(Ec);dM=n(ng,"TFXLMRobertaForSequenceClassification"),ng.forEach(t),cM=n(Ao," is supported by this "),pr=a(Ao,"A",{href:!0,rel:!0});var sg=r(pr);pM=n(sg,"example script"),sg.forEach(t),hM=n(Ao," and "),hr=a(Ao,"A",{href:!0,rel:!0});var ag=r(hr);uM=n(ag,"notebook"),ag.forEach(t),mM=n(Ao,"."),Ao.forEach(t),fM=h(Ft),Ro=a(Ft,"LI",{});var Go=r(Ro);jc=a(Go,"A",{href:!0});var rg=r(jc);gM=n(rg,"FlaxXLMRobertaForSequenceClassification"),rg.forEach(t),_M=n(Go," is supported by this "),ur=a(Go,"A",{href:!0,rel:!0});var lg=r(ur);bM=n(lg,"example script"),lg.forEach(t),MM=n(Go," and "),mr=a(Go,"A",{href:!0,rel:!0});var ig=r(mr);yM=n(ig,"notebook"),ig.forEach(t),vM=n(Go,"."),Go.forEach(t),kM=h(Ft),Cc=a(Ft,"LI",{});var oh=r(Cc);fr=a(oh,"A",{href:!0,rel:!0});var dg=r(fr);TM=n(dg,"Text classification"),dg.forEach(t),wM=n(oh," chapter of the \u{1F917} Hugging Face Task Guides."),oh.forEach(t),FM=h(Ft),jh=a(Ft,"LI",{});var cg=r(jh);Jc=a(cg,"A",{href:!0});var pg=r(Jc);$M=n(pg,"Text classification task guide"),pg.forEach(t),cg.forEach(t),Ft.forEach(t),Mg=h(l),k(gr.$$.fragment,l),yg=h(l),$t=a(l,"UL",{});var Vt=r($t);xo=a(Vt,"LI",{});var Vo=r(xo);zc=a(Vo,"A",{href:!0});var hg=r(zc);RM=n(hg,"XLMRobertaForTokenClassification"),hg.forEach(t),xM=n(Vo," is supported by this "),_r=a(Vo,"A",{href:!0,rel:!0});var ug=r(_r);LM=n(ug,"example script"),ug.forEach(t),XM=n(Vo," and "),br=a(Vo,"A",{href:!0,rel:!0});var mg=r(br);EM=n(mg,"notebook"),mg.forEach(t),jM=n(Vo,"."),Vo.forEach(t),CM=h(Vt),Lo=a(Vt,"LI",{});var yc=r(Lo);Uc=a(yc,"A",{href:!0});var $X=r(Uc);JM=n($X,"TFXLMRobertaForTokenClassification"),$X.forEach(t),zM=n(yc," is supported by this "),Mr=a(yc,"A",{href:!0,rel:!0});var RX=r(Mr);UM=n(RX,"example script"),RX.forEach(t),IM=n(yc," and "),yr=a(yc,"A",{href:!0,rel:!0});var xX=r(yr);NM=n(xX,"notebook"),xX.forEach(t),qM=n(yc,"."),yc.forEach(t),WM=h(Vt),as=a(Vt,"LI",{});var fg=r(as);Ic=a(fg,"A",{href:!0});var LX=r(Ic);BM=n(LX,"FlaxXLMRobertaForTokenClassification"),LX.forEach(t),ZM=n(fg," is supported by this "),vr=a(fg,"A",{href:!0,rel:!0});var XX=r(vr);AM=n(XX,"example script"),XX.forEach(t),GM=n(fg,"."),fg.forEach(t),VM=h(Vt),Nc=a(Vt,"LI",{});var bX=r(Nc);kr=a(bX,"A",{href:!0,rel:!0});var EX=r(kr);SM=n(EX,"Token classification"),EX.forEach(t),PM=n(bX," chapter of the \u{1F917} Hugging Face Course."),bX.forEach(t),OM=h(Vt),Ch=a(Vt,"LI",{});var jX=r(Ch);qc=a(jX,"A",{href:!0});var CX=r(qc);DM=n(CX,"Token classification task guide"),CX.forEach(t),jX.forEach(t),Vt.forEach(t),vg=h(l),k(Tr.$$.fragment,l),kg=h(l),Xo=a(l,"UL",{});var nh=r(Xo);Eo=a(nh,"LI",{});var vc=r(Eo);Wc=a(vc,"A",{href:!0});var JX=r(Wc);QM=n(JX,"XLMRobertaForCausalLM"),JX.forEach(t),YM=n(vc," is supported by this "),wr=a(vc,"A",{href:!0,rel:!0});var zX=r(wr);HM=n(zX,"example script"),zX.forEach(t),KM=n(vc," and "),Fr=a(vc,"A",{href:!0,rel:!0});var UX=r(Fr);ey=n(UX,"notebook"),UX.forEach(t),ty=n(vc,"."),vc.forEach(t),oy=h(nh),Bc=a(nh,"LI",{});var MX=r(Bc);$r=a(MX,"A",{href:!0,rel:!0});var IX=r($r);ny=n(IX,"Causal language modeling"),IX.forEach(t),sy=n(MX," chapter of the \u{1F917} Hugging Face Task Guides."),MX.forEach(t),ay=h(nh),Jh=a(nh,"LI",{});var NX=r(Jh);Zc=a(NX,"A",{href:!0});var qX=r(Zc);ry=n(qX,"Causal language modeling task guide"),qX.forEach(t),NX.forEach(t),nh.forEach(t),Tg=h(l),k(Rr.$$.fragment,l),wg=h(l),Rt=a(l,"UL",{});var So=r(Rt);jo=a(So,"LI",{});var kc=r(jo);Ac=a(kc,"A",{href:!0});var WX=r(Ac);ly=n(WX,"XLMRobertaForMaskedLM"),WX.forEach(t),iy=n(kc," is supported by this "),xr=a(kc,"A",{href:!0,rel:!0});var BX=r(xr);dy=n(BX,"example script"),BX.forEach(t),cy=n(kc," and "),Lr=a(kc,"A",{href:!0,rel:!0});var ZX=r(Lr);py=n(ZX,"notebook"),ZX.forEach(t),hy=n(kc,"."),kc.forEach(t),uy=h(So),Co=a(So,"LI",{});var Tc=r(Co);Gc=a(Tc,"A",{href:!0});var AX=r(Gc);my=n(AX,"TFXLMRobertaForMaskedLM"),AX.forEach(t),fy=n(Tc," is supported by this "),Xr=a(Tc,"A",{href:!0,rel:!0});var GX=r(Xr);gy=n(GX,"example script"),GX.forEach(t),_y=n(Tc," and "),Er=a(Tc,"A",{href:!0,rel:!0});var VX=r(Er);by=n(VX,"notebook"),VX.forEach(t),My=n(Tc,"."),Tc.forEach(t),yy=h(So),Jo=a(So,"LI",{});var wc=r(Jo);Vc=a(wc,"A",{href:!0});var SX=r(Vc);vy=n(SX,"FlaxXLMRobertaForMaskedLM"),SX.forEach(t),ky=n(wc," is supported by this "),jr=a(wc,"A",{href:!0,rel:!0});var PX=r(jr);Ty=n(PX,"example script"),PX.forEach(t),wy=n(wc," and "),Cr=a(wc,"A",{href:!0,rel:!0});var OX=r(Cr);Fy=n(OX,"notebook"),OX.forEach(t),$y=n(wc,"."),wc.forEach(t),Ry=h(So),Sc=a(So,"LI",{});var yX=r(Sc);Jr=a(yX,"A",{href:!0,rel:!0});var DX=r(Jr);xy=n(DX,"Masked language modeling"),DX.forEach(t),Ly=n(yX," chapter of the \u{1F917} Hugging Face Course."),yX.forEach(t),Xy=h(So),zh=a(So,"LI",{});var QX=r(zh);Pc=a(QX,"A",{href:!0});var YX=r(Pc);Ey=n(YX,"Masked language modeling"),YX.forEach(t),QX.forEach(t),So.forEach(t),Fg=h(l),k(zr.$$.fragment,l),$g=h(l),xt=a(l,"UL",{});var Po=r(xt);zo=a(Po,"LI",{});var Fc=r(zo);Oc=a(Fc,"A",{href:!0});var HX=r(Oc);jy=n(HX,"XLMRobertaForQuestionAnswering"),HX.forEach(t),Cy=n(Fc," is supported by this "),Ur=a(Fc,"A",{href:!0,rel:!0});var KX=r(Ur);Jy=n(KX,"example script"),KX.forEach(t),zy=n(Fc," and "),Ir=a(Fc,"A",{href:!0,rel:!0});var eE=r(Ir);Uy=n(eE,"notebook"),eE.forEach(t),Iy=n(Fc,"."),Fc.forEach(t),Ny=h(Po),Uo=a(Po,"LI",{});var $c=r(Uo);Dc=a($c,"A",{href:!0});var tE=r(Dc);qy=n(tE,"TFXLMRobertaForQuestionAnswering"),tE.forEach(t),Wy=n($c," is supported by this "),Nr=a($c,"A",{href:!0,rel:!0});var oE=r(Nr);By=n(oE,"example script"),oE.forEach(t),Zy=n($c," and "),qr=a($c,"A",{href:!0,rel:!0});var nE=r(qr);Ay=n(nE,"notebook"),nE.forEach(t),Gy=n($c,"."),$c.forEach(t),Vy=h(Po),rs=a(Po,"LI",{});var gg=r(rs);Qc=a(gg,"A",{href:!0});var sE=r(Qc);Sy=n(sE,"FlaxXLMRobertaForQuestionAnswering"),sE.forEach(t),Py=n(gg," is supported by this "),Wr=a(gg,"A",{href:!0,rel:!0});var aE=r(Wr);Oy=n(aE,"example script"),aE.forEach(t),Dy=n(gg,"."),gg.forEach(t),Qy=h(Po),Yc=a(Po,"LI",{});var vX=r(Yc);Br=a(vX,"A",{href:!0,rel:!0});var rE=r(Br);Yy=n(rE,"Question answering"),rE.forEach(t),Hy=n(vX," chapter of the \u{1F917} Hugging Face Course."),vX.forEach(t),Ky=h(Po),Uh=a(Po,"LI",{});var lE=r(Uh);Hc=a(lE,"A",{href:!0});var iE=r(Hc);ev=n(iE,"Question answering task guide"),iE.forEach(t),lE.forEach(t),Po.forEach(t),Rg=h(l),Kc=a(l,"P",{});var dE=r(Kc);Ih=a(dE,"STRONG",{});var cE=r(Ih);tv=n(cE,"Multiple choice"),cE.forEach(t),dE.forEach(t),xg=h(l),Io=a(l,"UL",{});var sh=r(Io);No=a(sh,"LI",{});var Rc=r(No);ep=a(Rc,"A",{href:!0});var pE=r(ep);ov=n(pE,"XLMRobertaForMultipleChoice"),pE.forEach(t),nv=n(Rc," is supported by this "),Zr=a(Rc,"A",{href:!0,rel:!0});var hE=r(Zr);sv=n(hE,"example script"),hE.forEach(t),av=n(Rc," and "),Ar=a(Rc,"A",{href:!0,rel:!0});var uE=r(Ar);rv=n(uE,"notebook"),uE.forEach(t),lv=n(Rc,"."),Rc.forEach(t),iv=h(sh),qo=a(sh,"LI",{});var xc=r(qo);tp=a(xc,"A",{href:!0});var mE=r(tp);dv=n(mE,"TFXLMRobertaForMultipleChoice"),mE.forEach(t),cv=n(xc," is supported by this "),Gr=a(xc,"A",{href:!0,rel:!0});var fE=r(Gr);pv=n(fE,"example script"),fE.forEach(t),hv=n(xc," and "),Vr=a(xc,"A",{href:!0,rel:!0});var gE=r(Vr);uv=n(gE,"notebook"),gE.forEach(t),mv=n(xc,"."),xc.forEach(t),fv=h(sh),Nh=a(sh,"LI",{});var _E=r(Nh);op=a(_E,"A",{href:!0});var bE=r(op);gv=n(bE,"Multiple choice task guide"),bE.forEach(t),_E.forEach(t),sh.forEach(t),Lg=h(l),np=a(l,"P",{});var ME=r(np);_v=n(ME,"\u{1F680} Deploy"),ME.forEach(t),Xg=h(l),sp=a(l,"UL",{});var yE=r(sp);Sr=a(yE,"LI",{});var $_=r(Sr);bv=n($_,"A blog post on how to "),Pr=a($_,"A",{href:!0,rel:!0});var vE=r(Pr);Mv=n(vE,"Deploy Serverless XLM RoBERTa on AWS Lambda"),vE.forEach(t),yv=n($_,"."),$_.forEach(t),yE.forEach(t),Eg=h(l),ln=a(l,"H2",{class:!0});var R_=r(ln);ls=a(R_,"A",{id:!0,class:!0,href:!0});var kE=r(ls);qh=a(kE,"SPAN",{});var TE=r(qh);k(Or.$$.fragment,TE),TE.forEach(t),kE.forEach(t),vv=h(R_),Wh=a(R_,"SPAN",{});var wE=r(Wh);kv=n(wE,"XLMRobertaConfig"),wE.forEach(t),R_.forEach(t),jg=h(l),At=a(l,"DIV",{class:!0});var Ua=r(At);k(Dr.$$.fragment,Ua),Tv=h(Ua),go=a(Ua,"P",{});var Ia=r(go);wv=n(Ia,"This is the configuration class to store the configuration of a "),ap=a(Ia,"A",{href:!0});var FE=r(ap);Fv=n(FE,"XLMRobertaModel"),FE.forEach(t),$v=n(Ia," or a "),rp=a(Ia,"A",{href:!0});var $E=r(rp);Rv=n($E,"TFXLMRobertaModel"),$E.forEach(t),xv=n(Ia,`. It
is used to instantiate a XLM-RoBERTa 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 XLMRoBERTa
`),Qr=a(Ia,"A",{href:!0,rel:!0});var RE=r(Qr);Lv=n(RE,"xlm-roberta-base"),RE.forEach(t),Xv=n(Ia," architecture."),Ia.forEach(t),Ev=h(Ua),dn=a(Ua,"P",{});var ah=r(dn);jv=n(ah,"Configuration objects inherit from "),lp=a(ah,"A",{href:!0});var xE=r(lp);Cv=n(xE,"PretrainedConfig"),xE.forEach(t),Jv=n(ah,` and can be used to control the model outputs. Read the
documentation from `),ip=a(ah,"A",{href:!0});var LE=r(ip);zv=n(LE,"PretrainedConfig"),LE.forEach(t),Uv=n(ah," for more information."),ah.forEach(t),Iv=h(Ua),k(is.$$.fragment,Ua),Ua.forEach(t),Cg=h(l),cn=a(l,"H2",{class:!0});var x_=r(cn);ds=a(x_,"A",{id:!0,class:!0,href:!0});var XE=r(ds);Bh=a(XE,"SPAN",{});var EE=r(Bh);k(Yr.$$.fragment,EE),EE.forEach(t),XE.forEach(t),Nv=h(x_),Zh=a(x_,"SPAN",{});var jE=r(Zh);qv=n(jE,"XLMRobertaTokenizer"),jE.forEach(t),x_.forEach(t),Jg=h(l),et=a(l,"DIV",{class:!0});var Jt=r(et);k(Hr.$$.fragment,Jt),Wv=h(Jt),_o=a(Jt,"P",{});var Na=r(_o);Bv=n(Na,"Adapted from "),dp=a(Na,"A",{href:!0});var CE=r(dp);Zv=n(CE,"RobertaTokenizer"),CE.forEach(t),Av=n(Na," and "),cp=a(Na,"A",{href:!0});var JE=r(cp);Gv=n(JE,"XLNetTokenizer"),JE.forEach(t),Vv=n(Na,`. Based on
`),Kr=a(Na,"A",{href:!0,rel:!0});var zE=r(Kr);Sv=n(zE,"SentencePiece"),zE.forEach(t),Pv=n(Na,"."),Na.forEach(t),Ov=h(Jt),el=a(Jt,"P",{});var L_=r(el);Dv=n(L_,"This tokenizer inherits from "),pp=a(L_,"A",{href:!0});var UE=r(pp);Qv=n(UE,"PreTrainedTokenizer"),UE.forEach(t),Yv=n(L_,` which contains most of the main methods. Users should refer to
this superclass for more information regarding those methods.`),L_.forEach(t),Hv=h(Jt),Wo=a(Jt,"DIV",{class:!0});var rh=r(Wo);k(tl.$$.fragment,rh),Kv=h(rh),Ah=a(rh,"P",{});var IE=r(Ah);ek=n(IE,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An XLM-RoBERTa sequence has the following format:`),IE.forEach(t),tk=h(rh),ol=a(rh,"UL",{});var X_=r(ol);hp=a(X_,"LI",{});var kX=r(hp);ok=n(kX,"single sequence: "),Gh=a(kX,"CODE",{});var NE=r(Gh);nk=n(NE,"<s> X </s>"),NE.forEach(t),kX.forEach(t),sk=h(X_),up=a(X_,"LI",{});var TX=r(up);ak=n(TX,"pair of sequences: "),Vh=a(TX,"CODE",{});var qE=r(Vh);rk=n(qE,"<s> A </s></s> B </s>"),qE.forEach(t),TX.forEach(t),X_.forEach(t),rh.forEach(t),lk=h(Jt),cs=a(Jt,"DIV",{class:!0});var E_=r(cs);k(nl.$$.fragment,E_),ik=h(E_),sl=a(E_,"P",{});var j_=r(sl);dk=n(j_,`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),Sh=a(j_,"CODE",{});var WE=r(Sh);ck=n(WE,"prepare_for_model"),WE.forEach(t),pk=n(j_," method."),j_.forEach(t),E_.forEach(t),hk=h(Jt),ps=a(Jt,"DIV",{class:!0});var C_=r(ps);k(al.$$.fragment,C_),uk=h(C_),Ph=a(C_,"P",{});var BE=r(Ph);mk=n(BE,`Create a mask from the two sequences passed to be used in a sequence-pair classification task. XLM-RoBERTa does
not make use of token type ids, therefore a list of zeros is returned.`),BE.forEach(t),C_.forEach(t),fk=h(Jt),mp=a(Jt,"DIV",{class:!0});var ZE=r(mp);k(rl.$$.fragment,ZE),ZE.forEach(t),Jt.forEach(t),zg=h(l),pn=a(l,"H2",{class:!0});var J_=r(pn);hs=a(J_,"A",{id:!0,class:!0,href:!0});var AE=r(hs);Oh=a(AE,"SPAN",{});var GE=r(Oh);k(ll.$$.fragment,GE),GE.forEach(t),AE.forEach(t),gk=h(J_),Dh=a(J_,"SPAN",{});var VE=r(Dh);_k=n(VE,"XLMRobertaTokenizerFast"),VE.forEach(t),J_.forEach(t),Ug=h(l),bt=a(l,"DIV",{class:!0});var Oo=r(bt);k(il.$$.fragment,Oo),bk=h(Oo),Gt=a(Oo,"P",{});var Do=r(Gt);Mk=n(Do,"Construct a \u201Cfast\u201D XLM-RoBERTa tokenizer (backed by HuggingFace\u2019s "),Qh=a(Do,"EM",{});var SE=r(Qh);yk=n(SE,"tokenizers"),SE.forEach(t),vk=n(Do,` library). Adapted from
`),fp=a(Do,"A",{href:!0});var PE=r(fp);kk=n(PE,"RobertaTokenizer"),PE.forEach(t),Tk=n(Do," and "),gp=a(Do,"A",{href:!0});var OE=r(gp);wk=n(OE,"XLNetTokenizer"),OE.forEach(t),Fk=n(Do,`. Based on
`),dl=a(Do,"A",{href:!0,rel:!0});var DE=r(dl);$k=n(DE,"BPE"),DE.forEach(t),Rk=n(Do,"."),Do.forEach(t),xk=h(Oo),cl=a(Oo,"P",{});var z_=r(cl);Lk=n(z_,"This tokenizer inherits from "),_p=a(z_,"A",{href:!0});var QE=r(_p);Xk=n(QE,"PreTrainedTokenizerFast"),QE.forEach(t),Ek=n(z_,` which contains most of the main methods. Users should
refer to this superclass for more information regarding those methods.`),z_.forEach(t),jk=h(Oo),Bo=a(Oo,"DIV",{class:!0});var lh=r(Bo);k(pl.$$.fragment,lh),Ck=h(lh),Yh=a(lh,"P",{});var YE=r(Yh);Jk=n(YE,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An XLM-RoBERTa sequence has the following format:`),YE.forEach(t),zk=h(lh),hl=a(lh,"UL",{});var U_=r(hl);bp=a(U_,"LI",{});var wX=r(bp);Uk=n(wX,"single sequence: "),Hh=a(wX,"CODE",{});var HE=r(Hh);Ik=n(HE,"<s> X </s>"),HE.forEach(t),wX.forEach(t),Nk=h(U_),Mp=a(U_,"LI",{});var FX=r(Mp);qk=n(FX,"pair of sequences: "),Kh=a(FX,"CODE",{});var KE=r(Kh);Wk=n(KE,"<s> A </s></s> B </s>"),KE.forEach(t),FX.forEach(t),U_.forEach(t),lh.forEach(t),Bk=h(Oo),us=a(Oo,"DIV",{class:!0});var I_=r(us);k(ul.$$.fragment,I_),Zk=h(I_),eu=a(I_,"P",{});var e4=r(eu);Ak=n(e4,`Create a mask from the two sequences passed to be used in a sequence-pair classification task. XLM-RoBERTa does
not make use of token type ids, therefore a list of zeros is returned.`),e4.forEach(t),I_.forEach(t),Oo.forEach(t),Ig=h(l),hn=a(l,"H2",{class:!0});var N_=r(hn);ms=a(N_,"A",{id:!0,class:!0,href:!0});var t4=r(ms);tu=a(t4,"SPAN",{});var o4=r(tu);k(ml.$$.fragment,o4),o4.forEach(t),t4.forEach(t),Gk=h(N_),ou=a(N_,"SPAN",{});var n4=r(ou);Vk=n(n4,"XLMRobertaModel"),n4.forEach(t),N_.forEach(t),Ng=h(l),Ke=a(l,"DIV",{class:!0});var _t=r(Ke);k(fl.$$.fragment,_t),Sk=h(_t),nu=a(_t,"P",{});var s4=r(nu);Pk=n(s4,"The bare XLM-RoBERTa Model transformer outputting raw hidden-states without any specific head on top."),s4.forEach(t),Ok=h(_t),gl=a(_t,"P",{});var q_=r(gl);Dk=n(q_,"This model inherits from "),yp=a(q_,"A",{href:!0});var a4=r(yp);Qk=n(a4,"PreTrainedModel"),a4.forEach(t),Yk=n(q_,`. 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.)`),q_.forEach(t),Hk=h(_t),_l=a(_t,"P",{});var W_=r(_l);Kk=n(W_,"This model is also a PyTorch "),bl=a(W_,"A",{href:!0,rel:!0});var r4=r(bl);eT=n(r4,"torch.nn.Module"),r4.forEach(t),tT=n(W_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),W_.forEach(t),oT=h(_t),Ml=a(_t,"P",{});var B_=r(Ml);nT=n(B_,`The model can behave as an encoder (with only self-attention) as well as a decoder, in which case a layer of
cross-attention is added between the self-attention layers, following the architecture described in `),su=a(B_,"EM",{});var l4=r(su);sT=n(l4,`Attention is
all you need`),l4.forEach(t),aT=n(B_,`_ by Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz
Kaiser and Illia Polosukhin.`),B_.forEach(t),rT=h(_t),it=a(_t,"P",{});var zt=r(it);lT=n(zt,"To behave as an decoder the model needs to be initialized with the "),au=a(zt,"CODE",{});var i4=r(au);iT=n(i4,"is_decoder"),i4.forEach(t),dT=n(zt,` argument of the configuration set
to `),ru=a(zt,"CODE",{});var d4=r(ru);cT=n(d4,"True"),d4.forEach(t),pT=n(zt,". To be used in a Seq2Seq model, the model needs to initialized with both "),lu=a(zt,"CODE",{});var c4=r(lu);hT=n(c4,"is_decoder"),c4.forEach(t),uT=n(zt,` argument and
`),iu=a(zt,"CODE",{});var p4=r(iu);mT=n(p4,"add_cross_attention"),p4.forEach(t),fT=n(zt," set to "),du=a(zt,"CODE",{});var h4=r(du);gT=n(h4,"True"),h4.forEach(t),_T=n(zt,"; an "),cu=a(zt,"CODE",{});var u4=r(cu);bT=n(u4,"encoder_hidden_states"),u4.forEach(t),MT=n(zt," is then expected as an input to the forward pass."),zt.forEach(t),yT=h(_t),fs=a(_t,"P",{});var _g=r(fs);vT=n(_g,".. _"),pu=a(_g,"EM",{});var m4=r(pu);kT=n(m4,"Attention is all you need"),m4.forEach(t),TT=n(_g,": "),yl=a(_g,"A",{href:!0,rel:!0});var f4=r(yl);wT=n(f4,"https://arxiv.org/abs/1706.03762"),f4.forEach(t),_g.forEach(t),FT=h(_t),St=a(_t,"DIV",{class:!0});var qa=r(St);k(vl.$$.fragment,qa),$T=h(qa),un=a(qa,"P",{});var ih=r(un);RT=n(ih,"The "),vp=a(ih,"A",{href:!0});var g4=r(vp);xT=n(g4,"XLMRobertaModel"),g4.forEach(t),LT=n(ih," forward method, overrides the "),hu=a(ih,"CODE",{});var _4=r(hu);XT=n(_4,"__call__"),_4.forEach(t),ET=n(ih," special method."),ih.forEach(t),jT=h(qa),k(gs.$$.fragment,qa),CT=h(qa),k(_s.$$.fragment,qa),qa.forEach(t),_t.forEach(t),qg=h(l),mn=a(l,"H2",{class:!0});var Z_=r(mn);bs=a(Z_,"A",{id:!0,class:!0,href:!0});var b4=r(bs);uu=a(b4,"SPAN",{});var M4=r(uu);k(kl.$$.fragment,M4),M4.forEach(t),b4.forEach(t),JT=h(Z_),mu=a(Z_,"SPAN",{});var y4=r(mu);zT=n(y4,"XLMRobertaForCausalLM"),y4.forEach(t),Z_.forEach(t),Wg=h(l),Mt=a(l,"DIV",{class:!0});var Qo=r(Mt);k(Tl.$$.fragment,Qo),UT=h(Qo),wl=a(Qo,"P",{});var A_=r(wl);IT=n(A_,"XLM-RoBERTa Model with a "),fu=a(A_,"CODE",{});var v4=r(fu);NT=n(v4,"language modeling"),v4.forEach(t),qT=n(A_," head on top for CLM fine-tuning."),A_.forEach(t),WT=h(Qo),Fl=a(Qo,"P",{});var G_=r(Fl);BT=n(G_,"This model inherits from "),kp=a(G_,"A",{href:!0});var k4=r(kp);ZT=n(k4,"PreTrainedModel"),k4.forEach(t),AT=n(G_,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),G_.forEach(t),GT=h(Qo),$l=a(Qo,"P",{});var V_=r($l);VT=n(V_,"This model is also a PyTorch "),Rl=a(V_,"A",{href:!0,rel:!0});var T4=r(Rl);ST=n(T4,"torch.nn.Module"),T4.forEach(t),PT=n(V_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),V_.forEach(t),OT=h(Qo),Pt=a(Qo,"DIV",{class:!0});var Wa=r(Pt);k(xl.$$.fragment,Wa),DT=h(Wa),fn=a(Wa,"P",{});var dh=r(fn);QT=n(dh,"The "),Tp=a(dh,"A",{href:!0});var w4=r(Tp);YT=n(w4,"XLMRobertaForCausalLM"),w4.forEach(t),HT=n(dh," forward method, overrides the "),gu=a(dh,"CODE",{});var F4=r(gu);KT=n(F4,"__call__"),F4.forEach(t),ew=n(dh," special method."),dh.forEach(t),tw=h(Wa),k(Ms.$$.fragment,Wa),ow=h(Wa),k(ys.$$.fragment,Wa),Wa.forEach(t),Qo.forEach(t),Bg=h(l),gn=a(l,"H2",{class:!0});var S_=r(gn);vs=a(S_,"A",{id:!0,class:!0,href:!0});var $4=r(vs);_u=a($4,"SPAN",{});var R4=r(_u);k(Ll.$$.fragment,R4),R4.forEach(t),$4.forEach(t),nw=h(S_),bu=a(S_,"SPAN",{});var x4=r(bu);sw=n(x4,"XLMRobertaForMaskedLM"),x4.forEach(t),S_.forEach(t),Zg=h(l),yt=a(l,"DIV",{class:!0});var Yo=r(yt);k(Xl.$$.fragment,Yo),aw=h(Yo),El=a(Yo,"P",{});var P_=r(El);rw=n(P_,"XLM-RoBERTa Model with a "),Mu=a(P_,"CODE",{});var L4=r(Mu);lw=n(L4,"language modeling"),L4.forEach(t),iw=n(P_," head on top."),P_.forEach(t),dw=h(Yo),jl=a(Yo,"P",{});var O_=r(jl);cw=n(O_,"This model inherits from "),wp=a(O_,"A",{href:!0});var X4=r(wp);pw=n(X4,"PreTrainedModel"),X4.forEach(t),hw=n(O_,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),O_.forEach(t),uw=h(Yo),Cl=a(Yo,"P",{});var D_=r(Cl);mw=n(D_,"This model is also a PyTorch "),Jl=a(D_,"A",{href:!0,rel:!0});var E4=r(Jl);fw=n(E4,"torch.nn.Module"),E4.forEach(t),gw=n(D_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),D_.forEach(t),_w=h(Yo),Ot=a(Yo,"DIV",{class:!0});var Ba=r(Ot);k(zl.$$.fragment,Ba),bw=h(Ba),_n=a(Ba,"P",{});var ch=r(_n);Mw=n(ch,"The "),Fp=a(ch,"A",{href:!0});var j4=r(Fp);yw=n(j4,"XLMRobertaForMaskedLM"),j4.forEach(t),vw=n(ch," forward method, overrides the "),yu=a(ch,"CODE",{});var C4=r(yu);kw=n(C4,"__call__"),C4.forEach(t),Tw=n(ch," special method."),ch.forEach(t),ww=h(Ba),k(ks.$$.fragment,Ba),Fw=h(Ba),k(Ts.$$.fragment,Ba),Ba.forEach(t),Yo.forEach(t),Ag=h(l),bn=a(l,"H2",{class:!0});var Q_=r(bn);ws=a(Q_,"A",{id:!0,class:!0,href:!0});var J4=r(ws);vu=a(J4,"SPAN",{});var z4=r(vu);k(Ul.$$.fragment,z4),z4.forEach(t),J4.forEach(t),$w=h(Q_),ku=a(Q_,"SPAN",{});var U4=r(ku);Rw=n(U4,"XLMRobertaForSequenceClassification"),U4.forEach(t),Q_.forEach(t),Gg=h(l),vt=a(l,"DIV",{class:!0});var Ho=r(vt);k(Il.$$.fragment,Ho),xw=h(Ho),Tu=a(Ho,"P",{});var I4=r(Tu);Lw=n(I4,`XLM-RoBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),I4.forEach(t),Xw=h(Ho),Nl=a(Ho,"P",{});var Y_=r(Nl);Ew=n(Y_,"This model inherits from "),$p=a(Y_,"A",{href:!0});var N4=r($p);jw=n(N4,"PreTrainedModel"),N4.forEach(t),Cw=n(Y_,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Y_.forEach(t),Jw=h(Ho),ql=a(Ho,"P",{});var H_=r(ql);zw=n(H_,"This model is also a PyTorch "),Wl=a(H_,"A",{href:!0,rel:!0});var q4=r(Wl);Uw=n(q4,"torch.nn.Module"),q4.forEach(t),Iw=n(H_,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),H_.forEach(t),Nw=h(Ho),Lt=a(Ho,"DIV",{class:!0});var Ko=r(Lt);k(Bl.$$.fragment,Ko),qw=h(Ko),Mn=a(Ko,"P",{});var ph=r(Mn);Ww=n(ph,"The "),Rp=a(ph,"A",{href:!0});var W4=r(Rp);Bw=n(W4,"XLMRobertaForSequenceClassification"),W4.forEach(t),Zw=n(ph," forward method, overrides the "),wu=a(ph,"CODE",{});var B4=r(wu);Aw=n(B4,"__call__"),B4.forEach(t),Gw=n(ph," special method."),ph.forEach(t),Vw=h(Ko),k(Fs.$$.fragment,Ko),Sw=h(Ko),k($s.$$.fragment,Ko),Pw=h(Ko),k(Rs.$$.fragment,Ko),Ko.forEach(t),Ho.forEach(t),Vg=h(l),yn=a(l,"H2",{class:!0});var K_=r(yn);xs=a(K_,"A",{id:!0,class:!0,href:!0});var Z4=r(xs);Fu=a(Z4,"SPAN",{});var A4=r(Fu);k(Zl.$$.fragment,A4),A4.forEach(t),Z4.forEach(t),Ow=h(K_),$u=a(K_,"SPAN",{});var G4=r($u);Dw=n(G4,"XLMRobertaForMultipleChoice"),G4.forEach(t),K_.forEach(t),Sg=h(l),kt=a(l,"DIV",{class:!0});var en=r(kt);k(Al.$$.fragment,en),Qw=h(en),Ru=a(en,"P",{});var V4=r(Ru);Yw=n(V4,`XLM-RoBERTa 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.`),V4.forEach(t),Hw=h(en),Gl=a(en,"P",{});var eb=r(Gl);Kw=n(eb,"This model inherits from "),xp=a(eb,"A",{href:!0});var S4=r(xp);e2=n(S4,"PreTrainedModel"),S4.forEach(t),t2=n(eb,`. 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.)`),eb.forEach(t),o2=h(en),Vl=a(en,"P",{});var tb=r(Vl);n2=n(tb,"This model is also a PyTorch "),Sl=a(tb,"A",{href:!0,rel:!0});var P4=r(Sl);s2=n(P4,"torch.nn.Module"),P4.forEach(t),a2=n(tb,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),tb.forEach(t),r2=h(en),Dt=a(en,"DIV",{class:!0});var Za=r(Dt);k(Pl.$$.fragment,Za),l2=h(Za),vn=a(Za,"P",{});var hh=r(vn);i2=n(hh,"The "),Lp=a(hh,"A",{href:!0});var O4=r(Lp);d2=n(O4,"XLMRobertaForMultipleChoice"),O4.forEach(t),c2=n(hh," forward method, overrides the "),xu=a(hh,"CODE",{});var D4=r(xu);p2=n(D4,"__call__"),D4.forEach(t),h2=n(hh," special method."),hh.forEach(t),u2=h(Za),k(Ls.$$.fragment,Za),m2=h(Za),k(Xs.$$.fragment,Za),Za.forEach(t),en.forEach(t),Pg=h(l),kn=a(l,"H2",{class:!0});var ob=r(kn);Es=a(ob,"A",{id:!0,class:!0,href:!0});var Q4=r(Es);Lu=a(Q4,"SPAN",{});var Y4=r(Lu);k(Ol.$$.fragment,Y4),Y4.forEach(t),Q4.forEach(t),f2=h(ob),Xu=a(ob,"SPAN",{});var H4=r(Xu);g2=n(H4,"XLMRobertaForTokenClassification"),H4.forEach(t),ob.forEach(t),Og=h(l),Tt=a(l,"DIV",{class:!0});var tn=r(Tt);k(Dl.$$.fragment,tn),_2=h(tn),Eu=a(tn,"P",{});var K4=r(Eu);b2=n(K4,`XLM-RoBERTa 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.`),K4.forEach(t),M2=h(tn),Ql=a(tn,"P",{});var nb=r(Ql);y2=n(nb,"This model inherits from "),Xp=a(nb,"A",{href:!0});var e3=r(Xp);v2=n(e3,"PreTrainedModel"),e3.forEach(t),k2=n(nb,`. 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.)`),nb.forEach(t),T2=h(tn),Yl=a(tn,"P",{});var sb=r(Yl);w2=n(sb,"This model is also a PyTorch "),Hl=a(sb,"A",{href:!0,rel:!0});var t3=r(Hl);F2=n(t3,"torch.nn.Module"),t3.forEach(t),$2=n(sb,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),sb.forEach(t),R2=h(tn),Qt=a(tn,"DIV",{class:!0});var Aa=r(Qt);k(Kl.$$.fragment,Aa),x2=h(Aa),Tn=a(Aa,"P",{});var uh=r(Tn);L2=n(uh,"The "),Ep=a(uh,"A",{href:!0});var o3=r(Ep);X2=n(o3,"XLMRobertaForTokenClassification"),o3.forEach(t),E2=n(uh," forward method, overrides the "),ju=a(uh,"CODE",{});var n3=r(ju);j2=n(n3,"__call__"),n3.forEach(t),C2=n(uh," special method."),uh.forEach(t),J2=h(Aa),k(js.$$.fragment,Aa),z2=h(Aa),k(Cs.$$.fragment,Aa),Aa.forEach(t),tn.forEach(t),Dg=h(l),wn=a(l,"H2",{class:!0});var ab=r(wn);Js=a(ab,"A",{id:!0,class:!0,href:!0});var s3=r(Js);Cu=a(s3,"SPAN",{});var a3=r(Cu);k(ei.$$.fragment,a3),a3.forEach(t),s3.forEach(t),U2=h(ab),Ju=a(ab,"SPAN",{});var r3=r(Ju);I2=n(r3,"XLMRobertaForQuestionAnswering"),r3.forEach(t),ab.forEach(t),Qg=h(l),wt=a(l,"DIV",{class:!0});var on=r(wt);k(ti.$$.fragment,on),N2=h(on),Fn=a(on,"P",{});var mh=r(Fn);q2=n(mh,`XLM-RoBERTa 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 `),zu=a(mh,"CODE",{});var l3=r(zu);W2=n(l3,"span start logits"),l3.forEach(t),B2=n(mh," and "),Uu=a(mh,"CODE",{});var i3=r(Uu);Z2=n(i3,"span end logits"),i3.forEach(t),A2=n(mh,")."),mh.forEach(t),G2=h(on),oi=a(on,"P",{});var rb=r(oi);V2=n(rb,"This model inherits from "),jp=a(rb,"A",{href:!0});var d3=r(jp);S2=n(d3,"PreTrainedModel"),d3.forEach(t),P2=n(rb,`. 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.)`),rb.forEach(t),O2=h(on),ni=a(on,"P",{});var lb=r(ni);D2=n(lb,"This model is also a PyTorch "),si=a(lb,"A",{href:!0,rel:!0});var c3=r(si);Q2=n(c3,"torch.nn.Module"),c3.forEach(t),Y2=n(lb,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),lb.forEach(t),H2=h(on),Yt=a(on,"DIV",{class:!0});var Ga=r(Yt);k(ai.$$.fragment,Ga),K2=h(Ga),$n=a(Ga,"P",{});var fh=r($n);e1=n(fh,"The "),Cp=a(fh,"A",{href:!0});var p3=r(Cp);t1=n(p3,"XLMRobertaForQuestionAnswering"),p3.forEach(t),o1=n(fh," forward method, overrides the "),Iu=a(fh,"CODE",{});var h3=r(Iu);n1=n(h3,"__call__"),h3.forEach(t),s1=n(fh," special method."),fh.forEach(t),a1=h(Ga),k(zs.$$.fragment,Ga),r1=h(Ga),k(Us.$$.fragment,Ga),Ga.forEach(t),on.forEach(t),Yg=h(l),Rn=a(l,"H2",{class:!0});var ib=r(Rn);Is=a(ib,"A",{id:!0,class:!0,href:!0});var u3=r(Is);Nu=a(u3,"SPAN",{});var m3=r(Nu);k(ri.$$.fragment,m3),m3.forEach(t),u3.forEach(t),l1=h(ib),qu=a(ib,"SPAN",{});var f3=r(qu);i1=n(f3,"TFXLMRobertaModel"),f3.forEach(t),ib.forEach(t),Hg=h(l),dt=a(l,"DIV",{class:!0});var io=r(dt);k(li.$$.fragment,io),d1=h(io),Wu=a(io,"P",{});var g3=r(Wu);c1=n(g3,"The bare XLM RoBERTa Model transformer outputting raw hidden-states without any specific head on top."),g3.forEach(t),p1=h(io),ii=a(io,"P",{});var db=r(ii);h1=n(db,"This model inherits from "),Jp=a(db,"A",{href:!0});var _3=r(Jp);u1=n(_3,"TFPreTrainedModel"),_3.forEach(t),m1=n(db,`. 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.)`),db.forEach(t),f1=h(io),di=a(io,"P",{});var cb=r(di);g1=n(cb,"This model is also a "),ci=a(cb,"A",{href:!0,rel:!0});var b3=r(ci);_1=n(b3,"tf.keras.Model"),b3.forEach(t),b1=n(cb,` 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.`),cb.forEach(t),M1=h(io),k(Ns.$$.fragment,io),y1=h(io),Ht=a(io,"DIV",{class:!0});var Va=r(Ht);k(pi.$$.fragment,Va),v1=h(Va),xn=a(Va,"P",{});var gh=r(xn);k1=n(gh,"The "),zp=a(gh,"A",{href:!0});var M3=r(zp);T1=n(M3,"TFXLMRobertaModel"),M3.forEach(t),w1=n(gh," forward method, overrides the "),Bu=a(gh,"CODE",{});var y3=r(Bu);F1=n(y3,"__call__"),y3.forEach(t),$1=n(gh," special method."),gh.forEach(t),R1=h(Va),k(qs.$$.fragment,Va),x1=h(Va),k(Ws.$$.fragment,Va),Va.forEach(t),io.forEach(t),Kg=h(l),Ln=a(l,"H2",{class:!0});var pb=r(Ln);Bs=a(pb,"A",{id:!0,class:!0,href:!0});var v3=r(Bs);Zu=a(v3,"SPAN",{});var k3=r(Zu);k(hi.$$.fragment,k3),k3.forEach(t),v3.forEach(t),L1=h(pb),Au=a(pb,"SPAN",{});var T3=r(Au);X1=n(T3,"TFXLMRobertaForCausalLM"),T3.forEach(t),pb.forEach(t),e_=h(l),ct=a(l,"DIV",{class:!0});var co=r(ct);k(ui.$$.fragment,co),E1=h(co),mi=a(co,"P",{});var hb=r(mi);j1=n(hb,"XLM-RoBERTa Model with a "),Gu=a(hb,"CODE",{});var w3=r(Gu);C1=n(w3,"language modeling"),w3.forEach(t),J1=n(hb," head on top for CLM fine-tuning."),hb.forEach(t),z1=h(co),fi=a(co,"P",{});var ub=r(fi);U1=n(ub,"This model inherits from "),Up=a(ub,"A",{href:!0});var F3=r(Up);I1=n(F3,"TFPreTrainedModel"),F3.forEach(t),N1=n(ub,`. 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.)`),ub.forEach(t),q1=h(co),gi=a(co,"P",{});var mb=r(gi);W1=n(mb,"This model is also a "),_i=a(mb,"A",{href:!0,rel:!0});var $3=r(_i);B1=n($3,"tf.keras.Model"),$3.forEach(t),Z1=n(mb,` 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.`),mb.forEach(t),A1=h(co),k(Zs.$$.fragment,co),G1=h(co),Kt=a(co,"DIV",{class:!0});var Sa=r(Kt);k(bi.$$.fragment,Sa),V1=h(Sa),Xn=a(Sa,"P",{});var _h=r(Xn);S1=n(_h,"The "),Ip=a(_h,"A",{href:!0});var R3=r(Ip);P1=n(R3,"TFXLMRobertaForCausalLM"),R3.forEach(t),O1=n(_h," forward method, overrides the "),Vu=a(_h,"CODE",{});var x3=r(Vu);D1=n(x3,"__call__"),x3.forEach(t),Q1=n(_h," special method."),_h.forEach(t),Y1=h(Sa),k(As.$$.fragment,Sa),H1=h(Sa),k(Gs.$$.fragment,Sa),Sa.forEach(t),co.forEach(t),t_=h(l),En=a(l,"H2",{class:!0});var fb=r(En);Vs=a(fb,"A",{id:!0,class:!0,href:!0});var L3=r(Vs);Su=a(L3,"SPAN",{});var X3=r(Su);k(Mi.$$.fragment,X3),X3.forEach(t),L3.forEach(t),K1=h(fb),Pu=a(fb,"SPAN",{});var E3=r(Pu);e0=n(E3,"TFXLMRobertaForMaskedLM"),E3.forEach(t),fb.forEach(t),o_=h(l),pt=a(l,"DIV",{class:!0});var po=r(pt);k(yi.$$.fragment,po),t0=h(po),vi=a(po,"P",{});var gb=r(vi);o0=n(gb,"XLM RoBERTa Model with a "),Ou=a(gb,"CODE",{});var j3=r(Ou);n0=n(j3,"language modeling"),j3.forEach(t),s0=n(gb," head on top."),gb.forEach(t),a0=h(po),ki=a(po,"P",{});var _b=r(ki);r0=n(_b,"This model inherits from "),Np=a(_b,"A",{href:!0});var C3=r(Np);l0=n(C3,"TFPreTrainedModel"),C3.forEach(t),i0=n(_b,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),_b.forEach(t),d0=h(po),Ti=a(po,"P",{});var bb=r(Ti);c0=n(bb,"This model is also a "),wi=a(bb,"A",{href:!0,rel:!0});var J3=r(wi);p0=n(J3,"tf.keras.Model"),J3.forEach(t),h0=n(bb,` 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.`),bb.forEach(t),u0=h(po),k(Ss.$$.fragment,po),m0=h(po),Xt=a(po,"DIV",{class:!0});var nn=r(Xt);k(Fi.$$.fragment,nn),f0=h(nn),jn=a(nn,"P",{});var bh=r(jn);g0=n(bh,"The "),qp=a(bh,"A",{href:!0});var z3=r(qp);_0=n(z3,"TFXLMRobertaForMaskedLM"),z3.forEach(t),b0=n(bh," forward method, overrides the "),Du=a(bh,"CODE",{});var U3=r(Du);M0=n(U3,"__call__"),U3.forEach(t),y0=n(bh," special method."),bh.forEach(t),v0=h(nn),k(Ps.$$.fragment,nn),k0=h(nn),k(Os.$$.fragment,nn),T0=h(nn),k(Ds.$$.fragment,nn),nn.forEach(t),po.forEach(t),n_=h(l),Cn=a(l,"H2",{class:!0});var Mb=r(Cn);Qs=a(Mb,"A",{id:!0,class:!0,href:!0});var I3=r(Qs);Qu=a(I3,"SPAN",{});var N3=r(Qu);k($i.$$.fragment,N3),N3.forEach(t),I3.forEach(t),w0=h(Mb),Yu=a(Mb,"SPAN",{});var q3=r(Yu);F0=n(q3,"TFXLMRobertaForSequenceClassification"),q3.forEach(t),Mb.forEach(t),s_=h(l),ht=a(l,"DIV",{class:!0});var ho=r(ht);k(Ri.$$.fragment,ho),$0=h(ho),Hu=a(ho,"P",{});var W3=r(Hu);R0=n(W3,`XLM RoBERTa Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),W3.forEach(t),x0=h(ho),xi=a(ho,"P",{});var yb=r(xi);L0=n(yb,"This model inherits from "),Wp=a(yb,"A",{href:!0});var B3=r(Wp);X0=n(B3,"TFPreTrainedModel"),B3.forEach(t),E0=n(yb,`. 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.)`),yb.forEach(t),j0=h(ho),Li=a(ho,"P",{});var vb=r(Li);C0=n(vb,"This model is also a "),Xi=a(vb,"A",{href:!0,rel:!0});var Z3=r(Xi);J0=n(Z3,"tf.keras.Model"),Z3.forEach(t),z0=n(vb,` 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.`),vb.forEach(t),U0=h(ho),k(Ys.$$.fragment,ho),I0=h(ho),Et=a(ho,"DIV",{class:!0});var sn=r(Et);k(Ei.$$.fragment,sn),N0=h(sn),Jn=a(sn,"P",{});var Mh=r(Jn);q0=n(Mh,"The "),Bp=a(Mh,"A",{href:!0});var A3=r(Bp);W0=n(A3,"TFXLMRobertaForSequenceClassification"),A3.forEach(t),B0=n(Mh," forward method, overrides the "),Ku=a(Mh,"CODE",{});var G3=r(Ku);Z0=n(G3,"__call__"),G3.forEach(t),A0=n(Mh," special method."),Mh.forEach(t),G0=h(sn),k(Hs.$$.fragment,sn),V0=h(sn),k(Ks.$$.fragment,sn),S0=h(sn),k(ea.$$.fragment,sn),sn.forEach(t),ho.forEach(t),a_=h(l),zn=a(l,"H2",{class:!0});var kb=r(zn);ta=a(kb,"A",{id:!0,class:!0,href:!0});var V3=r(ta);em=a(V3,"SPAN",{});var S3=r(em);k(ji.$$.fragment,S3),S3.forEach(t),V3.forEach(t),P0=h(kb),tm=a(kb,"SPAN",{});var P3=r(tm);O0=n(P3,"TFXLMRobertaForMultipleChoice"),P3.forEach(t),kb.forEach(t),r_=h(l),ut=a(l,"DIV",{class:!0});var uo=r(ut);k(Ci.$$.fragment,uo),D0=h(uo),om=a(uo,"P",{});var O3=r(om);Q0=n(O3,`XLM Roberta 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.`),O3.forEach(t),Y0=h(uo),Ji=a(uo,"P",{});var Tb=r(Ji);H0=n(Tb,"This model inherits from "),Zp=a(Tb,"A",{href:!0});var D3=r(Zp);K0=n(D3,"TFPreTrainedModel"),D3.forEach(t),eF=n(Tb,`. 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.)`),Tb.forEach(t),tF=h(uo),zi=a(uo,"P",{});var wb=r(zi);oF=n(wb,"This model is also a "),Ui=a(wb,"A",{href:!0,rel:!0});var Q3=r(Ui);nF=n(Q3,"tf.keras.Model"),Q3.forEach(t),sF=n(wb,` 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.`),wb.forEach(t),aF=h(uo),k(oa.$$.fragment,uo),rF=h(uo),eo=a(uo,"DIV",{class:!0});var Pa=r(eo);k(Ii.$$.fragment,Pa),lF=h(Pa),Un=a(Pa,"P",{});var yh=r(Un);iF=n(yh,"The "),Ap=a(yh,"A",{href:!0});var Y3=r(Ap);dF=n(Y3,"TFXLMRobertaForMultipleChoice"),Y3.forEach(t),cF=n(yh," forward method, overrides the "),nm=a(yh,"CODE",{});var H3=r(nm);pF=n(H3,"__call__"),H3.forEach(t),hF=n(yh," special method."),yh.forEach(t),uF=h(Pa),k(na.$$.fragment,Pa),mF=h(Pa),k(sa.$$.fragment,Pa),Pa.forEach(t),uo.forEach(t),l_=h(l),In=a(l,"H2",{class:!0});var Fb=r(In);aa=a(Fb,"A",{id:!0,class:!0,href:!0});var K3=r(aa);sm=a(K3,"SPAN",{});var ej=r(sm);k(Ni.$$.fragment,ej),ej.forEach(t),K3.forEach(t),fF=h(Fb),am=a(Fb,"SPAN",{});var tj=r(am);gF=n(tj,"TFXLMRobertaForTokenClassification"),tj.forEach(t),Fb.forEach(t),i_=h(l),mt=a(l,"DIV",{class:!0});var mo=r(mt);k(qi.$$.fragment,mo),_F=h(mo),rm=a(mo,"P",{});var oj=r(rm);bF=n(oj,`XLM RoBERTa 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.`),oj.forEach(t),MF=h(mo),Wi=a(mo,"P",{});var $b=r(Wi);yF=n($b,"This model inherits from "),Gp=a($b,"A",{href:!0});var nj=r(Gp);vF=n(nj,"TFPreTrainedModel"),nj.forEach(t),kF=n($b,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),$b.forEach(t),TF=h(mo),Bi=a(mo,"P",{});var Rb=r(Bi);wF=n(Rb,"This model is also a "),Zi=a(Rb,"A",{href:!0,rel:!0});var sj=r(Zi);FF=n(sj,"tf.keras.Model"),sj.forEach(t),$F=n(Rb,` 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.`),Rb.forEach(t),RF=h(mo),k(ra.$$.fragment,mo),xF=h(mo),jt=a(mo,"DIV",{class:!0});var an=r(jt);k(Ai.$$.fragment,an),LF=h(an),Nn=a(an,"P",{});var vh=r(Nn);XF=n(vh,"The "),Vp=a(vh,"A",{href:!0});var aj=r(Vp);EF=n(aj,"TFXLMRobertaForTokenClassification"),aj.forEach(t),jF=n(vh," forward method, overrides the "),lm=a(vh,"CODE",{});var rj=r(lm);CF=n(rj,"__call__"),rj.forEach(t),JF=n(vh," special method."),vh.forEach(t),zF=h(an),k(la.$$.fragment,an),UF=h(an),k(ia.$$.fragment,an),IF=h(an),k(da.$$.fragment,an),an.forEach(t),mo.forEach(t),d_=h(l),qn=a(l,"H2",{class:!0});var xb=r(qn);ca=a(xb,"A",{id:!0,class:!0,href:!0});var lj=r(ca);im=a(lj,"SPAN",{});var ij=r(im);k(Gi.$$.fragment,ij),ij.forEach(t),lj.forEach(t),NF=h(xb),dm=a(xb,"SPAN",{});var dj=r(dm);qF=n(dj,"TFXLMRobertaForQuestionAnswering"),dj.forEach(t),xb.forEach(t),c_=h(l),ft=a(l,"DIV",{class:!0});var fo=r(ft);k(Vi.$$.fragment,fo),WF=h(fo),Wn=a(fo,"P",{});var kh=r(Wn);BF=n(kh,`XLM RoBERTa 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 `),cm=a(kh,"CODE",{});var cj=r(cm);ZF=n(cj,"span start logits"),cj.forEach(t),AF=n(kh," and "),pm=a(kh,"CODE",{});var pj=r(pm);GF=n(pj,"span end logits"),pj.forEach(t),VF=n(kh,")."),kh.forEach(t),SF=h(fo),Si=a(fo,"P",{});var Lb=r(Si);PF=n(Lb,"This model inherits from "),Sp=a(Lb,"A",{href:!0});var hj=r(Sp);OF=n(hj,"TFPreTrainedModel"),hj.forEach(t),DF=n(Lb,`. 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.)`),Lb.forEach(t),QF=h(fo),Pi=a(fo,"P",{});var Xb=r(Pi);YF=n(Xb,"This model is also a "),Oi=a(Xb,"A",{href:!0,rel:!0});var uj=r(Oi);HF=n(uj,"tf.keras.Model"),uj.forEach(t),KF=n(Xb,` 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.`),Xb.forEach(t),e$=h(fo),k(pa.$$.fragment,fo),t$=h(fo),Ct=a(fo,"DIV",{class:!0});var rn=r(Ct);k(Di.$$.fragment,rn),o$=h(rn),Bn=a(rn,"P",{});var Th=r(Bn);n$=n(Th,"The "),Pp=a(Th,"A",{href:!0});var mj=r(Pp);s$=n(mj,"TFXLMRobertaForQuestionAnswering"),mj.forEach(t),a$=n(Th," forward method, overrides the "),hm=a(Th,"CODE",{});var fj=r(hm);r$=n(fj,"__call__"),fj.forEach(t),l$=n(Th," special method."),Th.forEach(t),i$=h(rn),k(ha.$$.fragment,rn),d$=h(rn),k(ua.$$.fragment,rn),c$=h(rn),k(ma.$$.fragment,rn),rn.forEach(t),fo.forEach(t),p_=h(l),Zn=a(l,"H2",{class:!0});var Eb=r(Zn);fa=a(Eb,"A",{id:!0,class:!0,href:!0});var gj=r(fa);um=a(gj,"SPAN",{});var _j=r(um);k(Qi.$$.fragment,_j),_j.forEach(t),gj.forEach(t),p$=h(Eb),mm=a(Eb,"SPAN",{});var bj=r(mm);h$=n(bj,"FlaxXLMRobertaModel"),bj.forEach(t),Eb.forEach(t),h_=h(l),tt=a(l,"DIV",{class:!0});var Ut=r(tt);k(Yi.$$.fragment,Ut),u$=h(Ut),fm=a(Ut,"P",{});var Mj=r(fm);m$=n(Mj,"The bare XLM RoBERTa Model transformer outputting raw hidden-states without any specific head on top."),Mj.forEach(t),f$=h(Ut),Hi=a(Ut,"P",{});var jb=r(Hi);g$=n(jb,"This model inherits from "),Op=a(jb,"A",{href:!0});var yj=r(Op);_$=n(yj,"FlaxPreTrainedModel"),yj.forEach(t),b$=n(jb,`. 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)`),jb.forEach(t),M$=h(Ut),Ki=a(Ut,"P",{});var Cb=r(Ki);y$=n(Cb,"This model is also a Flax Linen "),ed=a(Cb,"A",{href:!0,rel:!0});var vj=r(ed);v$=n(vj,"flax.linen.Module"),vj.forEach(t),k$=n(Cb,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Cb.forEach(t),T$=h(Ut),gm=a(Ut,"P",{});var kj=r(gm);w$=n(kj,"Finally, this model supports inherent JAX features such as:"),kj.forEach(t),F$=h(Ut),bo=a(Ut,"UL",{});var Oa=r(bo);_m=a(Oa,"LI",{});var Tj=r(_m);td=a(Tj,"A",{href:!0,rel:!0});var wj=r(td);$$=n(wj,"Just-In-Time (JIT) compilation"),wj.forEach(t),Tj.forEach(t),R$=h(Oa),bm=a(Oa,"LI",{});var Fj=r(bm);od=a(Fj,"A",{href:!0,rel:!0});var $j=r(od);x$=n($j,"Automatic Differentiation"),$j.forEach(t),Fj.forEach(t),L$=h(Oa),Mm=a(Oa,"LI",{});var Rj=r(Mm);nd=a(Rj,"A",{href:!0,rel:!0});var xj=r(nd);X$=n(xj,"Vectorization"),xj.forEach(t),Rj.forEach(t),E$=h(Oa),ym=a(Oa,"LI",{});var Lj=r(ym);sd=a(Lj,"A",{href:!0,rel:!0});var Xj=r(sd);j$=n(Xj,"Parallelization"),Xj.forEach(t),Lj.forEach(t),Oa.forEach(t),C$=h(Ut),to=a(Ut,"DIV",{class:!0});var Da=r(to);k(ad.$$.fragment,Da),J$=h(Da),An=a(Da,"P",{});var wh=r(An);z$=n(wh,"The "),vm=a(wh,"CODE",{});var Ej=r(vm);U$=n(Ej,"FlaxXLMRobertaPreTrainedModel"),Ej.forEach(t),I$=n(wh," forward method, overrides the "),km=a(wh,"CODE",{});var jj=r(km);N$=n(jj,"__call__"),jj.forEach(t),q$=n(wh," special method."),wh.forEach(t),W$=h(Da),k(ga.$$.fragment,Da),B$=h(Da),k(_a.$$.fragment,Da),Da.forEach(t),Ut.forEach(t),u_=h(l),Gn=a(l,"H2",{class:!0});var Jb=r(Gn);ba=a(Jb,"A",{id:!0,class:!0,href:!0});var Cj=r(ba);Tm=a(Cj,"SPAN",{});var Jj=r(Tm);k(rd.$$.fragment,Jj),Jj.forEach(t),Cj.forEach(t),Z$=h(Jb),wm=a(Jb,"SPAN",{});var zj=r(wm);A$=n(zj,"FlaxXLMRobertaForCausalLM"),zj.forEach(t),Jb.forEach(t),m_=h(l),ot=a(l,"DIV",{class:!0});var It=r(ot);k(ld.$$.fragment,It),G$=h(It),Fm=a(It,"P",{});var Uj=r(Fm);V$=n(Uj,`XLM Roberta Model with a language modeling head on top (a linear layer on top of the hidden-states output) e.g for
autoregressive tasks.`),Uj.forEach(t),S$=h(It),id=a(It,"P",{});var zb=r(id);P$=n(zb,"This model inherits from "),Dp=a(zb,"A",{href:!0});var Ij=r(Dp);O$=n(Ij,"FlaxPreTrainedModel"),Ij.forEach(t),D$=n(zb,`. 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)`),zb.forEach(t),Q$=h(It),dd=a(It,"P",{});var Ub=r(dd);Y$=n(Ub,"This model is also a Flax Linen "),cd=a(Ub,"A",{href:!0,rel:!0});var Nj=r(cd);H$=n(Nj,"flax.linen.Module"),Nj.forEach(t),K$=n(Ub,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Ub.forEach(t),eR=h(It),$m=a(It,"P",{});var qj=r($m);tR=n(qj,"Finally, this model supports inherent JAX features such as:"),qj.forEach(t),oR=h(It),Mo=a(It,"UL",{});var Qa=r(Mo);Rm=a(Qa,"LI",{});var Wj=r(Rm);pd=a(Wj,"A",{href:!0,rel:!0});var Bj=r(pd);nR=n(Bj,"Just-In-Time (JIT) compilation"),Bj.forEach(t),Wj.forEach(t),sR=h(Qa),xm=a(Qa,"LI",{});var Zj=r(xm);hd=a(Zj,"A",{href:!0,rel:!0});var Aj=r(hd);aR=n(Aj,"Automatic Differentiation"),Aj.forEach(t),Zj.forEach(t),rR=h(Qa),Lm=a(Qa,"LI",{});var Gj=r(Lm);ud=a(Gj,"A",{href:!0,rel:!0});var Vj=r(ud);lR=n(Vj,"Vectorization"),Vj.forEach(t),Gj.forEach(t),iR=h(Qa),Xm=a(Qa,"LI",{});var Sj=r(Xm);md=a(Sj,"A",{href:!0,rel:!0});var Pj=r(md);dR=n(Pj,"Parallelization"),Pj.forEach(t),Sj.forEach(t),Qa.forEach(t),cR=h(It),oo=a(It,"DIV",{class:!0});var Ya=r(oo);k(fd.$$.fragment,Ya),pR=h(Ya),Vn=a(Ya,"P",{});var Fh=r(Vn);hR=n(Fh,"The "),Em=a(Fh,"CODE",{});var Oj=r(Em);uR=n(Oj,"FlaxXLMRobertaPreTrainedModel"),Oj.forEach(t),mR=n(Fh," forward method, overrides the "),jm=a(Fh,"CODE",{});var Dj=r(jm);fR=n(Dj,"__call__"),Dj.forEach(t),gR=n(Fh," special method."),Fh.forEach(t),_R=h(Ya),k(Ma.$$.fragment,Ya),bR=h(Ya),k(ya.$$.fragment,Ya),Ya.forEach(t),It.forEach(t),f_=h(l),Sn=a(l,"H2",{class:!0});var Ib=r(Sn);va=a(Ib,"A",{id:!0,class:!0,href:!0});var Qj=r(va);Cm=a(Qj,"SPAN",{});var Yj=r(Cm);k(gd.$$.fragment,Yj),Yj.forEach(t),Qj.forEach(t),MR=h(Ib),Jm=a(Ib,"SPAN",{});var Hj=r(Jm);yR=n(Hj,"FlaxXLMRobertaForMaskedLM"),Hj.forEach(t),Ib.forEach(t),g_=h(l),nt=a(l,"DIV",{class:!0});var Nt=r(nt);k(_d.$$.fragment,Nt),vR=h(Nt),bd=a(Nt,"P",{});var Nb=r(bd);kR=n(Nb,"XLM RoBERTa Model with a "),zm=a(Nb,"CODE",{});var Kj=r(zm);TR=n(Kj,"language modeling"),Kj.forEach(t),wR=n(Nb," head on top."),Nb.forEach(t),FR=h(Nt),Md=a(Nt,"P",{});var qb=r(Md);$R=n(qb,"This model inherits from "),Qp=a(qb,"A",{href:!0});var eC=r(Qp);RR=n(eC,"FlaxPreTrainedModel"),eC.forEach(t),xR=n(qb,`. 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)`),qb.forEach(t),LR=h(Nt),yd=a(Nt,"P",{});var Wb=r(yd);XR=n(Wb,"This model is also a Flax Linen "),vd=a(Wb,"A",{href:!0,rel:!0});var tC=r(vd);ER=n(tC,"flax.linen.Module"),tC.forEach(t),jR=n(Wb,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Wb.forEach(t),CR=h(Nt),Um=a(Nt,"P",{});var oC=r(Um);JR=n(oC,"Finally, this model supports inherent JAX features such as:"),oC.forEach(t),zR=h(Nt),yo=a(Nt,"UL",{});var Ha=r(yo);Im=a(Ha,"LI",{});var nC=r(Im);kd=a(nC,"A",{href:!0,rel:!0});var sC=r(kd);UR=n(sC,"Just-In-Time (JIT) compilation"),sC.forEach(t),nC.forEach(t),IR=h(Ha),Nm=a(Ha,"LI",{});var aC=r(Nm);Td=a(aC,"A",{href:!0,rel:!0});var rC=r(Td);NR=n(rC,"Automatic Differentiation"),rC.forEach(t),aC.forEach(t),qR=h(Ha),qm=a(Ha,"LI",{});var lC=r(qm);wd=a(lC,"A",{href:!0,rel:!0});var iC=r(wd);WR=n(iC,"Vectorization"),iC.forEach(t),lC.forEach(t),BR=h(Ha),Wm=a(Ha,"LI",{});var dC=r(Wm);Fd=a(dC,"A",{href:!0,rel:!0});var cC=r(Fd);ZR=n(cC,"Parallelization"),cC.forEach(t),dC.forEach(t),Ha.forEach(t),AR=h(Nt),no=a(Nt,"DIV",{class:!0});var Ka=r(no);k($d.$$.fragment,Ka),GR=h(Ka),Pn=a(Ka,"P",{});var $h=r(Pn);VR=n($h,"The "),Bm=a($h,"CODE",{});var pC=r(Bm);SR=n(pC,"FlaxXLMRobertaPreTrainedModel"),pC.forEach(t),PR=n($h," forward method, overrides the "),Zm=a($h,"CODE",{});var hC=r(Zm);OR=n(hC,"__call__"),hC.forEach(t),DR=n($h," special method."),$h.forEach(t),QR=h(Ka),k(ka.$$.fragment,Ka),YR=h(Ka),k(Ta.$$.fragment,Ka),Ka.forEach(t),Nt.forEach(t),__=h(l),On=a(l,"H2",{class:!0});var Bb=r(On);wa=a(Bb,"A",{id:!0,class:!0,href:!0});var uC=r(wa);Am=a(uC,"SPAN",{});var mC=r(Am);k(Rd.$$.fragment,mC),mC.forEach(t),uC.forEach(t),HR=h(Bb),Gm=a(Bb,"SPAN",{});var fC=r(Gm);KR=n(fC,"FlaxXLMRobertaForSequenceClassification"),fC.forEach(t),Bb.forEach(t),b_=h(l),st=a(l,"DIV",{class:!0});var qt=r(st);k(xd.$$.fragment,qt),ex=h(qt),Vm=a(qt,"P",{});var gC=r(Vm);tx=n(gC,`XLM Roberta Model transformer with a sequence classification/regression head on top (a linear layer on top of the
pooled output) e.g. for GLUE tasks.`),gC.forEach(t),ox=h(qt),Ld=a(qt,"P",{});var Zb=r(Ld);nx=n(Zb,"This model inherits from "),Yp=a(Zb,"A",{href:!0});var _C=r(Yp);sx=n(_C,"FlaxPreTrainedModel"),_C.forEach(t),ax=n(Zb,`. 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)`),Zb.forEach(t),rx=h(qt),Xd=a(qt,"P",{});var Ab=r(Xd);lx=n(Ab,"This model is also a Flax Linen "),Ed=a(Ab,"A",{href:!0,rel:!0});var bC=r(Ed);ix=n(bC,"flax.linen.Module"),bC.forEach(t),dx=n(Ab,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Ab.forEach(t),cx=h(qt),Sm=a(qt,"P",{});var MC=r(Sm);px=n(MC,"Finally, this model supports inherent JAX features such as:"),MC.forEach(t),hx=h(qt),vo=a(qt,"UL",{});var er=r(vo);Pm=a(er,"LI",{});var yC=r(Pm);jd=a(yC,"A",{href:!0,rel:!0});var vC=r(jd);ux=n(vC,"Just-In-Time (JIT) compilation"),vC.forEach(t),yC.forEach(t),mx=h(er),Om=a(er,"LI",{});var kC=r(Om);Cd=a(kC,"A",{href:!0,rel:!0});var TC=r(Cd);fx=n(TC,"Automatic Differentiation"),TC.forEach(t),kC.forEach(t),gx=h(er),Dm=a(er,"LI",{});var wC=r(Dm);Jd=a(wC,"A",{href:!0,rel:!0});var FC=r(Jd);_x=n(FC,"Vectorization"),FC.forEach(t),wC.forEach(t),bx=h(er),Qm=a(er,"LI",{});var $C=r(Qm);zd=a($C,"A",{href:!0,rel:!0});var RC=r(zd);Mx=n(RC,"Parallelization"),RC.forEach(t),$C.forEach(t),er.forEach(t),yx=h(qt),so=a(qt,"DIV",{class:!0});var tr=r(so);k(Ud.$$.fragment,tr),vx=h(tr),Dn=a(tr,"P",{});var Rh=r(Dn);kx=n(Rh,"The "),Ym=a(Rh,"CODE",{});var xC=r(Ym);Tx=n(xC,"FlaxXLMRobertaPreTrainedModel"),xC.forEach(t),wx=n(Rh," forward method, overrides the "),Hm=a(Rh,"CODE",{});var LC=r(Hm);Fx=n(LC,"__call__"),LC.forEach(t),$x=n(Rh," special method."),Rh.forEach(t),Rx=h(tr),k(Fa.$$.fragment,tr),xx=h(tr),k($a.$$.fragment,tr),tr.forEach(t),qt.forEach(t),M_=h(l),Qn=a(l,"H2",{class:!0});var Gb=r(Qn);Ra=a(Gb,"A",{id:!0,class:!0,href:!0});var XC=r(Ra);Km=a(XC,"SPAN",{});var EC=r(Km);k(Id.$$.fragment,EC),EC.forEach(t),XC.forEach(t),Lx=h(Gb),ef=a(Gb,"SPAN",{});var jC=r(ef);Xx=n(jC,"FlaxXLMRobertaForMultipleChoice"),jC.forEach(t),Gb.forEach(t),y_=h(l),at=a(l,"DIV",{class:!0});var Wt=r(at);k(Nd.$$.fragment,Wt),Ex=h(Wt),tf=a(Wt,"P",{});var CC=r(tf);jx=n(CC,`XLM Roberta 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.`),CC.forEach(t),Cx=h(Wt),qd=a(Wt,"P",{});var Vb=r(qd);Jx=n(Vb,"This model inherits from "),Hp=a(Vb,"A",{href:!0});var JC=r(Hp);zx=n(JC,"FlaxPreTrainedModel"),JC.forEach(t),Ux=n(Vb,`. 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)`),Vb.forEach(t),Ix=h(Wt),Wd=a(Wt,"P",{});var Sb=r(Wd);Nx=n(Sb,"This model is also a Flax Linen "),Bd=a(Sb,"A",{href:!0,rel:!0});var zC=r(Bd);qx=n(zC,"flax.linen.Module"),zC.forEach(t),Wx=n(Sb,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Sb.forEach(t),Bx=h(Wt),of=a(Wt,"P",{});var UC=r(of);Zx=n(UC,"Finally, this model supports inherent JAX features such as:"),UC.forEach(t),Ax=h(Wt),ko=a(Wt,"UL",{});var or=r(ko);nf=a(or,"LI",{});var IC=r(nf);Zd=a(IC,"A",{href:!0,rel:!0});var NC=r(Zd);Gx=n(NC,"Just-In-Time (JIT) compilation"),NC.forEach(t),IC.forEach(t),Vx=h(or),sf=a(or,"LI",{});var qC=r(sf);Ad=a(qC,"A",{href:!0,rel:!0});var WC=r(Ad);Sx=n(WC,"Automatic Differentiation"),WC.forEach(t),qC.forEach(t),Px=h(or),af=a(or,"LI",{});var BC=r(af);Gd=a(BC,"A",{href:!0,rel:!0});var ZC=r(Gd);Ox=n(ZC,"Vectorization"),ZC.forEach(t),BC.forEach(t),Dx=h(or),rf=a(or,"LI",{});var AC=r(rf);Vd=a(AC,"A",{href:!0,rel:!0});var GC=r(Vd);Qx=n(GC,"Parallelization"),GC.forEach(t),AC.forEach(t),or.forEach(t),Yx=h(Wt),ao=a(Wt,"DIV",{class:!0});var nr=r(ao);k(Sd.$$.fragment,nr),Hx=h(nr),Yn=a(nr,"P",{});var xh=r(Yn);Kx=n(xh,"The "),lf=a(xh,"CODE",{});var VC=r(lf);eL=n(VC,"FlaxXLMRobertaPreTrainedModel"),VC.forEach(t),tL=n(xh," forward method, overrides the "),df=a(xh,"CODE",{});var SC=r(df);oL=n(SC,"__call__"),SC.forEach(t),nL=n(xh," special method."),xh.forEach(t),sL=h(nr),k(xa.$$.fragment,nr),aL=h(nr),k(La.$$.fragment,nr),nr.forEach(t),Wt.forEach(t),v_=h(l),Hn=a(l,"H2",{class:!0});var Pb=r(Hn);Xa=a(Pb,"A",{id:!0,class:!0,href:!0});var PC=r(Xa);cf=a(PC,"SPAN",{});var OC=r(cf);k(Pd.$$.fragment,OC),OC.forEach(t),PC.forEach(t),rL=h(Pb),pf=a(Pb,"SPAN",{});var DC=r(pf);lL=n(DC,"FlaxXLMRobertaForTokenClassification"),DC.forEach(t),Pb.forEach(t),k_=h(l),rt=a(l,"DIV",{class:!0});var Bt=r(rt);k(Od.$$.fragment,Bt),iL=h(Bt),hf=a(Bt,"P",{});var QC=r(hf);dL=n(QC,`XLM Roberta 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.`),QC.forEach(t),cL=h(Bt),Dd=a(Bt,"P",{});var Ob=r(Dd);pL=n(Ob,"This model inherits from "),Kp=a(Ob,"A",{href:!0});var YC=r(Kp);hL=n(YC,"FlaxPreTrainedModel"),YC.forEach(t),uL=n(Ob,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading, saving and converting weights from PyTorch models)`),Ob.forEach(t),mL=h(Bt),Qd=a(Bt,"P",{});var Db=r(Qd);fL=n(Db,"This model is also a Flax Linen "),Yd=a(Db,"A",{href:!0,rel:!0});var HC=r(Yd);gL=n(HC,"flax.linen.Module"),HC.forEach(t),_L=n(Db,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Db.forEach(t),bL=h(Bt),uf=a(Bt,"P",{});var KC=r(uf);ML=n(KC,"Finally, this model supports inherent JAX features such as:"),KC.forEach(t),yL=h(Bt),To=a(Bt,"UL",{});var sr=r(To);mf=a(sr,"LI",{});var eJ=r(mf);Hd=a(eJ,"A",{href:!0,rel:!0});var tJ=r(Hd);vL=n(tJ,"Just-In-Time (JIT) compilation"),tJ.forEach(t),eJ.forEach(t),kL=h(sr),ff=a(sr,"LI",{});var oJ=r(ff);Kd=a(oJ,"A",{href:!0,rel:!0});var nJ=r(Kd);TL=n(nJ,"Automatic Differentiation"),nJ.forEach(t),oJ.forEach(t),wL=h(sr),gf=a(sr,"LI",{});var sJ=r(gf);ec=a(sJ,"A",{href:!0,rel:!0});var aJ=r(ec);FL=n(aJ,"Vectorization"),aJ.forEach(t),sJ.forEach(t),$L=h(sr),_f=a(sr,"LI",{});var rJ=r(_f);tc=a(rJ,"A",{href:!0,rel:!0});var lJ=r(tc);RL=n(lJ,"Parallelization"),lJ.forEach(t),rJ.forEach(t),sr.forEach(t),xL=h(Bt),ro=a(Bt,"DIV",{class:!0});var ar=r(ro);k(oc.$$.fragment,ar),LL=h(ar),Kn=a(ar,"P",{});var Lh=r(Kn);XL=n(Lh,"The "),bf=a(Lh,"CODE",{});var iJ=r(bf);EL=n(iJ,"FlaxXLMRobertaPreTrainedModel"),iJ.forEach(t),jL=n(Lh," forward method, overrides the "),Mf=a(Lh,"CODE",{});var dJ=r(Mf);CL=n(dJ,"__call__"),dJ.forEach(t),JL=n(Lh," special method."),Lh.forEach(t),zL=h(ar),k(Ea.$$.fragment,ar),UL=h(ar),k(ja.$$.fragment,ar),ar.forEach(t),Bt.forEach(t),T_=h(l),es=a(l,"H2",{class:!0});var Qb=r(es);Ca=a(Qb,"A",{id:!0,class:!0,href:!0});var cJ=r(Ca);yf=a(cJ,"SPAN",{});var pJ=r(yf);k(nc.$$.fragment,pJ),pJ.forEach(t),cJ.forEach(t),IL=h(Qb),vf=a(Qb,"SPAN",{});var hJ=r(vf);NL=n(hJ,"FlaxXLMRobertaForQuestionAnswering"),hJ.forEach(t),Qb.forEach(t),w_=h(l),lt=a(l,"DIV",{class:!0});var Zt=r(lt);k(sc.$$.fragment,Zt),qL=h(Zt),ts=a(Zt,"P",{});var Xh=r(ts);WL=n(Xh,`XLM Roberta 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 `),kf=a(Xh,"CODE",{});var uJ=r(kf);BL=n(uJ,"span start logits"),uJ.forEach(t),ZL=n(Xh," and "),Tf=a(Xh,"CODE",{});var mJ=r(Tf);AL=n(mJ,"span end logits"),mJ.forEach(t),GL=n(Xh,")."),Xh.forEach(t),VL=h(Zt),ac=a(Zt,"P",{});var Yb=r(ac);SL=n(Yb,"This model inherits from "),eh=a(Yb,"A",{href:!0});var fJ=r(eh);PL=n(fJ,"FlaxPreTrainedModel"),fJ.forEach(t),OL=n(Yb,`. 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)`),Yb.forEach(t),DL=h(Zt),rc=a(Zt,"P",{});var Hb=r(rc);QL=n(Hb,"This model is also a Flax Linen "),lc=a(Hb,"A",{href:!0,rel:!0});var gJ=r(lc);YL=n(gJ,"flax.linen.Module"),gJ.forEach(t),HL=n(Hb,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Hb.forEach(t),KL=h(Zt),wf=a(Zt,"P",{});var _J=r(wf);eX=n(_J,"Finally, this model supports inherent JAX features such as:"),_J.forEach(t),tX=h(Zt),wo=a(Zt,"UL",{});var rr=r(wo);Ff=a(rr,"LI",{});var bJ=r(Ff);ic=a(bJ,"A",{href:!0,rel:!0});var MJ=r(ic);oX=n(MJ,"Just-In-Time (JIT) compilation"),MJ.forEach(t),bJ.forEach(t),nX=h(rr),$f=a(rr,"LI",{});var yJ=r($f);dc=a(yJ,"A",{href:!0,rel:!0});var vJ=r(dc);sX=n(vJ,"Automatic Differentiation"),vJ.forEach(t),yJ.forEach(t),aX=h(rr),Rf=a(rr,"LI",{});var kJ=r(Rf);cc=a(kJ,"A",{href:!0,rel:!0});var TJ=r(cc);rX=n(TJ,"Vectorization"),TJ.forEach(t),kJ.forEach(t),lX=h(rr),xf=a(rr,"LI",{});var wJ=r(xf);pc=a(wJ,"A",{href:!0,rel:!0});var FJ=r(pc);iX=n(FJ,"Parallelization"),FJ.forEach(t),wJ.forEach(t),rr.forEach(t),dX=h(Zt),lo=a(Zt,"DIV",{class:!0});var lr=r(lo);k(hc.$$.fragment,lr),cX=h(lr),os=a(lr,"P",{});var Eh=r(os);pX=n(Eh,"The "),Lf=a(Eh,"CODE",{});var $J=r(Lf);hX=n($J,"FlaxXLMRobertaPreTrainedModel"),$J.forEach(t),uX=n(Eh," forward method, overrides the "),Xf=a(Eh,"CODE",{});var RJ=r(Xf);mX=n(RJ,"__call__"),RJ.forEach(t),fX=n(Eh," special method."),Eh.forEach(t),gX=h(lr),k(Ja.$$.fragment,lr),_X=h(lr),k(za.$$.fragment,lr),lr.forEach(t),Zt.forEach(t),this.h()},h(){c(d,"name","hf:doc:metadata"),c(d,"content",JSON.stringify(Uz)),c(f,"id","xlmroberta"),c(f,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(f,"href","#xlmroberta"),c(m,"class","relative group"),c(te,"alt","Models"),xJ(te.src,R="https://img.shields.io/badge/All_model_pages-xlm--roberta-blueviolet")||c(te,"src",R),c(ce,"href","https://huggingface.co/models?filter=xlm-roberta"),c(pe,"alt","Spaces"),xJ(pe.src,Ce="https://img.shields.io/badge/%F0%9F%A4%97%20Hugging%20Face-Spaces-blue")||c(pe,"src",Ce),c(A,"href","https://huggingface.co/spaces/docs-demos/xlm-roberta-base"),c(q,"class","flex flex-wrap space-x-1"),c(re,"id","overview"),c(re,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(re,"href","#overview"),c(ae,"class","relative group"),c(ie,"href","https://arxiv.org/abs/1911.02116"),c(ie,"rel","nofollow"),c(U,"href","roberta"),c(K,"href","https://huggingface.co/stefan-it"),c(K,"rel","nofollow"),c(E,"href","https://github.com/pytorch/fairseq/tree/master/examples/xlmr"),c(E,"rel","nofollow"),c(ze,"id","resources"),c(ze,"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(ze,"href","#resources"),c(Je,"class","relative group"),c(ir,"href","https://www.philschmid.de/habana-distributed-training"),c(ir,"rel","nofollow"),c(Xc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForSequenceClassification"),c(dr,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/text-classification"),c(dr,"rel","nofollow"),c(cr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification.ipynb"),c(cr,"rel","nofollow"),c(Ec,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForSequenceClassification"),c(pr,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/text-classification"),c(pr,"rel","nofollow"),c(hr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification-tf.ipynb"),c(hr,"rel","nofollow"),c(jc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.FlaxXLMRobertaForSequenceClassification"),c(ur,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/text-classification"),c(ur,"rel","nofollow"),c(mr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/text_classification_flax.ipynb"),c(mr,"rel","nofollow"),c(fr,"href","https://huggingface.co/docs/transformers/tasks/sequence_classification"),c(fr,"rel","nofollow"),c(Jc,"href","../tasks/sequence_classification"),c(zc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForTokenClassification"),c(_r,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/token-classification"),c(_r,"rel","nofollow"),c(br,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification.ipynb"),c(br,"rel","nofollow"),c(Uc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForTokenClassification"),c(Mr,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/token-classification"),c(Mr,"rel","nofollow"),c(yr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/token_classification-tf.ipynb"),c(yr,"rel","nofollow"),c(Ic,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.FlaxXLMRobertaForTokenClassification"),c(vr,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/token-classification"),c(vr,"rel","nofollow"),c(kr,"href","https://huggingface.co/course/chapter7/2?fw=pt"),c(kr,"rel","nofollow"),c(qc,"href","../tasks/token_classification"),c(Wc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForCausalLM"),c(wr,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/language-modeling"),c(wr,"rel","nofollow"),c(Fr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling.ipynb"),c(Fr,"rel","nofollow"),c($r,"href","https://huggingface.co/docs/transformers/tasks/language_modeling"),c($r,"rel","nofollow"),c(Zc,"href","../tasks/language_modeling"),c(Ac,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForMaskedLM"),c(xr,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/language-modeling#robertabertdistilbert-and-masked-language-modeling"),c(xr,"rel","nofollow"),c(Lr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling.ipynb"),c(Lr,"rel","nofollow"),c(Gc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForMaskedLM"),c(Xr,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/language-modeling#run_mlmpy"),c(Xr,"rel","nofollow"),c(Er,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/language_modeling-tf.ipynb"),c(Er,"rel","nofollow"),c(Vc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.FlaxXLMRobertaForMaskedLM"),c(jr,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/language-modeling#masked-language-modeling"),c(jr,"rel","nofollow"),c(Cr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/masked_language_modeling_flax.ipynb"),c(Cr,"rel","nofollow"),c(Jr,"href","https://huggingface.co/course/chapter7/3?fw=pt"),c(Jr,"rel","nofollow"),c(Pc,"href","../tasks/masked_language_modeling"),c(Oc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForQuestionAnswering"),c(Ur,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/question-answering"),c(Ur,"rel","nofollow"),c(Ir,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering.ipynb"),c(Ir,"rel","nofollow"),c(Dc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForQuestionAnswering"),c(Nr,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/question-answering"),c(Nr,"rel","nofollow"),c(qr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/question_answering-tf.ipynb"),c(qr,"rel","nofollow"),c(Qc,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.FlaxXLMRobertaForQuestionAnswering"),c(Wr,"href","https://github.com/huggingface/transformers/tree/main/examples/flax/question-answering"),c(Wr,"rel","nofollow"),c(Br,"href","https://huggingface.co/course/chapter7/7?fw=pt"),c(Br,"rel","nofollow"),c(Hc,"href","../tasks/question_answering"),c(ep,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForMultipleChoice"),c(Zr,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/multiple-choice"),c(Zr,"rel","nofollow"),c(Ar,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/multiple_choice.ipynb"),c(Ar,"rel","nofollow"),c(tp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForMultipleChoice"),c(Gr,"href","https://github.com/huggingface/transformers/tree/main/examples/tensorflow/multiple-choice"),c(Gr,"rel","nofollow"),c(Vr,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/multiple_choice-tf.ipynb"),c(Vr,"rel","nofollow"),c(op,"href","../tasks/multiple_choice"),c(Pr,"href","https://www.philschmid.de/multilingual-serverless-xlm-roberta-with-huggingface"),c(Pr,"rel","nofollow"),c(ls,"id","transformers.XLMRobertaConfig"),c(ls,"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(ls,"href","#transformers.XLMRobertaConfig"),c(ln,"class","relative group"),c(ap,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaModel"),c(rp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaModel"),c(Qr,"href","https://huggingface.co/xlm-roberta-base"),c(Qr,"rel","nofollow"),c(lp,"href","/docs/transformers/v4.32.0/en/main_classes/configuration#transformers.PretrainedConfig"),c(ip,"href","/docs/transformers/v4.32.0/en/main_classes/configuration#transformers.PretrainedConfig"),c(At,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ds,"id","transformers.XLMRobertaTokenizer"),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.XLMRobertaTokenizer"),c(cn,"class","relative group"),c(dp,"href","/docs/transformers/v4.32.0/en/model_doc/roberta#transformers.RobertaTokenizer"),c(cp,"href","/docs/transformers/v4.32.0/en/model_doc/xlnet#transformers.XLNetTokenizer"),c(Kr,"href","https://github.com/google/sentencepiece"),c(Kr,"rel","nofollow"),c(pp,"href","/docs/transformers/v4.32.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizer"),c(Wo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(cs,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ps,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(mp,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(et,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(hs,"id","transformers.XLMRobertaTokenizerFast"),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.XLMRobertaTokenizerFast"),c(pn,"class","relative group"),c(fp,"href","/docs/transformers/v4.32.0/en/model_doc/roberta#transformers.RobertaTokenizer"),c(gp,"href","/docs/transformers/v4.32.0/en/model_doc/xlnet#transformers.XLNetTokenizer"),c(dl,"href","https://huggingface.co/docs/tokenizers/python/latest/components.html?highlight=BPE#models"),c(dl,"rel","nofollow"),c(_p,"href","/docs/transformers/v4.32.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast"),c(Bo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(us,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ms,"id","transformers.XLMRobertaModel"),c(ms,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ms,"href","#transformers.XLMRobertaModel"),c(hn,"class","relative group"),c(yp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(bl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(bl,"rel","nofollow"),c(yl,"href","https://arxiv.org/abs/1706.03762"),c(yl,"rel","nofollow"),c(vp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaModel"),c(St,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Ke,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(bs,"id","transformers.XLMRobertaForCausalLM"),c(bs,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(bs,"href","#transformers.XLMRobertaForCausalLM"),c(mn,"class","relative group"),c(kp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(Rl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Rl,"rel","nofollow"),c(Tp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForCausalLM"),c(Pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Mt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(vs,"id","transformers.XLMRobertaForMaskedLM"),c(vs,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(vs,"href","#transformers.XLMRobertaForMaskedLM"),c(gn,"class","relative group"),c(wp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(Jl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Jl,"rel","nofollow"),c(Fp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForMaskedLM"),c(Ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(yt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ws,"id","transformers.XLMRobertaForSequenceClassification"),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.XLMRobertaForSequenceClassification"),c(bn,"class","relative group"),c($p,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(Wl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Wl,"rel","nofollow"),c(Rp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForSequenceClassification"),c(Lt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(vt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(xs,"id","transformers.XLMRobertaForMultipleChoice"),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.XLMRobertaForMultipleChoice"),c(yn,"class","relative group"),c(xp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(Sl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Sl,"rel","nofollow"),c(Lp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForMultipleChoice"),c(Dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Es,"id","transformers.XLMRobertaForTokenClassification"),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.XLMRobertaForTokenClassification"),c(kn,"class","relative group"),c(Xp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(Hl,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Hl,"rel","nofollow"),c(Ep,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForTokenClassification"),c(Qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Js,"id","transformers.XLMRobertaForQuestionAnswering"),c(Js,"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(Js,"href","#transformers.XLMRobertaForQuestionAnswering"),c(wn,"class","relative group"),c(jp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.PreTrainedModel"),c(si,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(si,"rel","nofollow"),c(Cp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.XLMRobertaForQuestionAnswering"),c(Yt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(wt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Is,"id","transformers.TFXLMRobertaModel"),c(Is,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Is,"href","#transformers.TFXLMRobertaModel"),c(Rn,"class","relative group"),c(Jp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(ci,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(ci,"rel","nofollow"),c(zp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaModel"),c(Ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Bs,"id","transformers.TFXLMRobertaForCausalLM"),c(Bs,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Bs,"href","#transformers.TFXLMRobertaForCausalLM"),c(Ln,"class","relative group"),c(Up,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(_i,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(_i,"rel","nofollow"),c(Ip,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForCausalLM"),c(Kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ct,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Vs,"id","transformers.TFXLMRobertaForMaskedLM"),c(Vs,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Vs,"href","#transformers.TFXLMRobertaForMaskedLM"),c(En,"class","relative group"),c(Np,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(wi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(wi,"rel","nofollow"),c(qp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForMaskedLM"),c(Xt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Qs,"id","transformers.TFXLMRobertaForSequenceClassification"),c(Qs,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Qs,"href","#transformers.TFXLMRobertaForSequenceClassification"),c(Cn,"class","relative group"),c(Wp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(Xi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Xi,"rel","nofollow"),c(Bp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForSequenceClassification"),c(Et,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ta,"id","transformers.TFXLMRobertaForMultipleChoice"),c(ta,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ta,"href","#transformers.TFXLMRobertaForMultipleChoice"),c(zn,"class","relative group"),c(Zp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(Ui,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Ui,"rel","nofollow"),c(Ap,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForMultipleChoice"),c(eo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(aa,"id","transformers.TFXLMRobertaForTokenClassification"),c(aa,"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(aa,"href","#transformers.TFXLMRobertaForTokenClassification"),c(In,"class","relative group"),c(Gp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(Zi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Zi,"rel","nofollow"),c(Vp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForTokenClassification"),c(jt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(mt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ca,"id","transformers.TFXLMRobertaForQuestionAnswering"),c(ca,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ca,"href","#transformers.TFXLMRobertaForQuestionAnswering"),c(qn,"class","relative group"),c(Sp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(Oi,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Oi,"rel","nofollow"),c(Pp,"href","/docs/transformers/v4.32.0/en/model_doc/xlm-roberta#transformers.TFXLMRobertaForQuestionAnswering"),c(Ct,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(fa,"id","transformers.FlaxXLMRobertaModel"),c(fa,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(fa,"href","#transformers.FlaxXLMRobertaModel"),c(Zn,"class","relative group"),c(Op,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(ed,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(ed,"rel","nofollow"),c(td,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(td,"rel","nofollow"),c(od,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(od,"rel","nofollow"),c(nd,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(nd,"rel","nofollow"),c(sd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(sd,"rel","nofollow"),c(to,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ba,"id","transformers.FlaxXLMRobertaForCausalLM"),c(ba,"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(ba,"href","#transformers.FlaxXLMRobertaForCausalLM"),c(Gn,"class","relative group"),c(Dp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(cd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(cd,"rel","nofollow"),c(pd,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(pd,"rel","nofollow"),c(hd,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(hd,"rel","nofollow"),c(ud,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(ud,"rel","nofollow"),c(md,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(md,"rel","nofollow"),c(oo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(va,"id","transformers.FlaxXLMRobertaForMaskedLM"),c(va,"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(va,"href","#transformers.FlaxXLMRobertaForMaskedLM"),c(Sn,"class","relative group"),c(Qp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(vd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(vd,"rel","nofollow"),c(kd,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(kd,"rel","nofollow"),c(Td,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Td,"rel","nofollow"),c(wd,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(wd,"rel","nofollow"),c(Fd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Fd,"rel","nofollow"),c(no,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(nt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(wa,"id","transformers.FlaxXLMRobertaForSequenceClassification"),c(wa,"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(wa,"href","#transformers.FlaxXLMRobertaForSequenceClassification"),c(On,"class","relative group"),c(Yp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Ed,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Ed,"rel","nofollow"),c(jd,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(jd,"rel","nofollow"),c(Cd,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Cd,"rel","nofollow"),c(Jd,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Jd,"rel","nofollow"),c(zd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(zd,"rel","nofollow"),c(so,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(st,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Ra,"id","transformers.FlaxXLMRobertaForMultipleChoice"),c(Ra,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Ra,"href","#transformers.FlaxXLMRobertaForMultipleChoice"),c(Qn,"class","relative group"),c(Hp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Bd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Bd,"rel","nofollow"),c(Zd,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Zd,"rel","nofollow"),c(Ad,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Ad,"rel","nofollow"),c(Gd,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(Gd,"rel","nofollow"),c(Vd,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(Vd,"rel","nofollow"),c(ao,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(at,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Xa,"id","transformers.FlaxXLMRobertaForTokenClassification"),c(Xa,"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(Xa,"href","#transformers.FlaxXLMRobertaForTokenClassification"),c(Hn,"class","relative group"),c(Kp,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(Yd,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(Yd,"rel","nofollow"),c(Hd,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(Hd,"rel","nofollow"),c(Kd,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(Kd,"rel","nofollow"),c(ec,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(ec,"rel","nofollow"),c(tc,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(tc,"rel","nofollow"),c(ro,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Ca,"id","transformers.FlaxXLMRobertaForQuestionAnswering"),c(Ca,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(Ca,"href","#transformers.FlaxXLMRobertaForQuestionAnswering"),c(es,"class","relative group"),c(eh,"href","/docs/transformers/v4.32.0/en/main_classes/model#transformers.FlaxPreTrainedModel"),c(lc,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),c(lc,"rel","nofollow"),c(ic,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),c(ic,"rel","nofollow"),c(dc,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),c(dc,"rel","nofollow"),c(cc,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),c(cc,"rel","nofollow"),c(pc,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),c(pc,"rel","nofollow"),c(lo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(lt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(l,_){e(document.head,d),g(l,M,_),g(l,m,_),e(m,f),e(f,b),T(i,b,null),e(m,u),e(m,X),e(X,Me),g(l,fe,_),g(l,q,_),e(q,ce),e(ce,te),e(q,ye),e(q,A),e(A,pe),g(l,O,_),g(l,ae,_),e(ae,re),e(re,G),T(le,G,null),e(ae,ve),e(ae,V),e(V,ke),g(l,ge,_),g(l,B,_),e(B,Te),e(B,ie),e(ie,oe),e(B,j),g(l,z,_),g(l,he,_),e(he,Q),g(l,_e,_),g(l,ue,_),e(ue,S),e(S,we),g(l,be,_),g(l,J,_),e(J,Fe),g(l,D,_),g(l,ne,_),e(ne,de),e(de,Y),e(de,me),e(me,$e),e(de,N),e(ne,Re),e(ne,P),e(P,xe),e(ne,se),e(ne,C),e(C,Le),e(C,U),e(U,Xe),e(C,Ee),g(l,y,_),g(l,x,_),e(x,Pe),e(x,K),e(K,Oe),e(x,De),e(x,E),e(E,Qe),e(x,Ye),g(l,Ae,_),g(l,Je,_),e(Je,ze),e(ze,I),T(Z,I,null),e(Je,He),e(Je,Ze),e(Ze,H),g(l,Ge,_),g(l,Ie,_),e(Ie,je),g(l,Ve,_),T(ee,l,_),g(l,Se,_),g(l,gt,_),e(gt,Lc),e(Lc,Kb),e(Lc,ir),e(ir,eM),e(gt,tM),e(gt,Fo),e(Fo,Xc),e(Xc,oM),e(Fo,nM),e(Fo,dr),e(dr,sM),e(Fo,aM),e(Fo,cr),e(cr,rM),e(Fo,lM),e(gt,iM),e(gt,$o),e($o,Ec),e(Ec,dM),e($o,cM),e($o,pr),e(pr,pM),e($o,hM),e($o,hr),e(hr,uM),e($o,mM),e(gt,fM),e(gt,Ro),e(Ro,jc),e(jc,gM),e(Ro,_M),e(Ro,ur),e(ur,bM),e(Ro,MM),e(Ro,mr),e(mr,yM),e(Ro,vM),e(gt,kM),e(gt,Cc),e(Cc,fr),e(fr,TM),e(Cc,wM),e(gt,FM),e(gt,jh),e(jh,Jc),e(Jc,$M),g(l,Mg,_),T(gr,l,_),g(l,yg,_),g(l,$t,_),e($t,xo),e(xo,zc),e(zc,RM),e(xo,xM),e(xo,_r),e(_r,LM),e(xo,XM),e(xo,br),e(br,EM),e(xo,jM),e($t,CM),e($t,Lo),e(Lo,Uc),e(Uc,JM),e(Lo,zM),e(Lo,Mr),e(Mr,UM),e(Lo,IM),e(Lo,yr),e(yr,NM),e(Lo,qM),e($t,WM),e($t,as),e(as,Ic),e(Ic,BM),e(as,ZM),e(as,vr),e(vr,AM),e(as,GM),e($t,VM),e($t,Nc),e(Nc,kr),e(kr,SM),e(Nc,PM),e($t,OM),e($t,Ch),e(Ch,qc),e(qc,DM),g(l,vg,_),T(Tr,l,_),g(l,kg,_),g(l,Xo,_),e(Xo,Eo),e(Eo,Wc),e(Wc,QM),e(Eo,YM),e(Eo,wr),e(wr,HM),e(Eo,KM),e(Eo,Fr),e(Fr,ey),e(Eo,ty),e(Xo,oy),e(Xo,Bc),e(Bc,$r),e($r,ny),e(Bc,sy),e(Xo,ay),e(Xo,Jh),e(Jh,Zc),e(Zc,ry),g(l,Tg,_),T(Rr,l,_),g(l,wg,_),g(l,Rt,_),e(Rt,jo),e(jo,Ac),e(Ac,ly),e(jo,iy),e(jo,xr),e(xr,dy),e(jo,cy),e(jo,Lr),e(Lr,py),e(jo,hy),e(Rt,uy),e(Rt,Co),e(Co,Gc),e(Gc,my),e(Co,fy),e(Co,Xr),e(Xr,gy),e(Co,_y),e(Co,Er),e(Er,by),e(Co,My),e(Rt,yy),e(Rt,Jo),e(Jo,Vc),e(Vc,vy),e(Jo,ky),e(Jo,jr),e(jr,Ty),e(Jo,wy),e(Jo,Cr),e(Cr,Fy),e(Jo,$y),e(Rt,Ry),e(Rt,Sc),e(Sc,Jr),e(Jr,xy),e(Sc,Ly),e(Rt,Xy),e(Rt,zh),e(zh,Pc),e(Pc,Ey),g(l,Fg,_),T(zr,l,_),g(l,$g,_),g(l,xt,_),e(xt,zo),e(zo,Oc),e(Oc,jy),e(zo,Cy),e(zo,Ur),e(Ur,Jy),e(zo,zy),e(zo,Ir),e(Ir,Uy),e(zo,Iy),e(xt,Ny),e(xt,Uo),e(Uo,Dc),e(Dc,qy),e(Uo,Wy),e(Uo,Nr),e(Nr,By),e(Uo,Zy),e(Uo,qr),e(qr,Ay),e(Uo,Gy),e(xt,Vy),e(xt,rs),e(rs,Qc),e(Qc,Sy),e(rs,Py),e(rs,Wr),e(Wr,Oy),e(rs,Dy),e(xt,Qy),e(xt,Yc),e(Yc,Br),e(Br,Yy),e(Yc,Hy),e(xt,Ky),e(xt,Uh),e(Uh,Hc),e(Hc,ev),g(l,Rg,_),g(l,Kc,_),e(Kc,Ih),e(Ih,tv),g(l,xg,_),g(l,Io,_),e(Io,No),e(No,ep),e(ep,ov),e(No,nv),e(No,Zr),e(Zr,sv),e(No,av),e(No,Ar),e(Ar,rv),e(No,lv),e(Io,iv),e(Io,qo),e(qo,tp),e(tp,dv),e(qo,cv),e(qo,Gr),e(Gr,pv),e(qo,hv),e(qo,Vr),e(Vr,uv),e(qo,mv),e(Io,fv),e(Io,Nh),e(Nh,op),e(op,gv),g(l,Lg,_),g(l,np,_),e(np,_v),g(l,Xg,_),g(l,sp,_),e(sp,Sr),e(Sr,bv),e(Sr,Pr),e(Pr,Mv),e(Sr,yv),g(l,Eg,_),g(l,ln,_),e(ln,ls),e(ls,qh),T(Or,qh,null),e(ln,vv),e(ln,Wh),e(Wh,kv),g(l,jg,_),g(l,At,_),T(Dr,At,null),e(At,Tv),e(At,go),e(go,wv),e(go,ap),e(ap,Fv),e(go,$v),e(go,rp),e(rp,Rv),e(go,xv),e(go,Qr),e(Qr,Lv),e(go,Xv),e(At,Ev),e(At,dn),e(dn,jv),e(dn,lp),e(lp,Cv),e(dn,Jv),e(dn,ip),e(ip,zv),e(dn,Uv),e(At,Iv),T(is,At,null),g(l,Cg,_),g(l,cn,_),e(cn,ds),e(ds,Bh),T(Yr,Bh,null),e(cn,Nv),e(cn,Zh),e(Zh,qv),g(l,Jg,_),g(l,et,_),T(Hr,et,null),e(et,Wv),e(et,_o),e(_o,Bv),e(_o,dp),e(dp,Zv),e(_o,Av),e(_o,cp),e(cp,Gv),e(_o,Vv),e(_o,Kr),e(Kr,Sv),e(_o,Pv),e(et,Ov),e(et,el),e(el,Dv),e(el,pp),e(pp,Qv),e(el,Yv),e(et,Hv),e(et,Wo),T(tl,Wo,null),e(Wo,Kv),e(Wo,Ah),e(Ah,ek),e(Wo,tk),e(Wo,ol),e(ol,hp),e(hp,ok),e(hp,Gh),e(Gh,nk),e(ol,sk),e(ol,up),e(up,ak),e(up,Vh),e(Vh,rk),e(et,lk),e(et,cs),T(nl,cs,null),e(cs,ik),e(cs,sl),e(sl,dk),e(sl,Sh),e(Sh,ck),e(sl,pk),e(et,hk),e(et,ps),T(al,ps,null),e(ps,uk),e(ps,Ph),e(Ph,mk),e(et,fk),e(et,mp),T(rl,mp,null),g(l,zg,_),g(l,pn,_),e(pn,hs),e(hs,Oh),T(ll,Oh,null),e(pn,gk),e(pn,Dh),e(Dh,_k),g(l,Ug,_),g(l,bt,_),T(il,bt,null),e(bt,bk),e(bt,Gt),e(Gt,Mk),e(Gt,Qh),e(Qh,yk),e(Gt,vk),e(Gt,fp),e(fp,kk),e(Gt,Tk),e(Gt,gp),e(gp,wk),e(Gt,Fk),e(Gt,dl),e(dl,$k),e(Gt,Rk),e(bt,xk),e(bt,cl),e(cl,Lk),e(cl,_p),e(_p,Xk),e(cl,Ek),e(bt,jk),e(bt,Bo),T(pl,Bo,null),e(Bo,Ck),e(Bo,Yh),e(Yh,Jk),e(Bo,zk),e(Bo,hl),e(hl,bp),e(bp,Uk),e(bp,Hh),e(Hh,Ik),e(hl,Nk),e(hl,Mp),e(Mp,qk),e(Mp,Kh),e(Kh,Wk),e(bt,Bk),e(bt,us),T(ul,us,null),e(us,Zk),e(us,eu),e(eu,Ak),g(l,Ig,_),g(l,hn,_),e(hn,ms),e(ms,tu),T(ml,tu,null),e(hn,Gk),e(hn,ou),e(ou,Vk),g(l,Ng,_),g(l,Ke,_),T(fl,Ke,null),e(Ke,Sk),e(Ke,nu),e(nu,Pk),e(Ke,Ok),e(Ke,gl),e(gl,Dk),e(gl,yp),e(yp,Qk),e(gl,Yk),e(Ke,Hk),e(Ke,_l),e(_l,Kk),e(_l,bl),e(bl,eT),e(_l,tT),e(Ke,oT),e(Ke,Ml),e(Ml,nT),e(Ml,su),e(su,sT),e(Ml,aT),e(Ke,rT),e(Ke,it),e(it,lT),e(it,au),e(au,iT),e(it,dT),e(it,ru),e(ru,cT),e(it,pT),e(it,lu),e(lu,hT),e(it,uT),e(it,iu),e(iu,mT),e(it,fT),e(it,du),e(du,gT),e(it,_T),e(it,cu),e(cu,bT),e(it,MT),e(Ke,yT),e(Ke,fs),e(fs,vT),e(fs,pu),e(pu,kT),e(fs,TT),e(fs,yl),e(yl,wT),e(Ke,FT),e(Ke,St),T(vl,St,null),e(St,$T),e(St,un),e(un,RT),e(un,vp),e(vp,xT),e(un,LT),e(un,hu),e(hu,XT),e(un,ET),e(St,jT),T(gs,St,null),e(St,CT),T(_s,St,null),g(l,qg,_),g(l,mn,_),e(mn,bs),e(bs,uu),T(kl,uu,null),e(mn,JT),e(mn,mu),e(mu,zT),g(l,Wg,_),g(l,Mt,_),T(Tl,Mt,null),e(Mt,UT),e(Mt,wl),e(wl,IT),e(wl,fu),e(fu,NT),e(wl,qT),e(Mt,WT),e(Mt,Fl),e(Fl,BT),e(Fl,kp),e(kp,ZT),e(Fl,AT),e(Mt,GT),e(Mt,$l),e($l,VT),e($l,Rl),e(Rl,ST),e($l,PT),e(Mt,OT),e(Mt,Pt),T(xl,Pt,null),e(Pt,DT),e(Pt,fn),e(fn,QT),e(fn,Tp),e(Tp,YT),e(fn,HT),e(fn,gu),e(gu,KT),e(fn,ew),e(Pt,tw),T(Ms,Pt,null),e(Pt,ow),T(ys,Pt,null),g(l,Bg,_),g(l,gn,_),e(gn,vs),e(vs,_u),T(Ll,_u,null),e(gn,nw),e(gn,bu),e(bu,sw),g(l,Zg,_),g(l,yt,_),T(Xl,yt,null),e(yt,aw),e(yt,El),e(El,rw),e(El,Mu),e(Mu,lw),e(El,iw),e(yt,dw),e(yt,jl),e(jl,cw),e(jl,wp),e(wp,pw),e(jl,hw),e(yt,uw),e(yt,Cl),e(Cl,mw),e(Cl,Jl),e(Jl,fw),e(Cl,gw),e(yt,_w),e(yt,Ot),T(zl,Ot,null),e(Ot,bw),e(Ot,_n),e(_n,Mw),e(_n,Fp),e(Fp,yw),e(_n,vw),e(_n,yu),e(yu,kw),e(_n,Tw),e(Ot,ww),T(ks,Ot,null),e(Ot,Fw),T(Ts,Ot,null),g(l,Ag,_),g(l,bn,_),e(bn,ws),e(ws,vu),T(Ul,vu,null),e(bn,$w),e(bn,ku),e(ku,Rw),g(l,Gg,_),g(l,vt,_),T(Il,vt,null),e(vt,xw),e(vt,Tu),e(Tu,Lw),e(vt,Xw),e(vt,Nl),e(Nl,Ew),e(Nl,$p),e($p,jw),e(Nl,Cw),e(vt,Jw),e(vt,ql),e(ql,zw),e(ql,Wl),e(Wl,Uw),e(ql,Iw),e(vt,Nw),e(vt,Lt),T(Bl,Lt,null),e(Lt,qw),e(Lt,Mn),e(Mn,Ww),e(Mn,Rp),e(Rp,Bw),e(Mn,Zw),e(Mn,wu),e(wu,Aw),e(Mn,Gw),e(Lt,Vw),T(Fs,Lt,null),e(Lt,Sw),T($s,Lt,null),e(Lt,Pw),T(Rs,Lt,null),g(l,Vg,_),g(l,yn,_),e(yn,xs),e(xs,Fu),T(Zl,Fu,null),e(yn,Ow),e(yn,$u),e($u,Dw),g(l,Sg,_),g(l,kt,_),T(Al,kt,null),e(kt,Qw),e(kt,Ru),e(Ru,Yw),e(kt,Hw),e(kt,Gl),e(Gl,Kw),e(Gl,xp),e(xp,e2),e(Gl,t2),e(kt,o2),e(kt,Vl),e(Vl,n2),e(Vl,Sl),e(Sl,s2),e(Vl,a2),e(kt,r2),e(kt,Dt),T(Pl,Dt,null),e(Dt,l2),e(Dt,vn),e(vn,i2),e(vn,Lp),e(Lp,d2),e(vn,c2),e(vn,xu),e(xu,p2),e(vn,h2),e(Dt,u2),T(Ls,Dt,null),e(Dt,m2),T(Xs,Dt,null),g(l,Pg,_),g(l,kn,_),e(kn,Es),e(Es,Lu),T(Ol,Lu,null),e(kn,f2),e(kn,Xu),e(Xu,g2),g(l,Og,_),g(l,Tt,_),T(Dl,Tt,null),e(Tt,_2),e(Tt,Eu),e(Eu,b2),e(Tt,M2),e(Tt,Ql),e(Ql,y2),e(Ql,Xp),e(Xp,v2),e(Ql,k2),e(Tt,T2),e(Tt,Yl),e(Yl,w2),e(Yl,Hl),e(Hl,F2),e(Yl,$2),e(Tt,R2),e(Tt,Qt),T(Kl,Qt,null),e(Qt,x2),e(Qt,Tn),e(Tn,L2),e(Tn,Ep),e(Ep,X2),e(Tn,E2),e(Tn,ju),e(ju,j2),e(Tn,C2),e(Qt,J2),T(js,Qt,null),e(Qt,z2),T(Cs,Qt,null),g(l,Dg,_),g(l,wn,_),e(wn,Js),e(Js,Cu),T(ei,Cu,null),e(wn,U2),e(wn,Ju),e(Ju,I2),g(l,Qg,_),g(l,wt,_),T(ti,wt,null),e(wt,N2),e(wt,Fn),e(Fn,q2),e(Fn,zu),e(zu,W2),e(Fn,B2),e(Fn,Uu),e(Uu,Z2),e(Fn,A2),e(wt,G2),e(wt,oi),e(oi,V2),e(oi,jp),e(jp,S2),e(oi,P2),e(wt,O2),e(wt,ni),e(ni,D2),e(ni,si),e(si,Q2),e(ni,Y2),e(wt,H2),e(wt,Yt),T(ai,Yt,null),e(Yt,K2),e(Yt,$n),e($n,e1),e($n,Cp),e(Cp,t1),e($n,o1),e($n,Iu),e(Iu,n1),e($n,s1),e(Yt,a1),T(zs,Yt,null),e(Yt,r1),T(Us,Yt,null),g(l,Yg,_),g(l,Rn,_),e(Rn,Is),e(Is,Nu),T(ri,Nu,null),e(Rn,l1),e(Rn,qu),e(qu,i1),g(l,Hg,_),g(l,dt,_),T(li,dt,null),e(dt,d1),e(dt,Wu),e(Wu,c1),e(dt,p1),e(dt,ii),e(ii,h1),e(ii,Jp),e(Jp,u1),e(ii,m1),e(dt,f1),e(dt,di),e(di,g1),e(di,ci),e(ci,_1),e(di,b1),e(dt,M1),T(Ns,dt,null),e(dt,y1),e(dt,Ht),T(pi,Ht,null),e(Ht,v1),e(Ht,xn),e(xn,k1),e(xn,zp),e(zp,T1),e(xn,w1),e(xn,Bu),e(Bu,F1),e(xn,$1),e(Ht,R1),T(qs,Ht,null),e(Ht,x1),T(Ws,Ht,null),g(l,Kg,_),g(l,Ln,_),e(Ln,Bs),e(Bs,Zu),T(hi,Zu,null),e(Ln,L1),e(Ln,Au),e(Au,X1),g(l,e_,_),g(l,ct,_),T(ui,ct,null),e(ct,E1),e(ct,mi),e(mi,j1),e(mi,Gu),e(Gu,C1),e(mi,J1),e(ct,z1),e(ct,fi),e(fi,U1),e(fi,Up),e(Up,I1),e(fi,N1),e(ct,q1),e(ct,gi),e(gi,W1),e(gi,_i),e(_i,B1),e(gi,Z1),e(ct,A1),T(Zs,ct,null),e(ct,G1),e(ct,Kt),T(bi,Kt,null),e(Kt,V1),e(Kt,Xn),e(Xn,S1),e(Xn,Ip),e(Ip,P1),e(Xn,O1),e(Xn,Vu),e(Vu,D1),e(Xn,Q1),e(Kt,Y1),T(As,Kt,null),e(Kt,H1),T(Gs,Kt,null),g(l,t_,_),g(l,En,_),e(En,Vs),e(Vs,Su),T(Mi,Su,null),e(En,K1),e(En,Pu),e(Pu,e0),g(l,o_,_),g(l,pt,_),T(yi,pt,null),e(pt,t0),e(pt,vi),e(vi,o0),e(vi,Ou),e(Ou,n0),e(vi,s0),e(pt,a0),e(pt,ki),e(ki,r0),e(ki,Np),e(Np,l0),e(ki,i0),e(pt,d0),e(pt,Ti),e(Ti,c0),e(Ti,wi),e(wi,p0),e(Ti,h0),e(pt,u0),T(Ss,pt,null),e(pt,m0),e(pt,Xt),T(Fi,Xt,null),e(Xt,f0),e(Xt,jn),e(jn,g0),e(jn,qp),e(qp,_0),e(jn,b0),e(jn,Du),e(Du,M0),e(jn,y0),e(Xt,v0),T(Ps,Xt,null),e(Xt,k0),T(Os,Xt,null),e(Xt,T0),T(Ds,Xt,null),g(l,n_,_),g(l,Cn,_),e(Cn,Qs),e(Qs,Qu),T($i,Qu,null),e(Cn,w0),e(Cn,Yu),e(Yu,F0),g(l,s_,_),g(l,ht,_),T(Ri,ht,null),e(ht,$0),e(ht,Hu),e(Hu,R0),e(ht,x0),e(ht,xi),e(xi,L0),e(xi,Wp),e(Wp,X0),e(xi,E0),e(ht,j0),e(ht,Li),e(Li,C0),e(Li,Xi),e(Xi,J0),e(Li,z0),e(ht,U0),T(Ys,ht,null),e(ht,I0),e(ht,Et),T(Ei,Et,null),e(Et,N0),e(Et,Jn),e(Jn,q0),e(Jn,Bp),e(Bp,W0),e(Jn,B0),e(Jn,Ku),e(Ku,Z0),e(Jn,A0),e(Et,G0),T(Hs,Et,null),e(Et,V0),T(Ks,Et,null),e(Et,S0),T(ea,Et,null),g(l,a_,_),g(l,zn,_),e(zn,ta),e(ta,em),T(ji,em,null),e(zn,P0),e(zn,tm),e(tm,O0),g(l,r_,_),g(l,ut,_),T(Ci,ut,null),e(ut,D0),e(ut,om),e(om,Q0),e(ut,Y0),e(ut,Ji),e(Ji,H0),e(Ji,Zp),e(Zp,K0),e(Ji,eF),e(ut,tF),e(ut,zi),e(zi,oF),e(zi,Ui),e(Ui,nF),e(zi,sF),e(ut,aF),T(oa,ut,null),e(ut,rF),e(ut,eo),T(Ii,eo,null),e(eo,lF),e(eo,Un),e(Un,iF),e(Un,Ap),e(Ap,dF),e(Un,cF),e(Un,nm),e(nm,pF),e(Un,hF),e(eo,uF),T(na,eo,null),e(eo,mF),T(sa,eo,null),g(l,l_,_),g(l,In,_),e(In,aa),e(aa,sm),T(Ni,sm,null),e(In,fF),e(In,am),e(am,gF),g(l,i_,_),g(l,mt,_),T(qi,mt,null),e(mt,_F),e(mt,rm),e(rm,bF),e(mt,MF),e(mt,Wi),e(Wi,yF),e(Wi,Gp),e(Gp,vF),e(Wi,kF),e(mt,TF),e(mt,Bi),e(Bi,wF),e(Bi,Zi),e(Zi,FF),e(Bi,$F),e(mt,RF),T(ra,mt,null),e(mt,xF),e(mt,jt),T(Ai,jt,null),e(jt,LF),e(jt,Nn),e(Nn,XF),e(Nn,Vp),e(Vp,EF),e(Nn,jF),e(Nn,lm),e(lm,CF),e(Nn,JF),e(jt,zF),T(la,jt,null),e(jt,UF),T(ia,jt,null),e(jt,IF),T(da,jt,null),g(l,d_,_),g(l,qn,_),e(qn,ca),e(ca,im),T(Gi,im,null),e(qn,NF),e(qn,dm),e(dm,qF),g(l,c_,_),g(l,ft,_),T(Vi,ft,null),e(ft,WF),e(ft,Wn),e(Wn,BF),e(Wn,cm),e(cm,ZF),e(Wn,AF),e(Wn,pm),e(pm,GF),e(Wn,VF),e(ft,SF),e(ft,Si),e(Si,PF),e(Si,Sp),e(Sp,OF),e(Si,DF),e(ft,QF),e(ft,Pi),e(Pi,YF),e(Pi,Oi),e(Oi,HF),e(Pi,KF),e(ft,e$),T(pa,ft,null),e(ft,t$),e(ft,Ct),T(Di,Ct,null),e(Ct,o$),e(Ct,Bn),e(Bn,n$),e(Bn,Pp),e(Pp,s$),e(Bn,a$),e(Bn,hm),e(hm,r$),e(Bn,l$),e(Ct,i$),T(ha,Ct,null),e(Ct,d$),T(ua,Ct,null),e(Ct,c$),T(ma,Ct,null),g(l,p_,_),g(l,Zn,_),e(Zn,fa),e(fa,um),T(Qi,um,null),e(Zn,p$),e(Zn,mm),e(mm,h$),g(l,h_,_),g(l,tt,_),T(Yi,tt,null),e(tt,u$),e(tt,fm),e(fm,m$),e(tt,f$),e(tt,Hi),e(Hi,g$),e(Hi,Op),e(Op,_$),e(Hi,b$),e(tt,M$),e(tt,Ki),e(Ki,y$),e(Ki,ed),e(ed,v$),e(Ki,k$),e(tt,T$),e(tt,gm),e(gm,w$),e(tt,F$),e(tt,bo),e(bo,_m),e(_m,td),e(td,$$),e(bo,R$),e(bo,bm),e(bm,od),e(od,x$),e(bo,L$),e(bo,Mm),e(Mm,nd),e(nd,X$),e(bo,E$),e(bo,ym),e(ym,sd),e(sd,j$),e(tt,C$),e(tt,to),T(ad,to,null),e(to,J$),e(to,An),e(An,z$),e(An,vm),e(vm,U$),e(An,I$),e(An,km),e(km,N$),e(An,q$),e(to,W$),T(ga,to,null),e(to,B$),T(_a,to,null),g(l,u_,_),g(l,Gn,_),e(Gn,ba),e(ba,Tm),T(rd,Tm,null),e(Gn,Z$),e(Gn,wm),e(wm,A$),g(l,m_,_),g(l,ot,_),T(ld,ot,null),e(ot,G$),e(ot,Fm),e(Fm,V$),e(ot,S$),e(ot,id),e(id,P$),e(id,Dp),e(Dp,O$),e(id,D$),e(ot,Q$),e(ot,dd),e(dd,Y$),e(dd,cd),e(cd,H$),e(dd,K$),e(ot,eR),e(ot,$m),e($m,tR),e(ot,oR),e(ot,Mo),e(Mo,Rm),e(Rm,pd),e(pd,nR),e(Mo,sR),e(Mo,xm),e(xm,hd),e(hd,aR),e(Mo,rR),e(Mo,Lm),e(Lm,ud),e(ud,lR),e(Mo,iR),e(Mo,Xm),e(Xm,md),e(md,dR),e(ot,cR),e(ot,oo),T(fd,oo,null),e(oo,pR),e(oo,Vn),e(Vn,hR),e(Vn,Em),e(Em,uR),e(Vn,mR),e(Vn,jm),e(jm,fR),e(Vn,gR),e(oo,_R),T(Ma,oo,null),e(oo,bR),T(ya,oo,null),g(l,f_,_),g(l,Sn,_),e(Sn,va),e(va,Cm),T(gd,Cm,null),e(Sn,MR),e(Sn,Jm),e(Jm,yR),g(l,g_,_),g(l,nt,_),T(_d,nt,null),e(nt,vR),e(nt,bd),e(bd,kR),e(bd,zm),e(zm,TR),e(bd,wR),e(nt,FR),e(nt,Md),e(Md,$R),e(Md,Qp),e(Qp,RR),e(Md,xR),e(nt,LR),e(nt,yd),e(yd,XR),e(yd,vd),e(vd,ER),e(yd,jR),e(nt,CR),e(nt,Um),e(Um,JR),e(nt,zR),e(nt,yo),e(yo,Im),e(Im,kd),e(kd,UR),e(yo,IR),e(yo,Nm),e(Nm,Td),e(Td,NR),e(yo,qR),e(yo,qm),e(qm,wd),e(wd,WR),e(yo,BR),e(yo,Wm),e(Wm,Fd),e(Fd,ZR),e(nt,AR),e(nt,no),T($d,no,null),e(no,GR),e(no,Pn),e(Pn,VR),e(Pn,Bm),e(Bm,SR),e(Pn,PR),e(Pn,Zm),e(Zm,OR),e(Pn,DR),e(no,QR),T(ka,no,null),e(no,YR),T(Ta,no,null),g(l,__,_),g(l,On,_),e(On,wa),e(wa,Am),T(Rd,Am,null),e(On,HR),e(On,Gm),e(Gm,KR),g(l,b_,_),g(l,st,_),T(xd,st,null),e(st,ex),e(st,Vm),e(Vm,tx),e(st,ox),e(st,Ld),e(Ld,nx),e(Ld,Yp),e(Yp,sx),e(Ld,ax),e(st,rx),e(st,Xd),e(Xd,lx),e(Xd,Ed),e(Ed,ix),e(Xd,dx),e(st,cx),e(st,Sm),e(Sm,px),e(st,hx),e(st,vo),e(vo,Pm),e(Pm,jd),e(jd,ux),e(vo,mx),e(vo,Om),e(Om,Cd),e(Cd,fx),e(vo,gx),e(vo,Dm),e(Dm,Jd),e(Jd,_x),e(vo,bx),e(vo,Qm),e(Qm,zd),e(zd,Mx),e(st,yx),e(st,so),T(Ud,so,null),e(so,vx),e(so,Dn),e(Dn,kx),e(Dn,Ym),e(Ym,Tx),e(Dn,wx),e(Dn,Hm),e(Hm,Fx),e(Dn,$x),e(so,Rx),T(Fa,so,null),e(so,xx),T($a,so,null),g(l,M_,_),g(l,Qn,_),e(Qn,Ra),e(Ra,Km),T(Id,Km,null),e(Qn,Lx),e(Qn,ef),e(ef,Xx),g(l,y_,_),g(l,at,_),T(Nd,at,null),e(at,Ex),e(at,tf),e(tf,jx),e(at,Cx),e(at,qd),e(qd,Jx),e(qd,Hp),e(Hp,zx),e(qd,Ux),e(at,Ix),e(at,Wd),e(Wd,Nx),e(Wd,Bd),e(Bd,qx),e(Wd,Wx),e(at,Bx),e(at,of),e(of,Zx),e(at,Ax),e(at,ko),e(ko,nf),e(nf,Zd),e(Zd,Gx),e(ko,Vx),e(ko,sf),e(sf,Ad),e(Ad,Sx),e(ko,Px),e(ko,af),e(af,Gd),e(Gd,Ox),e(ko,Dx),e(ko,rf),e(rf,Vd),e(Vd,Qx),e(at,Yx),e(at,ao),T(Sd,ao,null),e(ao,Hx),e(ao,Yn),e(Yn,Kx),e(Yn,lf),e(lf,eL),e(Yn,tL),e(Yn,df),e(df,oL),e(Yn,nL),e(ao,sL),T(xa,ao,null),e(ao,aL),T(La,ao,null),g(l,v_,_),g(l,Hn,_),e(Hn,Xa),e(Xa,cf),T(Pd,cf,null),e(Hn,rL),e(Hn,pf),e(pf,lL),g(l,k_,_),g(l,rt,_),T(Od,rt,null),e(rt,iL),e(rt,hf),e(hf,dL),e(rt,cL),e(rt,Dd),e(Dd,pL),e(Dd,Kp),e(Kp,hL),e(Dd,uL),e(rt,mL),e(rt,Qd),e(Qd,fL),e(Qd,Yd),e(Yd,gL),e(Qd,_L),e(rt,bL),e(rt,uf),e(uf,ML),e(rt,yL),e(rt,To),e(To,mf),e(mf,Hd),e(Hd,vL),e(To,kL),e(To,ff),e(ff,Kd),e(Kd,TL),e(To,wL),e(To,gf),e(gf,ec),e(ec,FL),e(To,$L),e(To,_f),e(_f,tc),e(tc,RL),e(rt,xL),e(rt,ro),T(oc,ro,null),e(ro,LL),e(ro,Kn),e(Kn,XL),e(Kn,bf),e(bf,EL),e(Kn,jL),e(Kn,Mf),e(Mf,CL),e(Kn,JL),e(ro,zL),T(Ea,ro,null),e(ro,UL),T(ja,ro,null),g(l,T_,_),g(l,es,_),e(es,Ca),e(Ca,yf),T(nc,yf,null),e(es,IL),e(es,vf),e(vf,NL),g(l,w_,_),g(l,lt,_),T(sc,lt,null),e(lt,qL),e(lt,ts),e(ts,WL),e(ts,kf),e(kf,BL),e(ts,ZL),e(ts,Tf),e(Tf,AL),e(ts,GL),e(lt,VL),e(lt,ac),e(ac,SL),e(ac,eh),e(eh,PL),e(ac,OL),e(lt,DL),e(lt,rc),e(rc,QL),e(rc,lc),e(lc,YL),e(rc,HL),e(lt,KL),e(lt,wf),e(wf,eX),e(lt,tX),e(lt,wo),e(wo,Ff),e(Ff,ic),e(ic,oX),e(wo,nX),e(wo,$f),e($f,dc),e(dc,sX),e(wo,aX),e(wo,Rf),e(Rf,cc),e(cc,rX),e(wo,lX),e(wo,xf),e(xf,pc),e(pc,iX),e(lt,dX),e(lt,lo),T(hc,lo,null),e(lo,cX),e(lo,os),e(os,pX),e(os,Lf),e(Lf,hX),e(os,uX),e(os,Xf),e(Xf,mX),e(os,fX),e(lo,gX),T(Ja,lo,null),e(lo,_X),T(za,lo,null),F_=!0},p(l,[_]){const uc={};_&2&&(uc.$$scope={dirty:_,ctx:l}),is.$set(uc);const Ef={};_&2&&(Ef.$$scope={dirty:_,ctx:l}),gs.$set(Ef);const jf={};_&2&&(jf.$$scope={dirty:_,ctx:l}),_s.$set(jf);const Cf={};_&2&&(Cf.$$scope={dirty:_,ctx:l}),Ms.$set(Cf);const mc={};_&2&&(mc.$$scope={dirty:_,ctx:l}),ys.$set(mc);const Jf={};_&2&&(Jf.$$scope={dirty:_,ctx:l}),ks.$set(Jf);const zf={};_&2&&(zf.$$scope={dirty:_,ctx:l}),Ts.$set(zf);const fc={};_&2&&(fc.$$scope={dirty:_,ctx:l}),Fs.$set(fc);const Uf={};_&2&&(Uf.$$scope={dirty:_,ctx:l}),$s.$set(Uf);const If={};_&2&&(If.$$scope={dirty:_,ctx:l}),Rs.$set(If);const Nf={};_&2&&(Nf.$$scope={dirty:_,ctx:l}),Ls.$set(Nf);const gc={};_&2&&(gc.$$scope={dirty:_,ctx:l}),Xs.$set(gc);const qf={};_&2&&(qf.$$scope={dirty:_,ctx:l}),js.$set(qf);const Wf={};_&2&&(Wf.$$scope={dirty:_,ctx:l}),Cs.$set(Wf);const Bf={};_&2&&(Bf.$$scope={dirty:_,ctx:l}),zs.$set(Bf);const Zf={};_&2&&(Zf.$$scope={dirty:_,ctx:l}),Us.$set(Zf);const Af={};_&2&&(Af.$$scope={dirty:_,ctx:l}),Ns.$set(Af);const ns={};_&2&&(ns.$$scope={dirty:_,ctx:l}),qs.$set(ns);const _c={};_&2&&(_c.$$scope={dirty:_,ctx:l}),Ws.$set(_c);const Gf={};_&2&&(Gf.$$scope={dirty:_,ctx:l}),Zs.$set(Gf);const Vf={};_&2&&(Vf.$$scope={dirty:_,ctx:l}),As.$set(Vf);const bc={};_&2&&(bc.$$scope={dirty:_,ctx:l}),Gs.$set(bc);const Sf={};_&2&&(Sf.$$scope={dirty:_,ctx:l}),Ss.$set(Sf);const ss={};_&2&&(ss.$$scope={dirty:_,ctx:l}),Ps.$set(ss);const Pf={};_&2&&(Pf.$$scope={dirty:_,ctx:l}),Os.$set(Pf);const Of={};_&2&&(Of.$$scope={dirty:_,ctx:l}),Ds.$set(Of);const Mc={};_&2&&(Mc.$$scope={dirty:_,ctx:l}),Ys.$set(Mc);const Df={};_&2&&(Df.$$scope={dirty:_,ctx:l}),Hs.$set(Df);const Qf={};_&2&&(Qf.$$scope={dirty:_,ctx:l}),Ks.$set(Qf);const Yf={};_&2&&(Yf.$$scope={dirty:_,ctx:l}),ea.$set(Yf);const Hf={};_&2&&(Hf.$$scope={dirty:_,ctx:l}),oa.$set(Hf);const Ft={};_&2&&(Ft.$$scope={dirty:_,ctx:l}),na.$set(Ft);const th={};_&2&&(th.$$scope={dirty:_,ctx:l}),sa.$set(th);const Kf={};_&2&&(Kf.$$scope={dirty:_,ctx:l}),ra.$set(Kf);const Zo={};_&2&&(Zo.$$scope={dirty:_,ctx:l}),la.$set(Zo);const eg={};_&2&&(eg.$$scope={dirty:_,ctx:l}),ia.$set(eg);const tg={};_&2&&(tg.$$scope={dirty:_,ctx:l}),da.$set(tg);const og={};_&2&&(og.$$scope={dirty:_,ctx:l}),pa.$set(og);const Ao={};_&2&&(Ao.$$scope={dirty:_,ctx:l}),ha.$set(Ao);const ng={};_&2&&(ng.$$scope={dirty:_,ctx:l}),ua.$set(ng);const sg={};_&2&&(sg.$$scope={dirty:_,ctx:l}),ma.$set(sg);const ag={};_&2&&(ag.$$scope={dirty:_,ctx:l}),ga.$set(ag);const Go={};_&2&&(Go.$$scope={dirty:_,ctx:l}),_a.$set(Go);const rg={};_&2&&(rg.$$scope={dirty:_,ctx:l}),Ma.$set(rg);const lg={};_&2&&(lg.$$scope={dirty:_,ctx:l}),ya.$set(lg);const ig={};_&2&&(ig.$$scope={dirty:_,ctx:l}),ka.$set(ig);const oh={};_&2&&(oh.$$scope={dirty:_,ctx:l}),Ta.$set(oh);const dg={};_&2&&(dg.$$scope={dirty:_,ctx:l}),Fa.$set(dg);const cg={};_&2&&(cg.$$scope={dirty:_,ctx:l}),$a.$set(cg);const pg={};_&2&&(pg.$$scope={dirty:_,ctx:l}),xa.$set(pg);const Vt={};_&2&&(Vt.$$scope={dirty:_,ctx:l}),La.$set(Vt);const Vo={};_&2&&(Vo.$$scope={dirty:_,ctx:l}),Ea.$set(Vo);const hg={};_&2&&(hg.$$scope={dirty:_,ctx:l}),ja.$set(hg);const ug={};_&2&&(ug.$$scope={dirty:_,ctx:l}),Ja.$set(ug);const mg={};_&2&&(mg.$$scope={dirty:_,ctx:l}),za.$set(mg)},i(l){F_||(w(i.$$.fragment,l),w(le.$$.fragment,l),w(Z.$$.fragment,l),w(ee.$$.fragment,l),w(gr.$$.fragment,l),w(Tr.$$.fragment,l),w(Rr.$$.fragment,l),w(zr.$$.fragment,l),w(Or.$$.fragment,l),w(Dr.$$.fragment,l),w(is.$$.fragment,l),w(Yr.$$.fragment,l),w(Hr.$$.fragment,l),w(tl.$$.fragment,l),w(nl.$$.fragment,l),w(al.$$.fragment,l),w(rl.$$.fragment,l),w(ll.$$.fragment,l),w(il.$$.fragment,l),w(pl.$$.fragment,l),w(ul.$$.fragment,l),w(ml.$$.fragment,l),w(fl.$$.fragment,l),w(vl.$$.fragment,l),w(gs.$$.fragment,l),w(_s.$$.fragment,l),w(kl.$$.fragment,l),w(Tl.$$.fragment,l),w(xl.$$.fragment,l),w(Ms.$$.fragment,l),w(ys.$$.fragment,l),w(Ll.$$.fragment,l),w(Xl.$$.fragment,l),w(zl.$$.fragment,l),w(ks.$$.fragment,l),w(Ts.$$.fragment,l),w(Ul.$$.fragment,l),w(Il.$$.fragment,l),w(Bl.$$.fragment,l),w(Fs.$$.fragment,l),w($s.$$.fragment,l),w(Rs.$$.fragment,l),w(Zl.$$.fragment,l),w(Al.$$.fragment,l),w(Pl.$$.fragment,l),w(Ls.$$.fragment,l),w(Xs.$$.fragment,l),w(Ol.$$.fragment,l),w(Dl.$$.fragment,l),w(Kl.$$.fragment,l),w(js.$$.fragment,l),w(Cs.$$.fragment,l),w(ei.$$.fragment,l),w(ti.$$.fragment,l),w(ai.$$.fragment,l),w(zs.$$.fragment,l),w(Us.$$.fragment,l),w(ri.$$.fragment,l),w(li.$$.fragment,l),w(Ns.$$.fragment,l),w(pi.$$.fragment,l),w(qs.$$.fragment,l),w(Ws.$$.fragment,l),w(hi.$$.fragment,l),w(ui.$$.fragment,l),w(Zs.$$.fragment,l),w(bi.$$.fragment,l),w(As.$$.fragment,l),w(Gs.$$.fragment,l),w(Mi.$$.fragment,l),w(yi.$$.fragment,l),w(Ss.$$.fragment,l),w(Fi.$$.fragment,l),w(Ps.$$.fragment,l),w(Os.$$.fragment,l),w(Ds.$$.fragment,l),w($i.$$.fragment,l),w(Ri.$$.fragment,l),w(Ys.$$.fragment,l),w(Ei.$$.fragment,l),w(Hs.$$.fragment,l),w(Ks.$$.fragment,l),w(ea.$$.fragment,l),w(ji.$$.fragment,l),w(Ci.$$.fragment,l),w(oa.$$.fragment,l),w(Ii.$$.fragment,l),w(na.$$.fragment,l),w(sa.$$.fragment,l),w(Ni.$$.fragment,l),w(qi.$$.fragment,l),w(ra.$$.fragment,l),w(Ai.$$.fragment,l),w(la.$$.fragment,l),w(ia.$$.fragment,l),w(da.$$.fragment,l),w(Gi.$$.fragment,l),w(Vi.$$.fragment,l),w(pa.$$.fragment,l),w(Di.$$.fragment,l),w(ha.$$.fragment,l),w(ua.$$.fragment,l),w(ma.$$.fragment,l),w(Qi.$$.fragment,l),w(Yi.$$.fragment,l),w(ad.$$.fragment,l),w(ga.$$.fragment,l),w(_a.$$.fragment,l),w(rd.$$.fragment,l),w(ld.$$.fragment,l),w(fd.$$.fragment,l),w(Ma.$$.fragment,l),w(ya.$$.fragment,l),w(gd.$$.fragment,l),w(_d.$$.fragment,l),w($d.$$.fragment,l),w(ka.$$.fragment,l),w(Ta.$$.fragment,l),w(Rd.$$.fragment,l),w(xd.$$.fragment,l),w(Ud.$$.fragment,l),w(Fa.$$.fragment,l),w($a.$$.fragment,l),w(Id.$$.fragment,l),w(Nd.$$.fragment,l),w(Sd.$$.fragment,l),w(xa.$$.fragment,l),w(La.$$.fragment,l),w(Pd.$$.fragment,l),w(Od.$$.fragment,l),w(oc.$$.fragment,l),w(Ea.$$.fragment,l),w(ja.$$.fragment,l),w(nc.$$.fragment,l),w(sc.$$.fragment,l),w(hc.$$.fragment,l),w(Ja.$$.fragment,l),w(za.$$.fragment,l),F_=!0)},o(l){F(i.$$.fragment,l),F(le.$$.fragment,l),F(Z.$$.fragment,l),F(ee.$$.fragment,l),F(gr.$$.fragment,l),F(Tr.$$.fragment,l),F(Rr.$$.fragment,l),F(zr.$$.fragment,l),F(Or.$$.fragment,l),F(Dr.$$.fragment,l),F(is.$$.fragment,l),F(Yr.$$.fragment,l),F(Hr.$$.fragment,l),F(tl.$$.fragment,l),F(nl.$$.fragment,l),F(al.$$.fragment,l),F(rl.$$.fragment,l),F(ll.$$.fragment,l),F(il.$$.fragment,l),F(pl.$$.fragment,l),F(ul.$$.fragment,l),F(ml.$$.fragment,l),F(fl.$$.fragment,l),F(vl.$$.fragment,l),F(gs.$$.fragment,l),F(_s.$$.fragment,l),F(kl.$$.fragment,l),F(Tl.$$.fragment,l),F(xl.$$.fragment,l),F(Ms.$$.fragment,l),F(ys.$$.fragment,l),F(Ll.$$.fragment,l),F(Xl.$$.fragment,l),F(zl.$$.fragment,l),F(ks.$$.fragment,l),F(Ts.$$.fragment,l),F(Ul.$$.fragment,l),F(Il.$$.fragment,l),F(Bl.$$.fragment,l),F(Fs.$$.fragment,l),F($s.$$.fragment,l),F(Rs.$$.fragment,l),F(Zl.$$.fragment,l),F(Al.$$.fragment,l),F(Pl.$$.fragment,l),F(Ls.$$.fragment,l),F(Xs.$$.fragment,l),F(Ol.$$.fragment,l),F(Dl.$$.fragment,l),F(Kl.$$.fragment,l),F(js.$$.fragment,l),F(Cs.$$.fragment,l),F(ei.$$.fragment,l),F(ti.$$.fragment,l),F(ai.$$.fragment,l),F(zs.$$.fragment,l),F(Us.$$.fragment,l),F(ri.$$.fragment,l),F(li.$$.fragment,l),F(Ns.$$.fragment,l),F(pi.$$.fragment,l),F(qs.$$.fragment,l),F(Ws.$$.fragment,l),F(hi.$$.fragment,l),F(ui.$$.fragment,l),F(Zs.$$.fragment,l),F(bi.$$.fragment,l),F(As.$$.fragment,l),F(Gs.$$.fragment,l),F(Mi.$$.fragment,l),F(yi.$$.fragment,l),F(Ss.$$.fragment,l),F(Fi.$$.fragment,l),F(Ps.$$.fragment,l),F(Os.$$.fragment,l),F(Ds.$$.fragment,l),F($i.$$.fragment,l),F(Ri.$$.fragment,l),F(Ys.$$.fragment,l),F(Ei.$$.fragment,l),F(Hs.$$.fragment,l),F(Ks.$$.fragment,l),F(ea.$$.fragment,l),F(ji.$$.fragment,l),F(Ci.$$.fragment,l),F(oa.$$.fragment,l),F(Ii.$$.fragment,l),F(na.$$.fragment,l),F(sa.$$.fragment,l),F(Ni.$$.fragment,l),F(qi.$$.fragment,l),F(ra.$$.fragment,l),F(Ai.$$.fragment,l),F(la.$$.fragment,l),F(ia.$$.fragment,l),F(da.$$.fragment,l),F(Gi.$$.fragment,l),F(Vi.$$.fragment,l),F(pa.$$.fragment,l),F(Di.$$.fragment,l),F(ha.$$.fragment,l),F(ua.$$.fragment,l),F(ma.$$.fragment,l),F(Qi.$$.fragment,l),F(Yi.$$.fragment,l),F(ad.$$.fragment,l),F(ga.$$.fragment,l),F(_a.$$.fragment,l),F(rd.$$.fragment,l),F(ld.$$.fragment,l),F(fd.$$.fragment,l),F(Ma.$$.fragment,l),F(ya.$$.fragment,l),F(gd.$$.fragment,l),F(_d.$$.fragment,l),F($d.$$.fragment,l),F(ka.$$.fragment,l),F(Ta.$$.fragment,l),F(Rd.$$.fragment,l),F(xd.$$.fragment,l),F(Ud.$$.fragment,l),F(Fa.$$.fragment,l),F($a.$$.fragment,l),F(Id.$$.fragment,l),F(Nd.$$.fragment,l),F(Sd.$$.fragment,l),F(xa.$$.fragment,l),F(La.$$.fragment,l),F(Pd.$$.fragment,l),F(Od.$$.fragment,l),F(oc.$$.fragment,l),F(Ea.$$.fragment,l),F(ja.$$.fragment,l),F(nc.$$.fragment,l),F(sc.$$.fragment,l),F(hc.$$.fragment,l),F(Ja.$$.fragment,l),F(za.$$.fragment,l),F_=!1},d(l){t(d),l&&t(M),l&&t(m),$(i),l&&t(fe),l&&t(q),l&&t(O),l&&t(ae),$(le),l&&t(ge),l&&t(B),l&&t(z),l&&t(he),l&&t(_e),l&&t(ue),l&&t(be),l&&t(J),l&&t(D),l&&t(ne),l&&t(y),l&&t(x),l&&t(Ae),l&&t(Je),$(Z),l&&t(Ge),l&&t(Ie),l&&t(Ve),$(ee,l),l&&t(Se),l&&t(gt),l&&t(Mg),$(gr,l),l&&t(yg),l&&t($t),l&&t(vg),$(Tr,l),l&&t(kg),l&&t(Xo),l&&t(Tg),$(Rr,l),l&&t(wg),l&&t(Rt),l&&t(Fg),$(zr,l),l&&t($g),l&&t(xt),l&&t(Rg),l&&t(Kc),l&&t(xg),l&&t(Io),l&&t(Lg),l&&t(np),l&&t(Xg),l&&t(sp),l&&t(Eg),l&&t(ln),$(Or),l&&t(jg),l&&t(At),$(Dr),$(is),l&&t(Cg),l&&t(cn),$(Yr),l&&t(Jg),l&&t(et),$(Hr),$(tl),$(nl),$(al),$(rl),l&&t(zg),l&&t(pn),$(ll),l&&t(Ug),l&&t(bt),$(il),$(pl),$(ul),l&&t(Ig),l&&t(hn),$(ml),l&&t(Ng),l&&t(Ke),$(fl),$(vl),$(gs),$(_s),l&&t(qg),l&&t(mn),$(kl),l&&t(Wg),l&&t(Mt),$(Tl),$(xl),$(Ms),$(ys),l&&t(Bg),l&&t(gn),$(Ll),l&&t(Zg),l&&t(yt),$(Xl),$(zl),$(ks),$(Ts),l&&t(Ag),l&&t(bn),$(Ul),l&&t(Gg),l&&t(vt),$(Il),$(Bl),$(Fs),$($s),$(Rs),l&&t(Vg),l&&t(yn),$(Zl),l&&t(Sg),l&&t(kt),$(Al),$(Pl),$(Ls),$(Xs),l&&t(Pg),l&&t(kn),$(Ol),l&&t(Og),l&&t(Tt),$(Dl),$(Kl),$(js),$(Cs),l&&t(Dg),l&&t(wn),$(ei),l&&t(Qg),l&&t(wt),$(ti),$(ai),$(zs),$(Us),l&&t(Yg),l&&t(Rn),$(ri),l&&t(Hg),l&&t(dt),$(li),$(Ns),$(pi),$(qs),$(Ws),l&&t(Kg),l&&t(Ln),$(hi),l&&t(e_),l&&t(ct),$(ui),$(Zs),$(bi),$(As),$(Gs),l&&t(t_),l&&t(En),$(Mi),l&&t(o_),l&&t(pt),$(yi),$(Ss),$(Fi),$(Ps),$(Os),$(Ds),l&&t(n_),l&&t(Cn),$($i),l&&t(s_),l&&t(ht),$(Ri),$(Ys),$(Ei),$(Hs),$(Ks),$(ea),l&&t(a_),l&&t(zn),$(ji),l&&t(r_),l&&t(ut),$(Ci),$(oa),$(Ii),$(na),$(sa),l&&t(l_),l&&t(In),$(Ni),l&&t(i_),l&&t(mt),$(qi),$(ra),$(Ai),$(la),$(ia),$(da),l&&t(d_),l&&t(qn),$(Gi),l&&t(c_),l&&t(ft),$(Vi),$(pa),$(Di),$(ha),$(ua),$(ma),l&&t(p_),l&&t(Zn),$(Qi),l&&t(h_),l&&t(tt),$(Yi),$(ad),$(ga),$(_a),l&&t(u_),l&&t(Gn),$(rd),l&&t(m_),l&&t(ot),$(ld),$(fd),$(Ma),$(ya),l&&t(f_),l&&t(Sn),$(gd),l&&t(g_),l&&t(nt),$(_d),$($d),$(ka),$(Ta),l&&t(__),l&&t(On),$(Rd),l&&t(b_),l&&t(st),$(xd),$(Ud),$(Fa),$($a),l&&t(M_),l&&t(Qn),$(Id),l&&t(y_),l&&t(at),$(Nd),$(Sd),$(xa),$(La),l&&t(v_),l&&t(Hn),$(Pd),l&&t(k_),l&&t(rt),$(Od),$(oc),$(Ea),$(ja),l&&t(T_),l&&t(es),$(nc),l&&t(w_),l&&t(lt),$(sc),$(hc),$(Ja),$(za)}}}const Uz={local:"xlmroberta",sections:[{local:"overview",title:"Overview"},{local:"resources",title:"Resources"},{local:"transformers.XLMRobertaConfig",title:"XLMRobertaConfig"},{local:"transformers.XLMRobertaTokenizer",title:"XLMRobertaTokenizer"},{local:"transformers.XLMRobertaTokenizerFast",title:"XLMRobertaTokenizerFast"},{local:"transformers.XLMRobertaModel",title:"XLMRobertaModel"},{local:"transformers.XLMRobertaForCausalLM",title:"XLMRobertaForCausalLM"},{local:"transformers.XLMRobertaForMaskedLM",title:"XLMRobertaForMaskedLM"},{local:"transformers.XLMRobertaForSequenceClassification",title:"XLMRobertaForSequenceClassification"},{local:"transformers.XLMRobertaForMultipleChoice",title:"XLMRobertaForMultipleChoice"},{local:"transformers.XLMRobertaForTokenClassification",title:"XLMRobertaForTokenClassification"},{local:"transformers.XLMRobertaForQuestionAnswering",title:"XLMRobertaForQuestionAnswering"},{local:"transformers.TFXLMRobertaModel",title:"TFXLMRobertaModel"},{local:"transformers.TFXLMRobertaForCausalLM",title:"TFXLMRobertaForCausalLM"},{local:"transformers.TFXLMRobertaForMaskedLM",title:"TFXLMRobertaForMaskedLM"},{local:"transformers.TFXLMRobertaForSequenceClassification",title:"TFXLMRobertaForSequenceClassification"},{local:"transformers.TFXLMRobertaForMultipleChoice",title:"TFXLMRobertaForMultipleChoice"},{local:"transformers.TFXLMRobertaForTokenClassification",title:"TFXLMRobertaForTokenClassification"},{local:"transformers.TFXLMRobertaForQuestionAnswering",title:"TFXLMRobertaForQuestionAnswering"},{local:"transformers.FlaxXLMRobertaModel",title:"FlaxXLMRobertaModel"},{local:"transformers.FlaxXLMRobertaForCausalLM",title:"FlaxXLMRobertaForCausalLM"},{local:"transformers.FlaxXLMRobertaForMaskedLM",title:"FlaxXLMRobertaForMaskedLM"},{local:"transformers.FlaxXLMRobertaForSequenceClassification",title:"FlaxXLMRobertaForSequenceClassification"},{local:"transformers.FlaxXLMRobertaForMultipleChoice",title:"FlaxXLMRobertaForMultipleChoice"},{local:"transformers.FlaxXLMRobertaForTokenClassification",title:"FlaxXLMRobertaForTokenClassification"},{local:"transformers.FlaxXLMRobertaForQuestionAnswering",title:"FlaxXLMRobertaForQuestionAnswering"}],title:"XLM-RoBERTa"};function Iz(L){return CJ(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Vz extends LJ{constructor(d){super();XJ(this,d,Iz,zz,EJ,{})}}export{Vz as default,Uz as metadata};
