import{S as dm,i as im,s as cm,e as n,k as i,w as v,t as s,M as pm,c as a,d as o,m as c,a as r,x as T,h as l,b as u,G as e,g as _,y as w,q as S,o as $,B as x,v as um,L as mo}from"../../chunks/vendor-hf-doc-builder.js";import{T as Rn}from"../../chunks/Tip-hf-doc-builder.js";import{D as O}from"../../chunks/Docstring-hf-doc-builder.js";import{C as fo}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ee}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as ho}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";function hm(z){let p,k,f,m,b;return m=new fo({props:{code:`from transformers import BlenderbotSmallConfig, BlenderbotSmallModel

# Initializing a BlenderbotSmall facebook/blenderbot_small-90M style configuration
configuration = BlenderbotSmallConfig()

# Initializing a model (with random weights) from the facebook/blenderbot_small-90M style configuration
model = BlenderbotSmallModel(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> BlenderbotSmallConfig, BlenderbotSmallModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a BlenderbotSmall facebook/blenderbot_small-90M style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = BlenderbotSmallConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the facebook/blenderbot_small-90M style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = BlenderbotSmallModel(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(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function mm(z){let p,k,f,m,b;return{c(){p=n("p"),k=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=s("Module"),b=s(`
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(d){p=a(d,"P",{});var h=r(p);k=l(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(h,"CODE",{});var q=r(f);m=l(q,"Module"),q.forEach(o),b=l(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(o)},m(d,h){_(d,p,h),e(p,k),e(p,f),e(f,m),e(p,b)},d(d){d&&o(p)}}}function fm(z){let p,k,f,m,b;return m=new fo({props:{code:`from transformers import BlenderbotSmallTokenizer, BlenderbotSmallModel

model = BlenderbotSmallModel.from_pretrained("facebook/blenderbot_small-90M")
tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")

inputs = tokenizer("Studies have been shown that owning a dog is good for you", return_tensors="pt")
decoder_inputs = tokenizer("Studies show that", return_tensors="pt")  # Batch size 1
outputs = model(input_ids=inputs.input_ids, decoder_input_ids=decoder_inputs.input_ids)

last_hidden_states = outputs.last_hidden_state
list(last_hidden_states.shape)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> BlenderbotSmallTokenizer, BlenderbotSmallModel

<span class="hljs-meta">&gt;&gt;&gt; </span>model = BlenderbotSmallModel.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Studies have been shown that owning a dog is good for you&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>decoder_inputs = tokenizer(<span class="hljs-string">&quot;Studies show that&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)  <span class="hljs-comment"># Batch size 1</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(input_ids=inputs.input_ids, decoder_input_ids=decoder_inputs.input_ids)

<span class="hljs-meta">&gt;&gt;&gt; </span>last_hidden_states = outputs.last_hidden_state
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">list</span>(last_hidden_states.shape)
[<span class="hljs-number">1</span>, <span class="hljs-number">3</span>, <span class="hljs-number">512</span>]`}}),{c(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function _m(z){let p,k,f,m,b;return{c(){p=n("p"),k=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=s("Module"),b=s(`
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(d){p=a(d,"P",{});var h=r(p);k=l(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(h,"CODE",{});var q=r(f);m=l(q,"Module"),q.forEach(o),b=l(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(o)},m(d,h){_(d,p,h),e(p,k),e(p,f),e(f,m),e(p,b)},d(d){d&&o(p)}}}function gm(z){let p,k,f,m,b;return m=new fo({props:{code:`from transformers import BlenderbotSmallTokenizer, BlenderbotSmallForConditionalGeneration

mname = "facebook/blenderbot_small-90M"
model = BlenderbotSmallForConditionalGeneration.from_pretrained(mname)
tokenizer = BlenderbotSmallTokenizer.from_pretrained(mname)
UTTERANCE = "My friends are cool but they eat too many carbs."
print("Human: ", UTTERANCE)

inputs = tokenizer([UTTERANCE], return_tensors="pt")
reply_ids = model.generate(**inputs)
print("Bot: ", tokenizer.batch_decode(reply_ids, skip_special_tokens=True)[0])

REPLY = "I'm not sure"
print("Human: ", REPLY)

NEXT_UTTERANCE = (
    "My friends are cool but they eat too many carbs.</s> <s>what kind of carbs do they eat? "
    "i don't know much about carbs</s> "
    "<s> I'm not sure."
)
inputs = tokenizer([NEXT_UTTERANCE], return_tensors="pt")
next_reply_ids = model.generate(**inputs)
print("Bot: ", tokenizer.batch_decode(next_reply_ids, skip_special_tokens=True)[0])`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> BlenderbotSmallTokenizer, BlenderbotSmallForConditionalGeneration

<span class="hljs-meta">&gt;&gt;&gt; </span>mname = <span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = BlenderbotSmallForConditionalGeneration.from_pretrained(mname)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(mname)
<span class="hljs-meta">&gt;&gt;&gt; </span>UTTERANCE = <span class="hljs-string">&quot;My friends are cool but they eat too many carbs.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">print</span>(<span class="hljs-string">&quot;Human: &quot;</span>, UTTERANCE)
Human:  My friends are cool but they eat too many carbs.

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer([UTTERANCE], return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>reply_ids = model.generate(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">print</span>(<span class="hljs-string">&quot;Bot: &quot;</span>, tokenizer.batch_decode(reply_ids, skip_special_tokens=<span class="hljs-literal">True</span>)[<span class="hljs-number">0</span>])
Bot:  what kind of carbs do they eat? i don<span class="hljs-string">&#x27;t know much about carbs.

&gt;&gt;&gt; REPLY = &quot;I&#x27;</span>m <span class="hljs-keyword">not</span> sure<span class="hljs-string">&quot;
&gt;&gt;&gt; print(&quot;</span>Human: <span class="hljs-string">&quot;, REPLY)
Human: I&#x27;m not sure

&gt;&gt;&gt; NEXT_UTTERANCE = (
...     &quot;</span>My friends are cool but they eat too many carbs.&lt;/s&gt; &lt;s&gt;what kind of carbs do they eat? <span class="hljs-string">&quot;
...     &quot;</span>i don<span class="hljs-string">&#x27;t know much about carbs&lt;/s&gt; &quot;
...     &quot;&lt;s&gt; I&#x27;</span>m <span class="hljs-keyword">not</span> sure.<span class="hljs-string">&quot;
... )
&gt;&gt;&gt; inputs = tokenizer([NEXT_UTTERANCE], return_tensors=&quot;</span>pt<span class="hljs-string">&quot;)
&gt;&gt;&gt; next_reply_ids = model.generate(**inputs)
&gt;&gt;&gt; print(&quot;</span>Bot: <span class="hljs-string">&quot;, tokenizer.batch_decode(next_reply_ids, skip_special_tokens=True)[0])
Bot:  they eat a lot of carbs. carbs are high in fat, protein, and carbohydrates.</span>`}}),{c(){p=n("p"),k=s("Conversation example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Conversation example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function bm(z){let p,k,f,m,b;return m=new fo({props:{code:`from transformers import BlenderbotSmallTokenizer, BlenderbotSmallForCausalLM

tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")
model = BlenderbotSmallForCausalLM.from_pretrained(
    "facebook/blenderbot_small-90M", add_cross_attention=False
)
assert model.config.is_decoder, f"{model.__class__} has to be configured as a decoder."
inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
outputs = model(**inputs)

logits = outputs.logits
expected_shape = [1, inputs.input_ids.shape[-1], model.config.vocab_size]
list(logits.shape) == expected_shape`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> BlenderbotSmallTokenizer, BlenderbotSmallForCausalLM

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = BlenderbotSmallForCausalLM.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>, add_cross_attention=<span class="hljs-literal">False</span>
<span class="hljs-meta">... </span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">assert</span> model.config.is_decoder, <span class="hljs-string">f&quot;<span class="hljs-subst">{model.__class__}</span> has to be configured as a decoder.&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>logits = outputs.logits
<span class="hljs-meta">&gt;&gt;&gt; </span>expected_shape = [<span class="hljs-number">1</span>, inputs.input_ids.shape[-<span class="hljs-number">1</span>], model.config.vocab_size]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">list</span>(logits.shape) == expected_shape
<span class="hljs-literal">True</span>`}}),{c(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function km(z){let p,k,f,m,b,d,h,q,Ae,Me,C,De,se,B,Ge,Y,Ue,We,K,Re,Ke,Z,He,Qe,ee,Ve,Ce,G,le,we,te,P,I,Je,de,ie,Xe,H,Ye,Ze,A,ke,he,je,ye,ne,eo,Oe,N,oo,Q,to,Se,L,no,V,Pe,ae;return{c(){p=n("p"),k=s("TensorFlow models and layers in "),f=n("code"),m=s("transformers"),b=s(" accept two formats as input:"),d=i(),h=n("ul"),q=n("li"),Ae=s("having all inputs as keyword arguments (like PyTorch models), or"),Me=i(),C=n("li"),De=s("having all inputs as a list, tuple or dict in the first positional argument."),se=i(),B=n("p"),Ge=s(`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 `),Y=n("code"),Ue=s("model.fit()"),We=s(` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),K=n("code"),Re=s("model.fit()"),Ke=s(` supports! If, however, you want to use the second
format outside of Keras methods like `),Z=n("code"),He=s("fit()"),Qe=s(" and "),ee=n("code"),Ve=s("predict()"),Ce=s(`, such as when creating your own layers or models with
the Keras `),G=n("code"),le=s("Functional"),we=s(` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),te=i(),P=n("ul"),I=n("li"),Je=s("a single Tensor with "),de=n("code"),ie=s("input_ids"),Xe=s(" only and nothing else: "),H=n("code"),Ye=s("model(input_ids)"),Ze=i(),A=n("li"),ke=s(`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),he=n("code"),je=s("model([input_ids, attention_mask])"),ye=s(" or "),ne=n("code"),eo=s("model([input_ids, attention_mask, token_type_ids])"),Oe=i(),N=n("li"),oo=s(`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),Q=n("code"),to=s('model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),Se=i(),L=n("p"),no=s(`Note that when creating models and layers with
`),V=n("a"),Pe=s("subclassing"),ae=s(` then you don\u2019t need to worry
about any of this, as you can just pass inputs like you would to any other Python function!`),this.h()},l(y){p=a(y,"P",{});var F=r(p);k=l(F,"TensorFlow models and layers in "),f=a(F,"CODE",{});var $e=r(f);m=l($e,"transformers"),$e.forEach(o),b=l(F," accept two formats as input:"),F.forEach(o),d=c(y),h=a(y,"UL",{});var xe=r(h);q=a(xe,"LI",{});var ao=r(q);Ae=l(ao,"having all inputs as keyword arguments (like PyTorch models), or"),ao.forEach(o),Me=c(xe),C=a(xe,"LI",{});var _o=r(C);De=l(_o,"having all inputs as a list, tuple or dict in the first positional argument."),_o.forEach(o),xe.forEach(o),se=c(y),B=a(y,"P",{});var E=r(B);Ge=l(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 `),Y=a(E,"CODE",{});var J=r(Y);Ue=l(J,"model.fit()"),J.forEach(o),We=l(E,` things should \u201Cjust work\u201D for you - just
pass your inputs and labels in any format that `),K=a(E,"CODE",{});var Be=r(K);Re=l(Be,"model.fit()"),Be.forEach(o),Ke=l(E,` supports! If, however, you want to use the second
format outside of Keras methods like `),Z=a(E,"CODE",{});var go=r(Z);He=l(go,"fit()"),go.forEach(o),Qe=l(E," and "),ee=a(E,"CODE",{});var me=r(ee);Ve=l(me,"predict()"),me.forEach(o),Ce=l(E,`, such as when creating your own layers or models with
the Keras `),G=a(E,"CODE",{});var bo=r(G);le=l(bo,"Functional"),bo.forEach(o),we=l(E,` API, there are three possibilities you can use to gather all the input Tensors in the first
positional argument:`),E.forEach(o),te=c(y),P=a(y,"UL",{});var R=r(P);I=a(R,"LI",{});var fe=r(I);Je=l(fe,"a single Tensor with "),de=a(fe,"CODE",{});var ko=r(de);ie=l(ko,"input_ids"),ko.forEach(o),Xe=l(fe," only and nothing else: "),H=a(fe,"CODE",{});var ze=r(H);Ye=l(ze,"model(input_ids)"),ze.forEach(o),fe.forEach(o),Ze=c(R),A=a(R,"LI",{});var _e=r(A);ke=l(_e,`a list of varying length with one or several input Tensors IN THE ORDER given in the docstring:
`),he=a(_e,"CODE",{});var yo=r(he);je=l(yo,"model([input_ids, attention_mask])"),yo.forEach(o),ye=l(_e," or "),ne=a(_e,"CODE",{});var vo=r(ne);eo=l(vo,"model([input_ids, attention_mask, token_type_ids])"),vo.forEach(o),_e.forEach(o),Oe=c(R),N=a(R,"LI",{});var re=r(N);oo=l(re,`a dictionary with one or several input Tensors associated to the input names given in the docstring:
`),Q=a(re,"CODE",{});var To=r(Q);to=l(To,'model({"input_ids": input_ids, "token_type_ids": token_type_ids})'),To.forEach(o),re.forEach(o),R.forEach(o),Se=c(y),L=a(y,"P",{});var ce=r(L);no=l(ce,`Note that when creating models and layers with
`),V=a(ce,"A",{href:!0,rel:!0});var wo=r(V);Pe=l(wo,"subclassing"),wo.forEach(o),ae=l(ce,` 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!`),ce.forEach(o),this.h()},h(){u(V,"href","https://keras.io/guides/making_new_layers_and_models_via_subclassing/"),u(V,"rel","nofollow")},m(y,F){_(y,p,F),e(p,k),e(p,f),e(f,m),e(p,b),_(y,d,F),_(y,h,F),e(h,q),e(q,Ae),e(h,Me),e(h,C),e(C,De),_(y,se,F),_(y,B,F),e(B,Ge),e(B,Y),e(Y,Ue),e(B,We),e(B,K),e(K,Re),e(B,Ke),e(B,Z),e(Z,He),e(B,Qe),e(B,ee),e(ee,Ve),e(B,Ce),e(B,G),e(G,le),e(B,we),_(y,te,F),_(y,P,F),e(P,I),e(I,Je),e(I,de),e(de,ie),e(I,Xe),e(I,H),e(H,Ye),e(P,Ze),e(P,A),e(A,ke),e(A,he),e(he,je),e(A,ye),e(A,ne),e(ne,eo),e(P,Oe),e(P,N),e(N,oo),e(N,Q),e(Q,to),_(y,Se,F),_(y,L,F),e(L,no),e(L,V),e(V,Pe),e(L,ae)},d(y){y&&o(p),y&&o(d),y&&o(h),y&&o(se),y&&o(B),y&&o(te),y&&o(P),y&&o(Se),y&&o(L)}}}function ym(z){let p,k,f,m,b;return{c(){p=n("p"),k=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=s("Module"),b=s(`
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(d){p=a(d,"P",{});var h=r(p);k=l(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(h,"CODE",{});var q=r(f);m=l(q,"Module"),q.forEach(o),b=l(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(o)},m(d,h){_(d,p,h),e(p,k),e(p,f),e(f,m),e(p,b)},d(d){d&&o(p)}}}function vm(z){let p,k,f,m,b;return m=new fo({props:{code:`from transformers import BlenderbotSmallTokenizer, TFBlenderbotSmallModel
import tensorflow as tf

tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")
model = TFBlenderbotSmallModel.from_pretrained("facebook/blenderbot_small-90M")

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

tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")
model = FlaxBlenderbotSmallModel.from_pretrained("facebook/blenderbot_small-90M")

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> BlenderbotSmallTokenizer, FlaxBlenderbotSmallModel

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxBlenderbotSmallModel.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&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(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function $m(z){let p,k,f,m,b;return m=new fo({props:{code:`from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained("facebook/blenderbot_small-90M")
tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")

text = "My friends are cool but they eat too many carbs."
inputs = tokenizer(text, max_length=1024, return_tensors="np")
encoder_outputs = model.encode(**inputs)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>text = <span class="hljs-string">&quot;My friends are cool but they eat too many carbs.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(text, max_length=<span class="hljs-number">1024</span>, return_tensors=<span class="hljs-string">&quot;np&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>encoder_outputs = model.encode(**inputs)`}}),{c(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function xm(z){let p,k,f,m,b;return m=new fo({props:{code:`import jax.numpy as jnp
from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained("facebook/blenderbot_small-90M")
tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")

text = "My friends are cool but they eat too many carbs."
inputs = tokenizer(text, max_length=1024, return_tensors="np")
encoder_outputs = model.encode(**inputs)

decoder_start_token_id = model.config.decoder_start_token_id
decoder_input_ids = jnp.ones((inputs.input_ids.shape[0], 1), dtype="i4") * decoder_start_token_id

outputs = model.decode(decoder_input_ids, encoder_outputs)
last_decoder_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> jax.numpy <span class="hljs-keyword">as</span> jnp
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>text = <span class="hljs-string">&quot;My friends are cool but they eat too many carbs.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(text, max_length=<span class="hljs-number">1024</span>, return_tensors=<span class="hljs-string">&quot;np&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>encoder_outputs = model.encode(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>decoder_start_token_id = model.config.decoder_start_token_id
<span class="hljs-meta">&gt;&gt;&gt; </span>decoder_input_ids = jnp.ones((inputs.input_ids.shape[<span class="hljs-number">0</span>], <span class="hljs-number">1</span>), dtype=<span class="hljs-string">&quot;i4&quot;</span>) * decoder_start_token_id

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model.decode(decoder_input_ids, encoder_outputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>last_decoder_hidden_states = outputs.last_hidden_state`}}),{c(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function Bm(z){let p,k,f,m,b;return{c(){p=n("p"),k=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),f=n("code"),m=s("Module"),b=s(`
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(d){p=a(d,"P",{});var h=r(p);k=l(h,"Although the recipe for forward pass needs to be defined within this function, one should call the "),f=a(h,"CODE",{});var q=r(f);m=l(q,"Module"),q.forEach(o),b=l(h,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),h.forEach(o)},m(d,h){_(d,p,h),e(p,k),e(p,f),e(f,m),e(p,b)},d(d){d&&o(p)}}}function zm(z){let p,k,f,m,b;return m=new fo({props:{code:`from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained("facebook/blenderbot_small-90M")
tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")

text = "My friends are cool but they eat too many carbs."
inputs = tokenizer(text, max_length=1024, return_tensors="np")
encoder_outputs = model.encode(**inputs)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>text = <span class="hljs-string">&quot;My friends are cool but they eat too many carbs.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(text, max_length=<span class="hljs-number">1024</span>, return_tensors=<span class="hljs-string">&quot;np&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>encoder_outputs = model.encode(**inputs)`}}),{c(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function Fm(z){let p,k,f,m,b;return m=new fo({props:{code:`import jax.numpy as jnp
from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained("facebook/blenderbot_small-90M")
tokenizer = BlenderbotSmallTokenizer.from_pretrained("facebook/blenderbot_small-90M")

text = "My friends are cool but they eat too many carbs."
inputs = tokenizer(text, max_length=1024, return_tensors="np")
encoder_outputs = model.encode(**inputs)

decoder_start_token_id = model.config.decoder_start_token_id
decoder_input_ids = jnp.ones((inputs.input_ids.shape[0], 1), dtype="i4") * decoder_start_token_id

outputs = model.decode(decoder_input_ids, encoder_outputs)
logits = outputs.logits`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> jax.numpy <span class="hljs-keyword">as</span> jnp
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration

<span class="hljs-meta">&gt;&gt;&gt; </span>model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = BlenderbotSmallTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/blenderbot_small-90M&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>text = <span class="hljs-string">&quot;My friends are cool but they eat too many carbs.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(text, max_length=<span class="hljs-number">1024</span>, return_tensors=<span class="hljs-string">&quot;np&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>encoder_outputs = model.encode(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>decoder_start_token_id = model.config.decoder_start_token_id
<span class="hljs-meta">&gt;&gt;&gt; </span>decoder_input_ids = jnp.ones((inputs.input_ids.shape[<span class="hljs-number">0</span>], <span class="hljs-number">1</span>), dtype=<span class="hljs-string">&quot;i4&quot;</span>) * decoder_start_token_id

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model.decode(decoder_input_ids, encoder_outputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits`}}),{c(){p=n("p"),k=s("Example:"),f=i(),v(m.$$.fragment)},l(d){p=a(d,"P",{});var h=r(p);k=l(h,"Example:"),h.forEach(o),f=c(d),T(m.$$.fragment,d)},m(d,h){_(d,p,h),e(p,k),_(d,f,h),w(m,d,h),b=!0},p:mo,i(d){b||(S(m.$$.fragment,d),b=!0)},o(d){$(m.$$.fragment,d),b=!1},d(d){d&&o(p),d&&o(f),x(m,d)}}}function qm(z){let p,k,f,m,b,d,h,q,Ae,Me,C,De,se,B,Ge,Y,Ue,We,K,Re,Ke,Z,He,Qe,ee,Ve,Ce,G,le,we,te,P,I,Je,de,ie,Xe,H,Ye,Ze,A,ke,he,je,ye,ne,eo,Oe,N,oo,Q,to,Se,L,no,V,Pe,ae,y,F,$e,xe,ao,_o,E,J,Be,go,me,bo,R,fe,ko,ze,_e,yo,vo,re,To,ce,wo,wl,Kn,Sl,$l,xl,Ao,Ts,So,Do,ka,qt,Bl,ya,zl,ws,X,Et,Fl,va,ql,El,Mt,Ml,Hn,Cl,jl,Ol,io,Ct,Pl,Ta,Ll,Nl,wa,Il,Al,Go,jt,Dl,$o,Gl,Sa,Ul,Wl,$a,Rl,Kl,Hl,co,Ot,Ql,Qn,Vl,Vn,Jl,Xl,xa,Yl,Zl,Jn,Pt,Ss,xo,Uo,Ba,Lt,ed,za,od,$s,ro,Nt,td,It,nd,Fa,ad,rd,sd,Wo,At,ld,qa,dd,xs,Bo,Ro,Ea,Dt,id,Ma,cd,Bs,Fe,Gt,pd,Ut,ud,Xn,hd,md,fd,Wt,_d,Rt,gd,bd,kd,Le,Kt,yd,zo,vd,Yn,Td,wd,Ca,Sd,$d,xd,Ko,Bd,Ho,zs,Fo,Qo,ja,Ht,zd,Oa,Fd,Fs,qe,Qt,qd,Vt,Ed,Zn,Md,Cd,jd,Jt,Od,Xt,Pd,Ld,Nd,Ne,Yt,Id,qo,Ad,ea,Dd,Gd,Pa,Ud,Wd,Rd,Vo,Kd,Jo,qs,Eo,Xo,La,Zt,Hd,Na,Qd,Es,Mo,en,Vd,Yo,on,Jd,Zo,Ms,Co,et,Ia,tn,Xd,Aa,Yd,Cs,ge,nn,Zd,an,ei,oa,oi,ti,ni,rn,ai,sn,ri,si,li,ot,di,Ie,ln,ii,jo,ci,ta,pi,ui,Da,hi,mi,fi,tt,_i,nt,js,Oo,at,Ga,dn,gi,Ua,bi,Os,be,cn,ki,pn,yi,na,vi,Ti,wi,un,Si,hn,$i,xi,Bi,rt,zi,D,mn,Fi,Po,qi,aa,Ei,Mi,Wa,Ci,ji,Oi,st,Pi,Ra,Li,Ni,Ka,Ha,Qa,Va,Ii,Ai,Ja,Xa,Ya,Za,Di,Gi,er,or,tr,nr,Ui,Wi,ar,rr,sr,fn,Ri,lr,Ki,Hi,Qi,dr,ir,cr,pr,Vi,Ps,Lo,lt,ur,_n,Ji,hr,Xi,Ls,U,gn,Yi,bn,Zi,ra,ec,oc,tc,kn,nc,yn,ac,rc,sc,mr,lc,dc,so,fr,vn,ic,cc,_r,Tn,pc,uc,gr,wn,hc,mc,br,Sn,fc,_c,dt,$n,gc,it,bc,ct,xn,kc,pt,yc,ut,Bn,vc,ht,Ns,No,mt,kr,zn,Tc,yr,wc,Is,W,Fn,Sc,qn,$c,sa,xc,Bc,zc,En,Fc,Mn,qc,Ec,Mc,vr,Cc,jc,lo,Tr,Cn,Oc,Pc,wr,jn,Lc,Nc,Sr,On,Ic,Ac,$r,Pn,Dc,Gc,M,Ln,Uc,Io,Wc,xr,Rc,Kc,Br,Hc,Qc,Vc,ft,Jc,zr,Xc,Yc,Fr,qr,Er,Mr,Zc,ep,Cr,jr,Or,Pr,op,tp,Lr,Nr,Ir,Ar,np,ap,Dr,Gr,Nn,_t,gt,Ur,In,rp,Wr,sp,lp,Rr,dp,ip,Kr,cp,pp,Hr,Qr,Vr,Jr,up,hp,Xr,Yr,Zr,es,mp,fp,os,ts,ns,as,_p,gp,rs,ss,ls,ds,bp,kp,bt,An,yp,kt,vp,yt,Dn,Tp,vt,As;return d=new Ee({}),te=new Ee({}),$e=new Ee({}),Be=new O({props:{name:"class transformers.BlenderbotSmallConfig",anchor:"transformers.BlenderbotSmallConfig",parameters:[{name:"vocab_size",val:" = 50265"},{name:"max_position_embeddings",val:" = 512"},{name:"encoder_layers",val:" = 8"},{name:"encoder_ffn_dim",val:" = 2048"},{name:"encoder_attention_heads",val:" = 16"},{name:"decoder_layers",val:" = 8"},{name:"decoder_ffn_dim",val:" = 2048"},{name:"decoder_attention_heads",val:" = 16"},{name:"encoder_layerdrop",val:" = 0.0"},{name:"decoder_layerdrop",val:" = 0.0"},{name:"use_cache",val:" = True"},{name:"is_encoder_decoder",val:" = True"},{name:"activation_function",val:" = 'gelu'"},{name:"d_model",val:" = 512"},{name:"dropout",val:" = 0.1"},{name:"attention_dropout",val:" = 0.0"},{name:"activation_dropout",val:" = 0.0"},{name:"init_std",val:" = 0.02"},{name:"decoder_start_token_id",val:" = 1"},{name:"classifier_dropout",val:" = 0.0"},{name:"scale_embedding",val:" = False"},{name:"pad_token_id",val:" = 0"},{name:"bos_token_id",val:" = 1"},{name:"eos_token_id",val:" = 2"},{name:"forced_eos_token_id",val:" = 2"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.BlenderbotSmallConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 50265) &#x2014;
Vocabulary size of the BlenderbotSmall model. Defines the number of different tokens that can be
represented by the <code>inputs_ids</code> passed when calling <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallModel">BlenderbotSmallModel</a> or <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.TFBlenderbotSmallModel">TFBlenderbotSmallModel</a>.`,name:"vocab_size"},{anchor:"transformers.BlenderbotSmallConfig.d_model",description:`<strong>d_model</strong> (<code>int</code>, <em>optional</em>, defaults to 512) &#x2014;
Dimensionality of the layers and the pooler layer.`,name:"d_model"},{anchor:"transformers.BlenderbotSmallConfig.encoder_layers",description:`<strong>encoder_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 8) &#x2014;
Number of encoder layers.`,name:"encoder_layers"},{anchor:"transformers.BlenderbotSmallConfig.decoder_layers",description:`<strong>decoder_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 8) &#x2014;
Number of decoder layers.`,name:"decoder_layers"},{anchor:"transformers.BlenderbotSmallConfig.encoder_attention_heads",description:`<strong>encoder_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 16) &#x2014;
Number of attention heads for each attention layer in the Transformer encoder.`,name:"encoder_attention_heads"},{anchor:"transformers.BlenderbotSmallConfig.decoder_attention_heads",description:`<strong>decoder_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 16) &#x2014;
Number of attention heads for each attention layer in the Transformer decoder.`,name:"decoder_attention_heads"},{anchor:"transformers.BlenderbotSmallConfig.decoder_ffn_dim",description:`<strong>decoder_ffn_dim</strong> (<code>int</code>, <em>optional</em>, defaults to 2048) &#x2014;
Dimensionality of the &#x201C;intermediate&#x201D; (often named feed-forward) layer in decoder.`,name:"decoder_ffn_dim"},{anchor:"transformers.BlenderbotSmallConfig.encoder_ffn_dim",description:`<strong>encoder_ffn_dim</strong> (<code>int</code>, <em>optional</em>, defaults to 2048) &#x2014;
Dimensionality of the &#x201C;intermediate&#x201D; (often named feed-forward) layer in decoder.`,name:"encoder_ffn_dim"},{anchor:"transformers.BlenderbotSmallConfig.activation_function",description:`<strong>activation_function</strong> (<code>str</code> or <code>function</code>, <em>optional</em>, defaults to <code>&quot;gelu&quot;</code>) &#x2014;
The non-linear activation function (function or string) in the encoder and pooler. If string, <code>&quot;gelu&quot;</code>,
<code>&quot;relu&quot;</code>, <code>&quot;silu&quot;</code> and <code>&quot;gelu_new&quot;</code> are supported.`,name:"activation_function"},{anchor:"transformers.BlenderbotSmallConfig.dropout",description:`<strong>dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout probability for all fully connected layers in the embeddings, encoder, and pooler.`,name:"dropout"},{anchor:"transformers.BlenderbotSmallConfig.attention_dropout",description:`<strong>attention_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_dropout"},{anchor:"transformers.BlenderbotSmallConfig.activation_dropout",description:`<strong>activation_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The dropout ratio for activations inside the fully connected layer.`,name:"activation_dropout"},{anchor:"transformers.BlenderbotSmallConfig.classifier_dropout",description:`<strong>classifier_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The dropout ratio for classifier.`,name:"classifier_dropout"},{anchor:"transformers.BlenderbotSmallConfig.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.BlenderbotSmallConfig.init_std",description:`<strong>init_std</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:"init_std"},{anchor:"transformers.BlenderbotSmallConfig.encoder_layerdrop",description:`<strong>encoder_layerdrop</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The LayerDrop probability for the encoder. See the [LayerDrop paper](see <a href="https://arxiv.org/abs/1909.11556" rel="nofollow">https://arxiv.org/abs/1909.11556</a>)
for more details.`,name:"encoder_layerdrop"},{anchor:"transformers.BlenderbotSmallConfig.decoder_layerdrop",description:`<strong>decoder_layerdrop</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The LayerDrop probability for the decoder. See the [LayerDrop paper](see <a href="https://arxiv.org/abs/1909.11556" rel="nofollow">https://arxiv.org/abs/1909.11556</a>)
for more details.`,name:"decoder_layerdrop"},{anchor:"transformers.BlenderbotSmallConfig.scale_embedding",description:`<strong>scale_embedding</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Scale embeddings by diving by sqrt(d_model).`,name:"scale_embedding"},{anchor:"transformers.BlenderbotSmallConfig.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)`,name:"use_cache"},{anchor:"transformers.BlenderbotSmallConfig.forced_eos_token_id",description:`<strong>forced_eos_token_id</strong> (<code>int</code>, <em>optional</em>, defaults to 2) &#x2014;
The id of the token to force as the last generated token when <code>max_length</code> is reached. Usually set to
<code>eos_token_id</code>.`,name:"forced_eos_token_id"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/configuration_blenderbot_small.py#L36"}}),Ao=new ho({props:{anchor:"transformers.BlenderbotSmallConfig.example",$$slots:{default:[hm]},$$scope:{ctx:z}}}),qt=new Ee({}),Et=new O({props:{name:"class transformers.BlenderbotSmallTokenizer",anchor:"transformers.BlenderbotSmallTokenizer",parameters:[{name:"vocab_file",val:""},{name:"merges_file",val:""},{name:"bos_token",val:" = '__start__'"},{name:"eos_token",val:" = '__end__'"},{name:"unk_token",val:" = '__unk__'"},{name:"pad_token",val:" = '__null__'"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.BlenderbotSmallTokenizer.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
File containing the vocabulary.`,name:"vocab_file"},{anchor:"transformers.BlenderbotSmallTokenizer.merges_file",description:`<strong>merges_file</strong> (<code>str</code>) &#x2014;
Path to the merges file.`,name:"merges_file"},{anchor:"transformers.BlenderbotSmallTokenizer.bos_token",description:`<strong>bos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;__start__&quot;</code>) &#x2014;
The beginning of sentence token.`,name:"bos_token"},{anchor:"transformers.BlenderbotSmallTokenizer.eos_token",description:`<strong>eos_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;__end__&quot;</code>) &#x2014;
The end of sentence token.`,name:"eos_token"},{anchor:"transformers.BlenderbotSmallTokenizer.unk_token",description:`<strong>unk_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;__unk__&quot;</code>) &#x2014;
The unknown token. A token that is not in the vocabulary cannot be converted to an ID and is set to be this
token instead.`,name:"unk_token"},{anchor:"transformers.BlenderbotSmallTokenizer.pad_token",description:`<strong>pad_token</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;__pad__&quot;</code>) &#x2014;
The token used for padding, for example when batching sequences of different lengths.
**kwargs &#x2014;
Additional keyword arguments passed along to <a href="/docs/transformers/pr_19907/en/main_classes/tokenizer#transformers.PreTrainedTokenizer">PreTrainedTokenizer</a>`,name:"pad_token"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/tokenization_blenderbot_small.py#L69"}}),Ct=new O({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.BlenderbotSmallTokenizer.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.BlenderbotSmallTokenizer.build_inputs_with_special_tokens.token_ids_0",description:"<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014; The first tokenized sequence.",name:"token_ids_0"},{anchor:"transformers.BlenderbotSmallTokenizer.build_inputs_with_special_tokens.token_ids_1",description:"<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014; The second tokenized sequence.",name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/tokenization_utils_base.py#L3007",returnDescription:`
<p>The model input with special tokens.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),jt=new O({props:{name:"get_special_tokens_mask",anchor:"transformers.BlenderbotSmallTokenizer.get_special_tokens_mask",parameters:[{name:"token_ids_0",val:": typing.List"},{name:"token_ids_1",val:": typing.Optional[typing.List] = None"},{name:"already_has_special_tokens",val:": bool = False"}],parametersDescription:[{anchor:"transformers.BlenderbotSmallTokenizer.get_special_tokens_mask.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of ids of the first sequence.`,name:"token_ids_0"},{anchor:"transformers.BlenderbotSmallTokenizer.get_special_tokens_mask.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
List of ids of the second sequence.`,name:"token_ids_1"},{anchor:"transformers.BlenderbotSmallTokenizer.get_special_tokens_mask.already_has_special_tokens",description:`<strong>already_has_special_tokens</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the token list is already formatted with special tokens for the model.`,name:"already_has_special_tokens"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/tokenization_utils.py#L845",returnDescription:`
<p>1 for a special token, 0 for a sequence token.</p>
`,returnType:`
<p>A list of integers in the range [0, 1]</p>
`}}),Ot=new O({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.BlenderbotSmallTokenizer.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.BlenderbotSmallTokenizer.create_token_type_ids_from_sequences.token_ids_0",description:"<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014; The first tokenized sequence.",name:"token_ids_0"},{anchor:"transformers.BlenderbotSmallTokenizer.create_token_type_ids_from_sequences.token_ids_1",description:"<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014; The second tokenized sequence.",name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/tokenization_utils_base.py#L2987",returnDescription:`
<p>The token type ids.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),Pt=new O({props:{name:"save_vocabulary",anchor:"transformers.BlenderbotSmallTokenizer.save_vocabulary",parameters:[{name:"save_directory",val:": str"},{name:"filename_prefix",val:": typing.Optional[str] = None"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/tokenization_blenderbot_small.py#L211"}}),Lt=new Ee({}),Nt=new O({props:{name:"class transformers.BlenderbotSmallTokenizerFast",anchor:"transformers.BlenderbotSmallTokenizerFast",parameters:[{name:"vocab_file",val:" = None"},{name:"merges_file",val:" = None"},{name:"unk_token",val:" = '<|endoftext|>'"},{name:"bos_token",val:" = '<|endoftext|>'"},{name:"eos_token",val:" = '<|endoftext|>'"},{name:"add_prefix_space",val:" = False"},{name:"trim_offsets",val:" = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.BlenderbotSmallTokenizerFast.vocab_file",description:`<strong>vocab_file</strong> (<code>str</code>) &#x2014;
Path to the vocabulary file.`,name:"vocab_file"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/tokenization_blenderbot_small_fast.py#L52"}}),At=new O({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.BlenderbotSmallTokenizerFast.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.BlenderbotSmallTokenizerFast.create_token_type_ids_from_sequences.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.BlenderbotSmallTokenizerFast.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/tokenization_blenderbot_small_fast.py#L98",returnDescription:`
<p>List of zeros.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),Dt=new Ee({}),Gt=new O({props:{name:"class transformers.BlenderbotSmallModel",anchor:"transformers.BlenderbotSmallModel",parameters:[{name:"config",val:": BlenderbotSmallConfig"}],parametersDescription:[{anchor:"transformers.BlenderbotSmallModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig">BlenderbotSmallConfig</a>) &#x2014;
Model configuration class with all the parameters of the model. Initializing with a config file does not
load the weights associated with the model, only the configuration. Check out the
<a href="/docs/transformers/pr_19907/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/vr_19907/src/transformers/models/blenderbot_small/modeling_blenderbot_small.py#L1083"}}),Kt=new O({props:{name:"forward",anchor:"transformers.BlenderbotSmallModel.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"decoder_input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"decoder_attention_mask",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"decoder_head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"cross_attn_head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"encoder_outputs",val:": typing.Union[typing.Tuple, transformers.modeling_outputs.BaseModelOutput, NoneType] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[torch.FloatTensor]] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"decoder_inputs_embeds",val:": typing.Optional[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.BlenderbotSmallModel.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. Padding will be ignored by default should you provide
it.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.BlenderbotSmallModel.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.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.BlenderbotSmallModel.forward.decoder_input_ids",description:`<strong>decoder_input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of decoder input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#decoder-input-ids">What are decoder input IDs?</a></p>
<p>BlenderbotSmall uses the <code>bos_token_id</code> as the starting token for <code>decoder_input_ids</code> generation. If
<code>past_key_values</code> is used, optionally only the last <code>decoder_input_ids</code> have to be input (see
<code>past_key_values</code>).`,name:"decoder_input_ids"},{anchor:"transformers.BlenderbotSmallModel.forward.decoder_attention_mask",description:`<strong>decoder_attention_mask</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Default behavior: generate a tensor that ignores pad tokens in <code>decoder_input_ids</code>. Causal mask will also
be used by default.`,name:"decoder_attention_mask"},{anchor:"transformers.BlenderbotSmallModel.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.Tensor</code> of shape <code>(encoder_layers, encoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the encoder. 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.BlenderbotSmallModel.forward.decoder_head_mask",description:`<strong>decoder_head_mask</strong> (<code>torch.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the decoder. 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:"decoder_head_mask"},{anchor:"transformers.BlenderbotSmallModel.forward.cross_attn_head_mask",description:`<strong>cross_attn_head_mask</strong> (<code>torch.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the cross-attention modules in the decoder. 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:"cross_attn_head_mask"},{anchor:"transformers.BlenderbotSmallModel.forward.encoder_outputs",description:`<strong>encoder_outputs</strong> (<code>tuple(tuple(torch.FloatTensor)</code>, <em>optional</em>) &#x2014;
Tuple consists of (<code>last_hidden_state</code>, <em>optional</em>: <code>hidden_states</code>, <em>optional</em>: <code>attentions</code>)
<code>last_hidden_state</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) is a sequence of
hidden-states at the output of the last layer of the encoder. Used in the cross-attention of the decoder.`,name:"encoder_outputs"},{anchor:"transformers.BlenderbotSmallModel.forward.past_key_values",description:`<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>) &#x2014;
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 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 in the cross-attention
blocks) that can be used (see <code>past_key_values</code> input) to speed up sequential 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>. inputs_embeds (<code>torch.FloatTensor</code> of shape
<code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>): 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:"past_key_values"},{anchor:"transformers.BlenderbotSmallModel.forward.decoder_inputs_embeds",description:`<strong>decoder_inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, target_sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>decoder_input_ids</code> you can choose to directly pass an embedded
representation. If <code>past_key_values</code> is used, optionally only the last <code>decoder_inputs_embeds</code> have to be
input (see <code>past_key_values</code>). This is useful if you want more control over how to convert
<code>decoder_input_ids</code> indices into associated vectors than the model&#x2019;s internal embedding lookup matrix.</p>
<p>If <code>decoder_input_ids</code> and <code>decoder_inputs_embeds</code> are both unset, <code>decoder_inputs_embeds</code> takes the value
of <code>inputs_embeds</code>.`,name:"decoder_inputs_embeds"},{anchor:"transformers.BlenderbotSmallModel.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"},{anchor:"transformers.BlenderbotSmallModel.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.BlenderbotSmallModel.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.BlenderbotSmallModel.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_blenderbot_small.py#L1110",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_outputs.Seq2SeqModelOutput"
>transformers.modeling_outputs.Seq2SeqModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig"
>BlenderbotSmallConfig</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 decoder of the model.</p>
<p>If <code>past_key_values</code> is used only the last hidden-state of the sequences of shape <code>(batch_size, 1, hidden_size)</code> is output.</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 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 in the cross-attention
blocks) that can be used (see <code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
<li>
<p><strong>decoder_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 decoder at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>decoder_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 of the decoder, 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>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>encoder_last_hidden_state</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) \u2014 Sequence of hidden-states at the output of the last layer of the encoder of the model.</p>
</li>
<li>
<p><strong>encoder_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 encoder at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>encoder_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 of the encoder, after the attention softmax, used to compute the weighted average in the
self-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_outputs.Seq2SeqModelOutput"
>transformers.modeling_outputs.Seq2SeqModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ko=new Rn({props:{$$slots:{default:[mm]},$$scope:{ctx:z}}}),Ho=new ho({props:{anchor:"transformers.BlenderbotSmallModel.forward.example",$$slots:{default:[fm]},$$scope:{ctx:z}}}),Ht=new Ee({}),Qt=new O({props:{name:"class transformers.BlenderbotSmallForConditionalGeneration",anchor:"transformers.BlenderbotSmallForConditionalGeneration",parameters:[{name:"config",val:": BlenderbotSmallConfig"}],parametersDescription:[{anchor:"transformers.BlenderbotSmallForConditionalGeneration.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig">BlenderbotSmallConfig</a>) &#x2014;
Model configuration class with all the parameters of the model. Initializing with a config file does not
load the weights associated with the model, only the configuration. Check out the
<a href="/docs/transformers/pr_19907/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/vr_19907/src/transformers/models/blenderbot_small/modeling_blenderbot_small.py#L1209"}}),Yt=new O({props:{name:"forward",anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"decoder_input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"decoder_attention_mask",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"decoder_head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"cross_attn_head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"encoder_outputs",val:": typing.Union[typing.Tuple, transformers.modeling_outputs.BaseModelOutput, NoneType] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[torch.FloatTensor]] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"decoder_inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = 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.BlenderbotSmallForConditionalGeneration.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. Padding will be ignored by default should you provide
it.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.BlenderbotSmallForConditionalGeneration.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.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.BlenderbotSmallForConditionalGeneration.forward.decoder_input_ids",description:`<strong>decoder_input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of decoder input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#decoder-input-ids">What are decoder input IDs?</a></p>
<p>BlenderbotSmall uses the <code>bos_token_id</code> as the starting token for <code>decoder_input_ids</code> generation. If
<code>past_key_values</code> is used, optionally only the last <code>decoder_input_ids</code> have to be input (see
<code>past_key_values</code>).`,name:"decoder_input_ids"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward.decoder_attention_mask",description:`<strong>decoder_attention_mask</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Default behavior: generate a tensor that ignores pad tokens in <code>decoder_input_ids</code>. Causal mask will also
be used by default.`,name:"decoder_attention_mask"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.Tensor</code> of shape <code>(encoder_layers, encoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the encoder. 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.BlenderbotSmallForConditionalGeneration.forward.decoder_head_mask",description:`<strong>decoder_head_mask</strong> (<code>torch.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the decoder. 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:"decoder_head_mask"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward.cross_attn_head_mask",description:`<strong>cross_attn_head_mask</strong> (<code>torch.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the cross-attention modules in the decoder. 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:"cross_attn_head_mask"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward.encoder_outputs",description:`<strong>encoder_outputs</strong> (<code>tuple(tuple(torch.FloatTensor)</code>, <em>optional</em>) &#x2014;
Tuple consists of (<code>last_hidden_state</code>, <em>optional</em>: <code>hidden_states</code>, <em>optional</em>: <code>attentions</code>)
<code>last_hidden_state</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) is a sequence of
hidden-states at the output of the last layer of the encoder. Used in the cross-attention of the decoder.`,name:"encoder_outputs"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward.past_key_values",description:`<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>) &#x2014;
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 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 in the cross-attention
blocks) that can be used (see <code>past_key_values</code> input) to speed up sequential 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>. inputs_embeds (<code>torch.FloatTensor</code> of shape
<code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>): 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:"past_key_values"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward.decoder_inputs_embeds",description:`<strong>decoder_inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, target_sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>decoder_input_ids</code> you can choose to directly pass an embedded
representation. If <code>past_key_values</code> is used, optionally only the last <code>decoder_inputs_embeds</code> have to be
input (see <code>past_key_values</code>). This is useful if you want more control over how to convert
<code>decoder_input_ids</code> indices into associated vectors than the model&#x2019;s internal embedding lookup matrix.</p>
<p>If <code>decoder_input_ids</code> and <code>decoder_inputs_embeds</code> are both unset, <code>decoder_inputs_embeds</code> takes the value
of <code>inputs_embeds</code>.`,name:"decoder_inputs_embeds"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.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"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.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.BlenderbotSmallForConditionalGeneration.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.BlenderbotSmallForConditionalGeneration.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.BlenderbotSmallForConditionalGeneration.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 either be in <code>[0, ..., config.vocab_size]</code> or -100 (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/vr_19907/src/transformers/models/blenderbot_small/modeling_blenderbot_small.py#L1253",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_outputs.Seq2SeqLMOutput"
>transformers.modeling_outputs.Seq2SeqLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig"
>BlenderbotSmallConfig</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.</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>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 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 in the cross-attention
blocks) that can be used (see <code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
<li>
<p><strong>decoder_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 decoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>decoder_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 of the decoder, 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>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>encoder_last_hidden_state</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) \u2014 Sequence of hidden-states at the output of the last layer of the encoder of the model.</p>
</li>
<li>
<p><strong>encoder_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 encoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>encoder_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 of the encoder, after the attention softmax, used to compute the weighted average in the
self-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_outputs.Seq2SeqLMOutput"
>transformers.modeling_outputs.Seq2SeqLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Vo=new Rn({props:{$$slots:{default:[_m]},$$scope:{ctx:z}}}),Jo=new ho({props:{anchor:"transformers.BlenderbotSmallForConditionalGeneration.forward.example",$$slots:{default:[gm]},$$scope:{ctx:z}}}),Zt=new Ee({}),en=new O({props:{name:"class transformers.BlenderbotSmallForCausalLM",anchor:"transformers.BlenderbotSmallForCausalLM",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_blenderbot_small.py#L1389"}}),on=new O({props:{name:"forward",anchor:"transformers.BlenderbotSmallForCausalLM.forward",parameters:[{name:"input_ids",val:": LongTensor = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"encoder_hidden_states",val:": typing.Optional[torch.FloatTensor] = None"},{name:"encoder_attention_mask",val:": typing.Optional[torch.FloatTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"cross_attn_head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[torch.FloatTensor]] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = 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.BlenderbotSmallForCausalLM.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. Padding will be ignored by default should you
provide it.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.BlenderbotSmallForCausalLM.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.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.BlenderbotSmallForCausalLM.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.BlenderbotSmallForCausalLM.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>:`,name:"encoder_attention_mask"},{anchor:"transformers.BlenderbotSmallForCausalLM.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the 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.BlenderbotSmallForCausalLM.forward.cross_attn_head_mask",description:`<strong>cross_attn_head_mask</strong> (<code>torch.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the cross-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:"cross_attn_head_mask"},{anchor:"transformers.BlenderbotSmallForCausalLM.forward.past_key_values",description:`<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>) &#x2014;
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 2 additional tensors of
shape <code>(batch_size, num_heads, encoder_sequence_length, embed_size_per_head)</code>. The two additional
tensors are only required when the model is used as a decoder in a Sequence to Sequence model.</p>
<p>Contains pre-computed hidden-states (key and values in the self-attention blocks and in the
cross-attention blocks) that can be used (see <code>past_key_values</code> input) to speed up sequential 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.BlenderbotSmallForCausalLM.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 either be in <code>[0, ..., config.vocab_size]</code> or -100 (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.BlenderbotSmallForCausalLM.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>).</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:"use_cache"},{anchor:"transformers.BlenderbotSmallForCausalLM.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.BlenderbotSmallForCausalLM.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.BlenderbotSmallForCausalLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_blenderbot_small.py#L1420",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/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/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig"
>BlenderbotSmallConfig</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/pr_19907/en/main_classes/output#transformers.modeling_outputs.CausalLMOutputWithCrossAttentions"
>transformers.modeling_outputs.CausalLMOutputWithCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Zo=new ho({props:{anchor:"transformers.BlenderbotSmallForCausalLM.forward.example",$$slots:{default:[bm]},$$scope:{ctx:z}}}),tn=new Ee({}),nn=new O({props:{name:"class transformers.TFBlenderbotSmallModel",anchor:"transformers.TFBlenderbotSmallModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFBlenderbotSmallModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig">BlenderbotSmallConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_tf_blenderbot_small.py#L1167"}}),ot=new Rn({props:{$$slots:{default:[km]},$$scope:{ctx:z}}}),ln=new O({props:{name:"call",anchor:"transformers.TFBlenderbotSmallModel.call",parameters:[{name:"input_ids",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_input_ids",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_attention_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_position_ids",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"head_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_head_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"cross_attn_head_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"encoder_outputs",val:": typing.Union[typing.Tuple, transformers.modeling_tf_outputs.TFBaseModelOutput, NoneType] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[tensorflow.python.framework.ops.Tensor]] = None"},{name:"inputs_embeds",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_inputs_embeds",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = 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"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFBlenderbotSmallModel.call.input_ids",description:`<strong>input_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.TFBlenderbotSmallModel.call.attention_mask",description:`<strong>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 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.TFBlenderbotSmallModel.call.decoder_input_ids",description:`<strong>decoder_input_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of decoder input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#decoder-input-ids">What are decoder input IDs?</a></p>
<p>BlenderbotSmall uses the <code>bos_token_id</code> as the starting token for <code>decoder_input_ids</code> generation. If
<code>past_key_values</code> is used, optionally only the last <code>decoder_input_ids</code> have to be input (see
<code>past_key_values</code>).`,name:"decoder_input_ids"},{anchor:"transformers.TFBlenderbotSmallModel.call.decoder_attention_mask",description:`<strong>decoder_attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
will be made by default and ignore pad tokens. It is not recommended to set this for most use cases.`,name:"decoder_attention_mask"},{anchor:"transformers.TFBlenderbotSmallModel.call.decoder_position_ids",description:`<strong>decoder_position_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each decoder input sequence tokens in the position embeddings. Selected in the
range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"decoder_position_ids"},{anchor:"transformers.TFBlenderbotSmallModel.call.head_mask",description:`<strong>head_mask</strong> (<code>tf.Tensor</code> of shape <code>(encoder_layers, encoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the encoder. 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.TFBlenderbotSmallModel.call.decoder_head_mask",description:`<strong>decoder_head_mask</strong> (<code>tf.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the decoder. 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:"decoder_head_mask"},{anchor:"transformers.TFBlenderbotSmallModel.call.cross_attn_head_mask",description:`<strong>cross_attn_head_mask</strong> (<code>tf.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the cross-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:"cross_attn_head_mask"},{anchor:"transformers.TFBlenderbotSmallModel.call.encoder_outputs",description:`<strong>encoder_outputs</strong> (<code>tf.FloatTensor</code>, <em>optional</em>) &#x2014;
hidden states at the output of the last layer of the encoder. Used in the cross-attention of the decoder.
of shape <code>(batch_size, sequence_length, hidden_size)</code> is a sequence of`,name:"encoder_outputs"},{anchor:"transformers.TFBlenderbotSmallModel.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.TFBlenderbotSmallModel.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.TFBlenderbotSmallModel.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.TFBlenderbotSmallModel.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.TFBlenderbotSmallModel.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/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.TFBlenderbotSmallModel.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_tf_blenderbot_small.py#L1179",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_tf_outputs.TFSeq2SeqModelOutput"
>transformers.modeling_tf_outputs.TFSeq2SeqModelOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig"
>BlenderbotSmallConfig</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 decoder of the model.</p>
<p>If <code>past_key_values</code> is used only the last hidden-state of the sequences of shape <code>(batch_size, 1, hidden_size)</code> is output.</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) of the decoder that can be
used (see <code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
<li>
<p><strong>decoder_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 decoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>decoder_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, 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>encoder_last_hidden_state</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) \u2014 Sequence of hidden-states at the output of the last layer of the encoder of the model.</p>
</li>
<li>
<p><strong>encoder_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 encoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>encoder_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 encoder, after the attention softmax, used to compute the weighted average in the
self-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_tf_outputs.TFSeq2SeqModelOutput"
>transformers.modeling_tf_outputs.TFSeq2SeqModelOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),tt=new Rn({props:{$$slots:{default:[ym]},$$scope:{ctx:z}}}),nt=new ho({props:{anchor:"transformers.TFBlenderbotSmallModel.call.example",$$slots:{default:[vm]},$$scope:{ctx:z}}}),dn=new Ee({}),cn=new O({props:{name:"class transformers.TFBlenderbotSmallForConditionalGeneration",anchor:"transformers.TFBlenderbotSmallForConditionalGeneration",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig">BlenderbotSmallConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_tf_blenderbot_small.py#L1274"}}),rt=new Rn({props:{$$slots:{default:[Tm]},$$scope:{ctx:z}}}),mn=new O({props:{name:"call",anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call",parameters:[{name:"input_ids",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_input_ids",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_attention_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_position_ids",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"head_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_head_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"cross_attn_head_mask",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"encoder_outputs",val:": typing.Optional[transformers.modeling_tf_outputs.TFBaseModelOutput] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[tensorflow.python.framework.ops.Tensor]] = None"},{name:"inputs_embeds",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"decoder_inputs_embeds",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = 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.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call.input_ids",description:`<strong>input_ids</strong> (<code>tf.Tensor</code> of shape <code>({0})</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.TFBlenderbotSmallForConditionalGeneration.call.attention_mask",description:`<strong>attention_mask</strong> (<code>tf.Tensor</code> of shape <code>({0})</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call.decoder_input_ids",description:`<strong>decoder_input_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of decoder input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#decoder-input-ids">What are decoder input IDs?</a></p>
<p>BlenderbotSmall uses the <code>bos_token_id</code> as the starting token for <code>decoder_input_ids</code> generation. If
<code>past_key_values</code> is used, optionally only the last <code>decoder_input_ids</code> have to be input (see
<code>past_key_values</code>).`,name:"decoder_input_ids"},{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call.decoder_attention_mask",description:`<strong>decoder_attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
will be made by default and ignore pad tokens. It is not recommended to set this for most use cases.`,name:"decoder_attention_mask"},{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call.decoder_position_ids",description:`<strong>decoder_position_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each decoder input sequence tokens in the position embeddings. Selected in the
range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"decoder_position_ids"},{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call.head_mask",description:`<strong>head_mask</strong> (<code>tf.Tensor</code> of shape <code>(encoder_layers, encoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the encoder. 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.TFBlenderbotSmallForConditionalGeneration.call.decoder_head_mask",description:`<strong>decoder_head_mask</strong> (<code>tf.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the attention modules in the decoder. 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:"decoder_head_mask"},{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call.cross_attn_head_mask",description:`<strong>cross_attn_head_mask</strong> (<code>tf.Tensor</code> of shape <code>(decoder_layers, decoder_attention_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the cross-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:"cross_attn_head_mask"},{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.call.encoder_outputs",description:`<strong>encoder_outputs</strong> (<code>tf.FloatTensor</code>, <em>optional</em>) &#x2014;
hidden states at the output of the last layer of the encoder. Used in the cross-attention of the decoder.
of shape <code>(batch_size, sequence_length, hidden_size)</code> is a sequence of`,name:"encoder_outputs"},{anchor:"transformers.TFBlenderbotSmallForConditionalGeneration.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.TFBlenderbotSmallForConditionalGeneration.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.TFBlenderbotSmallForConditionalGeneration.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.TFBlenderbotSmallForConditionalGeneration.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.TFBlenderbotSmallForConditionalGeneration.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/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.TFBlenderbotSmallForConditionalGeneration.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.TFBlenderbotSmallForConditionalGeneration.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 either be in <code>[0, ..., config.vocab_size]</code> or -100 (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/vr_19907/src/transformers/models/blenderbot_small/modeling_tf_blenderbot_small.py#L1312",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_tf_outputs.TFSeq2SeqLMOutput"
>transformers.modeling_tf_outputs.TFSeq2SeqLMOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig"
>BlenderbotSmallConfig</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.</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>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) of the decoder that can be
used (see <code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
<li>
<p><strong>decoder_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 decoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>decoder_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, 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>encoder_last_hidden_state</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) \u2014 Sequence of hidden-states at the output of the last layer of the encoder of the model.</p>
</li>
<li>
<p><strong>encoder_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 encoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>encoder_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 encoder, after the attention softmax, used to compute the weighted average in the
self-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_tf_outputs.TFSeq2SeqLMOutput"
>transformers.modeling_tf_outputs.TFSeq2SeqLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),st=new Rn({props:{$$slots:{default:[wm]},$$scope:{ctx:z}}}),_n=new Ee({}),gn=new O({props:{name:"class transformers.FlaxBlenderbotSmallModel",anchor:"transformers.FlaxBlenderbotSmallModel",parameters:[{name:"config",val:": BlenderbotSmallConfig"},{name:"input_shape",val:": typing.Tuple[int] = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxBlenderbotSmallModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig">BlenderbotSmallConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxBlenderbotSmallModel.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L1215"}}),$n=new O({props:{name:"__call__",anchor:"transformers.FlaxBlenderbotSmallModel.__call__",parameters:[{name:"input_ids",val:": ndarray"},{name:"attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_input_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = 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:"train",val:": bool = False"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L1151",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSeq2SeqModelOutput"
>transformers.modeling_flax_outputs.FlaxSeq2SeqModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig"
>BlenderbotSmallConfig</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 decoder of the model.</p>
<p>If <code>past_key_values</code> is used only the last hidden-state of the sequences of shape <code>(batch_size, 1, hidden_size)</code> is output.</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>tuple(jnp.ndarray)</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 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 in the cross-attention
blocks) that can be used (see <code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
<li>
<p><strong>decoder_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 decoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>decoder_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 of the decoder, 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>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>encoder_last_hidden_state</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) \u2014 Sequence of hidden-states at the output of the last layer of the encoder of the model.</p>
</li>
<li>
<p><strong>encoder_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 encoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>encoder_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 of the encoder, after the attention softmax, used to compute the weighted average in the
self-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSeq2SeqModelOutput"
>transformers.modeling_flax_outputs.FlaxSeq2SeqModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),it=new ho({props:{anchor:"transformers.FlaxBlenderbotSmallModel.__call__.example",$$slots:{default:[Sm]},$$scope:{ctx:z}}}),xn=new O({props:{name:"encode",anchor:"transformers.FlaxBlenderbotSmallModel.encode",parameters:[{name:"input_ids",val:": ndarray"},{name:"attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = 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:"train",val:": bool = False"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"}],parametersDescription:[{anchor:"transformers.FlaxBlenderbotSmallModel.encode.input_ids",description:`<strong>input_ids</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary. Padding will be ignored by default should you provide
it.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.FlaxBlenderbotSmallModel.encode.attention_mask",description:`<strong>attention_mask</strong> (<code>jnp.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.FlaxBlenderbotSmallModel.encode.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.FlaxBlenderbotSmallModel.encode.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.FlaxBlenderbotSmallModel.encode.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.FlaxBlenderbotSmallModel.encode.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L972",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutput"
>transformers.modeling_flax_outputs.FlaxBaseModelOutput</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 (<code>&lt;class 'transformers.models.blenderbot_small.configuration_blenderbot_small.BlenderbotSmallConfig'&gt;</code>) 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>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutput"
>transformers.modeling_flax_outputs.FlaxBaseModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),pt=new ho({props:{anchor:"transformers.FlaxBlenderbotSmallModel.encode.example",$$slots:{default:[$m]},$$scope:{ctx:z}}}),Bn=new O({props:{name:"decode",anchor:"transformers.FlaxBlenderbotSmallModel.decode",parameters:[{name:"decoder_input_ids",val:""},{name:"encoder_outputs",val:""},{name:"encoder_attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"past_key_values",val:": dict = 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:"train",val:": bool = False"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"}],parametersDescription:[{anchor:"transformers.FlaxBlenderbotSmallModel.decode.decoder_input_ids",description:`<strong>decoder_input_ids</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, target_sequence_length)</code>) &#x2014;
Indices of decoder input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#decoder-input-ids">What are decoder input IDs?</a></p>
<p>For translation and summarization training, <code>decoder_input_ids</code> should be provided. If no
<code>decoder_input_ids</code> is provided, the model will create this tensor by shifting the <code>input_ids</code> to the right
for denoising pre-training following the paper.`,name:"decoder_input_ids"},{anchor:"transformers.FlaxBlenderbotSmallModel.decode.encoder_outputs",description:`<strong>encoder_outputs</strong> (<code>tuple(tuple(jnp.ndarray)</code>) &#x2014;
Tuple consists of (<code>last_hidden_state</code>, <em>optional</em>: <code>hidden_states</code>, <em>optional</em>: <code>attentions</code>)
<code>last_hidden_state</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) is a sequence of
hidden-states at the output of the last layer of the encoder. Used in the cross-attention of the decoder.`,name:"encoder_outputs"},{anchor:"transformers.FlaxBlenderbotSmallModel.decode.encoder_attention_mask",description:`<strong>encoder_attention_mask</strong> (<code>jnp.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:"encoder_attention_mask"},{anchor:"transformers.FlaxBlenderbotSmallModel.decode.decoder_attention_mask",description:`<strong>decoder_attention_mask</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Default behavior: generate a tensor that ignores pad tokens in <code>decoder_input_ids</code>. Causal mask will also
be used by default.</p>
<p>If you want to change padding behavior, you should modify to your needs. See diagram 1 in <a href="https://arxiv.org/abs/1910.13461" rel="nofollow">the
paper</a> for more information on the default strategy.`,name:"decoder_attention_mask"},{anchor:"transformers.FlaxBlenderbotSmallModel.decode.decoder_position_ids",description:`<strong>decoder_position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each decoder input sequence tokens in the position embeddings. Selected in the
range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"decoder_position_ids"},{anchor:"transformers.FlaxBlenderbotSmallModel.decode.past_key_values",description:`<strong>past_key_values</strong> (<code>Dict[str, np.ndarray]</code>, <em>optional</em>, returned by <code>init_cache</code> or when passing previous <code>past_key_values</code>) &#x2014;
Dictionary of pre-computed hidden-states (key and values in the attention blocks) that can be used for fast
auto-regressive decoding. Pre-computed key and value hidden-states are of shape <em>[batch_size, max_length]</em>.`,name:"past_key_values"},{anchor:"transformers.FlaxBlenderbotSmallModel.decode.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.FlaxBlenderbotSmallModel.decode.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.FlaxBlenderbotSmallModel.decode.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L1035",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPastAndCrossAttentions"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPastAndCrossAttentions</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 (<code>&lt;class 'transformers.models.blenderbot_small.configuration_blenderbot_small.BlenderbotSmallConfig'&gt;</code>) 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>
<p>If <code>past_key_values</code> is used only the last hidden-state of the sequences of shape <code>(batch_size, 1, hidden_size)</code> is output.</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>tuple(jnp.ndarray)</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>
<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> and <code>config.add_cross_attention=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 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/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPastAndCrossAttentions"
>transformers.modeling_flax_outputs.FlaxBaseModelOutputWithPastAndCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ht=new ho({props:{anchor:"transformers.FlaxBlenderbotSmallModel.decode.example",$$slots:{default:[xm]},$$scope:{ctx:z}}}),zn=new Ee({}),Fn=new O({props:{name:"class transformers.FlaxBlenderbotSmallForConditionalGeneration",anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration",parameters:[{name:"config",val:": BlenderbotSmallConfig"},{name:"input_shape",val:": typing.Tuple[int] = (1, 1)"},{name:"seed",val:": int = 0"},{name:"dtype",val:": dtype = <class 'jax.numpy.float32'>"},{name:"_do_init",val:": bool = True"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.config",description:`<strong>config</strong> (<a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig">BlenderbotSmallConfig</a>) &#x2014; Model configuration class with all the parameters of the model.
Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.dtype",description:`<strong>dtype</strong> (<code>jax.numpy.dtype</code>, <em>optional</em>, defaults to <code>jax.numpy.float32</code>) &#x2014;
The data type of the computation. Can be one of <code>jax.numpy.float32</code>, <code>jax.numpy.float16</code> (on GPUs) and
<code>jax.numpy.bfloat16</code> (on TPUs).</p>
<p>This can be used to enable mixed-precision training or half-precision inference on GPUs or TPUs. If
specified all the computation will be performed with the given <code>dtype</code>.</p>
<p><strong>Note that this only specifies the dtype of the computation and does not influence the dtype of model
parameters.</strong></p>
<p>If you wish to change the dtype of the model parameters, see <a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel.to_fp16">to_fp16()</a> and
<a href="/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel.to_bf16">to_bf16()</a>.`,name:"dtype"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L1303"}}),Ln=new O({props:{name:"__call__",anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.__call__",parameters:[{name:"input_ids",val:": ndarray"},{name:"attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_input_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = 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:"train",val:": bool = False"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"}],parametersDescription:[{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.__call__.input_ids",description:`<strong>input_ids</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary. Padding will be ignored by default should you provide
it.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.FlaxBlenderbotSmallForConditionalGeneration.__call__.attention_mask",description:`<strong>attention_mask</strong> (<code>jnp.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.FlaxBlenderbotSmallForConditionalGeneration.__call__.decoder_input_ids",description:`<strong>decoder_input_ids</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of decoder input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#decoder-input-ids">What are decoder input IDs?</a></p>
<p>For translation and summarization training, <code>decoder_input_ids</code> should be provided. If no
<code>decoder_input_ids</code> is provided, the model will create this tensor by shifting the <code>input_ids</code> to the right
for denoising pre-training following the paper.`,name:"decoder_input_ids"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.__call__.decoder_attention_mask",description:`<strong>decoder_attention_mask</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Default behavior: generate a tensor that ignores pad tokens in <code>decoder_input_ids</code>. Causal mask will also
be used by default.</p>
<p>If you want to change padding behavior, you should modify to your needs. See diagram 1 in <a href="https://arxiv.org/abs/1910.13461" rel="nofollow">the
paper</a> for more information on the default strategy.`,name:"decoder_attention_mask"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.__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.FlaxBlenderbotSmallForConditionalGeneration.__call__.decoder_position_ids",description:`<strong>decoder_position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each decoder input sequence tokens in the position embeddings. Selected in the
range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"decoder_position_ids"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.__call__.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.__call__.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L1151",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSeq2SeqLMOutput"
>transformers.modeling_flax_outputs.FlaxSeq2SeqLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallConfig"
>BlenderbotSmallConfig</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>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>tuple(jnp.ndarray)</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 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 in the cross-attention
blocks) that can be used (see <code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
<li>
<p><strong>decoder_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 decoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>decoder_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 of the decoder, 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>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>encoder_last_hidden_state</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) \u2014 Sequence of hidden-states at the output of the last layer of the encoder of the model.</p>
</li>
<li>
<p><strong>encoder_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 encoder at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>encoder_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 of the encoder, after the attention softmax, used to compute the weighted average in the
self-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxSeq2SeqLMOutput"
>transformers.modeling_flax_outputs.FlaxSeq2SeqLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ft=new Rn({props:{$$slots:{default:[Bm]},$$scope:{ctx:z}}}),In=new Ee({}),An=new O({props:{name:"encode",anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.encode",parameters:[{name:"input_ids",val:": ndarray"},{name:"attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = 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:"train",val:": bool = False"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"}],parametersDescription:[{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.encode.input_ids",description:`<strong>input_ids</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary. Padding will be ignored by default should you provide
it.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/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.FlaxBlenderbotSmallForConditionalGeneration.encode.attention_mask",description:`<strong>attention_mask</strong> (<code>jnp.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.FlaxBlenderbotSmallForConditionalGeneration.encode.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.FlaxBlenderbotSmallForConditionalGeneration.encode.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.FlaxBlenderbotSmallForConditionalGeneration.encode.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.FlaxBlenderbotSmallForConditionalGeneration.encode.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L972",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutput"
>transformers.modeling_flax_outputs.FlaxBaseModelOutput</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 (<code>&lt;class 'transformers.models.blenderbot_small.configuration_blenderbot_small.BlenderbotSmallConfig'&gt;</code>) 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>hidden_states</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(jnp.ndarray)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>jnp.ndarray</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxBaseModelOutput"
>transformers.modeling_flax_outputs.FlaxBaseModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),kt=new ho({props:{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.encode.example",$$slots:{default:[zm]},$$scope:{ctx:z}}}),Dn=new O({props:{name:"decode",anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode",parameters:[{name:"decoder_input_ids",val:""},{name:"encoder_outputs",val:""},{name:"encoder_attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_attention_mask",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"decoder_position_ids",val:": typing.Optional[jax._src.numpy.ndarray.ndarray] = None"},{name:"past_key_values",val:": dict = 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:"deterministic",val:": bool = True"},{name:"params",val:": dict = None"},{name:"dropout_rng",val:": PRNGKey = None"}],parametersDescription:[{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.decoder_input_ids",description:`<strong>decoder_input_ids</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, target_sequence_length)</code>) &#x2014;
Indices of decoder input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallTokenizer">BlenderbotSmallTokenizer</a>. See <a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/pr_19907/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#decoder-input-ids">What are decoder input IDs?</a></p>
<p>For translation and summarization training, <code>decoder_input_ids</code> should be provided. If no
<code>decoder_input_ids</code> is provided, the model will create this tensor by shifting the <code>input_ids</code> to the right
for denoising pre-training following the paper.`,name:"decoder_input_ids"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.encoder_outputs",description:`<strong>encoder_outputs</strong> (<code>tuple(tuple(jnp.ndarray)</code>) &#x2014;
Tuple consists of (<code>last_hidden_state</code>, <em>optional</em>: <code>hidden_states</code>, <em>optional</em>: <code>attentions</code>)
<code>last_hidden_state</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) is a sequence of
hidden-states at the output of the last layer of the encoder. Used in the cross-attention of the decoder.`,name:"encoder_outputs"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.encoder_attention_mask",description:`<strong>encoder_attention_mask</strong> (<code>jnp.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:"encoder_attention_mask"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.decoder_attention_mask",description:`<strong>decoder_attention_mask</strong> (<code>jnp.ndarray</code> of shape <code>(batch_size, target_sequence_length)</code>, <em>optional</em>) &#x2014;
Default behavior: generate a tensor that ignores pad tokens in <code>decoder_input_ids</code>. Causal mask will also
be used by default.</p>
<p>If you want to change padding behavior, you should modify to your needs. See diagram 1 in <a href="https://arxiv.org/abs/1910.13461" rel="nofollow">the
paper</a> for more information on the default strategy.`,name:"decoder_attention_mask"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.decoder_position_ids",description:`<strong>decoder_position_ids</strong> (<code>numpy.ndarray</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each decoder input sequence tokens in the position embeddings. Selected in the
range <code>[0, config.max_position_embeddings - 1]</code>.`,name:"decoder_position_ids"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.past_key_values",description:`<strong>past_key_values</strong> (<code>Dict[str, np.ndarray]</code>, <em>optional</em>, returned by <code>init_cache</code> or when passing previous <code>past_key_values</code>) &#x2014;
Dictionary of pre-computed hidden-states (key and values in the attention blocks) that can be used for fast
auto-regressive decoding. Pre-computed key and value hidden-states are of shape <em>[batch_size, max_length]</em>.`,name:"past_key_values"},{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.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.FlaxBlenderbotSmallForConditionalGeneration.decode.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.FlaxBlenderbotSmallForConditionalGeneration.decode.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/pr_19907/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/vr_19907/src/transformers/models/blenderbot_small/modeling_flax_blenderbot_small.py#L1307",returnDescription:`
<p>A <a
  href="/docs/transformers/pr_19907/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 (<code>&lt;class 'transformers.models.blenderbot_small.configuration_blenderbot_small.BlenderbotSmallConfig'&gt;</code>) 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/pr_19907/en/main_classes/output#transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions"
>transformers.modeling_flax_outputs.FlaxCausalLMOutputWithCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),vt=new ho({props:{anchor:"transformers.FlaxBlenderbotSmallForConditionalGeneration.decode.example",$$slots:{default:[Fm]},$$scope:{ctx:z}}}),{c(){p=n("meta"),k=i(),f=n("h1"),m=n("a"),b=n("span"),v(d.$$.fragment),h=i(),q=n("span"),Ae=s("Blenderbot Small"),Me=i(),C=n("p"),De=s("Note that "),se=n("a"),B=s("BlenderbotSmallModel"),Ge=s(` and
`),Y=n("a"),Ue=s("BlenderbotSmallForConditionalGeneration"),We=s(` are only used in combination with the checkpoint
`),K=n("a"),Re=s("facebook/blenderbot-90M"),Ke=s(`. Larger Blenderbot checkpoints should
instead be used with `),Z=n("a"),He=s("BlenderbotModel"),Qe=s(` and
`),ee=n("a"),Ve=s("BlenderbotForConditionalGeneration"),Ce=i(),G=n("h2"),le=n("a"),we=n("span"),v(te.$$.fragment),P=i(),I=n("span"),Je=s("Overview"),de=i(),ie=n("p"),Xe=s("The Blender chatbot model was proposed in "),H=n("a"),Ye=s("Recipes for building an open-domain chatbot"),Ze=s(` Stephen Roller, Emily Dinan, Naman Goyal, Da Ju, Mary Williamson, Yinhan Liu,
Jing Xu, Myle Ott, Kurt Shuster, Eric M. Smith, Y-Lan Boureau, Jason Weston on 30 Apr 2020.`),A=i(),ke=n("p"),he=s("The abstract of the paper is the following:"),je=i(),ye=n("p"),ne=n("em"),eo=s(`Building open-domain chatbots is a challenging area for machine learning research. While prior work has shown that
scaling neural models in the number of parameters and the size of the data they are trained on gives improved results,
we show that other ingredients are important for a high-performing chatbot. Good conversation requires a number of
skills that an expert conversationalist blends in a seamless way: providing engaging talking points and listening to
their partners, and displaying knowledge, empathy and personality appropriately, while maintaining a consistent
persona. We show that large scale models can learn these skills when given appropriate training data and choice of
generation strategy. We build variants of these recipes with 90M, 2.7B and 9.4B parameter models, and make our models
and code publicly available. Human evaluations show our best models are superior to existing approaches in multi-turn
dialogue in terms of engagingness and humanness measurements. We then discuss the limitations of this work by analyzing
failure cases of our models.`),Oe=i(),N=n("p"),oo=s("This model was contributed by "),Q=n("a"),to=s("patrickvonplaten"),Se=s(`. The authors\u2019 code can be
found `),L=n("a"),no=s("here"),V=s(" ."),Pe=i(),ae=n("h2"),y=n("a"),F=n("span"),v($e.$$.fragment),xe=i(),ao=n("span"),_o=s("BlenderbotSmallConfig"),E=i(),J=n("div"),v(Be.$$.fragment),go=i(),me=n("p"),bo=s("This is the configuration class to store the configuration of a "),R=n("a"),fe=s("BlenderbotSmallModel"),ko=s(`. It is used to instantiate
an BlenderbotSmall 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 BlenderbotSmall
`),ze=n("a"),_e=s("facebook/blenderbot_small-90M"),yo=s(" architecture."),vo=i(),re=n("p"),To=s("Configuration objects inherit from "),ce=n("a"),wo=s("PretrainedConfig"),wl=s(` and can be used to control the model outputs. Read the
documentation from `),Kn=n("a"),Sl=s("PretrainedConfig"),$l=s(" for more information."),xl=i(),v(Ao.$$.fragment),Ts=i(),So=n("h2"),Do=n("a"),ka=n("span"),v(qt.$$.fragment),Bl=i(),ya=n("span"),zl=s("BlenderbotSmallTokenizer"),ws=i(),X=n("div"),v(Et.$$.fragment),Fl=i(),va=n("p"),ql=s("Constructs a Blenderbot-90M tokenizer based on BPE (Byte-Pair-Encoding)"),El=i(),Mt=n("p"),Ml=s("This tokenizer inherits from "),Hn=n("a"),Cl=s("PreTrainedTokenizer"),jl=s(` which contains most of the main methods. Users should refer to
the superclass for more information regarding methods.`),Ol=i(),io=n("div"),v(Ct.$$.fragment),Pl=i(),Ta=n("p"),Ll=s(`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens.`),Nl=i(),wa=n("p"),Il=s("This implementation does not add special tokens and this method should be overridden in a subclass."),Al=i(),Go=n("div"),v(jt.$$.fragment),Dl=i(),$o=n("p"),Gl=s(`Retrieves sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),Sa=n("code"),Ul=s("prepare_for_model"),Wl=s(" or "),$a=n("code"),Rl=s("encode_plus"),Kl=s(" methods."),Hl=i(),co=n("div"),v(Ot.$$.fragment),Ql=i(),Qn=n("p"),Vl=s("Create the token type IDs corresponding to the sequences passed. "),Vn=n("a"),Jl=s(`What are token type
IDs?`),Xl=i(),xa=n("p"),Yl=s("Should be overridden in a subclass if the model has a special way of building those."),Zl=i(),Jn=n("div"),v(Pt.$$.fragment),Ss=i(),xo=n("h2"),Uo=n("a"),Ba=n("span"),v(Lt.$$.fragment),ed=i(),za=n("span"),od=s("BlenderbotSmallTokenizerFast"),$s=i(),ro=n("div"),v(Nt.$$.fragment),td=i(),It=n("p"),nd=s("Construct a \u201Cfast\u201D BlenderbotSmall tokenizer (backed by HuggingFace\u2019s "),Fa=n("em"),ad=s("tokenizers"),rd=s(" library)."),sd=i(),Wo=n("div"),v(At.$$.fragment),ld=i(),qa=n("p"),dd=s(`Create a mask from the two sequences passed to be used in a sequence-pair classification task. BlenderbotSmall
does not make use of token type ids, therefore a list of zeros is returned.`),xs=i(),Bo=n("h2"),Ro=n("a"),Ea=n("span"),v(Dt.$$.fragment),id=i(),Ma=n("span"),cd=s("BlenderbotSmallModel"),Bs=i(),Fe=n("div"),v(Gt.$$.fragment),pd=i(),Ut=n("p"),ud=s(`The bare BlenderbotSmall Model outputting raw hidden-states without any specific head on top.
This model inherits from `),Xn=n("a"),hd=s("PreTrainedModel"),md=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),fd=i(),Wt=n("p"),_d=s("This model is also a PyTorch "),Rt=n("a"),gd=s("torch.nn.Module"),bd=s(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),kd=i(),Le=n("div"),v(Kt.$$.fragment),yd=i(),zo=n("p"),vd=s("The "),Yn=n("a"),Td=s("BlenderbotSmallModel"),wd=s(" forward method, overrides the "),Ca=n("code"),Sd=s("__call__"),$d=s(" special method."),xd=i(),v(Ko.$$.fragment),Bd=i(),v(Ho.$$.fragment),zs=i(),Fo=n("h2"),Qo=n("a"),ja=n("span"),v(Ht.$$.fragment),zd=i(),Oa=n("span"),Fd=s("BlenderbotSmallForConditionalGeneration"),Fs=i(),qe=n("div"),v(Qt.$$.fragment),qd=i(),Vt=n("p"),Ed=s(`The BlenderbotSmall Model with a language modeling head. Can be used for summarization.
This model inherits from `),Zn=n("a"),Md=s("PreTrainedModel"),Cd=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),jd=i(),Jt=n("p"),Od=s("This model is also a PyTorch "),Xt=n("a"),Pd=s("torch.nn.Module"),Ld=s(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Nd=i(),Ne=n("div"),v(Yt.$$.fragment),Id=i(),qo=n("p"),Ad=s("The "),ea=n("a"),Dd=s("BlenderbotSmallForConditionalGeneration"),Gd=s(" forward method, overrides the "),Pa=n("code"),Ud=s("__call__"),Wd=s(" special method."),Rd=i(),v(Vo.$$.fragment),Kd=i(),v(Jo.$$.fragment),qs=i(),Eo=n("h2"),Xo=n("a"),La=n("span"),v(Zt.$$.fragment),Hd=i(),Na=n("span"),Qd=s("BlenderbotSmallForCausalLM"),Es=i(),Mo=n("div"),v(en.$$.fragment),Vd=i(),Yo=n("div"),v(on.$$.fragment),Jd=i(),v(Zo.$$.fragment),Ms=i(),Co=n("h2"),et=n("a"),Ia=n("span"),v(tn.$$.fragment),Xd=i(),Aa=n("span"),Yd=s("TFBlenderbotSmallModel"),Cs=i(),ge=n("div"),v(nn.$$.fragment),Zd=i(),an=n("p"),ei=s(`The bare BLENDERBOT_SMALL Model outputting raw hidden-states without any specific head on top.
This model inherits from `),oa=n("a"),oi=s("TFPreTrainedModel"),ti=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ni=i(),rn=n("p"),ai=s("This model is also a "),sn=n("a"),ri=s("tf.keras.Model"),si=s(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),li=i(),v(ot.$$.fragment),di=i(),Ie=n("div"),v(ln.$$.fragment),ii=i(),jo=n("p"),ci=s("The "),ta=n("a"),pi=s("TFBlenderbotSmallModel"),ui=s(" forward method, overrides the "),Da=n("code"),hi=s("__call__"),mi=s(" special method."),fi=i(),v(tt.$$.fragment),_i=i(),v(nt.$$.fragment),js=i(),Oo=n("h2"),at=n("a"),Ga=n("span"),v(dn.$$.fragment),gi=i(),Ua=n("span"),bi=s("TFBlenderbotSmallForConditionalGeneration"),Os=i(),be=n("div"),v(cn.$$.fragment),ki=i(),pn=n("p"),yi=s(`The BLENDERBOT_SMALL Model with a language modeling head. Can be used for summarization.
This model inherits from `),na=n("a"),vi=s("TFPreTrainedModel"),Ti=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),wi=i(),un=n("p"),Si=s("This model is also a "),hn=n("a"),$i=s("tf.keras.Model"),xi=s(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Bi=i(),v(rt.$$.fragment),zi=i(),D=n("div"),v(mn.$$.fragment),Fi=i(),Po=n("p"),qi=s("The "),aa=n("a"),Ei=s("TFBlenderbotSmallForConditionalGeneration"),Mi=s(" forward method, overrides the "),Wa=n("code"),Ci=s("__call__"),ji=s(" special method."),Oi=i(),v(st.$$.fragment),Pi=i(),Ra=n("p"),Li=s("Conversation example::"),Ni=i(),Ka=n("blockquote"),Ha=n("blockquote"),Qa=n("blockquote"),Va=n("p"),Ii=s(`from transformers import BlenderbotSmallTokenizer, TFBlenderbotSmallForConditionalGeneration >>> mname =
\u2018facebook/blenderbot_small-90M\u2019 >>> model = BlenderbotSmallForConditionalGeneration.from_pretrained(mname) >>>
tokenizer = BlenderbotSmallTokenizer.from_pretrained(mname)`),Ai=i(),Ja=n("blockquote"),Xa=n("blockquote"),Ya=n("blockquote"),Za=n("p"),Di=s(`UTTERANCE = \u201CMy friends are cool but they eat too many carbs.\u201D >>> print(\u201CHuman: \u201D, UTTERANCE) >>> inputs =
tokenizer([UTTERANCE], return_tensors=\u2018tf\u2019)`),Gi=i(),er=n("blockquote"),or=n("blockquote"),tr=n("blockquote"),nr=n("p"),Ui=s(`reply_ids = model.generate(**inputs) >>> print(\u201CBot: \u201D, tokenizer.batch_decode(reply_ids,
skip_special_tokens=True)[0]) what kind of carbs do they eat? i don\u2019t know much about carbs.`),Wi=i(),ar=n("blockquote"),rr=n("blockquote"),sr=n("blockquote"),fn=n("p"),Ri=s(`REPLY = \u201CI\u2019m not sure\u201D >>> print(\u201CHuman: \u201D, REPLY) >>> NEXT_UTTERANCE = ( \u2026 \u201CMy friends are cool but they
eat too many carbs.</s> \u201D \u2026 \u201D`),lr=n("s"),Ki=s("what kind of carbs do they eat? i don\u2019t know much about carbs."),Hi=s(` \u201D \u2026
\u201D<s>I\u2019m not sure.\u201D \u2026 )`),Qi=i(),dr=n("blockquote"),ir=n("blockquote"),cr=n("blockquote"),pr=n("p"),Vi=s(`inputs = tokenizer([NEXT_UTTERANCE], return_tensors=\u2018tf\u2019) >>> inputs.pop(\u201Ctoken_type_ids\u201D) >>>
next_reply_ids = model.generate(**inputs) >>> print(\u201CBot: \u201D, tokenizer.batch_decode(next_reply_ids,
skip_special_tokens=True)[0])`),Ps=i(),Lo=n("h2"),lt=n("a"),ur=n("span"),v(_n.$$.fragment),Ji=i(),hr=n("span"),Xi=s("FlaxBlenderbotSmallModel"),Ls=i(),U=n("div"),v(gn.$$.fragment),Yi=i(),bn=n("p"),Zi=s(`The bare BlenderbotSmall Model transformer outputting raw hidden-states without any specific head on top.
This model inherits from `),ra=n("a"),ec=s("FlaxPreTrainedModel"),oc=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),tc=i(),kn=n("p"),nc=s(`This model is also a Flax Linen
`),yn=n("a"),ac=s("flax.nn.Module"),rc=s(` subclass. Use it as a
regular Flax Module and refer to the Flax documentation for all matter related to general usage and behavior.`),sc=i(),mr=n("p"),lc=s("Finally, this model supports inherent JAX features such as:"),dc=i(),so=n("ul"),fr=n("li"),vn=n("a"),ic=s("Just-In-Time (JIT) compilation"),cc=i(),_r=n("li"),Tn=n("a"),pc=s("Automatic Differentiation"),uc=i(),gr=n("li"),wn=n("a"),hc=s("Vectorization"),mc=i(),br=n("li"),Sn=n("a"),fc=s("Parallelization"),_c=i(),dt=n("div"),v($n.$$.fragment),gc=i(),v(it.$$.fragment),bc=i(),ct=n("div"),v(xn.$$.fragment),kc=i(),v(pt.$$.fragment),yc=i(),ut=n("div"),v(Bn.$$.fragment),vc=i(),v(ht.$$.fragment),Ns=i(),No=n("h2"),mt=n("a"),kr=n("span"),v(zn.$$.fragment),Tc=i(),yr=n("span"),wc=s("FlaxBlenderbotForConditionalGeneration"),Is=i(),W=n("div"),v(Fn.$$.fragment),Sc=i(),qn=n("p"),$c=s(`The BLENDERBOT_SMALL Model with a language modeling head. Can be used for summarization.
This model inherits from `),sa=n("a"),xc=s("FlaxPreTrainedModel"),Bc=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),zc=i(),En=n("p"),Fc=s(`This model is also a Flax Linen
`),Mn=n("a"),qc=s("flax.nn.Module"),Ec=s(` subclass. Use it as a
regular Flax Module and refer to the Flax documentation for all matter related to general usage and behavior.`),Mc=i(),vr=n("p"),Cc=s("Finally, this model supports inherent JAX features such as:"),jc=i(),lo=n("ul"),Tr=n("li"),Cn=n("a"),Oc=s("Just-In-Time (JIT) compilation"),Pc=i(),wr=n("li"),jn=n("a"),Lc=s("Automatic Differentiation"),Nc=i(),Sr=n("li"),On=n("a"),Ic=s("Vectorization"),Ac=i(),$r=n("li"),Pn=n("a"),Dc=s("Parallelization"),Gc=i(),M=n("div"),v(Ln.$$.fragment),Uc=i(),Io=n("p"),Wc=s("The "),xr=n("code"),Rc=s("FlaxBlenderbotSmallPreTrainedModel"),Kc=s(" forward method, overrides the "),Br=n("code"),Hc=s("__call__"),Qc=s(" special method."),Vc=i(),v(ft.$$.fragment),Jc=i(),zr=n("p"),Xc=s("Summarization example:"),Yc=i(),Fr=n("blockquote"),qr=n("blockquote"),Er=n("blockquote"),Mr=n("p"),Zc=s("from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration"),ep=i(),Cr=n("blockquote"),jr=n("blockquote"),Or=n("blockquote"),Pr=n("p"),op=s(`model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019) >>>
tokenizer = BlenderbotSmallTokenizer.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019)`),tp=i(),Lr=n("blockquote"),Nr=n("blockquote"),Ir=n("blockquote"),Ar=n("p"),np=s(`ARTICLE_TO_SUMMARIZE = \u201CMy friends are cool but they eat too many carbs.\u201D >>> inputs =
tokenizer([ARTICLE_TO_SUMMARIZE], max_length=1024, return_tensors=\u2018np\u2019)`),ap=i(),Dr=n("blockquote"),Gr=n("blockquote"),Nn=n("blockquote"),_t=n("h1"),gt=n("a"),Ur=n("span"),v(In.$$.fragment),rp=i(),Wr=n("span"),sp=s("Generate Summary >>> summary_ids = model.generate(inputs[\u2018input_ids\u2019]).sequences >>>"),lp=i(),Rr=n("p"),dp=s("print(tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False))"),ip=i(),Kr=n("p"),cp=s("Mask filling example:"),pp=i(),Hr=n("blockquote"),Qr=n("blockquote"),Vr=n("blockquote"),Jr=n("p"),up=s(`from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration >>>
tokenizer = BlenderbotSmallTokenizer.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019) >>> TXT = \u201CMy friends are
<mask> but they eat too many carbs.\u201D`),hp=i(),Xr=n("blockquote"),Yr=n("blockquote"),Zr=n("blockquote"),es=n("p"),mp=s(`model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019) >>>
input_ids = tokenizer([TXT], return_tensors=\u2018np\u2019)[\u2018input_ids\u2019] >>> logits = model(input_ids).logits`),fp=i(),os=n("blockquote"),ts=n("blockquote"),ns=n("blockquote"),as=n("p"),_p=s(`masked_index = (input_ids[0] == tokenizer.mask_token_id).nonzero().item() >>> probs =
jax.nn.softmax(logits[0, masked_index], axis=0) >>> values, predictions = jax.lax.top_k(probs)`),gp=i(),rs=n("blockquote"),ss=n("blockquote"),ls=n("blockquote"),ds=n("p"),bp=s("tokenizer.decode(predictions).split()"),kp=i(),bt=n("div"),v(An.$$.fragment),yp=i(),v(kt.$$.fragment),vp=i(),yt=n("div"),v(Dn.$$.fragment),Tp=i(),v(vt.$$.fragment),this.h()},l(t){const g=pm('[data-svelte="svelte-1phssyn"]',document.head);p=a(g,"META",{name:!0,content:!0}),g.forEach(o),k=c(t),f=a(t,"H1",{class:!0});var Gn=r(f);m=a(Gn,"A",{id:!0,class:!0,href:!0});var is=r(m);b=a(is,"SPAN",{});var cs=r(b);T(d.$$.fragment,cs),cs.forEach(o),is.forEach(o),h=c(Gn),q=a(Gn,"SPAN",{});var ps=r(q);Ae=l(ps,"Blenderbot Small"),ps.forEach(o),Gn.forEach(o),Me=c(t),C=a(t,"P",{});var ve=r(C);De=l(ve,"Note that "),se=a(ve,"A",{href:!0});var us=r(se);B=l(us,"BlenderbotSmallModel"),us.forEach(o),Ge=l(ve,` and
`),Y=a(ve,"A",{href:!0});var hs=r(Y);Ue=l(hs,"BlenderbotSmallForConditionalGeneration"),hs.forEach(o),We=l(ve,` are only used in combination with the checkpoint
`),K=a(ve,"A",{href:!0,rel:!0});var ms=r(K);Re=l(ms,"facebook/blenderbot-90M"),ms.forEach(o),Ke=l(ve,`. Larger Blenderbot checkpoints should
instead be used with `),Z=a(ve,"A",{href:!0});var fs=r(Z);He=l(fs,"BlenderbotModel"),fs.forEach(o),Qe=l(ve,` and
`),ee=a(ve,"A",{href:!0});var _s=r(ee);Ve=l(_s,"BlenderbotForConditionalGeneration"),_s.forEach(o),ve.forEach(o),Ce=c(t),G=a(t,"H2",{class:!0});var Un=r(G);le=a(Un,"A",{id:!0,class:!0,href:!0});var gs=r(le);we=a(gs,"SPAN",{});var bs=r(we);T(te.$$.fragment,bs),bs.forEach(o),gs.forEach(o),P=c(Un),I=a(Un,"SPAN",{});var ks=r(I);Je=l(ks,"Overview"),ks.forEach(o),Un.forEach(o),de=c(t),ie=a(t,"P",{});var Wn=r(ie);Xe=l(Wn,"The Blender chatbot model was proposed in "),H=a(Wn,"A",{href:!0,rel:!0});var ys=r(H);Ye=l(ys,"Recipes for building an open-domain chatbot"),ys.forEach(o),Ze=l(Wn,` Stephen Roller, Emily Dinan, Naman Goyal, Da Ju, Mary Williamson, Yinhan Liu,
Jing Xu, Myle Ott, Kurt Shuster, Eric M. Smith, Y-Lan Boureau, Jason Weston on 30 Apr 2020.`),Wn.forEach(o),A=c(t),ke=a(t,"P",{});var vs=r(ke);he=l(vs,"The abstract of the paper is the following:"),vs.forEach(o),je=c(t),ye=a(t,"P",{});var Sp=r(ye);ne=a(Sp,"EM",{});var $p=r(ne);eo=l($p,`Building open-domain chatbots is a challenging area for machine learning research. While prior work has shown that
scaling neural models in the number of parameters and the size of the data they are trained on gives improved results,
we show that other ingredients are important for a high-performing chatbot. Good conversation requires a number of
skills that an expert conversationalist blends in a seamless way: providing engaging talking points and listening to
their partners, and displaying knowledge, empathy and personality appropriately, while maintaining a consistent
persona. We show that large scale models can learn these skills when given appropriate training data and choice of
generation strategy. We build variants of these recipes with 90M, 2.7B and 9.4B parameter models, and make our models
and code publicly available. Human evaluations show our best models are superior to existing approaches in multi-turn
dialogue in terms of engagingness and humanness measurements. We then discuss the limitations of this work by analyzing
failure cases of our models.`),$p.forEach(o),Sp.forEach(o),Oe=c(t),N=a(t,"P",{});var la=r(N);oo=l(la,"This model was contributed by "),Q=a(la,"A",{href:!0,rel:!0});var xp=r(Q);to=l(xp,"patrickvonplaten"),xp.forEach(o),Se=l(la,`. The authors\u2019 code can be
found `),L=a(la,"A",{href:!0,rel:!0});var Bp=r(L);no=l(Bp,"here"),Bp.forEach(o),V=l(la," ."),la.forEach(o),Pe=c(t),ae=a(t,"H2",{class:!0});var Ds=r(ae);y=a(Ds,"A",{id:!0,class:!0,href:!0});var zp=r(y);F=a(zp,"SPAN",{});var Fp=r(F);T($e.$$.fragment,Fp),Fp.forEach(o),zp.forEach(o),xe=c(Ds),ao=a(Ds,"SPAN",{});var qp=r(ao);_o=l(qp,"BlenderbotSmallConfig"),qp.forEach(o),Ds.forEach(o),E=c(t),J=a(t,"DIV",{class:!0});var Tt=r(J);T(Be.$$.fragment,Tt),go=c(Tt),me=a(Tt,"P",{});var da=r(me);bo=l(da,"This is the configuration class to store the configuration of a "),R=a(da,"A",{href:!0});var Ep=r(R);fe=l(Ep,"BlenderbotSmallModel"),Ep.forEach(o),ko=l(da,`. It is used to instantiate
an BlenderbotSmall 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 BlenderbotSmall
`),ze=a(da,"A",{href:!0,rel:!0});var Mp=r(ze);_e=l(Mp,"facebook/blenderbot_small-90M"),Mp.forEach(o),yo=l(da," architecture."),da.forEach(o),vo=c(Tt),re=a(Tt,"P",{});var ia=r(re);To=l(ia,"Configuration objects inherit from "),ce=a(ia,"A",{href:!0});var Cp=r(ce);wo=l(Cp,"PretrainedConfig"),Cp.forEach(o),wl=l(ia,` and can be used to control the model outputs. Read the
documentation from `),Kn=a(ia,"A",{href:!0});var jp=r(Kn);Sl=l(jp,"PretrainedConfig"),jp.forEach(o),$l=l(ia," for more information."),ia.forEach(o),xl=c(Tt),T(Ao.$$.fragment,Tt),Tt.forEach(o),Ts=c(t),So=a(t,"H2",{class:!0});var Gs=r(So);Do=a(Gs,"A",{id:!0,class:!0,href:!0});var Op=r(Do);ka=a(Op,"SPAN",{});var Pp=r(ka);T(qt.$$.fragment,Pp),Pp.forEach(o),Op.forEach(o),Bl=c(Gs),ya=a(Gs,"SPAN",{});var Lp=r(ya);zl=l(Lp,"BlenderbotSmallTokenizer"),Lp.forEach(o),Gs.forEach(o),ws=c(t),X=a(t,"DIV",{class:!0});var Te=r(X);T(Et.$$.fragment,Te),Fl=c(Te),va=a(Te,"P",{});var Np=r(va);ql=l(Np,"Constructs a Blenderbot-90M tokenizer based on BPE (Byte-Pair-Encoding)"),Np.forEach(o),El=c(Te),Mt=a(Te,"P",{});var Us=r(Mt);Ml=l(Us,"This tokenizer inherits from "),Hn=a(Us,"A",{href:!0});var Ip=r(Hn);Cl=l(Ip,"PreTrainedTokenizer"),Ip.forEach(o),jl=l(Us,` which contains most of the main methods. Users should refer to
the superclass for more information regarding methods.`),Us.forEach(o),Ol=c(Te),io=a(Te,"DIV",{class:!0});var ca=r(io);T(Ct.$$.fragment,ca),Pl=c(ca),Ta=a(ca,"P",{});var Ap=r(Ta);Ll=l(Ap,`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens.`),Ap.forEach(o),Nl=c(ca),wa=a(ca,"P",{});var Dp=r(wa);Il=l(Dp,"This implementation does not add special tokens and this method should be overridden in a subclass."),Dp.forEach(o),ca.forEach(o),Al=c(Te),Go=a(Te,"DIV",{class:!0});var Ws=r(Go);T(jt.$$.fragment,Ws),Dl=c(Ws),$o=a(Ws,"P",{});var pa=r($o);Gl=l(pa,`Retrieves sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),Sa=a(pa,"CODE",{});var Gp=r(Sa);Ul=l(Gp,"prepare_for_model"),Gp.forEach(o),Wl=l(pa," or "),$a=a(pa,"CODE",{});var Up=r($a);Rl=l(Up,"encode_plus"),Up.forEach(o),Kl=l(pa," methods."),pa.forEach(o),Ws.forEach(o),Hl=c(Te),co=a(Te,"DIV",{class:!0});var ua=r(co);T(Ot.$$.fragment,ua),Ql=c(ua),Qn=a(ua,"P",{});var wp=r(Qn);Vl=l(wp,"Create the token type IDs corresponding to the sequences passed. "),Vn=a(wp,"A",{href:!0});var Wp=r(Vn);Jl=l(Wp,`What are token type
IDs?`),Wp.forEach(o),wp.forEach(o),Xl=c(ua),xa=a(ua,"P",{});var Rp=r(xa);Yl=l(Rp,"Should be overridden in a subclass if the model has a special way of building those."),Rp.forEach(o),ua.forEach(o),Zl=c(Te),Jn=a(Te,"DIV",{class:!0});var Kp=r(Jn);T(Pt.$$.fragment,Kp),Kp.forEach(o),Te.forEach(o),Ss=c(t),xo=a(t,"H2",{class:!0});var Rs=r(xo);Uo=a(Rs,"A",{id:!0,class:!0,href:!0});var Hp=r(Uo);Ba=a(Hp,"SPAN",{});var Qp=r(Ba);T(Lt.$$.fragment,Qp),Qp.forEach(o),Hp.forEach(o),ed=c(Rs),za=a(Rs,"SPAN",{});var Vp=r(za);od=l(Vp,"BlenderbotSmallTokenizerFast"),Vp.forEach(o),Rs.forEach(o),$s=c(t),ro=a(t,"DIV",{class:!0});var ha=r(ro);T(Nt.$$.fragment,ha),td=c(ha),It=a(ha,"P",{});var Ks=r(It);nd=l(Ks,"Construct a \u201Cfast\u201D BlenderbotSmall tokenizer (backed by HuggingFace\u2019s "),Fa=a(Ks,"EM",{});var Jp=r(Fa);ad=l(Jp,"tokenizers"),Jp.forEach(o),rd=l(Ks," library)."),Ks.forEach(o),sd=c(ha),Wo=a(ha,"DIV",{class:!0});var Hs=r(Wo);T(At.$$.fragment,Hs),ld=c(Hs),qa=a(Hs,"P",{});var Xp=r(qa);dd=l(Xp,`Create a mask from the two sequences passed to be used in a sequence-pair classification task. BlenderbotSmall
does not make use of token type ids, therefore a list of zeros is returned.`),Xp.forEach(o),Hs.forEach(o),ha.forEach(o),xs=c(t),Bo=a(t,"H2",{class:!0});var Qs=r(Bo);Ro=a(Qs,"A",{id:!0,class:!0,href:!0});var Yp=r(Ro);Ea=a(Yp,"SPAN",{});var Zp=r(Ea);T(Dt.$$.fragment,Zp),Zp.forEach(o),Yp.forEach(o),id=c(Qs),Ma=a(Qs,"SPAN",{});var eu=r(Ma);cd=l(eu,"BlenderbotSmallModel"),eu.forEach(o),Qs.forEach(o),Bs=c(t),Fe=a(t,"DIV",{class:!0});var wt=r(Fe);T(Gt.$$.fragment,wt),pd=c(wt),Ut=a(wt,"P",{});var Vs=r(Ut);ud=l(Vs,`The bare BlenderbotSmall Model outputting raw hidden-states without any specific head on top.
This model inherits from `),Xn=a(Vs,"A",{href:!0});var ou=r(Xn);hd=l(ou,"PreTrainedModel"),ou.forEach(o),md=l(Vs,`. 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.)`),Vs.forEach(o),fd=c(wt),Wt=a(wt,"P",{});var Js=r(Wt);_d=l(Js,"This model is also a PyTorch "),Rt=a(Js,"A",{href:!0,rel:!0});var tu=r(Rt);gd=l(tu,"torch.nn.Module"),tu.forEach(o),bd=l(Js,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Js.forEach(o),kd=c(wt),Le=a(wt,"DIV",{class:!0});var St=r(Le);T(Kt.$$.fragment,St),yd=c(St),zo=a(St,"P",{});var ma=r(zo);vd=l(ma,"The "),Yn=a(ma,"A",{href:!0});var nu=r(Yn);Td=l(nu,"BlenderbotSmallModel"),nu.forEach(o),wd=l(ma," forward method, overrides the "),Ca=a(ma,"CODE",{});var au=r(Ca);Sd=l(au,"__call__"),au.forEach(o),$d=l(ma," special method."),ma.forEach(o),xd=c(St),T(Ko.$$.fragment,St),Bd=c(St),T(Ho.$$.fragment,St),St.forEach(o),wt.forEach(o),zs=c(t),Fo=a(t,"H2",{class:!0});var Xs=r(Fo);Qo=a(Xs,"A",{id:!0,class:!0,href:!0});var ru=r(Qo);ja=a(ru,"SPAN",{});var su=r(ja);T(Ht.$$.fragment,su),su.forEach(o),ru.forEach(o),zd=c(Xs),Oa=a(Xs,"SPAN",{});var lu=r(Oa);Fd=l(lu,"BlenderbotSmallForConditionalGeneration"),lu.forEach(o),Xs.forEach(o),Fs=c(t),qe=a(t,"DIV",{class:!0});var $t=r(qe);T(Qt.$$.fragment,$t),qd=c($t),Vt=a($t,"P",{});var Ys=r(Vt);Ed=l(Ys,`The BlenderbotSmall Model with a language modeling head. Can be used for summarization.
This model inherits from `),Zn=a(Ys,"A",{href:!0});var du=r(Zn);Md=l(du,"PreTrainedModel"),du.forEach(o),Cd=l(Ys,`. 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.)`),Ys.forEach(o),jd=c($t),Jt=a($t,"P",{});var Zs=r(Jt);Od=l(Zs,"This model is also a PyTorch "),Xt=a(Zs,"A",{href:!0,rel:!0});var iu=r(Xt);Pd=l(iu,"torch.nn.Module"),iu.forEach(o),Ld=l(Zs,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Zs.forEach(o),Nd=c($t),Ne=a($t,"DIV",{class:!0});var xt=r(Ne);T(Yt.$$.fragment,xt),Id=c(xt),qo=a(xt,"P",{});var fa=r(qo);Ad=l(fa,"The "),ea=a(fa,"A",{href:!0});var cu=r(ea);Dd=l(cu,"BlenderbotSmallForConditionalGeneration"),cu.forEach(o),Gd=l(fa," forward method, overrides the "),Pa=a(fa,"CODE",{});var pu=r(Pa);Ud=l(pu,"__call__"),pu.forEach(o),Wd=l(fa," special method."),fa.forEach(o),Rd=c(xt),T(Vo.$$.fragment,xt),Kd=c(xt),T(Jo.$$.fragment,xt),xt.forEach(o),$t.forEach(o),qs=c(t),Eo=a(t,"H2",{class:!0});var el=r(Eo);Xo=a(el,"A",{id:!0,class:!0,href:!0});var uu=r(Xo);La=a(uu,"SPAN",{});var hu=r(La);T(Zt.$$.fragment,hu),hu.forEach(o),uu.forEach(o),Hd=c(el),Na=a(el,"SPAN",{});var mu=r(Na);Qd=l(mu,"BlenderbotSmallForCausalLM"),mu.forEach(o),el.forEach(o),Es=c(t),Mo=a(t,"DIV",{class:!0});var ol=r(Mo);T(en.$$.fragment,ol),Vd=c(ol),Yo=a(ol,"DIV",{class:!0});var tl=r(Yo);T(on.$$.fragment,tl),Jd=c(tl),T(Zo.$$.fragment,tl),tl.forEach(o),ol.forEach(o),Ms=c(t),Co=a(t,"H2",{class:!0});var nl=r(Co);et=a(nl,"A",{id:!0,class:!0,href:!0});var fu=r(et);Ia=a(fu,"SPAN",{});var _u=r(Ia);T(tn.$$.fragment,_u),_u.forEach(o),fu.forEach(o),Xd=c(nl),Aa=a(nl,"SPAN",{});var gu=r(Aa);Yd=l(gu,"TFBlenderbotSmallModel"),gu.forEach(o),nl.forEach(o),Cs=c(t),ge=a(t,"DIV",{class:!0});var po=r(ge);T(nn.$$.fragment,po),Zd=c(po),an=a(po,"P",{});var al=r(an);ei=l(al,`The bare BLENDERBOT_SMALL Model outputting raw hidden-states without any specific head on top.
This model inherits from `),oa=a(al,"A",{href:!0});var bu=r(oa);oi=l(bu,"TFPreTrainedModel"),bu.forEach(o),ti=l(al,`. 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.)`),al.forEach(o),ni=c(po),rn=a(po,"P",{});var rl=r(rn);ai=l(rl,"This model is also a "),sn=a(rl,"A",{href:!0,rel:!0});var ku=r(sn);ri=l(ku,"tf.keras.Model"),ku.forEach(o),si=l(rl,` 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.`),rl.forEach(o),li=c(po),T(ot.$$.fragment,po),di=c(po),Ie=a(po,"DIV",{class:!0});var Bt=r(Ie);T(ln.$$.fragment,Bt),ii=c(Bt),jo=a(Bt,"P",{});var _a=r(jo);ci=l(_a,"The "),ta=a(_a,"A",{href:!0});var yu=r(ta);pi=l(yu,"TFBlenderbotSmallModel"),yu.forEach(o),ui=l(_a," forward method, overrides the "),Da=a(_a,"CODE",{});var vu=r(Da);hi=l(vu,"__call__"),vu.forEach(o),mi=l(_a," special method."),_a.forEach(o),fi=c(Bt),T(tt.$$.fragment,Bt),_i=c(Bt),T(nt.$$.fragment,Bt),Bt.forEach(o),po.forEach(o),js=c(t),Oo=a(t,"H2",{class:!0});var sl=r(Oo);at=a(sl,"A",{id:!0,class:!0,href:!0});var Tu=r(at);Ga=a(Tu,"SPAN",{});var wu=r(Ga);T(dn.$$.fragment,wu),wu.forEach(o),Tu.forEach(o),gi=c(sl),Ua=a(sl,"SPAN",{});var Su=r(Ua);bi=l(Su,"TFBlenderbotSmallForConditionalGeneration"),Su.forEach(o),sl.forEach(o),Os=c(t),be=a(t,"DIV",{class:!0});var uo=r(be);T(cn.$$.fragment,uo),ki=c(uo),pn=a(uo,"P",{});var ll=r(pn);yi=l(ll,`The BLENDERBOT_SMALL Model with a language modeling head. Can be used for summarization.
This model inherits from `),na=a(ll,"A",{href:!0});var $u=r(na);vi=l($u,"TFPreTrainedModel"),$u.forEach(o),Ti=l(ll,`. 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.)`),ll.forEach(o),wi=c(uo),un=a(uo,"P",{});var dl=r(un);Si=l(dl,"This model is also a "),hn=a(dl,"A",{href:!0,rel:!0});var xu=r(hn);$i=l(xu,"tf.keras.Model"),xu.forEach(o),xi=l(dl,` 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.`),dl.forEach(o),Bi=c(uo),T(rt.$$.fragment,uo),zi=c(uo),D=a(uo,"DIV",{class:!0});var oe=r(D);T(mn.$$.fragment,oe),Fi=c(oe),Po=a(oe,"P",{});var ga=r(Po);qi=l(ga,"The "),aa=a(ga,"A",{href:!0});var Bu=r(aa);Ei=l(Bu,"TFBlenderbotSmallForConditionalGeneration"),Bu.forEach(o),Mi=l(ga," forward method, overrides the "),Wa=a(ga,"CODE",{});var zu=r(Wa);Ci=l(zu,"__call__"),zu.forEach(o),ji=l(ga," special method."),ga.forEach(o),Oi=c(oe),T(st.$$.fragment,oe),Pi=c(oe),Ra=a(oe,"P",{});var Fu=r(Ra);Li=l(Fu,"Conversation example::"),Fu.forEach(o),Ni=c(oe),Ka=a(oe,"BLOCKQUOTE",{});var qu=r(Ka);Ha=a(qu,"BLOCKQUOTE",{});var Eu=r(Ha);Qa=a(Eu,"BLOCKQUOTE",{});var Mu=r(Qa);Va=a(Mu,"P",{});var Cu=r(Va);Ii=l(Cu,`from transformers import BlenderbotSmallTokenizer, TFBlenderbotSmallForConditionalGeneration >>> mname =
\u2018facebook/blenderbot_small-90M\u2019 >>> model = BlenderbotSmallForConditionalGeneration.from_pretrained(mname) >>>
tokenizer = BlenderbotSmallTokenizer.from_pretrained(mname)`),Cu.forEach(o),Mu.forEach(o),Eu.forEach(o),qu.forEach(o),Ai=c(oe),Ja=a(oe,"BLOCKQUOTE",{});var ju=r(Ja);Xa=a(ju,"BLOCKQUOTE",{});var Ou=r(Xa);Ya=a(Ou,"BLOCKQUOTE",{});var Pu=r(Ya);Za=a(Pu,"P",{});var Lu=r(Za);Di=l(Lu,`UTTERANCE = \u201CMy friends are cool but they eat too many carbs.\u201D >>> print(\u201CHuman: \u201D, UTTERANCE) >>> inputs =
tokenizer([UTTERANCE], return_tensors=\u2018tf\u2019)`),Lu.forEach(o),Pu.forEach(o),Ou.forEach(o),ju.forEach(o),Gi=c(oe),er=a(oe,"BLOCKQUOTE",{});var Nu=r(er);or=a(Nu,"BLOCKQUOTE",{});var Iu=r(or);tr=a(Iu,"BLOCKQUOTE",{});var Au=r(tr);nr=a(Au,"P",{});var Du=r(nr);Ui=l(Du,`reply_ids = model.generate(**inputs) >>> print(\u201CBot: \u201D, tokenizer.batch_decode(reply_ids,
skip_special_tokens=True)[0]) what kind of carbs do they eat? i don\u2019t know much about carbs.`),Du.forEach(o),Au.forEach(o),Iu.forEach(o),Nu.forEach(o),Wi=c(oe),ar=a(oe,"BLOCKQUOTE",{});var Gu=r(ar);rr=a(Gu,"BLOCKQUOTE",{});var Uu=r(rr);sr=a(Uu,"BLOCKQUOTE",{});var Wu=r(sr);fn=a(Wu,"P",{});var il=r(fn);Ri=l(il,`REPLY = \u201CI\u2019m not sure\u201D >>> print(\u201CHuman: \u201D, REPLY) >>> NEXT_UTTERANCE = ( \u2026 \u201CMy friends are cool but they
eat too many carbs.</s> \u201D \u2026 \u201D`),lr=a(il,"S",{});var Ru=r(lr);Ki=l(Ru,"what kind of carbs do they eat? i don\u2019t know much about carbs."),Ru.forEach(o),Hi=l(il,` \u201D \u2026
\u201D<s>I\u2019m not sure.\u201D \u2026 )`),il.forEach(o),Wu.forEach(o),Uu.forEach(o),Gu.forEach(o),Qi=c(oe),dr=a(oe,"BLOCKQUOTE",{});var Ku=r(dr);ir=a(Ku,"BLOCKQUOTE",{});var Hu=r(ir);cr=a(Hu,"BLOCKQUOTE",{});var Qu=r(cr);pr=a(Qu,"P",{});var Vu=r(pr);Vi=l(Vu,`inputs = tokenizer([NEXT_UTTERANCE], return_tensors=\u2018tf\u2019) >>> inputs.pop(\u201Ctoken_type_ids\u201D) >>>
next_reply_ids = model.generate(**inputs) >>> print(\u201CBot: \u201D, tokenizer.batch_decode(next_reply_ids,
skip_special_tokens=True)[0])`),Vu.forEach(o),Qu.forEach(o),Hu.forEach(o),Ku.forEach(o),oe.forEach(o),uo.forEach(o),Ps=c(t),Lo=a(t,"H2",{class:!0});var cl=r(Lo);lt=a(cl,"A",{id:!0,class:!0,href:!0});var Ju=r(lt);ur=a(Ju,"SPAN",{});var Xu=r(ur);T(_n.$$.fragment,Xu),Xu.forEach(o),Ju.forEach(o),Ji=c(cl),hr=a(cl,"SPAN",{});var Yu=r(hr);Xi=l(Yu,"FlaxBlenderbotSmallModel"),Yu.forEach(o),cl.forEach(o),Ls=c(t),U=a(t,"DIV",{class:!0});var pe=r(U);T(gn.$$.fragment,pe),Yi=c(pe),bn=a(pe,"P",{});var pl=r(bn);Zi=l(pl,`The bare BlenderbotSmall Model transformer outputting raw hidden-states without any specific head on top.
This model inherits from `),ra=a(pl,"A",{href:!0});var Zu=r(ra);ec=l(Zu,"FlaxPreTrainedModel"),Zu.forEach(o),oc=l(pl,`. 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.)`),pl.forEach(o),tc=c(pe),kn=a(pe,"P",{});var ul=r(kn);nc=l(ul,`This model is also a Flax Linen
`),yn=a(ul,"A",{href:!0,rel:!0});var eh=r(yn);ac=l(eh,"flax.nn.Module"),eh.forEach(o),rc=l(ul,` subclass. Use it as a
regular Flax Module and refer to the Flax documentation for all matter related to general usage and behavior.`),ul.forEach(o),sc=c(pe),mr=a(pe,"P",{});var oh=r(mr);lc=l(oh,"Finally, this model supports inherent JAX features such as:"),oh.forEach(o),dc=c(pe),so=a(pe,"UL",{});var zt=r(so);fr=a(zt,"LI",{});var th=r(fr);vn=a(th,"A",{href:!0,rel:!0});var nh=r(vn);ic=l(nh,"Just-In-Time (JIT) compilation"),nh.forEach(o),th.forEach(o),cc=c(zt),_r=a(zt,"LI",{});var ah=r(_r);Tn=a(ah,"A",{href:!0,rel:!0});var rh=r(Tn);pc=l(rh,"Automatic Differentiation"),rh.forEach(o),ah.forEach(o),uc=c(zt),gr=a(zt,"LI",{});var sh=r(gr);wn=a(sh,"A",{href:!0,rel:!0});var lh=r(wn);hc=l(lh,"Vectorization"),lh.forEach(o),sh.forEach(o),mc=c(zt),br=a(zt,"LI",{});var dh=r(br);Sn=a(dh,"A",{href:!0,rel:!0});var ih=r(Sn);fc=l(ih,"Parallelization"),ih.forEach(o),dh.forEach(o),zt.forEach(o),_c=c(pe),dt=a(pe,"DIV",{class:!0});var hl=r(dt);T($n.$$.fragment,hl),gc=c(hl),T(it.$$.fragment,hl),hl.forEach(o),bc=c(pe),ct=a(pe,"DIV",{class:!0});var ml=r(ct);T(xn.$$.fragment,ml),kc=c(ml),T(pt.$$.fragment,ml),ml.forEach(o),yc=c(pe),ut=a(pe,"DIV",{class:!0});var fl=r(ut);T(Bn.$$.fragment,fl),vc=c(fl),T(ht.$$.fragment,fl),fl.forEach(o),pe.forEach(o),Ns=c(t),No=a(t,"H2",{class:!0});var _l=r(No);mt=a(_l,"A",{id:!0,class:!0,href:!0});var ch=r(mt);kr=a(ch,"SPAN",{});var ph=r(kr);T(zn.$$.fragment,ph),ph.forEach(o),ch.forEach(o),Tc=c(_l),yr=a(_l,"SPAN",{});var uh=r(yr);wc=l(uh,"FlaxBlenderbotForConditionalGeneration"),uh.forEach(o),_l.forEach(o),Is=c(t),W=a(t,"DIV",{class:!0});var ue=r(W);T(Fn.$$.fragment,ue),Sc=c(ue),qn=a(ue,"P",{});var gl=r(qn);$c=l(gl,`The BLENDERBOT_SMALL Model with a language modeling head. Can be used for summarization.
This model inherits from `),sa=a(gl,"A",{href:!0});var hh=r(sa);xc=l(hh,"FlaxPreTrainedModel"),hh.forEach(o),Bc=l(gl,`. 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.)`),gl.forEach(o),zc=c(ue),En=a(ue,"P",{});var bl=r(En);Fc=l(bl,`This model is also a Flax Linen
`),Mn=a(bl,"A",{href:!0,rel:!0});var mh=r(Mn);qc=l(mh,"flax.nn.Module"),mh.forEach(o),Ec=l(bl,` subclass. Use it as a
regular Flax Module and refer to the Flax documentation for all matter related to general usage and behavior.`),bl.forEach(o),Mc=c(ue),vr=a(ue,"P",{});var fh=r(vr);Cc=l(fh,"Finally, this model supports inherent JAX features such as:"),fh.forEach(o),jc=c(ue),lo=a(ue,"UL",{});var Ft=r(lo);Tr=a(Ft,"LI",{});var _h=r(Tr);Cn=a(_h,"A",{href:!0,rel:!0});var gh=r(Cn);Oc=l(gh,"Just-In-Time (JIT) compilation"),gh.forEach(o),_h.forEach(o),Pc=c(Ft),wr=a(Ft,"LI",{});var bh=r(wr);jn=a(bh,"A",{href:!0,rel:!0});var kh=r(jn);Lc=l(kh,"Automatic Differentiation"),kh.forEach(o),bh.forEach(o),Nc=c(Ft),Sr=a(Ft,"LI",{});var yh=r(Sr);On=a(yh,"A",{href:!0,rel:!0});var vh=r(On);Ic=l(vh,"Vectorization"),vh.forEach(o),yh.forEach(o),Ac=c(Ft),$r=a(Ft,"LI",{});var Th=r($r);Pn=a(Th,"A",{href:!0,rel:!0});var wh=r(Pn);Dc=l(wh,"Parallelization"),wh.forEach(o),Th.forEach(o),Ft.forEach(o),Gc=c(ue),M=a(ue,"DIV",{class:!0});var j=r(M);T(Ln.$$.fragment,j),Uc=c(j),Io=a(j,"P",{});var ba=r(Io);Wc=l(ba,"The "),xr=a(ba,"CODE",{});var Sh=r(xr);Rc=l(Sh,"FlaxBlenderbotSmallPreTrainedModel"),Sh.forEach(o),Kc=l(ba," forward method, overrides the "),Br=a(ba,"CODE",{});var $h=r(Br);Hc=l($h,"__call__"),$h.forEach(o),Qc=l(ba," special method."),ba.forEach(o),Vc=c(j),T(ft.$$.fragment,j),Jc=c(j),zr=a(j,"P",{});var xh=r(zr);Xc=l(xh,"Summarization example:"),xh.forEach(o),Yc=c(j),Fr=a(j,"BLOCKQUOTE",{});var Bh=r(Fr);qr=a(Bh,"BLOCKQUOTE",{});var zh=r(qr);Er=a(zh,"BLOCKQUOTE",{});var Fh=r(Er);Mr=a(Fh,"P",{});var qh=r(Mr);Zc=l(qh,"from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration"),qh.forEach(o),Fh.forEach(o),zh.forEach(o),Bh.forEach(o),ep=c(j),Cr=a(j,"BLOCKQUOTE",{});var Eh=r(Cr);jr=a(Eh,"BLOCKQUOTE",{});var Mh=r(jr);Or=a(Mh,"BLOCKQUOTE",{});var Ch=r(Or);Pr=a(Ch,"P",{});var jh=r(Pr);op=l(jh,`model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019) >>>
tokenizer = BlenderbotSmallTokenizer.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019)`),jh.forEach(o),Ch.forEach(o),Mh.forEach(o),Eh.forEach(o),tp=c(j),Lr=a(j,"BLOCKQUOTE",{});var Oh=r(Lr);Nr=a(Oh,"BLOCKQUOTE",{});var Ph=r(Nr);Ir=a(Ph,"BLOCKQUOTE",{});var Lh=r(Ir);Ar=a(Lh,"P",{});var Nh=r(Ar);np=l(Nh,`ARTICLE_TO_SUMMARIZE = \u201CMy friends are cool but they eat too many carbs.\u201D >>> inputs =
tokenizer([ARTICLE_TO_SUMMARIZE], max_length=1024, return_tensors=\u2018np\u2019)`),Nh.forEach(o),Lh.forEach(o),Ph.forEach(o),Oh.forEach(o),ap=c(j),Dr=a(j,"BLOCKQUOTE",{});var Ih=r(Dr);Gr=a(Ih,"BLOCKQUOTE",{});var Ah=r(Gr);Nn=a(Ah,"BLOCKQUOTE",{});var kl=r(Nn);_t=a(kl,"H1",{class:!0});var yl=r(_t);gt=a(yl,"A",{id:!0,class:!0,href:!0});var Dh=r(gt);Ur=a(Dh,"SPAN",{});var Gh=r(Ur);T(In.$$.fragment,Gh),Gh.forEach(o),Dh.forEach(o),rp=c(yl),Wr=a(yl,"SPAN",{});var Uh=r(Wr);sp=l(Uh,"Generate Summary >>> summary_ids = model.generate(inputs[\u2018input_ids\u2019]).sequences >>>"),Uh.forEach(o),yl.forEach(o),lp=c(kl),Rr=a(kl,"P",{});var Wh=r(Rr);dp=l(Wh,"print(tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False))"),Wh.forEach(o),kl.forEach(o),Ah.forEach(o),Ih.forEach(o),ip=c(j),Kr=a(j,"P",{});var Rh=r(Kr);cp=l(Rh,"Mask filling example:"),Rh.forEach(o),pp=c(j),Hr=a(j,"BLOCKQUOTE",{});var Kh=r(Hr);Qr=a(Kh,"BLOCKQUOTE",{});var Hh=r(Qr);Vr=a(Hh,"BLOCKQUOTE",{});var Qh=r(Vr);Jr=a(Qh,"P",{});var Vh=r(Jr);up=l(Vh,`from transformers import BlenderbotSmallTokenizer, FlaxBlenderbotSmallForConditionalGeneration >>>
tokenizer = BlenderbotSmallTokenizer.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019) >>> TXT = \u201CMy friends are
<mask> but they eat too many carbs.\u201D`),Vh.forEach(o),Qh.forEach(o),Hh.forEach(o),Kh.forEach(o),hp=c(j),Xr=a(j,"BLOCKQUOTE",{});var Jh=r(Xr);Yr=a(Jh,"BLOCKQUOTE",{});var Xh=r(Yr);Zr=a(Xh,"BLOCKQUOTE",{});var Yh=r(Zr);es=a(Yh,"P",{});var Zh=r(es);mp=l(Zh,`model = FlaxBlenderbotSmallForConditionalGeneration.from_pretrained(\u2018facebook/blenderbot_small-90M\u2019) >>>
input_ids = tokenizer([TXT], return_tensors=\u2018np\u2019)[\u2018input_ids\u2019] >>> logits = model(input_ids).logits`),Zh.forEach(o),Yh.forEach(o),Xh.forEach(o),Jh.forEach(o),fp=c(j),os=a(j,"BLOCKQUOTE",{});var em=r(os);ts=a(em,"BLOCKQUOTE",{});var om=r(ts);ns=a(om,"BLOCKQUOTE",{});var tm=r(ns);as=a(tm,"P",{});var nm=r(as);_p=l(nm,`masked_index = (input_ids[0] == tokenizer.mask_token_id).nonzero().item() >>> probs =
jax.nn.softmax(logits[0, masked_index], axis=0) >>> values, predictions = jax.lax.top_k(probs)`),nm.forEach(o),tm.forEach(o),om.forEach(o),em.forEach(o),gp=c(j),rs=a(j,"BLOCKQUOTE",{});var am=r(rs);ss=a(am,"BLOCKQUOTE",{});var rm=r(ss);ls=a(rm,"BLOCKQUOTE",{});var sm=r(ls);ds=a(sm,"P",{});var lm=r(ds);bp=l(lm,"tokenizer.decode(predictions).split()"),lm.forEach(o),sm.forEach(o),rm.forEach(o),am.forEach(o),j.forEach(o),kp=c(ue),bt=a(ue,"DIV",{class:!0});var vl=r(bt);T(An.$$.fragment,vl),yp=c(vl),T(kt.$$.fragment,vl),vl.forEach(o),vp=c(ue),yt=a(ue,"DIV",{class:!0});var Tl=r(yt);T(Dn.$$.fragment,Tl),Tp=c(Tl),T(vt.$$.fragment,Tl),Tl.forEach(o),ue.forEach(o),this.h()},h(){u(p,"name","hf:doc:metadata"),u(p,"content",JSON.stringify(Em)),u(m,"id","blenderbot-small"),u(m,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(m,"href","#blenderbot-small"),u(f,"class","relative group"),u(se,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallModel"),u(Y,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallForConditionalGeneration"),u(K,"href","https://huggingface.co/facebook/blenderbot-90M"),u(K,"rel","nofollow"),u(Z,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot#transformers.BlenderbotModel"),u(ee,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot#transformers.BlenderbotForConditionalGeneration"),u(le,"id","overview"),u(le,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(le,"href","#overview"),u(G,"class","relative group"),u(H,"href","https://arxiv.org/pdf/2004.13637.pdf"),u(H,"rel","nofollow"),u(Q,"href","https://huggingface.co/patrickvonplaten"),u(Q,"rel","nofollow"),u(L,"href","https://github.com/facebookresearch/ParlAI"),u(L,"rel","nofollow"),u(y,"id","transformers.BlenderbotSmallConfig"),u(y,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(y,"href","#transformers.BlenderbotSmallConfig"),u(ae,"class","relative group"),u(R,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallModel"),u(ze,"href","https://huggingface.co/facebook/blenderbot_small-90M"),u(ze,"rel","nofollow"),u(ce,"href","/docs/transformers/pr_19907/en/main_classes/configuration#transformers.PretrainedConfig"),u(Kn,"href","/docs/transformers/pr_19907/en/main_classes/configuration#transformers.PretrainedConfig"),u(J,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Do,"id","transformers.BlenderbotSmallTokenizer"),u(Do,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(Do,"href","#transformers.BlenderbotSmallTokenizer"),u(So,"class","relative group"),u(Hn,"href","/docs/transformers/pr_19907/en/main_classes/tokenizer#transformers.PreTrainedTokenizer"),u(io,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Go,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Vn,"href","../glossary#token-type-ids"),u(co,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Jn,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(X,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Uo,"id","transformers.BlenderbotSmallTokenizerFast"),u(Uo,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(Uo,"href","#transformers.BlenderbotSmallTokenizerFast"),u(xo,"class","relative group"),u(Wo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ro,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Ro,"id","transformers.BlenderbotSmallModel"),u(Ro,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(Ro,"href","#transformers.BlenderbotSmallModel"),u(Bo,"class","relative group"),u(Xn,"href","/docs/transformers/pr_19907/en/main_classes/model#transformers.PreTrainedModel"),u(Rt,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(Rt,"rel","nofollow"),u(Yn,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallModel"),u(Le,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Fe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Qo,"id","transformers.BlenderbotSmallForConditionalGeneration"),u(Qo,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(Qo,"href","#transformers.BlenderbotSmallForConditionalGeneration"),u(Fo,"class","relative group"),u(Zn,"href","/docs/transformers/pr_19907/en/main_classes/model#transformers.PreTrainedModel"),u(Xt,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),u(Xt,"rel","nofollow"),u(ea,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.BlenderbotSmallForConditionalGeneration"),u(Ne,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(qe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Xo,"id","transformers.BlenderbotSmallForCausalLM"),u(Xo,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(Xo,"href","#transformers.BlenderbotSmallForCausalLM"),u(Eo,"class","relative group"),u(Yo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(Mo,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(et,"id","transformers.TFBlenderbotSmallModel"),u(et,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(et,"href","#transformers.TFBlenderbotSmallModel"),u(Co,"class","relative group"),u(oa,"href","/docs/transformers/pr_19907/en/main_classes/model#transformers.TFPreTrainedModel"),u(sn,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(sn,"rel","nofollow"),u(ta,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.TFBlenderbotSmallModel"),u(Ie,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ge,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(at,"id","transformers.TFBlenderbotSmallForConditionalGeneration"),u(at,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(at,"href","#transformers.TFBlenderbotSmallForConditionalGeneration"),u(Oo,"class","relative group"),u(na,"href","/docs/transformers/pr_19907/en/main_classes/model#transformers.TFPreTrainedModel"),u(hn,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),u(hn,"rel","nofollow"),u(aa,"href","/docs/transformers/pr_19907/en/model_doc/blenderbot-small#transformers.TFBlenderbotSmallForConditionalGeneration"),u(D,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(be,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(lt,"id","transformers.FlaxBlenderbotSmallModel"),u(lt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(lt,"href","#transformers.FlaxBlenderbotSmallModel"),u(Lo,"class","relative group"),u(ra,"href","/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(yn,"href","https://flax.readthedocs.io/en/latest/_autosummary/flax.nn.module.html"),u(yn,"rel","nofollow"),u(vn,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(vn,"rel","nofollow"),u(Tn,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(Tn,"rel","nofollow"),u(wn,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(wn,"rel","nofollow"),u(Sn,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(Sn,"rel","nofollow"),u(dt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ct,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(ut,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(U,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(mt,"id","transformers.FlaxBlenderbotSmallForConditionalGeneration"),u(mt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(mt,"href","#transformers.FlaxBlenderbotSmallForConditionalGeneration"),u(No,"class","relative group"),u(sa,"href","/docs/transformers/pr_19907/en/main_classes/model#transformers.FlaxPreTrainedModel"),u(Mn,"href","https://flax.readthedocs.io/en/latest/_autosummary/flax.nn.module.html"),u(Mn,"rel","nofollow"),u(Cn,"href","https://jax.readthedocs.io/en/latest/jax.html#just-in-time-compilation-jit"),u(Cn,"rel","nofollow"),u(jn,"href","https://jax.readthedocs.io/en/latest/jax.html#automatic-differentiation"),u(jn,"rel","nofollow"),u(On,"href","https://jax.readthedocs.io/en/latest/jax.html#vectorization-vmap"),u(On,"rel","nofollow"),u(Pn,"href","https://jax.readthedocs.io/en/latest/jax.html#parallelization-pmap"),u(Pn,"rel","nofollow"),u(gt,"id","generate-summary->>>-summary_ids-=-model.generate(inputs[\u2018input_ids\u2019]).sequences->>>"),u(gt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),u(gt,"href","#generate-summary->>>-summary_ids-=-model.generate(inputs[\u2018input_ids\u2019]).sequences->>>"),u(_t,"class","relative group"),u(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(bt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(yt,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),u(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(t,g){e(document.head,p),_(t,k,g),_(t,f,g),e(f,m),e(m,b),w(d,b,null),e(f,h),e(f,q),e(q,Ae),_(t,Me,g),_(t,C,g),e(C,De),e(C,se),e(se,B),e(C,Ge),e(C,Y),e(Y,Ue),e(C,We),e(C,K),e(K,Re),e(C,Ke),e(C,Z),e(Z,He),e(C,Qe),e(C,ee),e(ee,Ve),_(t,Ce,g),_(t,G,g),e(G,le),e(le,we),w(te,we,null),e(G,P),e(G,I),e(I,Je),_(t,de,g),_(t,ie,g),e(ie,Xe),e(ie,H),e(H,Ye),e(ie,Ze),_(t,A,g),_(t,ke,g),e(ke,he),_(t,je,g),_(t,ye,g),e(ye,ne),e(ne,eo),_(t,Oe,g),_(t,N,g),e(N,oo),e(N,Q),e(Q,to),e(N,Se),e(N,L),e(L,no),e(N,V),_(t,Pe,g),_(t,ae,g),e(ae,y),e(y,F),w($e,F,null),e(ae,xe),e(ae,ao),e(ao,_o),_(t,E,g),_(t,J,g),w(Be,J,null),e(J,go),e(J,me),e(me,bo),e(me,R),e(R,fe),e(me,ko),e(me,ze),e(ze,_e),e(me,yo),e(J,vo),e(J,re),e(re,To),e(re,ce),e(ce,wo),e(re,wl),e(re,Kn),e(Kn,Sl),e(re,$l),e(J,xl),w(Ao,J,null),_(t,Ts,g),_(t,So,g),e(So,Do),e(Do,ka),w(qt,ka,null),e(So,Bl),e(So,ya),e(ya,zl),_(t,ws,g),_(t,X,g),w(Et,X,null),e(X,Fl),e(X,va),e(va,ql),e(X,El),e(X,Mt),e(Mt,Ml),e(Mt,Hn),e(Hn,Cl),e(Mt,jl),e(X,Ol),e(X,io),w(Ct,io,null),e(io,Pl),e(io,Ta),e(Ta,Ll),e(io,Nl),e(io,wa),e(wa,Il),e(X,Al),e(X,Go),w(jt,Go,null),e(Go,Dl),e(Go,$o),e($o,Gl),e($o,Sa),e(Sa,Ul),e($o,Wl),e($o,$a),e($a,Rl),e($o,Kl),e(X,Hl),e(X,co),w(Ot,co,null),e(co,Ql),e(co,Qn),e(Qn,Vl),e(Qn,Vn),e(Vn,Jl),e(co,Xl),e(co,xa),e(xa,Yl),e(X,Zl),e(X,Jn),w(Pt,Jn,null),_(t,Ss,g),_(t,xo,g),e(xo,Uo),e(Uo,Ba),w(Lt,Ba,null),e(xo,ed),e(xo,za),e(za,od),_(t,$s,g),_(t,ro,g),w(Nt,ro,null),e(ro,td),e(ro,It),e(It,nd),e(It,Fa),e(Fa,ad),e(It,rd),e(ro,sd),e(ro,Wo),w(At,Wo,null),e(Wo,ld),e(Wo,qa),e(qa,dd),_(t,xs,g),_(t,Bo,g),e(Bo,Ro),e(Ro,Ea),w(Dt,Ea,null),e(Bo,id),e(Bo,Ma),e(Ma,cd),_(t,Bs,g),_(t,Fe,g),w(Gt,Fe,null),e(Fe,pd),e(Fe,Ut),e(Ut,ud),e(Ut,Xn),e(Xn,hd),e(Ut,md),e(Fe,fd),e(Fe,Wt),e(Wt,_d),e(Wt,Rt),e(Rt,gd),e(Wt,bd),e(Fe,kd),e(Fe,Le),w(Kt,Le,null),e(Le,yd),e(Le,zo),e(zo,vd),e(zo,Yn),e(Yn,Td),e(zo,wd),e(zo,Ca),e(Ca,Sd),e(zo,$d),e(Le,xd),w(Ko,Le,null),e(Le,Bd),w(Ho,Le,null),_(t,zs,g),_(t,Fo,g),e(Fo,Qo),e(Qo,ja),w(Ht,ja,null),e(Fo,zd),e(Fo,Oa),e(Oa,Fd),_(t,Fs,g),_(t,qe,g),w(Qt,qe,null),e(qe,qd),e(qe,Vt),e(Vt,Ed),e(Vt,Zn),e(Zn,Md),e(Vt,Cd),e(qe,jd),e(qe,Jt),e(Jt,Od),e(Jt,Xt),e(Xt,Pd),e(Jt,Ld),e(qe,Nd),e(qe,Ne),w(Yt,Ne,null),e(Ne,Id),e(Ne,qo),e(qo,Ad),e(qo,ea),e(ea,Dd),e(qo,Gd),e(qo,Pa),e(Pa,Ud),e(qo,Wd),e(Ne,Rd),w(Vo,Ne,null),e(Ne,Kd),w(Jo,Ne,null),_(t,qs,g),_(t,Eo,g),e(Eo,Xo),e(Xo,La),w(Zt,La,null),e(Eo,Hd),e(Eo,Na),e(Na,Qd),_(t,Es,g),_(t,Mo,g),w(en,Mo,null),e(Mo,Vd),e(Mo,Yo),w(on,Yo,null),e(Yo,Jd),w(Zo,Yo,null),_(t,Ms,g),_(t,Co,g),e(Co,et),e(et,Ia),w(tn,Ia,null),e(Co,Xd),e(Co,Aa),e(Aa,Yd),_(t,Cs,g),_(t,ge,g),w(nn,ge,null),e(ge,Zd),e(ge,an),e(an,ei),e(an,oa),e(oa,oi),e(an,ti),e(ge,ni),e(ge,rn),e(rn,ai),e(rn,sn),e(sn,ri),e(rn,si),e(ge,li),w(ot,ge,null),e(ge,di),e(ge,Ie),w(ln,Ie,null),e(Ie,ii),e(Ie,jo),e(jo,ci),e(jo,ta),e(ta,pi),e(jo,ui),e(jo,Da),e(Da,hi),e(jo,mi),e(Ie,fi),w(tt,Ie,null),e(Ie,_i),w(nt,Ie,null),_(t,js,g),_(t,Oo,g),e(Oo,at),e(at,Ga),w(dn,Ga,null),e(Oo,gi),e(Oo,Ua),e(Ua,bi),_(t,Os,g),_(t,be,g),w(cn,be,null),e(be,ki),e(be,pn),e(pn,yi),e(pn,na),e(na,vi),e(pn,Ti),e(be,wi),e(be,un),e(un,Si),e(un,hn),e(hn,$i),e(un,xi),e(be,Bi),w(rt,be,null),e(be,zi),e(be,D),w(mn,D,null),e(D,Fi),e(D,Po),e(Po,qi),e(Po,aa),e(aa,Ei),e(Po,Mi),e(Po,Wa),e(Wa,Ci),e(Po,ji),e(D,Oi),w(st,D,null),e(D,Pi),e(D,Ra),e(Ra,Li),e(D,Ni),e(D,Ka),e(Ka,Ha),e(Ha,Qa),e(Qa,Va),e(Va,Ii),e(D,Ai),e(D,Ja),e(Ja,Xa),e(Xa,Ya),e(Ya,Za),e(Za,Di),e(D,Gi),e(D,er),e(er,or),e(or,tr),e(tr,nr),e(nr,Ui),e(D,Wi),e(D,ar),e(ar,rr),e(rr,sr),e(sr,fn),e(fn,Ri),e(fn,lr),e(lr,Ki),e(fn,Hi),e(D,Qi),e(D,dr),e(dr,ir),e(ir,cr),e(cr,pr),e(pr,Vi),_(t,Ps,g),_(t,Lo,g),e(Lo,lt),e(lt,ur),w(_n,ur,null),e(Lo,Ji),e(Lo,hr),e(hr,Xi),_(t,Ls,g),_(t,U,g),w(gn,U,null),e(U,Yi),e(U,bn),e(bn,Zi),e(bn,ra),e(ra,ec),e(bn,oc),e(U,tc),e(U,kn),e(kn,nc),e(kn,yn),e(yn,ac),e(kn,rc),e(U,sc),e(U,mr),e(mr,lc),e(U,dc),e(U,so),e(so,fr),e(fr,vn),e(vn,ic),e(so,cc),e(so,_r),e(_r,Tn),e(Tn,pc),e(so,uc),e(so,gr),e(gr,wn),e(wn,hc),e(so,mc),e(so,br),e(br,Sn),e(Sn,fc),e(U,_c),e(U,dt),w($n,dt,null),e(dt,gc),w(it,dt,null),e(U,bc),e(U,ct),w(xn,ct,null),e(ct,kc),w(pt,ct,null),e(U,yc),e(U,ut),w(Bn,ut,null),e(ut,vc),w(ht,ut,null),_(t,Ns,g),_(t,No,g),e(No,mt),e(mt,kr),w(zn,kr,null),e(No,Tc),e(No,yr),e(yr,wc),_(t,Is,g),_(t,W,g),w(Fn,W,null),e(W,Sc),e(W,qn),e(qn,$c),e(qn,sa),e(sa,xc),e(qn,Bc),e(W,zc),e(W,En),e(En,Fc),e(En,Mn),e(Mn,qc),e(En,Ec),e(W,Mc),e(W,vr),e(vr,Cc),e(W,jc),e(W,lo),e(lo,Tr),e(Tr,Cn),e(Cn,Oc),e(lo,Pc),e(lo,wr),e(wr,jn),e(jn,Lc),e(lo,Nc),e(lo,Sr),e(Sr,On),e(On,Ic),e(lo,Ac),e(lo,$r),e($r,Pn),e(Pn,Dc),e(W,Gc),e(W,M),w(Ln,M,null),e(M,Uc),e(M,Io),e(Io,Wc),e(Io,xr),e(xr,Rc),e(Io,Kc),e(Io,Br),e(Br,Hc),e(Io,Qc),e(M,Vc),w(ft,M,null),e(M,Jc),e(M,zr),e(zr,Xc),e(M,Yc),e(M,Fr),e(Fr,qr),e(qr,Er),e(Er,Mr),e(Mr,Zc),e(M,ep),e(M,Cr),e(Cr,jr),e(jr,Or),e(Or,Pr),e(Pr,op),e(M,tp),e(M,Lr),e(Lr,Nr),e(Nr,Ir),e(Ir,Ar),e(Ar,np),e(M,ap),e(M,Dr),e(Dr,Gr),e(Gr,Nn),e(Nn,_t),e(_t,gt),e(gt,Ur),w(In,Ur,null),e(_t,rp),e(_t,Wr),e(Wr,sp),e(Nn,lp),e(Nn,Rr),e(Rr,dp),e(M,ip),e(M,Kr),e(Kr,cp),e(M,pp),e(M,Hr),e(Hr,Qr),e(Qr,Vr),e(Vr,Jr),e(Jr,up),e(M,hp),e(M,Xr),e(Xr,Yr),e(Yr,Zr),e(Zr,es),e(es,mp),e(M,fp),e(M,os),e(os,ts),e(ts,ns),e(ns,as),e(as,_p),e(M,gp),e(M,rs),e(rs,ss),e(ss,ls),e(ls,ds),e(ds,bp),e(W,kp),e(W,bt),w(An,bt,null),e(bt,yp),w(kt,bt,null),e(W,vp),e(W,yt),w(Dn,yt,null),e(yt,Tp),w(vt,yt,null),As=!0},p(t,[g]){const Gn={};g&2&&(Gn.$$scope={dirty:g,ctx:t}),Ao.$set(Gn);const is={};g&2&&(is.$$scope={dirty:g,ctx:t}),Ko.$set(is);const cs={};g&2&&(cs.$$scope={dirty:g,ctx:t}),Ho.$set(cs);const ps={};g&2&&(ps.$$scope={dirty:g,ctx:t}),Vo.$set(ps);const ve={};g&2&&(ve.$$scope={dirty:g,ctx:t}),Jo.$set(ve);const us={};g&2&&(us.$$scope={dirty:g,ctx:t}),Zo.$set(us);const hs={};g&2&&(hs.$$scope={dirty:g,ctx:t}),ot.$set(hs);const ms={};g&2&&(ms.$$scope={dirty:g,ctx:t}),tt.$set(ms);const fs={};g&2&&(fs.$$scope={dirty:g,ctx:t}),nt.$set(fs);const _s={};g&2&&(_s.$$scope={dirty:g,ctx:t}),rt.$set(_s);const Un={};g&2&&(Un.$$scope={dirty:g,ctx:t}),st.$set(Un);const gs={};g&2&&(gs.$$scope={dirty:g,ctx:t}),it.$set(gs);const bs={};g&2&&(bs.$$scope={dirty:g,ctx:t}),pt.$set(bs);const ks={};g&2&&(ks.$$scope={dirty:g,ctx:t}),ht.$set(ks);const Wn={};g&2&&(Wn.$$scope={dirty:g,ctx:t}),ft.$set(Wn);const ys={};g&2&&(ys.$$scope={dirty:g,ctx:t}),kt.$set(ys);const vs={};g&2&&(vs.$$scope={dirty:g,ctx:t}),vt.$set(vs)},i(t){As||(S(d.$$.fragment,t),S(te.$$.fragment,t),S($e.$$.fragment,t),S(Be.$$.fragment,t),S(Ao.$$.fragment,t),S(qt.$$.fragment,t),S(Et.$$.fragment,t),S(Ct.$$.fragment,t),S(jt.$$.fragment,t),S(Ot.$$.fragment,t),S(Pt.$$.fragment,t),S(Lt.$$.fragment,t),S(Nt.$$.fragment,t),S(At.$$.fragment,t),S(Dt.$$.fragment,t),S(Gt.$$.fragment,t),S(Kt.$$.fragment,t),S(Ko.$$.fragment,t),S(Ho.$$.fragment,t),S(Ht.$$.fragment,t),S(Qt.$$.fragment,t),S(Yt.$$.fragment,t),S(Vo.$$.fragment,t),S(Jo.$$.fragment,t),S(Zt.$$.fragment,t),S(en.$$.fragment,t),S(on.$$.fragment,t),S(Zo.$$.fragment,t),S(tn.$$.fragment,t),S(nn.$$.fragment,t),S(ot.$$.fragment,t),S(ln.$$.fragment,t),S(tt.$$.fragment,t),S(nt.$$.fragment,t),S(dn.$$.fragment,t),S(cn.$$.fragment,t),S(rt.$$.fragment,t),S(mn.$$.fragment,t),S(st.$$.fragment,t),S(_n.$$.fragment,t),S(gn.$$.fragment,t),S($n.$$.fragment,t),S(it.$$.fragment,t),S(xn.$$.fragment,t),S(pt.$$.fragment,t),S(Bn.$$.fragment,t),S(ht.$$.fragment,t),S(zn.$$.fragment,t),S(Fn.$$.fragment,t),S(Ln.$$.fragment,t),S(ft.$$.fragment,t),S(In.$$.fragment,t),S(An.$$.fragment,t),S(kt.$$.fragment,t),S(Dn.$$.fragment,t),S(vt.$$.fragment,t),As=!0)},o(t){$(d.$$.fragment,t),$(te.$$.fragment,t),$($e.$$.fragment,t),$(Be.$$.fragment,t),$(Ao.$$.fragment,t),$(qt.$$.fragment,t),$(Et.$$.fragment,t),$(Ct.$$.fragment,t),$(jt.$$.fragment,t),$(Ot.$$.fragment,t),$(Pt.$$.fragment,t),$(Lt.$$.fragment,t),$(Nt.$$.fragment,t),$(At.$$.fragment,t),$(Dt.$$.fragment,t),$(Gt.$$.fragment,t),$(Kt.$$.fragment,t),$(Ko.$$.fragment,t),$(Ho.$$.fragment,t),$(Ht.$$.fragment,t),$(Qt.$$.fragment,t),$(Yt.$$.fragment,t),$(Vo.$$.fragment,t),$(Jo.$$.fragment,t),$(Zt.$$.fragment,t),$(en.$$.fragment,t),$(on.$$.fragment,t),$(Zo.$$.fragment,t),$(tn.$$.fragment,t),$(nn.$$.fragment,t),$(ot.$$.fragment,t),$(ln.$$.fragment,t),$(tt.$$.fragment,t),$(nt.$$.fragment,t),$(dn.$$.fragment,t),$(cn.$$.fragment,t),$(rt.$$.fragment,t),$(mn.$$.fragment,t),$(st.$$.fragment,t),$(_n.$$.fragment,t),$(gn.$$.fragment,t),$($n.$$.fragment,t),$(it.$$.fragment,t),$(xn.$$.fragment,t),$(pt.$$.fragment,t),$(Bn.$$.fragment,t),$(ht.$$.fragment,t),$(zn.$$.fragment,t),$(Fn.$$.fragment,t),$(Ln.$$.fragment,t),$(ft.$$.fragment,t),$(In.$$.fragment,t),$(An.$$.fragment,t),$(kt.$$.fragment,t),$(Dn.$$.fragment,t),$(vt.$$.fragment,t),As=!1},d(t){o(p),t&&o(k),t&&o(f),x(d),t&&o(Me),t&&o(C),t&&o(Ce),t&&o(G),x(te),t&&o(de),t&&o(ie),t&&o(A),t&&o(ke),t&&o(je),t&&o(ye),t&&o(Oe),t&&o(N),t&&o(Pe),t&&o(ae),x($e),t&&o(E),t&&o(J),x(Be),x(Ao),t&&o(Ts),t&&o(So),x(qt),t&&o(ws),t&&o(X),x(Et),x(Ct),x(jt),x(Ot),x(Pt),t&&o(Ss),t&&o(xo),x(Lt),t&&o($s),t&&o(ro),x(Nt),x(At),t&&o(xs),t&&o(Bo),x(Dt),t&&o(Bs),t&&o(Fe),x(Gt),x(Kt),x(Ko),x(Ho),t&&o(zs),t&&o(Fo),x(Ht),t&&o(Fs),t&&o(qe),x(Qt),x(Yt),x(Vo),x(Jo),t&&o(qs),t&&o(Eo),x(Zt),t&&o(Es),t&&o(Mo),x(en),x(on),x(Zo),t&&o(Ms),t&&o(Co),x(tn),t&&o(Cs),t&&o(ge),x(nn),x(ot),x(ln),x(tt),x(nt),t&&o(js),t&&o(Oo),x(dn),t&&o(Os),t&&o(be),x(cn),x(rt),x(mn),x(st),t&&o(Ps),t&&o(Lo),x(_n),t&&o(Ls),t&&o(U),x(gn),x($n),x(it),x(xn),x(pt),x(Bn),x(ht),t&&o(Ns),t&&o(No),x(zn),t&&o(Is),t&&o(W),x(Fn),x(Ln),x(ft),x(In),x(An),x(kt),x(Dn),x(vt)}}}const Em={local:"blenderbot-small",sections:[{local:"overview",title:"Overview"},{local:"transformers.BlenderbotSmallConfig",title:"BlenderbotSmallConfig"},{local:"transformers.BlenderbotSmallTokenizer",title:"BlenderbotSmallTokenizer"},{local:"transformers.BlenderbotSmallTokenizerFast",title:"BlenderbotSmallTokenizerFast"},{local:"transformers.BlenderbotSmallModel",title:"BlenderbotSmallModel"},{local:"transformers.BlenderbotSmallForConditionalGeneration",title:"BlenderbotSmallForConditionalGeneration"},{local:"transformers.BlenderbotSmallForCausalLM",title:"BlenderbotSmallForCausalLM"},{local:"transformers.TFBlenderbotSmallModel",title:"TFBlenderbotSmallModel"},{local:"transformers.TFBlenderbotSmallForConditionalGeneration",title:"TFBlenderbotSmallForConditionalGeneration"},{local:"transformers.FlaxBlenderbotSmallModel",title:"FlaxBlenderbotSmallModel"},{local:"transformers.FlaxBlenderbotSmallForConditionalGeneration",title:"FlaxBlenderbotForConditionalGeneration"}],title:"Blenderbot Small"};function Mm(z){return um(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Im extends dm{constructor(p){super();im(this,p,Mm,qm,cm,{})}}export{Im as default,Em as metadata};
