import{S as D2,i as S2,s as W2,e as r,k as p,w as v,t as o,M as U2,c as a,d as t,m,a as s,x as T,h as n,b as f,G as e,g as _,y as w,q as $,o as P,B as F,v as B2,L as Oe}from"../../chunks/vendor-hf-doc-builder.js";import{T as je}from"../../chunks/Tip-hf-doc-builder.js";import{D as W}from"../../chunks/Docstring-hf-doc-builder.js";import{C as Ie}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ue}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as Ae}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";function Q2(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import RobertaPreLayerNormConfig, RobertaPreLayerNormModel

# Initializing a RoBERTa-PreLayerNorm configuration
configuration = RobertaPreLayerNormConfig()

# Initializing a model (with random weights) from the configuration
model = RobertaPreLayerNormModel(configuration)

# Accessing the model configuration
configuration = model.config`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> RobertaPreLayerNormConfig, RobertaPreLayerNormModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a RoBERTa-PreLayerNorm configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = RobertaPreLayerNormConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormModel(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=r("p"),y=o("Examples:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Examples:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function H2(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function K2(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, RobertaPreLayerNormModel
import torch

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = RobertaPreLayerNormModel.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, RobertaPreLayerNormModel
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormModel.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function V2(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function J2(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, RobertaPreLayerNormForCausalLM, AutoConfig
import torch

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
config = AutoConfig.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
config.is_decoder = True
model = RobertaPreLayerNormForCausalLM.from_pretrained("andreasmadsen/efficient_mlm_m0.40", config=config)

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

prediction_logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, RobertaPreLayerNormForCausalLM, 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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>config = AutoConfig.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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 = RobertaPreLayerNormForCausalLM.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function G2(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function X2(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, RobertaPreLayerNormForMaskedLM
import torch

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = RobertaPreLayerNormForMaskedLM.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

inputs = tokenizer("The capital of France is <mask>.", return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

# retrieve index of <mask>
mask_token_index = (inputs.input_ids == tokenizer.mask_token_id)[0].nonzero(as_tuple=True)[0]

predicted_token_id = logits[0, mask_token_index].argmax(axis=-1)
tokenizer.decode(predicted_token_id)

labels = tokenizer("The capital of France is Paris.", return_tensors="pt")["input_ids"]
# mask labels of non-<mask> tokens
labels = torch.where(inputs.input_ids == tokenizer.mask_token_id, labels, -100)

outputs = model(**inputs, labels=labels)
round(outputs.loss.item(), 2)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, RobertaPreLayerNormForMaskedLM
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormForMaskedLM.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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.69</span>`}}),{c(){d=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function Y2(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function Z2(N){let d,y,h,u,g;return u=new Ie({props:{code:`import torch
from transformers import AutoTokenizer, RobertaPreLayerNormForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = RobertaPreLayerNormForSequenceClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

with torch.no_grad():
    logits = model(**inputs).logits

predicted_class_id = logits.argmax().item()

# To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`
num_labels = len(model.config.id2label)
model = RobertaPreLayerNormForSequenceClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40", num_labels=num_labels)

labels = torch.tensor([1])
loss = model(**inputs, labels=labels).loss`,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, RobertaPreLayerNormForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = logits.argmax().item()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>, num_labels=num_labels)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.tensor([<span class="hljs-number">1</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=r("p"),y=o("Example of single-label classification:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example of single-label classification:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function eN(N){let d,y,h,u,g;return u=new Ie({props:{code:`import torch
from transformers import AutoTokenizer, RobertaPreLayerNormForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = RobertaPreLayerNormForSequenceClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40", problem_type="multi_label_classification")

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

with torch.no_grad():
    logits = model(**inputs).logits

predicted_class_ids = torch.arange(0, logits.shape[-1])[torch.sigmoid(logits).squeeze(dim=0) > 0.5]

# To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`
num_labels = len(model.config.id2label)
model = RobertaPreLayerNormForSequenceClassification.from_pretrained(
    "andreasmadsen/efficient_mlm_m0.40", num_labels=num_labels, problem_type="multi_label_classification"
)

labels = torch.sum(
    torch.nn.functional.one_hot(predicted_class_ids[None, :].clone(), num_classes=num_labels), dim=1
).to(torch.float)
loss = model(**inputs, labels=labels).loss`,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, RobertaPreLayerNormForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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 = RobertaPreLayerNormForSequenceClassification.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example of multi-label classification:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example of multi-label classification:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function tN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function oN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, RobertaPreLayerNormForMultipleChoice
import torch

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = RobertaPreLayerNormForMultipleChoice.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

# the linear classifier still needs to be trained
loss = outputs.loss
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, RobertaPreLayerNormForMultipleChoice
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function nN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function rN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, RobertaPreLayerNormForTokenClassification
import torch

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = RobertaPreLayerNormForTokenClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

inputs = tokenizer(
    "HuggingFace is a company based in Paris and New York", add_special_tokens=False, return_tensors="pt"
)

with torch.no_grad():
    logits = model(**inputs).logits

predicted_token_class_ids = logits.argmax(-1)

# Note that tokens are classified rather then input words which means that
# there might be more predicted token classes than words.
# Multiple token classes might account for the same word
predicted_tokens_classes = [model.config.id2label[t.item()] for t in predicted_token_class_ids[0]]

labels = predicted_token_class_ids
loss = model(**inputs, labels=labels).loss`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, RobertaPreLayerNormForTokenClassification
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormForTokenClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)

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

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function aN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function sN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, RobertaPreLayerNormForQuestionAnswering
import torch

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = RobertaPreLayerNormForQuestionAnswering.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

question, text = "Who was Jim Henson?", "Jim Henson was a nice puppet"

inputs = tokenizer(question, text, return_tensors="pt")
with torch.no_grad():
    outputs = model(**inputs)

answer_start_index = outputs.start_logits.argmax()
answer_end_index = outputs.end_logits.argmax()

predict_answer_tokens = inputs.input_ids[0, answer_start_index : answer_end_index + 1]

# target is "nice puppet"
target_start_index = torch.tensor([14])
target_end_index = torch.tensor([15])

outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
loss = outputs.loss`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, RobertaPreLayerNormForQuestionAnswering
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = RobertaPreLayerNormForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predict_answer_tokens = inputs.input_ids[<span class="hljs-number">0</span>, answer_start_index : answer_end_index + <span class="hljs-number">1</span>]

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

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

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = TFRobertaPreLayerNormModel.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFRobertaPreLayerNormModel
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFRobertaPreLayerNormModel.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function cN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function pN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, TFRobertaPreLayerNormForCausalLM
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = TFRobertaPreLayerNormForCausalLM.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = TFRobertaPreLayerNormForMaskedLM.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

inputs = tokenizer("The capital of France is <mask>.", return_tensors="tf")
logits = model(**inputs).logits

# retrieve index of <mask>
mask_token_index = tf.where((inputs.input_ids == tokenizer.mask_token_id)[0])
selected_logits = tf.gather_nd(logits[0], indices=mask_token_index)

predicted_token_id = tf.math.argmax(selected_logits, axis=-1)
tokenizer.decode(predicted_token_id)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFRobertaPreLayerNormForMaskedLM
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFRobertaPreLayerNormForMaskedLM.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function fN(N){let d,y;return d=new Ie({props:{code:`labels = tokenizer("The capital of France is Paris.", return_tensors="tf")["input_ids"]
# mask labels of non-<mask> tokens
labels = tf.where(inputs.input_ids == tokenizer.mask_token_id, labels, -100)

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

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = TFRobertaPreLayerNormForSequenceClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

logits = model(**inputs).logits

predicted_class_id = int(tf.math.argmax(logits, axis=-1)[0])`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFRobertaPreLayerNormForSequenceClassification
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFRobertaPreLayerNormForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)

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

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

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

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = TFRobertaPreLayerNormForMultipleChoice.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

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

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = TFRobertaPreLayerNormForTokenClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

inputs = tokenizer(
    "HuggingFace is a company based in Paris and New York", add_special_tokens=False, return_tensors="tf"
)

logits = model(**inputs).logits
predicted_token_class_ids = tf.math.argmax(logits, axis=-1)

# Note that tokens are classified rather then input words which means that
# there might be more predicted token classes than words.
# Multiple token classes might account for the same word
predicted_tokens_classes = [model.config.id2label[t] for t in predicted_token_class_ids[0].numpy().tolist()]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFRobertaPreLayerNormForTokenClassification
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFRobertaPreLayerNormForTokenClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)

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

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

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

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = TFRobertaPreLayerNormForQuestionAnswering.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

question, text = "Who was Jim Henson?", "Jim Henson was a nice puppet"

inputs = tokenizer(question, text, return_tensors="tf")
outputs = model(**inputs)

answer_start_index = int(tf.math.argmax(outputs.start_logits, axis=-1)[0])
answer_end_index = int(tf.math.argmax(outputs.end_logits, axis=-1)[0])

predict_answer_tokens = inputs.input_ids[0, answer_start_index : answer_end_index + 1]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFRobertaPreLayerNormForQuestionAnswering
<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;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFRobertaPreLayerNormForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>predict_answer_tokens = inputs.input_ids[<span class="hljs-number">0</span>, answer_start_index : answer_end_index + <span class="hljs-number">1</span>]`}}),{c(){d=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function MN(N){let d,y;return d=new Ie({props:{code:`# target is "nice puppet"
target_start_index = tf.constant([14])
target_end_index = tf.constant([15])

outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
loss = tf.math.reduce_mean(outputs.loss)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># target is &quot;nice puppet&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>target_start_index = tf.constant([<span class="hljs-number">14</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>target_end_index = tf.constant([<span class="hljs-number">15</span>])

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, start_positions=target_start_index, end_positions=target_end_index)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(outputs.loss)`}}),{c(){v(d.$$.fragment)},l(h){T(d.$$.fragment,h)},m(h,u){w(d,h,u),y=!0},p:Oe,i(h){y||($(d.$$.fragment,h),y=!0)},o(h){P(d.$$.fragment,h),y=!1},d(h){F(d,h)}}}function EN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function RN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, FlaxRobertaPreLayerNormModel

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = FlaxRobertaPreLayerNormModel.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxRobertaPreLayerNormModel.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function zN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function CN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, FlaxRobertaPreLayerNormForCausalLM

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = FlaxRobertaPreLayerNormForCausalLM.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

# retrieve logts for next token
next_token_logits = outputs.logits[:, -1]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, FlaxRobertaPreLayerNormForCausalLM

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxRobertaPreLayerNormForCausalLM.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function qN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function jN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, FlaxRobertaPreLayerNormForMaskedLM

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = FlaxRobertaPreLayerNormForMaskedLM.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxRobertaPreLayerNormForMaskedLM.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function AN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function ON(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, FlaxRobertaPreLayerNormForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = FlaxRobertaPreLayerNormForSequenceClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxRobertaPreLayerNormForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function IN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function DN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, FlaxRobertaPreLayerNormForMultipleChoice

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = FlaxRobertaPreLayerNormForMultipleChoice.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxRobertaPreLayerNormForMultipleChoice.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function SN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function WN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, FlaxRobertaPreLayerNormForTokenClassification

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = FlaxRobertaPreLayerNormForTokenClassification.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxRobertaPreLayerNormForTokenClassification.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function UN(N){let d,y,h,u,g;return{c(){d=r("p"),y=o("Although the recipe for forward pass needs to be defined within this function, one should call the "),h=r("code"),u=o("Module"),g=o(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Although the recipe for forward pass needs to be defined within this function, one should call the "),h=a(c,"CODE",{});var x=s(h);u=n(x,"Module"),x.forEach(t),g=n(c,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),c.forEach(t)},m(l,c){_(l,d,c),e(d,y),e(d,h),e(h,u),e(d,g)},d(l){l&&t(d)}}}function BN(N){let d,y,h,u,g;return u=new Ie({props:{code:`from transformers import AutoTokenizer, FlaxRobertaPreLayerNormForQuestionAnswering

tokenizer = AutoTokenizer.from_pretrained("andreasmadsen/efficient_mlm_m0.40")
model = FlaxRobertaPreLayerNormForQuestionAnswering.from_pretrained("andreasmadsen/efficient_mlm_m0.40")

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

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

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxRobertaPreLayerNormForQuestionAnswering.from_pretrained(<span class="hljs-string">&quot;andreasmadsen/efficient_mlm_m0.40&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=r("p"),y=o("Example:"),h=p(),v(u.$$.fragment)},l(l){d=a(l,"P",{});var c=s(d);y=n(c,"Example:"),c.forEach(t),h=m(l),T(u.$$.fragment,l)},m(l,c){_(l,d,c),e(d,y),_(l,h,c),w(u,l,c),g=!0},p:Oe,i(l){g||($(u.$$.fragment,l),g=!0)},o(l){P(u.$$.fragment,l),g=!1},d(l){l&&t(d),l&&t(h),F(u,l)}}}function QN(N){let d,y,h,u,g,l,c,x,ye,he,D,ae,te,L,be,B,ke,ue,A,ve,se,K,Te,ce,V,we,ie,J,$e,fe,ee,R,C,le,Q,Pe,ge,U,Fe,_e,z,H,G,de,Ne,X,pe,Le,S,me,Y,xe,oe,q,Me,j,Ee,Re,k,M,Be,re,ze,Qe,E,He,Ke,De,Ve,Je,O,I,Ge,Se,Z,Xe,We,Ce,Ye,ne,qe,$n,Md,ga,Bu,Ed,Qu,Qm,qt,_a,Hu,ro,Ku,Tl,Vu,Ju,wl,Gu,Xu,ya,Yu,Zu,ef,No,tf,$l,of,nf,Pl,rf,af,sf,Pn,Hm,Lo,Fn,Rd,ba,lf,zd,df,Km,Ze,ka,cf,Cd,pf,mf,va,hf,Fl,uf,ff,gf,Ta,_f,wa,yf,bf,kf,$a,vf,qd,Tf,wf,$f,lt,Pf,jd,Ff,Nf,Ad,Lf,xf,Od,Mf,Ef,Id,Rf,zf,Dd,Cf,qf,Sd,jf,Af,Of,Nn,If,Wd,Df,Sf,Pa,Wf,Uf,jt,Fa,Bf,xo,Qf,Nl,Hf,Kf,Ud,Vf,Jf,Gf,Ln,Xf,xn,Vm,Mo,Mn,Bd,Na,Yf,Qd,Zf,Jm,gt,La,eg,xa,tg,Hd,og,ng,rg,Ma,ag,Ll,sg,ig,lg,Ea,dg,Ra,cg,pg,mg,At,za,hg,Eo,ug,xl,fg,gg,Kd,_g,yg,bg,En,kg,Rn,Gm,Ro,zn,Vd,Ca,vg,Jd,Tg,Xm,_t,qa,wg,ja,$g,Gd,Pg,Fg,Ng,Aa,Lg,Ml,xg,Mg,Eg,Oa,Rg,Ia,zg,Cg,qg,Ot,Da,jg,zo,Ag,El,Og,Ig,Xd,Dg,Sg,Wg,Cn,Ug,qn,Ym,Co,jn,Yd,Sa,Bg,Zd,Qg,Zm,yt,Wa,Hg,ec,Kg,Vg,Ua,Jg,Rl,Gg,Xg,Yg,Ba,Zg,Qa,e_,t_,o_,Tt,Ha,n_,qo,r_,zl,a_,s_,tc,i_,l_,d_,An,c_,On,p_,In,eh,jo,Dn,oc,Ka,m_,nc,h_,th,bt,Va,u_,rc,f_,g_,Ja,__,Cl,y_,b_,k_,Ga,v_,Xa,T_,w_,$_,It,Ya,P_,Ao,F_,ql,N_,L_,ac,x_,M_,E_,Sn,R_,Wn,oh,Oo,Un,sc,Za,z_,ic,C_,nh,kt,es,q_,lc,j_,A_,ts,O_,jl,I_,D_,S_,os,W_,ns,U_,B_,Q_,Dt,rs,H_,Io,K_,Al,V_,J_,dc,G_,X_,Y_,Bn,Z_,Qn,rh,Do,Hn,cc,as,ey,pc,ty,ah,vt,ss,oy,So,ny,mc,ry,ay,hc,sy,iy,ly,is,dy,Ol,cy,py,my,ls,hy,ds,uy,fy,gy,St,cs,_y,Wo,yy,Il,by,ky,uc,vy,Ty,wy,Kn,$y,Vn,sh,Uo,Jn,fc,ps,Py,gc,Fy,ih,dt,ms,Ny,_c,Ly,xy,hs,My,Dl,Ey,Ry,zy,us,Cy,fs,qy,jy,Ay,Gn,Oy,Wt,gs,Iy,Bo,Dy,Sl,Sy,Wy,yc,Uy,By,Qy,Xn,Hy,Yn,lh,Qo,Zn,bc,_s,Ky,kc,Vy,dh,Ho,ys,Jy,Ut,bs,Gy,Ko,Xy,Wl,Yy,Zy,vc,eb,tb,ob,er,nb,tr,ch,Vo,or,Tc,ks,rb,wc,ab,ph,ct,vs,sb,Ts,ib,$c,lb,db,cb,ws,pb,Ul,mb,hb,ub,$s,fb,Ps,gb,_b,yb,nr,bb,wt,Fs,kb,Jo,vb,Bl,Tb,wb,Pc,$b,Pb,Fb,rr,Nb,ar,Lb,sr,mh,Go,ir,Fc,Ns,xb,Nc,Mb,hh,pt,Ls,Eb,Lc,Rb,zb,xs,Cb,Ql,qb,jb,Ab,Ms,Ob,Es,Ib,Db,Sb,lr,Wb,$t,Rs,Ub,Xo,Bb,Hl,Qb,Hb,xc,Kb,Vb,Jb,dr,Gb,cr,Xb,pr,uh,Yo,mr,Mc,zs,Yb,Ec,Zb,fh,mt,Cs,ek,Rc,tk,ok,qs,nk,Kl,rk,ak,sk,js,ik,As,lk,dk,ck,hr,pk,Bt,Os,mk,Zo,hk,Vl,uk,fk,zc,gk,_k,yk,ur,bk,fr,gh,en,gr,Cc,Is,kk,qc,vk,_h,ht,Ds,Tk,jc,wk,$k,Ss,Pk,Jl,Fk,Nk,Lk,Ws,xk,Us,Mk,Ek,Rk,_r,zk,Pt,Bs,Ck,tn,qk,Gl,jk,Ak,Ac,Ok,Ik,Dk,yr,Sk,br,Wk,kr,yh,on,vr,Oc,Qs,Uk,Ic,Bk,bh,ut,Hs,Qk,nn,Hk,Dc,Kk,Vk,Sc,Jk,Gk,Xk,Ks,Yk,Xl,Zk,ev,tv,Vs,ov,Js,nv,rv,av,Tr,sv,Ft,Gs,iv,rn,lv,Yl,dv,cv,Wc,pv,mv,hv,wr,uv,$r,fv,Pr,kh,an,Fr,Uc,Xs,gv,Bc,_v,vh,et,Ys,yv,Qc,bv,kv,Zs,vv,Zl,Tv,wv,$v,ei,Pv,ti,Fv,Nv,Lv,Hc,xv,Mv,ao,Kc,oi,Ev,Rv,Vc,ni,zv,Cv,Jc,ri,qv,jv,Gc,ai,Av,Ov,Qt,si,Iv,sn,Dv,Xc,Sv,Wv,Yc,Uv,Bv,Qv,Nr,Hv,Lr,Th,ln,xr,Zc,ii,Kv,ep,Vv,wh,tt,li,Jv,tp,Gv,Xv,di,Yv,ed,Zv,eT,tT,ci,oT,pi,nT,rT,aT,op,sT,iT,so,np,mi,lT,dT,rp,hi,cT,pT,ap,ui,mT,hT,sp,fi,uT,fT,Ht,gi,gT,dn,_T,ip,yT,bT,lp,kT,vT,TT,Mr,wT,Er,$h,cn,Rr,dp,_i,$T,cp,PT,Ph,ot,yi,FT,bi,NT,pp,LT,xT,MT,ki,ET,td,RT,zT,CT,vi,qT,Ti,jT,AT,OT,mp,IT,DT,io,hp,wi,ST,WT,up,$i,UT,BT,fp,Pi,QT,HT,gp,Fi,KT,VT,Kt,Ni,JT,pn,GT,_p,XT,YT,yp,ZT,ew,tw,zr,ow,Cr,Fh,mn,qr,bp,Li,nw,kp,rw,Nh,nt,xi,aw,vp,sw,iw,Mi,lw,od,dw,cw,pw,Ei,mw,Ri,hw,uw,fw,Tp,gw,_w,lo,wp,zi,yw,bw,$p,Ci,kw,vw,Pp,qi,Tw,ww,Fp,ji,$w,Pw,Vt,Ai,Fw,hn,Nw,Np,Lw,xw,Lp,Mw,Ew,Rw,jr,zw,Ar,Lh,un,Or,xp,Oi,Cw,Mp,qw,xh,rt,Ii,jw,Ep,Aw,Ow,Di,Iw,nd,Dw,Sw,Ww,Si,Uw,Wi,Bw,Qw,Hw,Rp,Kw,Vw,co,zp,Ui,Jw,Gw,Cp,Bi,Xw,Yw,qp,Qi,Zw,e$,jp,Hi,t$,o$,Jt,Ki,n$,fn,r$,Ap,a$,s$,Op,i$,l$,d$,Ir,c$,Dr,Mh,gn,Sr,Ip,Vi,p$,Dp,m$,Eh,at,Ji,h$,Sp,u$,f$,Gi,g$,rd,_$,y$,b$,Xi,k$,Yi,v$,T$,w$,Wp,$$,P$,po,Up,Zi,F$,N$,Bp,el,L$,x$,Qp,tl,M$,E$,Hp,ol,R$,z$,Gt,nl,C$,_n,q$,Kp,j$,A$,Vp,O$,I$,D$,Wr,S$,Ur,Rh,yn,Br,Jp,rl,W$,Gp,U$,zh,st,al,B$,bn,Q$,Xp,H$,K$,Yp,V$,J$,G$,sl,X$,ad,Y$,Z$,e1,il,t1,ll,o1,n1,r1,Zp,a1,s1,mo,em,dl,i1,l1,tm,cl,d1,c1,om,pl,p1,m1,nm,ml,h1,u1,Xt,hl,f1,kn,g1,rm,_1,y1,am,b1,k1,v1,Qr,T1,Hr,Ch;return l=new Ue({}),L=new Ue({}),ga=new Ue({}),_a=new W({props:{name:"class transformers.RobertaPreLayerNormConfig",anchor:"transformers.RobertaPreLayerNormConfig",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.RobertaPreLayerNormConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 30522) &#x2014;
Vocabulary size of the RoBERTa-PreLayerNorm model. Defines the number of different tokens that can be
represented by the <code>inputs_ids</code> passed when calling <a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormModel">RobertaPreLayerNormModel</a> or
<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormModel">TFRobertaPreLayerNormModel</a>.`,name:"vocab_size"},{anchor:"transformers.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.type_vocab_size",description:`<strong>type_vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 2) &#x2014;
The vocabulary size of the <code>token_type_ids</code> passed when calling <a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormModel">RobertaPreLayerNormModel</a> or
<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormModel">TFRobertaPreLayerNormModel</a>.`,name:"type_vocab_size"},{anchor:"transformers.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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.RobertaPreLayerNormConfig.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/main/src/transformers/models/roberta_prelayernorm/configuration_roberta_prelayernorm.py#L35"}}),Pn=new Ae({props:{anchor:"transformers.RobertaPreLayerNormConfig.example",$$slots:{default:[Q2]},$$scope:{ctx:N}}}),ba=new Ue({}),ka=new W({props:{name:"class transformers.RobertaPreLayerNormModel",anchor:"transformers.RobertaPreLayerNormModel",parameters:[{name:"config",val:""},{name:"add_pooling_layer",val:" = True"}],parametersDescription:[{anchor:"transformers.RobertaPreLayerNormModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L700"}}),Fa=new W({props:{name:"forward",anchor:"transformers.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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.
This parameter can only be used when the model is initialized with <code>type_vocab_size</code> parameter with value<blockquote>
<p>= 2. All the value in this tensor should be always &lt; type_vocab_size.</p>
</blockquote></li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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.RobertaPreLayerNormModel.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/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L745",returnDescription:`
<p>A <a
  href="/docs/transformers/main/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/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</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/main/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ln=new je({props:{$$slots:{default:[H2]},$$scope:{ctx:N}}}),xn=new Ae({props:{anchor:"transformers.RobertaPreLayerNormModel.forward.example",$$slots:{default:[K2]},$$scope:{ctx:N}}}),Na=new Ue({}),La=new W({props:{name:"class transformers.RobertaPreLayerNormForCausalLM",anchor:"transformers.RobertaPreLayerNormForCausalLM",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.RobertaPreLayerNormForCausalLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L887"}}),za=new W({props:{name:"forward",anchor:"transformers.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.
This parameter can only be used when the model is initialized with <code>type_vocab_size</code> parameter with value<blockquote>
<p>= 2. All the value in this tensor should be always &lt; type_vocab_size.</p>
</blockquote></li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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.RobertaPreLayerNormForCausalLM.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/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L915",returnDescription:`
<p>A <a
  href="/docs/transformers/main/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/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</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/main/en/main_classes/output#transformers.modeling_outputs.CausalLMOutputWithCrossAttentions"
>transformers.modeling_outputs.CausalLMOutputWithCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),En=new je({props:{$$slots:{default:[V2]},$$scope:{ctx:N}}}),Rn=new Ae({props:{anchor:"transformers.RobertaPreLayerNormForCausalLM.forward.example",$$slots:{default:[J2]},$$scope:{ctx:N}}}),Ca=new Ue({}),qa=new W({props:{name:"class transformers.RobertaPreLayerNormForMaskedLM",anchor:"transformers.RobertaPreLayerNormForMaskedLM",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.RobertaPreLayerNormForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1043"}}),Da=new W({props:{name:"forward",anchor:"transformers.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.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.
This parameter can only be used when the model is initialized with <code>type_vocab_size</code> parameter with value<blockquote>
<p>= 2. All the value in this tensor should be always &lt; type_vocab_size.</p>
</blockquote></li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.RobertaPreLayerNormForMaskedLM.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.RobertaPreLayerNormForMaskedLM.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/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1073",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Cn=new je({props:{$$slots:{default:[G2]},$$scope:{ctx:N}}}),qn=new Ae({props:{anchor:"transformers.RobertaPreLayerNormForMaskedLM.forward.example",$$slots:{default:[X2]},$$scope:{ctx:N}}}),Sa=new Ue({}),Wa=new W({props:{name:"class transformers.RobertaPreLayerNormForSequenceClassification",anchor:"transformers.RobertaPreLayerNormForSequenceClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.RobertaPreLayerNormForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1180"}}),Ha=new W({props:{name:"forward",anchor:"transformers.RobertaPreLayerNormForSequenceClassification.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.RobertaPreLayerNormForSequenceClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.RobertaPreLayerNormForSequenceClassification.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.RobertaPreLayerNormForSequenceClassification.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.
This parameter can only be used when the model is initialized with <code>type_vocab_size</code> parameter with value<blockquote>
<p>= 2. All the value in this tensor should be always &lt; type_vocab_size.</p>
</blockquote></li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.RobertaPreLayerNormForSequenceClassification.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.RobertaPreLayerNormForSequenceClassification.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.RobertaPreLayerNormForSequenceClassification.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.RobertaPreLayerNormForSequenceClassification.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.RobertaPreLayerNormForSequenceClassification.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.RobertaPreLayerNormForSequenceClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.RobertaPreLayerNormForSequenceClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1194",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),An=new je({props:{$$slots:{default:[Y2]},$$scope:{ctx:N}}}),On=new Ae({props:{anchor:"transformers.RobertaPreLayerNormForSequenceClassification.forward.example",$$slots:{default:[Z2]},$$scope:{ctx:N}}}),In=new Ae({props:{anchor:"transformers.RobertaPreLayerNormForSequenceClassification.forward.example-2",$$slots:{default:[eN]},$$scope:{ctx:N}}}),Ka=new Ue({}),Va=new W({props:{name:"class transformers.RobertaPreLayerNormForMultipleChoice",anchor:"transformers.RobertaPreLayerNormForMultipleChoice",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.RobertaPreLayerNormForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1279"}}),Ya=new W({props:{name:"forward",anchor:"transformers.RobertaPreLayerNormForMultipleChoice.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.RobertaPreLayerNormForMultipleChoice.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.RobertaPreLayerNormForMultipleChoice.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.RobertaPreLayerNormForMultipleChoice.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.
This parameter can only be used when the model is initialized with <code>type_vocab_size</code> parameter with value<blockquote>
<p>= 2. All the value in this tensor should be always &lt; type_vocab_size.</p>
</blockquote></li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.RobertaPreLayerNormForMultipleChoice.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.RobertaPreLayerNormForMultipleChoice.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.RobertaPreLayerNormForMultipleChoice.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.RobertaPreLayerNormForMultipleChoice.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.RobertaPreLayerNormForMultipleChoice.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.RobertaPreLayerNormForMultipleChoice.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.RobertaPreLayerNormForMultipleChoice.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the multiple choice classification loss. Indices should be in <code>[0, ..., num_choices-1]</code> where <code>num_choices</code> is the size of the second dimension of the input tensors. (See
<code>input_ids</code> above)`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1292",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <em>(1,)</em>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.MultipleChoiceModelOutput"
>transformers.modeling_outputs.MultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Sn=new je({props:{$$slots:{default:[tN]},$$scope:{ctx:N}}}),Wn=new Ae({props:{anchor:"transformers.RobertaPreLayerNormForMultipleChoice.forward.example",$$slots:{default:[oN]},$$scope:{ctx:N}}}),Za=new Ue({}),es=new W({props:{name:"class transformers.RobertaPreLayerNormForTokenClassification",anchor:"transformers.RobertaPreLayerNormForTokenClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.RobertaPreLayerNormForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1373"}}),rs=new W({props:{name:"forward",anchor:"transformers.RobertaPreLayerNormForTokenClassification.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.RobertaPreLayerNormForTokenClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.RobertaPreLayerNormForTokenClassification.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.RobertaPreLayerNormForTokenClassification.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.
This parameter can only be used when the model is initialized with <code>type_vocab_size</code> parameter with value<blockquote>
<p>= 2. All the value in this tensor should be always &lt; type_vocab_size.</p>
</blockquote></li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.RobertaPreLayerNormForTokenClassification.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.RobertaPreLayerNormForTokenClassification.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.RobertaPreLayerNormForTokenClassification.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.RobertaPreLayerNormForTokenClassification.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.RobertaPreLayerNormForTokenClassification.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.RobertaPreLayerNormForTokenClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.RobertaPreLayerNormForTokenClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1391",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Bn=new je({props:{$$slots:{default:[nN]},$$scope:{ctx:N}}}),Qn=new Ae({props:{anchor:"transformers.RobertaPreLayerNormForTokenClassification.forward.example",$$slots:{default:[rN]},$$scope:{ctx:N}}}),as=new Ue({}),ss=new W({props:{name:"class transformers.RobertaPreLayerNormForQuestionAnswering",anchor:"transformers.RobertaPreLayerNormForQuestionAnswering",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.RobertaPreLayerNormForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1481"}}),cs=new W({props:{name:"forward",anchor:"transformers.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.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.
This parameter can only be used when the model is initialized with <code>type_vocab_size</code> parameter with value<blockquote>
<p>= 2. All the value in this tensor should be always &lt; type_vocab_size.</p>
</blockquote></li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.RobertaPreLayerNormForQuestionAnswering.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.RobertaPreLayerNormForQuestionAnswering.forward.end_positions",description:`<strong>end_positions</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the end of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"end_positions"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_roberta_prelayernorm.py#L1495",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Total span extraction loss is the sum of a Cross-Entropy for the start and end positions.</p>
</li>
<li>
<p><strong>start_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.QuestionAnsweringModelOutput"
>transformers.modeling_outputs.QuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Kn=new je({props:{$$slots:{default:[aN]},$$scope:{ctx:N}}}),Vn=new Ae({props:{anchor:"transformers.RobertaPreLayerNormForQuestionAnswering.forward.example",$$slots:{default:[sN]},$$scope:{ctx:N}}}),ps=new Ue({}),ms=new W({props:{name:"class transformers.TFRobertaPreLayerNormModel",anchor:"transformers.TFRobertaPreLayerNormModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L924"}}),Gn=new je({props:{$$slots:{default:[iN]},$$scope:{ctx:N}}}),gs=new W({props:{name:"call",anchor:"transformers.TFRobertaPreLayerNormModel.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_hidden_states",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"past_key_values",val:": typing.Union[typing.Tuple[typing.Tuple[typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor]]], NoneType] = 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"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormModel.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFRobertaPreLayerNormModel.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFRobertaPreLayerNormModel.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFRobertaPreLayerNormModel.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.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.TFRobertaPreLayerNormModel.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/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L929",returnDescription:`
<p>A <a
  href="/docs/transformers/main/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/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</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/main/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Xn=new je({props:{$$slots:{default:[lN]},$$scope:{ctx:N}}}),Yn=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormModel.call.example",$$slots:{default:[dN]},$$scope:{ctx:N}}}),_s=new Ue({}),ys=new W({props:{name:"class transformers.TFRobertaPreLayerNormForCausalLM",anchor:"transformers.TFRobertaPreLayerNormForCausalLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1159"}}),bs=new W({props:{name:"call",anchor:"transformers.TFRobertaPreLayerNormForCausalLM.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_hidden_states",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"past_key_values",val:": typing.Union[typing.Tuple[typing.Tuple[typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor]]], NoneType] = 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"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForCausalLM.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFRobertaPreLayerNormForCausalLM.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFRobertaPreLayerNormForCausalLM.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFRobertaPreLayerNormForCausalLM.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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.TFRobertaPreLayerNormForCausalLM.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/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1198",returnDescription:`
<p>A <a
  href="/docs/transformers/main/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/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</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/main/en/main_classes/output#transformers.modeling_tf_outputs.TFCausalLMOutputWithCrossAttentions"
>transformers.modeling_tf_outputs.TFCausalLMOutputWithCrossAttentions</a> or <code>tuple(tf.Tensor)</code></p>
`}}),er=new je({props:{$$slots:{default:[cN]},$$scope:{ctx:N}}}),tr=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForCausalLM.call.example",$$slots:{default:[pN]},$$scope:{ctx:N}}}),ks=new Ue({}),vs=new W({props:{name:"class transformers.TFRobertaPreLayerNormForMaskedLM",anchor:"transformers.TFRobertaPreLayerNormForMaskedLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1070"}}),nr=new je({props:{$$slots:{default:[mN]},$$scope:{ctx:N}}}),Fs=new W({props:{name:"call",anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.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.TFRobertaPreLayerNormForMaskedLM.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.TFRobertaPreLayerNormForMaskedLM.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.TFRobertaPreLayerNormForMaskedLM.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.TFRobertaPreLayerNormForMaskedLM.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.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.TFRobertaPreLayerNormForMaskedLM.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the masked language modeling loss. Indices should be in <code>[-100, 0, ..., config.vocab_size]</code> (see <code>input_ids</code> docstring) Tokens with indices set to <code>-100</code> are ignored (masked), the
loss is only computed for the tokens with labels in <code>[0, ..., config.vocab_size]</code>`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1090",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of non-masked labels, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),rr=new je({props:{$$slots:{default:[hN]},$$scope:{ctx:N}}}),ar=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.call.example",$$slots:{default:[uN]},$$scope:{ctx:N}}}),sr=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForMaskedLM.call.example-2",$$slots:{default:[fN]},$$scope:{ctx:N}}}),Ns=new Ue({}),Ls=new W({props:{name:"class transformers.TFRobertaPreLayerNormForSequenceClassification",anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1337"}}),lr=new je({props:{$$slots:{default:[gN]},$$scope:{ctx:N}}}),Rs=new W({props:{name:"call",anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.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.TFRobertaPreLayerNormForSequenceClassification.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.TFRobertaPreLayerNormForSequenceClassification.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.TFRobertaPreLayerNormForSequenceClassification.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.TFRobertaPreLayerNormForSequenceClassification.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.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.TFRobertaPreLayerNormForSequenceClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1352",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, )</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),dr=new je({props:{$$slots:{default:[_N]},$$scope:{ctx:N}}}),cr=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.call.example",$$slots:{default:[yN]},$$scope:{ctx:N}}}),pr=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForSequenceClassification.call.example-2",$$slots:{default:[bN]},$$scope:{ctx:N}}}),zs=new Ue({}),Cs=new W({props:{name:"class transformers.TFRobertaPreLayerNormForMultipleChoice",anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1424"}}),hr=new je({props:{$$slots:{default:[kN]},$$scope:{ctx:N}}}),Os=new W({props:{name:"call",anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, num_choices, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.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.TFRobertaPreLayerNormForMultipleChoice.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.TFRobertaPreLayerNormForMultipleChoice.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.TFRobertaPreLayerNormForMultipleChoice.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.TFRobertaPreLayerNormForMultipleChoice.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.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.TFRobertaPreLayerNormForMultipleChoice.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the multiple choice classification loss. Indices should be in <code>[0, ..., num_choices]</code>
where <code>num_choices</code> is the size of the second dimension of the input tensors. (See <code>input_ids</code> above)`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1448",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <em>(batch_size, )</em>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput"
>transformers.modeling_tf_outputs.TFMultipleChoiceModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),ur=new je({props:{$$slots:{default:[vN]},$$scope:{ctx:N}}}),fr=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForMultipleChoice.call.example",$$slots:{default:[TN]},$$scope:{ctx:N}}}),Is=new Ue({}),Ds=new W({props:{name:"class transformers.TFRobertaPreLayerNormForTokenClassification",anchor:"transformers.TFRobertaPreLayerNormForTokenClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1546"}}),_r=new je({props:{$$slots:{default:[wN]},$$scope:{ctx:N}}}),Bs=new W({props:{name:"call",anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.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.TFRobertaPreLayerNormForTokenClassification.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.TFRobertaPreLayerNormForTokenClassification.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.TFRobertaPreLayerNormForTokenClassification.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.TFRobertaPreLayerNormForTokenClassification.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.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.TFRobertaPreLayerNormForTokenClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1566",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of unmasked labels, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),yr=new je({props:{$$slots:{default:[$N]},$$scope:{ctx:N}}}),br=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.call.example",$$slots:{default:[PN]},$$scope:{ctx:N}}}),kr=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForTokenClassification.call.example-2",$$slots:{default:[FN]},$$scope:{ctx:N}}}),Qs=new Ue({}),Hs=new W({props:{name:"class transformers.TFRobertaPreLayerNormForQuestionAnswering",anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1637"}}),Tr=new je({props:{$$slots:{default:[NN]},$$scope:{ctx:N}}}),Gs=new W({props:{name:"call",anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"token_type_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"start_positions",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"end_positions",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.call.input_ids",description:`<strong>input_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.call.attention_mask",description:`<strong>attention_mask</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.call.token_type_ids",description:`<strong>token_type_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Segment token indices to indicate first and second portions of the inputs. Indices are selected in <code>[0, 1]</code>:</p>
<ul>
<li>0 corresponds to a <em>sentence A</em> token,</li>
<li>1 corresponds to a <em>sentence B</em> token.</li>
</ul>
<p><a href="../glossary#token-type-ids">What are token type IDs?</a>`,name:"token_type_ids"},{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.call.position_ids",description:`<strong>position_ids</strong> (<code>Numpy array</code> or <code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.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.TFRobertaPreLayerNormForQuestionAnswering.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.TFRobertaPreLayerNormForQuestionAnswering.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.TFRobertaPreLayerNormForQuestionAnswering.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.TFRobertaPreLayerNormForQuestionAnswering.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.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.TFRobertaPreLayerNormForQuestionAnswering.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.TFRobertaPreLayerNormForQuestionAnswering.call.end_positions",description:`<strong>end_positions</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for position (index) of the end of the labelled span for computing the token classification loss.
Positions are clamped to the length of the sequence (<code>sequence_length</code>). Position outside of the sequence
are not taken into account for computing the loss.`,name:"end_positions"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_tf_roberta_prelayernorm.py#L1652",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, )</code>, <em>optional</em>, returned when <code>start_positions</code> and <code>end_positions</code> are provided) \u2014 Total span extraction loss is the sum of a Cross-Entropy for the start and end positions.</p>
</li>
<li>
<p><strong>start_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput"
>transformers.modeling_tf_outputs.TFQuestionAnsweringModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),wr=new je({props:{$$slots:{default:[LN]},$$scope:{ctx:N}}}),$r=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.call.example",$$slots:{default:[xN]},$$scope:{ctx:N}}}),Pr=new Ae({props:{anchor:"transformers.TFRobertaPreLayerNormForQuestionAnswering.call.example-2",$$slots:{default:[MN]},$$scope:{ctx:N}}}),Xs=new Ue({}),Ys=new W({props:{name:"class transformers.FlaxRobertaPreLayerNormModel",anchor:"transformers.FlaxRobertaPreLayerNormModel",parameters:[{name:"config",val:": RobertaPreLayerNormConfig"},{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.FlaxRobertaPreLayerNormModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L996"}}),si=new W({props:{name:"__call__",anchor:"transformers.FlaxRobertaPreLayerNormModel.__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.FlaxRobertaPreLayerNormModel.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxRobertaPreLayerNormModel.__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.FlaxRobertaPreLayerNormModel.__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.FlaxRobertaPreLayerNormModel.__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.FlaxRobertaPreLayerNormModel.__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.FlaxRobertaPreLayerNormModel.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L820",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>pooler_output</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) further processed by a
Linear layer and a Tanh activation function. The Linear layer weights are trained from the next sentence
prediction (classification) objective during pretraining.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Nr=new je({props:{$$slots:{default:[EN]},$$scope:{ctx:N}}}),Lr=new Ae({props:{anchor:"transformers.FlaxRobertaPreLayerNormModel.__call__.example",$$slots:{default:[RN]},$$scope:{ctx:N}}}),ii=new Ue({}),li=new W({props:{name:"class transformers.FlaxRobertaPreLayerNormForCausalLM",anchor:"transformers.FlaxRobertaPreLayerNormForCausalLM",parameters:[{name:"config",val:": RobertaPreLayerNormConfig"},{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.FlaxRobertaPreLayerNormForCausalLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L1479"}}),gi=new W({props:{name:"__call__",anchor:"transformers.FlaxRobertaPreLayerNormForCausalLM.__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.FlaxRobertaPreLayerNormForCausalLM.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxRobertaPreLayerNormForCausalLM.__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.FlaxRobertaPreLayerNormForCausalLM.__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.FlaxRobertaPreLayerNormForCausalLM.__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.FlaxRobertaPreLayerNormForCausalLM.__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.FlaxRobertaPreLayerNormForCausalLM.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L820",returnDescription:`
<p>A <a
  href="/docs/transformers/main/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/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</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/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions"
>transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Mr=new je({props:{$$slots:{default:[zN]},$$scope:{ctx:N}}}),Er=new Ae({props:{anchor:"transformers.FlaxRobertaPreLayerNormForCausalLM.__call__.example",$$slots:{default:[CN]},$$scope:{ctx:N}}}),_i=new Ue({}),yi=new W({props:{name:"class transformers.FlaxRobertaPreLayerNormForMaskedLM",anchor:"transformers.FlaxRobertaPreLayerNormForMaskedLM",parameters:[{name:"config",val:": RobertaPreLayerNormConfig"},{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.FlaxRobertaPreLayerNormForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L1073"}}),Ni=new W({props:{name:"__call__",anchor:"transformers.FlaxRobertaPreLayerNormForMaskedLM.__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.FlaxRobertaPreLayerNormForMaskedLM.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxRobertaPreLayerNormForMaskedLM.__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.FlaxRobertaPreLayerNormForMaskedLM.__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.FlaxRobertaPreLayerNormForMaskedLM.__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.FlaxRobertaPreLayerNormForMaskedLM.__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.FlaxRobertaPreLayerNormForMaskedLM.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L820",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>pooler_output</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) further processed by a
Linear layer and a Tanh activation function. The Linear layer weights are trained from the next sentence
prediction (classification) objective during pretraining.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPooling</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),zr=new je({props:{$$slots:{default:[qN]},$$scope:{ctx:N}}}),Cr=new Ae({props:{anchor:"transformers.FlaxRobertaPreLayerNormForMaskedLM.__call__.example",$$slots:{default:[jN]},$$scope:{ctx:N}}}),Li=new Ue({}),xi=new W({props:{name:"class transformers.FlaxRobertaPreLayerNormForSequenceClassification",anchor:"transformers.FlaxRobertaPreLayerNormForSequenceClassification",parameters:[{name:"config",val:": RobertaPreLayerNormConfig"},{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.FlaxRobertaPreLayerNormForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L1147"}}),Ai=new W({props:{name:"__call__",anchor:"transformers.FlaxRobertaPreLayerNormForSequenceClassification.__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.FlaxRobertaPreLayerNormForSequenceClassification.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxRobertaPreLayerNormForSequenceClassification.__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.FlaxRobertaPreLayerNormForSequenceClassification.__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.FlaxRobertaPreLayerNormForSequenceClassification.__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.FlaxRobertaPreLayerNormForSequenceClassification.__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.FlaxRobertaPreLayerNormForSequenceClassification.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L820",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput"
>transformers.modeling_flax_outputs.FlaxSequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),jr=new je({props:{$$slots:{default:[AN]},$$scope:{ctx:N}}}),Ar=new Ae({props:{anchor:"transformers.FlaxRobertaPreLayerNormForSequenceClassification.__call__.example",$$slots:{default:[ON]},$$scope:{ctx:N}}}),Oi=new Ue({}),Ii=new W({props:{name:"class transformers.FlaxRobertaPreLayerNormForMultipleChoice",anchor:"transformers.FlaxRobertaPreLayerNormForMultipleChoice",parameters:[{name:"config",val:": RobertaPreLayerNormConfig"},{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.FlaxRobertaPreLayerNormForMultipleChoice.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L1229"}}),Ki=new W({props:{name:"__call__",anchor:"transformers.FlaxRobertaPreLayerNormForMultipleChoice.__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.FlaxRobertaPreLayerNormForMultipleChoice.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, num_choices, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxRobertaPreLayerNormForMultipleChoice.__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.FlaxRobertaPreLayerNormForMultipleChoice.__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.FlaxRobertaPreLayerNormForMultipleChoice.__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.FlaxRobertaPreLayerNormForMultipleChoice.__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.FlaxRobertaPreLayerNormForMultipleChoice.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L820",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, num_choices)</code>) \u2014 <em>num_choices</em> is the second dimension of the input tensors. (see <em>input_ids</em> above).</p>
<p>Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput"
>transformers.modeling_flax_outputs.FlaxMultipleChoiceModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ir=new je({props:{$$slots:{default:[IN]},$$scope:{ctx:N}}}),Dr=new Ae({props:{anchor:"transformers.FlaxRobertaPreLayerNormForMultipleChoice.__call__.example",$$slots:{default:[DN]},$$scope:{ctx:N}}}),Vi=new Ue({}),Ji=new W({props:{name:"class transformers.FlaxRobertaPreLayerNormForTokenClassification",anchor:"transformers.FlaxRobertaPreLayerNormForTokenClassification",parameters:[{name:"config",val:": RobertaPreLayerNormConfig"},{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.FlaxRobertaPreLayerNormForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L1313"}}),nl=new W({props:{name:"__call__",anchor:"transformers.FlaxRobertaPreLayerNormForTokenClassification.__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.FlaxRobertaPreLayerNormForTokenClassification.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxRobertaPreLayerNormForTokenClassification.__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.FlaxRobertaPreLayerNormForTokenClassification.__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.FlaxRobertaPreLayerNormForTokenClassification.__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.FlaxRobertaPreLayerNormForTokenClassification.__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.FlaxRobertaPreLayerNormForTokenClassification.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L820",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxTokenClassifierOutput"
>transformers.modeling_flax_outputs.FlaxTokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Wr=new je({props:{$$slots:{default:[SN]},$$scope:{ctx:N}}}),Ur=new Ae({props:{anchor:"transformers.FlaxRobertaPreLayerNormForTokenClassification.__call__.example",$$slots:{default:[WN]},$$scope:{ctx:N}}}),rl=new Ue({}),al=new W({props:{name:"class transformers.FlaxRobertaPreLayerNormForQuestionAnswering",anchor:"transformers.FlaxRobertaPreLayerNormForQuestionAnswering",parameters:[{name:"config",val:": RobertaPreLayerNormConfig"},{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.FlaxRobertaPreLayerNormForQuestionAnswering.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig">RobertaPreLayerNormConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L1391"}}),hl=new W({props:{name:"__call__",anchor:"transformers.FlaxRobertaPreLayerNormForQuestionAnswering.__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.FlaxRobertaPreLayerNormForQuestionAnswering.__call__.input_ids",description:`<strong>input_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.FlaxRobertaPreLayerNormForQuestionAnswering.__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.FlaxRobertaPreLayerNormForQuestionAnswering.__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.FlaxRobertaPreLayerNormForQuestionAnswering.__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.FlaxRobertaPreLayerNormForQuestionAnswering.__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.FlaxRobertaPreLayerNormForQuestionAnswering.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta_prelayernorm/modeling_flax_roberta_prelayernorm.py#L820",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormConfig"
>RobertaPreLayerNormConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>start_logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-start scores (before SoftMax).</p>
</li>
<li>
<p><strong>end_logits</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) \u2014 Span-end scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput"
>transformers.modeling_flax_outputs.FlaxQuestionAnsweringModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Qr=new je({props:{$$slots:{default:[UN]},$$scope:{ctx:N}}}),Hr=new Ae({props:{anchor:"transformers.FlaxRobertaPreLayerNormForQuestionAnswering.__call__.example",$$slots:{default:[BN]},$$scope:{ctx:N}}}),{c(){d=r("meta"),y=p(),h=r("h1"),u=r("a"),g=r("span"),v(l.$$.fragment),c=p(),x=r("span"),ye=o("RoBERTa-PreLayerNorm"),he=p(),D=r("h2"),ae=r("a"),te=r("span"),v(L.$$.fragment),be=p(),B=r("span"),ke=o("Overview"),ue=p(),A=r("p"),ve=o("The RoBERTa-PreLayerNorm model was proposed in "),se=r("a"),K=o("fairseq: A Fast, Extensible Toolkit for Sequence Modeling"),Te=o(` by Myle Ott, Sergey Edunov, Alexei Baevski, Angela Fan, Sam Gross, Nathan Ng, David Grangier, Michael Auli.
It is identical to using the `),ce=r("code"),V=o("--encoder-normalize-before"),we=o(" flag in "),ie=r("a"),J=o("fairseq"),$e=o("."),fe=p(),ee=r("p"),R=o("The abstract from the paper is the following:"),C=p(),le=r("p"),Q=r("em"),Pe=o("fairseq is an open-source sequence modeling toolkit that allows researchers and developers to train custom models for translation, summarization, language modeling, and other text generation tasks. The toolkit is based on PyTorch and supports distributed training across multiple GPUs and machines. We also support fast mixed-precision training and inference on modern GPUs."),ge=p(),U=r("p"),Fe=o("Tips:"),_e=p(),z=r("ul"),H=r("li"),G=o("The implementation is the same as "),de=r("a"),Ne=o("Roberta"),X=o(" except instead of using "),pe=r("em"),Le=o("Add and Norm"),S=o(" it does "),me=r("em"),Y=o("Norm and Add"),xe=o(". "),oe=r("em"),q=o("Add"),Me=o(" and "),j=r("em"),Ee=o("Norm"),Re=o(" refers to the Addition and LayerNormalization as described in "),k=r("a"),M=o("Attention Is All You Need"),Be=o("."),re=p(),ze=r("li"),Qe=o("This is identical to using the "),E=r("code"),He=o("--encoder-normalize-before"),Ke=o(" flag in "),De=r("a"),Ve=o("fairseq"),Je=o("."),O=p(),I=r("p"),Ge=o("This model was contributed by "),Se=r("a"),Z=o("andreasmaden"),Xe=o(`.
The original code can be found `),We=r("a"),Ce=o("here"),Ye=o("."),ne=p(),qe=r("h2"),$n=r("a"),Md=r("span"),v(ga.$$.fragment),Bu=p(),Ed=r("span"),Qu=o("RobertaPreLayerNormConfig"),Qm=p(),qt=r("div"),v(_a.$$.fragment),Hu=p(),ro=r("p"),Ku=o("This is the configuration class to store the configuration of a "),Tl=r("a"),Vu=o("RobertaPreLayerNormModel"),Ju=o(` or a
`),wl=r("a"),Gu=o("TFRobertaPreLayerNormModel"),Xu=o(`. It is used to instantiate a RoBERTa-PreLayerNorm 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 RoBERTa-PreLayerNorm
`),ya=r("a"),Yu=o("andreasmadsen/efficient_mlm_m0.40"),Zu=o(" architecture."),ef=p(),No=r("p"),tf=o("Configuration objects inherit from "),$l=r("a"),of=o("PretrainedConfig"),nf=o(` and can be used to control the model outputs. Read the
documentation from `),Pl=r("a"),rf=o("PretrainedConfig"),af=o(" for more information."),sf=p(),v(Pn.$$.fragment),Hm=p(),Lo=r("h2"),Fn=r("a"),Rd=r("span"),v(ba.$$.fragment),lf=p(),zd=r("span"),df=o("RobertaPreLayerNormModel"),Km=p(),Ze=r("div"),v(ka.$$.fragment),cf=p(),Cd=r("p"),pf=o("The bare RoBERTa-PreLayerNorm Model transformer outputting raw hidden-states without any specific head on top."),mf=p(),va=r("p"),hf=o("This model inherits from "),Fl=r("a"),uf=o("PreTrainedModel"),ff=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.)`),gf=p(),Ta=r("p"),_f=o("This model is also a PyTorch "),wa=r("a"),yf=o("torch.nn.Module"),bf=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),kf=p(),$a=r("p"),vf=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 `),qd=r("em"),Tf=o(`Attention is
all you need`),wf=o(`_ by Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz
Kaiser and Illia Polosukhin.`),$f=p(),lt=r("p"),Pf=o("To behave as an decoder the model needs to be initialized with the "),jd=r("code"),Ff=o("is_decoder"),Nf=o(` argument of the configuration set
to `),Ad=r("code"),Lf=o("True"),xf=o(". To be used in a Seq2Seq model, the model needs to initialized with both "),Od=r("code"),Mf=o("is_decoder"),Ef=o(` argument and
`),Id=r("code"),Rf=o("add_cross_attention"),zf=o(" set to "),Dd=r("code"),Cf=o("True"),qf=o("; an "),Sd=r("code"),jf=o("encoder_hidden_states"),Af=o(" is then expected as an input to the forward pass."),Of=p(),Nn=r("p"),If=o(".. _"),Wd=r("em"),Df=o("Attention is all you need"),Sf=o(": "),Pa=r("a"),Wf=o("https://arxiv.org/abs/1706.03762"),Uf=p(),jt=r("div"),v(Fa.$$.fragment),Bf=p(),xo=r("p"),Qf=o("The "),Nl=r("a"),Hf=o("RobertaPreLayerNormModel"),Kf=o(" forward method, overrides the "),Ud=r("code"),Vf=o("__call__"),Jf=o(" special method."),Gf=p(),v(Ln.$$.fragment),Xf=p(),v(xn.$$.fragment),Vm=p(),Mo=r("h2"),Mn=r("a"),Bd=r("span"),v(Na.$$.fragment),Yf=p(),Qd=r("span"),Zf=o("RobertaPreLayerNormForCausalLM"),Jm=p(),gt=r("div"),v(La.$$.fragment),eg=p(),xa=r("p"),tg=o("RoBERTa-PreLayerNorm Model with a "),Hd=r("code"),og=o("language modeling"),ng=o(" head on top for CLM fine-tuning."),rg=p(),Ma=r("p"),ag=o("This model inherits from "),Ll=r("a"),sg=o("PreTrainedModel"),ig=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.)`),lg=p(),Ea=r("p"),dg=o("This model is also a PyTorch "),Ra=r("a"),cg=o("torch.nn.Module"),pg=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),mg=p(),At=r("div"),v(za.$$.fragment),hg=p(),Eo=r("p"),ug=o("The "),xl=r("a"),fg=o("RobertaPreLayerNormForCausalLM"),gg=o(" forward method, overrides the "),Kd=r("code"),_g=o("__call__"),yg=o(" special method."),bg=p(),v(En.$$.fragment),kg=p(),v(Rn.$$.fragment),Gm=p(),Ro=r("h2"),zn=r("a"),Vd=r("span"),v(Ca.$$.fragment),vg=p(),Jd=r("span"),Tg=o("RobertaPreLayerNormForMaskedLM"),Xm=p(),_t=r("div"),v(qa.$$.fragment),wg=p(),ja=r("p"),$g=o("RoBERTa-PreLayerNorm Model with a "),Gd=r("code"),Pg=o("language modeling"),Fg=o(" head on top."),Ng=p(),Aa=r("p"),Lg=o("This model inherits from "),Ml=r("a"),xg=o("PreTrainedModel"),Mg=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.)`),Eg=p(),Oa=r("p"),Rg=o("This model is also a PyTorch "),Ia=r("a"),zg=o("torch.nn.Module"),Cg=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),qg=p(),Ot=r("div"),v(Da.$$.fragment),jg=p(),zo=r("p"),Ag=o("The "),El=r("a"),Og=o("RobertaPreLayerNormForMaskedLM"),Ig=o(" forward method, overrides the "),Xd=r("code"),Dg=o("__call__"),Sg=o(" special method."),Wg=p(),v(Cn.$$.fragment),Ug=p(),v(qn.$$.fragment),Ym=p(),Co=r("h2"),jn=r("a"),Yd=r("span"),v(Sa.$$.fragment),Bg=p(),Zd=r("span"),Qg=o("RobertaPreLayerNormForSequenceClassification"),Zm=p(),yt=r("div"),v(Wa.$$.fragment),Hg=p(),ec=r("p"),Kg=o(`RoBERTa-PreLayerNorm Model transformer with a sequence classification/regression head on top (a linear layer on top
of the pooled output) e.g. for GLUE tasks.`),Vg=p(),Ua=r("p"),Jg=o("This model inherits from "),Rl=r("a"),Gg=o("PreTrainedModel"),Xg=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.)`),Yg=p(),Ba=r("p"),Zg=o("This model is also a PyTorch "),Qa=r("a"),e_=o("torch.nn.Module"),t_=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),o_=p(),Tt=r("div"),v(Ha.$$.fragment),n_=p(),qo=r("p"),r_=o("The "),zl=r("a"),a_=o("RobertaPreLayerNormForSequenceClassification"),s_=o(" forward method, overrides the "),tc=r("code"),i_=o("__call__"),l_=o(" special method."),d_=p(),v(An.$$.fragment),c_=p(),v(On.$$.fragment),p_=p(),v(In.$$.fragment),eh=p(),jo=r("h2"),Dn=r("a"),oc=r("span"),v(Ka.$$.fragment),m_=p(),nc=r("span"),h_=o("RobertaPreLayerNormForMultipleChoice"),th=p(),bt=r("div"),v(Va.$$.fragment),u_=p(),rc=r("p"),f_=o(`RobertaPreLayerNorm 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.`),g_=p(),Ja=r("p"),__=o("This model inherits from "),Cl=r("a"),y_=o("PreTrainedModel"),b_=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.)`),k_=p(),Ga=r("p"),v_=o("This model is also a PyTorch "),Xa=r("a"),T_=o("torch.nn.Module"),w_=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),$_=p(),It=r("div"),v(Ya.$$.fragment),P_=p(),Ao=r("p"),F_=o("The "),ql=r("a"),N_=o("RobertaPreLayerNormForMultipleChoice"),L_=o(" forward method, overrides the "),ac=r("code"),x_=o("__call__"),M_=o(" special method."),E_=p(),v(Sn.$$.fragment),R_=p(),v(Wn.$$.fragment),oh=p(),Oo=r("h2"),Un=r("a"),sc=r("span"),v(Za.$$.fragment),z_=p(),ic=r("span"),C_=o("RobertaPreLayerNormForTokenClassification"),nh=p(),kt=r("div"),v(es.$$.fragment),q_=p(),lc=r("p"),j_=o(`RobertaPreLayerNorm 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.`),A_=p(),ts=r("p"),O_=o("This model inherits from "),jl=r("a"),I_=o("PreTrainedModel"),D_=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.)`),S_=p(),os=r("p"),W_=o("This model is also a PyTorch "),ns=r("a"),U_=o("torch.nn.Module"),B_=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Q_=p(),Dt=r("div"),v(rs.$$.fragment),H_=p(),Io=r("p"),K_=o("The "),Al=r("a"),V_=o("RobertaPreLayerNormForTokenClassification"),J_=o(" forward method, overrides the "),dc=r("code"),G_=o("__call__"),X_=o(" special method."),Y_=p(),v(Bn.$$.fragment),Z_=p(),v(Qn.$$.fragment),rh=p(),Do=r("h2"),Hn=r("a"),cc=r("span"),v(as.$$.fragment),ey=p(),pc=r("span"),ty=o("RobertaPreLayerNormForQuestionAnswering"),ah=p(),vt=r("div"),v(ss.$$.fragment),oy=p(),So=r("p"),ny=o(`RobertaPreLayerNorm 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 `),mc=r("code"),ry=o("span start logits"),ay=o(" and "),hc=r("code"),sy=o("span end logits"),iy=o(")."),ly=p(),is=r("p"),dy=o("This model inherits from "),Ol=r("a"),cy=o("PreTrainedModel"),py=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.)`),my=p(),ls=r("p"),hy=o("This model is also a PyTorch "),ds=r("a"),uy=o("torch.nn.Module"),fy=o(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),gy=p(),St=r("div"),v(cs.$$.fragment),_y=p(),Wo=r("p"),yy=o("The "),Il=r("a"),by=o("RobertaPreLayerNormForQuestionAnswering"),ky=o(" forward method, overrides the "),uc=r("code"),vy=o("__call__"),Ty=o(" special method."),wy=p(),v(Kn.$$.fragment),$y=p(),v(Vn.$$.fragment),sh=p(),Uo=r("h2"),Jn=r("a"),fc=r("span"),v(ps.$$.fragment),Py=p(),gc=r("span"),Fy=o("TFRobertaPreLayerNormModel"),ih=p(),dt=r("div"),v(ms.$$.fragment),Ny=p(),_c=r("p"),Ly=o("The bare RoBERTa-PreLayerNorm Model transformer outputting raw hidden-states without any specific head on top."),xy=p(),hs=r("p"),My=o("This model inherits from "),Dl=r("a"),Ey=o("TFPreTrainedModel"),Ry=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.)`),zy=p(),us=r("p"),Cy=o("This model is also a "),fs=r("a"),qy=o("tf.keras.Model"),jy=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.`),Ay=p(),v(Gn.$$.fragment),Oy=p(),Wt=r("div"),v(gs.$$.fragment),Iy=p(),Bo=r("p"),Dy=o("The "),Sl=r("a"),Sy=o("TFRobertaPreLayerNormModel"),Wy=o(" forward method, overrides the "),yc=r("code"),Uy=o("__call__"),By=o(" special method."),Qy=p(),v(Xn.$$.fragment),Hy=p(),v(Yn.$$.fragment),lh=p(),Qo=r("h2"),Zn=r("a"),bc=r("span"),v(_s.$$.fragment),Ky=p(),kc=r("span"),Vy=o("TFRobertaPreLayerNormForCausalLM"),dh=p(),Ho=r("div"),v(ys.$$.fragment),Jy=p(),Ut=r("div"),v(bs.$$.fragment),Gy=p(),Ko=r("p"),Xy=o("The "),Wl=r("a"),Yy=o("TFRobertaPreLayerNormForCausalLM"),Zy=o(" forward method, overrides the "),vc=r("code"),eb=o("__call__"),tb=o(" special method."),ob=p(),v(er.$$.fragment),nb=p(),v(tr.$$.fragment),ch=p(),Vo=r("h2"),or=r("a"),Tc=r("span"),v(ks.$$.fragment),rb=p(),wc=r("span"),ab=o("TFRobertaPreLayerNormForMaskedLM"),ph=p(),ct=r("div"),v(vs.$$.fragment),sb=p(),Ts=r("p"),ib=o("RoBERTa-PreLayerNorm Model with a "),$c=r("code"),lb=o("language modeling"),db=o(" head on top."),cb=p(),ws=r("p"),pb=o("This model inherits from "),Ul=r("a"),mb=o("TFPreTrainedModel"),hb=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.)`),ub=p(),$s=r("p"),fb=o("This model is also a "),Ps=r("a"),gb=o("tf.keras.Model"),_b=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.`),yb=p(),v(nr.$$.fragment),bb=p(),wt=r("div"),v(Fs.$$.fragment),kb=p(),Jo=r("p"),vb=o("The "),Bl=r("a"),Tb=o("TFRobertaPreLayerNormForMaskedLM"),wb=o(" forward method, overrides the "),Pc=r("code"),$b=o("__call__"),Pb=o(" special method."),Fb=p(),v(rr.$$.fragment),Nb=p(),v(ar.$$.fragment),Lb=p(),v(sr.$$.fragment),mh=p(),Go=r("h2"),ir=r("a"),Fc=r("span"),v(Ns.$$.fragment),xb=p(),Nc=r("span"),Mb=o("TFRobertaPreLayerNormForSequenceClassification"),hh=p(),pt=r("div"),v(Ls.$$.fragment),Eb=p(),Lc=r("p"),Rb=o(`RoBERTa-PreLayerNorm Model transformer with a sequence classification/regression head on top (a linear layer on top
of the pooled output) e.g. for GLUE tasks.`),zb=p(),xs=r("p"),Cb=o("This model inherits from "),Ql=r("a"),qb=o("TFPreTrainedModel"),jb=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.)`),Ab=p(),Ms=r("p"),Ob=o("This model is also a "),Es=r("a"),Ib=o("tf.keras.Model"),Db=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.`),Sb=p(),v(lr.$$.fragment),Wb=p(),$t=r("div"),v(Rs.$$.fragment),Ub=p(),Xo=r("p"),Bb=o("The "),Hl=r("a"),Qb=o("TFRobertaPreLayerNormForSequenceClassification"),Hb=o(" forward method, overrides the "),xc=r("code"),Kb=o("__call__"),Vb=o(" special method."),Jb=p(),v(dr.$$.fragment),Gb=p(),v(cr.$$.fragment),Xb=p(),v(pr.$$.fragment),uh=p(),Yo=r("h2"),mr=r("a"),Mc=r("span"),v(zs.$$.fragment),Yb=p(),Ec=r("span"),Zb=o("TFRobertaPreLayerNormForMultipleChoice"),fh=p(),mt=r("div"),v(Cs.$$.fragment),ek=p(),Rc=r("p"),tk=o(`RobertaPreLayerNorm 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.`),ok=p(),qs=r("p"),nk=o("This model inherits from "),Kl=r("a"),rk=o("TFPreTrainedModel"),ak=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.)`),sk=p(),js=r("p"),ik=o("This model is also a "),As=r("a"),lk=o("tf.keras.Model"),dk=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.`),ck=p(),v(hr.$$.fragment),pk=p(),Bt=r("div"),v(Os.$$.fragment),mk=p(),Zo=r("p"),hk=o("The "),Vl=r("a"),uk=o("TFRobertaPreLayerNormForMultipleChoice"),fk=o(" forward method, overrides the "),zc=r("code"),gk=o("__call__"),_k=o(" special method."),yk=p(),v(ur.$$.fragment),bk=p(),v(fr.$$.fragment),gh=p(),en=r("h2"),gr=r("a"),Cc=r("span"),v(Is.$$.fragment),kk=p(),qc=r("span"),vk=o("TFRobertaPreLayerNormForTokenClassification"),_h=p(),ht=r("div"),v(Ds.$$.fragment),Tk=p(),jc=r("p"),wk=o(`RoBERTa-PreLayerNorm 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.`),$k=p(),Ss=r("p"),Pk=o("This model inherits from "),Jl=r("a"),Fk=o("TFPreTrainedModel"),Nk=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.)`),Lk=p(),Ws=r("p"),xk=o("This model is also a "),Us=r("a"),Mk=o("tf.keras.Model"),Ek=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.`),Rk=p(),v(_r.$$.fragment),zk=p(),Pt=r("div"),v(Bs.$$.fragment),Ck=p(),tn=r("p"),qk=o("The "),Gl=r("a"),jk=o("TFRobertaPreLayerNormForTokenClassification"),Ak=o(" forward method, overrides the "),Ac=r("code"),Ok=o("__call__"),Ik=o(" special method."),Dk=p(),v(yr.$$.fragment),Sk=p(),v(br.$$.fragment),Wk=p(),v(kr.$$.fragment),yh=p(),on=r("h2"),vr=r("a"),Oc=r("span"),v(Qs.$$.fragment),Uk=p(),Ic=r("span"),Bk=o("TFRobertaPreLayerNormForQuestionAnswering"),bh=p(),ut=r("div"),v(Hs.$$.fragment),Qk=p(),nn=r("p"),Hk=o(`RoBERTa-PreLayerNorm 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 `),Dc=r("code"),Kk=o("span start logits"),Vk=o(" and "),Sc=r("code"),Jk=o("span end logits"),Gk=o(")."),Xk=p(),Ks=r("p"),Yk=o("This model inherits from "),Xl=r("a"),Zk=o("TFPreTrainedModel"),ev=o(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),tv=p(),Vs=r("p"),ov=o("This model is also a "),Js=r("a"),nv=o("tf.keras.Model"),rv=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.`),av=p(),v(Tr.$$.fragment),sv=p(),Ft=r("div"),v(Gs.$$.fragment),iv=p(),rn=r("p"),lv=o("The "),Yl=r("a"),dv=o("TFRobertaPreLayerNormForQuestionAnswering"),cv=o(" forward method, overrides the "),Wc=r("code"),pv=o("__call__"),mv=o(" special method."),hv=p(),v(wr.$$.fragment),uv=p(),v($r.$$.fragment),fv=p(),v(Pr.$$.fragment),kh=p(),an=r("h2"),Fr=r("a"),Uc=r("span"),v(Xs.$$.fragment),gv=p(),Bc=r("span"),_v=o("FlaxRobertaPreLayerNormModel"),vh=p(),et=r("div"),v(Ys.$$.fragment),yv=p(),Qc=r("p"),bv=o("The bare RoBERTa-PreLayerNorm Model transformer outputting raw hidden-states without any specific head on top."),kv=p(),Zs=r("p"),vv=o("This model inherits from "),Zl=r("a"),Tv=o("FlaxPreTrainedModel"),wv=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)`),$v=p(),ei=r("p"),Pv=o("This model is also a Flax Linen "),ti=r("a"),Fv=o("flax.linen.Module"),Nv=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.`),Lv=p(),Hc=r("p"),xv=o("Finally, this model supports inherent JAX features such as:"),Mv=p(),ao=r("ul"),Kc=r("li"),oi=r("a"),Ev=o("Just-In-Time (JIT) compilation"),Rv=p(),Vc=r("li"),ni=r("a"),zv=o("Automatic Differentiation"),Cv=p(),Jc=r("li"),ri=r("a"),qv=o("Vectorization"),jv=p(),Gc=r("li"),ai=r("a"),Av=o("Parallelization"),Ov=p(),Qt=r("div"),v(si.$$.fragment),Iv=p(),sn=r("p"),Dv=o("The "),Xc=r("code"),Sv=o("FlaxRobertaPreLayerNormPreTrainedModel"),Wv=o(" forward method, overrides the "),Yc=r("code"),Uv=o("__call__"),Bv=o(" special method."),Qv=p(),v(Nr.$$.fragment),Hv=p(),v(Lr.$$.fragment),Th=p(),ln=r("h2"),xr=r("a"),Zc=r("span"),v(ii.$$.fragment),Kv=p(),ep=r("span"),Vv=o("FlaxRobertaPreLayerNormForCausalLM"),wh=p(),tt=r("div"),v(li.$$.fragment),Jv=p(),tp=r("p"),Gv=o(`RobertaPreLayerNorm Model with a language modeling head on top (a linear layer on top of the hidden-states output)
e.g for autoregressive tasks.`),Xv=p(),di=r("p"),Yv=o("This model inherits from "),ed=r("a"),Zv=o("FlaxPreTrainedModel"),eT=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)`),tT=p(),ci=r("p"),oT=o("This model is also a Flax Linen "),pi=r("a"),nT=o("flax.linen.Module"),rT=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.`),aT=p(),op=r("p"),sT=o("Finally, this model supports inherent JAX features such as:"),iT=p(),so=r("ul"),np=r("li"),mi=r("a"),lT=o("Just-In-Time (JIT) compilation"),dT=p(),rp=r("li"),hi=r("a"),cT=o("Automatic Differentiation"),pT=p(),ap=r("li"),ui=r("a"),mT=o("Vectorization"),hT=p(),sp=r("li"),fi=r("a"),uT=o("Parallelization"),fT=p(),Ht=r("div"),v(gi.$$.fragment),gT=p(),dn=r("p"),_T=o("The "),ip=r("code"),yT=o("FlaxRobertaPreLayerNormPreTrainedModel"),bT=o(" forward method, overrides the "),lp=r("code"),kT=o("__call__"),vT=o(" special method."),TT=p(),v(Mr.$$.fragment),wT=p(),v(Er.$$.fragment),$h=p(),cn=r("h2"),Rr=r("a"),dp=r("span"),v(_i.$$.fragment),$T=p(),cp=r("span"),PT=o("FlaxRobertaPreLayerNormForMaskedLM"),Ph=p(),ot=r("div"),v(yi.$$.fragment),FT=p(),bi=r("p"),NT=o("RoBERTa-PreLayerNorm Model with a "),pp=r("code"),LT=o("language modeling"),xT=o(" head on top."),MT=p(),ki=r("p"),ET=o("This model inherits from "),td=r("a"),RT=o("FlaxPreTrainedModel"),zT=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)`),CT=p(),vi=r("p"),qT=o("This model is also a Flax Linen "),Ti=r("a"),jT=o("flax.linen.Module"),AT=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.`),OT=p(),mp=r("p"),IT=o("Finally, this model supports inherent JAX features such as:"),DT=p(),io=r("ul"),hp=r("li"),wi=r("a"),ST=o("Just-In-Time (JIT) compilation"),WT=p(),up=r("li"),$i=r("a"),UT=o("Automatic Differentiation"),BT=p(),fp=r("li"),Pi=r("a"),QT=o("Vectorization"),HT=p(),gp=r("li"),Fi=r("a"),KT=o("Parallelization"),VT=p(),Kt=r("div"),v(Ni.$$.fragment),JT=p(),pn=r("p"),GT=o("The "),_p=r("code"),XT=o("FlaxRobertaPreLayerNormPreTrainedModel"),YT=o(" forward method, overrides the "),yp=r("code"),ZT=o("__call__"),ew=o(" special method."),tw=p(),v(zr.$$.fragment),ow=p(),v(Cr.$$.fragment),Fh=p(),mn=r("h2"),qr=r("a"),bp=r("span"),v(Li.$$.fragment),nw=p(),kp=r("span"),rw=o("FlaxRobertaPreLayerNormForSequenceClassification"),Nh=p(),nt=r("div"),v(xi.$$.fragment),aw=p(),vp=r("p"),sw=o(`RobertaPreLayerNorm Model transformer with a sequence classification/regression head on top (a linear layer on top
of the pooled output) e.g. for GLUE tasks.`),iw=p(),Mi=r("p"),lw=o("This model inherits from "),od=r("a"),dw=o("FlaxPreTrainedModel"),cw=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)`),pw=p(),Ei=r("p"),mw=o("This model is also a Flax Linen "),Ri=r("a"),hw=o("flax.linen.Module"),uw=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.`),fw=p(),Tp=r("p"),gw=o("Finally, this model supports inherent JAX features such as:"),_w=p(),lo=r("ul"),wp=r("li"),zi=r("a"),yw=o("Just-In-Time (JIT) compilation"),bw=p(),$p=r("li"),Ci=r("a"),kw=o("Automatic Differentiation"),vw=p(),Pp=r("li"),qi=r("a"),Tw=o("Vectorization"),ww=p(),Fp=r("li"),ji=r("a"),$w=o("Parallelization"),Pw=p(),Vt=r("div"),v(Ai.$$.fragment),Fw=p(),hn=r("p"),Nw=o("The "),Np=r("code"),Lw=o("FlaxRobertaPreLayerNormPreTrainedModel"),xw=o(" forward method, overrides the "),Lp=r("code"),Mw=o("__call__"),Ew=o(" special method."),Rw=p(),v(jr.$$.fragment),zw=p(),v(Ar.$$.fragment),Lh=p(),un=r("h2"),Or=r("a"),xp=r("span"),v(Oi.$$.fragment),Cw=p(),Mp=r("span"),qw=o("FlaxRobertaPreLayerNormForMultipleChoice"),xh=p(),rt=r("div"),v(Ii.$$.fragment),jw=p(),Ep=r("p"),Aw=o(`RobertaPreLayerNorm 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.`),Ow=p(),Di=r("p"),Iw=o("This model inherits from "),nd=r("a"),Dw=o("FlaxPreTrainedModel"),Sw=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)`),Ww=p(),Si=r("p"),Uw=o("This model is also a Flax Linen "),Wi=r("a"),Bw=o("flax.linen.Module"),Qw=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.`),Hw=p(),Rp=r("p"),Kw=o("Finally, this model supports inherent JAX features such as:"),Vw=p(),co=r("ul"),zp=r("li"),Ui=r("a"),Jw=o("Just-In-Time (JIT) compilation"),Gw=p(),Cp=r("li"),Bi=r("a"),Xw=o("Automatic Differentiation"),Yw=p(),qp=r("li"),Qi=r("a"),Zw=o("Vectorization"),e$=p(),jp=r("li"),Hi=r("a"),t$=o("Parallelization"),o$=p(),Jt=r("div"),v(Ki.$$.fragment),n$=p(),fn=r("p"),r$=o("The "),Ap=r("code"),a$=o("FlaxRobertaPreLayerNormPreTrainedModel"),s$=o(" forward method, overrides the "),Op=r("code"),i$=o("__call__"),l$=o(" special method."),d$=p(),v(Ir.$$.fragment),c$=p(),v(Dr.$$.fragment),Mh=p(),gn=r("h2"),Sr=r("a"),Ip=r("span"),v(Vi.$$.fragment),p$=p(),Dp=r("span"),m$=o("FlaxRobertaPreLayerNormForTokenClassification"),Eh=p(),at=r("div"),v(Ji.$$.fragment),h$=p(),Sp=r("p"),u$=o(`RobertaPreLayerNorm Model with a token classification head on top (a linear layer on top of the hidden-states
output) e.g. for Named-Entity-Recognition (NER) tasks.`),f$=p(),Gi=r("p"),g$=o("This model inherits from "),rd=r("a"),_$=o("FlaxPreTrainedModel"),y$=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)`),b$=p(),Xi=r("p"),k$=o("This model is also a Flax Linen "),Yi=r("a"),v$=o("flax.linen.Module"),T$=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.`),w$=p(),Wp=r("p"),$$=o("Finally, this model supports inherent JAX features such as:"),P$=p(),po=r("ul"),Up=r("li"),Zi=r("a"),F$=o("Just-In-Time (JIT) compilation"),N$=p(),Bp=r("li"),el=r("a"),L$=o("Automatic Differentiation"),x$=p(),Qp=r("li"),tl=r("a"),M$=o("Vectorization"),E$=p(),Hp=r("li"),ol=r("a"),R$=o("Parallelization"),z$=p(),Gt=r("div"),v(nl.$$.fragment),C$=p(),_n=r("p"),q$=o("The "),Kp=r("code"),j$=o("FlaxRobertaPreLayerNormPreTrainedModel"),A$=o(" forward method, overrides the "),Vp=r("code"),O$=o("__call__"),I$=o(" special method."),D$=p(),v(Wr.$$.fragment),S$=p(),v(Ur.$$.fragment),Rh=p(),yn=r("h2"),Br=r("a"),Jp=r("span"),v(rl.$$.fragment),W$=p(),Gp=r("span"),U$=o("FlaxRobertaPreLayerNormForQuestionAnswering"),zh=p(),st=r("div"),v(al.$$.fragment),B$=p(),bn=r("p"),Q$=o(`RobertaPreLayerNorm 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 `),Xp=r("code"),H$=o("span start logits"),K$=o(" and "),Yp=r("code"),V$=o("span end logits"),J$=o(")."),G$=p(),sl=r("p"),X$=o("This model inherits from "),ad=r("a"),Y$=o("FlaxPreTrainedModel"),Z$=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)`),e1=p(),il=r("p"),t1=o("This model is also a Flax Linen "),ll=r("a"),o1=o("flax.linen.Module"),n1=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.`),r1=p(),Zp=r("p"),a1=o("Finally, this model supports inherent JAX features such as:"),s1=p(),mo=r("ul"),em=r("li"),dl=r("a"),i1=o("Just-In-Time (JIT) compilation"),l1=p(),tm=r("li"),cl=r("a"),d1=o("Automatic Differentiation"),c1=p(),om=r("li"),pl=r("a"),p1=o("Vectorization"),m1=p(),nm=r("li"),ml=r("a"),h1=o("Parallelization"),u1=p(),Xt=r("div"),v(hl.$$.fragment),f1=p(),kn=r("p"),g1=o("The "),rm=r("code"),_1=o("FlaxRobertaPreLayerNormPreTrainedModel"),y1=o(" forward method, overrides the "),am=r("code"),b1=o("__call__"),k1=o(" special method."),v1=p(),v(Qr.$$.fragment),T1=p(),v(Hr.$$.fragment),this.h()},l(i){const b=U2('[data-svelte="svelte-1phssyn"]',document.head);d=a(b,"META",{name:!0,content:!0}),b.forEach(t),y=m(i),h=a(i,"H1",{class:!0});var ul=s(h);u=a(ul,"A",{id:!0,class:!0,href:!0});var sm=s(u);g=a(sm,"SPAN",{});var im=s(g);T(l.$$.fragment,im),im.forEach(t),sm.forEach(t),c=m(ul),x=a(ul,"SPAN",{});var lm=s(x);ye=n(lm,"RoBERTa-PreLayerNorm"),lm.forEach(t),ul.forEach(t),he=m(i),D=a(i,"H2",{class:!0});var fl=s(D);ae=a(fl,"A",{id:!0,class:!0,href:!0});var dm=s(ae);te=a(dm,"SPAN",{});var cm=s(te);T(L.$$.fragment,cm),cm.forEach(t),dm.forEach(t),be=m(fl),B=a(fl,"SPAN",{});var pm=s(B);ke=n(pm,"Overview"),pm.forEach(t),fl.forEach(t),ue=m(i),A=a(i,"P",{});var ho=s(A);ve=n(ho,"The RoBERTa-PreLayerNorm model was proposed in "),se=a(ho,"A",{href:!0,rel:!0});var mm=s(se);K=n(mm,"fairseq: A Fast, Extensible Toolkit for Sequence Modeling"),mm.forEach(t),Te=n(ho,` by Myle Ott, Sergey Edunov, Alexei Baevski, Angela Fan, Sam Gross, Nathan Ng, David Grangier, Michael Auli.
It is identical to using the `),ce=a(ho,"CODE",{});var hm=s(ce);V=n(hm,"--encoder-normalize-before"),hm.forEach(t),we=n(ho," flag in "),ie=a(ho,"A",{href:!0,rel:!0});var um=s(ie);J=n(um,"fairseq"),um.forEach(t),$e=n(ho,"."),ho.forEach(t),fe=m(i),ee=a(i,"P",{});var fm=s(ee);R=n(fm,"The abstract from the paper is the following:"),fm.forEach(t),C=m(i),le=a(i,"P",{});var gm=s(le);Q=a(gm,"EM",{});var _m=s(Q);Pe=n(_m,"fairseq is an open-source sequence modeling toolkit that allows researchers and developers to train custom models for translation, summarization, language modeling, and other text generation tasks. The toolkit is based on PyTorch and supports distributed training across multiple GPUs and machines. We also support fast mixed-precision training and inference on modern GPUs."),_m.forEach(t),gm.forEach(t),ge=m(i),U=a(i,"P",{});var ym=s(U);Fe=n(ym,"Tips:"),ym.forEach(t),_e=m(i),z=a(i,"UL",{});var gl=s(z);H=a(gl,"LI",{});var ft=s(H);G=n(ft,"The implementation is the same as "),de=a(ft,"A",{href:!0});var bm=s(de);Ne=n(bm,"Roberta"),bm.forEach(t),X=n(ft," except instead of using "),pe=a(ft,"EM",{});var km=s(pe);Le=n(km,"Add and Norm"),km.forEach(t),S=n(ft," it does "),me=a(ft,"EM",{});var vm=s(me);Y=n(vm,"Norm and Add"),vm.forEach(t),xe=n(ft,". "),oe=a(ft,"EM",{});var Tm=s(oe);q=n(Tm,"Add"),Tm.forEach(t),Me=n(ft," and "),j=a(ft,"EM",{});var wm=s(j);Ee=n(wm,"Norm"),wm.forEach(t),Re=n(ft," refers to the Addition and LayerNormalization as described in "),k=a(ft,"A",{href:!0,rel:!0});var $m=s(k);M=n($m,"Attention Is All You Need"),$m.forEach(t),Be=n(ft,"."),ft.forEach(t),re=m(gl),ze=a(gl,"LI",{});var vn=s(ze);Qe=n(vn,"This is identical to using the "),E=a(vn,"CODE",{});var Pm=s(E);He=n(Pm,"--encoder-normalize-before"),Pm.forEach(t),Ke=n(vn," flag in "),De=a(vn,"A",{href:!0,rel:!0});var Fm=s(De);Ve=n(Fm,"fairseq"),Fm.forEach(t),Je=n(vn,"."),vn.forEach(t),gl.forEach(t),O=m(i),I=a(i,"P",{});var Tn=s(I);Ge=n(Tn,"This model was contributed by "),Se=a(Tn,"A",{href:!0,rel:!0});var Nm=s(Se);Z=n(Nm,"andreasmaden"),Nm.forEach(t),Xe=n(Tn,`.
The original code can be found `),We=a(Tn,"A",{href:!0,rel:!0});var Lm=s(We);Ce=n(Lm,"here"),Lm.forEach(t),Ye=n(Tn,"."),Tn.forEach(t),ne=m(i),qe=a(i,"H2",{class:!0});var _l=s(qe);$n=a(_l,"A",{id:!0,class:!0,href:!0});var xm=s($n);Md=a(xm,"SPAN",{});var Mm=s(Md);T(ga.$$.fragment,Mm),Mm.forEach(t),xm.forEach(t),Bu=m(_l),Ed=a(_l,"SPAN",{});var Em=s(Ed);Qu=n(Em,"RobertaPreLayerNormConfig"),Em.forEach(t),_l.forEach(t),Qm=m(i),qt=a(i,"DIV",{class:!0});var uo=s(qt);T(_a.$$.fragment,uo),Hu=m(uo),ro=a(uo,"P",{});var fo=s(ro);Ku=n(fo,"This is the configuration class to store the configuration of a "),Tl=a(fo,"A",{href:!0});var Rm=s(Tl);Vu=n(Rm,"RobertaPreLayerNormModel"),Rm.forEach(t),Ju=n(fo,` or a
`),wl=a(fo,"A",{href:!0});var zm=s(wl);Gu=n(zm,"TFRobertaPreLayerNormModel"),zm.forEach(t),Xu=n(fo,`. It is used to instantiate a RoBERTa-PreLayerNorm 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 RoBERTa-PreLayerNorm
`),ya=a(fo,"A",{href:!0,rel:!0});var Cm=s(ya);Yu=n(Cm,"andreasmadsen/efficient_mlm_m0.40"),Cm.forEach(t),Zu=n(fo," architecture."),fo.forEach(t),ef=m(uo),No=a(uo,"P",{});var wn=s(No);tf=n(wn,"Configuration objects inherit from "),$l=a(wn,"A",{href:!0});var qm=s($l);of=n(qm,"PretrainedConfig"),qm.forEach(t),nf=n(wn,` and can be used to control the model outputs. Read the
documentation from `),Pl=a(wn,"A",{href:!0});var jm=s(Pl);rf=n(jm,"PretrainedConfig"),jm.forEach(t),af=n(wn," for more information."),wn.forEach(t),sf=m(uo),T(Pn.$$.fragment,uo),uo.forEach(t),Hm=m(i),Lo=a(i,"H2",{class:!0});var yl=s(Lo);Fn=a(yl,"A",{id:!0,class:!0,href:!0});var Am=s(Fn);Rd=a(Am,"SPAN",{});var Om=s(Rd);T(ba.$$.fragment,Om),Om.forEach(t),Am.forEach(t),lf=m(yl),zd=a(yl,"SPAN",{});var Im=s(zd);df=n(Im,"RobertaPreLayerNormModel"),Im.forEach(t),yl.forEach(t),Km=m(i),Ze=a(i,"DIV",{class:!0});var it=s(Ze);T(ka.$$.fragment,it),cf=m(it),Cd=a(it,"P",{});var Dm=s(Cd);pf=n(Dm,"The bare RoBERTa-PreLayerNorm Model transformer outputting raw hidden-states without any specific head on top."),Dm.forEach(t),mf=m(it),va=a(it,"P",{});var bl=s(va);hf=n(bl,"This model inherits from "),Fl=a(bl,"A",{href:!0});var Sm=s(Fl);uf=n(Sm,"PreTrainedModel"),Sm.forEach(t),ff=n(bl,`. 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.)`),bl.forEach(t),gf=m(it),Ta=a(it,"P",{});var kl=s(Ta);_f=n(kl,"This model is also a PyTorch "),wa=a(kl,"A",{href:!0,rel:!0});var Wm=s(wa);yf=n(Wm,"torch.nn.Module"),Wm.forEach(t),bf=n(kl,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),kl.forEach(t),kf=m(it),$a=a(it,"P",{});var vl=s($a);vf=n(vl,`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 `),qd=a(vl,"EM",{});var Um=s(qd);Tf=n(Um,`Attention is
all you need`),Um.forEach(t),wf=n(vl,`_ by Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz
Kaiser and Illia Polosukhin.`),vl.forEach(t),$f=m(it),lt=a(it,"P",{});var Nt=s(lt);Pf=n(Nt,"To behave as an decoder the model needs to be initialized with the "),jd=a(Nt,"CODE",{});var w1=s(jd);Ff=n(w1,"is_decoder"),w1.forEach(t),Nf=n(Nt,` argument of the configuration set
to `),Ad=a(Nt,"CODE",{});var $1=s(Ad);Lf=n($1,"True"),$1.forEach(t),xf=n(Nt,". To be used in a Seq2Seq model, the model needs to initialized with both "),Od=a(Nt,"CODE",{});var P1=s(Od);Mf=n(P1,"is_decoder"),P1.forEach(t),Ef=n(Nt,` argument and
`),Id=a(Nt,"CODE",{});var F1=s(Id);Rf=n(F1,"add_cross_attention"),F1.forEach(t),zf=n(Nt," set to "),Dd=a(Nt,"CODE",{});var N1=s(Dd);Cf=n(N1,"True"),N1.forEach(t),qf=n(Nt,"; an "),Sd=a(Nt,"CODE",{});var L1=s(Sd);jf=n(L1,"encoder_hidden_states"),L1.forEach(t),Af=n(Nt," is then expected as an input to the forward pass."),Nt.forEach(t),Of=m(it),Nn=a(it,"P",{});var Bm=s(Nn);If=n(Bm,".. _"),Wd=a(Bm,"EM",{});var x1=s(Wd);Df=n(x1,"Attention is all you need"),x1.forEach(t),Sf=n(Bm,": "),Pa=a(Bm,"A",{href:!0,rel:!0});var M1=s(Pa);Wf=n(M1,"https://arxiv.org/abs/1706.03762"),M1.forEach(t),Bm.forEach(t),Uf=m(it),jt=a(it,"DIV",{class:!0});var Kr=s(jt);T(Fa.$$.fragment,Kr),Bf=m(Kr),xo=a(Kr,"P",{});var sd=s(xo);Qf=n(sd,"The "),Nl=a(sd,"A",{href:!0});var E1=s(Nl);Hf=n(E1,"RobertaPreLayerNormModel"),E1.forEach(t),Kf=n(sd," forward method, overrides the "),Ud=a(sd,"CODE",{});var R1=s(Ud);Vf=n(R1,"__call__"),R1.forEach(t),Jf=n(sd," special method."),sd.forEach(t),Gf=m(Kr),T(Ln.$$.fragment,Kr),Xf=m(Kr),T(xn.$$.fragment,Kr),Kr.forEach(t),it.forEach(t),Vm=m(i),Mo=a(i,"H2",{class:!0});var qh=s(Mo);Mn=a(qh,"A",{id:!0,class:!0,href:!0});var z1=s(Mn);Bd=a(z1,"SPAN",{});var C1=s(Bd);T(Na.$$.fragment,C1),C1.forEach(t),z1.forEach(t),Yf=m(qh),Qd=a(qh,"SPAN",{});var q1=s(Qd);Zf=n(q1,"RobertaPreLayerNormForCausalLM"),q1.forEach(t),qh.forEach(t),Jm=m(i),gt=a(i,"DIV",{class:!0});var go=s(gt);T(La.$$.fragment,go),eg=m(go),xa=a(go,"P",{});var jh=s(xa);tg=n(jh,"RoBERTa-PreLayerNorm Model with a "),Hd=a(jh,"CODE",{});var j1=s(Hd);og=n(j1,"language modeling"),j1.forEach(t),ng=n(jh," head on top for CLM fine-tuning."),jh.forEach(t),rg=m(go),Ma=a(go,"P",{});var Ah=s(Ma);ag=n(Ah,"This model inherits from "),Ll=a(Ah,"A",{href:!0});var A1=s(Ll);sg=n(A1,"PreTrainedModel"),A1.forEach(t),ig=n(Ah,`. 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.)`),Ah.forEach(t),lg=m(go),Ea=a(go,"P",{});var Oh=s(Ea);dg=n(Oh,"This model is also a PyTorch "),Ra=a(Oh,"A",{href:!0,rel:!0});var O1=s(Ra);cg=n(O1,"torch.nn.Module"),O1.forEach(t),pg=n(Oh,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Oh.forEach(t),mg=m(go),At=a(go,"DIV",{class:!0});var Vr=s(At);T(za.$$.fragment,Vr),hg=m(Vr),Eo=a(Vr,"P",{});var id=s(Eo);ug=n(id,"The "),xl=a(id,"A",{href:!0});var I1=s(xl);fg=n(I1,"RobertaPreLayerNormForCausalLM"),I1.forEach(t),gg=n(id," forward method, overrides the "),Kd=a(id,"CODE",{});var D1=s(Kd);_g=n(D1,"__call__"),D1.forEach(t),yg=n(id," special method."),id.forEach(t),bg=m(Vr),T(En.$$.fragment,Vr),kg=m(Vr),T(Rn.$$.fragment,Vr),Vr.forEach(t),go.forEach(t),Gm=m(i),Ro=a(i,"H2",{class:!0});var Ih=s(Ro);zn=a(Ih,"A",{id:!0,class:!0,href:!0});var S1=s(zn);Vd=a(S1,"SPAN",{});var W1=s(Vd);T(Ca.$$.fragment,W1),W1.forEach(t),S1.forEach(t),vg=m(Ih),Jd=a(Ih,"SPAN",{});var U1=s(Jd);Tg=n(U1,"RobertaPreLayerNormForMaskedLM"),U1.forEach(t),Ih.forEach(t),Xm=m(i),_t=a(i,"DIV",{class:!0});var _o=s(_t);T(qa.$$.fragment,_o),wg=m(_o),ja=a(_o,"P",{});var Dh=s(ja);$g=n(Dh,"RoBERTa-PreLayerNorm Model with a "),Gd=a(Dh,"CODE",{});var B1=s(Gd);Pg=n(B1,"language modeling"),B1.forEach(t),Fg=n(Dh," head on top."),Dh.forEach(t),Ng=m(_o),Aa=a(_o,"P",{});var Sh=s(Aa);Lg=n(Sh,"This model inherits from "),Ml=a(Sh,"A",{href:!0});var Q1=s(Ml);xg=n(Q1,"PreTrainedModel"),Q1.forEach(t),Mg=n(Sh,`. 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.)`),Sh.forEach(t),Eg=m(_o),Oa=a(_o,"P",{});var Wh=s(Oa);Rg=n(Wh,"This model is also a PyTorch "),Ia=a(Wh,"A",{href:!0,rel:!0});var H1=s(Ia);zg=n(H1,"torch.nn.Module"),H1.forEach(t),Cg=n(Wh,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Wh.forEach(t),qg=m(_o),Ot=a(_o,"DIV",{class:!0});var Jr=s(Ot);T(Da.$$.fragment,Jr),jg=m(Jr),zo=a(Jr,"P",{});var ld=s(zo);Ag=n(ld,"The "),El=a(ld,"A",{href:!0});var K1=s(El);Og=n(K1,"RobertaPreLayerNormForMaskedLM"),K1.forEach(t),Ig=n(ld," forward method, overrides the "),Xd=a(ld,"CODE",{});var V1=s(Xd);Dg=n(V1,"__call__"),V1.forEach(t),Sg=n(ld," special method."),ld.forEach(t),Wg=m(Jr),T(Cn.$$.fragment,Jr),Ug=m(Jr),T(qn.$$.fragment,Jr),Jr.forEach(t),_o.forEach(t),Ym=m(i),Co=a(i,"H2",{class:!0});var Uh=s(Co);jn=a(Uh,"A",{id:!0,class:!0,href:!0});var J1=s(jn);Yd=a(J1,"SPAN",{});var G1=s(Yd);T(Sa.$$.fragment,G1),G1.forEach(t),J1.forEach(t),Bg=m(Uh),Zd=a(Uh,"SPAN",{});var X1=s(Zd);Qg=n(X1,"RobertaPreLayerNormForSequenceClassification"),X1.forEach(t),Uh.forEach(t),Zm=m(i),yt=a(i,"DIV",{class:!0});var yo=s(yt);T(Wa.$$.fragment,yo),Hg=m(yo),ec=a(yo,"P",{});var Y1=s(ec);Kg=n(Y1,`RoBERTa-PreLayerNorm Model transformer with a sequence classification/regression head on top (a linear layer on top
of the pooled output) e.g. for GLUE tasks.`),Y1.forEach(t),Vg=m(yo),Ua=a(yo,"P",{});var Bh=s(Ua);Jg=n(Bh,"This model inherits from "),Rl=a(Bh,"A",{href:!0});var Z1=s(Rl);Gg=n(Z1,"PreTrainedModel"),Z1.forEach(t),Xg=n(Bh,`. 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.)`),Bh.forEach(t),Yg=m(yo),Ba=a(yo,"P",{});var Qh=s(Ba);Zg=n(Qh,"This model is also a PyTorch "),Qa=a(Qh,"A",{href:!0,rel:!0});var eP=s(Qa);e_=n(eP,"torch.nn.Module"),eP.forEach(t),t_=n(Qh,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Qh.forEach(t),o_=m(yo),Tt=a(yo,"DIV",{class:!0});var bo=s(Tt);T(Ha.$$.fragment,bo),n_=m(bo),qo=a(bo,"P",{});var dd=s(qo);r_=n(dd,"The "),zl=a(dd,"A",{href:!0});var tP=s(zl);a_=n(tP,"RobertaPreLayerNormForSequenceClassification"),tP.forEach(t),s_=n(dd," forward method, overrides the "),tc=a(dd,"CODE",{});var oP=s(tc);i_=n(oP,"__call__"),oP.forEach(t),l_=n(dd," special method."),dd.forEach(t),d_=m(bo),T(An.$$.fragment,bo),c_=m(bo),T(On.$$.fragment,bo),p_=m(bo),T(In.$$.fragment,bo),bo.forEach(t),yo.forEach(t),eh=m(i),jo=a(i,"H2",{class:!0});var Hh=s(jo);Dn=a(Hh,"A",{id:!0,class:!0,href:!0});var nP=s(Dn);oc=a(nP,"SPAN",{});var rP=s(oc);T(Ka.$$.fragment,rP),rP.forEach(t),nP.forEach(t),m_=m(Hh),nc=a(Hh,"SPAN",{});var aP=s(nc);h_=n(aP,"RobertaPreLayerNormForMultipleChoice"),aP.forEach(t),Hh.forEach(t),th=m(i),bt=a(i,"DIV",{class:!0});var ko=s(bt);T(Va.$$.fragment,ko),u_=m(ko),rc=a(ko,"P",{});var sP=s(rc);f_=n(sP,`RobertaPreLayerNorm 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.`),sP.forEach(t),g_=m(ko),Ja=a(ko,"P",{});var Kh=s(Ja);__=n(Kh,"This model inherits from "),Cl=a(Kh,"A",{href:!0});var iP=s(Cl);y_=n(iP,"PreTrainedModel"),iP.forEach(t),b_=n(Kh,`. 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.)`),Kh.forEach(t),k_=m(ko),Ga=a(ko,"P",{});var Vh=s(Ga);v_=n(Vh,"This model is also a PyTorch "),Xa=a(Vh,"A",{href:!0,rel:!0});var lP=s(Xa);T_=n(lP,"torch.nn.Module"),lP.forEach(t),w_=n(Vh,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Vh.forEach(t),$_=m(ko),It=a(ko,"DIV",{class:!0});var Gr=s(It);T(Ya.$$.fragment,Gr),P_=m(Gr),Ao=a(Gr,"P",{});var cd=s(Ao);F_=n(cd,"The "),ql=a(cd,"A",{href:!0});var dP=s(ql);N_=n(dP,"RobertaPreLayerNormForMultipleChoice"),dP.forEach(t),L_=n(cd," forward method, overrides the "),ac=a(cd,"CODE",{});var cP=s(ac);x_=n(cP,"__call__"),cP.forEach(t),M_=n(cd," special method."),cd.forEach(t),E_=m(Gr),T(Sn.$$.fragment,Gr),R_=m(Gr),T(Wn.$$.fragment,Gr),Gr.forEach(t),ko.forEach(t),oh=m(i),Oo=a(i,"H2",{class:!0});var Jh=s(Oo);Un=a(Jh,"A",{id:!0,class:!0,href:!0});var pP=s(Un);sc=a(pP,"SPAN",{});var mP=s(sc);T(Za.$$.fragment,mP),mP.forEach(t),pP.forEach(t),z_=m(Jh),ic=a(Jh,"SPAN",{});var hP=s(ic);C_=n(hP,"RobertaPreLayerNormForTokenClassification"),hP.forEach(t),Jh.forEach(t),nh=m(i),kt=a(i,"DIV",{class:!0});var vo=s(kt);T(es.$$.fragment,vo),q_=m(vo),lc=a(vo,"P",{});var uP=s(lc);j_=n(uP,`RobertaPreLayerNorm 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.`),uP.forEach(t),A_=m(vo),ts=a(vo,"P",{});var Gh=s(ts);O_=n(Gh,"This model inherits from "),jl=a(Gh,"A",{href:!0});var fP=s(jl);I_=n(fP,"PreTrainedModel"),fP.forEach(t),D_=n(Gh,`. 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.)`),Gh.forEach(t),S_=m(vo),os=a(vo,"P",{});var Xh=s(os);W_=n(Xh,"This model is also a PyTorch "),ns=a(Xh,"A",{href:!0,rel:!0});var gP=s(ns);U_=n(gP,"torch.nn.Module"),gP.forEach(t),B_=n(Xh,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Xh.forEach(t),Q_=m(vo),Dt=a(vo,"DIV",{class:!0});var Xr=s(Dt);T(rs.$$.fragment,Xr),H_=m(Xr),Io=a(Xr,"P",{});var pd=s(Io);K_=n(pd,"The "),Al=a(pd,"A",{href:!0});var _P=s(Al);V_=n(_P,"RobertaPreLayerNormForTokenClassification"),_P.forEach(t),J_=n(pd," forward method, overrides the "),dc=a(pd,"CODE",{});var yP=s(dc);G_=n(yP,"__call__"),yP.forEach(t),X_=n(pd," special method."),pd.forEach(t),Y_=m(Xr),T(Bn.$$.fragment,Xr),Z_=m(Xr),T(Qn.$$.fragment,Xr),Xr.forEach(t),vo.forEach(t),rh=m(i),Do=a(i,"H2",{class:!0});var Yh=s(Do);Hn=a(Yh,"A",{id:!0,class:!0,href:!0});var bP=s(Hn);cc=a(bP,"SPAN",{});var kP=s(cc);T(as.$$.fragment,kP),kP.forEach(t),bP.forEach(t),ey=m(Yh),pc=a(Yh,"SPAN",{});var vP=s(pc);ty=n(vP,"RobertaPreLayerNormForQuestionAnswering"),vP.forEach(t),Yh.forEach(t),ah=m(i),vt=a(i,"DIV",{class:!0});var To=s(vt);T(ss.$$.fragment,To),oy=m(To),So=a(To,"P",{});var md=s(So);ny=n(md,`RobertaPreLayerNorm 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 `),mc=a(md,"CODE",{});var TP=s(mc);ry=n(TP,"span start logits"),TP.forEach(t),ay=n(md," and "),hc=a(md,"CODE",{});var wP=s(hc);sy=n(wP,"span end logits"),wP.forEach(t),iy=n(md,")."),md.forEach(t),ly=m(To),is=a(To,"P",{});var Zh=s(is);dy=n(Zh,"This model inherits from "),Ol=a(Zh,"A",{href:!0});var $P=s(Ol);cy=n($P,"PreTrainedModel"),$P.forEach(t),py=n(Zh,`. 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.)`),Zh.forEach(t),my=m(To),ls=a(To,"P",{});var eu=s(ls);hy=n(eu,"This model is also a PyTorch "),ds=a(eu,"A",{href:!0,rel:!0});var PP=s(ds);uy=n(PP,"torch.nn.Module"),PP.forEach(t),fy=n(eu,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),eu.forEach(t),gy=m(To),St=a(To,"DIV",{class:!0});var Yr=s(St);T(cs.$$.fragment,Yr),_y=m(Yr),Wo=a(Yr,"P",{});var hd=s(Wo);yy=n(hd,"The "),Il=a(hd,"A",{href:!0});var FP=s(Il);by=n(FP,"RobertaPreLayerNormForQuestionAnswering"),FP.forEach(t),ky=n(hd," forward method, overrides the "),uc=a(hd,"CODE",{});var NP=s(uc);vy=n(NP,"__call__"),NP.forEach(t),Ty=n(hd," special method."),hd.forEach(t),wy=m(Yr),T(Kn.$$.fragment,Yr),$y=m(Yr),T(Vn.$$.fragment,Yr),Yr.forEach(t),To.forEach(t),sh=m(i),Uo=a(i,"H2",{class:!0});var tu=s(Uo);Jn=a(tu,"A",{id:!0,class:!0,href:!0});var LP=s(Jn);fc=a(LP,"SPAN",{});var xP=s(fc);T(ps.$$.fragment,xP),xP.forEach(t),LP.forEach(t),Py=m(tu),gc=a(tu,"SPAN",{});var MP=s(gc);Fy=n(MP,"TFRobertaPreLayerNormModel"),MP.forEach(t),tu.forEach(t),ih=m(i),dt=a(i,"DIV",{class:!0});var Yt=s(dt);T(ms.$$.fragment,Yt),Ny=m(Yt),_c=a(Yt,"P",{});var EP=s(_c);Ly=n(EP,"The bare RoBERTa-PreLayerNorm Model transformer outputting raw hidden-states without any specific head on top."),EP.forEach(t),xy=m(Yt),hs=a(Yt,"P",{});var ou=s(hs);My=n(ou,"This model inherits from "),Dl=a(ou,"A",{href:!0});var RP=s(Dl);Ey=n(RP,"TFPreTrainedModel"),RP.forEach(t),Ry=n(ou,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ou.forEach(t),zy=m(Yt),us=a(Yt,"P",{});var nu=s(us);Cy=n(nu,"This model is also a "),fs=a(nu,"A",{href:!0,rel:!0});var zP=s(fs);qy=n(zP,"tf.keras.Model"),zP.forEach(t),jy=n(nu,` 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.`),nu.forEach(t),Ay=m(Yt),T(Gn.$$.fragment,Yt),Oy=m(Yt),Wt=a(Yt,"DIV",{class:!0});var Zr=s(Wt);T(gs.$$.fragment,Zr),Iy=m(Zr),Bo=a(Zr,"P",{});var ud=s(Bo);Dy=n(ud,"The "),Sl=a(ud,"A",{href:!0});var CP=s(Sl);Sy=n(CP,"TFRobertaPreLayerNormModel"),CP.forEach(t),Wy=n(ud," forward method, overrides the "),yc=a(ud,"CODE",{});var qP=s(yc);Uy=n(qP,"__call__"),qP.forEach(t),By=n(ud," special method."),ud.forEach(t),Qy=m(Zr),T(Xn.$$.fragment,Zr),Hy=m(Zr),T(Yn.$$.fragment,Zr),Zr.forEach(t),Yt.forEach(t),lh=m(i),Qo=a(i,"H2",{class:!0});var ru=s(Qo);Zn=a(ru,"A",{id:!0,class:!0,href:!0});var jP=s(Zn);bc=a(jP,"SPAN",{});var AP=s(bc);T(_s.$$.fragment,AP),AP.forEach(t),jP.forEach(t),Ky=m(ru),kc=a(ru,"SPAN",{});var OP=s(kc);Vy=n(OP,"TFRobertaPreLayerNormForCausalLM"),OP.forEach(t),ru.forEach(t),dh=m(i),Ho=a(i,"DIV",{class:!0});var au=s(Ho);T(ys.$$.fragment,au),Jy=m(au),Ut=a(au,"DIV",{class:!0});var ea=s(Ut);T(bs.$$.fragment,ea),Gy=m(ea),Ko=a(ea,"P",{});var fd=s(Ko);Xy=n(fd,"The "),Wl=a(fd,"A",{href:!0});var IP=s(Wl);Yy=n(IP,"TFRobertaPreLayerNormForCausalLM"),IP.forEach(t),Zy=n(fd," forward method, overrides the "),vc=a(fd,"CODE",{});var DP=s(vc);eb=n(DP,"__call__"),DP.forEach(t),tb=n(fd," special method."),fd.forEach(t),ob=m(ea),T(er.$$.fragment,ea),nb=m(ea),T(tr.$$.fragment,ea),ea.forEach(t),au.forEach(t),ch=m(i),Vo=a(i,"H2",{class:!0});var su=s(Vo);or=a(su,"A",{id:!0,class:!0,href:!0});var SP=s(or);Tc=a(SP,"SPAN",{});var WP=s(Tc);T(ks.$$.fragment,WP),WP.forEach(t),SP.forEach(t),rb=m(su),wc=a(su,"SPAN",{});var UP=s(wc);ab=n(UP,"TFRobertaPreLayerNormForMaskedLM"),UP.forEach(t),su.forEach(t),ph=m(i),ct=a(i,"DIV",{class:!0});var Zt=s(ct);T(vs.$$.fragment,Zt),sb=m(Zt),Ts=a(Zt,"P",{});var iu=s(Ts);ib=n(iu,"RoBERTa-PreLayerNorm Model with a "),$c=a(iu,"CODE",{});var BP=s($c);lb=n(BP,"language modeling"),BP.forEach(t),db=n(iu," head on top."),iu.forEach(t),cb=m(Zt),ws=a(Zt,"P",{});var lu=s(ws);pb=n(lu,"This model inherits from "),Ul=a(lu,"A",{href:!0});var QP=s(Ul);mb=n(QP,"TFPreTrainedModel"),QP.forEach(t),hb=n(lu,`. 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.)`),lu.forEach(t),ub=m(Zt),$s=a(Zt,"P",{});var du=s($s);fb=n(du,"This model is also a "),Ps=a(du,"A",{href:!0,rel:!0});var HP=s(Ps);gb=n(HP,"tf.keras.Model"),HP.forEach(t),_b=n(du,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),du.forEach(t),yb=m(Zt),T(nr.$$.fragment,Zt),bb=m(Zt),wt=a(Zt,"DIV",{class:!0});var wo=s(wt);T(Fs.$$.fragment,wo),kb=m(wo),Jo=a(wo,"P",{});var gd=s(Jo);vb=n(gd,"The "),Bl=a(gd,"A",{href:!0});var KP=s(Bl);Tb=n(KP,"TFRobertaPreLayerNormForMaskedLM"),KP.forEach(t),wb=n(gd," forward method, overrides the "),Pc=a(gd,"CODE",{});var VP=s(Pc);$b=n(VP,"__call__"),VP.forEach(t),Pb=n(gd," special method."),gd.forEach(t),Fb=m(wo),T(rr.$$.fragment,wo),Nb=m(wo),T(ar.$$.fragment,wo),Lb=m(wo),T(sr.$$.fragment,wo),wo.forEach(t),Zt.forEach(t),mh=m(i),Go=a(i,"H2",{class:!0});var cu=s(Go);ir=a(cu,"A",{id:!0,class:!0,href:!0});var JP=s(ir);Fc=a(JP,"SPAN",{});var GP=s(Fc);T(Ns.$$.fragment,GP),GP.forEach(t),JP.forEach(t),xb=m(cu),Nc=a(cu,"SPAN",{});var XP=s(Nc);Mb=n(XP,"TFRobertaPreLayerNormForSequenceClassification"),XP.forEach(t),cu.forEach(t),hh=m(i),pt=a(i,"DIV",{class:!0});var eo=s(pt);T(Ls.$$.fragment,eo),Eb=m(eo),Lc=a(eo,"P",{});var YP=s(Lc);Rb=n(YP,`RoBERTa-PreLayerNorm Model transformer with a sequence classification/regression head on top (a linear layer on top
of the pooled output) e.g. for GLUE tasks.`),YP.forEach(t),zb=m(eo),xs=a(eo,"P",{});var pu=s(xs);Cb=n(pu,"This model inherits from "),Ql=a(pu,"A",{href:!0});var ZP=s(Ql);qb=n(ZP,"TFPreTrainedModel"),ZP.forEach(t),jb=n(pu,`. 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.)`),pu.forEach(t),Ab=m(eo),Ms=a(eo,"P",{});var mu=s(Ms);Ob=n(mu,"This model is also a "),Es=a(mu,"A",{href:!0,rel:!0});var e0=s(Es);Ib=n(e0,"tf.keras.Model"),e0.forEach(t),Db=n(mu,` 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.`),mu.forEach(t),Sb=m(eo),T(lr.$$.fragment,eo),Wb=m(eo),$t=a(eo,"DIV",{class:!0});var $o=s($t);T(Rs.$$.fragment,$o),Ub=m($o),Xo=a($o,"P",{});var _d=s(Xo);Bb=n(_d,"The "),Hl=a(_d,"A",{href:!0});var t0=s(Hl);Qb=n(t0,"TFRobertaPreLayerNormForSequenceClassification"),t0.forEach(t),Hb=n(_d," forward method, overrides the "),xc=a(_d,"CODE",{});var o0=s(xc);Kb=n(o0,"__call__"),o0.forEach(t),Vb=n(_d," special method."),_d.forEach(t),Jb=m($o),T(dr.$$.fragment,$o),Gb=m($o),T(cr.$$.fragment,$o),Xb=m($o),T(pr.$$.fragment,$o),$o.forEach(t),eo.forEach(t),uh=m(i),Yo=a(i,"H2",{class:!0});var hu=s(Yo);mr=a(hu,"A",{id:!0,class:!0,href:!0});var n0=s(mr);Mc=a(n0,"SPAN",{});var r0=s(Mc);T(zs.$$.fragment,r0),r0.forEach(t),n0.forEach(t),Yb=m(hu),Ec=a(hu,"SPAN",{});var a0=s(Ec);Zb=n(a0,"TFRobertaPreLayerNormForMultipleChoice"),a0.forEach(t),hu.forEach(t),fh=m(i),mt=a(i,"DIV",{class:!0});var to=s(mt);T(Cs.$$.fragment,to),ek=m(to),Rc=a(to,"P",{});var s0=s(Rc);tk=n(s0,`RobertaPreLayerNorm 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.`),s0.forEach(t),ok=m(to),qs=a(to,"P",{});var uu=s(qs);nk=n(uu,"This model inherits from "),Kl=a(uu,"A",{href:!0});var i0=s(Kl);rk=n(i0,"TFPreTrainedModel"),i0.forEach(t),ak=n(uu,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),uu.forEach(t),sk=m(to),js=a(to,"P",{});var fu=s(js);ik=n(fu,"This model is also a "),As=a(fu,"A",{href:!0,rel:!0});var l0=s(As);lk=n(l0,"tf.keras.Model"),l0.forEach(t),dk=n(fu,` 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.`),fu.forEach(t),ck=m(to),T(hr.$$.fragment,to),pk=m(to),Bt=a(to,"DIV",{class:!0});var ta=s(Bt);T(Os.$$.fragment,ta),mk=m(ta),Zo=a(ta,"P",{});var yd=s(Zo);hk=n(yd,"The "),Vl=a(yd,"A",{href:!0});var d0=s(Vl);uk=n(d0,"TFRobertaPreLayerNormForMultipleChoice"),d0.forEach(t),fk=n(yd," forward method, overrides the "),zc=a(yd,"CODE",{});var c0=s(zc);gk=n(c0,"__call__"),c0.forEach(t),_k=n(yd," special method."),yd.forEach(t),yk=m(ta),T(ur.$$.fragment,ta),bk=m(ta),T(fr.$$.fragment,ta),ta.forEach(t),to.forEach(t),gh=m(i),en=a(i,"H2",{class:!0});var gu=s(en);gr=a(gu,"A",{id:!0,class:!0,href:!0});var p0=s(gr);Cc=a(p0,"SPAN",{});var m0=s(Cc);T(Is.$$.fragment,m0),m0.forEach(t),p0.forEach(t),kk=m(gu),qc=a(gu,"SPAN",{});var h0=s(qc);vk=n(h0,"TFRobertaPreLayerNormForTokenClassification"),h0.forEach(t),gu.forEach(t),_h=m(i),ht=a(i,"DIV",{class:!0});var oo=s(ht);T(Ds.$$.fragment,oo),Tk=m(oo),jc=a(oo,"P",{});var u0=s(jc);wk=n(u0,`RoBERTa-PreLayerNorm 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.`),u0.forEach(t),$k=m(oo),Ss=a(oo,"P",{});var _u=s(Ss);Pk=n(_u,"This model inherits from "),Jl=a(_u,"A",{href:!0});var f0=s(Jl);Fk=n(f0,"TFPreTrainedModel"),f0.forEach(t),Nk=n(_u,`. 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.)`),_u.forEach(t),Lk=m(oo),Ws=a(oo,"P",{});var yu=s(Ws);xk=n(yu,"This model is also a "),Us=a(yu,"A",{href:!0,rel:!0});var g0=s(Us);Mk=n(g0,"tf.keras.Model"),g0.forEach(t),Ek=n(yu,` 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.`),yu.forEach(t),Rk=m(oo),T(_r.$$.fragment,oo),zk=m(oo),Pt=a(oo,"DIV",{class:!0});var Po=s(Pt);T(Bs.$$.fragment,Po),Ck=m(Po),tn=a(Po,"P",{});var bd=s(tn);qk=n(bd,"The "),Gl=a(bd,"A",{href:!0});var _0=s(Gl);jk=n(_0,"TFRobertaPreLayerNormForTokenClassification"),_0.forEach(t),Ak=n(bd," forward method, overrides the "),Ac=a(bd,"CODE",{});var y0=s(Ac);Ok=n(y0,"__call__"),y0.forEach(t),Ik=n(bd," special method."),bd.forEach(t),Dk=m(Po),T(yr.$$.fragment,Po),Sk=m(Po),T(br.$$.fragment,Po),Wk=m(Po),T(kr.$$.fragment,Po),Po.forEach(t),oo.forEach(t),yh=m(i),on=a(i,"H2",{class:!0});var bu=s(on);vr=a(bu,"A",{id:!0,class:!0,href:!0});var b0=s(vr);Oc=a(b0,"SPAN",{});var k0=s(Oc);T(Qs.$$.fragment,k0),k0.forEach(t),b0.forEach(t),Uk=m(bu),Ic=a(bu,"SPAN",{});var v0=s(Ic);Bk=n(v0,"TFRobertaPreLayerNormForQuestionAnswering"),v0.forEach(t),bu.forEach(t),bh=m(i),ut=a(i,"DIV",{class:!0});var no=s(ut);T(Hs.$$.fragment,no),Qk=m(no),nn=a(no,"P",{});var kd=s(nn);Hk=n(kd,`RoBERTa-PreLayerNorm 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 `),Dc=a(kd,"CODE",{});var T0=s(Dc);Kk=n(T0,"span start logits"),T0.forEach(t),Vk=n(kd," and "),Sc=a(kd,"CODE",{});var w0=s(Sc);Jk=n(w0,"span end logits"),w0.forEach(t),Gk=n(kd,")."),kd.forEach(t),Xk=m(no),Ks=a(no,"P",{});var ku=s(Ks);Yk=n(ku,"This model inherits from "),Xl=a(ku,"A",{href:!0});var $0=s(Xl);Zk=n($0,"TFPreTrainedModel"),$0.forEach(t),ev=n(ku,`. 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.)`),ku.forEach(t),tv=m(no),Vs=a(no,"P",{});var vu=s(Vs);ov=n(vu,"This model is also a "),Js=a(vu,"A",{href:!0,rel:!0});var P0=s(Js);nv=n(P0,"tf.keras.Model"),P0.forEach(t),rv=n(vu,` 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.`),vu.forEach(t),av=m(no),T(Tr.$$.fragment,no),sv=m(no),Ft=a(no,"DIV",{class:!0});var Fo=s(Ft);T(Gs.$$.fragment,Fo),iv=m(Fo),rn=a(Fo,"P",{});var vd=s(rn);lv=n(vd,"The "),Yl=a(vd,"A",{href:!0});var F0=s(Yl);dv=n(F0,"TFRobertaPreLayerNormForQuestionAnswering"),F0.forEach(t),cv=n(vd," forward method, overrides the "),Wc=a(vd,"CODE",{});var N0=s(Wc);pv=n(N0,"__call__"),N0.forEach(t),mv=n(vd," special method."),vd.forEach(t),hv=m(Fo),T(wr.$$.fragment,Fo),uv=m(Fo),T($r.$$.fragment,Fo),fv=m(Fo),T(Pr.$$.fragment,Fo),Fo.forEach(t),no.forEach(t),kh=m(i),an=a(i,"H2",{class:!0});var Tu=s(an);Fr=a(Tu,"A",{id:!0,class:!0,href:!0});var L0=s(Fr);Uc=a(L0,"SPAN",{});var x0=s(Uc);T(Xs.$$.fragment,x0),x0.forEach(t),L0.forEach(t),gv=m(Tu),Bc=a(Tu,"SPAN",{});var M0=s(Bc);_v=n(M0,"FlaxRobertaPreLayerNormModel"),M0.forEach(t),Tu.forEach(t),vh=m(i),et=a(i,"DIV",{class:!0});var Lt=s(et);T(Ys.$$.fragment,Lt),yv=m(Lt),Qc=a(Lt,"P",{});var E0=s(Qc);bv=n(E0,"The bare RoBERTa-PreLayerNorm Model transformer outputting raw hidden-states without any specific head on top."),E0.forEach(t),kv=m(Lt),Zs=a(Lt,"P",{});var wu=s(Zs);vv=n(wu,"This model inherits from "),Zl=a(wu,"A",{href:!0});var R0=s(Zl);Tv=n(R0,"FlaxPreTrainedModel"),R0.forEach(t),wv=n(wu,`. 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)`),wu.forEach(t),$v=m(Lt),ei=a(Lt,"P",{});var $u=s(ei);Pv=n($u,"This model is also a Flax Linen "),ti=a($u,"A",{href:!0,rel:!0});var z0=s(ti);Fv=n(z0,"flax.linen.Module"),z0.forEach(t),Nv=n($u,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),$u.forEach(t),Lv=m(Lt),Hc=a(Lt,"P",{});var C0=s(Hc);xv=n(C0,"Finally, this model supports inherent JAX features such as:"),C0.forEach(t),Mv=m(Lt),ao=a(Lt,"UL",{});var oa=s(ao);Kc=a(oa,"LI",{});var q0=s(Kc);oi=a(q0,"A",{href:!0,rel:!0});var j0=s(oi);Ev=n(j0,"Just-In-Time (JIT) compilation"),j0.forEach(t),q0.forEach(t),Rv=m(oa),Vc=a(oa,"LI",{});var A0=s(Vc);ni=a(A0,"A",{href:!0,rel:!0});var O0=s(ni);zv=n(O0,"Automatic Differentiation"),O0.forEach(t),A0.forEach(t),Cv=m(oa),Jc=a(oa,"LI",{});var I0=s(Jc);ri=a(I0,"A",{href:!0,rel:!0});var D0=s(ri);qv=n(D0,"Vectorization"),D0.forEach(t),I0.forEach(t),jv=m(oa),Gc=a(oa,"LI",{});var S0=s(Gc);ai=a(S0,"A",{href:!0,rel:!0});var W0=s(ai);Av=n(W0,"Parallelization"),W0.forEach(t),S0.forEach(t),oa.forEach(t),Ov=m(Lt),Qt=a(Lt,"DIV",{class:!0});var na=s(Qt);T(si.$$.fragment,na),Iv=m(na),sn=a(na,"P",{});var Td=s(sn);Dv=n(Td,"The "),Xc=a(Td,"CODE",{});var U0=s(Xc);Sv=n(U0,"FlaxRobertaPreLayerNormPreTrainedModel"),U0.forEach(t),Wv=n(Td," forward method, overrides the "),Yc=a(Td,"CODE",{});var B0=s(Yc);Uv=n(B0,"__call__"),B0.forEach(t),Bv=n(Td," special method."),Td.forEach(t),Qv=m(na),T(Nr.$$.fragment,na),Hv=m(na),T(Lr.$$.fragment,na),na.forEach(t),Lt.forEach(t),Th=m(i),ln=a(i,"H2",{class:!0});var Pu=s(ln);xr=a(Pu,"A",{id:!0,class:!0,href:!0});var Q0=s(xr);Zc=a(Q0,"SPAN",{});var H0=s(Zc);T(ii.$$.fragment,H0),H0.forEach(t),Q0.forEach(t),Kv=m(Pu),ep=a(Pu,"SPAN",{});var K0=s(ep);Vv=n(K0,"FlaxRobertaPreLayerNormForCausalLM"),K0.forEach(t),Pu.forEach(t),wh=m(i),tt=a(i,"DIV",{class:!0});var xt=s(tt);T(li.$$.fragment,xt),Jv=m(xt),tp=a(xt,"P",{});var V0=s(tp);Gv=n(V0,`RobertaPreLayerNorm Model with a language modeling head on top (a linear layer on top of the hidden-states output)
e.g for autoregressive tasks.`),V0.forEach(t),Xv=m(xt),di=a(xt,"P",{});var Fu=s(di);Yv=n(Fu,"This model inherits from "),ed=a(Fu,"A",{href:!0});var J0=s(ed);Zv=n(J0,"FlaxPreTrainedModel"),J0.forEach(t),eT=n(Fu,`. 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)`),Fu.forEach(t),tT=m(xt),ci=a(xt,"P",{});var Nu=s(ci);oT=n(Nu,"This model is also a Flax Linen "),pi=a(Nu,"A",{href:!0,rel:!0});var G0=s(pi);nT=n(G0,"flax.linen.Module"),G0.forEach(t),rT=n(Nu,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Nu.forEach(t),aT=m(xt),op=a(xt,"P",{});var X0=s(op);sT=n(X0,"Finally, this model supports inherent JAX features such as:"),X0.forEach(t),iT=m(xt),so=a(xt,"UL",{});var ra=s(so);np=a(ra,"LI",{});var Y0=s(np);mi=a(Y0,"A",{href:!0,rel:!0});var Z0=s(mi);lT=n(Z0,"Just-In-Time (JIT) compilation"),Z0.forEach(t),Y0.forEach(t),dT=m(ra),rp=a(ra,"LI",{});var eF=s(rp);hi=a(eF,"A",{href:!0,rel:!0});var tF=s(hi);cT=n(tF,"Automatic Differentiation"),tF.forEach(t),eF.forEach(t),pT=m(ra),ap=a(ra,"LI",{});var oF=s(ap);ui=a(oF,"A",{href:!0,rel:!0});var nF=s(ui);mT=n(nF,"Vectorization"),nF.forEach(t),oF.forEach(t),hT=m(ra),sp=a(ra,"LI",{});var rF=s(sp);fi=a(rF,"A",{href:!0,rel:!0});var aF=s(fi);uT=n(aF,"Parallelization"),aF.forEach(t),rF.forEach(t),ra.forEach(t),fT=m(xt),Ht=a(xt,"DIV",{class:!0});var aa=s(Ht);T(gi.$$.fragment,aa),gT=m(aa),dn=a(aa,"P",{});var wd=s(dn);_T=n(wd,"The "),ip=a(wd,"CODE",{});var sF=s(ip);yT=n(sF,"FlaxRobertaPreLayerNormPreTrainedModel"),sF.forEach(t),bT=n(wd," forward method, overrides the "),lp=a(wd,"CODE",{});var iF=s(lp);kT=n(iF,"__call__"),iF.forEach(t),vT=n(wd," special method."),wd.forEach(t),TT=m(aa),T(Mr.$$.fragment,aa),wT=m(aa),T(Er.$$.fragment,aa),aa.forEach(t),xt.forEach(t),$h=m(i),cn=a(i,"H2",{class:!0});var Lu=s(cn);Rr=a(Lu,"A",{id:!0,class:!0,href:!0});var lF=s(Rr);dp=a(lF,"SPAN",{});var dF=s(dp);T(_i.$$.fragment,dF),dF.forEach(t),lF.forEach(t),$T=m(Lu),cp=a(Lu,"SPAN",{});var cF=s(cp);PT=n(cF,"FlaxRobertaPreLayerNormForMaskedLM"),cF.forEach(t),Lu.forEach(t),Ph=m(i),ot=a(i,"DIV",{class:!0});var Mt=s(ot);T(yi.$$.fragment,Mt),FT=m(Mt),bi=a(Mt,"P",{});var xu=s(bi);NT=n(xu,"RoBERTa-PreLayerNorm Model with a "),pp=a(xu,"CODE",{});var pF=s(pp);LT=n(pF,"language modeling"),pF.forEach(t),xT=n(xu," head on top."),xu.forEach(t),MT=m(Mt),ki=a(Mt,"P",{});var Mu=s(ki);ET=n(Mu,"This model inherits from "),td=a(Mu,"A",{href:!0});var mF=s(td);RT=n(mF,"FlaxPreTrainedModel"),mF.forEach(t),zT=n(Mu,`. 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)`),Mu.forEach(t),CT=m(Mt),vi=a(Mt,"P",{});var Eu=s(vi);qT=n(Eu,"This model is also a Flax Linen "),Ti=a(Eu,"A",{href:!0,rel:!0});var hF=s(Ti);jT=n(hF,"flax.linen.Module"),hF.forEach(t),AT=n(Eu,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Eu.forEach(t),OT=m(Mt),mp=a(Mt,"P",{});var uF=s(mp);IT=n(uF,"Finally, this model supports inherent JAX features such as:"),uF.forEach(t),DT=m(Mt),io=a(Mt,"UL",{});var sa=s(io);hp=a(sa,"LI",{});var fF=s(hp);wi=a(fF,"A",{href:!0,rel:!0});var gF=s(wi);ST=n(gF,"Just-In-Time (JIT) compilation"),gF.forEach(t),fF.forEach(t),WT=m(sa),up=a(sa,"LI",{});var _F=s(up);$i=a(_F,"A",{href:!0,rel:!0});var yF=s($i);UT=n(yF,"Automatic Differentiation"),yF.forEach(t),_F.forEach(t),BT=m(sa),fp=a(sa,"LI",{});var bF=s(fp);Pi=a(bF,"A",{href:!0,rel:!0});var kF=s(Pi);QT=n(kF,"Vectorization"),kF.forEach(t),bF.forEach(t),HT=m(sa),gp=a(sa,"LI",{});var vF=s(gp);Fi=a(vF,"A",{href:!0,rel:!0});var TF=s(Fi);KT=n(TF,"Parallelization"),TF.forEach(t),vF.forEach(t),sa.forEach(t),VT=m(Mt),Kt=a(Mt,"DIV",{class:!0});var ia=s(Kt);T(Ni.$$.fragment,ia),JT=m(ia),pn=a(ia,"P",{});var $d=s(pn);GT=n($d,"The "),_p=a($d,"CODE",{});var wF=s(_p);XT=n(wF,"FlaxRobertaPreLayerNormPreTrainedModel"),wF.forEach(t),YT=n($d," forward method, overrides the "),yp=a($d,"CODE",{});var $F=s(yp);ZT=n($F,"__call__"),$F.forEach(t),ew=n($d," special method."),$d.forEach(t),tw=m(ia),T(zr.$$.fragment,ia),ow=m(ia),T(Cr.$$.fragment,ia),ia.forEach(t),Mt.forEach(t),Fh=m(i),mn=a(i,"H2",{class:!0});var Ru=s(mn);qr=a(Ru,"A",{id:!0,class:!0,href:!0});var PF=s(qr);bp=a(PF,"SPAN",{});var FF=s(bp);T(Li.$$.fragment,FF),FF.forEach(t),PF.forEach(t),nw=m(Ru),kp=a(Ru,"SPAN",{});var NF=s(kp);rw=n(NF,"FlaxRobertaPreLayerNormForSequenceClassification"),NF.forEach(t),Ru.forEach(t),Nh=m(i),nt=a(i,"DIV",{class:!0});var Et=s(nt);T(xi.$$.fragment,Et),aw=m(Et),vp=a(Et,"P",{});var LF=s(vp);sw=n(LF,`RobertaPreLayerNorm Model transformer with a sequence classification/regression head on top (a linear layer on top
of the pooled output) e.g. for GLUE tasks.`),LF.forEach(t),iw=m(Et),Mi=a(Et,"P",{});var zu=s(Mi);lw=n(zu,"This model inherits from "),od=a(zu,"A",{href:!0});var xF=s(od);dw=n(xF,"FlaxPreTrainedModel"),xF.forEach(t),cw=n(zu,`. 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)`),zu.forEach(t),pw=m(Et),Ei=a(Et,"P",{});var Cu=s(Ei);mw=n(Cu,"This model is also a Flax Linen "),Ri=a(Cu,"A",{href:!0,rel:!0});var MF=s(Ri);hw=n(MF,"flax.linen.Module"),MF.forEach(t),uw=n(Cu,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Cu.forEach(t),fw=m(Et),Tp=a(Et,"P",{});var EF=s(Tp);gw=n(EF,"Finally, this model supports inherent JAX features such as:"),EF.forEach(t),_w=m(Et),lo=a(Et,"UL",{});var la=s(lo);wp=a(la,"LI",{});var RF=s(wp);zi=a(RF,"A",{href:!0,rel:!0});var zF=s(zi);yw=n(zF,"Just-In-Time (JIT) compilation"),zF.forEach(t),RF.forEach(t),bw=m(la),$p=a(la,"LI",{});var CF=s($p);Ci=a(CF,"A",{href:!0,rel:!0});var qF=s(Ci);kw=n(qF,"Automatic Differentiation"),qF.forEach(t),CF.forEach(t),vw=m(la),Pp=a(la,"LI",{});var jF=s(Pp);qi=a(jF,"A",{href:!0,rel:!0});var AF=s(qi);Tw=n(AF,"Vectorization"),AF.forEach(t),jF.forEach(t),ww=m(la),Fp=a(la,"LI",{});var OF=s(Fp);ji=a(OF,"A",{href:!0,rel:!0});var IF=s(ji);$w=n(IF,"Parallelization"),IF.forEach(t),OF.forEach(t),la.forEach(t),Pw=m(Et),Vt=a(Et,"DIV",{class:!0});var da=s(Vt);T(Ai.$$.fragment,da),Fw=m(da),hn=a(da,"P",{});var Pd=s(hn);Nw=n(Pd,"The "),Np=a(Pd,"CODE",{});var DF=s(Np);Lw=n(DF,"FlaxRobertaPreLayerNormPreTrainedModel"),DF.forEach(t),xw=n(Pd," forward method, overrides the "),Lp=a(Pd,"CODE",{});var SF=s(Lp);Mw=n(SF,"__call__"),SF.forEach(t),Ew=n(Pd," special method."),Pd.forEach(t),Rw=m(da),T(jr.$$.fragment,da),zw=m(da),T(Ar.$$.fragment,da),da.forEach(t),Et.forEach(t),Lh=m(i),un=a(i,"H2",{class:!0});var qu=s(un);Or=a(qu,"A",{id:!0,class:!0,href:!0});var WF=s(Or);xp=a(WF,"SPAN",{});var UF=s(xp);T(Oi.$$.fragment,UF),UF.forEach(t),WF.forEach(t),Cw=m(qu),Mp=a(qu,"SPAN",{});var BF=s(Mp);qw=n(BF,"FlaxRobertaPreLayerNormForMultipleChoice"),BF.forEach(t),qu.forEach(t),xh=m(i),rt=a(i,"DIV",{class:!0});var Rt=s(rt);T(Ii.$$.fragment,Rt),jw=m(Rt),Ep=a(Rt,"P",{});var QF=s(Ep);Aw=n(QF,`RobertaPreLayerNorm 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.`),QF.forEach(t),Ow=m(Rt),Di=a(Rt,"P",{});var ju=s(Di);Iw=n(ju,"This model inherits from "),nd=a(ju,"A",{href:!0});var HF=s(nd);Dw=n(HF,"FlaxPreTrainedModel"),HF.forEach(t),Sw=n(ju,`. 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)`),ju.forEach(t),Ww=m(Rt),Si=a(Rt,"P",{});var Au=s(Si);Uw=n(Au,"This model is also a Flax Linen "),Wi=a(Au,"A",{href:!0,rel:!0});var KF=s(Wi);Bw=n(KF,"flax.linen.Module"),KF.forEach(t),Qw=n(Au,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Au.forEach(t),Hw=m(Rt),Rp=a(Rt,"P",{});var VF=s(Rp);Kw=n(VF,"Finally, this model supports inherent JAX features such as:"),VF.forEach(t),Vw=m(Rt),co=a(Rt,"UL",{});var ca=s(co);zp=a(ca,"LI",{});var JF=s(zp);Ui=a(JF,"A",{href:!0,rel:!0});var GF=s(Ui);Jw=n(GF,"Just-In-Time (JIT) compilation"),GF.forEach(t),JF.forEach(t),Gw=m(ca),Cp=a(ca,"LI",{});var XF=s(Cp);Bi=a(XF,"A",{href:!0,rel:!0});var YF=s(Bi);Xw=n(YF,"Automatic Differentiation"),YF.forEach(t),XF.forEach(t),Yw=m(ca),qp=a(ca,"LI",{});var ZF=s(qp);Qi=a(ZF,"A",{href:!0,rel:!0});var e2=s(Qi);Zw=n(e2,"Vectorization"),e2.forEach(t),ZF.forEach(t),e$=m(ca),jp=a(ca,"LI",{});var t2=s(jp);Hi=a(t2,"A",{href:!0,rel:!0});var o2=s(Hi);t$=n(o2,"Parallelization"),o2.forEach(t),t2.forEach(t),ca.forEach(t),o$=m(Rt),Jt=a(Rt,"DIV",{class:!0});var pa=s(Jt);T(Ki.$$.fragment,pa),n$=m(pa),fn=a(pa,"P",{});var Fd=s(fn);r$=n(Fd,"The "),Ap=a(Fd,"CODE",{});var n2=s(Ap);a$=n(n2,"FlaxRobertaPreLayerNormPreTrainedModel"),n2.forEach(t),s$=n(Fd," forward method, overrides the "),Op=a(Fd,"CODE",{});var r2=s(Op);i$=n(r2,"__call__"),r2.forEach(t),l$=n(Fd," special method."),Fd.forEach(t),d$=m(pa),T(Ir.$$.fragment,pa),c$=m(pa),T(Dr.$$.fragment,pa),pa.forEach(t),Rt.forEach(t),Mh=m(i),gn=a(i,"H2",{class:!0});var Ou=s(gn);Sr=a(Ou,"A",{id:!0,class:!0,href:!0});var a2=s(Sr);Ip=a(a2,"SPAN",{});var s2=s(Ip);T(Vi.$$.fragment,s2),s2.forEach(t),a2.forEach(t),p$=m(Ou),Dp=a(Ou,"SPAN",{});var i2=s(Dp);m$=n(i2,"FlaxRobertaPreLayerNormForTokenClassification"),i2.forEach(t),Ou.forEach(t),Eh=m(i),at=a(i,"DIV",{class:!0});var zt=s(at);T(Ji.$$.fragment,zt),h$=m(zt),Sp=a(zt,"P",{});var l2=s(Sp);u$=n(l2,`RobertaPreLayerNorm 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.`),l2.forEach(t),f$=m(zt),Gi=a(zt,"P",{});var Iu=s(Gi);g$=n(Iu,"This model inherits from "),rd=a(Iu,"A",{href:!0});var d2=s(rd);_$=n(d2,"FlaxPreTrainedModel"),d2.forEach(t),y$=n(Iu,`. 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)`),Iu.forEach(t),b$=m(zt),Xi=a(zt,"P",{});var Du=s(Xi);k$=n(Du,"This model is also a Flax Linen "),Yi=a(Du,"A",{href:!0,rel:!0});var c2=s(Yi);v$=n(c2,"flax.linen.Module"),c2.forEach(t),T$=n(Du,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Du.forEach(t),w$=m(zt),Wp=a(zt,"P",{});var p2=s(Wp);$$=n(p2,"Finally, this model supports inherent JAX features such as:"),p2.forEach(t),P$=m(zt),po=a(zt,"UL",{});var ma=s(po);Up=a(ma,"LI",{});var m2=s(Up);Zi=a(m2,"A",{href:!0,rel:!0});var h2=s(Zi);F$=n(h2,"Just-In-Time (JIT) compilation"),h2.forEach(t),m2.forEach(t),N$=m(ma),Bp=a(ma,"LI",{});var u2=s(Bp);el=a(u2,"A",{href:!0,rel:!0});var f2=s(el);L$=n(f2,"Automatic Differentiation"),f2.forEach(t),u2.forEach(t),x$=m(ma),Qp=a(ma,"LI",{});var g2=s(Qp);tl=a(g2,"A",{href:!0,rel:!0});var _2=s(tl);M$=n(_2,"Vectorization"),_2.forEach(t),g2.forEach(t),E$=m(ma),Hp=a(ma,"LI",{});var y2=s(Hp);ol=a(y2,"A",{href:!0,rel:!0});var b2=s(ol);R$=n(b2,"Parallelization"),b2.forEach(t),y2.forEach(t),ma.forEach(t),z$=m(zt),Gt=a(zt,"DIV",{class:!0});var ha=s(Gt);T(nl.$$.fragment,ha),C$=m(ha),_n=a(ha,"P",{});var Nd=s(_n);q$=n(Nd,"The "),Kp=a(Nd,"CODE",{});var k2=s(Kp);j$=n(k2,"FlaxRobertaPreLayerNormPreTrainedModel"),k2.forEach(t),A$=n(Nd," forward method, overrides the "),Vp=a(Nd,"CODE",{});var v2=s(Vp);O$=n(v2,"__call__"),v2.forEach(t),I$=n(Nd," special method."),Nd.forEach(t),D$=m(ha),T(Wr.$$.fragment,ha),S$=m(ha),T(Ur.$$.fragment,ha),ha.forEach(t),zt.forEach(t),Rh=m(i),yn=a(i,"H2",{class:!0});var Su=s(yn);Br=a(Su,"A",{id:!0,class:!0,href:!0});var T2=s(Br);Jp=a(T2,"SPAN",{});var w2=s(Jp);T(rl.$$.fragment,w2),w2.forEach(t),T2.forEach(t),W$=m(Su),Gp=a(Su,"SPAN",{});var $2=s(Gp);U$=n($2,"FlaxRobertaPreLayerNormForQuestionAnswering"),$2.forEach(t),Su.forEach(t),zh=m(i),st=a(i,"DIV",{class:!0});var Ct=s(st);T(al.$$.fragment,Ct),B$=m(Ct),bn=a(Ct,"P",{});var Ld=s(bn);Q$=n(Ld,`RobertaPreLayerNorm 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 `),Xp=a(Ld,"CODE",{});var P2=s(Xp);H$=n(P2,"span start logits"),P2.forEach(t),K$=n(Ld," and "),Yp=a(Ld,"CODE",{});var F2=s(Yp);V$=n(F2,"span end logits"),F2.forEach(t),J$=n(Ld,")."),Ld.forEach(t),G$=m(Ct),sl=a(Ct,"P",{});var Wu=s(sl);X$=n(Wu,"This model inherits from "),ad=a(Wu,"A",{href:!0});var N2=s(ad);Y$=n(N2,"FlaxPreTrainedModel"),N2.forEach(t),Z$=n(Wu,`. 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)`),Wu.forEach(t),e1=m(Ct),il=a(Ct,"P",{});var Uu=s(il);t1=n(Uu,"This model is also a Flax Linen "),ll=a(Uu,"A",{href:!0,rel:!0});var L2=s(ll);o1=n(L2,"flax.linen.Module"),L2.forEach(t),n1=n(Uu,`
subclass. Use it as a regular Flax linen Module and refer to the Flax documentation for all matter related to
general usage and behavior.`),Uu.forEach(t),r1=m(Ct),Zp=a(Ct,"P",{});var x2=s(Zp);a1=n(x2,"Finally, this model supports inherent JAX features such as:"),x2.forEach(t),s1=m(Ct),mo=a(Ct,"UL",{});var ua=s(mo);em=a(ua,"LI",{});var M2=s(em);dl=a(M2,"A",{href:!0,rel:!0});var E2=s(dl);i1=n(E2,"Just-In-Time (JIT) compilation"),E2.forEach(t),M2.forEach(t),l1=m(ua),tm=a(ua,"LI",{});var R2=s(tm);cl=a(R2,"A",{href:!0,rel:!0});var z2=s(cl);d1=n(z2,"Automatic Differentiation"),z2.forEach(t),R2.forEach(t),c1=m(ua),om=a(ua,"LI",{});var C2=s(om);pl=a(C2,"A",{href:!0,rel:!0});var q2=s(pl);p1=n(q2,"Vectorization"),q2.forEach(t),C2.forEach(t),m1=m(ua),nm=a(ua,"LI",{});var j2=s(nm);ml=a(j2,"A",{href:!0,rel:!0});var A2=s(ml);h1=n(A2,"Parallelization"),A2.forEach(t),j2.forEach(t),ua.forEach(t),u1=m(Ct),Xt=a(Ct,"DIV",{class:!0});var fa=s(Xt);T(hl.$$.fragment,fa),f1=m(fa),kn=a(fa,"P",{});var xd=s(kn);g1=n(xd,"The "),rm=a(xd,"CODE",{});var O2=s(rm);_1=n(O2,"FlaxRobertaPreLayerNormPreTrainedModel"),O2.forEach(t),y1=n(xd," forward method, overrides the "),am=a(xd,"CODE",{});var I2=s(am);b1=n(I2,"__call__"),I2.forEach(t),k1=n(xd," special method."),xd.forEach(t),v1=m(fa),T(Qr.$$.fragment,fa),T1=m(fa),T(Hr.$$.fragment,fa),fa.forEach(t),Ct.forEach(t),this.h()},h(){f(d,"name","hf:doc:metadata"),f(d,"content",JSON.stringify(HN)),f(u,"id","robertaprelayernorm"),f(u,"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"),f(u,"href","#robertaprelayernorm"),f(h,"class","relative group"),f(ae,"id","overview"),f(ae,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(ae,"href","#overview"),f(D,"class","relative group"),f(se,"href","https://arxiv.org/abs/1904.01038"),f(se,"rel","nofollow"),f(ie,"href","https://fairseq.readthedocs.io/"),f(ie,"rel","nofollow"),f(de,"href","roberta"),f(k,"href","https://arxiv.org/abs/1706.03762"),f(k,"rel","nofollow"),f(De,"href","https://fairseq.readthedocs.io/"),f(De,"rel","nofollow"),f(Se,"href","https://huggingface.co/andreasmaden"),f(Se,"rel","nofollow"),f(We,"href","https://github.com/princeton-nlp/DinkyTrain"),f(We,"rel","nofollow"),f($n,"id","transformers.RobertaPreLayerNormConfig"),f($n,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f($n,"href","#transformers.RobertaPreLayerNormConfig"),f(qe,"class","relative group"),f(Tl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormModel"),f(wl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormModel"),f(ya,"href","https://huggingface.co/andreasmadsen/efficient_mlm_m0.40"),f(ya,"rel","nofollow"),f($l,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),f(Pl,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),f(qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Fn,"id","transformers.RobertaPreLayerNormModel"),f(Fn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Fn,"href","#transformers.RobertaPreLayerNormModel"),f(Lo,"class","relative group"),f(Fl,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),f(wa,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(wa,"rel","nofollow"),f(Pa,"href","https://arxiv.org/abs/1706.03762"),f(Pa,"rel","nofollow"),f(Nl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormModel"),f(jt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Ze,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Mn,"id","transformers.RobertaPreLayerNormForCausalLM"),f(Mn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Mn,"href","#transformers.RobertaPreLayerNormForCausalLM"),f(Mo,"class","relative group"),f(Ll,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),f(Ra,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(Ra,"rel","nofollow"),f(xl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormForCausalLM"),f(At,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(gt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(zn,"id","transformers.RobertaPreLayerNormForMaskedLM"),f(zn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(zn,"href","#transformers.RobertaPreLayerNormForMaskedLM"),f(Ro,"class","relative group"),f(Ml,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),f(Ia,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(Ia,"rel","nofollow"),f(El,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormForMaskedLM"),f(Ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(_t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(jn,"id","transformers.RobertaPreLayerNormForSequenceClassification"),f(jn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(jn,"href","#transformers.RobertaPreLayerNormForSequenceClassification"),f(Co,"class","relative group"),f(Rl,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),f(Qa,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(Qa,"rel","nofollow"),f(zl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormForSequenceClassification"),f(Tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(yt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Dn,"id","transformers.RobertaPreLayerNormForMultipleChoice"),f(Dn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Dn,"href","#transformers.RobertaPreLayerNormForMultipleChoice"),f(jo,"class","relative group"),f(Cl,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),f(Xa,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(Xa,"rel","nofollow"),f(ql,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormForMultipleChoice"),f(It,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Un,"id","transformers.RobertaPreLayerNormForTokenClassification"),f(Un,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Un,"href","#transformers.RobertaPreLayerNormForTokenClassification"),f(Oo,"class","relative group"),f(jl,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),f(ns,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(ns,"rel","nofollow"),f(Al,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormForTokenClassification"),f(Dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Hn,"id","transformers.RobertaPreLayerNormForQuestionAnswering"),f(Hn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Hn,"href","#transformers.RobertaPreLayerNormForQuestionAnswering"),f(Do,"class","relative group"),f(Ol,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),f(ds,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),f(ds,"rel","nofollow"),f(Il,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.RobertaPreLayerNormForQuestionAnswering"),f(St,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(vt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Jn,"id","transformers.TFRobertaPreLayerNormModel"),f(Jn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Jn,"href","#transformers.TFRobertaPreLayerNormModel"),f(Uo,"class","relative group"),f(Dl,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),f(fs,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(fs,"rel","nofollow"),f(Sl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormModel"),f(Wt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Zn,"id","transformers.TFRobertaPreLayerNormForCausalLM"),f(Zn,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),f(Zn,"href","#transformers.TFRobertaPreLayerNormForCausalLM"),f(Qo,"class","relative group"),f(Wl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormForCausalLM"),f(Ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Ho,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(or,"id","transformers.TFRobertaPreLayerNormForMaskedLM"),f(or,"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"),f(or,"href","#transformers.TFRobertaPreLayerNormForMaskedLM"),f(Vo,"class","relative group"),f(Ul,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),f(Ps,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(Ps,"rel","nofollow"),f(Bl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormForMaskedLM"),f(wt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(ct,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(ir,"id","transformers.TFRobertaPreLayerNormForSequenceClassification"),f(ir,"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"),f(ir,"href","#transformers.TFRobertaPreLayerNormForSequenceClassification"),f(Go,"class","relative group"),f(Ql,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),f(Es,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(Es,"rel","nofollow"),f(Hl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormForSequenceClassification"),f($t,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(mr,"id","transformers.TFRobertaPreLayerNormForMultipleChoice"),f(mr,"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"),f(mr,"href","#transformers.TFRobertaPreLayerNormForMultipleChoice"),f(Yo,"class","relative group"),f(Kl,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),f(As,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(As,"rel","nofollow"),f(Vl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormForMultipleChoice"),f(Bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(mt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(gr,"id","transformers.TFRobertaPreLayerNormForTokenClassification"),f(gr,"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"),f(gr,"href","#transformers.TFRobertaPreLayerNormForTokenClassification"),f(en,"class","relative group"),f(Jl,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),f(Us,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(Us,"rel","nofollow"),f(Gl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormForTokenClassification"),f(Pt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(vr,"id","transformers.TFRobertaPreLayerNormForQuestionAnswering"),f(vr,"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"),f(vr,"href","#transformers.TFRobertaPreLayerNormForQuestionAnswering"),f(on,"class","relative group"),f(Xl,"href","/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel"),f(Js,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),f(Js,"rel","nofollow"),f(Yl,"href","/docs/transformers/main/en/model_doc/roberta-prelayernorm#transformers.TFRobertaPreLayerNormForQuestionAnswering"),f(Ft,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Fr,"id","transformers.FlaxRobertaPreLayerNormModel"),f(Fr,"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"),f(Fr,"href","#transformers.FlaxRobertaPreLayerNormModel"),f(an,"class","relative group"),f(Zl,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),f(ti,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),f(ti,"rel","nofollow"),f(oi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),f(oi,"rel","nofollow"),f(ni,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),f(ni,"rel","nofollow"),f(ri,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),f(ri,"rel","nofollow"),f(ai,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),f(ai,"rel","nofollow"),f(Qt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(et,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(xr,"id","transformers.FlaxRobertaPreLayerNormForCausalLM"),f(xr,"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"),f(xr,"href","#transformers.FlaxRobertaPreLayerNormForCausalLM"),f(ln,"class","relative group"),f(ed,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),f(pi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),f(pi,"rel","nofollow"),f(mi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),f(mi,"rel","nofollow"),f(hi,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),f(hi,"rel","nofollow"),f(ui,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),f(ui,"rel","nofollow"),f(fi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),f(fi,"rel","nofollow"),f(Ht,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(tt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Rr,"id","transformers.FlaxRobertaPreLayerNormForMaskedLM"),f(Rr,"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"),f(Rr,"href","#transformers.FlaxRobertaPreLayerNormForMaskedLM"),f(cn,"class","relative group"),f(td,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),f(Ti,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),f(Ti,"rel","nofollow"),f(wi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),f(wi,"rel","nofollow"),f($i,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),f($i,"rel","nofollow"),f(Pi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),f(Pi,"rel","nofollow"),f(Fi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),f(Fi,"rel","nofollow"),f(Kt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(qr,"id","transformers.FlaxRobertaPreLayerNormForSequenceClassification"),f(qr,"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"),f(qr,"href","#transformers.FlaxRobertaPreLayerNormForSequenceClassification"),f(mn,"class","relative group"),f(od,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),f(Ri,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),f(Ri,"rel","nofollow"),f(zi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),f(zi,"rel","nofollow"),f(Ci,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),f(Ci,"rel","nofollow"),f(qi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),f(qi,"rel","nofollow"),f(ji,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),f(ji,"rel","nofollow"),f(Vt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(nt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Or,"id","transformers.FlaxRobertaPreLayerNormForMultipleChoice"),f(Or,"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"),f(Or,"href","#transformers.FlaxRobertaPreLayerNormForMultipleChoice"),f(un,"class","relative group"),f(nd,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),f(Wi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),f(Wi,"rel","nofollow"),f(Ui,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),f(Ui,"rel","nofollow"),f(Bi,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),f(Bi,"rel","nofollow"),f(Qi,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),f(Qi,"rel","nofollow"),f(Hi,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),f(Hi,"rel","nofollow"),f(Jt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(rt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Sr,"id","transformers.FlaxRobertaPreLayerNormForTokenClassification"),f(Sr,"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"),f(Sr,"href","#transformers.FlaxRobertaPreLayerNormForTokenClassification"),f(gn,"class","relative group"),f(rd,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),f(Yi,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),f(Yi,"rel","nofollow"),f(Zi,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),f(Zi,"rel","nofollow"),f(el,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),f(el,"rel","nofollow"),f(tl,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),f(tl,"rel","nofollow"),f(ol,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),f(ol,"rel","nofollow"),f(Gt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(at,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(Br,"id","transformers.FlaxRobertaPreLayerNormForQuestionAnswering"),f(Br,"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"),f(Br,"href","#transformers.FlaxRobertaPreLayerNormForQuestionAnswering"),f(yn,"class","relative group"),f(ad,"href","/docs/transformers/main/en/main_classes/model#transformers.FlaxPreTrainedModel"),f(ll,"href","https://flax.readthedocs.io/en/latest/flax.linen.html#module"),f(ll,"rel","nofollow"),f(dl,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),f(dl,"rel","nofollow"),f(cl,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),f(cl,"rel","nofollow"),f(pl,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),f(pl,"rel","nofollow"),f(ml,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),f(ml,"rel","nofollow"),f(Xt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),f(st,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(i,b){e(document.head,d),_(i,y,b),_(i,h,b),e(h,u),e(u,g),w(l,g,null),e(h,c),e(h,x),e(x,ye),_(i,he,b),_(i,D,b),e(D,ae),e(ae,te),w(L,te,null),e(D,be),e(D,B),e(B,ke),_(i,ue,b),_(i,A,b),e(A,ve),e(A,se),e(se,K),e(A,Te),e(A,ce),e(ce,V),e(A,we),e(A,ie),e(ie,J),e(A,$e),_(i,fe,b),_(i,ee,b),e(ee,R),_(i,C,b),_(i,le,b),e(le,Q),e(Q,Pe),_(i,ge,b),_(i,U,b),e(U,Fe),_(i,_e,b),_(i,z,b),e(z,H),e(H,G),e(H,de),e(de,Ne),e(H,X),e(H,pe),e(pe,Le),e(H,S),e(H,me),e(me,Y),e(H,xe),e(H,oe),e(oe,q),e(H,Me),e(H,j),e(j,Ee),e(H,Re),e(H,k),e(k,M),e(H,Be),e(z,re),e(z,ze),e(ze,Qe),e(ze,E),e(E,He),e(ze,Ke),e(ze,De),e(De,Ve),e(ze,Je),_(i,O,b),_(i,I,b),e(I,Ge),e(I,Se),e(Se,Z),e(I,Xe),e(I,We),e(We,Ce),e(I,Ye),_(i,ne,b),_(i,qe,b),e(qe,$n),e($n,Md),w(ga,Md,null),e(qe,Bu),e(qe,Ed),e(Ed,Qu),_(i,Qm,b),_(i,qt,b),w(_a,qt,null),e(qt,Hu),e(qt,ro),e(ro,Ku),e(ro,Tl),e(Tl,Vu),e(ro,Ju),e(ro,wl),e(wl,Gu),e(ro,Xu),e(ro,ya),e(ya,Yu),e(ro,Zu),e(qt,ef),e(qt,No),e(No,tf),e(No,$l),e($l,of),e(No,nf),e(No,Pl),e(Pl,rf),e(No,af),e(qt,sf),w(Pn,qt,null),_(i,Hm,b),_(i,Lo,b),e(Lo,Fn),e(Fn,Rd),w(ba,Rd,null),e(Lo,lf),e(Lo,zd),e(zd,df),_(i,Km,b),_(i,Ze,b),w(ka,Ze,null),e(Ze,cf),e(Ze,Cd),e(Cd,pf),e(Ze,mf),e(Ze,va),e(va,hf),e(va,Fl),e(Fl,uf),e(va,ff),e(Ze,gf),e(Ze,Ta),e(Ta,_f),e(Ta,wa),e(wa,yf),e(Ta,bf),e(Ze,kf),e(Ze,$a),e($a,vf),e($a,qd),e(qd,Tf),e($a,wf),e(Ze,$f),e(Ze,lt),e(lt,Pf),e(lt,jd),e(jd,Ff),e(lt,Nf),e(lt,Ad),e(Ad,Lf),e(lt,xf),e(lt,Od),e(Od,Mf),e(lt,Ef),e(lt,Id),e(Id,Rf),e(lt,zf),e(lt,Dd),e(Dd,Cf),e(lt,qf),e(lt,Sd),e(Sd,jf),e(lt,Af),e(Ze,Of),e(Ze,Nn),e(Nn,If),e(Nn,Wd),e(Wd,Df),e(Nn,Sf),e(Nn,Pa),e(Pa,Wf),e(Ze,Uf),e(Ze,jt),w(Fa,jt,null),e(jt,Bf),e(jt,xo),e(xo,Qf),e(xo,Nl),e(Nl,Hf),e(xo,Kf),e(xo,Ud),e(Ud,Vf),e(xo,Jf),e(jt,Gf),w(Ln,jt,null),e(jt,Xf),w(xn,jt,null),_(i,Vm,b),_(i,Mo,b),e(Mo,Mn),e(Mn,Bd),w(Na,Bd,null),e(Mo,Yf),e(Mo,Qd),e(Qd,Zf),_(i,Jm,b),_(i,gt,b),w(La,gt,null),e(gt,eg),e(gt,xa),e(xa,tg),e(xa,Hd),e(Hd,og),e(xa,ng),e(gt,rg),e(gt,Ma),e(Ma,ag),e(Ma,Ll),e(Ll,sg),e(Ma,ig),e(gt,lg),e(gt,Ea),e(Ea,dg),e(Ea,Ra),e(Ra,cg),e(Ea,pg),e(gt,mg),e(gt,At),w(za,At,null),e(At,hg),e(At,Eo),e(Eo,ug),e(Eo,xl),e(xl,fg),e(Eo,gg),e(Eo,Kd),e(Kd,_g),e(Eo,yg),e(At,bg),w(En,At,null),e(At,kg),w(Rn,At,null),_(i,Gm,b),_(i,Ro,b),e(Ro,zn),e(zn,Vd),w(Ca,Vd,null),e(Ro,vg),e(Ro,Jd),e(Jd,Tg),_(i,Xm,b),_(i,_t,b),w(qa,_t,null),e(_t,wg),e(_t,ja),e(ja,$g),e(ja,Gd),e(Gd,Pg),e(ja,Fg),e(_t,Ng),e(_t,Aa),e(Aa,Lg),e(Aa,Ml),e(Ml,xg),e(Aa,Mg),e(_t,Eg),e(_t,Oa),e(Oa,Rg),e(Oa,Ia),e(Ia,zg),e(Oa,Cg),e(_t,qg),e(_t,Ot),w(Da,Ot,null),e(Ot,jg),e(Ot,zo),e(zo,Ag),e(zo,El),e(El,Og),e(zo,Ig),e(zo,Xd),e(Xd,Dg),e(zo,Sg),e(Ot,Wg),w(Cn,Ot,null),e(Ot,Ug),w(qn,Ot,null),_(i,Ym,b),_(i,Co,b),e(Co,jn),e(jn,Yd),w(Sa,Yd,null),e(Co,Bg),e(Co,Zd),e(Zd,Qg),_(i,Zm,b),_(i,yt,b),w(Wa,yt,null),e(yt,Hg),e(yt,ec),e(ec,Kg),e(yt,Vg),e(yt,Ua),e(Ua,Jg),e(Ua,Rl),e(Rl,Gg),e(Ua,Xg),e(yt,Yg),e(yt,Ba),e(Ba,Zg),e(Ba,Qa),e(Qa,e_),e(Ba,t_),e(yt,o_),e(yt,Tt),w(Ha,Tt,null),e(Tt,n_),e(Tt,qo),e(qo,r_),e(qo,zl),e(zl,a_),e(qo,s_),e(qo,tc),e(tc,i_),e(qo,l_),e(Tt,d_),w(An,Tt,null),e(Tt,c_),w(On,Tt,null),e(Tt,p_),w(In,Tt,null),_(i,eh,b),_(i,jo,b),e(jo,Dn),e(Dn,oc),w(Ka,oc,null),e(jo,m_),e(jo,nc),e(nc,h_),_(i,th,b),_(i,bt,b),w(Va,bt,null),e(bt,u_),e(bt,rc),e(rc,f_),e(bt,g_),e(bt,Ja),e(Ja,__),e(Ja,Cl),e(Cl,y_),e(Ja,b_),e(bt,k_),e(bt,Ga),e(Ga,v_),e(Ga,Xa),e(Xa,T_),e(Ga,w_),e(bt,$_),e(bt,It),w(Ya,It,null),e(It,P_),e(It,Ao),e(Ao,F_),e(Ao,ql),e(ql,N_),e(Ao,L_),e(Ao,ac),e(ac,x_),e(Ao,M_),e(It,E_),w(Sn,It,null),e(It,R_),w(Wn,It,null),_(i,oh,b),_(i,Oo,b),e(Oo,Un),e(Un,sc),w(Za,sc,null),e(Oo,z_),e(Oo,ic),e(ic,C_),_(i,nh,b),_(i,kt,b),w(es,kt,null),e(kt,q_),e(kt,lc),e(lc,j_),e(kt,A_),e(kt,ts),e(ts,O_),e(ts,jl),e(jl,I_),e(ts,D_),e(kt,S_),e(kt,os),e(os,W_),e(os,ns),e(ns,U_),e(os,B_),e(kt,Q_),e(kt,Dt),w(rs,Dt,null),e(Dt,H_),e(Dt,Io),e(Io,K_),e(Io,Al),e(Al,V_),e(Io,J_),e(Io,dc),e(dc,G_),e(Io,X_),e(Dt,Y_),w(Bn,Dt,null),e(Dt,Z_),w(Qn,Dt,null),_(i,rh,b),_(i,Do,b),e(Do,Hn),e(Hn,cc),w(as,cc,null),e(Do,ey),e(Do,pc),e(pc,ty),_(i,ah,b),_(i,vt,b),w(ss,vt,null),e(vt,oy),e(vt,So),e(So,ny),e(So,mc),e(mc,ry),e(So,ay),e(So,hc),e(hc,sy),e(So,iy),e(vt,ly),e(vt,is),e(is,dy),e(is,Ol),e(Ol,cy),e(is,py),e(vt,my),e(vt,ls),e(ls,hy),e(ls,ds),e(ds,uy),e(ls,fy),e(vt,gy),e(vt,St),w(cs,St,null),e(St,_y),e(St,Wo),e(Wo,yy),e(Wo,Il),e(Il,by),e(Wo,ky),e(Wo,uc),e(uc,vy),e(Wo,Ty),e(St,wy),w(Kn,St,null),e(St,$y),w(Vn,St,null),_(i,sh,b),_(i,Uo,b),e(Uo,Jn),e(Jn,fc),w(ps,fc,null),e(Uo,Py),e(Uo,gc),e(gc,Fy),_(i,ih,b),_(i,dt,b),w(ms,dt,null),e(dt,Ny),e(dt,_c),e(_c,Ly),e(dt,xy),e(dt,hs),e(hs,My),e(hs,Dl),e(Dl,Ey),e(hs,Ry),e(dt,zy),e(dt,us),e(us,Cy),e(us,fs),e(fs,qy),e(us,jy),e(dt,Ay),w(Gn,dt,null),e(dt,Oy),e(dt,Wt),w(gs,Wt,null),e(Wt,Iy),e(Wt,Bo),e(Bo,Dy),e(Bo,Sl),e(Sl,Sy),e(Bo,Wy),e(Bo,yc),e(yc,Uy),e(Bo,By),e(Wt,Qy),w(Xn,Wt,null),e(Wt,Hy),w(Yn,Wt,null),_(i,lh,b),_(i,Qo,b),e(Qo,Zn),e(Zn,bc),w(_s,bc,null),e(Qo,Ky),e(Qo,kc),e(kc,Vy),_(i,dh,b),_(i,Ho,b),w(ys,Ho,null),e(Ho,Jy),e(Ho,Ut),w(bs,Ut,null),e(Ut,Gy),e(Ut,Ko),e(Ko,Xy),e(Ko,Wl),e(Wl,Yy),e(Ko,Zy),e(Ko,vc),e(vc,eb),e(Ko,tb),e(Ut,ob),w(er,Ut,null),e(Ut,nb),w(tr,Ut,null),_(i,ch,b),_(i,Vo,b),e(Vo,or),e(or,Tc),w(ks,Tc,null),e(Vo,rb),e(Vo,wc),e(wc,ab),_(i,ph,b),_(i,ct,b),w(vs,ct,null),e(ct,sb),e(ct,Ts),e(Ts,ib),e(Ts,$c),e($c,lb),e(Ts,db),e(ct,cb),e(ct,ws),e(ws,pb),e(ws,Ul),e(Ul,mb),e(ws,hb),e(ct,ub),e(ct,$s),e($s,fb),e($s,Ps),e(Ps,gb),e($s,_b),e(ct,yb),w(nr,ct,null),e(ct,bb),e(ct,wt),w(Fs,wt,null),e(wt,kb),e(wt,Jo),e(Jo,vb),e(Jo,Bl),e(Bl,Tb),e(Jo,wb),e(Jo,Pc),e(Pc,$b),e(Jo,Pb),e(wt,Fb),w(rr,wt,null),e(wt,Nb),w(ar,wt,null),e(wt,Lb),w(sr,wt,null),_(i,mh,b),_(i,Go,b),e(Go,ir),e(ir,Fc),w(Ns,Fc,null),e(Go,xb),e(Go,Nc),e(Nc,Mb),_(i,hh,b),_(i,pt,b),w(Ls,pt,null),e(pt,Eb),e(pt,Lc),e(Lc,Rb),e(pt,zb),e(pt,xs),e(xs,Cb),e(xs,Ql),e(Ql,qb),e(xs,jb),e(pt,Ab),e(pt,Ms),e(Ms,Ob),e(Ms,Es),e(Es,Ib),e(Ms,Db),e(pt,Sb),w(lr,pt,null),e(pt,Wb),e(pt,$t),w(Rs,$t,null),e($t,Ub),e($t,Xo),e(Xo,Bb),e(Xo,Hl),e(Hl,Qb),e(Xo,Hb),e(Xo,xc),e(xc,Kb),e(Xo,Vb),e($t,Jb),w(dr,$t,null),e($t,Gb),w(cr,$t,null),e($t,Xb),w(pr,$t,null),_(i,uh,b),_(i,Yo,b),e(Yo,mr),e(mr,Mc),w(zs,Mc,null),e(Yo,Yb),e(Yo,Ec),e(Ec,Zb),_(i,fh,b),_(i,mt,b),w(Cs,mt,null),e(mt,ek),e(mt,Rc),e(Rc,tk),e(mt,ok),e(mt,qs),e(qs,nk),e(qs,Kl),e(Kl,rk),e(qs,ak),e(mt,sk),e(mt,js),e(js,ik),e(js,As),e(As,lk),e(js,dk),e(mt,ck),w(hr,mt,null),e(mt,pk),e(mt,Bt),w(Os,Bt,null),e(Bt,mk),e(Bt,Zo),e(Zo,hk),e(Zo,Vl),e(Vl,uk),e(Zo,fk),e(Zo,zc),e(zc,gk),e(Zo,_k),e(Bt,yk),w(ur,Bt,null),e(Bt,bk),w(fr,Bt,null),_(i,gh,b),_(i,en,b),e(en,gr),e(gr,Cc),w(Is,Cc,null),e(en,kk),e(en,qc),e(qc,vk),_(i,_h,b),_(i,ht,b),w(Ds,ht,null),e(ht,Tk),e(ht,jc),e(jc,wk),e(ht,$k),e(ht,Ss),e(Ss,Pk),e(Ss,Jl),e(Jl,Fk),e(Ss,Nk),e(ht,Lk),e(ht,Ws),e(Ws,xk),e(Ws,Us),e(Us,Mk),e(Ws,Ek),e(ht,Rk),w(_r,ht,null),e(ht,zk),e(ht,Pt),w(Bs,Pt,null),e(Pt,Ck),e(Pt,tn),e(tn,qk),e(tn,Gl),e(Gl,jk),e(tn,Ak),e(tn,Ac),e(Ac,Ok),e(tn,Ik),e(Pt,Dk),w(yr,Pt,null),e(Pt,Sk),w(br,Pt,null),e(Pt,Wk),w(kr,Pt,null),_(i,yh,b),_(i,on,b),e(on,vr),e(vr,Oc),w(Qs,Oc,null),e(on,Uk),e(on,Ic),e(Ic,Bk),_(i,bh,b),_(i,ut,b),w(Hs,ut,null),e(ut,Qk),e(ut,nn),e(nn,Hk),e(nn,Dc),e(Dc,Kk),e(nn,Vk),e(nn,Sc),e(Sc,Jk),e(nn,Gk),e(ut,Xk),e(ut,Ks),e(Ks,Yk),e(Ks,Xl),e(Xl,Zk),e(Ks,ev),e(ut,tv),e(ut,Vs),e(Vs,ov),e(Vs,Js),e(Js,nv),e(Vs,rv),e(ut,av),w(Tr,ut,null),e(ut,sv),e(ut,Ft),w(Gs,Ft,null),e(Ft,iv),e(Ft,rn),e(rn,lv),e(rn,Yl),e(Yl,dv),e(rn,cv),e(rn,Wc),e(Wc,pv),e(rn,mv),e(Ft,hv),w(wr,Ft,null),e(Ft,uv),w($r,Ft,null),e(Ft,fv),w(Pr,Ft,null),_(i,kh,b),_(i,an,b),e(an,Fr),e(Fr,Uc),w(Xs,Uc,null),e(an,gv),e(an,Bc),e(Bc,_v),_(i,vh,b),_(i,et,b),w(Ys,et,null),e(et,yv),e(et,Qc),e(Qc,bv),e(et,kv),e(et,Zs),e(Zs,vv),e(Zs,Zl),e(Zl,Tv),e(Zs,wv),e(et,$v),e(et,ei),e(ei,Pv),e(ei,ti),e(ti,Fv),e(ei,Nv),e(et,Lv),e(et,Hc),e(Hc,xv),e(et,Mv),e(et,ao),e(ao,Kc),e(Kc,oi),e(oi,Ev),e(ao,Rv),e(ao,Vc),e(Vc,ni),e(ni,zv),e(ao,Cv),e(ao,Jc),e(Jc,ri),e(ri,qv),e(ao,jv),e(ao,Gc),e(Gc,ai),e(ai,Av),e(et,Ov),e(et,Qt),w(si,Qt,null),e(Qt,Iv),e(Qt,sn),e(sn,Dv),e(sn,Xc),e(Xc,Sv),e(sn,Wv),e(sn,Yc),e(Yc,Uv),e(sn,Bv),e(Qt,Qv),w(Nr,Qt,null),e(Qt,Hv),w(Lr,Qt,null),_(i,Th,b),_(i,ln,b),e(ln,xr),e(xr,Zc),w(ii,Zc,null),e(ln,Kv),e(ln,ep),e(ep,Vv),_(i,wh,b),_(i,tt,b),w(li,tt,null),e(tt,Jv),e(tt,tp),e(tp,Gv),e(tt,Xv),e(tt,di),e(di,Yv),e(di,ed),e(ed,Zv),e(di,eT),e(tt,tT),e(tt,ci),e(ci,oT),e(ci,pi),e(pi,nT),e(ci,rT),e(tt,aT),e(tt,op),e(op,sT),e(tt,iT),e(tt,so),e(so,np),e(np,mi),e(mi,lT),e(so,dT),e(so,rp),e(rp,hi),e(hi,cT),e(so,pT),e(so,ap),e(ap,ui),e(ui,mT),e(so,hT),e(so,sp),e(sp,fi),e(fi,uT),e(tt,fT),e(tt,Ht),w(gi,Ht,null),e(Ht,gT),e(Ht,dn),e(dn,_T),e(dn,ip),e(ip,yT),e(dn,bT),e(dn,lp),e(lp,kT),e(dn,vT),e(Ht,TT),w(Mr,Ht,null),e(Ht,wT),w(Er,Ht,null),_(i,$h,b),_(i,cn,b),e(cn,Rr),e(Rr,dp),w(_i,dp,null),e(cn,$T),e(cn,cp),e(cp,PT),_(i,Ph,b),_(i,ot,b),w(yi,ot,null),e(ot,FT),e(ot,bi),e(bi,NT),e(bi,pp),e(pp,LT),e(bi,xT),e(ot,MT),e(ot,ki),e(ki,ET),e(ki,td),e(td,RT),e(ki,zT),e(ot,CT),e(ot,vi),e(vi,qT),e(vi,Ti),e(Ti,jT),e(vi,AT),e(ot,OT),e(ot,mp),e(mp,IT),e(ot,DT),e(ot,io),e(io,hp),e(hp,wi),e(wi,ST),e(io,WT),e(io,up),e(up,$i),e($i,UT),e(io,BT),e(io,fp),e(fp,Pi),e(Pi,QT),e(io,HT),e(io,gp),e(gp,Fi),e(Fi,KT),e(ot,VT),e(ot,Kt),w(Ni,Kt,null),e(Kt,JT),e(Kt,pn),e(pn,GT),e(pn,_p),e(_p,XT),e(pn,YT),e(pn,yp),e(yp,ZT),e(pn,ew),e(Kt,tw),w(zr,Kt,null),e(Kt,ow),w(Cr,Kt,null),_(i,Fh,b),_(i,mn,b),e(mn,qr),e(qr,bp),w(Li,bp,null),e(mn,nw),e(mn,kp),e(kp,rw),_(i,Nh,b),_(i,nt,b),w(xi,nt,null),e(nt,aw),e(nt,vp),e(vp,sw),e(nt,iw),e(nt,Mi),e(Mi,lw),e(Mi,od),e(od,dw),e(Mi,cw),e(nt,pw),e(nt,Ei),e(Ei,mw),e(Ei,Ri),e(Ri,hw),e(Ei,uw),e(nt,fw),e(nt,Tp),e(Tp,gw),e(nt,_w),e(nt,lo),e(lo,wp),e(wp,zi),e(zi,yw),e(lo,bw),e(lo,$p),e($p,Ci),e(Ci,kw),e(lo,vw),e(lo,Pp),e(Pp,qi),e(qi,Tw),e(lo,ww),e(lo,Fp),e(Fp,ji),e(ji,$w),e(nt,Pw),e(nt,Vt),w(Ai,Vt,null),e(Vt,Fw),e(Vt,hn),e(hn,Nw),e(hn,Np),e(Np,Lw),e(hn,xw),e(hn,Lp),e(Lp,Mw),e(hn,Ew),e(Vt,Rw),w(jr,Vt,null),e(Vt,zw),w(Ar,Vt,null),_(i,Lh,b),_(i,un,b),e(un,Or),e(Or,xp),w(Oi,xp,null),e(un,Cw),e(un,Mp),e(Mp,qw),_(i,xh,b),_(i,rt,b),w(Ii,rt,null),e(rt,jw),e(rt,Ep),e(Ep,Aw),e(rt,Ow),e(rt,Di),e(Di,Iw),e(Di,nd),e(nd,Dw),e(Di,Sw),e(rt,Ww),e(rt,Si),e(Si,Uw),e(Si,Wi),e(Wi,Bw),e(Si,Qw),e(rt,Hw),e(rt,Rp),e(Rp,Kw),e(rt,Vw),e(rt,co),e(co,zp),e(zp,Ui),e(Ui,Jw),e(co,Gw),e(co,Cp),e(Cp,Bi),e(Bi,Xw),e(co,Yw),e(co,qp),e(qp,Qi),e(Qi,Zw),e(co,e$),e(co,jp),e(jp,Hi),e(Hi,t$),e(rt,o$),e(rt,Jt),w(Ki,Jt,null),e(Jt,n$),e(Jt,fn),e(fn,r$),e(fn,Ap),e(Ap,a$),e(fn,s$),e(fn,Op),e(Op,i$),e(fn,l$),e(Jt,d$),w(Ir,Jt,null),e(Jt,c$),w(Dr,Jt,null),_(i,Mh,b),_(i,gn,b),e(gn,Sr),e(Sr,Ip),w(Vi,Ip,null),e(gn,p$),e(gn,Dp),e(Dp,m$),_(i,Eh,b),_(i,at,b),w(Ji,at,null),e(at,h$),e(at,Sp),e(Sp,u$),e(at,f$),e(at,Gi),e(Gi,g$),e(Gi,rd),e(rd,_$),e(Gi,y$),e(at,b$),e(at,Xi),e(Xi,k$),e(Xi,Yi),e(Yi,v$),e(Xi,T$),e(at,w$),e(at,Wp),e(Wp,$$),e(at,P$),e(at,po),e(po,Up),e(Up,Zi),e(Zi,F$),e(po,N$),e(po,Bp),e(Bp,el),e(el,L$),e(po,x$),e(po,Qp),e(Qp,tl),e(tl,M$),e(po,E$),e(po,Hp),e(Hp,ol),e(ol,R$),e(at,z$),e(at,Gt),w(nl,Gt,null),e(Gt,C$),e(Gt,_n),e(_n,q$),e(_n,Kp),e(Kp,j$),e(_n,A$),e(_n,Vp),e(Vp,O$),e(_n,I$),e(Gt,D$),w(Wr,Gt,null),e(Gt,S$),w(Ur,Gt,null),_(i,Rh,b),_(i,yn,b),e(yn,Br),e(Br,Jp),w(rl,Jp,null),e(yn,W$),e(yn,Gp),e(Gp,U$),_(i,zh,b),_(i,st,b),w(al,st,null),e(st,B$),e(st,bn),e(bn,Q$),e(bn,Xp),e(Xp,H$),e(bn,K$),e(bn,Yp),e(Yp,V$),e(bn,J$),e(st,G$),e(st,sl),e(sl,X$),e(sl,ad),e(ad,Y$),e(sl,Z$),e(st,e1),e(st,il),e(il,t1),e(il,ll),e(ll,o1),e(il,n1),e(st,r1),e(st,Zp),e(Zp,a1),e(st,s1),e(st,mo),e(mo,em),e(em,dl),e(dl,i1),e(mo,l1),e(mo,tm),e(tm,cl),e(cl,d1),e(mo,c1),e(mo,om),e(om,pl),e(pl,p1),e(mo,m1),e(mo,nm),e(nm,ml),e(ml,h1),e(st,u1),e(st,Xt),w(hl,Xt,null),e(Xt,f1),e(Xt,kn),e(kn,g1),e(kn,rm),e(rm,_1),e(kn,y1),e(kn,am),e(am,b1),e(kn,k1),e(Xt,v1),w(Qr,Xt,null),e(Xt,T1),w(Hr,Xt,null),Ch=!0},p(i,[b]){const ul={};b&2&&(ul.$$scope={dirty:b,ctx:i}),Pn.$set(ul);const sm={};b&2&&(sm.$$scope={dirty:b,ctx:i}),Ln.$set(sm);const im={};b&2&&(im.$$scope={dirty:b,ctx:i}),xn.$set(im);const lm={};b&2&&(lm.$$scope={dirty:b,ctx:i}),En.$set(lm);const fl={};b&2&&(fl.$$scope={dirty:b,ctx:i}),Rn.$set(fl);const dm={};b&2&&(dm.$$scope={dirty:b,ctx:i}),Cn.$set(dm);const cm={};b&2&&(cm.$$scope={dirty:b,ctx:i}),qn.$set(cm);const pm={};b&2&&(pm.$$scope={dirty:b,ctx:i}),An.$set(pm);const ho={};b&2&&(ho.$$scope={dirty:b,ctx:i}),On.$set(ho);const mm={};b&2&&(mm.$$scope={dirty:b,ctx:i}),In.$set(mm);const hm={};b&2&&(hm.$$scope={dirty:b,ctx:i}),Sn.$set(hm);const um={};b&2&&(um.$$scope={dirty:b,ctx:i}),Wn.$set(um);const fm={};b&2&&(fm.$$scope={dirty:b,ctx:i}),Bn.$set(fm);const gm={};b&2&&(gm.$$scope={dirty:b,ctx:i}),Qn.$set(gm);const _m={};b&2&&(_m.$$scope={dirty:b,ctx:i}),Kn.$set(_m);const ym={};b&2&&(ym.$$scope={dirty:b,ctx:i}),Vn.$set(ym);const gl={};b&2&&(gl.$$scope={dirty:b,ctx:i}),Gn.$set(gl);const ft={};b&2&&(ft.$$scope={dirty:b,ctx:i}),Xn.$set(ft);const bm={};b&2&&(bm.$$scope={dirty:b,ctx:i}),Yn.$set(bm);const km={};b&2&&(km.$$scope={dirty:b,ctx:i}),er.$set(km);const vm={};b&2&&(vm.$$scope={dirty:b,ctx:i}),tr.$set(vm);const Tm={};b&2&&(Tm.$$scope={dirty:b,ctx:i}),nr.$set(Tm);const wm={};b&2&&(wm.$$scope={dirty:b,ctx:i}),rr.$set(wm);const $m={};b&2&&($m.$$scope={dirty:b,ctx:i}),ar.$set($m);const vn={};b&2&&(vn.$$scope={dirty:b,ctx:i}),sr.$set(vn);const Pm={};b&2&&(Pm.$$scope={dirty:b,ctx:i}),lr.$set(Pm);const Fm={};b&2&&(Fm.$$scope={dirty:b,ctx:i}),dr.$set(Fm);const Tn={};b&2&&(Tn.$$scope={dirty:b,ctx:i}),cr.$set(Tn);const Nm={};b&2&&(Nm.$$scope={dirty:b,ctx:i}),pr.$set(Nm);const Lm={};b&2&&(Lm.$$scope={dirty:b,ctx:i}),hr.$set(Lm);const _l={};b&2&&(_l.$$scope={dirty:b,ctx:i}),ur.$set(_l);const xm={};b&2&&(xm.$$scope={dirty:b,ctx:i}),fr.$set(xm);const Mm={};b&2&&(Mm.$$scope={dirty:b,ctx:i}),_r.$set(Mm);const Em={};b&2&&(Em.$$scope={dirty:b,ctx:i}),yr.$set(Em);const uo={};b&2&&(uo.$$scope={dirty:b,ctx:i}),br.$set(uo);const fo={};b&2&&(fo.$$scope={dirty:b,ctx:i}),kr.$set(fo);const Rm={};b&2&&(Rm.$$scope={dirty:b,ctx:i}),Tr.$set(Rm);const zm={};b&2&&(zm.$$scope={dirty:b,ctx:i}),wr.$set(zm);const Cm={};b&2&&(Cm.$$scope={dirty:b,ctx:i}),$r.$set(Cm);const wn={};b&2&&(wn.$$scope={dirty:b,ctx:i}),Pr.$set(wn);const qm={};b&2&&(qm.$$scope={dirty:b,ctx:i}),Nr.$set(qm);const jm={};b&2&&(jm.$$scope={dirty:b,ctx:i}),Lr.$set(jm);const yl={};b&2&&(yl.$$scope={dirty:b,ctx:i}),Mr.$set(yl);const Am={};b&2&&(Am.$$scope={dirty:b,ctx:i}),Er.$set(Am);const Om={};b&2&&(Om.$$scope={dirty:b,ctx:i}),zr.$set(Om);const Im={};b&2&&(Im.$$scope={dirty:b,ctx:i}),Cr.$set(Im);const it={};b&2&&(it.$$scope={dirty:b,ctx:i}),jr.$set(it);const Dm={};b&2&&(Dm.$$scope={dirty:b,ctx:i}),Ar.$set(Dm);const bl={};b&2&&(bl.$$scope={dirty:b,ctx:i}),Ir.$set(bl);const Sm={};b&2&&(Sm.$$scope={dirty:b,ctx:i}),Dr.$set(Sm);const kl={};b&2&&(kl.$$scope={dirty:b,ctx:i}),Wr.$set(kl);const Wm={};b&2&&(Wm.$$scope={dirty:b,ctx:i}),Ur.$set(Wm);const vl={};b&2&&(vl.$$scope={dirty:b,ctx:i}),Qr.$set(vl);const Um={};b&2&&(Um.$$scope={dirty:b,ctx:i}),Hr.$set(Um)},i(i){Ch||($(l.$$.fragment,i),$(L.$$.fragment,i),$(ga.$$.fragment,i),$(_a.$$.fragment,i),$(Pn.$$.fragment,i),$(ba.$$.fragment,i),$(ka.$$.fragment,i),$(Fa.$$.fragment,i),$(Ln.$$.fragment,i),$(xn.$$.fragment,i),$(Na.$$.fragment,i),$(La.$$.fragment,i),$(za.$$.fragment,i),$(En.$$.fragment,i),$(Rn.$$.fragment,i),$(Ca.$$.fragment,i),$(qa.$$.fragment,i),$(Da.$$.fragment,i),$(Cn.$$.fragment,i),$(qn.$$.fragment,i),$(Sa.$$.fragment,i),$(Wa.$$.fragment,i),$(Ha.$$.fragment,i),$(An.$$.fragment,i),$(On.$$.fragment,i),$(In.$$.fragment,i),$(Ka.$$.fragment,i),$(Va.$$.fragment,i),$(Ya.$$.fragment,i),$(Sn.$$.fragment,i),$(Wn.$$.fragment,i),$(Za.$$.fragment,i),$(es.$$.fragment,i),$(rs.$$.fragment,i),$(Bn.$$.fragment,i),$(Qn.$$.fragment,i),$(as.$$.fragment,i),$(ss.$$.fragment,i),$(cs.$$.fragment,i),$(Kn.$$.fragment,i),$(Vn.$$.fragment,i),$(ps.$$.fragment,i),$(ms.$$.fragment,i),$(Gn.$$.fragment,i),$(gs.$$.fragment,i),$(Xn.$$.fragment,i),$(Yn.$$.fragment,i),$(_s.$$.fragment,i),$(ys.$$.fragment,i),$(bs.$$.fragment,i),$(er.$$.fragment,i),$(tr.$$.fragment,i),$(ks.$$.fragment,i),$(vs.$$.fragment,i),$(nr.$$.fragment,i),$(Fs.$$.fragment,i),$(rr.$$.fragment,i),$(ar.$$.fragment,i),$(sr.$$.fragment,i),$(Ns.$$.fragment,i),$(Ls.$$.fragment,i),$(lr.$$.fragment,i),$(Rs.$$.fragment,i),$(dr.$$.fragment,i),$(cr.$$.fragment,i),$(pr.$$.fragment,i),$(zs.$$.fragment,i),$(Cs.$$.fragment,i),$(hr.$$.fragment,i),$(Os.$$.fragment,i),$(ur.$$.fragment,i),$(fr.$$.fragment,i),$(Is.$$.fragment,i),$(Ds.$$.fragment,i),$(_r.$$.fragment,i),$(Bs.$$.fragment,i),$(yr.$$.fragment,i),$(br.$$.fragment,i),$(kr.$$.fragment,i),$(Qs.$$.fragment,i),$(Hs.$$.fragment,i),$(Tr.$$.fragment,i),$(Gs.$$.fragment,i),$(wr.$$.fragment,i),$($r.$$.fragment,i),$(Pr.$$.fragment,i),$(Xs.$$.fragment,i),$(Ys.$$.fragment,i),$(si.$$.fragment,i),$(Nr.$$.fragment,i),$(Lr.$$.fragment,i),$(ii.$$.fragment,i),$(li.$$.fragment,i),$(gi.$$.fragment,i),$(Mr.$$.fragment,i),$(Er.$$.fragment,i),$(_i.$$.fragment,i),$(yi.$$.fragment,i),$(Ni.$$.fragment,i),$(zr.$$.fragment,i),$(Cr.$$.fragment,i),$(Li.$$.fragment,i),$(xi.$$.fragment,i),$(Ai.$$.fragment,i),$(jr.$$.fragment,i),$(Ar.$$.fragment,i),$(Oi.$$.fragment,i),$(Ii.$$.fragment,i),$(Ki.$$.fragment,i),$(Ir.$$.fragment,i),$(Dr.$$.fragment,i),$(Vi.$$.fragment,i),$(Ji.$$.fragment,i),$(nl.$$.fragment,i),$(Wr.$$.fragment,i),$(Ur.$$.fragment,i),$(rl.$$.fragment,i),$(al.$$.fragment,i),$(hl.$$.fragment,i),$(Qr.$$.fragment,i),$(Hr.$$.fragment,i),Ch=!0)},o(i){P(l.$$.fragment,i),P(L.$$.fragment,i),P(ga.$$.fragment,i),P(_a.$$.fragment,i),P(Pn.$$.fragment,i),P(ba.$$.fragment,i),P(ka.$$.fragment,i),P(Fa.$$.fragment,i),P(Ln.$$.fragment,i),P(xn.$$.fragment,i),P(Na.$$.fragment,i),P(La.$$.fragment,i),P(za.$$.fragment,i),P(En.$$.fragment,i),P(Rn.$$.fragment,i),P(Ca.$$.fragment,i),P(qa.$$.fragment,i),P(Da.$$.fragment,i),P(Cn.$$.fragment,i),P(qn.$$.fragment,i),P(Sa.$$.fragment,i),P(Wa.$$.fragment,i),P(Ha.$$.fragment,i),P(An.$$.fragment,i),P(On.$$.fragment,i),P(In.$$.fragment,i),P(Ka.$$.fragment,i),P(Va.$$.fragment,i),P(Ya.$$.fragment,i),P(Sn.$$.fragment,i),P(Wn.$$.fragment,i),P(Za.$$.fragment,i),P(es.$$.fragment,i),P(rs.$$.fragment,i),P(Bn.$$.fragment,i),P(Qn.$$.fragment,i),P(as.$$.fragment,i),P(ss.$$.fragment,i),P(cs.$$.fragment,i),P(Kn.$$.fragment,i),P(Vn.$$.fragment,i),P(ps.$$.fragment,i),P(ms.$$.fragment,i),P(Gn.$$.fragment,i),P(gs.$$.fragment,i),P(Xn.$$.fragment,i),P(Yn.$$.fragment,i),P(_s.$$.fragment,i),P(ys.$$.fragment,i),P(bs.$$.fragment,i),P(er.$$.fragment,i),P(tr.$$.fragment,i),P(ks.$$.fragment,i),P(vs.$$.fragment,i),P(nr.$$.fragment,i),P(Fs.$$.fragment,i),P(rr.$$.fragment,i),P(ar.$$.fragment,i),P(sr.$$.fragment,i),P(Ns.$$.fragment,i),P(Ls.$$.fragment,i),P(lr.$$.fragment,i),P(Rs.$$.fragment,i),P(dr.$$.fragment,i),P(cr.$$.fragment,i),P(pr.$$.fragment,i),P(zs.$$.fragment,i),P(Cs.$$.fragment,i),P(hr.$$.fragment,i),P(Os.$$.fragment,i),P(ur.$$.fragment,i),P(fr.$$.fragment,i),P(Is.$$.fragment,i),P(Ds.$$.fragment,i),P(_r.$$.fragment,i),P(Bs.$$.fragment,i),P(yr.$$.fragment,i),P(br.$$.fragment,i),P(kr.$$.fragment,i),P(Qs.$$.fragment,i),P(Hs.$$.fragment,i),P(Tr.$$.fragment,i),P(Gs.$$.fragment,i),P(wr.$$.fragment,i),P($r.$$.fragment,i),P(Pr.$$.fragment,i),P(Xs.$$.fragment,i),P(Ys.$$.fragment,i),P(si.$$.fragment,i),P(Nr.$$.fragment,i),P(Lr.$$.fragment,i),P(ii.$$.fragment,i),P(li.$$.fragment,i),P(gi.$$.fragment,i),P(Mr.$$.fragment,i),P(Er.$$.fragment,i),P(_i.$$.fragment,i),P(yi.$$.fragment,i),P(Ni.$$.fragment,i),P(zr.$$.fragment,i),P(Cr.$$.fragment,i),P(Li.$$.fragment,i),P(xi.$$.fragment,i),P(Ai.$$.fragment,i),P(jr.$$.fragment,i),P(Ar.$$.fragment,i),P(Oi.$$.fragment,i),P(Ii.$$.fragment,i),P(Ki.$$.fragment,i),P(Ir.$$.fragment,i),P(Dr.$$.fragment,i),P(Vi.$$.fragment,i),P(Ji.$$.fragment,i),P(nl.$$.fragment,i),P(Wr.$$.fragment,i),P(Ur.$$.fragment,i),P(rl.$$.fragment,i),P(al.$$.fragment,i),P(hl.$$.fragment,i),P(Qr.$$.fragment,i),P(Hr.$$.fragment,i),Ch=!1},d(i){t(d),i&&t(y),i&&t(h),F(l),i&&t(he),i&&t(D),F(L),i&&t(ue),i&&t(A),i&&t(fe),i&&t(ee),i&&t(C),i&&t(le),i&&t(ge),i&&t(U),i&&t(_e),i&&t(z),i&&t(O),i&&t(I),i&&t(ne),i&&t(qe),F(ga),i&&t(Qm),i&&t(qt),F(_a),F(Pn),i&&t(Hm),i&&t(Lo),F(ba),i&&t(Km),i&&t(Ze),F(ka),F(Fa),F(Ln),F(xn),i&&t(Vm),i&&t(Mo),F(Na),i&&t(Jm),i&&t(gt),F(La),F(za),F(En),F(Rn),i&&t(Gm),i&&t(Ro),F(Ca),i&&t(Xm),i&&t(_t),F(qa),F(Da),F(Cn),F(qn),i&&t(Ym),i&&t(Co),F(Sa),i&&t(Zm),i&&t(yt),F(Wa),F(Ha),F(An),F(On),F(In),i&&t(eh),i&&t(jo),F(Ka),i&&t(th),i&&t(bt),F(Va),F(Ya),F(Sn),F(Wn),i&&t(oh),i&&t(Oo),F(Za),i&&t(nh),i&&t(kt),F(es),F(rs),F(Bn),F(Qn),i&&t(rh),i&&t(Do),F(as),i&&t(ah),i&&t(vt),F(ss),F(cs),F(Kn),F(Vn),i&&t(sh),i&&t(Uo),F(ps),i&&t(ih),i&&t(dt),F(ms),F(Gn),F(gs),F(Xn),F(Yn),i&&t(lh),i&&t(Qo),F(_s),i&&t(dh),i&&t(Ho),F(ys),F(bs),F(er),F(tr),i&&t(ch),i&&t(Vo),F(ks),i&&t(ph),i&&t(ct),F(vs),F(nr),F(Fs),F(rr),F(ar),F(sr),i&&t(mh),i&&t(Go),F(Ns),i&&t(hh),i&&t(pt),F(Ls),F(lr),F(Rs),F(dr),F(cr),F(pr),i&&t(uh),i&&t(Yo),F(zs),i&&t(fh),i&&t(mt),F(Cs),F(hr),F(Os),F(ur),F(fr),i&&t(gh),i&&t(en),F(Is),i&&t(_h),i&&t(ht),F(Ds),F(_r),F(Bs),F(yr),F(br),F(kr),i&&t(yh),i&&t(on),F(Qs),i&&t(bh),i&&t(ut),F(Hs),F(Tr),F(Gs),F(wr),F($r),F(Pr),i&&t(kh),i&&t(an),F(Xs),i&&t(vh),i&&t(et),F(Ys),F(si),F(Nr),F(Lr),i&&t(Th),i&&t(ln),F(ii),i&&t(wh),i&&t(tt),F(li),F(gi),F(Mr),F(Er),i&&t($h),i&&t(cn),F(_i),i&&t(Ph),i&&t(ot),F(yi),F(Ni),F(zr),F(Cr),i&&t(Fh),i&&t(mn),F(Li),i&&t(Nh),i&&t(nt),F(xi),F(Ai),F(jr),F(Ar),i&&t(Lh),i&&t(un),F(Oi),i&&t(xh),i&&t(rt),F(Ii),F(Ki),F(Ir),F(Dr),i&&t(Mh),i&&t(gn),F(Vi),i&&t(Eh),i&&t(at),F(Ji),F(nl),F(Wr),F(Ur),i&&t(Rh),i&&t(yn),F(rl),i&&t(zh),i&&t(st),F(al),F(hl),F(Qr),F(Hr)}}}const HN={local:"robertaprelayernorm",sections:[{local:"overview",title:"Overview"},{local:"transformers.RobertaPreLayerNormConfig",title:"RobertaPreLayerNormConfig"},{local:"transformers.RobertaPreLayerNormModel",title:"RobertaPreLayerNormModel"},{local:"transformers.RobertaPreLayerNormForCausalLM",title:"RobertaPreLayerNormForCausalLM"},{local:"transformers.RobertaPreLayerNormForMaskedLM",title:"RobertaPreLayerNormForMaskedLM"},{local:"transformers.RobertaPreLayerNormForSequenceClassification",title:"RobertaPreLayerNormForSequenceClassification"},{local:"transformers.RobertaPreLayerNormForMultipleChoice",title:"RobertaPreLayerNormForMultipleChoice"},{local:"transformers.RobertaPreLayerNormForTokenClassification",title:"RobertaPreLayerNormForTokenClassification"},{local:"transformers.RobertaPreLayerNormForQuestionAnswering",title:"RobertaPreLayerNormForQuestionAnswering"},{local:"transformers.TFRobertaPreLayerNormModel",title:"TFRobertaPreLayerNormModel"},{local:"transformers.TFRobertaPreLayerNormForCausalLM",title:"TFRobertaPreLayerNormForCausalLM"},{local:"transformers.TFRobertaPreLayerNormForMaskedLM",title:"TFRobertaPreLayerNormForMaskedLM"},{local:"transformers.TFRobertaPreLayerNormForSequenceClassification",title:"TFRobertaPreLayerNormForSequenceClassification"},{local:"transformers.TFRobertaPreLayerNormForMultipleChoice",title:"TFRobertaPreLayerNormForMultipleChoice"},{local:"transformers.TFRobertaPreLayerNormForTokenClassification",title:"TFRobertaPreLayerNormForTokenClassification"},{local:"transformers.TFRobertaPreLayerNormForQuestionAnswering",title:"TFRobertaPreLayerNormForQuestionAnswering"},{local:"transformers.FlaxRobertaPreLayerNormModel",title:"FlaxRobertaPreLayerNormModel"},{local:"transformers.FlaxRobertaPreLayerNormForCausalLM",title:"FlaxRobertaPreLayerNormForCausalLM"},{local:"transformers.FlaxRobertaPreLayerNormForMaskedLM",title:"FlaxRobertaPreLayerNormForMaskedLM"},{local:"transformers.FlaxRobertaPreLayerNormForSequenceClassification",title:"FlaxRobertaPreLayerNormForSequenceClassification"},{local:"transformers.FlaxRobertaPreLayerNormForMultipleChoice",title:"FlaxRobertaPreLayerNormForMultipleChoice"},{local:"transformers.FlaxRobertaPreLayerNormForTokenClassification",title:"FlaxRobertaPreLayerNormForTokenClassification"},{local:"transformers.FlaxRobertaPreLayerNormForQuestionAnswering",title:"FlaxRobertaPreLayerNormForQuestionAnswering"}],title:"RoBERTa-PreLayerNorm"};function KN(N){return B2(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class eL extends D2{constructor(d){super();S2(this,d,KN,QN,W2,{})}}export{eL as default,HN as metadata};
